check oqs print
This commit is contained in:
@@ -28,7 +28,7 @@ class MenuItem < ApplicationRecord
|
||||
MenuItem.select("id, name").map { |e| [e.name, e.id] }
|
||||
end
|
||||
|
||||
|
||||
# Work with item_code = item_instance_code
|
||||
def self.search_by_item_code(item_code)
|
||||
menu_item_hash = Hash.new
|
||||
mt_instance = MenuItemInstance.find_by_item_instance_code(item_code)
|
||||
|
||||
@@ -93,6 +93,7 @@ class Order < ApplicationRecord
|
||||
return false
|
||||
|
||||
end
|
||||
|
||||
#Main Method - to update order / add items
|
||||
def modify
|
||||
|
||||
@@ -108,6 +109,7 @@ class Order < ApplicationRecord
|
||||
|
||||
menu_item = MenuItem.search_by_item_code(item[:item_instance_code])
|
||||
|
||||
# For Product while item code not in menu item
|
||||
if menu_item.nil?
|
||||
menu_item = Product.search_by_product_code(item[:item_instance_code])
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user