Last active
October 21, 2017 04:50
-
-
Save Sampath-Lokuge/e4ba50011b421dc25fe51bb60f5966af to your computer and use it in GitHub Desktop.
Formula of paid
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
this.remainingAmount = this.totalOfBudgetAndContingency - spent; | |
this.paidPercentage = (this.amountPaid / this.totalOfBudgetAndContingency) * 100; | |
if (this.paidPercentage > 80) { | |
this.remainingPercentageExcludingPaid = 0; | |
this.contingencyPercentage = (totalContingency / this.totalOfBudgetAndContingency) * 100; | |
this.paidPercentage = 100 - this.contingencyPercentage; | |
} else { | |
this.remainingPercentageExcludingPaid = (this.remainingAmount / this.totalOfBudgetAndContingency) * 100; | |
this.contingencyPercentage = (totalContingency / this.totalOfBudgetAndContingency) * 100; | |
} |
Author
Sampath-Lokuge
commented
Oct 21, 2017
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment