Merge branch 'adminbsb_ui_changes' of bitbucket.org:code2lab/sxrestaurant
This commit is contained in:
@@ -29,7 +29,9 @@ if (menu.menu_categories)
|
||||
|
||||
if category.menu_items
|
||||
json.items category.menu_items do |item|
|
||||
json.partial! 'origami/addorders/menu_item', item: item
|
||||
if item.is_available
|
||||
json.partial! 'origami/addorders/menu_item', item: item
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@@ -151,14 +151,24 @@
|
||||
<td style='text-align:right;'><%= number_with_precision(rounding_adj, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
|
||||
</tr>
|
||||
<% total_tax = 0 %>
|
||||
<% total_tax = 0
|
||||
tax_amount = 0
|
||||
tax_name = ''
|
||||
tax_arr = [] %>
|
||||
<% net = 0 %>
|
||||
<% unless @tax.empty? %>
|
||||
<% @tax.each do |tax| %>
|
||||
<% total_tax += tax.tax_amount.to_f %>
|
||||
<% if tax.tax_name.downcase == tax_name.downcase
|
||||
tax_amount += tax.tax_amount
|
||||
else
|
||||
tax_amount = tax.tax_amount
|
||||
end
|
||||
tax_name = tax.tax_name
|
||||
total_tax += tax.tax_amount.to_f
|
||||
%>
|
||||
<tr style="font-weight:600;">
|
||||
<td colspan="17" style='text-align:right;'><%= tax.tax_name rescue '-'%></td>
|
||||
<td style='text-align:right;'><%= number_with_precision(tax.tax_amount, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<td colspan="17" style='text-align:right;'><%= tax_name rescue '-'%></td>
|
||||
<td style='text-align:right;'><%= number_with_precision(tax_amount, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<td colspan="2"> </td>
|
||||
</tr>
|
||||
<% end %>
|
||||
@@ -170,8 +180,8 @@
|
||||
<td colspan="2"> </td>
|
||||
</tr>
|
||||
|
||||
<% net = grand_total%>
|
||||
<% net = grand_total- discount%>
|
||||
<% net = grand_total %>
|
||||
<% net = grand_total + discount%>
|
||||
<% net = net - rounding_adj%>
|
||||
<% net = net - total_tax %>
|
||||
<tr style="font-weight:600;">
|
||||
|
||||
Reference in New Issue
Block a user