upgrade refactor

This commit is contained in:
2016-06-02 14:40:30 +02:00
parent 1acd200408
commit eb368a31ca
25 changed files with 36 additions and 30 deletions
@@ -40,8 +40,8 @@ App.Order = DS.Model.extend
display_with_table: (->
table = t('models.table').toLowerCase()
"#{@get('display')} #{table} #{@get('list.table.number')}".htmlSafe()
).property('display', 'list.table.number')
"#{@get('display')} #{table} #{@get('list.table.table_number')}".htmlSafe()
).property('display', 'list.table.table_number')
display_tag: (->
"<span class='display order-display order-#{@get('id')} #{@get('state')}'><span class='pre-display'></span>#{@get('display')}<span class='post-display'></span></span>".htmlSafe()
@@ -18,3 +18,4 @@ App.Table = DS.Model.extend
# Casted number to use in sortBy because a numberField will
# set property number to string value (TablesIndexController)
casted_number: (-> parseInt(@get('number'))).property('number')
table_number: Ember.computed.alias('number')