From 9d0627610fa66b6896b4b6c238b022165f132827 2015-03-12 01:57:06 From: Bradley M. Kuhn Date: 2015-03-12 01:57:06 Subject: [PATCH] Make rise level consistent for both items. With this change, both numbers should go up at the same rate. --- diff --git a/www/conservancy/static/supporter-page.js b/www/conservancy/static/supporter-page.js index 8b4a785712ccb2fff13c745498fdae5ddb12d648..7aa7468571118e0c8397ff2beb0204857a21e21c 100644 --- a/www/conservancy/static/supporter-page.js +++ b/www/conservancy/static/supporter-page.js @@ -15,7 +15,8 @@ $(document).ready(function() { var curValue = 0.00; var incrementSoFar = 0.00; var curDonationCount = 0; - var incrementDonationCount = Math.round( 0.01 * donationCount ); + var riseLevelPercent = 0.5; + var incrementDonationCount = Math.round( (riseLevelPercent / 100) * donationCount ); $('span#fundraiser-percentage').css({ 'color' : 'green', 'font-weight' : 'bold', @@ -32,7 +33,7 @@ $(document).ready(function() { var newVal = (curValue / 100.00) * noCommaGoal; $("#progressbar").progressbar({ value: curValue }); $('span#fundraiser-so-far').text(newVal.toLocaleString()); - curValue += 0.5; + curValue += riseLevelPercent; setTimeout(riseDonationProgressBar, 50); } }