diff --git a/app/controllers/origami/card_payments_controller.rb b/app/controllers/origami/card_payments_controller.rb deleted file mode 100644 index 2df4b266..00000000 --- a/app/controllers/origami/card_payments_controller.rb +++ /dev/null @@ -1,10 +0,0 @@ -class Origami::CardPaymentsController < BaseOrigamiController - - - def index - end - - def create - end - -end diff --git a/app/controllers/origami/others_payments_controller.rb b/app/controllers/origami/others_payments_controller.rb new file mode 100644 index 00000000..e92c9535 --- /dev/null +++ b/app/controllers/origami/others_payments_controller.rb @@ -0,0 +1,10 @@ +class Origami::OthersPaymentsController < BaseOrigamiController + + + def index + end + + def create + end + +end diff --git a/app/controllers/origami/payments_controller.rb b/app/controllers/origami/payments_controller.rb index f64e27e3..45b03c79 100644 --- a/app/controllers/origami/payments_controller.rb +++ b/app/controllers/origami/payments_controller.rb @@ -5,13 +5,17 @@ class Origami::PaymentsController < BaseOrigamiController end def create - #payment type - #sale status - #point - get [ food amount ] + cash = params[:cash] + card = params[:card] + + #process_payment(invoice, action_by) end def show - + sale_id = params[:sale_id] + if Sale.exists?(sale_id) + @sale_data = Sale.find_by_sale_id(sale_id) + end end end diff --git a/app/controllers/origami/request_bills_controller.rb b/app/controllers/origami/request_bills_controller.rb index 31766599..9e14e9ea 100644 --- a/app/controllers/origami/request_bills_controller.rb +++ b/app/controllers/origami/request_bills_controller.rb @@ -25,13 +25,5 @@ class Origami::RequestBillsController < BaseOrigamiController printer.print_receipt_bill(print_settings,@sale_items,@sale,@sale_data) end - - - def show - sale_id = params[:sale_id] - if Sale.exists?(sale_id) - @sale_data = Sale.find_by_sale_id(sale_id) - end - end - + end diff --git a/app/views/origami/card_payments/index.html.erb b/app/views/origami/others_payments/index.html.erb similarity index 100% rename from app/views/origami/card_payments/index.html.erb rename to app/views/origami/others_payments/index.html.erb diff --git a/app/views/origami/request_bills/show.html.erb b/app/views/origami/payments/show.html.erb similarity index 92% rename from app/views/origami/request_bills/show.html.erb rename to app/views/origami/payments/show.html.erb index 6de89ab8..e35696d2 100644 --- a/app/views/origami/request_bills/show.html.erb +++ b/app/views/origami/payments/show.html.erb @@ -87,7 +87,7 @@