Questions
{{-- Add Question --}}
Sl No. | Question | Answer | Class | Books | Module | Chapter | {{--Mark | Preferences | --}}Action | |
---|---|---|---|---|---|---|---|---|---|---|
{{ ($objectiveQuestions->currentPage() - 1) * $objectiveQuestions->perPage() + $index + 1 }} | {{$objectiveQuestion->question}} | {{--{{$objectiveQuestion->answer}} | --}}@php $options = [ '1' => $objectiveQuestion->option_1, '2' => $objectiveQuestion->option_2, '3' => $objectiveQuestion->option_3, '4' => $objectiveQuestion->option_4, ]; $answer = $options[$objectiveQuestion->answer] ?? 'Invalid answer'; echo $answer; @endphp | {{$objectiveQuestion->chapter->module->book->class->class_name}} | {{$objectiveQuestion->chapter->module->book->book_name}} | {{$objectiveQuestion->chapter->module->module_name}} | {{$objectiveQuestion->chapter->chapter_name}} | {{--2 | 1 | --}}
-
{{-- Previous Page Link --}}
@if ($objectiveQuestions->onFirstPage())
- Previous @else
- Previous @endif {{-- Pagination Elements --}} @foreach ($objectiveQuestions->getUrlRange(1, $objectiveQuestions->lastPage()) as $page => $url) @if ($page == $objectiveQuestions->currentPage())
- {{ $page }} @else
- {{ $page }} @endif @endforeach {{-- Next Page Link --}} @if ($objectiveQuestions->hasMorePages())
- Next @else
- Next @endif