From b8c87fda6c92bc55c271c93cb0e27a203c62da26 Mon Sep 17 00:00:00 2001 From: phyusin Date: Tue, 2 Oct 2018 11:24:32 +0630 Subject: [PATCH] check status --- .../api/order_reserve/order_reservation_controller.rb | 2 +- app/views/origami/reservation/index.html.erb | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/controllers/api/order_reserve/order_reservation_controller.rb b/app/controllers/api/order_reserve/order_reservation_controller.rb index fc05fe20..aa157a2c 100644 --- a/app/controllers/api/order_reserve/order_reservation_controller.rb +++ b/app/controllers/api/order_reserve/order_reservation_controller.rb @@ -131,7 +131,7 @@ class Api::OrderReserve::OrderReservationController < Api::ApiController result = {:status=> false, :message => "Status :: "+order_reservation.status+" cann't get FOC!" } end elsif status == 'VOID' - if order_reservation.status == "ready_to_delivery" + if order_reservation.status == "ready_to_delivery" || order_reservation.status == "delivered" OrderReservation.update_order_reservation(order_reservation_id, nil, nil,nil,reason) result = {:status=> true, :message => "VOID successfully" } else diff --git a/app/views/origami/reservation/index.html.erb b/app/views/origami/reservation/index.html.erb index 1374983b..1575b1e5 100644 --- a/app/views/origami/reservation/index.html.erb +++ b/app/views/origami/reservation/index.html.erb @@ -136,10 +136,10 @@
-
+
-
+