mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-02-14 23:47:48 +00:00
Reworking the RABL templates for simplicity AND fixing up all the tests
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
Darkswarm.factory 'Enterprises', (enterprises)->
|
||||
new class Enterprises
|
||||
constructor: ->
|
||||
@enterprises = enterprises
|
||||
@dereference()
|
||||
@@ -1,4 +1,4 @@
|
||||
Darkswarm.factory 'Hubs', ($location, hubs, $filter, CurrentHub) ->
|
||||
Darkswarm.factory 'Hubs', (hubs, $filter) ->
|
||||
new class Hubs
|
||||
constructor: ->
|
||||
@hubs = $filter('orderBy')(hubs, ['-active', '+orders_close_at'])
|
||||
|
||||
@@ -2,11 +2,4 @@ Darkswarm.factory 'Producers', (producers) ->
|
||||
new class Producers
|
||||
constructor: ->
|
||||
@producers = producers
|
||||
|
||||
# TODO: start adding functionality to producers like so
|
||||
#@producers = (@extend(producer) for producer in producers)
|
||||
|
||||
#extend: (producer)->
|
||||
#new class Producer
|
||||
#constructor: ->
|
||||
#@[k] = v for k, v of Producer
|
||||
|
||||
Reference in New Issue
Block a user