Pull from master
This commit is contained in:
@@ -3,7 +3,12 @@ App.order = App.cable.subscriptions.create('OrderChannel', {
|
||||
|
||||
disconnected: function() {},
|
||||
|
||||
received: function(data) {
|
||||
received: function(data) {
|
||||
var hostname = location.hostname.trim();
|
||||
console.log(hostname)
|
||||
console.log(data.from)
|
||||
if(data.from == "" || hostname == data.from)
|
||||
{
|
||||
if (data.type == 'order') {
|
||||
$('.table_'+data.table.id).removeClass('green');
|
||||
$('.table_'+data.table.id).addClass('blue');
|
||||
@@ -14,6 +19,7 @@ App.order = App.cable.subscriptions.create('OrderChannel', {
|
||||
$('.new_text_'+data.table.id).html('');
|
||||
$('.new_text_'+data.table.id).removeClass('hide')
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user