shift update

This commit is contained in:
Yan
2017-12-07 12:07:06 +06:30
parent 04b27489dd
commit 69b786a91d
4 changed files with 12 additions and 4 deletions

View File

@@ -115,7 +115,7 @@ class Sale < ApplicationRecord
booking.sale_id = self.id
booking.checkout_at = Time.now.utc.getlocal
booking.checkout_by = requested_by.name
# booking.checkout_by = requested_by.name
booking.save
InventoryJob.perform_now(self.id)

View File

@@ -282,7 +282,7 @@ class SalePayment < ApplicationRecord
end
def sale_update_payment_status(paid_amount)
def sale_update_payment_status(paid_amount)
#update amount_outstanding
self.sale.amount_received = self.sale.amount_received.to_f + paid_amount.to_f
self.sale.save!