Room Charges(Account ID change,add dropdown list,tac not calculate)
This commit is contained in:
@@ -177,7 +177,7 @@ class Sale < ApplicationRecord
|
|||||||
sale_item = SaleItem.new
|
sale_item = SaleItem.new
|
||||||
sale_item.product_code = chargeObj.item_code
|
sale_item.product_code = chargeObj.item_code
|
||||||
sale_item.product_name = dining_name.to_s + " ( " + dining_time.to_s + " )"
|
sale_item.product_name = dining_name.to_s + " ( " + dining_time.to_s + " )"
|
||||||
# sale_item.account_id = item.account_id
|
sale_item.account_id = 0
|
||||||
sale_item.product_alt_name = "-"
|
sale_item.product_alt_name = "-"
|
||||||
sale_item.qty = 1
|
sale_item.qty = 1
|
||||||
sale_item.unit_price = chargeObj.unit_price
|
sale_item.unit_price = chargeObj.unit_price
|
||||||
@@ -186,7 +186,7 @@ class Sale < ApplicationRecord
|
|||||||
sale_item.sale_id = self.id
|
sale_item.sale_id = self.id
|
||||||
sale_item.price = diningprice
|
sale_item.price = diningprice
|
||||||
sale_item.save
|
sale_item.save
|
||||||
self.compute
|
self.compute_by_sale_items(self.id, self.sale_items, self.total_discount)
|
||||||
end
|
end
|
||||||
|
|
||||||
def update_item (item)
|
def update_item (item)
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
<%= f.input :charge_type, :collection => [:hr, :day] %>
|
<%= f.input :charge_type, :collection => [:hr, :day] %>
|
||||||
<%= f.input :minimum_free_time %>
|
<%= f.input :minimum_free_time %>
|
||||||
<%= f.input :charge_block, :input_html => { :id => 'charge_block'} %>
|
<%= f.input :charge_block, :input_html => { :id => 'charge_block'} %>
|
||||||
<%= f.input :time_rounding %>
|
<%= f.input :time_rounding, :collection => [:down, :up] %>
|
||||||
<%= f.input :time_rounding_block, :input_html => { :id => 'time_rounding_block'} %>
|
<%= f.input :time_rounding_block, :input_html => { :id => 'time_rounding_block'} %>
|
||||||
<%= f.input :time_rounding_block_price, :input_html => { :id => 'time_rounding_block_price'} %>
|
<%= f.input :time_rounding_block_price, :input_html => { :id => 'time_rounding_block_price'} %>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user