<audio id="bell" src="/ui/sounds/bell.mp3" preload="auto"></audio>
<check if="{{(int)@base_settings['show_error_executor_display']==1}}">
<audio id="show_error_executor_display" src="/ui/sounds/false.mp3" preload="auto"></audio>
</check>
<div id="display" align="center">
	<a href="/receipts/archive?time={{time()}}&kitchen={{@GET.kitchen}}&bar={{@GET.bar}}" target="_blank">
		<button class="archive_button {{@complite==0 || @create==0 || (int)@base_settings['auto_issued']==1?'archive_button_right':''}}">Архив</button>
	</a>
	<a href="/products/stoplist" target="_blank">
		<button class="stoplist_button {{@complite==0 || @create==0 || (int)@base_settings['auto_issued']==1?'stoplist_button_right':''}}">Стоп-лист</button>
	</a>
	<table class="work_table reload">
		<tr class="hover_no">
			<check if="{{@create==1}}">
			<th width="50%" height="30">
				В работе
			</th>
			</check>
			<check if="{{@complite==1 && (int)@base_settings['auto_issued']!==1}}">
			<th width="50%" height="30">
				Ожидает выдачи
			</th>
			</check>
		</tr>
		<tr class="hover_no">
			<check if="{{@create==1}}">
			<td valign="top" id="orders_create">
				
			</td>
			</check>
			<check if="{{@complite==1 && (int)@base_settings['auto_issued']!==1}}">
			<td valign="top" id="orders_complite">
				
			</td>
			</check>
		</tr>
	</table>
	<div id="executor_display_settings">
		<table width="100%">
			<tr>
				<td>
					<b>Отображать:</b>
				</td>
				<td>
					<label for="show_order_create">
						заказы в работе
					</label>
					<div class="switch">
						<input type="checkbox" name="create" id="show_order_create" value="1" {{(int)@COOKIE.show_order_create==1?'checked="checked"':''}}>
					</div>
				</td>
				<td>
					<label for="show_order_complite">
						заказы к выдаче
					</label>
					<div class="switch">
						<input type="checkbox" name="complite" id="show_order_complite" value="1" {{(int)@COOKIE.show_order_complite==1?'checked="checked"':''}}>
					</div>
				</td>
				<td>
					<label for="show_order_kitchen">
						заказы для кухни
					</label>
					<div class="switch">
						<input type="checkbox" name="kitchen" id="show_order_kitchen" value="1" {{(int)@COOKIE.show_order_kitchen==1?'checked="checked"':''}}>
					</div>
				</td>
				<td class="id_kitchen {{(int)@COOKIE.show_order_kitchen!=1?'hide':''}}">
					ID кухни
					<input type="number" value="{{@COOKIE.id_kitchen?@COOKIE.id_kitchen:0}}" name="id_kitchen" id="id_kitchen">
				</td>
				<td>
					<label for="show_order_bar">
						заказы для бара
					</label>
					<div class="switch">
						<input type="checkbox" name="bar" id="show_order_bar" value="1" {{(int)@COOKIE.show_order_bar==1?'checked="checked"':''}}>
					</div>
				</td>
				<td class="id_bar {{(int)@COOKIE.show_order_bar!=1?'hide':''}}">
					ID бара
					<input type="number" value="{{@COOKIE.id_bar?@COOKIE.id_bar:0}}" name="id_bar" id="id_bar">
				</td>
				<td>
					<label for="show_order_bar">
						Включить построчное выполнение
					</label>
					<div class="switch">
						<input type="checkbox" name="order_line_ok" id="order_line_ok" value="1" {{(int)@COOKIE.order_line_ok==1?'checked="checked"':''}}>
					</div>
				</td>
			</tr>
		</table>
	</div>
</div>
<div class="hide" id="order_tmp">
	<div class="order" id="@div_id">
		<table width="100%">
			<tr class="h">
				<td>
					<h2>@order_number</h2>
						Очередь @turn_number
					<check if="{{@base_settings['cafe_mode']>0}}">
					<br>
					<small>Зал @room_title Стол @table_title</small>
					</check>
					<span class="right">@create_order_time</span>
				</td>
				<td width="100" align="right" colspan="2">
					<form action="/receipts/@action_type" method="GET" timeout="3000" showerror="0">
						<input type="hidden" name="id" value="@order_id">
						<input type="hidden" name="show_kitchen" value="{{@COOKIE.show_order_kitchen}}">
						<input type="hidden" name="id_kitchen" value="{{@COOKIE.id_kitchen}}">
						<input type="hidden" name="show_bar" value="{{@COOKIE.show_order_bar}}">
						<input type="hidden" name="id_bar" value="{{@COOKIE.id_bar}}">
						<input type="hidden" name="turn" value="@turn_number">
						<input type="hidden" name="issued" value="{{@base_settings['auto_issued']}}">
						<input type="hidden" name="ip" value="@cashbox_ip">
						<button type="submit">@button</button>
					</form>
				</td>
			</tr>
			<tr>
				<td colspan="3">
					<small class="order_description_@order_number">@order_description</small>
				</td>
			</tr>
		</table>
	</div>
</div>
<table class="hide" id="orderline_tmp">
	<tbody>
		<tr class="hover_no line new_line line_@line_id">
			<td>
				<b>@line_title</b>
			</td>
			<td width="10" align="center">
				X
			</td>
			<td width="90" align="right">
				@line_count
			</td>
		</tr>
		<tr class="modifiers_add_@line_id hide"><td colspan="3"></td></tr>
		<tr class="order_line_ok_tr_@line_id {{!@COOKIE.order_line_ok?'hide':''}}">
			<td colspan="3">
				<form action="/receipts/@action_type_line" class="line_order_form" method="GET" timeout="3000" showerror="0">
					<input type="hidden" name="id" value="@line_id">
					<input type="hidden" name="ip" value="@cashbox_ip">
					<button type="submit" class="line_order_submit">@button</button>
				</form>
			</td>
		</tr>
	</tbody>
</table>
<table class="hide" id="orderline_modifiers_tmp">
	<tbody>
		<tr class="hover_no line tree last_tree new_line line_@line_id modifiers_@parent_id">
			<td>
				<b>@line_title</b>
			</td>
			<td width="10" align="center">
				X
			</td>
			<td width="90" align="right">
				@line_count
			</td>
		</tr>
	</tbody>
</table>
<script type="text/javascript">
var json=1;
var orders_display_url='/receipts/executor_display?json=1&{{@QUERY|raw}}';
synchronization_start=0;
</script>
<script type="text/javascript" src="/ui/scripts/orders_display.js?v={{@site_version}}"></script>
