change query for credit payment report

This commit is contained in:
phyusin
2018-09-19 10:40:45 +06:30
parent 7256469c4a
commit e7ef645200
3 changed files with 14 additions and 3 deletions

View File

@@ -55,7 +55,13 @@
<td><%= credit.cashier_name rescue '-' %></td>
<td><%= credit.sale.customer.name rescue '-' %></td>
<td><%= credit.payment_amount rescue '-' %></td>
<td><%= credit.credit_payment_shift_name rescue '-' %></td>
<td>
<%if credit.credit_payment_shift_name == '-' %>
<%= credit.sale_date.utc.getlocal.strftime("%e %b %I:%M%p") rescue '-'%>
<% else %>
<%= credit.credit_payment_shift_name rescue '-' %>
<% end %>
</td>
<td><%= credit.credit_payment_receipt_date rescue '-' %></td>
<td><%= credit.credit_payment_cashier_name rescue '-' %></td>
<td><%= credit.credit_payment rescue '-' %></td>