@extends('layouts.master') @section('content')
@csrf
{{ generateDropdown($exams, 'class="form-control exam_id" id="exam_id" name="exam_id" required', $exam_id, 'Exam') }}
{{ generateDropdown($academicYears, 'name="academic_year" class="form-control academic_year" id="academic_year" required', $academic_year, "Year") }}
{{ generateDropdown($shifts, 'class="form-control shift_id" id="shift_id" name="shift_id" ', $shift_id, "Shift") }}
{{ generateDropdown($studentClasses, 'class="form-control select2 student_class" id="student_class" name="student_class_id" required', $student_class_id, "Class") }}
{{ generateDropdown([], 'class="form-control section_id" id="section_id" name="section_id" ', $section_id, "Section") }}
{{ generateDropdown($groups, 'class="form-control group_id" id="group_id" name="group_id"', $group_id, 'Group') }}
@if(isset($students) && !$students->isEmpty())
Mark Sheet (Total Result: {{count($students)}})
{{-- --}}
@php $grades_str = ''; foreach ($grades as $grade){ $grades_str .= " $grade->mark_from-$grade->mark_to $grade->name $grade->remark "; } $head_marks_array = json_decode($assignedMarksHead->first(), true); $head_id_array = array_keys($head_marks_array); $subject_head_marks = $assignedMarksHead; $highest_grand_total_obtain = 0; @endphp @foreach ($students as $key=>$student) @php $grand_total = 0; $grand_total_obtain = 0; $fail_count = 0; $exam = $exams[$exam_id] ?? ""; $head_wise_grand_total = []; $section = $sections[$student->section_id] ?? ""; $class = $studentClasses[$student->student_class_id] ?? ""; $academicYear = $academicYears[$academic_year] ?? ""; $examRecords = $student?->examRecords ?? ""; @endphp @if ($examRecords->isNotEmpty())

Jabalunnur Al-Jamiatul Islamia

{{-- Academic Transcript --}}
Student Information
ID {{$student->student_id_no}}
Name {{$student->first_name}} {{$student->last_name}}
Session {{$academicYear}}
Class {{$class}}
Section {{$section}}
Roll {{$student->class_roll}}
{!!$grades_str!!}
Grade Referance
Marks(%) Grade Comments
@if (isset($head_id_array)) @foreach ($markHeads as $head) @if (in_array($head->id,$head_id_array)) @endif @endforeach @endif @foreach ($examRecords as $recoards) @php $full_marks = 0; $head_wise_total_obtain = []; $total_marks_obtain = 0; $head_records_str = ''; $head_wise_marks_record = json_decode($recoards->head_wise_marks); $head_marks_data = $subject_head_marks[$recoards->subject->id]; $head_marks_array = json_decode($head_marks_data); @endphp @if (isset($head_wise_marks_record)) @foreach ($markHeads as $head) @if (in_array($head->id,$head_id_array)) @php $full_marks += $head_marks_array->{$head?->id}; $head_records_str .= ""; $total_marks_obtain += $head_wise_marks_record?->{$head?->id} ?? 0; $head_wise_grand_total[$head?->id] = ($head_wise_grand_total[$head?->id] ?? 0) + ($head_wise_marks_record?->{$head?->id} ?? 0); @endphp @endif @endforeach {!!$head_records_str!!} @php $grand_total_obtain += $total_marks_obtain; $grand_total += $full_marks; @endphp @endif @php $subject_grade_name = ""; $grade_name_remarks = ""; $total_percentage = ($total_marks_obtain>0 && $full_marks>0) ? round((($total_marks_obtain*100)/$full_marks)) : 0; foreach ($grades as $grade){ if($grade->mark_from<=$total_percentage && $grade->mark_to>=$total_percentage){ $subject_grade_name = $grade->name; if($subject_grade_name=='F'){ $fail_count++; } } } @endphp @endforeach @php if ($grand_total_obtain > $highest_grand_total_obtain) { $highest_grand_total_obtain = $grand_total_obtain; } @endphp @foreach ($markHeads as $head) @if (in_array($head->id,$head_id_array)) @endif @endforeach @php $grade_name = ""; $grade_name_remarks = ""; $grand_total_percentage = ($grand_total_obtain>0 && $grand_total>0) ? round((($grand_total_obtain*100)/$grand_total)) : 0; foreach ($grades as $grade){ if($grade->mark_from<=$grand_total_percentage && $grade->mark_to>=$grand_total_percentage){ $grade_name = $grade->name; $grade_name_remarks = $grade->remark; } } @endphp
Subject Full
Marks
{{$exam}}
{{$head->short_name}}Total Obt. Grade Heighest marks
{{$recoards->subject->subject_name}}".($head_wise_marks_record?->{$head?->id} ?? "-")."{{$full_marks}}{{$total_marks_obtain}}{{ $subject_grade_name }} {{-- @dd($highest_marks_array) --}} @if (array_key_exists($recoards->subject->id, $highest_marks_array)) {{round($highest_marks_array[$recoards->subject->id])}} @endif
Grand Total {{$grand_total}}{{$head_wise_grand_total[$head->id]}} {{$grand_total_obtain}}
Percentage {{round($grand_total_percentage,2)}}%
Grade @if ($fail_count>0) F @else {{$grade_name}} @endif
Working Days 80
Present {{""}}
Absent {{""}}
Remarks
Result Published {{$publish_date}}
Conduct
Moral Development
Discipline
Hand Writing
General Remark {{$grade_name_remarks}}
Class Teacher's Signature Principle's Signature Guardian's Signature
@endif @endforeach
@endif @endsection @section('scripts') @endsection