fix: test cases
This commit is contained in:
parent
e540534e42
commit
70b996af73
@ -452,7 +452,10 @@ class SalarySlip(TransactionBase):
|
||||
|
||||
self.set_loan_repayment()
|
||||
|
||||
self.net_pay = (flt(self.gross_pay) - (flt(self.total_deduction) + flt(self.total_loan_repayment))) * flt(self.payment_days / self.total_working_days)
|
||||
self.net_pay = 0
|
||||
if self.total_working_days:
|
||||
self.net_pay = (flt(self.gross_pay) - (flt(self.total_deduction) + flt(self.total_loan_repayment))) * flt(self.payment_days / self.total_working_days)
|
||||
|
||||
self.rounded_total = rounded(self.net_pay,
|
||||
self.precision("net_pay") if disable_rounded_total else 0)
|
||||
|
||||
|
@ -160,8 +160,9 @@ erpnext.TransactionController = erpnext.taxes_and_totals.extend({
|
||||
}
|
||||
|
||||
if(frappe.meta.get_docfield(this.frm.doc.doctype, "pricing_rules")) {
|
||||
this.frm.set_indicator_formatter('pricing_rule',
|
||||
function(doc) { return (doc.rule_applied) ? "green" : "red" });
|
||||
this.frm.set_indicator_formatter('pricing_rule', function(doc) {
|
||||
return (doc.rule_applied) ? "green" : "red";
|
||||
});
|
||||
}
|
||||
},
|
||||
onload: function() {
|
||||
|
Loading…
x
Reference in New Issue
Block a user