pengubahan pengaturan live class
This commit is contained in:
parent
40f7a8e3c2
commit
6a0a81cc70
@ -37,20 +37,21 @@ class LiveClassController extends Controller
|
||||
]);
|
||||
|
||||
$data['class_topic'] = $request->class_topic;
|
||||
$data['link'] = $request->link;
|
||||
$data['course_id'] = $request->course_id;
|
||||
$data['user_id'] = $request->user_id;
|
||||
$data['provider'] = $request->provider;
|
||||
$data['class_date_and_time'] = date('Y-m-d\TH:i:s', strtotime($request->class_date_and_time));
|
||||
$data['note'] = $request->note;
|
||||
|
||||
if ($request->provider == 'zoom') {
|
||||
$meeting_info = $this->create_zoom_live_class($request->class_topic, $request->class_date_and_time);
|
||||
$meeting_info_arr = json_decode($meeting_info, true);
|
||||
if (array_key_exists('code', $meeting_info_arr) && $meeting_info_arr) {
|
||||
return redirect(route('admin.course.edit', ['id' => $course_id, 'tab' => 'live-class']))->with('error', get_phrase($meeting_info_arr['message']));
|
||||
}
|
||||
$data['additional_info'] = $meeting_info;
|
||||
}
|
||||
// if ($request->provider == 'zoom') {
|
||||
// $meeting_info = $this->create_zoom_live_class($request->class_topic, $request->class_date_and_time);
|
||||
// $meeting_info_arr = json_decode($meeting_info, true);
|
||||
// if (array_key_exists('code', $meeting_info_arr) && $meeting_info_arr) {
|
||||
// return redirect(route('admin.course.edit', ['id' => $course_id, 'tab' => 'live-class']))->with('error', get_phrase($meeting_info_arr['message']));
|
||||
// }
|
||||
// $data['additional_info'] = $meeting_info;
|
||||
// }
|
||||
Live_class::insert($data);
|
||||
|
||||
return redirect(route('admin.course.edit', ['id' => $course_id, 'tab' => 'live-class']))->with('success', get_phrase('Live class added successfully'));
|
||||
@ -67,17 +68,18 @@ class LiveClassController extends Controller
|
||||
]);
|
||||
|
||||
$data['class_topic'] = $request->class_topic;
|
||||
$data['link'] = $request->link;
|
||||
$data['user_id'] = $request->user_id;
|
||||
$data['class_date_and_time'] = date('Y-m-d\TH:i:s', strtotime($request->class_date_and_time));
|
||||
$data['note'] = $request->note;
|
||||
|
||||
if ($previous_meeting_data->provider == 'zoom') {
|
||||
$previous_meeting_info = json_decode($previous_meeting_data->additional_info, true);
|
||||
$this->update_zoom_live_class($request->class_topic, $request->class_date_and_time, $previous_meeting_info['id']);
|
||||
$previous_meeting_info["start_time"] = date('Y-m-d\TH:i:s', strtotime($request->class_date_and_time));
|
||||
$previous_meeting_info["topic"] = $request->class_topic;
|
||||
$data['additional_info'] = json_encode($previous_meeting_info);
|
||||
}
|
||||
// if ($previous_meeting_data->provider == 'zoom') {
|
||||
// $previous_meeting_info = json_decode($previous_meeting_data->additional_info, true);
|
||||
// $this->update_zoom_live_class($request->class_topic, $request->class_date_and_time, $previous_meeting_info['id']);
|
||||
// $previous_meeting_info["start_time"] = date('Y-m-d\TH:i:s', strtotime($request->class_date_and_time));
|
||||
// $previous_meeting_info["topic"] = $request->class_topic;
|
||||
// $data['additional_info'] = json_encode($previous_meeting_info);
|
||||
// }
|
||||
Live_class::where('id', $id)->update($data);
|
||||
|
||||
return redirect(route('admin.course.edit', ['id' => $previous_meeting_data->course_id, 'tab' => 'live-class']))->with('success', get_phrase('Live class updated successfully'));
|
||||
|
||||
@ -37,20 +37,21 @@ class LiveClassController extends Controller
|
||||
]);
|
||||
|
||||
$data['class_topic'] = $request->class_topic;
|
||||
$data['link'] = $request->link;
|
||||
$data['course_id'] = $request->course_id;
|
||||
$data['user_id'] = $request->user_id;
|
||||
$data['provider'] = $request->provider;
|
||||
$data['class_date_and_time'] = date('Y-m-d\TH:i:s', strtotime($request->class_date_and_time));
|
||||
$data['note'] = $request->note;
|
||||
|
||||
if ($request->provider == 'zoom') {
|
||||
$meeting_info = $this->create_zoom_live_class($request->class_topic, $request->class_date_and_time);
|
||||
$meeting_info_arr = json_decode($meeting_info, true);
|
||||
if (array_key_exists('code', $meeting_info_arr) && $meeting_info_arr) {
|
||||
return redirect(route('instructor.course.edit', ['id' => $course_id, 'tab' => 'live-class']))->with('error', get_phrase($meeting_info_arr['message']));
|
||||
}
|
||||
$data['additional_info'] = $meeting_info;
|
||||
}
|
||||
// if ($request->provider == 'zoom') {
|
||||
// $meeting_info = $this->create_zoom_live_class($request->class_topic, $request->class_date_and_time);
|
||||
// $meeting_info_arr = json_decode($meeting_info, true);
|
||||
// if (array_key_exists('code', $meeting_info_arr) && $meeting_info_arr) {
|
||||
// return redirect(route('instructor.course.edit', ['id' => $course_id, 'tab' => 'live-class']))->with('error', get_phrase($meeting_info_arr['message']));
|
||||
// }
|
||||
// $data['additional_info'] = $meeting_info;
|
||||
// }
|
||||
Live_class::insert($data);
|
||||
|
||||
return redirect(route('instructor.course.edit', ['id' => $course_id, 'tab' => 'live-class']))->with('success', get_phrase('Live class added successfully'));
|
||||
@ -67,17 +68,18 @@ class LiveClassController extends Controller
|
||||
]);
|
||||
|
||||
$data['class_topic'] = $request->class_topic;
|
||||
$data['link'] = $request->link;
|
||||
$data['user_id'] = $request->user_id;
|
||||
$data['class_date_and_time'] = date('Y-m-d\TH:i:s', strtotime($request->class_date_and_time));
|
||||
$data['note'] = $request->note;
|
||||
|
||||
if ($previous_meeting_data->provider == 'zoom') {
|
||||
$previous_meeting_info = json_decode($previous_meeting_data->additional_info, true);
|
||||
$this->update_zoom_live_class($request->class_topic, $request->class_date_and_time, $previous_meeting_info['id']);
|
||||
$previous_meeting_info["start_time"] = date('Y-m-d\TH:i:s', strtotime($request->class_date_and_time));
|
||||
$previous_meeting_info["topic"] = $request->class_topic;
|
||||
$data['additional_info'] = json_encode($previous_meeting_info);
|
||||
}
|
||||
// if ($previous_meeting_data->provider == 'zoom') {
|
||||
// $previous_meeting_info = json_decode($previous_meeting_data->additional_info, true);
|
||||
// $this->update_zoom_live_class($request->class_topic, $request->class_date_and_time, $previous_meeting_info['id']);
|
||||
// $previous_meeting_info["start_time"] = date('Y-m-d\TH:i:s', strtotime($request->class_date_and_time));
|
||||
// $previous_meeting_info["topic"] = $request->class_topic;
|
||||
// $data['additional_info'] = json_encode($previous_meeting_info);
|
||||
// }
|
||||
Live_class::where('id', $id)->update($data);
|
||||
|
||||
return redirect(route('instructor.course.edit', ['id' => $previous_meeting_data->course_id, 'tab' => 'live-class']))->with('success', get_phrase('Live class updated successfully'));
|
||||
|
||||
@ -10,7 +10,7 @@ class CustomEmailVerificationNotification extends Notification
|
||||
{
|
||||
public function __construct()
|
||||
{
|
||||
//
|
||||
|
||||
}
|
||||
|
||||
public function via($notifiable)
|
||||
@ -23,7 +23,7 @@ class CustomEmailVerificationNotification extends Notification
|
||||
$verificationUrl = $this->verificationUrl($notifiable);
|
||||
|
||||
return (new MailMessage)
|
||||
->subject(get_phrase('Custom Email Verification Subject'))
|
||||
->subject(get_phrase('Email Verification Notification'))
|
||||
->action('Verify Email Address', $verificationUrl);
|
||||
}
|
||||
|
||||
|
||||
@ -96,12 +96,12 @@
|
||||
|
||||
<div class="d-flex gap-4">
|
||||
<div class="d-flex align-items-center gap-2">
|
||||
<input type="radio" id="mark_yes" value="1" name="is_popular">
|
||||
<input type="radio" id="mark_yes" value="1" name="is_popular" checked>
|
||||
<label for="mark_yes">{{ get_phrase('Yes') }}</label>
|
||||
</div>
|
||||
|
||||
<div class="d-flex align-items-center gap-2">
|
||||
<input type="radio" id="mark_no" value="0" name="is_popular" checked>
|
||||
<input type="radio" id="mark_no" value="0" name="is_popular">
|
||||
<label for="mark_no">{{ get_phrase('No') }}</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -16,6 +16,11 @@
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<div class="fpb-7 mb-3">
|
||||
<label class="form-label ol-form-label" for="class_topic">{{ get_phrase('Meeting Link') }}<span class="required">*</span></label>
|
||||
<textarea class="form-control ol-form-control" name="link" id="link" rows="2" required></textarea>
|
||||
</div>
|
||||
|
||||
<div class="fpb-7 mb-3">
|
||||
<label class="form-label ol-form-label" for="class_date_and_time">{{ get_phrase('Class date and time') }}<span class="required">*</span></label>
|
||||
<input type="datetime-local" class="form-control ol-form-control" name="class_date_and_time" id="class_date_and_time" required>
|
||||
|
||||
@ -17,6 +17,11 @@
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<div class="fpb-7 mb-3">
|
||||
<label class="form-label ol-form-label" for="class_topic">{{ get_phrase('Meeting Link') }}<span class="required">*</span></label>
|
||||
<textarea class="form-control ol-form-control" name="link" id="link" rows="2" required>{{$live_class->link}}</textarea>
|
||||
</div>
|
||||
|
||||
<div class="fpb-7 mb-3">
|
||||
<label class="form-label ol-form-label" for="class_date_and_time">{{ get_phrase('Class date and time') }}<span class="required">*</span></label>
|
||||
<input value="{{date('Y-m-d\TH:i', strtotime($live_class->class_date_and_time))}}" type="datetime-local" class="form-control ol-form-control" name="class_date_and_time" id="class_date_and_time" required>
|
||||
|
||||
@ -35,8 +35,8 @@
|
||||
<p class="sub-title text-12px">{{ date('d M Y - h:i A', strtotime($live_class->class_date_and_time)) }}</p>
|
||||
</td>
|
||||
<td class="p-0 pt-3">
|
||||
<a href="{{ route('admin.live.class.start', ['id' => $live_class->id]) }}" class="btn py-0 ps-1 pe-1 text-dark" data-bs-toggle="tooltip"
|
||||
data-bs-title="{{ get_phrase('Start live class') }}"><i class="fi-rr-video-camera"></i></a>
|
||||
<!-- <a href="{{ route('admin.live.class.start', ['id' => $live_class->id]) }}" class="btn py-0 ps-1 pe-1 text-dark" data-bs-toggle="tooltip"
|
||||
data-bs-title="{{ get_phrase('Start live class') }}"><i class="fi-rr-video-camera"></i></a> -->
|
||||
<a href="#" class="btn py-0 px-1 text-dark"
|
||||
onclick="ajaxModal('{{ route('modal', ['view_path' => 'admin.course.edit_live_class', 'id' => $live_class->id]) }}', '{{ get_phrase('Edit live class') }}')"
|
||||
data-bs-toggle="tooltip" data-bs-title="{{ get_phrase('Edit') }}"><i class="fi-rr-pencil"></i></a>
|
||||
|
||||
@ -22,10 +22,12 @@
|
||||
</td>
|
||||
<td>{{ date('d M Y - h:i A', strtotime($live_class->class_date_and_time)) }}</td>
|
||||
<td>
|
||||
<a href="{{ route('live.class.join', ['id' => $live_class->id]) }}"
|
||||
class="btn py-0 ps-1 pe-1 text-dark" data-bs-toggle="tooltip"
|
||||
data-bs-title="{{ get_phrase('Join Now') }}"><i
|
||||
class="fi-rr-video-camera"></i></a>
|
||||
<a href="{{ $live_class->link }}" target="_blank" rel="noopener noreferrer"
|
||||
class="btn py-0 ps-1 pe-1 text-dark"
|
||||
data-bs-toggle="tooltip"
|
||||
data-bs-title="{{ get_phrase('Join Now') }}">
|
||||
<i class="fi-rr-video-camera"></i>
|
||||
</a>
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
|
||||
@ -100,14 +100,13 @@
|
||||
|
||||
<div class="d-flex gap-4">
|
||||
<div class="d-flex align-items-center gap-2">
|
||||
<input type="radio" id="mark_yes" value="1" name="is_popular">
|
||||
<label for="mark_yes">{{ get_phrase('Yes') }}</label>
|
||||
</div>
|
||||
|
||||
<div class="d-flex align-items-center gap-2">
|
||||
<input type="radio" id="mark_no" value="0" name="is_popular" checked>
|
||||
<input type="radio" id="mark_no" value="0" name="is_popular">
|
||||
<label for="mark_no">{{ get_phrase('No') }}</label>
|
||||
</div>
|
||||
<div class="d-flex align-items-center gap-2">
|
||||
<input type="radio" id="mark_yes" value="1" name="is_popular" checked>
|
||||
<label for="mark_yes">{{ get_phrase('Yes') }}</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@ -157,10 +157,10 @@
|
||||
<input type="hidden" name="old_og_image" value="{{ $seo_meta_tag->og_image }}">
|
||||
</div>
|
||||
|
||||
<div class="fpb-7 mb-3">
|
||||
<!-- <div class="fpb-7 mb-3">
|
||||
<label for="json_ld" class="form-label ol-form-label">{{ get_phrase('Json Id') }}</label>
|
||||
<textarea class="form-control ol-form-control" id="json_ld" name="json_ld">{{ $seo_meta_tag->json_ld }}</textarea>
|
||||
</div>
|
||||
</div> -->
|
||||
|
||||
<div class=" mb-3">
|
||||
<button type="submit" class="ol-btn-primary">{{ get_phrase('Update blog') }}</button>
|
||||
|
||||
@ -19,6 +19,11 @@
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<div class="fpb-7 mb-3">
|
||||
<label class="form-label ol-form-label" for="link_for_student">{{ get_phrase('Meeting Link') }}</label>
|
||||
<textarea class="form-control ol-form-control" name="link" id="link_for_student" rows="2"></textarea>
|
||||
</div>
|
||||
|
||||
<div class="fpb-7 mb-3">
|
||||
<label class="form-label ol-form-label" for="class_date_and_time">{{ get_phrase('Class date and time') }}<span
|
||||
class="required">*</span></label>
|
||||
|
||||
@ -18,6 +18,11 @@
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<div class="fpb-7 mb-3">
|
||||
<label class="form-label ol-form-label" for="link">{{ get_phrase('Meeting Link') }}<span class="required">*</span></label>
|
||||
<input type="text" value="{{ $live_class->link }}" name="link" id = "link" class="form-control ol-form-control" required>
|
||||
</div>
|
||||
|
||||
<div class="fpb-7 mb-3">
|
||||
<label class="form-label ol-form-label" for="class_date_and_time">{{ get_phrase('Class date and time') }}<span class="required">*</span></label>
|
||||
<input value="{{ date('Y-m-d\TH:i', strtotime($live_class->class_date_and_time)) }}" type="datetime-local" class="form-control ol-form-control" name="class_date_and_time" id="class_date_and_time" required>
|
||||
|
||||
@ -51,7 +51,7 @@
|
||||
<input type="hidden" name="old_og_image" value="{{ $seo_meta_tag->og_image }}">
|
||||
</div>
|
||||
|
||||
<div class="fpb-7 mb-3">
|
||||
<!-- <div class="fpb-7 mb-3">
|
||||
<label for="json_ld" class="form-label ol-form-label">{{ get_phrase('Json Id') }}</label>
|
||||
<textarea class="form-control ol-form-control" id="json_ld" name="json_ld">{{ $seo_meta_tag->json_ld }}</textarea>
|
||||
</div>
|
||||
</div> -->
|
||||
|
||||
@ -22,7 +22,7 @@
|
||||
<td class="p-0">{{ date('d M Y - h:i A', strtotime($live_class->class_date_and_time)) }}
|
||||
</td>
|
||||
<td class="p-0">
|
||||
<a href="{{ route('instructor.live.class.start', ['id' => $live_class->id]) }}" class="btn py-0 ps-1 pe-1 text-dark" data-bs-toggle="tooltip" data-bs-title="{{ get_phrase('Start live class') }}"><i class="fi-rr-video-camera"></i></a>
|
||||
<!-- <a href="{{ route('instructor.live.class.start', ['id' => $live_class->id]) }}" class="btn py-0 ps-1 pe-1 text-dark" data-bs-toggle="tooltip" data-bs-title="{{ get_phrase('Start live class') }}"><i class="fi-rr-video-camera"></i></a> -->
|
||||
<a href="#" class="btn py-0 px-1 text-dark" onclick="ajaxModal('{{ route('modal', ['view_path' => 'instructor.course.edit_live_class', 'id' => $live_class->id]) }}', '{{ get_phrase('Edit live class') }}')" data-bs-toggle="tooltip" data-bs-title="{{ get_phrase('Edit') }}"><i class="fi-rr-pencil"></i></a>
|
||||
<a href="#" class="btn py-0 px-1 text-danger" onclick="confirmModal('{{ route('instructor.live.class.delete', ['id' => $live_class->id]) }}')" data-bs-toggle="tooltip" data-bs-title="{{ get_phrase('Delete') }}"><i class="fi-rr-trash"></i></a>
|
||||
</td>
|
||||
|
||||
@ -98,7 +98,7 @@
|
||||
</a>
|
||||
</li>
|
||||
|
||||
<li class="sidebar-first-li first-li-have-sub @if ($current_route == 'instructor.payout.reports' || $current_route == 'instructor.payout.setting') active showMenu @endif">
|
||||
<!-- <li class="sidebar-first-li first-li-have-sub @if ($current_route == 'instructor.payout.reports' || $current_route == 'instructor.payout.setting') active showMenu @endif">
|
||||
<a href="javascript:void(0);">
|
||||
<span class="icon fi fi-rr-file-invoice-dollar"></span>
|
||||
<div class="text">
|
||||
@ -114,7 +114,7 @@
|
||||
<a href="{{ route('instructor.payout.setting') }}">{{ get_phrase('Settings') }}</a>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
</li> -->
|
||||
|
||||
|
||||
@if (get_frontend_settings('instructors_blog_permission'))
|
||||
@ -133,9 +133,9 @@
|
||||
<li class="sidebar-second-li @if ($current_route == 'instructor.blog.create') active @endif">
|
||||
<a href="{{ route('instructor.blog.create') }}">{{ get_phrase('Add New Blog') }}</a>
|
||||
</li>
|
||||
<li class="sidebar-second-li @if ($current_route == 'instructor.blog.pending') active @endif">
|
||||
<!-- <li class="sidebar-second-li @if ($current_route == 'instructor.blog.pending') active @endif">
|
||||
<a href="{{ route('instructor.blog.pending') }}">{{ get_phrase('Pending Blogs') }}</a>
|
||||
</li>
|
||||
</li> -->
|
||||
</ul>
|
||||
</li>
|
||||
@endif
|
||||
|
||||
Loading…
Reference in New Issue
Block a user