@php use App\Http\Controllers\facultyController; @endphp @extends('layouts.master') @section('title', 'Import Faculty') @section('style') @endsection @section('script') @endsection @section('content') @include('layouts.header') @include('layouts.title')
Import Faculty
{{-- Add --}}
{{ csrf_field() }}
File Import :
(.xlsx only)

@if (!empty($data)) @php $error_array = array() @endphp @foreach ($data as $key => $new_data) @if (facultyController::check_schools(trim($new_data->faculty_school)) == 0) @php $error_array[] = 'Check the name of School.' @endphp @endif @endforeach @if (count($error_array) == 0) @else

@php $error_array = array_unique($error_array) @endphp @foreach ($error_array as $error)
  • {{ $error }}
  • @endforeach @endif @endif

    @if (isset($show))
    @if (!empty($data)) @foreach ($data as $key => $new_data) @endforeach @endif
    No. Title First Name Last Name E-mail School
    {{ ++$key }} {{ $new_data->faculty_title }} {{ $new_data->faculty_firstname }} {{ $new_data->faculty_lastname }} {{ $new_data->faculty_email }} @if (facultyController::check_schools(trim($new_data->faculty_school)) == 0) {{ $new_data->faculty_school }} @else {{ $new_data->faculty_school }} @endif
    @endif
    @include('layouts.footer') @endsection