booking status changed

This commit is contained in:
phyusin
2018-10-03 14:17:08 +06:30
parent 9dba93ea9c
commit 7bf01a863c
4 changed files with 66 additions and 11 deletions

View File

@@ -41,21 +41,22 @@
<th><%= t :cashier %></th>
<th><%= t("views.right_panel.detail.sales_status") %></th>
<th><%= t("views.right_panel.detail.receipt_generated_at") %></th>
<% if @sale.sale_status == "completed" %>
<% if @sale.sale_status == "new" || @sale.sale_status == "completed" %>
<% if current_login_employee.role == "administrator" || current_login_employee.role == "manager" %>
<th>
<button type="button" class="btn btn-block bg-red waves-effect" data-toggle="modal" data-target="#voidModal" <%= (can? :overall_void, :void)? ' ': 'disabled=' %> > Void</button>
</th>
<div class="form-group">
<button type="button" class="btn btn-block bg-red waves-effect col-md-5" style="margin-top: 8px;" data-toggle="modal" data-target="#voidModal" <%= (can? :overall_void, :void)? ' ': 'disabled=' %> > Void</button>
<% end %>
<% elsif @sale.sale_status == "new" %>
<% end %>
<% if @sale.sale_status == "new" %>
<% if current_login_employee.role == "administrator" %>
<%if @membership.discount && @sale.customer.membership_id %>
<th>
<button type="button" class="btn btn-block bg-blue waves-effect" data-toggle="modal" data-target="#paymentModal">Pay</button>
<button type="button" class="btn btn-block bg-blue waves-effect col-md-5" data-toggle="modal" data-target="#paymentModal">Pay</button>
</div>
</th>
<%else%>
<th>
<button type="button" id="pay" class="btn btn-block bg-blue waves-effect">Pay</button>
<button type="button" id="pay" class="btn btn-block bg-blue waves-effect col-md-5">Pay</button>
</div>
</th>
<%end%>
<%end%>