@extends('layouts.app',['title' => transMsg('Register') ]) @section('content') @component('components.cropper.element',['width'=>'270','height'=>'270','type'=>'square']) @endcomponent
@if(\Auth::user()->role == 'master')
@include('layouts.master-left-menu')
@else
@include('layouts.leftside-menubar')
@endif @php $cName = school('country')->code == 'BD' ? 'Subjects' : 'Courses'; @endphp
@if(session('register_role', 'student') == 'student') @php $cancelBtnLink = url('users/'.Auth::user()->school->code.'/1/0'); $categories= \App\Category::bySchool(Auth::user()->school_id)->status()->pluck('name', 'id'); $houses = \App\House::bySchool(Auth::user()->school_id)->status()->pluck('name', 'id'); if (school('country')->code == 'BD'){ $division = (new \App\Division())->pluckDivision(); }else{ $country = \App\Country::pluck('name', 'id'); } @endphp @include('components.pages-bar',['pageTitle' =>''. trans('Students').' / '. trans('Add').'']) @include('components.sectionbar.student-bar') @endif @if(session('register_role', 'teacher') == 'teacher') @php $cancelBtnLink = route('all_index',[Auth::user()->school->code,0,1]); @endphp @include('components.pages-bar',['pageTitle' =>''. trans('Human Resource').' / '.trans('Teachers') .' / '. trans('Add').'']) @include('components.sectionbar.teacher-bar') @endif @if(session('register_role', 'staff') == 'staff') @php $cancelBtnLink = route('all_index',[Auth::user()->school->code,0,2]); @endphp @include('components.pages-bar',['pageTitle' =>''. trans('Human Resource').' / '.trans('Staff') .' / '. trans('Add').'']) @include('components.sectionbar.teacher-bar') @endif @if(session('register_role', 'accountant') == 'accountant') @include('components.sectionbar.teacher-bar') @endif @if(session('register_role', 'librarian') == 'librarian') @include('components.sectionbar.teacher-bar') @endif
@if (session('register_school_code') && auth()->user()->role == 'admin') @endif
{{ csrf_field() }} @if(session('register_role', 'student') == 'student')

@lang('Student Information') @lang(':')

@if(school('country')->code == 'BD')
@if ($errors->has('class_roll')) {{ $errors->first('class_roll') }} @endif
@endif @endif @if(\Auth::user()->role == 'master') @php $cancelBtnLink = route('schools.index'); @endphp
{!! Form::label('isSuper', trans('Super Admin'), ['class' => 'control-label']) !!} * {!! Form::select('isSuper', ['1'=>transMsg('Yes'),'0'=>transMsg('No')] , 0, ['class' => 'form-control','id' => 'isSuper']) !!} @error('isSuper')) {{ $message }} @enderror
@endif @if(session('register_role', 'staff') == 'staff' || \Auth::user()->role == 'master')
{!! Form::select('role',role(), old('role'), array('id' => 'role', 'class' => 'form-control', 'placeholder' => trans('Choose'))) !!} @error('role') {{ $message }} @enderror
{!! Form::text('role_title', NULL, array('id' => 'role_title', 'class' => 'form-control','autocomplete' => 'off')) !!} @error('role_title') {{ $message }} @enderror
@endif
@if ($errors->has('name')) {{ $errors->first('name') }} @endif
@if ($errors->has('phone_number')) {{ $errors->first('phone_number') }} @endif
@if ($errors->has('email')) {{ $errors->first('email') }} @endif
@if ($errors->has('password')) {{ $errors->first('password') }} @endif
@if(session('register_role', 'student') == 'student')
{!! Form::text('placeBirth', null, array('id' => 'placeBirth', 'class' => 'form-control', 'autocomplete'=>'off')) !!}
@if ($errors->has('birthday')) {{ $errors->first('birthday') }} @endif
@if(school('country')->code == 'BD') @php $birthcertificateNo = 'Birth Certificate No'; @endphp @elseif(school('country')->code == 'SG') @php $birthcertificateNo = 'NRIC No/Passport No'; @endphp @else @php $birthcertificateNo = 'NRIC No/Passport No'; @endphp @endif
{!! Form::text('dob_no', null, array('id' => 'dob_no', 'class' => 'form-control','autocomplete'=>'off')) !!}
{!! Form::select('section', getSectionAndClassPluck(),null, ['class' => 'select2 form-control','id'=>'section','placeholder'=>'Choose','required']) !!} @if ($errors->has('section')) {{ $errors->first('section') }} @endif
{!! Form::select('session', schoolSession(1, true), null, ['class' => 'select2 form-control','id'=>'session','required','placeholder'=>'Choose']) !!} @if ($errors->has('session')) {{ $errors->first('session') }} @endif
{!! Form::label('coursegroup_id', trans($cName.' Group'), ['class' => 'control-label']) !!} * @php $activeCourseGroup = schoolCourseGroup(1, true); @endphp {!! Form::select('coursegroup_id', $activeCourseGroup, null, ['class' => 'popTop form-control','id'=>'coursegroup_id','required','placeholder'=>'Choose']) !!} @error('coursegroup_id') {{ $message }} @enderror @if (schoolCourseGroup()->count() == 0) @lang('Note'):{{transMsg('There is no ' .$cName. ' group')}} {{transMsg('First create an '.$cName.' group')}} @endif @if ($activeCourseGroup->count() == 0 && schoolCourseGroup(2)->count()) @lang('Note') :{{transMsg('There are all '.$cName.' group Inactive')}} {{transMsg('First active '.$cName.' group')}} @endif
@endif @if(session('register_role', 'teacher') == 'teacher')
@if ($errors->has('department')) {{ $errors->first('department') }} @endif
{!! Form::select('class_teacher_section_id', getSectionAndClassPluck()->prepend('Not Class Teacher','0'),null, ['class' => 'select2 form-control','id'=>'class_teacher_section_id']) !!} @if ($errors->has('class_teacher')) {{ $errors->first('class_teacher') }} @endif
@endif
{!! Form::select('nationality',nationalityArray(), (school('country')->code == 'BD' ? 14 : (school('country')->code == 'SG' ? 159 : 3)), array('id' => 'nationality','required', 'class' => 'form-control select2', 'placeholder' => trans('Choose'))) !!} @if ($errors->has('nationality')) {{ $errors->first('nationality') }} @endif
{!! Form::select('gender',gender(), null, array('id' => 'gender', 'class' => 'form-control','required','placeholder'=>transMsg('Choose'))) !!} @if ($errors->has('gender')) {{ $errors->first('gender') }} @endif
{!!Form::select('blood_group',bloodgroup(), null, array('id' => 'blood_group', 'class' => 'form-control','placeholder'=>transMsg('N/C'))) !!} @if ($errors->has('blood_group')) {{ $errors->first('blood_group') }} @endif
@if(session('register_role', 'staff') == 'staff' || session('register_role', 'teacher') == 'teacher') @if(school('country')->code == 'SG') @php $houses = \App\House::bySchool(Auth::user()->school_id)->status()->pluck('name', 'id'); @endphp
{!! Form::label('house_id','Branch', ['class' => 'control-label']) !!} {!! Form::select('house_id', $houses , null , ['class' => 'form-control','placeholder'=>'Choose']) !!} @error('house_id') {{ $message }} @enderror
@endif
@if ($errors->has('joindate')) {{ $errors->first('joindate') }} @endif
@endif @if(session('register_role', 'student') == 'student')
{!! Form::select('religion',religon(), null, array('id' => 'religion', 'class' => 'form-control', 'placeholder' => trans('N/C'))) !!} @if ($errors->has('religion')) {{ $errors->first('religion') }} @endif
{!! Form::label('version', trans(school('country')->code == 'SG' ? 'NTIL' : 'Version'), ['class' => 'control-label']) !!} {!! Form::select('version', pluckVersion() , null , ['class' => 'form-control','placeholder'=>'Choose']) !!} @if ($errors->has('version')) {{ $errors->first('version') }} @endif
@if ($errors->has('group')) {{ $errors->first('group') }} @endif
{{--
@if ($errors->has('address')) {{ $errors->first('address') }} @endif
--}}
{!! Form::label('category_id', (school('country')->code == 'SG' ? 'Race' : 'Category'), ['class' => 'control-label']) !!} {!! Form::select('category_id', $categories , null , ['class' => 'form-control','placeholder'=>'Choose']) !!} @error('category_id') {{ $message }} @enderror
{!! Form::label('house_id', (school('country')->code == 'SG' ? 'Branch' : 'House'), ['class' => 'control-label']) !!} {!! Form::select('house_id', $houses , null , ['class' => 'form-control','placeholder'=>'Choose']) !!} @error('house_id') {{ $message }} @enderror
@if(school('country')->code == 'BD') @php $previous_school_name = 'Previous School Name'; @endphp @elseif(school('country')->code == 'SG') @php $previous_school_name = 'Name and Address of Main School'; @endphp
{!! Form::select('singaporepr',residentstatus(), null, array('id' => 'singaporepr', 'class' => 'form-control','required', 'placeholder' => trans('Choose'))) !!}
@else @php $previous_school_name = 'Previous School Name'; @endphp @endif
{!! Form::text('main_school_name_address', null, array('id' => 'main_school_name_address', 'class' => 'form-control','autocomplete' => 'off')) !!} @if ($errors->has('main_school_name_address')) {{ $errors->first('main_school_name_address') }} @endif
@if(school('country')->code == 'BD') @php $previous_class = 'Previous Class'; @endphp
{!! Form::text('previous_class' ,null, array('id' => 'previous_class', 'class' => 'form-control','autocomplete'=>'off')) !!}
{!! Form::text('last_gpa' ,null, array('id' => 'last_gpa', 'class' => 'form-control','autocomplete'=>'off')) !!}
@endif @if(school('country')->code == 'SG')
{!! Form::text('stream' ,null, array('id' => 'stream', 'class' => 'form-control','autocomplete'=>'off')) !!}
{!! Form::text('weekEnd' ,null, array('id' => 'weekEnd', 'class' => 'form-control','autocomplete'=>'off')) !!}
@endif

@lang('Guardian Information') @lang(':')

@if ($errors->has('father_name')) {{ $errors->first('father_name') }} @endif
@if ($errors->has('father_phone_number')) {{ $errors->first('father_phone_number') }} @endif
@if ($errors->has('father_national_id')) {{ $errors->first('father_national_id') }} @endif
@if ($errors->has('father_occupation')) {{ $errors->first('father_occupation') }} @endif
@if ($errors->has('father_designation')) {{ $errors->first('father_designation') }} @endif
@if ($errors->has('father_annual_income')) {{ $errors->first('father_annual_income') }} @endif
@if ($errors->has('mother_name')) {{ $errors->first('mother_name') }} @endif
@if ($errors->has('mother_phone_number')) {{ $errors->first('mother_phone_number') }} @endif
@if ($errors->has('mother_national_id')) {{ $errors->first('mother_national_id') }} @endif
@if ($errors->has('mother_occupation')) {{ $errors->first('mother_occupation') }} @endif
@if ($errors->has('mother_designation')) {{ $errors->first('mother_designation') }} @endif
@if ($errors->has('mother_annual_income')) {{ $errors->first('mother_annual_income') }} @endif

@lang('Emergency Contact Information'):

{!! Form::text('contact_person',null, array('id' => 'contact_person', 'class' => 'form-control', 'autocomplete'=>'off')) !!}
{!! Form::text('contact_person_mobile', null, array('id' => 'contact_person_mobile', 'class' => 'form-control', 'autocomplete'=>'off')) !!}
{!! Form::text('contact_person_email', null, array('id' => 'contact_person_email', 'class' => 'form-control', 'autocomplete'=>'off')) !!}
{!! Form::text('relation_with_cperson', null, array('id' => 'relation_with_cperson', 'class' => 'form-control', 'autocomplete'=>'off')) !!}
@if(school('country')->code == 'BD')

@lang('Present Address'):

{!! Form::text('present_address', null, array('id' => 'presentAddress', 'class' => 'form-control','autocomplete'=>'off')) !!}
{!! Form::text('present_post_office',null, array('id' => 'perpostoffice', 'class' => 'form-control','autocomplete'=>'off')) !!}
{!! Form::text('present_postcode', null, array('id' => 'perpostcode', 'class' => 'popTop form-control', 'autocomplete'=>'off','pattern' => '[0-9]*','title'=>'Please enter number only','maxlength'=>4,'minlength'=>4)) !!}
{!! Form::select('present_division',$division, null, array('id' => 'preDivision', 'class' => 'form-control', 'onchange'=>'getPersentDistrict(this.value)', 'placeholder' => trans('Choose'))) !!}
{!! Form::select('present_district',array(), null, array('id' => 'preDistrict', 'class' => 'form-control', 'onchange'=>'getPersentThana(this.value)', 'placeholder' => trans('Choose'))) !!}
{!! Form::select('present_thana', array(),null, array('id' => 'preThana', 'class' => 'form-control', 'placeholder' => trans('Choose'))) !!}

@lang('Permanent Address'):

{!! Form::text('permanent_address', null, array('id' => 'pastAddress', 'class' => 'form-control', 'placeholder' => trans(''),'autocomplete'=>'off')) !!}
{!! Form::text('permanent_post_office', null, array('id' => 'pastpostoffice', 'class' => 'form-control', 'placeholder' => trans(''),'autocomplete'=>'off')) !!}
{!! Form::text('permanent_postcode',null, array('id' => 'pastpostcode', 'class' => 'popTop form-control', 'placeholder' => trans(''),'autocomplete'=>'off','pattern' => '[0-9]*','title'=>'Please enter number only','maxlength'=>4,'minlength'=>4)) !!}
{!! Form::select('permanent_division',$division, null, array('id' => 'pastDivision', 'class' => 'form-control', 'onchange'=>'getPermanentDistrict(this.value)', 'placeholder' => trans('Choose'))) !!}
{!! Form::select('permanent_district',array(), null, array('id' => 'pastDistrict', 'class' => 'form-control', 'onchange'=>'getPermanentThana(this.value)', 'placeholder' => trans('Choose'))) !!}
{!! Form::select('permanent_thana', array(),null, array('id' => 'pastThana', 'class' => 'form-control', 'placeholder' => trans('Choose'))) !!}
@else

@lang('Address Information'):

{!! Form::text('street_address_1', null, array('id' => 'streetAddress_1', 'class' => 'form-control', 'placeholder' => trans(''),'autocomplete'=>'off')) !!}
{!! Form::text('street_address_2', null, array('id' => 'streetAddress_2', 'class' => 'form-control', 'placeholder' => trans(''),'autocomplete'=>'off')) !!}
{!! Form::select('country',$country, null, array('id' => 'country', 'class' => 'form-control', 'onchange'=>'getPersentstate(this.value)', 'placeholder' => trans('Choose'))) !!}
{!! Form::select('state',array(), null, array('id' => 'state', 'class' => 'form-control', 'placeholder' => trans('Choose'))) !!}
{!! Form::text('city', null, array('id' => 'city', 'class' => 'form-control', 'placeholder' => trans(''),'autocomplete'=>'off')) !!}
{!! Form::text('zipCode', null, array('id' => 'zipCode', 'class' => 'form-control', 'placeholder' => trans(''),'autocomplete'=>'off')) !!}
@endif
@if ($errors->has('about')) {{ $errors->first('about') }} @endif
@endif
@php if (foqas_setting('admission_additional_file') != '') $additional_files = explode(',',foqas_setting('admission_additional_file')); else $additional_files = []; @endphp @if(session('register_role', 'student') == 'student') @foreach($additional_files as $key => $file) @if($file != 1) @php $renderAddSlug = school('code').$file @endphp
@lang('Choose File')
@endif @endforeach @endif @if(session('register_role', 'teacher') == 'teacher')
@lang('Choose File')
@endif
@if(session('register_role', 'teacher') == 'teacher' || auth()->user()->hasRole('master'))
@push('script') @endpush @endif @if(isset($cancelBtnLink)) @elseif(session('register_branch_admin')) @endif
@endsection