@extends('layouts.seller') @section('css') @endsection() @section('content') @php $pageHeading = __('printers.add'); if(isset($duplicate) && $duplicate){ $pageHeading = __('printers.new_printer'); }elseif ($data->id){ $pageHeading = __('printers.edit'); } $selectedCat = [] ; if(isset($data->category) && !empty($data->category)) $selectedCat = explode(',',$data->category); $allCategoryChecked = (count($selectedCat) <= 0); @endphp
{{ Form::open(array('route' => $routes, 'method' => 'POST', 'id' => 'ajaxSave'))}}
@if (isset($duplicate) && $duplicate) {{ Form::hidden('is_duplicate', 1) }} @endif
{!! Form::label('printer_name', __('printers.printer_name')) !!} {!! Form::text('printer_name', $data->printer_name ?? '', ['class' => 'form-control']) !!}
{!! Form::label('model_name', __('printers.model_name')) !!} {!! Form::text('model_name', $data->model_name ?? '', ['class' => 'form-control']) !!}
{!! Form::label('port_name', __('printers.port_name')) !!} {!! Form::text('port_name', $data->port_name ?? '', ['class' => 'form-control','readonly' => $data->id ? true : false]) !!}
{!! Form::label('printer_for', __('printers.for')) !!} {!! Form::select('printer_for', [1 => 'Bluetooth', 2 => 'Wifi', 3 => 'USB Connected'], ($data->printer_for ?? null), ['class' => 'form-control select2']) !!}
{!! Form::label('device_id', __('printers.pos_device')) !!} {!! Form::select('device_id', $posDevices ?? [], $data->device_id ?? null, ['class' => 'form-control select2']) !!}
{!! Form::label('print_receipt_count', __('printers.receipts_count')) !!}
{!! Form::number('print_receipt_count', $data->print_receipt_count ?? 0, ['class' => 'form-control col-md-2 mx-3 text-center']) !!}
{{Form::label('status', __('printers.status'), array('class' => 'control-label'))}}
{{Form::label('full_receipt', __('printers.full_receipt'), array('class' => 'control-label'))}}
{{Form::label('kitchen_receipt', __('printers.kitchen_receipt'), array('class' => 'control-label'))}}
{{Form::label('print_web_order', __('printers.print_web_order'), array('class' => 'control-label'))}}
{{Form::label('z_report', __('printers.z_report'), array('class' => 'control-label'))}}
{{Form::label('kvittering', __('printers.kvittering'), array('class' => 'control-label'))}}
{{ Form::submit( __('common.save'), array('class' => 'btn btn-primary width80'))}}
{!! Form::label('category', __('printers.category'), ['class' => 'mt-3']) !!}
{{Form::label('category_all', __('printers.category_all'), array('class' => 'control-label mr-3 mt-3'))}}
{{Form::label('category_specific', __('printers.category_specific'), array('class' => 'control-label mr-3 mt-3'))}}
{{Form::label('specific_categories', __('printers.specific_categories'), array('class' => 'control-label'))}}
@foreach( $category as $k => $c) @php $checked = in_array($k,$selectedCat) ? '1' : '0'; @endphp
{{Form::label('', $c.' ('.$k.')', array('class' => 'control-label mr-3 mt-3 col-md-7'))}}
@endforeach
{{ Form::close()}}
@endsection @section('script') @endsection