2020-04-30 08:34:51 +00:00
|
|
|
@extends('Shared.Layouts.BilettmLayout',['folder' => 'desktop'])
|
|
|
|
|
@section('content')
|
|
|
|
|
{{\DaveJamesMiller\Breadcrumbs\Facades\Breadcrumbs::render('help')}}
|
|
|
|
|
|
2020-04-30 12:39:58 +00:00
|
|
|
<section class="movie-items-group firts-child my-5">
|
|
|
|
|
<div class="container">
|
|
|
|
|
<div class="row justify-content-center">
|
|
|
|
|
<div class="col-6">
|
|
|
|
|
<form action="{{route('help.create')}}" method="POST">
|
|
|
|
|
@csrf
|
2020-05-01 11:32:41 +00:00
|
|
|
|
2020-04-30 12:39:58 +00:00
|
|
|
<div class="form-group">
|
|
|
|
|
{!! Form::label('name', trans("ClientSide.name"), array('class'=>'control-label')) !!}
|
|
|
|
|
{!! Form::text('name', old('name'),array('class'=>'form-control' )) !!}
|
|
|
|
|
</div>
|
2020-05-04 11:30:25 +00:00
|
|
|
<div class="form-group {{ ($errors->has('email')) ? 'has-error' : '' }}">
|
2020-04-30 12:39:58 +00:00
|
|
|
{!! Form::label('email', trans("ClientSide.email"), array('class'=>'control-label required')) !!}
|
|
|
|
|
{!! Form::text('email', old('email'),array('class'=>'form-control' )) !!}
|
2020-05-04 11:30:25 +00:00
|
|
|
@if($errors->has('email'))
|
|
|
|
|
<p class="help-block">{{ $errors->first('email') }}</p>
|
|
|
|
|
@endif
|
2020-04-30 12:39:58 +00:00
|
|
|
</div>
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
{!! Form::label('phone', trans("ClientSide.phone"), array('class'=>'control-label')) !!}
|
|
|
|
|
{!! Form::text('phone', old('phone'),array('class'=>'form-control' )) !!}
|
|
|
|
|
</div>
|
2020-04-30 09:44:17 +00:00
|
|
|
|
2020-05-04 11:30:25 +00:00
|
|
|
<div class="form-group {{ ($errors->has('topic')) ? 'has-error' : '' }}">
|
2020-04-30 12:39:58 +00:00
|
|
|
{!! Form::label('topic', trans("ClientSide.topic"), array('class'=>'control-label')) !!}
|
2020-05-01 11:39:41 +00:00
|
|
|
{!! Form::select('topic',help_topics(), old('topic'), ['placeholder'=>trans('ClientSide.please_select'),'class' => 'form-control','id'=>'topic']) !!}
|
2020-05-04 11:30:25 +00:00
|
|
|
@if($errors->has('topic'))
|
|
|
|
|
<p class="help-block">{{ $errors->first('topic') }}</p>
|
|
|
|
|
@endif
|
2020-04-30 12:39:58 +00:00
|
|
|
</div>
|
2020-05-01 12:22:53 +00:00
|
|
|
<div class="form-group d-none">
|
2020-05-01 11:32:41 +00:00
|
|
|
{!! Form::label('subject', trans("ClientSide.subject"), array('class'=>'control-label')) !!}
|
2020-05-01 12:01:52 +00:00
|
|
|
{!! Form::text('subject', old('subject',trans('ClientSide.other')),array('class'=>'form-control' )) !!}
|
2020-05-01 11:32:41 +00:00
|
|
|
</div>
|
2020-05-04 11:30:25 +00:00
|
|
|
<div class="form-group custom-theme {{ ($errors->has('text')) ? 'has-error' : '' }}">
|
2020-04-30 12:39:58 +00:00
|
|
|
{!! Form::label('text', trans("ClientSide.text"), array('class'=>'control-label required')) !!}
|
|
|
|
|
{!! Form::textarea('text', old('text'),
|
|
|
|
|
array(
|
|
|
|
|
'class'=>'form-control editable',
|
|
|
|
|
'rows' => 5
|
|
|
|
|
)) !!}
|
2020-05-04 11:30:25 +00:00
|
|
|
@if($errors->has('text'))
|
|
|
|
|
<p class="help-block">{{ $errors->first('text') }}</p>
|
|
|
|
|
@endif
|
2020-04-30 12:39:58 +00:00
|
|
|
</div>
|
2020-05-04 11:30:25 +00:00
|
|
|
<div class="form-group {{ ($errors->has('attachment')) ? 'has-error' : '' }}">
|
2020-05-01 10:54:03 +00:00
|
|
|
{!! Form::label('attachment', trans("ClientSide.attachment"), array('class'=>'control-label')) !!}
|
|
|
|
|
{!! Form::file('attachment') !!}
|
|
|
|
|
</div>
|
2020-04-30 12:39:58 +00:00
|
|
|
{!! Form::submit(trans("ClientSide.create_ticket"), ['class'=>"btn btn-success"]) !!}
|
2020-05-04 11:30:25 +00:00
|
|
|
@if($errors->has('attachment'))
|
|
|
|
|
<p class="help-block">{{ $errors->first('attachment') }}</p>
|
|
|
|
|
@endif
|
2020-04-30 12:39:58 +00:00
|
|
|
</form>
|
2020-04-30 08:34:51 +00:00
|
|
|
</div>
|
|
|
|
|
</div>
|
2020-04-30 12:39:58 +00:00
|
|
|
</div>
|
|
|
|
|
</section>
|
2020-04-30 08:34:51 +00:00
|
|
|
@endsection
|
2020-05-01 11:32:41 +00:00
|
|
|
@section('after_scripts')
|
2020-05-01 12:01:52 +00:00
|
|
|
<script>
|
|
|
|
|
$('select[name="topic"]').on('change', function() {
|
2020-05-04 11:59:04 +00:00
|
|
|
alert(this.value);
|
|
|
|
|
if(this.options[this.selectedIndex].value == 0)
|
2020-05-01 12:22:53 +00:00
|
|
|
{
|
2020-05-01 12:28:33 +00:00
|
|
|
|
2020-05-01 12:22:53 +00:00
|
|
|
$('input[name="subject"]').parent().removeClass('d-none');
|
2020-05-01 12:30:10 +00:00
|
|
|
|
2020-05-01 12:22:53 +00:00
|
|
|
$('input[name="subject"]').val('');
|
2020-05-01 12:30:10 +00:00
|
|
|
|
2020-05-01 12:22:53 +00:00
|
|
|
}else{
|
2020-05-01 12:30:10 +00:00
|
|
|
|
2020-05-01 12:22:53 +00:00
|
|
|
$('input[name="subject"]').parent().addClass('d-none');
|
2020-05-01 12:30:10 +00:00
|
|
|
|
2020-05-02 11:01:02 +00:00
|
|
|
$('input[name="subject"]').val(this.options[this.selectedIndex].text);
|
2020-05-01 12:22:53 +00:00
|
|
|
}
|
|
|
|
|
|
2020-05-01 12:01:52 +00:00
|
|
|
});
|
|
|
|
|
</script>
|
2020-05-01 11:32:41 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
@endsection
|