@if($errors->any())
@foreach($errors->all() as $error)
{!! $error !!}
@endforeach
@endif
@if(session()->has('success'))
{{ session()->get('success') }}
@endif
@if(session()->has('error'))
{{ session()->get('error') }}
@endif
@if(isset($editModeData))
{{ Form::model($editModeData, array('route' => array('promotion.update', $editModeData->promotion_id), 'method' => 'PUT','files' => 'true','id' => 'promotionForm')) }}
@else
{{ Form::open(array('route' => 'promotion.store','enctype'=>'multipart/form-data','id' => 'promotionForm')) }}
@endif
{{ Form::select('employee_id', $employeeList, Input::old('employee_id'), array('class' => 'form-control employee_id required select2')) }}
{{ Form::select('current_department', $departmentList, Input::old('current_department'), array('class' => 'form-control current_department required','id'=>'current_department','style'=>'pointer-events: none')) }}
{{ Form::select('current_designation', $designationList, Input::old('current_designation'), array('class' => 'form-control current_designation required','id'=>'current_designation','style'=>'pointer-events: none')) }}
{{ Form::select('current_pay_grade', $payGradeList, Input::old('current_pay_grade'), array('class' => 'form-control current_pay_grade required ','id'=>'current_pay_grade','style'=>'pointer-events: none')) }}
{!! Form::text('current_salary',Input::old('current_salary'), $attributes = array('class'=>'form-control required current_salary','id'=>'current_salary','readonly'=>'readonly','placeholder'=>'Enter current salary')) !!}
{{ Form::select('promoted_pay_grade', $payGradeList, Input::old('promoted_pay_grade'), array('class' => 'form-control promoted_pay_grade required select2','id'=>'promoted_pay_grade')) }}
{!! Form::text('new_salary',Input::old('new_salary'), $attributes = array('class'=>'form-control required new_salary','id'=>'new_salary','readonly'=>'readonly','placeholder'=>'Enter new salary')) !!}
{{ Form::select('promoted_department', $departmentList, Input::old('promoted_department'), array('class' => 'form-control promoted_department required select2')) }}
{{ Form::select('promoted_designation', $designationList, Input::old('promoted_designation'), array('class' => 'form-control promoted_designation required select2')) }}
{!! Form::text('promotion_date',isset($editModeData) ? dateConvertDBtoForm($editModeData->promotion_date) : Input::old('promotion_date'), $attributes = array('class'=>'form-control required dateField','readonly'=>'readonly','placeholder'=>'Enter Promotion Date')) !!}
{!! Form::textarea('description',Input::old('description'), $attributes = array('class'=>'form-control description','id'=>'description','cols'=>'50','rows'=>'3','placeholder'=>'Enter description')) !!}
{{ Form::close() }}