update OQS and cashier
This commit is contained in:
@@ -123,9 +123,15 @@
|
||||
<div class="card" >
|
||||
<div class="card-header">
|
||||
<% if @status_order == 'order' %>
|
||||
<div id="save_order_id" data-order="<%= @obj_order.order_id %>"><strong id="order-title">ORDER DETAILS </strong> | Table <%= @room.name rescue "" %></div>
|
||||
<div id="save_order_id" data-order="<%= @obj_order.order_id %>"><strong id="order-title">ORDER DETAILS </strong> | Table <%= @room.name rescue "" %>
|
||||
<span class="float-right">Checkin Time : <%= @booking.checkin_at.utc.getlocal.strftime("%I:%M %p") %></span>
|
||||
</div>
|
||||
|
||||
<% elsif @status_sale == 'sale' %>
|
||||
<div><strong id="order-title">INVOICE DETAILS </strong> | Table <%= @room.name rescue "" %></div>
|
||||
<div><strong id="order-title">INVOICE DETAILS </strong> | Table <%= @room.name rescue "" %>
|
||||
<span class="float-right">Checkin Time : <%= @booking.checkin_at.utc.getlocal.strftime("%I:%M %p") %></span>
|
||||
</div>
|
||||
|
||||
<% end %>
|
||||
|
||||
</div>
|
||||
@@ -140,22 +146,22 @@
|
||||
</span>
|
||||
</div>
|
||||
<div class="col-lg-6 col-md-6 col-sm-6 text-right">
|
||||
Date: <span id="receipt_date"><%= @obj_sale.created_at.utc.getlocal.strftime("%d/%m/%Y - %I:%M %p") rescue '-'%></span>
|
||||
Date: <span id="receipt_date"><%= @date.utc.getlocal.strftime("%d/%m/%Y - %I:%M %p") rescue '-'%></span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-title row customer_detail p-l-5 p-r-5" >
|
||||
<div class="col-lg-6 col-md-6 col-sm-6">
|
||||
<% if @status_sale == 'sale' %>
|
||||
<p class="hidden customer-id"><%= @obj_sale_sale.customer_id rescue '' %></p>
|
||||
Customer : <%= @obj_sale_sale.customer.name rescue '-' %>
|
||||
Customer : <%= @obj_sale.customer.name rescue '-' %>
|
||||
<%else%>
|
||||
<p class="hidden customer-id"><%= @customer.customer_id rescue "" %></p>
|
||||
<p class="hidden customer-id"><%= @obj_order.customer_id rescue "-" %></p>
|
||||
Customer : <%= @customer.name rescue "-" %>
|
||||
<%end%>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div id="order-detail-slimscroll" data-height="160">
|
||||
<div id="order-detail-slimscroll" data-height="<%= @status_sale=="sale" ? 240 : 160%>">
|
||||
<div class="card-text order-info">
|
||||
<table class="table table-striped" id="order-items-table">
|
||||
<thead>
|
||||
@@ -312,23 +318,25 @@
|
||||
<% if @room.bookings.length >= 1 %>
|
||||
<% if @status_order == 'order' && @status_sale != 'sale' %>
|
||||
<!-- <button type="button" class="btn bg-blue btn-block" >Add Order</button> -->
|
||||
<button type="button" id="customer" class="btn bg-blue btn-block" disabled>Customer</button>
|
||||
<button type="button" class="btn bg-blue btn-block" disabled >Edit</button>
|
||||
<button type="button" id="discount" class="btn bg-blue btn-block" disabled >Discount</button>
|
||||
<button type="button" id="other-charges" class="btn bg-blue btn-block" disabled>Charges</button>
|
||||
<!-- <button type="button" id="customer" class="btn bg-blue btn-block" disabled>Customer</button> -->
|
||||
<!-- <button type="button" class="btn bg-blue btn-block" disabled >Edit</button> -->
|
||||
<!-- <button type="button" id="discount" class="btn bg-blue btn-block" disabled >Discount</button> -->
|
||||
<!-- <button type="button" id="other-charges" class="btn bg-blue btn-block" disabled>Charges</button> -->
|
||||
<button type="button" class="btn bg-blue btn-block" id='move'>Move</button>
|
||||
<button type="button" id="request_bills" class="btn bg-blue btn-block">Req.Bill</button>
|
||||
<button type="button" id="first_bill" class="btn bg-blue btn-block" disabled>First Bill</button>
|
||||
<button type="button" id="pay" class="btn bg-blue btn-block" disabled>Pay</button>
|
||||
<button type="button" class="btn bg-blue btn-block" disabled=""> Void </button>
|
||||
<!-- <button type="button" id="first_bill" class="btn bg-blue btn-block" disabled>First Bill</button> -->
|
||||
<!-- <button type="button" id="pay" class="btn bg-blue btn-block" disabled>Pay</button> -->
|
||||
<!-- <button type="button" class="btn bg-blue btn-block" disabled=""> Void </button> -->
|
||||
<% else %>
|
||||
<!-- <button type="button" class="btn bg-blue btn-block" disabled>Add Order</button> -->
|
||||
<button type="button" id="customer" class="btn bg-blue btn-block" >Customer</button>
|
||||
<button type="button" class="btn bg-blue btn-block" id='edit'>Edit</button>
|
||||
<button type="button" id="discount" class="btn bg-blue btn-block" >Discount</button>
|
||||
<button type="button" id="other-charges" class="btn bg-blue btn-block" >Charges</button>
|
||||
<button type="button" class="btn bg-blue btn-block" id='move' disabled="">Move</button>
|
||||
<button type="button" id="request_bills" class="btn bg-blue btn-block" disabled> Req.Bill</button>
|
||||
<button type="button" id="commissions" class="btn btn-block bg-blue waves-effect">Commissions</button>
|
||||
<button type="button" id="in_duties" class="btn btn-block bg-blue waves-effect">In Duties</button>
|
||||
<!-- <button type="button" class="btn bg-blue btn-block" id='move' disabled="">Move</button> -->
|
||||
<!-- <button type="button" id="request_bills" class="btn bg-blue btn-block" disabled> Req.Bill</button> -->
|
||||
<button type="button" id="first_bill" class="btn bg-blue btn-block">First Bill</button>
|
||||
<button type="button" id="pay" class="btn bg-blue btn-block">Pay</button>
|
||||
<button type="button" id="void" class="btn bg-blue btn-block" > Void </button>
|
||||
@@ -659,6 +667,17 @@ $('#add_invoice').on('click',function(){
|
||||
}
|
||||
});
|
||||
|
||||
$('#commissions').on('click', function () {
|
||||
var dining_id = "<%= @room.id %>"
|
||||
var sale_id = "<%= @obj_sale.sale_id rescue "" %>"
|
||||
window.location.href = '/origami/table/' + dining_id + "/sale/" + sale_id + "/load_commissioners";
|
||||
});
|
||||
|
||||
$('#in_duties').on('click', function () {
|
||||
var dining_id = "<%= @room.id %>"
|
||||
window.location.href = '/origami/assign_in_duty/'+ dining_id;
|
||||
});
|
||||
|
||||
// Ordering
|
||||
$('#add_order').on('click', function () {
|
||||
var dining_id = "<%= @room.id %>"
|
||||
|
||||
Reference in New Issue
Block a user