From ad2dfa2ee04b2c91fdc39ad2af3c9761d34cd1e7 Mon Sep 17 00:00:00 2001 From: Yan Date: Wed, 26 Jul 2017 18:39:46 +0630 Subject: [PATCH] crm updated --- app/controllers/crm/customers_controller.rb | 3 --- app/views/crm/customers/_new_form.html.erb | 5 ++-- app/views/origami/customers/index.html.erb | 14 +++++++----- db/seeds.rb | 3 ++- dump.rdb | Bin 573 -> 574 bytes lib/tasks/menu_osaka.rake | 24 ++++++++++---------- 6 files changed, 24 insertions(+), 25 deletions(-) diff --git a/app/controllers/crm/customers_controller.rb b/app/controllers/crm/customers_controller.rb index c819af7b..b2c715ad 100644 --- a/app/controllers/crm/customers_controller.rb +++ b/app/controllers/crm/customers_controller.rb @@ -215,14 +215,11 @@ end end if response["status"] == true - customer = Customer.find(@crm_customer.customer_id) status = customer.update_attributes(membership_id: response["customer_datas"]["id"],membership_type:member_group_id ) format.html { redirect_to crm_customers_path, notice: 'Customer was successfully updated'} - else - customer = Customer.find(@crm_customer.customer_id) # Check membership id and bind to user if response["membership_id"] != nil diff --git a/app/views/crm/customers/_new_form.html.erb b/app/views/crm/customers/_new_form.html.erb index 3c09d20f..b99c25a3 100644 --- a/app/views/crm/customers/_new_form.html.erb +++ b/app/views/crm/customers/_new_form.html.erb @@ -128,10 +128,9 @@