Merge branch 'master' of bitbucket.org:code2lab/sxrestaurant
This commit is contained in:
@@ -29,7 +29,12 @@ class Api::BillController < Api::ApiController
|
||||
@sale_items = SaleItem.where("sale_id=?",@sale_id)
|
||||
|
||||
unique_code = "ReceiptBillPdf"
|
||||
#shop detail
|
||||
shop_details = Shop.find(1)
|
||||
|
||||
customer= Customer.where('customer_id=' + @sale_data.customer_id)
|
||||
# get member information
|
||||
member_info = Customer.get_member_account(customer)
|
||||
|
||||
# get printer info
|
||||
print_settings=PrintSetting.find_by_unique_code(unique_code)
|
||||
@@ -38,7 +43,7 @@ class Api::BillController < Api::ApiController
|
||||
item_price_by_accounts = SaleItem.calculate_price_by_accounts(@sale_items)
|
||||
|
||||
printer = Printer::ReceiptPrinter.new(print_settings)
|
||||
printer.print_receipt_bill(print_settings,@sale_items,@sale_data,customer.name, item_price_by_accounts)
|
||||
printer.print_receipt_bill(print_settings,@sale_items,@sale_data,customer.name, item_price_by_accounts, member_info, shop_details)
|
||||
end
|
||||
|
||||
|
||||
|
||||
@@ -55,9 +55,8 @@
|
||||
<div class="table-responsive">
|
||||
<table class="table table-striped">
|
||||
<thead>
|
||||
<% puts "'''''''''''''''''''"
|
||||
puts @response
|
||||
if @response["status"] == true %>
|
||||
<%
|
||||
if @response["data"].present? %>
|
||||
<tr>
|
||||
<th colspan="5">Membership Transactions</th>
|
||||
<% if @response["status"] == true %>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<div class="page-header">
|
||||
<ul class="breadcrumb">
|
||||
<li><a href="<%= %>">Home</a></li>
|
||||
<li><a href="<%= dashboard_path %>">Home</a></li>
|
||||
<li>Daily Sale Report</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<div class="page-header">
|
||||
<ul class="breadcrumb">
|
||||
<li><a href="<%= %>">Home</a></li>
|
||||
<li><a href="<%= dashboard_path %>">Home</a></li>
|
||||
<li>Daily Sale Report</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<div class="page-header">
|
||||
<ul class="breadcrumb">
|
||||
<li><a href="<%= %>">Home</a></li>
|
||||
<li><a href="<%= dashboard_path %>">Home</a></li>
|
||||
<li>Receipt List Report</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<div class="page-header">
|
||||
<ul class="breadcrumb">
|
||||
<li><a href="<%= %>">Home</a></li>
|
||||
<li><a href="<%= dashboard_path %>">Home</a></li>
|
||||
<li>Daily Sale Report</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<div class="page-header">
|
||||
<ul class="breadcrumb">
|
||||
<li><a href="<%= %>">Home</a></li>
|
||||
<li><a href="<%= dashboard_path %>">Home</a></li>
|
||||
<li>Daily Sale Report</li>
|
||||
</ul>
|
||||
</div>
|
||||
@@ -11,13 +11,13 @@
|
||||
<hr />
|
||||
</div>
|
||||
|
||||
<div class="container">
|
||||
<!-- <div class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-12 text-right">
|
||||
<a href="javascript:export_to('<%=reports_sale_items_path%>.xls')" class = "btn btn-default">Export to Excel</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div> -->
|
||||
|
||||
<div class="container margin-top-20">
|
||||
<div class="card row">
|
||||
|
||||
@@ -13,7 +13,7 @@ module SXRestaurants
|
||||
# -- all .rb files in that directory are automatically loaded.
|
||||
config.active_record.time_zone_aware_types = [:datetime, :time]
|
||||
config.active_job.queue_adapter = :sidekiq
|
||||
config.time_zone = 'Asia/Rangoon'
|
||||
# config.time_zone = 'Asia/Rangoon'
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
@@ -131,7 +131,7 @@ menu_item_attribute_size_small = MenuItemAttribute.create({attribute_type:"size"
|
||||
menu_item_attribute_size_medium = MenuItemAttribute.create({attribute_type:"size",name: "Medium", value: "medium"})
|
||||
menu_item_attribute_size_large = MenuItemAttribute.create({attribute_type:"size", name: "Large", value: "large"})
|
||||
|
||||
shop = Shop.create({id:1, name: "Beauty In the Pot", address:'No.42-A, Sayar San Road', township:"Bahan",state:"Yangon",city:"Yangon", country:"Myanmar", phone_no:"+95(9) 252221188, +95(9) 252221177",reservation_no:"111",license:"123",
|
||||
shop = Shop.create({id:1, name: "Beauty In the Pot", address:'No.42-A, Sayar San Road, Bahan, Yangon', township:"Bahan",state:"Yangon",city:"Yangon", country:"Myanmar", phone_no:"+95(9) 252221188, +95(9) 252221177",reservation_no:"111",license:"123",
|
||||
activated_at:"2017-06-26 08:36:24",license_data:"test",base_currency:"111",id_prefix:"111"})
|
||||
#Default Order Queue stations
|
||||
# order_queue_station1 = OrderQueueStation.create({station_name: "Queue Station 1", is_active: true,printer_name: "kitchen_printer", processing_items: JSON.generate(['01001','01002','01003','01004']), print_copy:true, cut_per_item: false, use_alternate_name: false, created_by: "SYSTEM DEFAULT"})
|
||||
|
||||
Reference in New Issue
Block a user