diff --git a/app/assets/javascripts/user/quser.js.coffee b/app/assets/javascripts/user/quser.js.coffee index d651edaf..d2bd225a 100644 --- a/app/assets/javascripts/user/quser.js.coffee +++ b/app/assets/javascripts/user/quser.js.coffee @@ -358,7 +358,7 @@ class Quser else ## Offer to move table Qwaiter.confirm( - ok: -> + ok: => $.post(data_host + '/user/move_table', $.extend({table_id: table.table_id}, @authentication_object), (res2)-> if res2.occupied redirect_to 'user_root', {message: 'move_table.cannot_move_to_occupied_tabe'} @@ -393,7 +393,8 @@ class Quser cont.html('') cont.append $($('').attr('src', "#{$asset_path}spinner.gif")) cont.append $($('

').html(t('join_request.waiting_for_confirmation'))) - $.post(data_host + '/user/join_occupied_table', $.extend({table_id: table_id}, @authentication_object)) + @ensure_token => + $.post(data_host + '/user/join_occupied_table', $.extend({table_id: table_id}, @authentication_object)) #setInterval('Quser.check_if_can_join_occupied_table("'+table_id+'")', 7500) add_product: (product_id, count) -> count ||= 1 diff --git a/app/views/user/active_list.html.slim b/app/views/user/active_list.html.slim index b1de8455..16966741 100644 --- a/app/views/user/active_list.html.slim +++ b/app/views/user/active_list.html.slim @@ -1,13 +1,13 @@ = top_bar title: 'active_list.title' do + .pull-right + .table-number + .supplier-name .action-buttons = link_to content_tag(:span, t('helpers.links.place_order')), user_list_products_path, class: ['user-top-button'], id: 'place-order-on-list' span#list-needs-payment-button.user-top-button span span#list-needs-help-button.user-top-button span - .pull-right - .table-number - .supplier-name .well table#active-list-table.table thead diff --git a/app/views/user/list_products.html.slim b/app/views/user/list_products.html.slim index f689c285..bf9c2fe1 100644 --- a/app/views/user/list_products.html.slim +++ b/app/views/user/list_products.html.slim @@ -1,14 +1,13 @@ = top_bar title: 'show_products.title' do + .pull-right + .table-number + .supplier-name .action-buttons = link_to content_tag(:span, t('helpers.links.show_active_list'), list: List.model_name.human), user_active_list_path, class: ['user-top-button'], id: 'show-active-list' span#list-needs-payment-button.user-top-button span span#list-needs-help-button.user-top-button span - .pull-right - .table-number - .supplier-name - .well table#products-table.table tbody