check tax for promo activated

This commit is contained in:
phyusin
2018-06-20 14:57:52 +06:30
parent d024810739
commit 84084303f4

View File

@@ -426,6 +426,9 @@ class Sale < ApplicationRecord
tax_profiles = TaxProfile.all.order("order_by asc")
customer = Customer.find(sale.customer_id)
# #Creat new tax records
if order_source.to_s == "emenu"
order_source = "cashier"
end
if sale.payment_status != 'foc'
tax_profiles.each do |tax|