Conceptual architectural change for CLI user app
This commit is contained in:
@@ -34,5 +34,14 @@ module Users
|
||||
obj[:ok] = true unless obj.has_key?(:ok)
|
||||
obj
|
||||
end
|
||||
|
||||
def new_order_product_orders
|
||||
case params[:product_orders]
|
||||
when String then JSON.parse(params[:product_orders]) rescue []
|
||||
when Hash then params[:product_orders].values
|
||||
else
|
||||
[]
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user