@extends("admin.template") @section('content')

{{ucfirst($action)}} Ticket

{!! csrf_field() !!}
{{Form::text('title', $ticket->title, ['class'=>'form-control'])}}
@if($action !== 'create')
{{ $ticket->ticket_code }}
{{ TicketStat::$values[$ticket->stat] }}
@endif
{{Form::select('category_id', $categories, $ticket->category_id, ['class'=>'form-control', 'placeholder'=>''])}}
{{Form::select('urgency', TicketUrgency::$values, $ticket->urgency, ['id'=>'requester_id', 'class'=>'form-control', 'placeholder'=>''])}}
{{Form::select('company_id', $companies, $ticket->company_id, ['id'=>'company_id', 'class'=>'form-control', 'placeholder'=>''])}}
@if($action != 'create') {{Form::select('office_id', $offices, $ticket->office_id, ['id'=>'office_id', 'class'=>'form-control', 'placeholder'=>''])}} @else {{Form::select('office_id',[],'', ['id'=>'office_id', 'class'=>'form-control', 'placeholder'=>''])}} @endif
{{ $ticket->office_addr }}
{{ $ticket->office_postal }}
@if($action != 'create') {{Form::select('requested_by', $requesters, $ticket->requested_by, ['id'=>'requested_by', 'class'=>'form-control', 'placeholder'=>''])}} @else {{Form::select('requested_by', [], '', ['id'=>'requested_by', 'class'=>'form-control', 'placeholder'=>''])}} @endif
{{Form::text('requested_on', ViewHelper::formatDate($ticket->requested_on != ''?$ticket->requested_on:date('d M Y')), ['class'=>'form-control datepicker', 'placeholder'=>''])}}
{{Form::textarea('requester_desc', $ticket->requester_desc, ['class'=>'form-control', 'rows'=>3])}}
@if($action == 'create') {{Form::select('agent_code', $agent_codes, '', ['class'=>'form-control', 'placeholder'=>''])}} @else {{$ticket->agent_code }} @endif
{{--START Hide ticket on first time--}} @if($action != 'create' && $ticket->stat != TicketStat::Drafted)
{{Form::text('quoted_price', ViewHelper::formatNumber($ticket->quoted_price) == '0' ? '':ViewHelper::formatNumber($ticket->quoted_price), ['class'=>'form-control allow_decimal', 'step'=>".01" ])}}
{{Form::textarea('quotation_desc', $ticket->quotation_desc, ['class'=>'form-control', 'rows'=>5, 'maxlength'=>5000,'id'=>'quotation_desc'])}}
{{Form::text('quotation_no',$ticket->quotation_no,['class'=>'form-control'])}}
{{Form::text('sales_person',$ticket->sales_person,['class'=>'form-control'])}}
{{Form::text('contact_no',$ticket->contact_no,['class'=>'form-control'])}}
{{Form::text('quotation_date',$ticket->quotation_date,['class'=>'form-control'])}}
{{Form::textarea('terms_of_payment', $ticket->terms_of_payment, ['class'=>'form-control', 'rows'=>5, 'maxlength'=>5000,'id'=>'terms_of_payment'])}}
@endif {{--END Hide ticket on first time--}} @if ($ticket->stat == TicketStat::Quoted)
{{ ViewHelper::formatDate($ticket->quote_valid_till) }} (inclusive)
@endif @if($ticket->stat == TicketStat::Declined)
{{Form::text('decline_reason', ViewHelper::formatNumber($ticket->decline_reason), ['class'=>'form-control'])}}
@endif
Image / Video
Supported image formats: png, jpg, gif, video formats: wmv, avi, flv, mp4, mov, Supported document formats: pdf
Issue Expected Outcome
@{{issue.image}}
@foreach($ticket->preferred_slots as $index => $slot) @endforeach
Date Start Time End Time
@if(count($ticket->preferred_slots) !=1) @endif
@foreach($ticket->attachments as $index=>$a) @endforeach
Supported document formats: xls,pdf,doc,docs
@if(!empty($a->filename)) Attachment {{$a->filename}} @else @endif
{{--Hide ticket on first time--}} @if($action != 'create' && $ticket->stat != TicketStat::Drafted && $ticket->stat != TicketStat::Opened)
@foreach($skills as $skill_id => $name) @endforeach
@endif
{{Form::textarea('remarks', $ticket->remarks, ['class'=>'form-control', 'rows'=>5, 'maxlength'=>5000,'id'=>'remarks'])}}
@if($ticket->stat == null) @elseif($ticket->stat == TicketStat::Drafted) @elseif($ticket->stat == TicketStat::Opened) @endif @if($ticket->stat == TicketStat::Quoted)
Quotation has been sent. Waiting for customer's response.
@endif
@if($ticket->stat == TicketStat::Opened) @endif
@include('admin.ticket.history', ['ticket'=>$ticket])
@endsection @section('css') @endsection @section('script') @endsection