still nfc
This commit is contained in:
@@ -131,10 +131,10 @@
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<%= f.input :nrc_no, :class => "form-control nrc_no" %>
|
||||
<%= f.input :nrc_no, :label => "NRC No",:class => "form-control nrc_no" %>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<%= f.input :company, :class => "form-control col-md-6 company",:required => true%>
|
||||
<%= f.input :company, :class => "form-control col-md-6 company"%>
|
||||
|
||||
<% flash.each do |name, msg| %>
|
||||
<% str="[\"#{msg['company']}\"]"
|
||||
|
||||
@@ -519,7 +519,7 @@ $(document).ready(function(){
|
||||
}
|
||||
|
||||
$.confirm({
|
||||
title: 'Infomation!',
|
||||
title: result.title,
|
||||
content: result.status,
|
||||
columnClass: 'small',
|
||||
type: type,
|
||||
@@ -542,18 +542,14 @@ $(document).ready(function(){
|
||||
}
|
||||
});
|
||||
}else{
|
||||
$.confirm({
|
||||
title: 'Alert !',
|
||||
content: 'Please Select Account',
|
||||
type: 'red',
|
||||
$.alert({
|
||||
title: 'Alert!',
|
||||
content: 'Please Select Account',
|
||||
type: 'red',
|
||||
typeAnimated: true,
|
||||
buttons: {
|
||||
confirm: {
|
||||
text: 'Ok',
|
||||
btnClass: 'btn-danger',
|
||||
}
|
||||
}
|
||||
});
|
||||
btnClass: 'btn-danger',
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
});//end member discount
|
||||
|
||||
@@ -105,9 +105,10 @@
|
||||
</div>
|
||||
<div class="col-lg-2 col-md-2 col-sm-2">
|
||||
<button id="refreshbutton" type="button" class="btn btn-block" style="border-radius:5px;color:#fff;background-color:red;"> Refresh off </button>
|
||||
<button id="cash_in" type="button" class="btn btn-block btn-primary" style="border-radius:5px;color:#fff;"> Cash In </button>
|
||||
<button id="cash_out" type="button" class="btn btn-block btn-primary" style="border-radius:5px;color:#fff;"> Cash Out </button>
|
||||
<button id="close_cashier" type="button" class="btn btn-block btn-primary" style="border-radius:5px;color:#fff;"> Close Cashier </button>
|
||||
<button id="cash_in" type="button" class="btn btn-block btn-primary"> Cash In </button>
|
||||
<button id="cash_out" type="button" class="btn btn-block btn-primary"> Cash Out </button>
|
||||
<button id="sale_summary" type="button" class="btn btn-block btn-primary">Sale Sammary</button>
|
||||
<button id="close_cashier" type="button" class="btn btn-block btn-primary"> Close Cashier </button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- Column One -->
|
||||
@@ -116,20 +117,28 @@ $(document).ready(function(){
|
||||
$(".tables").on('click', function(){
|
||||
var dining_id = $(this).attr("data-id");
|
||||
window.location.href = '/origami/table/' + dining_id;
|
||||
})
|
||||
});
|
||||
|
||||
$(".sales").on('click',function(){
|
||||
var sale_id = $(this).attr("data-id");
|
||||
window.location.href = '/origami/sale/' + sale_id;
|
||||
})
|
||||
});
|
||||
|
||||
$(".rooms").on('click', function(){
|
||||
var dining_id = $(this).attr("data-id");
|
||||
window.location.href = '/origami/room/' + dining_id;
|
||||
})
|
||||
});
|
||||
|
||||
$(".orders").on('click',function(){
|
||||
var order_id = $(this).attr("data-id");
|
||||
window.location.href = '/origami/order/' + order_id;
|
||||
});
|
||||
|
||||
$('#sale_summary').on('click',function(){
|
||||
window.location.href = '/origami/shift/sale_summary';
|
||||
})
|
||||
});
|
||||
|
||||
$(function() {
|
||||
var timer;
|
||||
|
||||
|
||||
@@ -15,13 +15,13 @@
|
||||
</ul>
|
||||
<!-- Nav tabs - End -->
|
||||
|
||||
<div class="tab-content" style="max-height:670px; overflow:auto">
|
||||
<div class="tab-content" style="max-height:570px; overflow:auto">
|
||||
<!--- Panel 0 - Completed Orders -->
|
||||
|
||||
|
||||
<!--- Panel 1 - Table Orders -->
|
||||
<div class="tab-pane " id="tables" role="tabpanel">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;min-height:500px; max-height:500px; overflow-x:scroll">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @tables.each do |table| %>
|
||||
<% if table.status == 'occupied' %>
|
||||
<div class="card tables red text-white" data-id="<%= table.id %>" data-name="<%= table.name %>">
|
||||
@@ -42,7 +42,7 @@
|
||||
|
||||
<!--- Panel 2 - Room Orders -->
|
||||
<div class="tab-pane active" id="rooms" role="tabpanel">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;min-height:500px; max-height:500px; overflow-x:scroll" >
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;" >
|
||||
<% @rooms.each do |room| %>
|
||||
<% if room.status == 'occupied' %>
|
||||
<div class="card rooms red text-white" data-id="<%= room.id %>" data-name="<%= room.name %>">
|
||||
@@ -95,7 +95,7 @@
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="card-text" style="min-height:500px; max-height:500px; overflow-x:scroll" >
|
||||
<div class="card-text" style="min-height:500px; max-height:500px; overflow:auto" >
|
||||
<table class="table table-striped" id="order-items-table">
|
||||
<thead>
|
||||
<tr>
|
||||
|
||||
@@ -15,13 +15,13 @@
|
||||
</ul>
|
||||
<!-- Nav tabs - End -->
|
||||
|
||||
<div class="tab-content" style="max-height:670px; overflow:auto">
|
||||
<div class="tab-content" style="max-height:570px; overflow:auto">
|
||||
<!--- Panel 0 - Completed Orders -->
|
||||
|
||||
|
||||
<!--- Panel 1 - Table Orders -->
|
||||
<div class="tab-pane active" id="tables" role="tabpanel">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;min-height:500px; max-height:500px; overflow-x:scroll" >
|
||||
<div class="card-columns" style="padding-top:10px;" >
|
||||
<% @tables.each do |table| %>
|
||||
<% if table.status == 'occupied' %>
|
||||
<div class="card tables red text-white" data-id="<%= table.id %>" data-name="<%= table.name %>">
|
||||
@@ -42,7 +42,7 @@
|
||||
|
||||
<!--- Panel 2 - Room Orders -->
|
||||
<div class="tab-pane" id="rooms" role="tabpanel">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;min-height:500px; max-height:500px; overflow-x:scroll" >
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;" >
|
||||
<% @rooms.each do |room| %>
|
||||
<% if room.status == 'occupied' %>
|
||||
<div class="card rooms red text-white" data-id="<%= room.id %>" data-name="<%= room.name %>">
|
||||
@@ -95,7 +95,7 @@
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="card-text" style="min-height:500px; max-height:500px; overflow-x:scroll" >
|
||||
<div class="card-text" style="min-height:500px; max-height:500px; overflow:auto" >
|
||||
<table class="table table-striped" id="order-items-table">
|
||||
<thead>
|
||||
<tr>
|
||||
|
||||
@@ -175,11 +175,9 @@
|
||||
<td class="item-attr"><strong id="order-sub-total"><%= sub_total %></strong></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<%if @selected_item.discount_type == 'member_discount'%>
|
||||
<td class="charges-name"><strong>Member Discount:</strong></td>
|
||||
<%else%>
|
||||
|
||||
<td class="charges-name"><strong>Discount:</strong></td>
|
||||
<%end%>
|
||||
|
||||
<td class="item-attr"><strong id="order-discount">(<%=@selected_item.total_discount rescue 0%>)</strong></td>
|
||||
</tr>
|
||||
<tr class="rebate_amount"></tr>
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
|
||||
<div id="loading_wrapper" style="display:none;">
|
||||
<div id="loading"></div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-lg-6 col-md-6 col-sm-3">
|
||||
<div class="card" >
|
||||
@@ -104,6 +106,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-5 col-md-5 col-sm-3">
|
||||
<div class="row" style="margin-top:10px;">
|
||||
<div class="col-md-8"><strong style="font-size:18px;">Amount Due</strong></div>
|
||||
@@ -258,6 +261,8 @@
|
||||
<button type="button" class="btn btn-primary btn-block"> FOC </button>
|
||||
<button type="button" class="btn btn-primary btn-block" id="void"> Void </button>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<script>
|
||||
@@ -344,15 +349,19 @@ $( document ).ready(function() {
|
||||
|
||||
$('#pay').click(function() {
|
||||
$('#pay').text("Processing, Please wait!")
|
||||
|
||||
$( "#loading_wrapper" ).show();
|
||||
|
||||
if($('#balance').text() > 0){
|
||||
alert(" Insufficient Amount!")
|
||||
$( "#loading_wrapper" ).hide();
|
||||
}else{
|
||||
// payment
|
||||
var cash = $('#cash').text();
|
||||
var credit = $('#credit').text();
|
||||
var card = $('#card').text();
|
||||
var sale_id = $('#sale_id').text();
|
||||
|
||||
|
||||
$.ajax({type: "POST",
|
||||
url: "<%= origami_payment_cash_path %>",
|
||||
data: "cash="+ cash + "&sale_id=" + sale_id,
|
||||
@@ -364,7 +373,7 @@ $( document ).ready(function() {
|
||||
else{
|
||||
var msg = '';
|
||||
}
|
||||
|
||||
$( "#loading_wrapper" ).hide();
|
||||
if($('#balance').text() < 0){
|
||||
$.confirm({
|
||||
title: 'Infomation!',
|
||||
@@ -434,4 +443,4 @@ function update_balance(){
|
||||
$('#balance').text(result.toFixed(2));
|
||||
}
|
||||
|
||||
</script>
|
||||
</script>
|
||||
@@ -203,7 +203,7 @@
|
||||
<td class="item-attr"><strong id="order-sub-total"><%= sub_total %></strong></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<%if @obj.discount_type == 'member_discount'%>
|
||||
<%if @obj != nil && @status_sale == 'sale' && @obj.discount_type == 'member_discount'%>
|
||||
<td class="charges-name"><strong>Member Discount:</strong></td>
|
||||
<%else%>
|
||||
<td class="charges-name"><strong>Discount:</strong></td>
|
||||
|
||||
@@ -110,7 +110,7 @@ $(document).on('focusout', '.float-value', function(event){
|
||||
|
||||
$('#open_cashier').on('click',function(){
|
||||
var cashier_terminal = $('#cashier_terminal').val();
|
||||
var amount = $('#total').text();
|
||||
var amount = $('#total').text()||0;
|
||||
$.ajax({type: "POST",
|
||||
url: "<%= origami_shifts_path %>",
|
||||
data: "opening_balance=" + amount + "&cashier_terminal="+ cashier_terminal,
|
||||
|
||||
Reference in New Issue
Block a user