This commit is contained in:
Myat Zin Wai Maw
2019-09-04 18:19:06 +06:30
parent f3f74db446
commit 34c3dc47ae
6 changed files with 46 additions and 44 deletions

View File

@@ -395,7 +395,6 @@ class SalePayment < ApplicationRecord
self.payment_status = "paid"
payment_status = self.save!
if !payment_for
sale_update_payment_status(self.received_amount,status)
end
@@ -661,8 +660,7 @@ class SalePayment < ApplicationRecord
method_status = true
end
end
if (self.sale.grand_total <= all_received_amount) && method_status
if (self.sale.grand_total.round <= all_received_amount) && method_status
if is_credit == 0
self.sale.payment_status = "paid"
else