Make user app better and more simple :happy:

This commit is contained in:
2014-04-01 21:37:03 +01:00
parent 14217efad3
commit 5bf9c5be59
22 changed files with 77 additions and 119 deletions
@@ -1,18 +0,0 @@
App.ListProductsForTableRoute = Ember.Route.extend {}
#setupController: (controller)->
#controller.secured ->
#src = '/user/list_products_for_table.json'
#data = {}
#$.getJSON(data_host + src, $.extend(@authentication_object, data)).then (res) =>
#if res.not_present
#@redirect_to 'index', message: 'the_list_has_been_closed'
#return
#for pc in res.categories
#product_category = @store.createRecord 'product_category',
#name: pc.name
#for pp in pc.products
#pp.id = pp._id
#pp.product_category = product_category
#product = @store.createRecord 'product', pp
#controller.set 'model', @store.all('product_category')
#debugger
@@ -1,19 +0,0 @@
App.ListProductsRoute = Ember.Route.extend
model: ->
@store.all 'product_category'
#setupController: (controller)->
#controller.secured ->
#src = '/user/list_products.json'
#data = {}
#$.getJSON(data_host + src, $.extend(@authentication_object, data)).then (res) =>
#if res.not_present
#@redirect_to 'index', message: 'the_list_has_been_closed'
#return
#for pc in res.categories
#product_category = @store.createRecord 'product_category',
#name: pc.name
#for pp in pc.products
#pp.id = pp._id
#pp.product_category = product_category
#product = @store.createRecord 'product', pp
#controller.set 'model', @store.all('product_category')