Refactor course finder and resources templates for improved readability and functionality
- Updated course finder form to use HTML helper methods for cleaner syntax. - Enhanced form structure with better class management and attributes. - Implemented AJAX pagination for course listings to improve user experience. - Cleaned up resource template code for consistency and readability. - Ensured proper indentation and spacing for better maintainability. - Added missing target="_blank" attribute for external links in resource documents.
This commit is contained in:
@@ -93,7 +93,6 @@ class ProgramController extends Controller
|
||||
$program->tests()->sync($attachData);
|
||||
|
||||
flash()->success('Program has been created!');
|
||||
|
||||
});
|
||||
|
||||
return redirect()->route('program.index');
|
||||
@@ -148,7 +147,6 @@ class ProgramController extends Controller
|
||||
}
|
||||
|
||||
$program->tests()->sync($attachData);
|
||||
|
||||
});
|
||||
|
||||
flash()->success('program has been updated!');
|
||||
@@ -166,12 +164,10 @@ class ProgramController extends Controller
|
||||
$program->delete();
|
||||
|
||||
flash()->success('Program has been deleted!');
|
||||
|
||||
} catch (\Throwable $th) {
|
||||
flash()->error($th->getMessage());
|
||||
}
|
||||
return response()->json(['status' => 200, 'message' => 'Program has been deleted!'], 200);
|
||||
|
||||
}
|
||||
|
||||
public function getProgramByInstitution(Request $request)
|
||||
@@ -190,7 +186,6 @@ class ProgramController extends Controller
|
||||
'status' => false,
|
||||
'msg' => $th->getMessage(),
|
||||
], 500);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -206,4 +201,62 @@ class ProgramController extends Controller
|
||||
return redirect()->back()->with('error', $th->getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
public function getCoursesList(Request $request)
|
||||
{
|
||||
$data['intakes'] = Program::INTAKE;
|
||||
|
||||
$query = Program::query();
|
||||
|
||||
if ($request->filled('countries_id')) {
|
||||
$query->whereRelation('institution', 'countries_id', $request->countries_id);
|
||||
}
|
||||
|
||||
if ($request->filled('institution_id')) {
|
||||
$query->where('institutions_id', $request->institution_id);
|
||||
}
|
||||
|
||||
if ($request->filled('search')) {
|
||||
$query->where(function ($q) use ($request) {
|
||||
$q->where('keywords', 'like', "%{$request->search}%")
|
||||
->orWhere('title', 'like', "%{$request->search}%");
|
||||
});
|
||||
}
|
||||
|
||||
if ($request->filled('programlevels_id')) {
|
||||
$query->where('programlevels_id', $request->programlevels_id);
|
||||
}
|
||||
|
||||
if ($request->filled('intake_id')) {
|
||||
$query->whereJsonContains('intakes', $request->intake_id);
|
||||
}
|
||||
|
||||
if ($request->filled('preffered_location')) {
|
||||
$query->where('location', 'like', "%{$request->preffered_location}%");
|
||||
}
|
||||
|
||||
if ($request->filled('service_id')) {
|
||||
$query->whereRelation('services', 'service_id', '=', $request->service_id);
|
||||
|
||||
if ($request->filled('min_score')) {
|
||||
$query->whereRelation('services', 'min_score', '<=', $request->min_score);
|
||||
}
|
||||
|
||||
if ($request->filled('max_score')) {
|
||||
$query->whereRelation('services', 'band_score', '<=', $request->max_score);
|
||||
}
|
||||
}
|
||||
|
||||
$data['courses'] = $query
|
||||
->orderBy('title', 'asc')
|
||||
->paginate(10)
|
||||
->withQueryString();
|
||||
|
||||
$queryCount = $data['courses']->total();
|
||||
|
||||
if ($request->ajax()) {
|
||||
$view = view('client.raffles.pages.course.list', $data)->render();
|
||||
return response()->json(['html' => $view, 'queryCount' => $queryCount]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -215,7 +215,8 @@
|
||||
<h5 class="card-title">Sample Sheet</h5>
|
||||
<p class="card-text text-danger">Note: Do not change sheet header.
|
||||
</p>
|
||||
<a href="{{ asset('samples/CourseSample.xlsx') }}" class="btn btn-secondary btn-md">Download
|
||||
<a href="{{ asset('samples/CourseSample.xlsx') }}"
|
||||
class="btn btn-secondary btn-md">Download
|
||||
Sample</a>
|
||||
</div>
|
||||
</div>
|
||||
|
82
resources/views/client/raffles/pages/course/list.blade.php
Normal file
82
resources/views/client/raffles/pages/course/list.blade.php
Normal file
@@ -0,0 +1,82 @@
|
||||
@if (isset($courses))
|
||||
{{ $courses->links() }}
|
||||
@forelse ($programs as $item)
|
||||
<div class="course-finder-box">
|
||||
<div class="row">
|
||||
<div class="col col-md-2">
|
||||
<div class="sm:w-50percent w-full h-70">
|
||||
<img class="w-full h-full" src="{{ $item->institution?->image }}" alt="">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col col-md-7">
|
||||
<div class="flex flex-col gap-5">
|
||||
<h3 class="text-20 font-medium">{{ $item->title }}</h3>
|
||||
<h5 class="text-16 font-lighter">{{ $item->institution?->title }} <span
|
||||
class="text-brand">{{ $item->institution?->country?->title }}</span>
|
||||
</h5>
|
||||
<div class="flex gap-10 items-center">
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Code:</span>
|
||||
{{ !empty($item->code) ? $item->code : 'N/A' }}</h6>
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Fee:</span>
|
||||
{{ !empty($item->fee) ? $item->fee : 'N/A' }}</h6>
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Schlorship:</span>
|
||||
{{ !empty($item->scholarship) ? $item->scholarship : 'N/A' }}</h6>
|
||||
</div>
|
||||
|
||||
<div class="flex gap-10 items-center">
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Level:</span>
|
||||
{{ !empty($item->programlevel?->title) ? $item->programlevel?->title : 'N/A' }}
|
||||
</h6>
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Duration:</span>
|
||||
{{ !empty($item->year) ? $item->year : 'N/A' }}</h6>
|
||||
</h6>
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">PSW:</span>
|
||||
{{ !empty($item->psw) ? $item->psw : 'N/A' }}</h6>
|
||||
</h6>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col col-md-3">
|
||||
<div class="flex flex-col gap-10 ">
|
||||
@foreach ($item->tests as $index => $test)
|
||||
<h6 class="text-black text-16 font-medium"><span
|
||||
class="font-bold">{{ $test->title }}:</span>
|
||||
{{ $test->pivot?->min_score }}
|
||||
({{ $test->pivot?->band_score }})
|
||||
</h6>
|
||||
@endforeach
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col col-12">
|
||||
<div class="flex items-center gap-10">
|
||||
@if (!empty($item->intakes))
|
||||
<h6 class="text-16">Intake:</h6>
|
||||
@forelse ($item->intakes as $value)
|
||||
<h6 class="bg-sec text-14 text-white px-5 py-5 rounded-10 font-bold">
|
||||
{{ $intakeOptions[$value] }}</h6>
|
||||
</h6>
|
||||
@empty
|
||||
<span class="fs-13 text-muted mb-0 text-center"><span
|
||||
class="badge bg-danger p-2">N/A</span></span>
|
||||
@endforelse
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
@empty
|
||||
|
||||
<div class="text-center">
|
||||
<p class="text-danger">No Course Found !!!</p>
|
||||
</div>
|
||||
@endforelse
|
||||
{{ $programs->links() }}
|
||||
@endif
|
@@ -12,13 +12,14 @@
|
||||
deciding where and what to study abroad can be a daunting task. Don't worry, we are here to guide you during
|
||||
the entire process.</p>
|
||||
</div>
|
||||
<form id="filterForm" method="GET">
|
||||
|
||||
|
||||
{{ html()->form('GET')->route('program.index')->class(['filter-form', 'filterForm'])->attributes(['id' => 'filter-form'])->open() }}
|
||||
<div class="row">
|
||||
<div class=" col col-md-9 ">
|
||||
<div class=" course-finder-top">
|
||||
<h2 class="text-black text-center text-24 py-10">Browse Subjects</h2>
|
||||
<input class="w-full px-10 py-10" type="text" name="" id=""
|
||||
value="{{ request('search') }}" placeholder="Search Your Favourite Subjects" autocomplete="off">
|
||||
{{ html()->text('search')->value(request('search'))->placeholder('Search Program')->class('form-control px-10 py-10')->style('width: 95%;') }}
|
||||
<button type="submit" class="bg-transparent border-0"><i
|
||||
class="lqd-icn-ess icon-ld-search-2 text-24 font-bold"></i></button>
|
||||
</div>
|
||||
@@ -33,58 +34,38 @@
|
||||
<h2 class="text-22 text-center text-sec font-bold">Browse Through Category</h2>
|
||||
<div class="row">
|
||||
<div class="col col-sm-6 col-md-4">
|
||||
<select class="w-full py-10 px-5 text-14" name="country_id"
|
||||
value="{{ request('country_id') }}">
|
||||
<option value="" selected hidden>Choose Country</option>
|
||||
@foreach ($countryOptions as $key => $value)
|
||||
<option value="{{ $key }}" @selected(request('country_id') == $key)>
|
||||
{{ $value }}</option>
|
||||
@endforeach
|
||||
</select>
|
||||
{{ html()->select('country_id', $countryOptions)->value(request('country_id'))->placeholder('Select Country')->class('form-select choices-select countryDropdown w-full py-10 px-5 text-14') }}
|
||||
</div>
|
||||
|
||||
<div class="col col-sm-6 col-md-4">
|
||||
<select class=" w-full py-10 px-5 text-14" name="" id="institutionDropdown"
|
||||
name="institution_id">
|
||||
<option value="" selected>Choose Institution</option>
|
||||
@foreach ($institutionOptions as $key => $Institution)
|
||||
<option value="{{ $key }}" @selected(request('institution_id') == $key)>
|
||||
{{ $Institution }}</option>
|
||||
@endforeach
|
||||
</select>
|
||||
{{ html()->select('institution_id', $institutionOptions)->value(request('institution_id'))->placeholder('Select Institution')->class('form-select institutionDropdown w-full py-10 px-5 text-14') }}
|
||||
</div>
|
||||
|
||||
<div class="col col-sm-6 col-md-4">
|
||||
<select class=" w-full py-10 px-5 text-14" name="programlevel_id"
|
||||
value="{{ request('institution_id') }}">
|
||||
<option value="" selected hidden>Choose Level</option>
|
||||
@foreach ($programLevelOptions as $key => $Level)
|
||||
<option value="{{ $key }}" @selected(request('programlevel_id') == $key)>
|
||||
{{ $Level }}</option>
|
||||
@endforeach
|
||||
</select>
|
||||
{{ html()->select('programlevel_id', $programLevelOptions)->value(request('programlevel_id'))->placeholder('Select Program Level')->class('form-select choices-select w-full py-10 px-5 text-14') }}
|
||||
</div>
|
||||
|
||||
<div class="col col-sm-6 col-md-4">
|
||||
<select class=" w-full py-10 px-5 text-14" name="intake_id"
|
||||
value="{{ request('intake_id') }}">
|
||||
<option value="" selected hidden>Choose Intake</option>
|
||||
@foreach ($intakeOptions as $key => $Intake)
|
||||
<option value="{{ $key }}" @selected(request('intake_id') == $key)>
|
||||
{{ $Intake }}</option>
|
||||
@endforeach
|
||||
</select>
|
||||
{{ html()->select('intake_id', $intakeOptions)->value(request('intake_id'))->placeholder('Select Intake')->class('form-select choices-select w-full py-10 px-5 text-14') }}
|
||||
</div>
|
||||
|
||||
@php
|
||||
$statusList = config('constants.page_status_options');
|
||||
$hasClass = false;
|
||||
$hasStatus = false;
|
||||
|
||||
if (request()->has('class_id')) {
|
||||
$hasClass = true;
|
||||
}
|
||||
|
||||
if (request()->has('status')) {
|
||||
$hasStatus = true;
|
||||
}
|
||||
|
||||
@endphp
|
||||
|
||||
<div class="col col-sm-6 col-md-4">
|
||||
<select class=" w-full py-10 px-5 text-14" name="test_id"
|
||||
value="{{ request('test_id') }}">
|
||||
<option value="" selected hidden>Choose Class</option>
|
||||
@foreach ($testOptions as $key => $Test)
|
||||
<option value="{{ $key }}" @selected(request('test_id') == $key)>
|
||||
{{ $Test }}</option>
|
||||
@endforeach
|
||||
</select>
|
||||
{{ html()->select('test_id', $testOptions)->value(request('test_id'))->placeholder('Test Proficiency')->class('form-select choices-select w-full py-10 px-5 text-14') }}
|
||||
</div>
|
||||
|
||||
<div class="col col-sm-6 col-md-4">
|
||||
@@ -107,183 +88,96 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
|
||||
<div class="py-20">
|
||||
{{-- <div class="course-finder-box">
|
||||
<div class="row">
|
||||
<div class="col col-md-2">
|
||||
<div class="sm:w-50percent w-full h-70">
|
||||
<img class="w-full h-full" src="assets/images/general/university.jpg" alt="">
|
||||
|
||||
</div>
|
||||
{{ html()->form()->close() }}
|
||||
|
||||
|
||||
</div>
|
||||
<div class="col col-md-7">
|
||||
<div class="flex flex-col gap-5">
|
||||
<h3 class="text-20 font-medium">(STEM) Bachelor of Architecture (BArch)</h3>
|
||||
<h5 class="text-16 font-lighter">Marywood University <span class="text-brand">(USA)</span></h5>
|
||||
<div class="flex gap-10 items-center">
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Code:</span>
|
||||
BArch</h6>
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Fee:</span>
|
||||
$41,3700 per year</h6>
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Schlorship:</span> Upto
|
||||
$23,000</h6>
|
||||
</div>
|
||||
<div class="flex gap-10 items-center">
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Level:</span>
|
||||
Bachelor</h6>
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Duration:</span> N/A
|
||||
</h6>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col col-md-3">
|
||||
<div class="flex flex-col gap-10 ">
|
||||
<h6 class="text-black text-16 font-medium"><span class="font-bold">IELTS:</span>
|
||||
5.5(5.5)</h6>
|
||||
<h6 class="text-gray text-16 font-medium"><span class="font-bold">PTE:</span>
|
||||
48(48)</h6>
|
||||
<h6 class="text-gray text-16 font-medium"><span class="font-bold">Duolingo:</span>
|
||||
90 Overall</h6>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col col-12">
|
||||
<div class="flex items-center gap-10">
|
||||
<h6 class="text-16">Intake:</h6>
|
||||
<h6 class="bg-sec text-14 text-white px-5 py-5 rounded-10 font-bold">January
|
||||
</h6>
|
||||
<h6 class="bg-sec text-14 text-white px-5 py-5 rounded-10 font-bold">January
|
||||
</h6>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="data-wrapper py-20">
|
||||
<h2 class="text-22 text-center text-sec font-bold">Available Courses</h2>
|
||||
@forelse ($programs as $item)
|
||||
<div class="course-finder-box">
|
||||
<div class="row">
|
||||
<div class="col col-md-2">
|
||||
<div class="sm:w-50percent w-full h-70">
|
||||
<img class="w-full h-full" src="assets/images/general/university.jpg" alt="">
|
||||
|
||||
<img class="w-full h-full" src="{{ $item->institution?->image }}"
|
||||
alt="">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
<div class="col col-md-7">
|
||||
<div class="flex flex-col gap-5">
|
||||
<h3 class="text-20 font-medium">(STEM) Bachelor of Architecture (BArch)</h3>
|
||||
<h5 class="text-16 font-lighter">Marywood University <span class="text-brand">(USA)</span>
|
||||
<h3 class="text-20 font-medium">{{ $item->title }}</h3>
|
||||
<h5 class="text-16 font-lighter">{{ $item->institution?->title }} <span
|
||||
class="text-brand">{{ $item->institution?->country?->title }}</span>
|
||||
</h5>
|
||||
<div class="flex gap-10 items-center">
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Code:</span>
|
||||
BArch</h6>
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Fee:</span>
|
||||
$41,3700 per year</h6>
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Schlorship:</span> Upto
|
||||
$23,000</h6>
|
||||
<h6 class="text-grey font-medium text-14"><span
|
||||
class="font-bold">Code:</span>
|
||||
{{ !empty($item->code) ? $item->code : 'N/A' }}</h6>
|
||||
<h6 class="text-grey font-medium text-14"><span
|
||||
class="font-bold">Fee:</span>
|
||||
{{ !empty($item->fee) ? $item->fee : 'N/A' }}</h6>
|
||||
<h6 class="text-grey font-medium text-14"><span
|
||||
class="font-bold">Schlorship:</span>
|
||||
{{ !empty($item->scholarship) ? $item->scholarship : 'N/A' }}</h6>
|
||||
</div>
|
||||
|
||||
<div class="flex gap-10 items-center">
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Level:</span> Bachelor
|
||||
<h6 class="text-grey font-medium text-14"><span
|
||||
class="font-bold">Level:</span>
|
||||
{{ !empty($item->programlevel?->title) ? $item->programlevel?->title : 'N/A' }}
|
||||
</h6>
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Duration:</span> N/A
|
||||
<h6 class="text-grey font-medium text-14"><span
|
||||
class="font-bold">Duration:</span>
|
||||
{{ !empty($item->year) ? $item->year : 'N/A' }}</h6>
|
||||
</h6>
|
||||
<h6 class="text-grey font-medium text-14"><span
|
||||
class="font-bold">PSW:</span>
|
||||
{{ !empty($item->psw) ? $item->psw : 'N/A' }}</h6>
|
||||
</h6>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col col-md-3">
|
||||
<div class="flex flex-col gap-10 ">
|
||||
<h6 class="text-black text-16 font-medium"><span class="font-bold">IELTS:</span>
|
||||
5.5(5.5)</h6>
|
||||
<h6 class="text-gray text-16 font-medium"><span class="font-bold">PTE:</span>
|
||||
48(48)</h6>
|
||||
<h6 class="text-gray text-16 font-medium"><span class="font-bold">Duolingo:</span>
|
||||
90 Overall</h6>
|
||||
|
||||
@foreach ($item->tests as $index => $test)
|
||||
<h6 class="text-black text-16 font-medium"><span
|
||||
class="font-bold">{{ $test->title }}:</span>
|
||||
{{ $test->pivot?->min_score }}
|
||||
({{ $test->pivot?->band_score }})
|
||||
</h6>
|
||||
@endforeach
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col col-12">
|
||||
<div class="flex items-center gap-10">
|
||||
@if (!empty($item->intakes))
|
||||
<h6 class="text-16">Intake:</h6>
|
||||
<h6 class="bg-sec text-14 text-white px-5 py-5 rounded-10 font-bold">January
|
||||
</h6>
|
||||
<h6 class="bg-sec text-14 text-white px-5 py-5 rounded-10 font-bold">January
|
||||
@forelse ($item->intakes as $value)
|
||||
<h6 class="bg-sec text-14 text-white px-5 py-5 rounded-10 font-bold">
|
||||
{{ $intakeOptions[$value] }}</h6>
|
||||
</h6>
|
||||
@empty
|
||||
<span class="fs-13 text-muted mb-0 text-center"><span
|
||||
class="badge bg-danger p-2">N/A</span></span>
|
||||
@endforelse
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="course-finder-box">
|
||||
<div class="row">
|
||||
<div class="col col-md-2">
|
||||
<div class="sm:w-50percent w-full h-70">
|
||||
<img class="w-full h-full" src="assets/images/general/university.jpg" alt="">
|
||||
</div>
|
||||
</div>
|
||||
<div class="col col-md-7">
|
||||
<div class="flex flex-col gap-5">
|
||||
<h3 class="text-20 font-medium">(STEM) Bachelor of Architecture (BArch)</h3>
|
||||
<h5 class="text-16 font-lighter">Marywood University <span class="text-brand">(USA)</span>
|
||||
</h5>
|
||||
<div class="flex gap-10 items-center">
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Code:</span>
|
||||
BArch</h6>
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Fee:</span>
|
||||
$41,3700 per year</h6>
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Schlorship:</span> Upto
|
||||
$23,000</h6>
|
||||
</div>
|
||||
<div class="flex gap-10 items-center">
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Level:</span> Bachelor
|
||||
</h6>
|
||||
<h6 class="text-grey font-medium text-14"><span class="font-bold">Duration:</span> N/A
|
||||
</h6>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col col-md-3">
|
||||
<div class="flex flex-col gap-10 ">
|
||||
<h6 class="text-black text-16 font-medium"><span class="font-bold">IELTS:</span>
|
||||
5.5(5.5)</h6>
|
||||
<h6 class="text-gray text-16 font-medium"><span class="font-bold">PTE:</span>
|
||||
48(48)</h6>
|
||||
<h6 class="text-gray text-16 font-medium"><span class="font-bold">Duolingo:</span>
|
||||
90 Overall</h6>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col col-12">
|
||||
<div class="flex items-center gap-10">
|
||||
<h6 class="text-16">Intake:</h6>
|
||||
<h6 class="bg-sec text-14 text-white px-5 py-5 rounded-10 font-bold">January
|
||||
</h6>
|
||||
<h6 class="bg-sec text-14 text-white px-5 py-5 rounded-10 font-bold">January
|
||||
</h6>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div> --}}
|
||||
@empty
|
||||
<div class="text-center">
|
||||
<p class="text-danger">No Course Found !!!</p>
|
||||
</div>
|
||||
@endforelse
|
||||
{{ $programs->links() }}
|
||||
</div>
|
||||
</div>
|
||||
<div class="col col-md-3">
|
||||
@@ -293,17 +187,18 @@
|
||||
class="module-title flex flex-col h-full relative bg-size bg-no-repeat bg-center-right transition-all pt-30 pb-30 px-20 sm:mr-0 rounded-10">
|
||||
|
||||
<div class="d-flex justify-center pb-10">
|
||||
<h2 class="ld-fh-element mb-0/2em inline-block relative leading-45 -mt-0/2em text-sec text-20">
|
||||
<h2
|
||||
class="ld-fh-element mb-0/2em inline-block relative leading-45 -mt-0/2em text-sec text-20">
|
||||
Get Your Free Counselling!
|
||||
</h2>
|
||||
</div>
|
||||
|
||||
<form action="{{ route('enquiry.store') }}" method="post" id="contact-form">
|
||||
@csrf
|
||||
<input class="w-full mb-30 rounded-6 py-15 text-14 px-10 bg-light-blue border-light-grey" type="text"
|
||||
name="name" id="" placeholder="Full Name">
|
||||
<input class="w-full mb-30 rounded-6 py-15 text-14 px-10 bg-light-blue border-light-grey" type="text"
|
||||
name="phone" id="" placeholder="Phone">
|
||||
<input class="w-full mb-30 rounded-6 py-15 text-14 px-10 bg-light-blue border-light-grey"
|
||||
type="text" name="name" id="" placeholder="Full Name">
|
||||
<input class="w-full mb-30 rounded-6 py-15 text-14 px-10 bg-light-blue border-light-grey"
|
||||
type="text" name="phone" id="" placeholder="Phone">
|
||||
<input class="w-full mb-30 rounded-6 py-15 text-14 px-10 bg-light-blue border-light-grey"
|
||||
type="email" name="email" id="" placeholder="Email">
|
||||
<textarea class="w-full mb-20 rounded-6 py-15 text-14 px-10 bg-light-blue border-light-grey" name="subject"
|
||||
@@ -320,3 +215,98 @@
|
||||
<!-- form starts -->
|
||||
</div>
|
||||
@endsection
|
||||
@push('js')
|
||||
<script>
|
||||
const url = "{{ route('program.getCoursesList') }}";
|
||||
let isLoading = false;
|
||||
$(document).ready(function() {
|
||||
setTimeout(() => {
|
||||
infiniteLoadMore(1)
|
||||
}, 2000);
|
||||
})
|
||||
|
||||
// var institutionSelect = $('.institution-select').select2();
|
||||
|
||||
$(document).on('submit', '#filter-course-form', function(event) {
|
||||
event.preventDefault();
|
||||
const page = 1;
|
||||
if (!isLoading) {
|
||||
isLoading = true;
|
||||
infiniteLoadMore(page);
|
||||
}
|
||||
})
|
||||
|
||||
// $(document).on('click', '.reset-course-filter', function(event) {
|
||||
// event.preventDefault();
|
||||
// const page = 1;
|
||||
|
||||
|
||||
// $('.institution-select').val(null).trigger('change.select2');
|
||||
|
||||
// institutionSelect.select2('destroy').select2();
|
||||
|
||||
// $('#filter-course-form')
|
||||
// .find('input:not([type="hidden"]), select, textarea')
|
||||
// .val('')
|
||||
// .prop('checked', false)
|
||||
// .prop('selected', false);
|
||||
|
||||
// if (!isLoading) {
|
||||
// isLoading = true;
|
||||
// infiniteLoadMore(page);
|
||||
// }
|
||||
// })
|
||||
|
||||
$(document).on('click', '.pagination .page-link', function(event) {
|
||||
event.preventDefault();
|
||||
const page = $(this).attr('href').split('page=')[1];
|
||||
|
||||
if (!isLoading) {
|
||||
isLoading = true;
|
||||
infiniteLoadMore(page);
|
||||
}
|
||||
});
|
||||
|
||||
function infiniteLoadMore(page) {
|
||||
$.ajax({
|
||||
url: `${url}?page=${page}`,
|
||||
datatype: "html",
|
||||
type: "GET",
|
||||
data: $('#filter-course-form').serializeArray(),
|
||||
beforeSend: function() {
|
||||
$("#data-wrapper").empty();
|
||||
$('.auto-load').show();
|
||||
}
|
||||
})
|
||||
.done(function(response) {
|
||||
if (response.html == '') {
|
||||
$('#total-result').text(`Total Results: ${response.queryCount}`);
|
||||
$('.pagination').closest().parent().find('nav').hide();
|
||||
$("#data-wrapper").empty().append(`
|
||||
<div class="card">
|
||||
<div class="card-body">
|
||||
<p class="d-flex align-items-center justify-content-center">
|
||||
No data to display :(
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
`);
|
||||
$('.auto-load').hide();
|
||||
return;
|
||||
}
|
||||
|
||||
$('.auto-load').hide();
|
||||
$('#total-result').text(`Total Results: ${response.queryCount}`);
|
||||
$("#data-wrapper").empty().append(response.html);
|
||||
})
|
||||
.fail(function(jqXHR, ajaxOptions, thrownError) {
|
||||
console.log('Server error occurred');
|
||||
})
|
||||
.always(function() {
|
||||
isLoading = false;
|
||||
});
|
||||
}
|
||||
|
||||
</script>
|
||||
@endpush
|
||||
|
||||
|
@@ -1,6 +1,5 @@
|
||||
@extends('client.raffles.layouts.app')
|
||||
@section('content')
|
||||
|
||||
<div class="about-banner">
|
||||
</div>
|
||||
<section class="container py-30 free-resources">
|
||||
@@ -26,7 +25,8 @@
|
||||
data-bs-toggle="collapse" data-bs-parent="#accordion-questions"
|
||||
href="index.php#collapse-question-item-1" aria-expanded="false"
|
||||
aria-controls="collapse-question-item-1">
|
||||
<img class="w-40" src="{{asset('raffles/assets/images/icons/one.svg')}}" alt="">
|
||||
<img class="w-40" src="{{ asset('raffles/assets/images/icons/one.svg') }}"
|
||||
alt="">
|
||||
<h5 class="text-16 p-0 m-0">Countries</h5>
|
||||
</a>
|
||||
</h4>
|
||||
@@ -36,11 +36,11 @@
|
||||
data-bs-parent="#accordion-questions" role="tabpanel"
|
||||
aria-labelledby="heading-question-1">
|
||||
|
||||
@foreach($countries as $country)
|
||||
@foreach ($countries as $country)
|
||||
<div class="accordion-content text-16 leading-20 text-black bg-white px-10 flex items-center gap-10"
|
||||
onclick="showTab('tab{{$country->title}}')">
|
||||
onclick="showTab('tab{{ $country->title }}')">
|
||||
<i class="fa-solid fa-angles-right text-18 text-brand"></i>
|
||||
<p>{{$country->title}}</p>
|
||||
<p>{{ $country->title }}</p>
|
||||
</div>
|
||||
@endforeach
|
||||
|
||||
@@ -60,7 +60,8 @@
|
||||
data-bs-toggle="collapse" data-bs-parent="#accordion-questions"
|
||||
href="index.php#collapse-question-item-2" aria-expanded="false"
|
||||
aria-controls="collapse-question-item-2">
|
||||
<img class="w-40" src="{{asset('raffles/assets/images/icons/two.svg')}}" alt="">
|
||||
<img class="w-40" src="{{ asset('raffles/assets/images/icons/two.svg') }}"
|
||||
alt="">
|
||||
<h5 class="text-16 p-0 m-0">Language Test</h5>
|
||||
</a>
|
||||
</h4>
|
||||
@@ -70,11 +71,11 @@
|
||||
data-bs-parent="#accordion-questions" role="tabpanel"
|
||||
aria-labelledby="heading-question-2">
|
||||
|
||||
@foreach($tests as $test)
|
||||
@foreach ($tests as $test)
|
||||
<div class="accordion-content text-16 leading-20 text-black bg-white px-10 flex items-center gap-10"
|
||||
onclick="showTab('tab{{$test->title}}')">
|
||||
onclick="showTab('tab{{ $test->title }}')">
|
||||
<i class="fa-solid fa-angles-right text-18 text-brand"></i>
|
||||
<p>{{$test->title}}</p>
|
||||
<p>{{ $test->title }}</p>
|
||||
</div>
|
||||
@endforeach
|
||||
|
||||
@@ -93,7 +94,9 @@
|
||||
data-bs-toggle="collapse" data-bs-parent="#accordion-questions"
|
||||
href="index.php#collapse-question-item-3" aria-expanded="false"
|
||||
aria-controls="collapse-question-item-3">
|
||||
<img class="w-40" src="{{asset('raffles/assets/images/icons/three.svg')}}" alt="">
|
||||
<img class="w-40"
|
||||
src="{{ asset('raffles/assets/images/icons/three.svg') }}"
|
||||
alt="">
|
||||
<h5 class="text-16 p-0 m-0">Support Services</h5>
|
||||
</a>
|
||||
</h4>
|
||||
@@ -103,11 +106,11 @@
|
||||
data-bs-parent="#accordion-questions" role="tabpanel"
|
||||
aria-labelledby="heading-question-2">
|
||||
|
||||
@foreach($services as $service)
|
||||
@foreach ($services as $service)
|
||||
<div class="accordion-content text-16 leading-20 text-black bg-white px-10 flex items-center gap-10"
|
||||
onclick="showTab('tab{{$service->title}}')">
|
||||
onclick="showTab('tab{{ $service->title }}')">
|
||||
<i class="fa-solid fa-angles-right text-18 text-brand"></i>
|
||||
<p>{{$service->title}}</p>
|
||||
<p>{{ $service->title }}</p>
|
||||
|
||||
</div>
|
||||
@endforeach
|
||||
@@ -127,7 +130,7 @@
|
||||
<div class="second-row">
|
||||
<div class="tab-content active lg:w-full lg:text-end bg-center bg-contain bg-no-repeat -mt-20"
|
||||
style="
|
||||
background-image: url('{{asset('raffles/assets/images/demo/start-hub-1/shape-Blob.svg')}});
|
||||
background-image: url('{{ asset('raffles/assets/images/demo/start-hub-1/shape-Blob.svg') }});
|
||||
">
|
||||
|
||||
<div data-custom-animations="true"
|
||||
@@ -136,8 +139,8 @@
|
||||
<div class="content-inside">
|
||||
<div class="w-60percent h-400 mx-auto lqd-imggrp-single relative monkey-img"
|
||||
data-float="ease-in-out">
|
||||
<img class="w-full h-full " src="{{asset('raffles/assets/images/general/monkey.png')}}"
|
||||
alt="">
|
||||
<img class="w-full h-full "
|
||||
src="{{ asset('raffles/assets/images/general/monkey.png') }}" alt="">
|
||||
<div class="absolute top-30 -left-20 flex gap-10 items-center">
|
||||
<i class="fa-solid fa-arrow-left text-20 text-brand md:hiden"></i>
|
||||
<i class="fa-solid fa-arrow-up text-20 text-brand md:bloc hidden"></i>
|
||||
@@ -151,8 +154,8 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@foreach($countries as $country)
|
||||
<div class="tab-content " id="tab{{$country->title}}">
|
||||
@foreach ($countries as $country)
|
||||
<div class="tab-content " id="tab{{ $country->title }}">
|
||||
<div data-custom-animations="true"
|
||||
data-ca-options='{"animationTarget": ".content-inside", "ease": "power4.out", "initValues":{"y": "-50px", "opacity":0} , "animations":{"y": "0px", "opacity":1}}'>
|
||||
|
||||
@@ -160,7 +163,7 @@
|
||||
<div class="content-inside">
|
||||
|
||||
|
||||
<h3 class="text-brand text-30 mb-30">{{$country->title}}</h3>
|
||||
<h3 class="text-brand text-30 mb-30">{{ $country->title }}</h3>
|
||||
|
||||
<table class="">
|
||||
|
||||
@@ -168,22 +171,23 @@
|
||||
$countryDocs = $country->documents()->get();
|
||||
@endphp
|
||||
|
||||
@foreach($countryDocs as $doc)
|
||||
|
||||
@foreach ($countryDocs as $doc)
|
||||
@php
|
||||
$path = $doc->collection_name . '/' . $doc->file_path;
|
||||
$full_path = Storage::disk('public')->url($path)
|
||||
$full_path = Storage::disk('public')->url($path);
|
||||
@endphp
|
||||
|
||||
<tr>
|
||||
<td class="pl-20 text-brand text-16">{{$loop->index + 1}}</td>
|
||||
<td class="text-brand text-16">{{$doc->title}}</td>
|
||||
<td class="pl-20 text-brand text-16">{{ $loop->index + 1 }}</td>
|
||||
<td class="text-brand text-16">{{ $doc->title }}</td>
|
||||
<td class=" flex items-center justify-end gap-10">
|
||||
<a href="{{ $full_path }}" class="link-primary fs-15" download>
|
||||
<a href="{{ $full_path }}" class="link-primary fs-15"
|
||||
target="_blank">
|
||||
<button
|
||||
class="cursor-pointer px-20 py-10 bg-sec rounded-10 text-center text-white text-12 button-hover border-0">View</button>
|
||||
</a>
|
||||
<a href="{{ $full_path }}" class="link-primary fs-15" download>
|
||||
<a href="{{ $full_path }}" class="link-primary fs-15"
|
||||
download>
|
||||
<button
|
||||
class="cursor-pointer px-20 py-10 bg-green rounded-10 text-center text-white text-12 button-hover border-0">Download</button>
|
||||
</a>
|
||||
@@ -196,15 +200,15 @@
|
||||
</div>
|
||||
@endforeach
|
||||
|
||||
@foreach($tests as $test)
|
||||
<div class="tab-content " id="tab{{$test->title}}">
|
||||
@foreach ($tests as $test)
|
||||
<div class="tab-content " id="tab{{ $test->title }}">
|
||||
|
||||
<div data-custom-animations="true"
|
||||
data-ca-options='{"animationTarget": ".content-inside", "ease": "power4.out", "initValues":{"y": "-50px", "opacity":0} , "animations":{"y": "0px", "opacity":1}}'>
|
||||
|
||||
|
||||
<div class="content-inside">
|
||||
<h3 class="text-brand text-30 mb-30">{{$test->title}}</h3>
|
||||
<h3 class="text-brand text-30 mb-30">{{ $test->title }}</h3>
|
||||
|
||||
<table class="">
|
||||
|
||||
@@ -212,28 +216,28 @@
|
||||
$testDocs = $test->documents()->get();
|
||||
@endphp
|
||||
|
||||
@foreach($testDocs as $docs)
|
||||
|
||||
@foreach ($testDocs as $docs)
|
||||
@php
|
||||
$paths = $docs->collection_name . '/' . $docs->file_path;
|
||||
$full_paths = Storage::disk('public')->url($paths)
|
||||
$full_paths = Storage::disk('public')->url($paths);
|
||||
@endphp
|
||||
|
||||
<tr>
|
||||
<td class="pl-20 text-brand text-16">{{$loop->index + 1}}</td>
|
||||
<td class="text-brand text-16">{{$docs->title}}</td>
|
||||
<td class="pl-20 text-brand text-16">{{ $loop->index + 1 }}</td>
|
||||
<td class="text-brand text-16">{{ $docs->title }}</td>
|
||||
<td class=" flex items-center gap-10 justify-end">
|
||||
<a href="{{ $full_paths }}" class="link-primary fs-15" download>
|
||||
<a href="{{ $full_paths }}" class="link-primary fs-15 "
|
||||
target="_blank">
|
||||
<button
|
||||
class="cursor-pointer px-20 py-10 bg-sec rounded-10 text-center text-white text-12 button-hover border-0">View</button>
|
||||
</a>
|
||||
<a href="{{ $full_paths }}" class="link-primary fs-15" download>
|
||||
<a href="{{ $full_paths }}" class="link-primary fs-15"
|
||||
download>
|
||||
<button
|
||||
class="cursor-pointer px-20 py-10 bg-green rounded-10 text-center text-white text-12 button-hover border-0">Download</button>
|
||||
</a>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
@endforeach
|
||||
|
||||
</table>
|
||||
@@ -242,15 +246,15 @@
|
||||
</div>
|
||||
@endforeach
|
||||
|
||||
@foreach($services as $service)
|
||||
<div class="tab-content " id="tab{{$service->title}}">
|
||||
@foreach ($services as $service)
|
||||
<div class="tab-content " id="tab{{ $service->title }}">
|
||||
|
||||
<div data-custom-animations="true"
|
||||
data-ca-options='{"animationTarget": ".content-inside", "ease": "power4.out", "initValues":{"y": "-50px", "opacity":0} , "animations":{"y": "0px", "opacity":1}}'>
|
||||
|
||||
|
||||
<div class="content-inside">
|
||||
<h3 class="text-brand text-30 mb-30">{{$service->title}}</h3>
|
||||
<h3 class="text-brand text-30 mb-30">{{ $service->title }}</h3>
|
||||
|
||||
<table class="">
|
||||
|
||||
@@ -258,22 +262,23 @@
|
||||
$serviceDocs = $service->documents()->get();
|
||||
@endphp
|
||||
|
||||
@foreach($serviceDocs as $docss)
|
||||
|
||||
@foreach ($serviceDocs as $docss)
|
||||
@php
|
||||
$pathss = $docss->collection_name . '/' . $docss->file_path;
|
||||
$full_pathss = Storage::disk('public')->url($pathss)
|
||||
$full_pathss = Storage::disk('public')->url($pathss);
|
||||
@endphp
|
||||
|
||||
<tr>
|
||||
<td class="pl-20 text-brand text-16">{{$loop->index + 1}}</td>
|
||||
<td class="text-brand text-16">{{$docss->title}}</td>
|
||||
<td class="pl-20 text-brand text-16">{{ $loop->index + 1 }}</td>
|
||||
<td class="text-brand text-16">{{ $docss->title }}</td>
|
||||
<td class=" flex items-center gap-10 justify-end">
|
||||
<a href="{{ $full_pathss }}" class="link-primary fs-15" download>
|
||||
<a href="{{ $full_pathss }}" class="link-primary fs-15"
|
||||
target="_blank">
|
||||
<button
|
||||
class="cursor-pointer px-20 py-10 bg-sec rounded-10 text-center text-white text-12 button-hover border-0">View</button>
|
||||
</a>
|
||||
<a href="{{ $full_pathss }}" class="link-primary fs-15" download>
|
||||
<a href="{{ $full_pathss }}" class="link-primary fs-15"
|
||||
download>
|
||||
<button
|
||||
class="cursor-pointer px-20 py-10 bg-green rounded-10 text-center text-white text-12 button-hover border-0">Download</button>
|
||||
</a>
|
||||
@@ -299,9 +304,10 @@
|
||||
<div class="divider"></div>
|
||||
|
||||
<ul class="flex-flex-col gap-20 list-none px-0 py-20">
|
||||
@foreach($countries as $country)
|
||||
@foreach ($countries as $country)
|
||||
<li class="py-10 border-bottom text-16 text-hover"><a class="text-grey "
|
||||
href="{{route('country.single', $country->slug)}}">{{$country->title}}</a></li>
|
||||
href="{{ route('country.single', $country->slug) }}">{{ $country->title }}</a>
|
||||
</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
|
||||
|
Reference in New Issue
Block a user