Merge branch 'master' of bitbucket.org:code2lab/sxrestaurant into doemal_ordering
This commit is contained in:
@@ -211,7 +211,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="card">
|
<!-- <div class="card">
|
||||||
<div class="card-header">
|
<div class="card-header">
|
||||||
<div><strong id="order-title">Promo Code</strong></div>
|
<div><strong id="order-title">Promo Code</strong></div>
|
||||||
</div>
|
</div>
|
||||||
@@ -233,7 +233,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div> -->
|
||||||
</div>
|
</div>
|
||||||
<!-- Column Three -->
|
<!-- Column Three -->
|
||||||
<div class="col-lg-1 col-md-1 col-sm-1">
|
<div class="col-lg-1 col-md-1 col-sm-1">
|
||||||
@@ -432,6 +432,9 @@ var cashier_type = "<%= @cashier_type %>";
|
|||||||
// Pay Discount for Payment
|
// Pay Discount for Payment
|
||||||
$("#pay-discount").on('click', function(e){
|
$("#pay-discount").on('click', function(e){
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
|
if($('#pay-discount').is(":visible")) {
|
||||||
|
$('#pay-discount').prop("disabled",true);
|
||||||
|
}
|
||||||
$("#loading_wrapper").show();
|
$("#loading_wrapper").show();
|
||||||
var sale_id = $('#sale-id').text();
|
var sale_id = $('#sale-id').text();
|
||||||
var discount_items = JSON.stringify(get_discount_item_rows());
|
var discount_items = JSON.stringify(get_discount_item_rows());
|
||||||
|
|||||||
@@ -869,6 +869,10 @@
|
|||||||
|
|
||||||
// Bill Request
|
// Bill Request
|
||||||
$('#request_bills').click(function () {
|
$('#request_bills').click(function () {
|
||||||
|
if($('#request_bills').is(":visible")) {
|
||||||
|
$('#request_bills').prop("disabled",true);
|
||||||
|
}
|
||||||
|
|
||||||
var order_id = $('#save_order_id').attr('data-order');
|
var order_id = $('#save_order_id').attr('data-order');
|
||||||
var ajax_url = "/origami/" + order_id + "/request_bills";
|
var ajax_url = "/origami/" + order_id + "/request_bills";
|
||||||
$.ajax({
|
$.ajax({
|
||||||
@@ -893,8 +897,11 @@
|
|||||||
});
|
});
|
||||||
|
|
||||||
$('#move').on('click', function () {
|
$('#move').on('click', function () {
|
||||||
var dining_id = "<%= @dining.id %>";
|
if($('#move').is(":visible")) {
|
||||||
window.location.href = '/origami/table/' + dining_id + "/movetable";
|
$('#move').prop("disabled",true);
|
||||||
|
}
|
||||||
|
var dining_id = "<%= @dining.id %>";
|
||||||
|
window.location.href = '/origami/table/' + dining_id + "/movetable";
|
||||||
})
|
})
|
||||||
|
|
||||||
$('#back').on('click', function () {
|
$('#back').on('click', function () {
|
||||||
|
|||||||
@@ -308,6 +308,9 @@ var cashier_type = "<%= @cashier_type %>";
|
|||||||
// Calculate Other Charges for Payment
|
// Calculate Other Charges for Payment
|
||||||
$("#charge_other").on('click', function(e){
|
$("#charge_other").on('click', function(e){
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
|
if($('#charge_other').is(":visible")) {
|
||||||
|
$('#charge_other').prop("disabled",true);
|
||||||
|
}
|
||||||
var sale_id = $('#sale-id').text();
|
var sale_id = $('#sale-id').text();
|
||||||
var sub_total = $('#order-sub-total').text();
|
var sub_total = $('#order-sub-total').text();
|
||||||
var other_charges_items = JSON.stringify(get_other_item_rows());
|
var other_charges_items = JSON.stringify(get_other_item_rows());
|
||||||
|
|||||||
@@ -1050,6 +1050,14 @@ var pdf_view = '<%=@pdf_view%>';
|
|||||||
});
|
});
|
||||||
|
|
||||||
function print_receipt() {
|
function print_receipt() {
|
||||||
|
if($('.print_receipt').is(":visible")) {
|
||||||
|
$('.print_receipt').prop("disabled",true);
|
||||||
|
}
|
||||||
|
|
||||||
|
if($('#pay').is(":visible")) {
|
||||||
|
$('#pay').prop("disabled",true);
|
||||||
|
}
|
||||||
|
|
||||||
var sale_id = $('#sale_id').text();
|
var sale_id = $('#sale_id').text();
|
||||||
var filename = $("#filename").val();
|
var filename = $("#filename").val();
|
||||||
var printer_name = $("#printer_name").val();
|
var printer_name = $("#printer_name").val();
|
||||||
|
|||||||
@@ -870,6 +870,9 @@ $('#pay').on('click',function() {
|
|||||||
});
|
});
|
||||||
// Bill Request
|
// Bill Request
|
||||||
$('#request_bills').click(function() {
|
$('#request_bills').click(function() {
|
||||||
|
if($('#request_bills').is(":visible")) {
|
||||||
|
$('#request_bills').prop("disabled",true);
|
||||||
|
}
|
||||||
var order_id = $('#save_order_id').attr('data-order');
|
var order_id = $('#save_order_id').attr('data-order');
|
||||||
var ajax_url = "/origami/" + order_id + "/request_bills";
|
var ajax_url = "/origami/" + order_id + "/request_bills";
|
||||||
$.ajax({
|
$.ajax({
|
||||||
@@ -894,6 +897,9 @@ $('#split_bills').click(function(){
|
|||||||
});
|
});
|
||||||
|
|
||||||
$('#move').on('click',function(){
|
$('#move').on('click',function(){
|
||||||
|
if($('#move').is(":visible")) {
|
||||||
|
$('#move').prop("disabled",true);
|
||||||
|
}
|
||||||
var dining_id = "<%= @room.id %>"
|
var dining_id = "<%= @room.id %>"
|
||||||
window.location.href = '/origami/table/'+ dining_id + "/moveroom";
|
window.location.href = '/origami/table/'+ dining_id + "/moveroom";
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -32,8 +32,6 @@
|
|||||||
</div>
|
</div>
|
||||||
<%= link_to t("views.btn.new"),new_settings_menu_path,:class => 'btn btn-primary btn-lg float-right waves-effect"' %>
|
<%= link_to t("views.btn.new"),new_settings_menu_path,:class => 'btn btn-primary btn-lg float-right waves-effect"' %>
|
||||||
|
|
||||||
<%= link_to "Export", settings_menus_path(format: "xlsx"),:class => 'btn btn-info btn-lg waves-effect float-right m-r-10' %>
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div class="card">
|
<div class="card">
|
||||||
<table class="table table-striped">
|
<table class="table table-striped">
|
||||||
|
|||||||
Reference in New Issue
Block a user