From 6ae451f2bc8717a6f51d488e3c80f929b74df26a Mon Sep 17 00:00:00 2001 From: phyusin Date: Mon, 19 Feb 2018 17:23:39 +0630 Subject: [PATCH] check split bill --- app/controllers/origami/home_controller.rb | 6 ++++++ app/controllers/origami/surveys_controller.rb | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/app/controllers/origami/home_controller.rb b/app/controllers/origami/home_controller.rb index 0e3eef26..3a7501e6 100755 --- a/app/controllers/origami/home_controller.rb +++ b/app/controllers/origami/home_controller.rb @@ -123,6 +123,12 @@ class Origami::HomeController < BaseOrigamiController #for bank integration @checkout_time = Lookup.collection_of('checkout_time') @checkout_alert_time = Lookup.collection_of('checkout_alert_time') + + lookup_spit_bill = Lookup.collection_of('split_bill') + @split_bill = 0 + if !lookup_spit_bill[0].nil? + @split_bill = lookup_spit_bill[0][1] + end end #Shop Name in Navbor diff --git a/app/controllers/origami/surveys_controller.rb b/app/controllers/origami/surveys_controller.rb index b49359e0..0baec650 100644 --- a/app/controllers/origami/surveys_controller.rb +++ b/app/controllers/origami/surveys_controller.rb @@ -71,7 +71,7 @@ class Origami::SurveysController < BaseOrigamiController survey = Survey.new survey.dining_name = dining_facility.name survey.receipt_no = params[:receipt_no] - survey.shift_id = shift_by_terminal.id + survey.shift_id = shift_by_terminal.id survey.created_by = current_user.name survey.total_customer = params[:total_customer] survey.total_amount = params[:total_amount]