feat: enable certification from course form
This commit is contained in:
@@ -18,7 +18,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div
|
<div
|
||||||
v-if="sidebarSettings.data?.web_pages?.length || isModerator"
|
v-if="sidebarSettings.data?.web_pages?.length || isModerator"
|
||||||
class="pt-1"
|
class="mt-4"
|
||||||
>
|
>
|
||||||
<div
|
<div
|
||||||
class="flex items-center justify-between pr-2 cursor-pointer"
|
class="flex items-center justify-between pr-2 cursor-pointer"
|
||||||
@@ -36,7 +36,7 @@
|
|||||||
/>
|
/>
|
||||||
</span>
|
</span>
|
||||||
<span class="ml-2">
|
<span class="ml-2">
|
||||||
{{ __('Web Pages') }}
|
{{ __('More') }}
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
<Button v-if="isModerator" variant="ghost" @click="openPageModal()">
|
<Button v-if="isModerator" variant="ghost" @click="openPageModal()">
|
||||||
|
|||||||
@@ -119,7 +119,7 @@
|
|||||||
<div class="text-lg font-semibold mt-5 mb-4">
|
<div class="text-lg font-semibold mt-5 mb-4">
|
||||||
{{ __('Settings') }}
|
{{ __('Settings') }}
|
||||||
</div>
|
</div>
|
||||||
<div class="grid grid-cols-2 gap-10 mb-4">
|
<div class="grid grid-cols-3 gap-10 mb-4">
|
||||||
<div
|
<div
|
||||||
v-if="user.data?.is_moderator"
|
v-if="user.data?.is_moderator"
|
||||||
class="flex flex-col space-y-3"
|
class="flex flex-col space-y-3"
|
||||||
@@ -147,11 +147,18 @@
|
|||||||
v-model="course.featured"
|
v-model="course.featured"
|
||||||
:label="__('Featured')"
|
:label="__('Featured')"
|
||||||
/>
|
/>
|
||||||
|
</div>
|
||||||
|
<div class="flex flex-col space-y-3">
|
||||||
<FormControl
|
<FormControl
|
||||||
type="checkbox"
|
type="checkbox"
|
||||||
v-model="course.disable_self_learning"
|
v-model="course.disable_self_learning"
|
||||||
:label="__('Disable Self Enrollment')"
|
:label="__('Disable Self Enrollment')"
|
||||||
/>
|
/>
|
||||||
|
<FormControl
|
||||||
|
type="checkbox"
|
||||||
|
v-model="course.enable_certification"
|
||||||
|
:label="__('Completion Certificate')"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -244,6 +251,7 @@ const course = reactive({
|
|||||||
featured: false,
|
featured: false,
|
||||||
upcoming: false,
|
upcoming: false,
|
||||||
disable_self_learning: false,
|
disable_self_learning: false,
|
||||||
|
enable_certification: false,
|
||||||
paid_course: false,
|
paid_course: false,
|
||||||
course_price: '',
|
course_price: '',
|
||||||
currency: '',
|
currency: '',
|
||||||
@@ -337,6 +345,7 @@ const courseResource = createResource({
|
|||||||
'disable_self_learning',
|
'disable_self_learning',
|
||||||
'paid_course',
|
'paid_course',
|
||||||
'featured',
|
'featured',
|
||||||
|
'enable_certification',
|
||||||
]
|
]
|
||||||
for (let idx in checkboxes) {
|
for (let idx in checkboxes) {
|
||||||
let key = checkboxes[idx]
|
let key = checkboxes[idx]
|
||||||
|
|||||||
Reference in New Issue
Block a user