update closing receipt

This commit is contained in:
Aung Myo
2017-08-08 18:03:02 +06:30
parent 285ad93501
commit 644b94764e
5 changed files with 156 additions and 26 deletions

View File

@@ -569,7 +569,7 @@ def self.get_item_query()
query = query.joins(" JOIN accounts acc ON acc.id = mi.account_id")
query = query.group('i.product_code ').order("mi.account_id, mi.menu_category_id")
end
end
def self.get_by_shift_items(shift_sale_range, shift, from, to, status)
@@ -746,15 +746,6 @@ def self.get_separate_tax(shift_sale_range=nil,shift,from,to,payment_type)
end
end
# def self.get_separate_tax(from,to,payment_method=nil)
# query = SaleTax.select("SUM(tax_payable_amount) AS st_amount,tax_name")
# .joins("INNER JOIN sales ON sales.sale_id = sale_taxes.sale_id")
# .group("sale_taxes.tax_name")
# return query = query.where("sale_status=? and receipt_date between ? and ?","completed",from,to)
# end
def grand_total_after_rounding
return self.old_grand_total.to_f + self.rounding_adjustment.to_f
end