(function(i,s,o,g,r,a,m){ i['GoogleAnalyticsObject']=r; i[r]=i[r]||function(){(i[r].q=i[r].q||[]).push(arguments);}; i[r].l=1*new Date(); a=s.createElement(o); m=s.getElementsByTagName(o)[0]; a.async=1; a.src=g; m.parentNode.insertBefore(a,m); })(window,document,'script','//www.google-analytics.com/analytics.js','ga'); // google analytics // UA-58389346-2 is the development tracker // UA-58389346-3 is the production release tracker // this code should always point to the development tracker // The release script will change this automatically when it is pushed to production ga('create', 'UA-58389346-3', 'auto'); ga('set', { 'appName': 'DebtPlanner', 'appId': '3', 'appVersion': '2.0', 'appInstallerId': 'unknown' }); /** * @constructor */ function GlobalConstants() { var queries = {}; $.each(document.location.search.substr(1).split('&'),function(c,q){ if(q) { var i = q.split('='); queries[i[0].toString()] = i[1].toString(); } }); this.SERVER_PHP = "/server.php"; this.ATIME = (typeof queries.atime === 'undefined')?400:(queries.atime*1); this.PIE_CHART_COLORS = ["#4BC5DC","#FFCA53","#6AF04E","#FF6353","#777","#71D8EB","#FFD577","#8AF673","#FF8477","#CCC","#9FE8F6","#FFE2A2","#B0FBA0","#FFABA2","#999",]; this.COLORS = {p1:"#71D8EB",s1:"#FFD577",f1:"#8AF673",t1:"#FF8477",g1:"#997EEF",gray0:"#CCC",p2:"#F0FCFF",s2:"#FFFAF0",f2:"#DEFED8",t2:"#FFF1F0",g2:"#E4DBFD",gray1:"#AAA",p3:"#9FE8F6",s3:"#FFE2A2",f3:"#B0FBA0",t3:"#FFABA2",g3:"#BBA8F7",gray2:"#999",p4:"#4BC5DC",s4:"#FFCA53",f4:"#6AF04E",t4:"#FF6353",g4:"#7B5BE3",gray3:"#777",p5:"#29ACC5",s5:"#FFBF31",f5:"#4CE62C",t5:"#FF4431",g5:"#5E3BD0",gray4:"#555",}; // this.ORDER_KEY_TO_TEXT = { // "reverse_avalanche":"Reverse Avalanche (APR low to high)", // "reverse_snowball":"Reverse Snowball (Balance high to low)", // "listed":"As listed", // "snowball":"Snowball (Balance low to high)", // "avalanche":"Avalanche (APR high to low)" // }; this.ORDER_KEY_TO_TEXT = { "reverse_avalanche":"Reverse Avalanche", "reverse_snowball":"Reverse Snowball", "listed":"As listed", "snowball":"Snowball", "avalanche":"Avalanche" }; this.IS_MOBILE = false; this.IS_DESKTOP_FREE = true; this.STRIPE_KEY = 'pk_live_s6Q9vCueGp8PrwreShe18TlM'; this.DEBT_TYPE_ICON = (function() { var x = { "Credit Card": "fad fa-credit-card-front fad-orange", "Auto Loan": "fad fa-car fad-purple", "Student Loan": "fad fa-graduation-cap fad-orange-invert", "Medical Loan": "fad fa-heartbeat fad-red-invert", "Mortgage": "fad fa-home fad-red-invert", "Personal Loan": "fad fa-user-check fad-blue", "Taxes": "fad fa-university fad-purple-invert", "Other": "fad fa-file-invoice fad-blue-invert", "": "far fa-ellipsis-h fad-orange-invert", "Uncategorized": "far fa-ellipsis-h fad-orange-invert" }; var y = {}; Object.keys(x).forEach(function(key) { y[key] = '' }) return y; })(); this.BUTTON_ICON = (function() { var x = { "chart": "fad fa-credit-card-front fad-orange", "edit": "fad fa-car fad-purple", "delete": "fad fa-graduation-cap fad-orange-invert", "goback": "fad fa-heartbeat fad-red-invert", "add": "fad fa-home fad-red-invert", "question": "fad fa-user-check fad-blue", "calculator": "fad fa-university fad-purple-invert", "Other": "fad fa-file-invoice fad-blue-invert", "carat_down": "far fa-ellipsis-h fad-orange-invert", "carat_right": "far fa-ellipsis-h fad-orange-invert", "printer": "", }; var y = {}; Object.keys(x).forEach(function(key) { y[key] = '' }) return y; })(); this.DEBT_TYPE_EMOJI = (function() { var x = { "Credit Card": "💳", "Auto Loan": "🚗", "Student Loan": "🎓", "Medical Loan": "🏥", "Mortgage": "🏠", "Personal Loan": "👥", "Taxes": "🏛️", "Other": "💰", "": "💸", "Uncategorized": "💸" }; var y = {}; Object.keys(x).forEach(function(key) { y[key] = ''+x[key]+'' }) return y; })(); this.PROGRESS_PAID_COLOR = "#4BC5DC"; this.PROGRESS_UNPAID_COLOR = "#DDD"; this.KELLY_SJOSTROM_PROMO_SPLIT_TARGET = "C"; // "B" this.KELLY_SJOSTROM_PROMO_SPLIT_INDEX = 3; // 3 this.KELLY_SJOSTROM_PROMO2_SPLIT_TARGET = "C"; // set to "C" to disable the promo completely this.KELLY_SJOSTROM_PROMO2_SPLIT_INDEX = 2; } var gc_ = new GlobalConstants();