Package: webinar
Generated from api/packages/webinar
Source: api/packages/webinar · imported version 0.1.44. The sections after the README are extracted from the code on every docs build.
README
Section titled “README”Package enabling live video stream
What does it do
Section titled “What does it do”This package is used for creating Webinar for Ulams.
Installing
Section titled “Installing”composer require ulams/webinarphp artisan migratephp artisan db:seed --class="Ulams\Webinar\Database\Seeders\WebinarsPermissionSeeder"- Integration with Youtube
Schedule
Section titled “Schedule”- In App\Console\Kernel to method schedule add
$schedule->job(new ReminderAboutWebinarJob(WebinarTermReminderStatusEnum::REMINDED_HOUR_BEFORE))->everyFiveMinutes()- reminder about to webinar before one hour, executed every 5 minutes$schedule->job(new ReminderAboutWebinarJob(WebinarTermReminderStatusEnum::REMINDED_DAY_BEFORE))->everySixHours();- reminder about to webinar before one day, executed every 6 hours
Endpoints
Section titled “Endpoints”All the endpoints are defined in
Run ./vendor/bin/phpunit --filter=Webinar to run tests. See tests folder as it’s quite good staring point as documentation appendix.
Events
Section titled “Events”Ulams\Webinar\Events\ReminderAboutTerm=> Event is dispatched after execute cron jobUlams\Webinar\Jobs\ReminderAboutWebinarJob, Event is dispatched when deadline for purchased webinars before 1 hours and 1 dayUlams\Webinar\Events\WebinarTrainerAssigned=> Event is dispatched after assigned trainer to webinarUlams\Webinar\Events\WebinarTrainerUnassigned=> Event is dispatched after unassigned trainer from webinar
Listeners
Section titled “Listeners”Ulams\Webinar\Listeners\ReminderAboutTermListener=> Listener execute a method that singed the status in the webinar reminder
How does this work on frontend.
Section titled “How does this work on frontend.”sequenceDiagram
box Embeed in Web App
participant Jisti
actor Tutor
participant Youtube
participant Web App
actor Student
end
box Administration
participant Admin Panel
actor Admin
end
Admin->>Admin Panel: Creates a webinar instance
Student->>Web App: Get access to webinar (eg. buys)
Tutor->>Web App: (on the day of the event) Broadcast
Web App->>Jisti: Broadcast with Jitsu GUI
Jisti->>Youtube: Broadcast to public
Youtube->>Web App: forward for public
Student->>Web App: Watches webinar with YT GUI
Permissions
Section titled “Permissions”Permissions are defined in seeder
Database relation
Section titled “Database relation”TrainersWebinar is related belongs to many with UserTagsWebinar model morph many to model tagsUsersWebinar is related belongs to many with User which bought webinar
Webinar 1 -> n UserWebinar 1 -> n TagsWebinar 1 -> n UserMore documentation in the package
Section titled “More documentation in the package”- api/packages/webinar/ADMIN.md
- api/packages/webinar/docs/list.png
- api/packages/webinar/docs/menu.png
- api/packages/webinar/docs/new_webinar.png
API endpoints
Section titled “API endpoints”| Method | Path | Auth | Action |
|---|---|---|---|
POST |
/api/admin/webinars/{id} |
yes | WebinarController@update |
GET |
/api/admin/webinars/{id}/users |
yes | WebinarController@webinarUsers |
GET |
/api/admin/webinars |
yes | WebinarController@index |
GET |
/api/admin/webinars/create |
yes | WebinarController@create |
POST |
/api/admin/webinars |
yes | WebinarController@store |
GET |
/api/admin/webinars/{id} |
yes | WebinarController@show |
GET |
/api/admin/webinars/{id}/edit |
yes | WebinarController@edit |
PUT|PATCH |
/api/admin/webinars/{id} |
yes | WebinarController@update |
DELETE |
/api/admin/webinars/{id} |
yes | WebinarController@destroy |
GET |
/api/admin/webinars/users/assignable |
yes | WebinarController@assignableUsers |
GET |
/api/webinars/me |
yes | WebinarAPIController@forCurrentUser |
GET |
/api/webinars/generate-jitsi/{id} |
yes | WebinarAPIController@generateJitsi |
GET |
/api/webinars/start-live-stream/{id} |
yes | WebinarAPIController@startLiveStream |
GET |
/api/webinars/stop-live-stream/{id} |
yes | WebinarAPIController@stopLiveStream |
GET |
/api/webinars |
WebinarAPIController@index |
|
GET |
/api/webinars/{id} |
WebinarAPIController@show |
Permissions
Section titled “Permissions”| Permission | Seeded for roles | Constant |
|---|---|---|
webinar_list |
admin | WebinarPermissionsEnum::WEBINAR_LIST |
webinar_create |
admin, tutor | WebinarPermissionsEnum::WEBINAR_CREATE |
webinar_update |
admin | WebinarPermissionsEnum::WEBINAR_UPDATE |
webinar_delete |
admin | WebinarPermissionsEnum::WEBINAR_DELETE |
webinar_read |
admin | WebinarPermissionsEnum::WEBINAR_READ |
webinar_list-own |
tutor | WebinarPermissionsEnum::WEBINAR_LIST_OWN |
webinar_update-own |
tutor | WebinarPermissionsEnum::WEBINAR_UPDATE_OWN |
webinar_delete-own |
tutor | WebinarPermissionsEnum::WEBINAR_DELETE_OWN |
webinar_read-own |
tutor | WebinarPermissionsEnum::WEBINAR_READ_OWN |
Settings
Section titled “Settings”Registered with AdministrableConfig::registerConfig (editable in the admin panel under Configuration → Settings).
None.
Events
Section titled “Events”| Event | Description | Notification templates |
|---|---|---|
ReminderAboutTerm |
Email, Email, Sms | |
WebinarTrainerAssigned |
||
WebinarTrainerUnassigned |
||
WebinarUserAssigned |
||
WebinarUserUnassigned |
Notification templates registered here
Section titled “Notification templates registered here”None.
Artisan commands
Section titled “Artisan commands”None.
Scheduled jobs
Section titled “Scheduled jobs”None.
Environment variables read
Section titled “Environment variables read”AWS_ACCESS_KEY_ID