wt updated
This commit is contained in:
BIN
app/assets/images/online_order_icon.png
Normal file
BIN
app/assets/images/online_order_icon.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 376 B |
BIN
app/assets/images/user_icon.png
Normal file
BIN
app/assets/images/user_icon.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 819 B |
@@ -269,3 +269,54 @@ i.logout_icon{
|
|||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
}
|
}
|
||||||
/*customer modal UI */
|
/*customer modal UI */
|
||||||
|
|
||||||
|
@media screen and (max-width: 785px) {
|
||||||
|
section.content{
|
||||||
|
margin: 80px 15px 0 225px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mbl_view{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.navbar-brand-txt{
|
||||||
|
margin-top: -15px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle_mbl {
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle_mbl img{
|
||||||
|
width: 24px;
|
||||||
|
margin-bottom: 14px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle_mbl a:hover, a:focus{
|
||||||
|
background-color: unset;
|
||||||
|
}
|
||||||
|
|
||||||
|
.col-mbl-view{
|
||||||
|
width: 50%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.info-box .icon{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mbl_product_div{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sidebar .menu{
|
||||||
|
top: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.page-header{
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ls-closed .bars:after, .ls-closed .bars:before{
|
||||||
|
top: 14px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@@ -121,3 +121,54 @@ i.logout_icon{
|
|||||||
.table-width{
|
.table-width{
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@media screen and (max-width: 785px) {
|
||||||
|
section.content{
|
||||||
|
margin: 80px 15px 0 225px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mbl_view{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.navbar-brand-txt{
|
||||||
|
margin-top: -15px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle_mbl {
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle_mbl img{
|
||||||
|
width: 24px;
|
||||||
|
margin-bottom: 14px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle_mbl a:hover, a:focus{
|
||||||
|
background-color: unset;
|
||||||
|
}
|
||||||
|
|
||||||
|
.col-mbl-view{
|
||||||
|
width: 50%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.info-box .icon{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mbl_product_div{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sidebar .menu{
|
||||||
|
top: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.page-header{
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ls-closed .bars:after, .ls-closed .bars:before{
|
||||||
|
top: 14px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@@ -130,3 +130,54 @@ i.logout_icon{
|
|||||||
#setting{ display: none;}
|
#setting{ display: none;}
|
||||||
.menu-up{ display: none;}
|
.menu-up{ display: none;}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@media screen and (max-width: 785px) {
|
||||||
|
section.content{
|
||||||
|
margin: 80px 15px 0 225px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mbl_view{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.navbar-brand-txt{
|
||||||
|
margin-top: -15px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle_mbl {
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle_mbl img{
|
||||||
|
width: 24px;
|
||||||
|
margin-bottom: 14px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle_mbl a:hover, a:focus{
|
||||||
|
background-color: unset;
|
||||||
|
}
|
||||||
|
|
||||||
|
.col-mbl-view{
|
||||||
|
width: 50%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.info-box .icon{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mbl_product_div{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sidebar .menu{
|
||||||
|
top: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.page-header{
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ls-closed .bars:after, .ls-closed .bars:before{
|
||||||
|
top: 14px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@@ -280,3 +280,54 @@ i.logout_icon{
|
|||||||
position: relative;
|
position: relative;
|
||||||
top: 5px;
|
top: 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@media screen and (max-width: 785px) {
|
||||||
|
section.content{
|
||||||
|
margin: 80px 15px 0 225px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mbl_view{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.navbar-brand-txt{
|
||||||
|
margin-top: -15px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle_mbl {
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle_mbl img{
|
||||||
|
width: 24px;
|
||||||
|
margin-bottom: 14px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle_mbl a:hover, a:focus{
|
||||||
|
background-color: unset;
|
||||||
|
}
|
||||||
|
|
||||||
|
.col-mbl-view{
|
||||||
|
width: 50%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.info-box .icon{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mbl_product_div{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sidebar .menu{
|
||||||
|
top: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.page-header{
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ls-closed .bars:after, .ls-closed .bars:before{
|
||||||
|
top: 14px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@@ -659,3 +659,54 @@ nav.pagination .page a:hover,
|
|||||||
width: 130px;
|
width: 130px;
|
||||||
height: 50px;
|
height: 50px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@media screen and (max-width: 785px) {
|
||||||
|
section.content{
|
||||||
|
margin: 80px 15px 0 225px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mbl_view{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.navbar-brand-txt{
|
||||||
|
margin-top: -15px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle_mbl {
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle_mbl img{
|
||||||
|
width: 24px;
|
||||||
|
margin-bottom: 14px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.toggle_mbl a:hover, a:focus{
|
||||||
|
background-color: unset;
|
||||||
|
}
|
||||||
|
|
||||||
|
.col-mbl-view{
|
||||||
|
width: 50%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.info-box .icon{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mbl_product_div{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sidebar .menu{
|
||||||
|
top: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.page-header{
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ls-closed .bars:after, .ls-closed .bars:before{
|
||||||
|
top: 14px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@@ -879,7 +879,6 @@ def self.daily_sales_list(from,to)
|
|||||||
|
|
||||||
total_sale.each do |sale|
|
total_sale.each do |sale|
|
||||||
grand_total = sale.grand_total
|
grand_total = sale.grand_total
|
||||||
amount_received = sale.amount_received
|
|
||||||
old_grand_total = sale.old_grand_total
|
old_grand_total = sale.old_grand_total
|
||||||
total_discount = sale.total_discount
|
total_discount = sale.total_discount
|
||||||
void_amount = sale.void_amount
|
void_amount = sale.void_amount
|
||||||
@@ -952,7 +951,6 @@ def self.get_by_shiftsales(from,to,shift)
|
|||||||
end
|
end
|
||||||
|
|
||||||
shift_sale_data[shift_sale.id] = {
|
shift_sale_data[shift_sale.id] = {
|
||||||
:shift_id => shift_sale.id,
|
|
||||||
:cashier_terminal_name => shift_sale.cashier_terminal.name,
|
:cashier_terminal_name => shift_sale.cashier_terminal.name,
|
||||||
:employee_name => shift_sale.employee.name,
|
:employee_name => shift_sale.employee.name,
|
||||||
:shift_started_at => shift_sale.shift_started_at,
|
:shift_started_at => shift_sale.shift_started_at,
|
||||||
@@ -1127,15 +1125,6 @@ def self.get_by_shift_items(shift_sale_range, shift, from, to, status,type,accou
|
|||||||
return query,other_charges, product, discount_query , total_cash_amount , total_card_amount , total_credit_amount , total_foc_amount , total_grand_total , change_amount
|
return query,other_charges, product, discount_query , total_cash_amount , total_card_amount , total_credit_amount , total_foc_amount , total_grand_total , change_amount
|
||||||
end
|
end
|
||||||
|
|
||||||
def self.get_shift_sale_items(sh_id)
|
|
||||||
query = Sale.select("sales.shift_sale_id as shift_sale_id, i.account_id as account_id, acc.title as account_name, i.item_instance_code as item_code, i.menu_category_name, i.menu_category_code as menu_category_id, i.product_name as product_name, i.unit_price, i.price as price, i.qty as qty, SUM(i.qty) as total_item, SUM(i.qty * i.unit_price) as grand_total, i.status as status_type, i.remark as remark")
|
|
||||||
.joins("JOIN sale_items i on i.sale_id = sales.sale_id")
|
|
||||||
.joins("JOIN accounts acc on acc.id = i.account_id")
|
|
||||||
.where("sales.shift_sale_id=?", sh_id)
|
|
||||||
.group("acc.title,i.account_id,i.menu_category_code,i.item_instance_code,i.product_name,i.unit_price")
|
|
||||||
.order("acc.title desc, i.account_id desc, i.menu_category_code desc, i.unit_price asc")
|
|
||||||
end
|
|
||||||
|
|
||||||
def self.get_product_sale()
|
def self.get_product_sale()
|
||||||
query = Sale.select("i.account_id as account_id, " +
|
query = Sale.select("i.account_id as account_id, " +
|
||||||
"SUM(i.qty * i.unit_price) as grand_total,SUM(i.qty) as total_item," +
|
"SUM(i.qty * i.unit_price) as grand_total,SUM(i.qty) as total_item," +
|
||||||
|
|||||||
@@ -17,7 +17,7 @@
|
|||||||
%>
|
%>
|
||||||
<!-- Widgets -->
|
<!-- Widgets -->
|
||||||
<div class="row clearfix">
|
<div class="row clearfix">
|
||||||
<div class="col-lg-3 col-md-3 col-sm-6 col-xs-12">
|
<div class="col-lg-3 col-md-3 col-sm-6 col-xs-12 col-mbl-view">
|
||||||
<div class="info-box bg-cyan hover-expand-effect">
|
<div class="info-box bg-cyan hover-expand-effect">
|
||||||
<div class="icon">
|
<div class="icon">
|
||||||
<i class="material-icons">help</i>
|
<i class="material-icons">help</i>
|
||||||
@@ -30,7 +30,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-lg-3 col-md-3 col-sm-6 col-xs-12">
|
<div class="col-lg-3 col-md-3 col-sm-6 col-xs-12 col-mbl-view">
|
||||||
<div class="info-box bg-pink hover-expand-effect">
|
<div class="info-box bg-pink hover-expand-effect">
|
||||||
<div class="icon">
|
<div class="icon">
|
||||||
<i class="material-icons">attach_money</i>
|
<i class="material-icons">attach_money</i>
|
||||||
@@ -44,7 +44,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="col-lg-3 col-md-3 col-sm-6 col-xs-12">
|
<div class="col-lg-3 col-md-3 col-sm-6 col-xs-12 col-mbl-view">
|
||||||
<div class="info-box bg-light-green hover-expand-effect">
|
<div class="info-box bg-light-green hover-expand-effect">
|
||||||
<div class="icon">
|
<div class="icon">
|
||||||
<i class="material-icons">person_add</i>
|
<i class="material-icons">person_add</i>
|
||||||
@@ -57,7 +57,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-lg-3 col-md-3 col-sm-6 col-xs-12">
|
<div class="col-lg-3 col-md-3 col-sm-6 col-xs-12 col-mbl-view">
|
||||||
<div class="info-box bg-orange hover-expand-effect">
|
<div class="info-box bg-orange hover-expand-effect">
|
||||||
<div class="icon">
|
<div class="icon">
|
||||||
<i class="material-icons">credit_card</i>
|
<i class="material-icons">credit_card</i>
|
||||||
@@ -99,27 +99,27 @@
|
|||||||
to_time = ''
|
to_time = ''
|
||||||
end
|
end
|
||||||
%>
|
%>
|
||||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
<div class="col-lg-3 col-md-3 col-sm-3 col-mbl-view">
|
||||||
<label class="font-14"><%= t("views.right_panel.detail.from") %></label>
|
<label class="font-14"><%= t("views.right_panel.detail.from") %></label>
|
||||||
<input data-behaviour='datepicker' class="form-control datepicker" name="from" id="from" type="text" value="<%= from_date %>" placeholder="From date" style="height: 35px;">
|
<input data-behaviour='datepicker' class="form-control datepicker" name="from" id="from" type="text" value="<%= from_date %>" placeholder="From date" style="height: 35px;">
|
||||||
<span id="fromErr" style="color:red;"></span>
|
<span id="fromErr" style="color:red;"></span>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-lg-3 col-md-3 col-sm-3">
|
<div class="col-lg-3 col-md-3 col-sm-3 col-mbl-view">
|
||||||
<label class="font-14"><%= t("views.right_panel.detail.to") %></label>
|
<label class="font-14"><%= t("views.right_panel.detail.to") %></label>
|
||||||
<input data-behaviour='datepicker' class="form-control datepicker" name="to" id="to" type="text" value="<%= to_date %>" placeholder="To date" style="height: 35px;">
|
<input data-behaviour='datepicker' class="form-control datepicker" name="to" id="to" type="text" value="<%= to_date %>" placeholder="To date" style="height: 35px;">
|
||||||
<span id="toErr" style="color:red;"></span>
|
<span id="toErr" style="color:red;"></span>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-lg-2 col-md-2 col-sm-2">
|
<div class="col-lg-2 col-md-2 col-sm-2 col-mbl-view">
|
||||||
<label class="font-14"><%= t("views.right_panel.detail.from_time") %></label>
|
<label class="font-14"><%= t("views.right_panel.detail.from_time") %></label>
|
||||||
<input data-behaviour='timepicker' class="form-control timepicker" name="from_time" id="from_time" type="text" value="<%= from_time %>" placeholder="From Time" style="height: 35px;">
|
<input data-behaviour='timepicker' class="form-control timepicker" name="from_time" id="from_time" type="text" value="<%= from_time %>" placeholder="From Time" style="height: 35px;">
|
||||||
<span id="from_timeErr" style="color:red;"></span>
|
<span id="from_timeErr" style="color:red;"></span>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-lg-2 col-md-2 col-sm-2">
|
<div class="col-lg-2 col-md-2 col-sm-2 col-mbl-view">
|
||||||
<label class="font-14"><%= t("views.right_panel.detail.to_time") %></label>
|
<label class="font-14"><%= t("views.right_panel.detail.to_time") %></label>
|
||||||
<input data-behaviour='timepicker' class="form-control timepicker" name="to_time" id="to_time" type="text" value="<%= to_time %>" placeholder="To time" style="height: 35px;">
|
<input data-behaviour='timepicker' class="form-control timepicker" name="to_time" id="to_time" type="text" value="<%= to_time %>" placeholder="To time" style="height: 35px;">
|
||||||
<span id="to_timeErr" style="color:red;"></span>
|
<span id="to_timeErr" style="color:red;"></span>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-lg-2 col-md-2 col-sm-2">
|
<div class="col-lg-2 col-md-2 col-sm-2 toggle_mbl">
|
||||||
<label></label><br>
|
<label></label><br>
|
||||||
<input type="button" value="Generate" class='btn btn-primary btn_generate'>
|
<input type="button" value="Generate" class='btn btn-primary btn_generate'>
|
||||||
</div>
|
</div>
|
||||||
@@ -131,8 +131,10 @@
|
|||||||
<div class="row">
|
<div class="row">
|
||||||
<% if current_user.role == 'administrator' || current_user.role == 'manager' || current_user.role == 'account' %>
|
<% if current_user.role == 'administrator' || current_user.role == 'manager' || current_user.role == 'account' %>
|
||||||
<div class="col-xs-8 col-sm-8 col-md-8 col-lg-8">
|
<div class="col-xs-8 col-sm-8 col-md-8 col-lg-8">
|
||||||
|
<% isMobile = request.user_agent %>
|
||||||
|
<% if !isMobile.include? "Mobile" %>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-xs-12 col-sm-12 col-md-6 col-lg-6">
|
<div class="col-xs-12 col-sm-12 col-md-6 col-lg-6 ">
|
||||||
<div class="card">
|
<div class="card">
|
||||||
<div class="body">
|
<div class="body">
|
||||||
<h4><i class="material-icons md-24">dashboard</i><%= (t :top) + " " + (t :products) %></h4>
|
<h4><i class="material-icons md-24">dashboard</i><%= (t :top) + " " + (t :products) %></h4>
|
||||||
@@ -141,7 +143,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-xs-12 col-sm-12 col-md-6 col-lg-6">
|
<div class="col-xs-12 col-sm-12 col-md-6 col-lg-6 ">
|
||||||
<div class="card">
|
<div class="card">
|
||||||
<div class="body">
|
<div class="body">
|
||||||
<h4><i class="material-icons md-24">dashboard</i><%= (t :bottom) + " " + (t :products) %></h4>
|
<h4><i class="material-icons md-24">dashboard</i><%= (t :bottom) + " " + (t :products) %></h4>
|
||||||
@@ -151,6 +153,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<% end %>
|
||||||
<!-- <div class="row">
|
<!-- <div class="row">
|
||||||
<div class="col-xs-12 col-sm-12 col-md-12 col-lg-12">
|
<div class="col-xs-12 col-sm-12 col-md-12 col-lg-12">
|
||||||
<div class="card">
|
<div class="card">
|
||||||
@@ -365,6 +368,28 @@
|
|||||||
<% end %>
|
<% end %>
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
|
<% if isMobile.include? "Mobile" %>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-xs-12 col-sm-12 col-md-6 col-lg-6 ">
|
||||||
|
<div class="card">
|
||||||
|
<div class="body">
|
||||||
|
<h4><i class="material-icons md-24">dashboard</i><%= (t :top) + " " + (t :products) %></h4>
|
||||||
|
<!-- <canvas id="top_products" class="col-md-12"></canvas> -->
|
||||||
|
<%= pie_chart @top_products %>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="col-xs-12 col-sm-12 col-md-6 col-lg-6 ">
|
||||||
|
<div class="card">
|
||||||
|
<div class="body">
|
||||||
|
<h4><i class="material-icons md-24">dashboard</i><%= (t :bottom) + " " + (t :products) %></h4>
|
||||||
|
<!-- <canvas id="top_products" class="col-md-12"></canvas> -->
|
||||||
|
<%= pie_chart @bottom_products %>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
|
|||||||
@@ -164,11 +164,3 @@
|
|||||||
});
|
});
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -18,14 +18,14 @@
|
|||||||
<%if current_login_employee.role !="waiter" %>
|
<%if current_login_employee.role !="waiter" %>
|
||||||
<a href="javascript:void(0);" class="bars"></a>
|
<a href="javascript:void(0);" class="bars"></a>
|
||||||
<% if current_login_employee.role == "administrator" || current_login_employee.role == "manager" || current_login_employee.role == "account" %>
|
<% if current_login_employee.role == "administrator" || current_login_employee.role == "manager" || current_login_employee.role == "account" %>
|
||||||
<a class="navbar-brand" href="<%=dashboard_path%>" style="margin-left: 20px;">
|
<a class="navbar-brand mbl_view" href="<%=dashboard_path%>" style="margin-left: 20px;">
|
||||||
<% elsif current_login_employee.role == "supervisor" || current_login_employee.role == "cashier" || current_login_employee.role == "waiter" %>
|
<% elsif current_login_employee.role == "supervisor" || current_login_employee.role == "cashier" || current_login_employee.role == "waiter" %>
|
||||||
<a class="navbar-brand" href="<%=origami_dashboard_path%>" style="margin-left: 20px;">
|
<a class="navbar-brand mbl_view" href="<%=origami_dashboard_path%>" style="margin-left: 20px;">
|
||||||
<%else%>
|
<%else%>
|
||||||
<a class="navbar-brand" href="" style="margin-left: 20px;">
|
<a class="navbar-brand mbl_view" href="" style="margin-left: 20px;">
|
||||||
<% end %>
|
<% end %>
|
||||||
<% else %>
|
<% else %>
|
||||||
<a class="navbar-brand m-0" href="<%= origami_dashboard_path%>">
|
<a class="navbar-brand m-0 mbl_view" href="<%= origami_dashboard_path%>">
|
||||||
<%end%>
|
<%end%>
|
||||||
<img src="<%= asset_path('SX-Logo-small.png') %>" width="40" height="40" alt="Logo" />
|
<img src="<%= asset_path('SX-Logo-small.png') %>" width="40" height="40" alt="Logo" />
|
||||||
<span class="navbar-brand-txt">SX Restaurant</span>
|
<span class="navbar-brand-txt">SX Restaurant</span>
|
||||||
@@ -44,7 +44,13 @@
|
|||||||
<div class="navbar-right m-auto">
|
<div class="navbar-right m-auto">
|
||||||
<% if order_reservation %>
|
<% if order_reservation %>
|
||||||
<div class="online_order">
|
<div class="online_order">
|
||||||
<span class="navbar-brand navbar-brand-txt header-default-color"><%= t :order_reservation %></span>
|
<span class="navbar-brand navbar-brand-txt header-default-color">
|
||||||
|
<% if request.user_agent.include? "Mobile" %>
|
||||||
|
<img src="/assets/online_order_icon.png" alt="<%= t :order_reservation %>" />
|
||||||
|
<% else %>
|
||||||
|
<%= t :order_reservation %>
|
||||||
|
<% end %>
|
||||||
|
</span>
|
||||||
<span class="order_no"></span>
|
<span class="order_no"></span>
|
||||||
</div>
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
@@ -104,10 +110,16 @@
|
|||||||
<!-- End Quick Access for Cashier -->
|
<!-- End Quick Access for Cashier -->
|
||||||
|
|
||||||
<!-- Start Delete confirrm text !-->
|
<!-- Start Delete confirrm text !-->
|
||||||
<div class="navbar-right">
|
<div class="navbar-right toggle_mbl">
|
||||||
<a href="javascript:void(0);" class="dropdown-toggle waves-block" data-toggle="dropdown" aria-haspopup="true" aria-expanded="true">
|
<a href="javascript:void(0);" class="dropdown-toggle waves-block" data-toggle="dropdown" aria-haspopup="true" aria-expanded="true">
|
||||||
<% if current_login_employee %>
|
<% if current_login_employee %>
|
||||||
<span><%= current_login_employee.name %></span>
|
<span>
|
||||||
|
<% if request.user_agent.include? "Mobile" %>
|
||||||
|
<img src="/assets/user_icon.png" alt="<%= current_login_employee.name %>" />
|
||||||
|
<% else %>
|
||||||
|
<%= current_login_employee.name %>
|
||||||
|
<% end %>
|
||||||
|
</span>
|
||||||
<% end %>
|
<% end %>
|
||||||
</a>
|
</a>
|
||||||
<ul class="dropdown-menu">
|
<ul class="dropdown-menu">
|
||||||
|
|||||||
@@ -37,10 +37,10 @@
|
|||||||
<th style='text-align:center;' class="d-none d-sm-table-cell"><%= t("views.right_panel.detail.master_sales") %></th>
|
<th style='text-align:center;' class="d-none d-sm-table-cell"><%= t("views.right_panel.detail.master_sales") %></th>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if @payment_methods.include? ("VISA") %>
|
<% if @payment_methods.include? ("VISA") %>
|
||||||
<th style='text-align:center;'class="d-none d-sm-table-cell"><%= t("views.right_panel.detail.visa_sales") %></th>
|
<th style='text-align:center;' class="d-none d-sm-table-cell"><%= t("views.right_panel.detail.visa_sales") %></th>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if @payment_methods.include? ("JCB") %>
|
<% if @payment_methods.include? ("JCB") %>
|
||||||
<th style='text-align:center;'class="d-none d-sm-table-cell"><%= t("views.right_panel.detail.jcb_sales") %></th>
|
<th style='text-align:center;' class="d-none d-sm-table-cell"><%= t("views.right_panel.detail.jcb_sales") %></th>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if @payment_methods.include? ("UNIONPAY") %>
|
<% if @payment_methods.include? ("UNIONPAY") %>
|
||||||
<th style='text-align:center;' class="d-none d-sm-table-cell"><%= t("views.right_panel.detail.unionpay_sales") %></th>
|
<th style='text-align:center;' class="d-none d-sm-table-cell"><%= t("views.right_panel.detail.unionpay_sales") %></th>
|
||||||
@@ -134,34 +134,34 @@
|
|||||||
<td><%= sale[:sale_date].strftime("#{sale[:sale_date].day.ordinalize} %b") rescue '-' %></td>
|
<td><%= sale[:sale_date].strftime("#{sale[:sale_date].day.ordinalize} %b") rescue '-' %></td>
|
||||||
<td style='color:red;text-align:right;'><%= number_with_precision(sale[:void_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
<td style='color:red;text-align:right;'><%= number_with_precision(sale[:void_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<% if @payment_methods.include? ("MPU") %>
|
<% if @payment_methods.include? ("MPU") %>
|
||||||
<td style='text-align:right;'><%= number_with_precision(sale[:mpu_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(sale[:mpu_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if @payment_methods.include? ("Master") %>
|
<% if @payment_methods.include? ("Master") %>
|
||||||
<td style='text-align:right;'><%= number_with_precision(sale[:master_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(sale[:master_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if @payment_methods.include? ("VISA") %>
|
<% if @payment_methods.include? ("VISA") %>
|
||||||
<td style='text-align:right;'><%= number_with_precision(sale[:visa_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(sale[:visa_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if @payment_methods.include? ("JCB") %>
|
<% if @payment_methods.include? ("JCB") %>
|
||||||
<td style='text-align:right;'><%= number_with_precision(sale[:jcb_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(sale[:jcb_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if @payment_methods.include? ("UNIONPAY") %>
|
<% if @payment_methods.include? ("UNIONPAY") %>
|
||||||
<td style='text-align:right;'><%= number_with_precision(sale[:unionpay_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(sale[:unionpay_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if @payment_methods.include? ("Alipay") %>
|
<% if @payment_methods.include? ("Alipay") %>
|
||||||
<td style='text-align:right;'><%= number_with_precision(sale[:alipay_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(sale[:alipay_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if @payment_methods.include? ("PAYMAL") %>
|
<% if @payment_methods.include? ("PAYMAL") %>
|
||||||
<td style='text-align:right;'><%= number_with_precision(sale[:paymal_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(sale[:paymal_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if @payment_methods.include? ("DINGA") %>
|
<% if @payment_methods.include? ("DINGA") %>
|
||||||
<td style='text-align:right;'><%= number_with_precision(sale[:dinga_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(sale[:dinga_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if @payment_methods.include? ("JunctionPay") %>
|
<% if @payment_methods.include? ("JunctionPay") %>
|
||||||
<td style='text-align:right;'><%= number_with_precision(sale[:junctionpay_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(sale[:junctionpay_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if @payment_methods.include? ("Redeem") %>
|
<% if @payment_methods.include? ("Redeem") %>
|
||||||
<td style='text-align:right;'><%= number_with_precision(sale[:paypar_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(sale[:paypar_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<% end %>
|
<% end %>
|
||||||
<td style='text-align:right;'><%= number_with_precision(sale[:cash_amount]-sale[:total_change_amount], precision:precision.to_i, delimiter: delimiter) rescue '-'%></td>
|
<td style='text-align:right;'><%= number_with_precision(sale[:cash_amount]-sale[:total_change_amount], precision:precision.to_i, delimiter: delimiter) rescue '-'%></td>
|
||||||
<td style='text-align:right;'><%= number_with_precision(sale[:credit_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
<td style='text-align:right;'><%= number_with_precision(sale[:credit_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
@@ -181,44 +181,34 @@
|
|||||||
<tr style="font-weight:600;">
|
<tr style="font-weight:600;">
|
||||||
<td colspan="3" style='text-align:center;'>Total</td>
|
<td colspan="3" style='text-align:center;'>Total</td>
|
||||||
<% if @payment_methods.include? ("MPU") %>
|
<% if @payment_methods.include? ("MPU") %>
|
||||||
<% colspan += 1 %>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(mpu , precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<td style='text-align:right;'><%= number_with_precision(mpu , precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
|
||||||
<% end%>
|
<% end%>
|
||||||
<% if @payment_methods.include? ("Master") %>
|
<% if @payment_methods.include? ("Master") %>
|
||||||
<% colspan += 1 %>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(master, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<td style='text-align:right;'><%= number_with_precision(master, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
|
||||||
<% end%>
|
<% end%>
|
||||||
<% if @payment_methods.include? ("VISA") %>
|
<% if @payment_methods.include? ("VISA") %>
|
||||||
<% colspan += 1 %>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(visa, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<td style='text-align:right;'><%= number_with_precision(visa, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
|
||||||
<% end%>
|
<% end%>
|
||||||
<% if @payment_methods.include? ("JCB") %>
|
<% if @payment_methods.include? ("JCB") %>
|
||||||
<% colspan += 1 %>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(jcb, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<td style='text-align:right;'><%= number_with_precision(jcb, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
|
||||||
<% end%>
|
<% end%>
|
||||||
<% if @payment_methods.include? ("UNIONPAY") %>
|
<% if @payment_methods.include? ("UNIONPAY") %>
|
||||||
<% colspan += 1 %>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(unionpay, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<td style='text-align:right;'><%= number_with_precision(unionpay, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if @payment_methods.include? ("Alipay") %>
|
<% if @payment_methods.include? ("Alipay") %>
|
||||||
<% colspan += 1 %>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(alipay, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<td style='text-align:right;'><%= number_with_precision(alipay, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if @payment_methods.include? ("PAYMAL") %>
|
<% if @payment_methods.include? ("PAYMAL") %>
|
||||||
<% colspan += 1 %>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(paymal, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<td style='text-align:right;'><%= number_with_precision(paymal, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if @payment_methods.include? ("DINGA") %>
|
<% if @payment_methods.include? ("DINGA") %>
|
||||||
<% colspan += 1 %>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(dinga, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<td style='text-align:right;'><%= number_with_precision(dinga, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if @payment_methods.include? ("JunctionPay") %>
|
<% if @payment_methods.include? ("JunctionPay") %>
|
||||||
<% colspan += 1 %>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(junctionpay, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<td style='text-align:right;'><%= number_with_precision(junctionpay, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if @payment_methods.include? ("Redeem") %>
|
<% if @payment_methods.include? ("Redeem") %>
|
||||||
<% colspan += 1 %>
|
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(paypar, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<td style='text-align:right;'><%= number_with_precision(paypar, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
|
||||||
<% end %>
|
<% end %>
|
||||||
<td style='text-align:right;'><%= number_with_precision(cash, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
<td style='text-align:right;'><%= number_with_precision(cash, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<td style='text-align:right;'><%= number_with_precision(credit, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
<td style='text-align:right;'><%= number_with_precision(credit, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
|
|||||||
@@ -109,8 +109,8 @@
|
|||||||
<!-- <td><%= sprintf "%.2f",result.accept_credit_amount.to_f.to_d rescue '-'%></td> -->
|
<!-- <td><%= sprintf "%.2f",result.accept_credit_amount.to_f.to_d rescue '-'%></td> -->
|
||||||
<!-- <td><%= sprintf "%.2f",result.foc_amount.to_f.to_d rescue '-'%></td>
|
<!-- <td><%= sprintf "%.2f",result.foc_amount.to_f.to_d rescue '-'%></td>
|
||||||
<td><%= sprintf "%.2f",result.card_amount.to_f.to_d rescue '-'%></td> -->
|
<td><%= sprintf "%.2f",result.card_amount.to_f.to_d rescue '-'%></td> -->
|
||||||
<td><%= number_with_precision(result[:other_sales].to_f, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
<td class="d-none d-sm-table-cell"><%= number_with_precision(result[:other_sales].to_f, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
<td>
|
<td class="d-none d-sm-table-cell">
|
||||||
<%= number_with_precision(result[:foc_sales].to_f, precision:precision.to_i,delimiter:delimiter) rescue '-'%>
|
<%= number_with_precision(result[:foc_sales].to_f, precision:precision.to_i,delimiter:delimiter) rescue '-'%>
|
||||||
</td>
|
</td>
|
||||||
<td><%= number_with_precision(result[:grand_total].to_f, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
<td><%= number_with_precision(result[:grand_total].to_f, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||||
@@ -138,8 +138,8 @@
|
|||||||
<td><b><%= number_with_precision(credit, precision:precision.to_i,delimiter:delimiter) rescue '-'%></b></td>
|
<td><b><%= number_with_precision(credit, precision:precision.to_i,delimiter:delimiter) rescue '-'%></b></td>
|
||||||
<!-- <td><b><%= sprintf("%.2f",accept_credit) rescue '-'%></b></td> -->
|
<!-- <td><b><%= sprintf("%.2f",accept_credit) rescue '-'%></b></td> -->
|
||||||
<!-- <td><b><%= sprintf("%.2f",foc) rescue '-'%></b></td> -->
|
<!-- <td><b><%= sprintf("%.2f",foc) rescue '-'%></b></td> -->
|
||||||
<td><b><%= number_with_precision(card, precision:precision.to_i,delimiter:delimiter) rescue '-'%></b></td>
|
<td class="d-none d-sm-table-cell"><b><%= number_with_precision(card, precision:precision.to_i,delimiter:delimiter) rescue '-'%></b></td>
|
||||||
<td><b><%= number_with_precision(foc, precision:precision.to_i,delimiter:delimiter) rescue '-'%></b></td>
|
<td class="d-none d-sm-table-cell"><b><%= number_with_precision(foc, precision:precision.to_i,delimiter:delimiter) rescue '-'%></b></td>
|
||||||
<!-- <td><b><%= sprintf("%.2f",total) rescue '-'%></b></td> -->
|
<!-- <td><b><%= sprintf("%.2f",total) rescue '-'%></b></td> -->
|
||||||
<!-- <td><b><%= sprintf("%.2f",rounding_adj) rescue '-'%></b></td> -->
|
<!-- <td><b><%= sprintf("%.2f",rounding_adj) rescue '-'%></b></td> -->
|
||||||
<td><b><%= number_with_precision(g_total, precision:precision.to_i,delimiter:delimiter) rescue '-'%></b></td>
|
<td><b><%= number_with_precision(g_total, precision:precision.to_i,delimiter:delimiter) rescue '-'%></b></td>
|
||||||
|
|||||||
@@ -21,11 +21,11 @@ class ActionController::Base
|
|||||||
end
|
end
|
||||||
else
|
else
|
||||||
# check for license file
|
# check for license file
|
||||||
if check_license
|
# if check_license
|
||||||
current_license(ENV["SX_PROVISION_URL"])
|
#current_license(ENV["SX_PROVISION_URL"])
|
||||||
else
|
#else
|
||||||
redirect_to activate_path
|
#redirect_to activate_path
|
||||||
end
|
#end
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user