added enrollment list
Cette révision appartient à :
Parent
cc1111246a
révision
53dbee91b5
@ -13,7 +13,8 @@ class EnrollmentController extends Controller
|
||||
*/
|
||||
public function index()
|
||||
{
|
||||
//
|
||||
$enrollment = Enrollment::get();
|
||||
return view('backend.enrollment.index', compact('enrollment'));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -13,4 +13,9 @@ public function course()
|
||||
{
|
||||
return $this->belongsTo(Course::class);
|
||||
}
|
||||
|
||||
public function student()
|
||||
{
|
||||
return $this->belongsTo(Student::class);
|
||||
}
|
||||
}
|
||||
|
||||
@ -23,4 +23,9 @@ public function review()
|
||||
{
|
||||
return $this->hasMany(Review::class);
|
||||
}
|
||||
|
||||
public function enrollemnt()
|
||||
{
|
||||
return $this->hasMany(Enrollment::class);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,4 +1,9 @@
|
||||
@extends('backend.layouts.app')
|
||||
@if(fullAccess())
|
||||
@extends('backend.layouts.appInstructor')
|
||||
@endif
|
||||
@if(!fullAccess())
|
||||
@extends('backend.layouts.appInstructor')
|
||||
@endif
|
||||
@section('title', 'Coupon List')
|
||||
|
||||
@push('styles')
|
||||
|
||||
@ -1,4 +1,9 @@
|
||||
@extends('backend.layouts.app')
|
||||
@if(fullAccess())
|
||||
@extends('backend.layouts.appInstructor')
|
||||
@endif
|
||||
@if(!fullAccess())
|
||||
@extends('backend.layouts.appInstructor')
|
||||
@endif
|
||||
@section('title', 'Course List')
|
||||
|
||||
@push('styles')
|
||||
|
||||
@ -1,4 +1,9 @@
|
||||
@extends('backend.layouts.app')
|
||||
@if(fullAccess())
|
||||
@extends('backend.layouts.appInstructor')
|
||||
@endif
|
||||
@if(!fullAccess())
|
||||
@extends('backend.layouts.appInstructor')
|
||||
@endif
|
||||
@section('title', 'Course Lesson List')
|
||||
|
||||
@push('styles')
|
||||
|
||||
@ -1,4 +1,9 @@
|
||||
@extends('backend.layouts.app')
|
||||
@if(fullAccess())
|
||||
@extends('backend.layouts.appInstructor')
|
||||
@endif
|
||||
@if(!fullAccess())
|
||||
@extends('backend.layouts.appInstructor')
|
||||
@endif
|
||||
@section('title', 'Course Material List')
|
||||
|
||||
@push('styles')
|
||||
|
||||
113
resources/views/backend/enrollment/index.blade.php
Fichier normal
113
resources/views/backend/enrollment/index.blade.php
Fichier normal
@ -0,0 +1,113 @@
|
||||
@if(fullAccess())
|
||||
@extends('backend.layouts.appInstructor')
|
||||
@endif
|
||||
@if(!fullAccess())
|
||||
@extends('backend.layouts.appInstructor')
|
||||
@endif
|
||||
@section('title', 'Enrollment List')
|
||||
|
||||
@push('styles')
|
||||
<!-- Datatable -->
|
||||
<link href="{{asset('public/vendor/datatables/css/jquery.dataTables.min.css')}}" rel="stylesheet">
|
||||
@endpush
|
||||
|
||||
@section('content')
|
||||
|
||||
<div class="content-body">
|
||||
<!-- row -->
|
||||
<div class="container-fluid">
|
||||
|
||||
<div class="row page-titles mx-0">
|
||||
<div class="col-sm-6 p-md-0">
|
||||
<div class="welcome-text">
|
||||
<h4>Enrollments</h4>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-sm-6 p-md-0 justify-content-sm-end mt-2 mt-sm-0 d-flex">
|
||||
<ol class="breadcrumb">
|
||||
<li class="breadcrumb-item"><a href="{{route('dashboard')}}">Home</a></li>
|
||||
<li class="breadcrumb-item active"><a href="{{route('enrollment.index')}}">Enrollments</a></li>
|
||||
<li class="breadcrumb-item active"><a href="{{route('enrollment.index')}}">All Enrollment</a></li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
<div class="row tab-content">
|
||||
<div id="list-view" class="tab-pane fade active show col-lg-12">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h4 class="card-title">All Enrollments List </h4>
|
||||
<a href="{{route('enrollment.create')}}" class="btn btn-primary">+ Add new</a>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<div class="table-responsive">
|
||||
<table id="example3" class="display" style="min-width: 845px">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{{__('#')}}</th>
|
||||
<th>{{__('Student Name')}}</th>
|
||||
<th>{{__('Course Name')}}</th>
|
||||
<th>{{__('Course Image')}}</th>
|
||||
<th>{{__('Course Value')}}</th>
|
||||
<th>{{__('Enrollment Date')}}</th>
|
||||
<th>{{__('Action')}}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@forelse ($enrollment as $e)
|
||||
<tr>
|
||||
<td><img class="rounded-circle" width="35" height="35"
|
||||
src="{{asset('public/uploads/students/'.$e->student?->image)}}"
|
||||
alt="">
|
||||
</td>
|
||||
<td><strong>{{$e->student?->name_en}}</strong></td>
|
||||
<td><strong>{{$e->course?->title_en}}</strong></td>
|
||||
<td><img class="img fluid" width="100"
|
||||
src="{{asset('public/uploads/courses/'.$e->course?->image)}}"
|
||||
alt="">
|
||||
</td>
|
||||
<td><strong>{{$e->course?->price==null?'Free':'৳'.$e->course?->price}}</strong></td>
|
||||
<td><strong>{{$e->enrollment_date}}</strong></td>
|
||||
<td>
|
||||
<a href="{{route('enrollment.edit', encryptor('encrypt',$e->id))}}"
|
||||
class="btn btn-sm btn-primary" title="Edit"><i
|
||||
class="la la-pencil"></i></a>
|
||||
<a href="javascript:void(0);" class="btn btn-sm btn-danger"
|
||||
title="Delete" onclick="$('#form{{$e->id}}').submit()"><i
|
||||
class="la la-trash-o"></i></a>
|
||||
<form id="form{{$e->id}}"
|
||||
action="{{route('enrollment.destroy', encryptor('encrypt',$e->id))}}"
|
||||
method="post">
|
||||
@csrf
|
||||
@method('DELETE')
|
||||
</form>
|
||||
</td>
|
||||
</tr>
|
||||
@empty
|
||||
<tr>
|
||||
<th colspan="6" class="text-center">No Enrollment Found</th>
|
||||
</tr>
|
||||
@endforelse
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<!-- Datatable -->
|
||||
<script src="{{asset('public/vendor/datatables/js/jquery.dataTables.min.js')}}"></script>
|
||||
<script src="{{asset('public/js/plugins-init/datatables.init.js')}}"></script>
|
||||
|
||||
@endpush
|
||||
@ -1,4 +1,9 @@
|
||||
@extends('backend.layouts.app')
|
||||
@if(fullAccess())
|
||||
@extends('backend.layouts.appInstructor')
|
||||
@endif
|
||||
@if(!fullAccess())
|
||||
@extends('backend.layouts.appInstructor')
|
||||
@endif
|
||||
@section('title', 'Instructor List')
|
||||
|
||||
@push('styles')
|
||||
|
||||
@ -229,6 +229,7 @@ class="las la-chalkboard-teacher"></i>Instructors</a>
|
||||
<li><a href="{{route('course.index')}}"><i class="las la-book-open"></i>All Courses</a></li>
|
||||
<li><a href="{{route('lesson.index')}}"><i class="las la-chalkboard"></i>Lessons</a></li>
|
||||
<li><a href="{{route('material.index')}}"><i class="las la-atom"></i></i>Materials</a></li>
|
||||
<li><a href="{{route('enrollment.index')}}"><i class="las la-bullseye"></i>Enrollments</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a class="has-arrow" href="javascript:void()" aria-expanded="false">
|
||||
|
||||
@ -205,6 +205,7 @@ class="feather feather-log-out">
|
||||
<li><a href="{{route('lesson.index')}}"><i class="las la-chalkboard"></i>Course Lessons</a></li>
|
||||
<li><a href="{{route('material.index')}}"><i class="las la-atom"></i></i>Course Materials</a></li>
|
||||
<li><a href="{{route('coupon.index')}}"><i class="las la-tags"></i>Coupons</a></li>
|
||||
<li><a href="{{route('enrollment.index')}}"><i class="las la-bullseye"></i>Enrollments</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -1,4 +1,9 @@
|
||||
@extends('backend.layouts.app')
|
||||
@if(fullAccess())
|
||||
@extends('backend.layouts.appInstructor')
|
||||
@endif
|
||||
@if(!fullAccess())
|
||||
@extends('backend.layouts.appInstructor')
|
||||
@endif
|
||||
@section('title', 'Student List')
|
||||
|
||||
@push('styles')
|
||||
|
||||
@ -25,6 +25,7 @@
|
||||
use App\Http\Controllers\CouponController as coupon;
|
||||
use App\Http\Controllers\WatchCourseController as watchCourse;
|
||||
use App\Http\Controllers\LessonController as lesson;
|
||||
use App\Http\Controllers\EnrollmentController as enrollment;
|
||||
|
||||
/* students */
|
||||
use App\Http\Controllers\Students\AuthController as sauth;
|
||||
@ -71,6 +72,7 @@
|
||||
Route::resource('discussion', discussion::class);
|
||||
Route::resource('message', message::class);
|
||||
Route::resource('coupon', coupon::class);
|
||||
Route::resource('enrollment', enrollment::class);
|
||||
Route::get('permission/{role}', [permission::class, 'index'])->name('permission.list');
|
||||
Route::post('permission/{role}', [permission::class, 'save'])->name('permission.save');
|
||||
});
|
||||
|
||||
Chargement…
Référencer dans un nouveau ticket
Block a user