update scrll and member transaction
This commit is contained in:
@@ -50,7 +50,7 @@ class Origami::PaymentsController < BaseOrigamiController
|
||||
|
||||
unique_code = "ReceiptBillPdf"
|
||||
customer= Customer.find(saleObj.customer_id)
|
||||
rebate_amount = Customer.get_membership_transactions(customer)
|
||||
rebate_amount = Customer.get_membership_transactions(customer,saleObj.receipt_no)
|
||||
#shop detail
|
||||
shop_details = Shop.find(1)
|
||||
# get member information
|
||||
@@ -133,7 +133,7 @@ class Origami::PaymentsController < BaseOrigamiController
|
||||
shop_details = Shop.find(1)
|
||||
# get member information
|
||||
member_info = Customer.get_member_account(customer)
|
||||
rebate_amount = Customer.get_membership_transactions(customer)
|
||||
rebate_amount = Customer.get_membership_transactions(customer,saleObj.receipt_no)
|
||||
# get printer info
|
||||
print_settings=PrintSetting.find_by_unique_code(unique_code)
|
||||
|
||||
|
||||
@@ -46,7 +46,7 @@ class Customer < ApplicationRecord
|
||||
|
||||
end
|
||||
|
||||
def self.get_membership_transactions(customer)
|
||||
def self.get_membership_transactions(customer,receipt_no = nil)
|
||||
membership = MembershipSetting.find_by_membership_type("paypar_url")
|
||||
memberaction = MembershipAction.find_by_membership_type("get_member_transactions")
|
||||
merchant_uid = memberaction.merchant_account_id.to_s
|
||||
@@ -55,13 +55,17 @@ class Customer < ApplicationRecord
|
||||
# urltest =self.url_exist?(url)
|
||||
|
||||
begin
|
||||
response = HTTParty.get(url, :body => { membership_id: customer.membership_id,merchant_uid:merchant_uid,auth_token:auth_token}.to_json,
|
||||
:headers => {
|
||||
'Content-Type' => 'application/json',
|
||||
'Accept' => 'application/json'
|
||||
},
|
||||
:timeout => 10
|
||||
)
|
||||
response = HTTParty.get(url,
|
||||
:body => { membership_id: customer.membership_id,
|
||||
receipt_no:receipt_no,
|
||||
merchant_uid:merchant_uid,auth_token:auth_token
|
||||
}.to_json,
|
||||
:headers => {
|
||||
'Content-Type' => 'application/json',
|
||||
'Accept' => 'application/json'
|
||||
},
|
||||
:timeout => 10
|
||||
)
|
||||
rescue Net::OpenTimeout
|
||||
response = { status: false , message: "Server Time out"}
|
||||
|
||||
|
||||
@@ -269,20 +269,19 @@ class ReceiptBillPdf < Prawn::Document
|
||||
|
||||
if rebate_amount["status"] == true
|
||||
stroke_horizontal_rule
|
||||
rebate = 0
|
||||
balance = 0
|
||||
redeem = 0
|
||||
rebate_amount["data"].each do |res|
|
||||
|
||||
#total redeem amount
|
||||
if res["receipt_no"]== sale_data.receipt_no && res["status"]== "Redeem"
|
||||
redeem = redeem + res["redeem"]
|
||||
|
||||
balance = balance + res["balance"]
|
||||
end
|
||||
|
||||
|
||||
|
||||
#end Total redem
|
||||
#total Rebate Earn
|
||||
if res["receipt_no"]== sale_data.receipt_no && res["account_status"]== "RebateAccount" && res["status"]== "Rebate"
|
||||
|
||||
rebate = rebate + res["rebate"]
|
||||
# balance = balance + res["balance"]
|
||||
|
||||
move_down 5
|
||||
y_position = cursor
|
||||
@@ -294,11 +293,9 @@ class ReceiptBillPdf < Prawn::Document
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
# Total Rebate Amount if birthday
|
||||
if res["receipt_no"]== sale_data.receipt_no && res["account_status"]== "RebateBonusAccount" && res["status"]== "Rebate"
|
||||
|
||||
rebate = rebate + res["rebate"]
|
||||
|
||||
# balance = balance + res["balance"]
|
||||
move_down 5
|
||||
y_position = cursor
|
||||
bounding_box([0,y_position], :width =>self.item_description_width, :height => self.item_height) do
|
||||
@@ -307,21 +304,33 @@ class ReceiptBillPdf < Prawn::Document
|
||||
bounding_box([self.item_description_width,y_position], :width =>self.label_width) do
|
||||
text "#{number_with_precision(res["balance"], :precision => precision.to_i, :delimiter => delimiter)}" , :size => self.item_font_size,:align => :right
|
||||
end
|
||||
|
||||
end
|
||||
#end Total rebate if birthday
|
||||
end
|
||||
|
||||
move_down 5
|
||||
y_position = cursor
|
||||
bounding_box([0,y_position], :width =>self.item_description_width, :height => self.item_height) do
|
||||
text "Redeem Amount", :size => self.item_font_size,:align => :left
|
||||
end
|
||||
bounding_box([self.item_description_width,y_position], :width =>self.label_width) do
|
||||
text "#{number_with_precision(redeem, :precision => precision.to_i, :delimiter => delimiter)}", :size => self.item_font_size,:align => :right
|
||||
end
|
||||
y_position = cursor
|
||||
bounding_box([0,y_position], :width =>self.item_description_width, :height => self.item_height) do
|
||||
text "Redeem Amount", :size => self.item_font_size,:align => :left
|
||||
end
|
||||
bounding_box([self.item_description_width,y_position], :width =>self.label_width) do
|
||||
text "#{number_with_precision(redeem, :precision => precision.to_i, :delimiter => delimiter)}", :size => self.item_font_size,:align => :right
|
||||
end
|
||||
|
||||
# old = balance + redeem
|
||||
|
||||
# move_down 5
|
||||
# y_position = cursor
|
||||
# bounding_box([0,y_position], :width =>self.item_description_width, :height => self.item_height) do
|
||||
# text "Old Balance", :size => self.item_font_size,:align => :left
|
||||
# end
|
||||
# bounding_box([self.item_description_width,y_position], :width =>self.label_width) do
|
||||
# text "#{number_with_precision(old, :precision => precision.to_i, :delimiter => delimiter)}", :size => self.item_font_size,:align => :right
|
||||
# end
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
if member_info["status"] == true && member_info["data"].present?
|
||||
balance = 0
|
||||
member_info["data"].each do |res|
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<div class="col-lg-4 col-md-4 col-sm-4">
|
||||
<div class="col-lg-4 col-md-4 col-sm-4" style="min-height:600px; max-height:600px; overflow-x:scroll">
|
||||
|
||||
<%= simple_form_for @crm_customer,:url => crm_customers_path, :method => :post do |f| %>
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
<div class="row">
|
||||
<div class="col-lg-7 col-md-7 col-sm-7">
|
||||
|
||||
<div class="main-box-body clearfix">
|
||||
<div class="main-box-body clearfix" style="min-height:500px; max-height:500px; overflow-x:scroll">
|
||||
<div class="table-responsive">
|
||||
<table class="table table-striped">
|
||||
|
||||
@@ -71,7 +71,7 @@
|
||||
|
||||
</div>
|
||||
|
||||
<div class="col-lg-4 col-md-4 col-sm-4">
|
||||
<div class="col-lg-4 col-md-4 col-sm-4" style="min-height:600px; max-height:600px; overflow-x:scroll">
|
||||
<%= simple_form_for @crm_customer,:url => crm_customers_path, :method => :post do |f| %>
|
||||
|
||||
<span class="patch_method"></span>
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
<p>Date: <span id="receipt_date"> <%=@sale_data.receipt_date.strftime("%d/%m/%Y - %I:%M %p") rescue '-'%></span></p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-text">
|
||||
<div class="card-text" style="min-height:500px; max-height:500px; overflow-x:scroll">
|
||||
<table class="table table-default" id="order-items-table">
|
||||
<thead>
|
||||
<tr>
|
||||
|
||||
@@ -19,9 +19,9 @@
|
||||
</ul>
|
||||
<!-- Nav tabs - End -->
|
||||
|
||||
<div class="tab-content" style="max-height:670px; overflow:auto">
|
||||
<div class="tab-content" >
|
||||
<!--- Panel 0 - Completed Orders -->
|
||||
<div class="tab-pane" id="Completed" role="tabpanel">
|
||||
<div class="tab-pane" id="Completed" role="tabpanel" style="max-height:670px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @complete.each do |sale| %>
|
||||
<div class="card sales red text-white" data-id = "<%= sale.sale_id %>">
|
||||
@@ -35,7 +35,7 @@
|
||||
</div>
|
||||
|
||||
<!--- Panel 1 - Table Orders -->
|
||||
<div class="tab-pane active" id="tables" role="tabpanel">
|
||||
<div class="tab-pane active" id="tables" role="tabpanel" style="max-height:670px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @tables.each do |table| %>
|
||||
<% if table.status == 'occupied' %>
|
||||
@@ -67,7 +67,7 @@
|
||||
</div>
|
||||
|
||||
<!--- Panel 2 - Room Orders -->
|
||||
<div class="tab-pane" id="rooms" role="tabpanel">
|
||||
<div class="tab-pane" id="rooms" role="tabpanel" style="max-height:670px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @rooms.each do |room| %>
|
||||
<% if room.status == 'occupied' %>
|
||||
@@ -88,7 +88,7 @@
|
||||
</div>
|
||||
|
||||
<!--- Panel 3 - Orders -->
|
||||
<div class="tab-pane" id="orders" role="tabpanel">
|
||||
<div class="tab-pane" id="orders" role="tabpanel" style="max-height:670px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @orders.each do |order| %>
|
||||
<div class="card orders red text-white" data-id = "<%= order.order_id %>">
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
<ul class="nav nav-tabs" role="tablist">
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" data-toggle="tab" href="#Completed" role="tab">Completed</a>
|
||||
<a class="nav-link" data-toggle="tab" href="#completed" role="tab">Completed</a>
|
||||
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
@@ -21,10 +21,10 @@
|
||||
</ul>
|
||||
<!-- Nav tabs - End -->
|
||||
|
||||
<div class="tab-content" style="max-height:670px; overflow:auto">
|
||||
<div class="tab-content">
|
||||
<!--- Panel 0 - Completed Orders -->
|
||||
|
||||
<div class="tab-pane" id="completed" role="tabpanel">
|
||||
<div class="tab-pane" id="completed" role="tabpanel" style="max-height:600px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @complete.each do |sale| %>
|
||||
<div class="card sales red text-white" data-id = "<%= sale.sale_id %>">
|
||||
@@ -38,7 +38,7 @@
|
||||
</div>
|
||||
|
||||
<!--- Panel 1 - Table Orders -->
|
||||
<div class="tab-pane active" id="tables" role="tabpanel">
|
||||
<div class="tab-pane active" id="tables" role="tabpanel" style="max-height:600px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @tables.each do |table| %>
|
||||
<% if table.status == 'occupied' %>
|
||||
@@ -71,7 +71,7 @@
|
||||
</div>
|
||||
|
||||
<!--- Panel 2 - Room Orders -->
|
||||
<div class="tab-pane" id="rooms" role="tabpanel">
|
||||
<div class="tab-pane" id="rooms" role="tabpanel" style="max-height:600px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @rooms.each do |room| %>
|
||||
<% if room.status == 'occupied' %>
|
||||
@@ -98,7 +98,7 @@
|
||||
</div>
|
||||
|
||||
<!--- Panel 3 - Orders -->
|
||||
<div class="tab-pane" id="orders" role="tabpanel">
|
||||
<div class="tab-pane" id="orders" role="tabpanel" style="max-height:600px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
|
||||
<% @orders.each do |order| %>
|
||||
@@ -150,7 +150,7 @@
|
||||
<%end%>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-text">
|
||||
<div class="card-text" style="min-height:500px; max-height:500px; overflow-x:scroll">
|
||||
<table class="table table-striped" id="order-items-table">
|
||||
<thead>
|
||||
<tr>
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
|
||||
<!--- Panel 1 - Table Orders -->
|
||||
<div class="tab-pane " id="tables" role="tabpanel">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;min-height:500px; max-height:500px; overflow-x:scroll">
|
||||
<% @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;">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;min-height:500px; max-height:500px; overflow-x:scroll" >
|
||||
<% @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">
|
||||
<div class="card-text" style="min-height:500px; max-height:500px; overflow-x:scroll" >
|
||||
<table class="table table-striped" id="order-items-table">
|
||||
<thead>
|
||||
<tr>
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
|
||||
<!--- 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;">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;min-height:500px; max-height:500px; overflow-x:scroll" >
|
||||
<% @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;">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;min-height:500px; max-height:500px; overflow-x:scroll" >
|
||||
<% @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">
|
||||
<div class="card-text" style="min-height:500px; max-height:500px; overflow-x:scroll" >
|
||||
<table class="table table-striped" id="order-items-table">
|
||||
<thead>
|
||||
<tr>
|
||||
|
||||
@@ -19,9 +19,9 @@
|
||||
</ul>
|
||||
<!-- Nav tabs - End -->
|
||||
|
||||
<div class="tab-content" style="max-height:670px; overflow:auto">
|
||||
<div class="tab-content">
|
||||
<!--- Panel 0 - Completed Orders -->
|
||||
<div class="tab-pane " id="completed" role="tabpanel">
|
||||
<div class="tab-pane " id="completed" role="tabpanel" style="max-height:600px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @complete.each do |sale| %>
|
||||
<div class="card sales red text-white" data-id = "<%= sale.sale_id %>">
|
||||
@@ -34,7 +34,7 @@
|
||||
</div>
|
||||
|
||||
<!--- Panel 1 - Table Orders -->
|
||||
<div class="tab-pane " id="tables" role="tabpanel">
|
||||
<div class="tab-pane " id="tables" role="tabpanel" style="max-height:600px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @tables.each do |table| %>
|
||||
<% if table.status == 'occupied' %>
|
||||
@@ -60,7 +60,7 @@
|
||||
</div>
|
||||
|
||||
<!--- Panel 2 - Room Orders -->
|
||||
<div class="tab-pane" id="rooms" role="tabpanel">
|
||||
<div class="tab-pane" id="rooms" role="tabpanel" style="max-height:600px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @rooms.each do |room| %>
|
||||
<% if room.status == 'occupied' %>
|
||||
@@ -86,7 +86,7 @@
|
||||
</div>
|
||||
|
||||
<!--- Panel 3 - Orders -->
|
||||
<div class="tab-pane active" id="orders" role="tabpanel">
|
||||
<div class="tab-pane active" id="orders" role="tabpanel" style="max-height:600px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @orders.each do |order| %>
|
||||
<div class="card orders red text-white" data-id = "<%= order.order_id %>">
|
||||
@@ -140,7 +140,7 @@
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="card-text">
|
||||
<div class="card-text" style="max-height:500px; overflow:auto">
|
||||
<table class="table table-striped" id="order-items-table">
|
||||
<thead>
|
||||
<tr>
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
<p>Date: <span id="receipt_date"> <%=@sale_data.receipt_date.strftime("%d/%m/%Y - %I:%M %p") rescue '-'%></span></p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-text">
|
||||
<div class="card-text" style="min-height:500px; max-height:500px; overflow-x:scroll">
|
||||
<table class="table table-default" id="order-items-table">
|
||||
<thead>
|
||||
<tr>
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="card-text">
|
||||
<div class="card-text" style="max-height:600px; overflow:auto">
|
||||
<table class="table table-striped" id="order-items-table">
|
||||
<thead>
|
||||
<tr>
|
||||
|
||||
@@ -19,9 +19,9 @@
|
||||
</ul>
|
||||
<!-- Nav tabs - End -->
|
||||
|
||||
<div class="tab-content" style="max-height:670px; overflow:auto">
|
||||
<div class="tab-content" >
|
||||
<!--- Panel 0 - Completed Orders -->
|
||||
<div class="tab-pane" id="completed" role="tabpanel">
|
||||
<div class="tab-pane" id="completed" role="tabpanel" style="max-height:600px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @complete.each do |sale| %>
|
||||
<div class="card sales red text-white" data-id = "<%= sale.sale_id %>">
|
||||
@@ -34,7 +34,7 @@
|
||||
</div>
|
||||
|
||||
<!--- Panel 1 - Table Orders -->
|
||||
<div class="tab-pane " id="tables" role="tabpanel">
|
||||
<div class="tab-pane " id="tables" role="tabpanel" style="max-height:600px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @tables.each do |table| %>
|
||||
<% if table.status == 'occupied' %>
|
||||
@@ -65,7 +65,7 @@
|
||||
</div>
|
||||
|
||||
<!--- Panel 2 - Room Orders -->
|
||||
<div class="tab-pane active" id="rooms" role="tabpanel">
|
||||
<div class="tab-pane active" id="rooms" role="tabpanel" style="max-height:600px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @rooms.each do |room| %>
|
||||
<% if room.status == 'occupied' %>
|
||||
@@ -98,7 +98,7 @@
|
||||
</div>
|
||||
|
||||
<!--- Panel 3 - Orders -->
|
||||
<div class="tab-pane" id="orders" role="tabpanel">
|
||||
<div class="tab-pane" id="orders" role="tabpanel" style="max-height:600px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @orders.each do |order| %>
|
||||
<div class="card orders red text-white" data-id = "<%= order.order_id %>">
|
||||
@@ -148,7 +148,7 @@
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="card-text">
|
||||
<div class="card-text" style="min-height:500px; max-height:500px; overflow-x:scroll">
|
||||
<table class="table table-striped" id="order-items-table">
|
||||
<thead>
|
||||
<tr>
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="card-text">
|
||||
<div class="card-text" style="min-height:500px; max-height:500px; overflow-x:scroll">
|
||||
<table class="table " id="order-items-table">
|
||||
<thead>
|
||||
<tr>
|
||||
|
||||
@@ -19,9 +19,9 @@
|
||||
</ul>
|
||||
<!-- Nav tabs - End -->
|
||||
|
||||
<div class="tab-content" style="max-height:670px; overflow:auto">
|
||||
<div class="tab-content">
|
||||
<!--- Panel 0 - Completed Orders -->
|
||||
<div class="tab-pane active" id="completed" role="tabpanel">
|
||||
<div class="tab-pane active" id="completed" role="tabpanel" style="max-height:600px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @complete.each do |sale| %>
|
||||
<div class="card sales red text-white" data-id = "<%= sale.sale_id %>">
|
||||
@@ -34,7 +34,7 @@
|
||||
</div>
|
||||
|
||||
<!--- Panel 1 - Table Orders -->
|
||||
<div class="tab-pane " id="tables" role="tabpanel">
|
||||
<div class="tab-pane " id="tables" role="tabpanel" style="max-height:600px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @tables.each do |table| %>
|
||||
<% if table.status == 'occupied' %>
|
||||
@@ -60,7 +60,7 @@
|
||||
</div>
|
||||
|
||||
<!--- Panel 2 - Room Orders -->
|
||||
<div class="tab-pane" id="rooms" role="tabpanel">
|
||||
<div class="tab-pane" id="rooms" role="tabpanel" style="max-height:600px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @rooms.each do |room| %>
|
||||
<% if room.status == 'occupied' %>
|
||||
@@ -86,7 +86,7 @@
|
||||
</div>
|
||||
|
||||
<!--- Panel 3 - Orders -->
|
||||
<div class="tab-pane" id="orders" role="tabpanel">
|
||||
<div class="tab-pane" id="orders" role="tabpanel" style="max-height:600px; overflow:auto">
|
||||
<div class="card-columns" style="padding-top:10px; column-gap: 1.2rem;">
|
||||
<% @orders.each do |order| %>
|
||||
<div class="card orders red text-white" data-id = "<%= order.order_id %>">
|
||||
@@ -126,7 +126,7 @@
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="card-text">
|
||||
<div class="card-text" style="max-height:400px; overflow:auto">
|
||||
<table class="table table-striped" id="order-items-table">
|
||||
<thead>
|
||||
<tr>
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="card-text">
|
||||
<div class="card-text" style="max-height:600px; overflow:auto">
|
||||
<table class="table table-striped" id="order-items-table">
|
||||
<thead>
|
||||
<tr>
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
<td><%= link_to employee.name,settings_employee_path(employee) %></td>
|
||||
<td><%= employee.role %></td>
|
||||
<td>
|
||||
<%= link_to 'Edit', edit_settings_employee_path(employee) %> | <%= link_to 'Destroy', employee[:setting], method: :delete, data: { confirm: 'Are you sure?' } %></td>
|
||||
<%= link_to 'Edit', edit_settings_employee_path(employee) %> | <%= link_to 'Destroy', settings_employee_path(employee), method: :delete, data: { confirm: 'Are you sure?' } %></td>
|
||||
</tr>
|
||||
<% end %>
|
||||
</tbody>
|
||||
|
||||
@@ -205,15 +205,16 @@
|
||||
<td><%= @customer.address%></td>
|
||||
<td><%= @customer.date_of_birth %></td>
|
||||
</tr>
|
||||
<tr></tr>
|
||||
<tr>
|
||||
<th colspan="8">Membership Transactions</th>
|
||||
<th colspan="5">Membership Transactions</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Date</th>
|
||||
<th>Redeem</th>
|
||||
<th>Rebate</th>
|
||||
<th>Balance</th>
|
||||
<!-- <th>Account No</th> -->
|
||||
<th>From Account</th>
|
||||
<th>Status</th>
|
||||
<th>Receipt No</th>
|
||||
</tr>
|
||||
@@ -226,7 +227,7 @@
|
||||
<td><%= transaction["redeem"]%></td>
|
||||
<td><%= transaction["rebate"] %></td>
|
||||
<td><%= transaction["balance"] %></td>
|
||||
<!-- <td><%= transaction["account_no"] %></td> -->
|
||||
<td><%= transaction["account_status"] %></td>
|
||||
<td><%= transaction["status"] %></td>
|
||||
<td><%= transaction["receipt_no"] %></td>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user