add req bill and payment #left order and sale
This commit is contained in:
@@ -255,7 +255,14 @@ class Origami::PaymentsController < BaseOrigamiController
|
||||
def show
|
||||
path = request.fullpath
|
||||
sale_id = params[:sale_id]
|
||||
@cashier_type = params[:type]
|
||||
@trans_flag = true
|
||||
if params[:type] == "transaction"
|
||||
@trans_flag = false
|
||||
@cashier_type = "cashier"
|
||||
else
|
||||
@cashier_type = params[:type]
|
||||
end
|
||||
|
||||
if path.include? ("credit_payment")
|
||||
@sale_payment = SalePayment.get_credit_amount_due_left(sale_id)
|
||||
end
|
||||
|
||||
@@ -65,7 +65,7 @@ class Origami::RequestBillsController < ApplicationController
|
||||
ActionCable.server.broadcast "bill_channel",table: table, from: from
|
||||
if order.source == "quick_service"
|
||||
result = {:status=> @status, :data => @sale.sale_id }
|
||||
render :json => result.to_json
|
||||
render :json => result.to_json
|
||||
else
|
||||
#check checkInOut pdf print
|
||||
check_booking = Booking.find_by_sale_id(@sale_id)
|
||||
|
||||
@@ -35,7 +35,7 @@ class Transactions::BookingsController < ApplicationController
|
||||
def show
|
||||
|
||||
@booking = Booking.find(params[:id])
|
||||
|
||||
@order = []
|
||||
@order_items = []
|
||||
@booking.booking_orders.each do |booking_order|
|
||||
@order = Order.find(booking_order.order_id)
|
||||
|
||||
@@ -89,7 +89,8 @@ class Transactions::SalesController < ApplicationController
|
||||
# GET /transactions/sales/1
|
||||
# GET /transactions/sales/1.json
|
||||
def show
|
||||
|
||||
@membership = MembershipSetting::MembershipSetting
|
||||
@payment_methods = PaymentMethodSetting.where("is_active='1'")
|
||||
@sale = Sale.find(params[:id])
|
||||
|
||||
@order_items = []
|
||||
|
||||
Reference in New Issue
Block a user