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 |
@@ -69,11 +69,11 @@
|
||||
z-index: 1100;
|
||||
}
|
||||
|
||||
#sxModal-Content {
|
||||
#sxModal-Content {
|
||||
position: relative;
|
||||
left: 42%;
|
||||
top: 30%;
|
||||
background-color: #32ad1a;
|
||||
background-color: #32ad1a;
|
||||
color: #fff;
|
||||
text-align: center;
|
||||
width: 200px;
|
||||
@@ -92,7 +92,7 @@
|
||||
#videoElement {
|
||||
width: 480px;
|
||||
height: 375px;
|
||||
|
||||
|
||||
}
|
||||
|
||||
.cashier_number{
|
||||
@@ -243,7 +243,7 @@ i.logout_icon{
|
||||
span.round-tab:hover{
|
||||
color: white;
|
||||
border: 1px solid #fff;
|
||||
background-color:#2196F3;
|
||||
background-color:#2196F3;
|
||||
}
|
||||
.wizard .nav-tabs > li {
|
||||
width: 25%;
|
||||
@@ -268,4 +268,55 @@ i.logout_icon{
|
||||
font-size: 14px;
|
||||
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;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -120,4 +120,55 @@ i.logout_icon{
|
||||
|
||||
.table-width{
|
||||
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;}
|
||||
.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;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -279,4 +279,55 @@ tr.discount-item-row:hover {
|
||||
i.logout_icon{
|
||||
position: relative;
|
||||
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;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -62,8 +62,8 @@ select.form-control {
|
||||
|
||||
/*
|
||||
.order-info {
|
||||
min-height:300px;
|
||||
max-height:500px;
|
||||
min-height:300px;
|
||||
max-height:500px;
|
||||
overflow:auto
|
||||
}
|
||||
*/
|
||||
@@ -222,7 +222,7 @@ select.form-control {
|
||||
margin-right: 15px;
|
||||
color:#fff !important;
|
||||
# background-color: green !important;
|
||||
}
|
||||
}
|
||||
|
||||
/* Reciept Style */
|
||||
#order-charges-table td {
|
||||
@@ -336,11 +336,11 @@ tr.discount-item-row:hover {
|
||||
z-index: 1100;
|
||||
}
|
||||
|
||||
#sxModal-Content {
|
||||
#sxModal-Content {
|
||||
position: relative;
|
||||
left: 42%;
|
||||
top: 30%;
|
||||
background-color: #32ad1a;
|
||||
background-color: #32ad1a;
|
||||
color: #fff;
|
||||
text-align: center;
|
||||
width: 200px;
|
||||
@@ -373,7 +373,7 @@ tr.discount-item-row:hover {
|
||||
opacity: 1;
|
||||
filter: alpha(opacity=100); /* ie */
|
||||
-moz-opacity: 1; /* mozilla */
|
||||
|
||||
|
||||
}
|
||||
|
||||
/* For Payment Page */
|
||||
@@ -465,7 +465,7 @@ iframe {
|
||||
}
|
||||
|
||||
.tax-btn-box {
|
||||
width: 230px;
|
||||
width: 230px;
|
||||
height: 80px;
|
||||
}
|
||||
|
||||
@@ -518,12 +518,12 @@ nav.pagination .page a:hover,
|
||||
opacity: 1;
|
||||
z-index: 101;
|
||||
filter: alpha(opacity=100); /* ie */
|
||||
-moz-opacity: 1; /* mozilla */
|
||||
-moz-opacity: 1; /* mozilla */
|
||||
}
|
||||
.existing_invoice{
|
||||
background-color:#ffab51;
|
||||
color:#fff;
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -628,7 +628,7 @@ nav.pagination .page a:hover,
|
||||
span.round-tab:hover{
|
||||
color: white;
|
||||
border: 1px solid #fff;
|
||||
background-color:#2196F3;
|
||||
background-color:#2196F3;
|
||||
}
|
||||
.wizard .nav-tabs > li {
|
||||
width: 25%;
|
||||
@@ -656,6 +656,57 @@ nav.pagination .page a:hover,
|
||||
/*customer modal UI */
|
||||
|
||||
.payment-btn-box {
|
||||
width: 130px;
|
||||
width: 130px;
|
||||
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;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
class Reports::DailysaleController < BaseReportController
|
||||
authorize_resource :class => false
|
||||
|
||||
|
||||
def index
|
||||
from, to = get_date_range_from_params
|
||||
@sale_data = Sale.daily_sales_list(from,to)
|
||||
@@ -16,9 +16,9 @@ class Reports::DailysaleController < BaseReportController
|
||||
format.xls
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
def show
|
||||
|
||||
|
||||
end
|
||||
|
||||
|
||||
end
|
||||
|
||||
@@ -879,7 +879,6 @@ def self.daily_sales_list(from,to)
|
||||
|
||||
total_sale.each do |sale|
|
||||
grand_total = sale.grand_total
|
||||
amount_received = sale.amount_received
|
||||
old_grand_total = sale.old_grand_total
|
||||
total_discount = sale.total_discount
|
||||
void_amount = sale.void_amount
|
||||
@@ -952,7 +951,6 @@ def self.get_by_shiftsales(from,to,shift)
|
||||
end
|
||||
|
||||
shift_sale_data[shift_sale.id] = {
|
||||
:shift_id => shift_sale.id,
|
||||
:cashier_terminal_name => shift_sale.cashier_terminal.name,
|
||||
:employee_name => shift_sale.employee.name,
|
||||
: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
|
||||
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()
|
||||
query = Sale.select("i.account_id as account_id, " +
|
||||
"SUM(i.qty * i.unit_price) as grand_total,SUM(i.qty) as total_item," +
|
||||
|
||||
@@ -14,10 +14,10 @@
|
||||
else
|
||||
delimiter = ""
|
||||
end
|
||||
%>
|
||||
%>
|
||||
<!-- Widgets -->
|
||||
<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="icon">
|
||||
<i class="material-icons">help</i>
|
||||
@@ -30,7 +30,7 @@
|
||||
</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="icon">
|
||||
<i class="material-icons">attach_money</i>
|
||||
@@ -44,7 +44,7 @@
|
||||
</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="icon">
|
||||
<i class="material-icons">person_add</i>
|
||||
@@ -57,7 +57,7 @@
|
||||
</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="icon">
|
||||
<i class="material-icons">credit_card</i>
|
||||
@@ -99,27 +99,27 @@
|
||||
to_time = ''
|
||||
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>
|
||||
<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>
|
||||
</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>
|
||||
<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>
|
||||
</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>
|
||||
<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>
|
||||
</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>
|
||||
<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>
|
||||
</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>
|
||||
<input type="button" value="Generate" class='btn btn-primary btn_generate'>
|
||||
</div>
|
||||
@@ -131,26 +131,29 @@
|
||||
<div class="row">
|
||||
<% 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="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 %>
|
||||
<% isMobile = request.user_agent %>
|
||||
<% 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>
|
||||
<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 class="row">
|
||||
<div class="col-xs-12 col-sm-12 col-md-12 col-lg-12">
|
||||
<div class="card">
|
||||
@@ -231,9 +234,9 @@
|
||||
<tr>
|
||||
<% if payment.payment_method == 'paypar' %>
|
||||
<td>Redeem Sale : </td>
|
||||
<% else %>
|
||||
<% else %>
|
||||
<td><%= payment.payment_method.to_s.capitalize %> Sale : </td>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<td align="right">
|
||||
<% @sale_data.each do |data| %>
|
||||
<% pay_mth = payment.payment_method %>
|
||||
@@ -254,7 +257,7 @@
|
||||
</td>
|
||||
</tr>
|
||||
<% end %>
|
||||
|
||||
|
||||
<% end %>
|
||||
</table>
|
||||
</div>
|
||||
@@ -329,7 +332,7 @@
|
||||
<td align="right" width="60px"><%= @total_order.total_order %></td>
|
||||
</tr>
|
||||
<% end %>
|
||||
|
||||
|
||||
<% if !@total_accounts.nil? %>
|
||||
<% @total_accounts.each do |account| %>
|
||||
<tr>
|
||||
@@ -346,7 +349,7 @@
|
||||
<% if !@top_items.nil? %>
|
||||
<tr>
|
||||
<td width="40px"><%= t :top %> <%= t("views.right_panel.detail.item") %> : </td>
|
||||
<td align="right" width="60px"><%= @top_items.item_name %>
|
||||
<td align="right" width="60px"><%= @top_items.item_name %>
|
||||
<br>(<%= @top_items.item_total_price %>)</td>
|
||||
</tr>
|
||||
<% end %>
|
||||
@@ -359,19 +362,41 @@
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<% if current_user.role == 'administrator' || current_user.role == 'manager' || current_user.role == 'account' %>
|
||||
</div>
|
||||
<% end %>
|
||||
<% end %>
|
||||
</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>
|
||||
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function(){
|
||||
var from = '<%= @from.strftime('%d-%m-%Y') rescue '' %>';
|
||||
var to = '<%= @to.strftime('%d-%m-%Y') rescue '' %>';
|
||||
|
||||
|
||||
if((from!=undefined) && (from != null) && (from != '')){
|
||||
$('#from').val(from);
|
||||
}
|
||||
@@ -434,4 +459,4 @@
|
||||
if(status && t_status) status = true;
|
||||
return status;
|
||||
}
|
||||
</script>
|
||||
</script>
|
||||
|
||||
@@ -154,7 +154,7 @@
|
||||
$(".collapse.in").each(function () {
|
||||
$(this).siblings(".panel-heading").find(".glyphicon").addClass("glyphicon-minus").removeClass("glyphicon-plus");
|
||||
});
|
||||
|
||||
|
||||
// Toggle plus minus icon on show hide of collapse element
|
||||
$(".collapse").on('show.bs.collapse', function () {
|
||||
$(this).parent().find(".glyphicon").removeClass("glyphicon-plus").addClass("glyphicon-minus");
|
||||
@@ -164,11 +164,3 @@
|
||||
});
|
||||
|
||||
</script>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -18,19 +18,19 @@
|
||||
<%if current_login_employee.role !="waiter" %>
|
||||
<a href="javascript:void(0);" class="bars"></a>
|
||||
<% 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" %>
|
||||
<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%>
|
||||
<a class="navbar-brand" href="" style="margin-left: 20px;">
|
||||
<a class="navbar-brand mbl_view" href="" style="margin-left: 20px;">
|
||||
<% end %>
|
||||
<% else %>
|
||||
<a class="navbar-brand m-0" href="<%= origami_dashboard_path%>">
|
||||
<a class="navbar-brand m-0 mbl_view" href="<%= origami_dashboard_path%>">
|
||||
<%end%>
|
||||
<img src="<%= asset_path('SX-Logo-small.png') %>" width="40" height="40" alt="Logo" />
|
||||
<span class="navbar-brand-txt">SX Restaurant</span>
|
||||
</a>
|
||||
|
||||
|
||||
<span class="navbar-brand m-0">
|
||||
<span id="others_payment"></span>
|
||||
</span>
|
||||
@@ -40,11 +40,17 @@
|
||||
<span class="navbar-brand navbar-brand-txt"><%= shop_detail.name %></span>
|
||||
</div>
|
||||
<!-- End Shop Info -->
|
||||
|
||||
|
||||
<div class="navbar-right m-auto">
|
||||
<% if order_reservation %>
|
||||
<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>
|
||||
</div>
|
||||
<% end %>
|
||||
@@ -52,7 +58,7 @@
|
||||
|
||||
<!-- Start Quick Access for Cashier -->
|
||||
<!-- <div class="navbar-right m-auto">
|
||||
<a href="#" class="dropdown-toggle waves-block col-white" data-toggle="dropdown" aria-haspopup="true" aria-expanded="flase">
|
||||
<a href="#" class="dropdown-toggle waves-block col-white" data-toggle="dropdown" aria-haspopup="true" aria-expanded="flase">
|
||||
<span><%= t :cashier %></span>
|
||||
</a>
|
||||
<ul class="dropdown-menu">
|
||||
@@ -62,7 +68,7 @@
|
||||
<i class="material-icons font-7 logout_icon shopinfo">monetization_on</i>
|
||||
<span class="font-15 shopinfo dinein" ><%= t :dine_in %></span>
|
||||
</a>
|
||||
</p>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p class="waves-effect waves-block p-l-20 m-b-5">
|
||||
@@ -70,7 +76,7 @@
|
||||
<i class="material-icons font-7 logout_icon shopinfo">restaurant_menu</i>
|
||||
<span class="font-15 shopinfo quick_service" ><%= t :quick_service %></span>
|
||||
</a>
|
||||
</p>
|
||||
</p>
|
||||
</li>
|
||||
<% if order_reservation %>
|
||||
<li>
|
||||
@@ -80,7 +86,7 @@
|
||||
<span class="font-15 col-black online_order" ><%= t :order_reservation %></span>
|
||||
<span class="order_no"></span>
|
||||
</a>
|
||||
</p>
|
||||
</p>
|
||||
</li>
|
||||
<% end %>
|
||||
<li>
|
||||
@@ -89,7 +95,7 @@
|
||||
<i class="material-icons font-7 logout_icon shopinfo">book</i>
|
||||
<span class="font-15 col-black reservation" ><%= t :reservation %></span>
|
||||
</a>
|
||||
</p>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<p class="waves-effect waves-block p-l-20 m-b-5">
|
||||
@@ -97,17 +103,23 @@
|
||||
<i class="material-icons font-7 logout_icon shopinfo">restaurant</i>
|
||||
<span class="font-15 col-black foodcourt" ><%= t :foodcourt %></span>
|
||||
</a>
|
||||
</p>
|
||||
</p>
|
||||
</li>
|
||||
</ul>
|
||||
</div> -->
|
||||
<!-- End Quick Access for Cashier -->
|
||||
|
||||
|
||||
<!-- Start Delete confirrm text !-->
|
||||
<div class="navbar-right">
|
||||
<a href="javascript:void(0);" class="dropdown-toggle waves-block" data-toggle="dropdown" aria-haspopup="true" aria-expanded="true">
|
||||
<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">
|
||||
<% 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 %>
|
||||
</a>
|
||||
<ul class="dropdown-menu">
|
||||
@@ -118,14 +130,14 @@
|
||||
<i class="material-icons font-7 logout_icon shopinfo">info</i>
|
||||
<span class="font-15 shopinfo" >Shop Info</span>
|
||||
</a>
|
||||
</p>
|
||||
</p>
|
||||
</li>
|
||||
<% end %>
|
||||
<li>
|
||||
<p class="waves-effect waves-block p-l-30 m-b-5 team_viewer">
|
||||
<i class="material-icons font-7 logout_icon shopinfo">touch_app</i>
|
||||
<span class="font-15 shopinfo" >Team Viewer</span>
|
||||
</p>
|
||||
</p>
|
||||
</li>
|
||||
<li>
|
||||
<!-- <p class="delete waves-effect waves-block p-l-30 m-b-5" data-ref="<%=logout_path%>" data-method="delete">
|
||||
@@ -140,7 +152,7 @@
|
||||
<h6>Are you sure you want to Logout ?</h6>
|
||||
<!-- <h6>This action can't be undo. </h6> -->
|
||||
</span>
|
||||
</li>
|
||||
</li>
|
||||
</ul>
|
||||
<!-- NO Need for color Change
|
||||
<a href="javascript:void(0);" class="js-right-sidebar" data-close="true">
|
||||
@@ -156,7 +168,7 @@
|
||||
var method = $(this).attr('data-method');
|
||||
var url = $(this).attr('data-ref');
|
||||
var html_text = $(this).siblings( "#delete_text" ).html();
|
||||
//var page = url.substring(url.lastIndexOf('/') + 1);
|
||||
//var page = url.substring(url.lastIndexOf('/') + 1);
|
||||
swal({
|
||||
title: "Confirmation",
|
||||
text: html_text,
|
||||
@@ -168,11 +180,11 @@
|
||||
if (isConfirm) {
|
||||
$.ajax({
|
||||
type: method,
|
||||
url: url ,
|
||||
success: function(data) {
|
||||
url: url ,
|
||||
success: function(data) {
|
||||
location.href = data.url;
|
||||
}
|
||||
});
|
||||
});
|
||||
} else {
|
||||
swal("Cancelled", "Your imaginary file is safe :)", "error");
|
||||
}
|
||||
@@ -203,6 +215,6 @@
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
});
|
||||
</script>
|
||||
</script>
|
||||
|
||||
@@ -15,14 +15,14 @@
|
||||
<hr />
|
||||
<div class=" text-right">
|
||||
<a href="javascript:export_to('<%=reports_dailysale_index_path%>.xls')" class = "btn btn-info wave-effects"><%= t("views.btn.exp_to_excel") %></a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12 col-lg-12">
|
||||
<div class="card" style="width:129%;">
|
||||
<div class="body table-responsive">
|
||||
<table class="table table-bordered">
|
||||
<thead>
|
||||
<thead>
|
||||
<tr>
|
||||
<th colspan="15"> <%= t("views.right_panel.detail.from_date") %> : <%= @from.utc.getlocal.strftime("%Y-%b-%d") rescue '-' %> - <%= t("views.right_panel.detail.to_date") %> : <%= @to.utc.getlocal.strftime("%Y-%b-%d") rescue '-'%></th>
|
||||
</tr>
|
||||
@@ -37,10 +37,10 @@
|
||||
<th style='text-align:center;' class="d-none d-sm-table-cell"><%= t("views.right_panel.detail.master_sales") %></th>
|
||||
<% end %>
|
||||
<% 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 %>
|
||||
<% 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 %>
|
||||
<% 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>
|
||||
@@ -67,10 +67,10 @@
|
||||
<th style='text-align:center;'><%= t("views.right_panel.detail.giftvoucher_sales") %></th>
|
||||
<% end %>
|
||||
<th style='text-align:center;'>(<%= t("views.right_panel.detail.discount") %>)</th>
|
||||
<!-- <th style='text-align:center;'><%= t("views.right_panel.detail.grand_total") %> + <br/> <%= t("views.right_panel.detail.rnd_adj_sh") %></th> -->
|
||||
<th style='text-align:center;'><%= t("views.right_panel.detail.grand_total") %></th>
|
||||
<!-- <th style='text-align:center;'><%= t("views.right_panel.detail.grand_total") %> + <br/> <%= t("views.right_panel.detail.rnd_adj_sh") %></th> -->
|
||||
<th style='text-align:center;'><%= t("views.right_panel.detail.grand_total") %></th>
|
||||
<th style='text-align:center;'><%= t("views.right_panel.detail.rnd_adj_sh") %></th>
|
||||
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<% if @print_settings.precision.to_i > 0
|
||||
@@ -84,7 +84,7 @@
|
||||
else
|
||||
delimiter = ""
|
||||
end
|
||||
%>
|
||||
%>
|
||||
<% unless @sale_data.empty? %>
|
||||
|
||||
<tbody>
|
||||
@@ -105,8 +105,8 @@
|
||||
<% foc = 0 %>
|
||||
<% discount = 0 %>
|
||||
<% total = 0 %>
|
||||
<% grand_total = 0 %>
|
||||
<% old_grand_total = 0 %>
|
||||
<% grand_total = 0 %>
|
||||
<% old_grand_total = 0 %>
|
||||
<% count = 1 %> <% rounding_adj = 0 %>
|
||||
<% @sale_data.each do |sale| %>
|
||||
<% void += sale[:void_amount] %>
|
||||
@@ -122,121 +122,111 @@
|
||||
<% giftvoucher += sale[:giftvoucher_amount] %>
|
||||
<% paypar += sale[:paypar_amount] %>
|
||||
<% cash += sale[:cash_amount]-sale[:total_change_amount] %>
|
||||
<% credit += sale[:credit_amount] %>
|
||||
<% credit += sale[:credit_amount] %>
|
||||
<% foc += sale[:foc_amount] %>
|
||||
<% discount += sale[:total_discount] %>
|
||||
<% total += sale[:grand_total].to_f + sale[:rounding_adj].to_f %>
|
||||
<% grand_total += sale[:grand_total].to_f %>
|
||||
<% old_grand_total += sale[:old_grand_total].to_f %>
|
||||
<% rounding_adj += sale[:rounding_adj].to_f %>
|
||||
<% grand_total += sale[:grand_total].to_f %>
|
||||
<% old_grand_total += sale[:old_grand_total].to_f %>
|
||||
<% rounding_adj += sale[:rounding_adj].to_f %>
|
||||
<tr>
|
||||
<td style='text-align:right;'><%= count %></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>
|
||||
<% 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 %>
|
||||
<% 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 %>
|
||||
<% 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 %>
|
||||
<% 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 %>
|
||||
<% 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 %>
|
||||
<% 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 %>
|
||||
<% 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 %>
|
||||
<% 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 %>
|
||||
<% 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 %>
|
||||
<% 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 %>
|
||||
<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[:foc_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<td style='text-align:right;'><%= number_with_precision(sale[:foc_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<% if @payment_methods.include? ("GiftVoucher") %>
|
||||
<td style='text-align:right;'><%= number_with_precision(sale[:giftvoucher_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<% end %>
|
||||
<td style='text-align:right;'><%= number_with_precision(sale[:giftvoucher_amount], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<% end %>
|
||||
<td style='text-align:right;'>(<%= number_with_precision(sale[:total_discount], precision:precision,delimiter:delimiter) rescue '-'%>)</td>
|
||||
<!-- <td style='text-align:right;'><%= number_with_precision(sale[:grand_total].to_f + sale[:rounding_adj].to_f , precision:precision.to_i,delimiter:delimiter) rescue '-'%></td> -->
|
||||
<td style='text-align:right;'><%= number_with_precision(sale[:grand_total], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<!-- <td style='text-align:right;'><%= number_with_precision(sale[:grand_total].to_f + sale[:rounding_adj].to_f , precision:precision.to_i,delimiter:delimiter) rescue '-'%></td> -->
|
||||
<td style='text-align:right;'><%= number_with_precision(sale[:grand_total], precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<td style='text-align:right;'><%= number_with_precision(sale[:rounding_adj].to_f, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
|
||||
|
||||
</tr>
|
||||
<% count = count + 1 %>
|
||||
<% end %>
|
||||
<% colspan = 7 %>
|
||||
<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") %>
|
||||
<% colspan += 1 %>
|
||||
<td style='text-align:right;'><%= number_with_precision(mpu , precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(mpu , precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<% end%>
|
||||
<% if @payment_methods.include? ("Master") %>
|
||||
<% colspan += 1 %>
|
||||
<td style='text-align:right;'><%= number_with_precision(master, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(master, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<% end%>
|
||||
<% if @payment_methods.include? ("VISA") %>
|
||||
<% colspan += 1 %>
|
||||
<td style='text-align:right;'><%= number_with_precision(visa, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(visa, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<% end%>
|
||||
<% if @payment_methods.include? ("JCB") %>
|
||||
<% colspan += 1 %>
|
||||
<td style='text-align:right;'><%= number_with_precision(jcb, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(jcb, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<% end%>
|
||||
<% if @payment_methods.include? ("UNIONPAY") %>
|
||||
<% colspan += 1 %>
|
||||
<td style='text-align:right;'><%= number_with_precision(unionpay, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(unionpay, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<% end %>
|
||||
<% if @payment_methods.include? ("Alipay") %>
|
||||
<% colspan += 1 %>
|
||||
<td style='text-align:right;'><%= number_with_precision(alipay, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(alipay, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<% end %>
|
||||
<% if @payment_methods.include? ("PAYMAL") %>
|
||||
<% colspan += 1 %>
|
||||
<td style='text-align:right;'><%= number_with_precision(paymal, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(paymal, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<% end %>
|
||||
<% if @payment_methods.include? ("DINGA") %>
|
||||
<% colspan += 1 %>
|
||||
<td style='text-align:right;'><%= number_with_precision(dinga, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(dinga, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<% end %>
|
||||
<% if @payment_methods.include? ("JunctionPay") %>
|
||||
<% colspan += 1 %>
|
||||
<td style='text-align:right;'><%= number_with_precision(junctionpay, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(junctionpay, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<% end %>
|
||||
<% if @payment_methods.include? ("Redeem") %>
|
||||
<% colspan += 1 %>
|
||||
<td style='text-align:right;'><%= number_with_precision(paypar, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<td style='text-align:right;' class="d-none d-sm-table-cell"><%= number_with_precision(paypar, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<% 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(credit, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<td style='text-align:right;'><%= number_with_precision(foc, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<% if @payment_methods.include? ("GiftVoucher") %>
|
||||
<% colspan += 1 %>
|
||||
<td style='text-align:right;'><%= number_with_precision(giftvoucher, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<% end %>
|
||||
<td style='text-align:right;'><%= number_with_precision(giftvoucher, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<% end %>
|
||||
<td style='text-align:right;'>(<%= number_with_precision(discount, precision:precision.to_i,delimiter:delimiter) rescue '-'%>)</td>
|
||||
<!-- <td style='text-align:right;'><%= number_with_precision(total, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td> -->
|
||||
<td style='text-align:right;'><%= number_with_precision(grand_total, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<td style='text-align:right;'><%= number_with_precision(rounding_adj, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
|
||||
<td style='text-align:right;'><%= number_with_precision(grand_total, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<td style='text-align:right;'><%= number_with_precision(rounding_adj, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
|
||||
</tr>
|
||||
<% total_tax = 0 %>
|
||||
<% net = 0 %>
|
||||
<% unless @tax.empty? %>
|
||||
<% @tax.each do |tax|
|
||||
<% @tax.each do |tax|
|
||||
total_tax += tax.tax_amount.to_f %>
|
||||
<tr style="font-weight:600;">
|
||||
<td colspan="<%= colspan %>" style='text-align:right;'><%= tax.tax_name rescue '-'%></td>
|
||||
@@ -245,14 +235,14 @@
|
||||
</tr>
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
||||
|
||||
<% net = grand_total %>
|
||||
<% net = net - rounding_adj%>
|
||||
<% net = net - total_tax %>
|
||||
<tr style="font-weight:600;">
|
||||
<td colspan="<%= colspan %>" style='text-align:right;'><%= t("views.right_panel.detail.net_amount") %></td>
|
||||
<td style='text-align:right;'><%= number_with_precision(net, precision:precision.to_i,delimiter:delimiter) rescue '-'%></td>
|
||||
<td colspan="2"> </td>
|
||||
<td colspan="2"> </td>
|
||||
</tr>
|
||||
</tbody>
|
||||
<% end %>
|
||||
@@ -263,4 +253,4 @@
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -56,10 +56,10 @@
|
||||
<th><%= t("views.right_panel.detail.credit_payment") %></th>
|
||||
<th class="d-none d-sm-table-cell"><%= t("views.btn.other_payment") %></th>
|
||||
<th class="d-none d-sm-table-cell"><%= t("views.btn.foc") %> <%= t :payment %></th>
|
||||
<!-- <th>Grand Total
|
||||
<br/>Rounding Adj</th> -->
|
||||
<!-- <th>Grand Total
|
||||
<br/>Rounding Adj</th> -->
|
||||
|
||||
|
||||
|
||||
<!-- <th>Grand Total
|
||||
<br/>Rounding Adj</th> -->
|
||||
|
||||
@@ -109,8 +109,8 @@
|
||||
<!-- <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.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>
|
||||
<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 class="d-none d-sm-table-cell">
|
||||
<%= number_with_precision(result[:foc_sales].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><%= sprintf("%.2f",accept_credit) 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><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(card, 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",rounding_adj) 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
|
||||
else
|
||||
# check for license file
|
||||
if check_license
|
||||
current_license(ENV["SX_PROVISION_URL"])
|
||||
else
|
||||
redirect_to activate_path
|
||||
end
|
||||
# if check_license
|
||||
#current_license(ENV["SX_PROVISION_URL"])
|
||||
#else
|
||||
#redirect_to activate_path
|
||||
#end
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user