Waiter app progress
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
attr = DS.attr
|
||||
App.Supplier = DS.Model.extend
|
||||
name: attr 'string'
|
||||
email: attr 'string'
|
||||
time_zone: attr 'string'
|
||||
address: attr 'string'
|
||||
house_number: attr 'number'
|
||||
house_number_addition: attr 'string'
|
||||
postal_code: attr 'string'
|
||||
city: attr 'string'
|
||||
open: attr 'boolean'
|
||||
country: attr 'string'
|
||||
facebook_promotion_url: attr 'string'
|
||||
iens_profile: attr 'string'
|
||||
lat: attr 'number'
|
||||
lng: attr 'number'
|
||||
week_starts_on_monday: attr 'boolean'
|
||||
product_categories: DS.hasMany 'product_category'
|
||||
orders_in_process_count: attr('number')
|
||||
orders_placed_count: attr('number')
|
||||
|
||||
close: ->
|
||||
$.post Routes.mark_as_closed_suppliers_supplier_path(@id), =>
|
||||
@set 'open', false
|
||||
open_the_place: ->
|
||||
$.post Routes.mark_as_open_suppliers_supplier_path(@id), =>
|
||||
@set 'open', true
|
||||
|
||||
Reference in New Issue
Block a user