Can be object or {}, it's what the injector is doing, not related to rabl any more

This commit is contained in:
Luis Ramos
2020-02-25 13:02:31 +00:00
parent 0308f1465d
commit da2598282b

View File

@@ -1,6 +1,6 @@
Darkswarm.factory 'OrderCycle', ($resource, orderCycleData) ->
class OrderCycle
@order_cycle = orderCycleData # Object or {} due to RABL
@order_cycle = orderCycleData # Object or {}
@push_order_cycle: (callback) ->
new $resource("/shop/order_cycle").save {order_cycle_id: @order_cycle.order_cycle_id}, (order_data)->
OrderCycle.order_cycle.orders_close_at = order_data.orders_close_at