update for shift and deving member dis

This commit is contained in:
Yan
2017-07-07 14:56:05 +06:30
parent 4d3de51e72
commit 1b0bcbffea
9 changed files with 78 additions and 37 deletions

View File

@@ -9,6 +9,11 @@ class Origami::VoidController < BaseOrigamiController
sale.sale_status = 'void'
sale.save
# update count for shift sale
shift = ShiftSale.current_open_shift(sale.cashier_id)
shift.total_void = shift.total_void + 1
shift.save
bookings = sale.bookings
bookings.each do |booking|
orders = booking.orders