Receipt No : <%=@sale_data.receipt_no rescue ' '%>
Receipt Date : <%=@sale_data.receipt_date.utc.getlocal.strftime("%d/%m/%Y-%I:%M %p") rescue '-' %>
Table No : <%=@table_no%>
Sale ID : <% if @sale_data %><%=@sale_data.sale_id %><% end %>
Customer : <%= @sale_data.customer.name%>
Checkin Time : <%= @checkin_time.utc.getlocal.strftime("%I:%M %p") %>
# Items QTY Price
<% sub_total = 0 count = 0 %> <% @sale_data.sale_items.each do |sale_item| count += 1 %> <% sub_total += sale_item.price%> <%end %>
<%= count %> <%=sale_item.product_name%>@<%=sale_item.unit_price%> <%=sale_item.qty%> <%=(sale_item.price)%>
Amount Due
<%= @sale_data.grand_total %>
Cash
<%= @cash %>
Credit
<%= @credit %>
<% if @other == 0.0 && @ppamount == 0.0 && @visacount == 0.0 && @jcbcount == 0.0 && @mastercount == 0.0%>
Other Payments
<%= @other %>
<% else %>
Other Payments
<% end %>
<% if @other != 0.0 %>
MPU
<%= @other %>
<% else %> <% end %> <% if @ppamount != 0.0 %>
Redeem
<%= @ppamount %>
<% else %> <% end %> <% if @visacount != 0.0 %>
Visa
<%= @visacount %>
<% else %> <% end %> <% if @jcbcount != 0.0 %>
JCB
<%= @jcbcount %>
<% else %> <% end %> <% if @mastercount != 0.0 %>
Master
<%= @mastercount %>
<% else %> <% end %>
Balance
<%= @sale_data.grand_total %>