Files
openfoodnetwork/app/assets/javascripts/darkswarm/services/map.js.coffee
Will Marshall a87361d82e Merge branch 'master' into maps
Conflicts:
	app/assets/javascripts/darkswarm/services/map.js.coffee
	app/assets/javascripts/templates/map_modal.html.haml
	app/views/layouts/darkswarm.html.haml
	app/views/map/index.html.haml
	app/views/shared/menu/_large_menu.html.haml
	config/routes.rb
2014-06-06 17:21:27 +10:00

23 lines
557 B
CoffeeScript

Darkswarm.factory "OfnMap", (enterprisesForMap, MapModal)->
new class OfnMap
constructor: ->
@enterprises = (@extend(enterprise) for enterprise in enterprisesForMap)
# Adding methods to each enterprise
extend: (enterprise)->
new class MapMarker
<<<<<<< HEAD
icon: "/test.opng"
constructor: ->
@[k] = v for k, v of enterprise
reveal: =>
console.log @
=======
constructor: ->
@[k] = v for k, v of enterprise
reveal: =>
>>>>>>> master
MapModal.open @