fix: misc issues
This commit is contained in:
@@ -293,8 +293,8 @@ const tabsStructure = computed(() => {
|
|||||||
type: 'checkbox',
|
type: 'checkbox',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: 'Certified Participants',
|
label: 'Certified Members',
|
||||||
name: 'certified_participants',
|
name: 'certified_members',
|
||||||
type: 'checkbox',
|
type: 'checkbox',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -61,7 +61,7 @@
|
|||||||
</button>
|
</button>
|
||||||
</template>
|
</template>
|
||||||
<script setup>
|
<script setup>
|
||||||
import { Tooltip, Button } from 'frappe-ui'
|
import { Tooltip } from 'frappe-ui'
|
||||||
import { computed } from 'vue'
|
import { computed } from 'vue'
|
||||||
import { useRouter } from 'vue-router'
|
import { useRouter } from 'vue-router'
|
||||||
import * as icons from 'lucide-vue-next'
|
import * as icons from 'lucide-vue-next'
|
||||||
|
|||||||
@@ -125,6 +125,9 @@ onMounted(() => {
|
|||||||
const jobs = createResource({
|
const jobs = createResource({
|
||||||
url: 'lms.lms.api.get_job_opportunities',
|
url: 'lms.lms.api.get_job_opportunities',
|
||||||
cache: ['jobs'],
|
cache: ['jobs'],
|
||||||
|
onSuccess(data) {
|
||||||
|
jobCount.value = data.length
|
||||||
|
},
|
||||||
})
|
})
|
||||||
|
|
||||||
const updateJobs = () => {
|
const updateJobs = () => {
|
||||||
@@ -168,10 +171,7 @@ const updateFilters = () => {
|
|||||||
const getJobCount = () => {
|
const getJobCount = () => {
|
||||||
call('lms.lms.api.get_count', {
|
call('lms.lms.api.get_count', {
|
||||||
doctype: 'Job Opportunity',
|
doctype: 'Job Opportunity',
|
||||||
filters: {
|
filters: filters.value,
|
||||||
status: 'Open',
|
|
||||||
disabled: 0,
|
|
||||||
},
|
|
||||||
}).then((data) => {
|
}).then((data) => {
|
||||||
jobCount.value = data
|
jobCount.value = data
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -552,7 +552,7 @@ def get_sidebar_settings():
|
|||||||
items = [
|
items = [
|
||||||
"courses",
|
"courses",
|
||||||
"batches",
|
"batches",
|
||||||
"certified_participants",
|
"certified_members",
|
||||||
"jobs",
|
"jobs",
|
||||||
"statistics",
|
"statistics",
|
||||||
"notifications",
|
"notifications",
|
||||||
|
|||||||
@@ -35,6 +35,7 @@
|
|||||||
"courses",
|
"courses",
|
||||||
"batches",
|
"batches",
|
||||||
"certified_participants",
|
"certified_participants",
|
||||||
|
"certified_members",
|
||||||
"column_break_exdz",
|
"column_break_exdz",
|
||||||
"jobs",
|
"jobs",
|
||||||
"statistics",
|
"statistics",
|
||||||
@@ -277,6 +278,7 @@
|
|||||||
"default": "1",
|
"default": "1",
|
||||||
"fieldname": "certified_participants",
|
"fieldname": "certified_participants",
|
||||||
"fieldtype": "Check",
|
"fieldtype": "Check",
|
||||||
|
"hidden": 1,
|
||||||
"label": "Certified Participants"
|
"label": "Certified Participants"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -397,13 +399,19 @@
|
|||||||
"fieldtype": "Check",
|
"fieldtype": "Check",
|
||||||
"label": "Persona Captured",
|
"label": "Persona Captured",
|
||||||
"read_only": 1
|
"read_only": 1
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"default": "0",
|
||||||
|
"fieldname": "certified_members",
|
||||||
|
"fieldtype": "Check",
|
||||||
|
"label": "Certified Members"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"grid_page_length": 50,
|
"grid_page_length": 50,
|
||||||
"index_web_pages_for_search": 1,
|
"index_web_pages_for_search": 1,
|
||||||
"issingle": 1,
|
"issingle": 1,
|
||||||
"links": [],
|
"links": [],
|
||||||
"modified": "2025-05-14 12:43:22.749850",
|
"modified": "2025-05-30 19:02:51.381668",
|
||||||
"modified_by": "sayali@frappe.io",
|
"modified_by": "sayali@frappe.io",
|
||||||
"module": "LMS",
|
"module": "LMS",
|
||||||
"name": "LMS Settings",
|
"name": "LMS Settings",
|
||||||
|
|||||||
@@ -106,4 +106,5 @@ lms.patches.v2_0.update_job_city_and_country
|
|||||||
lms.patches.v2_0.update_course_evaluator_data
|
lms.patches.v2_0.update_course_evaluator_data
|
||||||
lms.patches.v2_0.move_zoom_settings #20-05-2025
|
lms.patches.v2_0.move_zoom_settings #20-05-2025
|
||||||
lms.patches.v2_0.link_zoom_account_to_live_class
|
lms.patches.v2_0.link_zoom_account_to_live_class
|
||||||
lms.patches.v2_0.link_zoom_account_to_batch
|
lms.patches.v2_0.link_zoom_account_to_batch
|
||||||
|
lms.patches.v2_0.sidebar_for_certified_members
|
||||||
@@ -7,6 +7,10 @@ def execute():
|
|||||||
|
|
||||||
def create_settings():
|
def create_settings():
|
||||||
current_settings = frappe.get_single("Zoom Settings")
|
current_settings = frappe.get_single("Zoom Settings")
|
||||||
|
|
||||||
|
if not current_settings.enable:
|
||||||
|
return
|
||||||
|
|
||||||
member = current_settings.owner
|
member = current_settings.owner
|
||||||
member_name = frappe.get_value("User", member, "full_name")
|
member_name = frappe.get_value("User", member, "full_name")
|
||||||
|
|
||||||
|
|||||||
10
lms/patches/v2_0/sidebar_for_certified_members.py
Normal file
10
lms/patches/v2_0/sidebar_for_certified_members.py
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
import frappe
|
||||||
|
|
||||||
|
|
||||||
|
def execute():
|
||||||
|
show_certified_members = frappe.db.get_single_value(
|
||||||
|
"LMS Settings", "certified_participants"
|
||||||
|
)
|
||||||
|
|
||||||
|
if show_certified_members:
|
||||||
|
frappe.db.set_single_value("LMS Settings", "certified_members", 1)
|
||||||
Reference in New Issue
Block a user