fix: restrict profile and mark as complete
This commit is contained in:
@@ -14,7 +14,7 @@ frappe.ready(function () {
|
||||
frappe.web_form.validate = () => {
|
||||
let information_missing;
|
||||
const data = frappe.web_form.get_values();
|
||||
data.work_experience.forEach(exp => {
|
||||
data.work_experience && data.work_experience.length && data.work_experience.forEach(exp => {
|
||||
if (!exp.current && !exp.to_date) {
|
||||
information_missing = true
|
||||
frappe.msgprint('To Date is mandatory in Work Experience.');
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
"is_standard": 1,
|
||||
"login_required": 1,
|
||||
"max_attachment_size": 0,
|
||||
"modified": "2021-12-20 13:20:19.810134",
|
||||
"modified": "2021-12-21 11:05:56.505121",
|
||||
"modified_by": "Administrator",
|
||||
"module": "LMS",
|
||||
"name": "profile",
|
||||
@@ -330,7 +330,7 @@
|
||||
"fieldname": "preferred_location",
|
||||
"fieldtype": "Data",
|
||||
"hidden": 0,
|
||||
"label": "Preferred Location",
|
||||
"label": "Preferred Locations",
|
||||
"max_length": 0,
|
||||
"max_value": 0,
|
||||
"options": "",
|
||||
@@ -411,7 +411,7 @@
|
||||
"label": "Location Preference",
|
||||
"max_length": 0,
|
||||
"max_value": 0,
|
||||
"options": "Travel to work\nOffice close to Home",
|
||||
"options": "Travel\nOffice close to Home",
|
||||
"read_only": 0,
|
||||
"reqd": 0,
|
||||
"show_in_filter": 0
|
||||
@@ -456,4 +456,4 @@
|
||||
"show_in_filter": 0
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user