diff --git a/castle/castle_app/custom.js b/castle/castle_app/custom.js new file mode 100644 index 0000000..2c0c79a --- /dev/null +++ b/castle/castle_app/custom.js @@ -0,0 +1,7 @@ + +frappe.ui.form.on("Employee", { + refresh: function(frm) { + frappe.msgprint(__("Message printed from Hooks")); + + } + }); \ No newline at end of file diff --git a/castle/castle_app/custom/employee.json b/castle/castle_app/custom/employee.json new file mode 100644 index 0000000..e26e9a7 --- /dev/null +++ b/castle/castle_app/custom/employee.json @@ -0,0 +1,3748 @@ +{ + "custom_fields": [ + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-01-05 17:46:29.709230", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "employment_type", + "fieldtype": "Link", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 32, + "ignore_user_permissions": 1, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "department", + "is_system_generated": 1, + "is_virtual": 0, + "label": "Employment Type", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-01-05 17:46:29.709230", + "modified_by": "Administrator", + "module": null, + "name": "Employee-employment_type", + "no_copy": 0, + "non_negative": 0, + "options": "Employment Type", + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-01-05 17:46:29.834232", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "job_applicant", + "fieldtype": "Link", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 44, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "employment_details", + "is_system_generated": 1, + "is_virtual": 0, + "label": "Job Applicant", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-01-05 17:46:29.834232", + "modified_by": "Administrator", + "module": null, + "name": "Employee-job_applicant", + "no_copy": 0, + "non_negative": 0, + "options": "Job Applicant", + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-01-05 17:46:29.913002", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "grade", + "fieldtype": "Link", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 41, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "branch", + "is_system_generated": 1, + "is_virtual": 0, + "label": "Grade", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-01-05 17:46:29.913002", + "modified_by": "Administrator", + "module": null, + "name": "Employee-grade", + "no_copy": 0, + "non_negative": 0, + "options": "Employee Grade", + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-01-05 17:46:29.985766", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "default_shift", + "fieldtype": "Link", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 79, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "holiday_list", + "is_system_generated": 1, + "is_virtual": 0, + "label": "Default Shift", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-01-05 17:46:29.985766", + "modified_by": "Administrator", + "module": null, + "name": "Employee-default_shift", + "no_copy": 0, + "non_negative": 0, + "options": "Shift Type", + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 1, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-01-05 17:46:30.059487", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "health_insurance_section", + "fieldtype": "Section Break", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 108, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "license_type", + "is_system_generated": 1, + "is_virtual": 0, + "label": "Health Insurance", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-01-05 17:46:30.059487", + "modified_by": "Administrator", + "module": null, + "name": "Employee-health_insurance_section", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-01-05 17:46:30.131225", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "health_insurance_provider", + "fieldtype": "Link", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 109, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "health_insurance_section", + "is_system_generated": 1, + "is_virtual": 0, + "label": "Health Insurance Provider", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-01-05 17:46:30.131225", + "modified_by": "Administrator", + "module": null, + "name": "Employee-health_insurance_provider", + "no_copy": 0, + "non_negative": 0, + "options": "Employee Health Insurance", + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-01-05 17:46:30.212474", + "default": null, + "depends_on": "eval:doc.health_insurance_provider", + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "health_insurance_no", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 110, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "health_insurance_provider", + "is_system_generated": 1, + "is_virtual": 0, + "label": "Health Insurance No", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-01-05 17:46:30.212474", + "modified_by": "Administrator", + "module": null, + "name": "Employee-health_insurance_no", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-01-05 17:46:30.288387", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "approvers_section", + "fieldtype": "Section Break", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 80, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "default_shift", + "is_system_generated": 1, + "is_virtual": 0, + "label": "Approvers", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-01-05 17:46:30.288387", + "modified_by": "Administrator", + "module": null, + "name": "Employee-approvers_section", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-01-05 17:46:30.361430", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "expense_approver", + "fieldtype": "Link", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 81, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "approvers_section", + "is_system_generated": 1, + "is_virtual": 0, + "label": "Expense Approver", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-01-05 17:46:30.361430", + "modified_by": "Administrator", + "module": null, + "name": "Employee-expense_approver", + "no_copy": 0, + "non_negative": 0, + "options": "User", + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-01-05 17:46:30.439042", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "leave_approver", + "fieldtype": "Link", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 82, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "expense_approver", + "is_system_generated": 1, + "is_virtual": 0, + "label": "Leave Approver", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-01-05 17:46:30.439042", + "modified_by": "Administrator", + "module": null, + "name": "Employee-leave_approver", + "no_copy": 0, + "non_negative": 0, + "options": "User", + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-01-05 17:46:30.518040", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "column_break_45", + "fieldtype": "Column Break", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 83, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "leave_approver", + "is_system_generated": 1, + "is_virtual": 0, + "label": null, + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-01-05 17:46:30.518040", + "modified_by": "Administrator", + "module": null, + "name": "Employee-column_break_45", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-01-05 17:46:30.598402", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "shift_request_approver", + "fieldtype": "Link", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 84, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "column_break_45", + "is_system_generated": 1, + "is_virtual": 0, + "label": "Shift Request Approver", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-01-05 17:46:30.598402", + "modified_by": "Administrator", + "module": null, + "name": "Employee-shift_request_approver", + "no_copy": 0, + "non_negative": 0, + "options": "User", + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-01-05 17:46:30.763027", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": "department.payroll_cost_center", + "fetch_if_empty": 1, + "fieldname": "payroll_cost_center", + "fieldtype": "Link", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 87, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "gross_salary", + "is_system_generated": 1, + "is_virtual": 0, + "label": "Payroll Cost Center", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-01-05 17:46:30.763027", + "modified_by": "Administrator", + "module": null, + "name": "Employee-payroll_cost_center", + "no_copy": 0, + "non_negative": 0, + "options": "Cost Center", + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-01-18 13:33:36.707491", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "checkin", + "fieldtype": "Check", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 10, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "arabic_name", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Attendance status", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-01-18 13:36:54.285516", + "modified_by": "Administrator", + "module": null, + "name": "Employee-checkin", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-26 08:50:55.511394", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "arabic_name", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 9, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "employee_name", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Arabic Name", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-26 08:50:55.511394", + "modified_by": "Administrator", + "module": null, + "name": "Employee-arabic_name", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-26 08:57:05.187272", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "nationality_", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 16, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "salutation", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Nationality ", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-26 08:57:05.187272", + "modified_by": "Administrator", + "module": null, + "name": "Employee-nationality_", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-26 09:05:36.684205", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "division", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 42, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "grade", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Division", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-26 09:05:36.684205", + "modified_by": "Administrator", + "module": null, + "name": "Employee-division", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-26 09:07:17.651652", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "working_location", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 37, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "reports_to", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Working Location", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-26 09:07:17.651652", + "modified_by": "Administrator", + "module": null, + "name": "Employee-working_location", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 1, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-29 09:57:16.933676", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "visa_details_", + "fieldtype": "Section Break", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 124, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "ec_expiry_date", + "is_system_generated": 0, + "is_virtual": 0, + "label": "QID Details ", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-29 09:57:16.933676", + "modified_by": "Administrator", + "module": null, + "name": "Employee-visa_details_", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-29 09:58:17.872065", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "visa_number", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 125, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "visa_details_", + "is_system_generated": 0, + "is_virtual": 0, + "label": "QID Number", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-29 09:58:17.872065", + "modified_by": "Administrator", + "module": null, + "name": "Employee-visa_number", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-29 10:01:30.664440", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "qid_expiry_", + "fieldtype": "Date", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 126, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "visa_number", + "is_system_generated": 0, + "is_virtual": 0, + "label": "QID Expiry ", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-29 10:01:30.664440", + "modified_by": "Administrator", + "module": null, + "name": "Employee-qid_expiry_", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-29 10:26:18.081665", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "issue_date", + "fieldtype": "Date", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 111, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "health_insurance_no", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Issue Date", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-29 10:26:18.081665", + "modified_by": "Administrator", + "module": null, + "name": "Employee-issue_date", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-29 10:27:23.203823", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "expiry_date", + "fieldtype": "Date", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 112, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "issue_date", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Expiry Date", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-29 10:27:23.203823", + "modified_by": "Administrator", + "module": null, + "name": "Employee-expiry_date", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-29 10:28:31.609649", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "column_break_aped1", + "fieldtype": "Column Break", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 113, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "expiry_date", + "is_system_generated": 0, + "is_virtual": 0, + "label": null, + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-29 10:28:31.609649", + "modified_by": "Administrator", + "module": null, + "name": "Employee-column_break_aped1", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-29 10:30:20.991189", + "default": "VALID", + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "hc_status", + "fieldtype": "Select", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 114, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "column_break_aped1", + "is_system_generated": 0, + "is_virtual": 0, + "label": "HC Status", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-29 10:30:20.991189", + "modified_by": "Administrator", + "module": null, + "name": "Employee-hc_status", + "no_copy": 0, + "non_negative": 0, + "options": "VALID\nEXPIRED\n", + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-29 10:35:51.332678", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "hc_location", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 115, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "hc_status", + "is_system_generated": 0, + "is_virtual": 0, + "label": "HC Location", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-29 10:35:51.332678", + "modified_by": "Administrator", + "module": null, + "name": "Employee-hc_location", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-29 11:12:34.271273", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "age", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 14, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "date_of_birth", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Age", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-29 11:12:34.271273", + "modified_by": "Administrator", + "module": null, + "name": "Employee-age", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-29 11:14:09.812839", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "religion", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 23, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "status", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Religion", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-29 11:14:09.812839", + "modified_by": "Administrator", + "module": null, + "name": "Employee-religion", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 1, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-30 09:17:43.661396", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "employee_visa", + "fieldtype": "Section Break", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 136, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "passport_status_", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Employee Visa", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-30 09:17:43.661396", + "modified_by": "Administrator", + "module": null, + "name": "Employee-employee_visa", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-30 09:20:08.960163", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "visa", + "fieldtype": "Table", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 137, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "employee_visa", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Visa", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-30 09:20:08.960163", + "modified_by": "Administrator", + "module": null, + "name": "Employee-visa", + "no_copy": 0, + "non_negative": 0, + "options": "Employee Visa", + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-31 09:02:32.703974", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "referred_by", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 24, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "religion", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Referred By", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-31 09:02:32.703974", + "modified_by": "Administrator", + "module": null, + "name": "Employee-referred_by", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-31 09:08:51.233253", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "column_break_4o4qj", + "fieldtype": "Column Break", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 127, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "qid_expiry_", + "is_system_generated": 0, + "is_virtual": 0, + "label": null, + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-31 09:08:51.233253", + "modified_by": "Administrator", + "module": null, + "name": "Employee-column_break_4o4qj", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-31 09:08:51.418076", + "default": "VALID", + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "qid_status", + "fieldtype": "Select", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 128, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "column_break_4o4qj", + "is_system_generated": 0, + "is_virtual": 0, + "label": "QID Status", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-31 09:08:51.418076", + "modified_by": "Administrator", + "module": null, + "name": "Employee-qid_status", + "no_copy": 0, + "non_negative": 0, + "options": "VALID\nEXPIRED", + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-31 10:12:50.231474", + "default": "VALID", + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "passport_status_", + "fieldtype": "Select", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 135, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "place_of_issue", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Passport Status ", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-31 10:12:50.231474", + "modified_by": "Administrator", + "module": null, + "name": "Employee-passport_status_", + "no_copy": 0, + "non_negative": 0, + "options": "VALID\nEXPIRED", + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 1, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-31 10:21:13.929130", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "license_details_", + "fieldtype": "Section Break", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 102, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "health_details", + "is_system_generated": 0, + "is_virtual": 0, + "label": "License Details ", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-31 10:21:13.929130", + "modified_by": "Administrator", + "module": null, + "name": "Employee-license_details_", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-31 10:21:59.595132", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "driving_license_no", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 103, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "license_details_", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Driving License No", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-31 10:21:59.595132", + "modified_by": "Administrator", + "module": null, + "name": "Employee-driving_license_no", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-31 10:22:48.277672", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "dl_issue_date", + "fieldtype": "Date", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 104, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "driving_license_no", + "is_system_generated": 0, + "is_virtual": 0, + "label": "DL Issue Date", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-31 10:22:48.277672", + "modified_by": "Administrator", + "module": null, + "name": "Employee-dl_issue_date", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-31 10:23:21.435311", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "column_break_jar7z", + "fieldtype": "Column Break", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 105, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "dl_issue_date", + "is_system_generated": 0, + "is_virtual": 0, + "label": null, + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-31 10:23:21.435311", + "modified_by": "Administrator", + "module": null, + "name": "Employee-column_break_jar7z", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-31 10:23:49.893234", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "dl_expiry_date", + "fieldtype": "Date", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 106, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "column_break_jar7z", + "is_system_generated": 0, + "is_virtual": 0, + "label": "DL Expiry Date", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-31 10:23:49.893234", + "modified_by": "Administrator", + "module": null, + "name": "Employee-dl_expiry_date", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-31 10:25:12.633348", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "license_type", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 107, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "dl_expiry_date", + "is_system_generated": 0, + "is_virtual": 0, + "label": "License Type", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-31 10:25:12.633348", + "modified_by": "Administrator", + "module": null, + "name": "Employee-license_type", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-31 10:34:19.843454", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "accommodation", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 64, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "current_accommodation_type", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Accommodation", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-31 10:34:19.843454", + "modified_by": "Administrator", + "module": null, + "name": "Employee-accommodation", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-31 10:35:04.386598", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "room_no", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 68, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "permanent_accommodation_type", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Room No", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-31 10:35:04.386598", + "modified_by": "Administrator", + "module": null, + "name": "Employee-room_no", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-05-31 14:55:12.289933", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "arrival_date", + "fieldtype": "Date", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 19, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "number_of_years_in_service", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Arrival Date", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-05-31 14:55:12.289933", + "modified_by": "Administrator", + "module": null, + "name": "Employee-arrival_date", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-06-01 09:40:42.677407", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "sponsor_", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 38, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "working_location", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Sponsor ", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-06-01 09:40:42.677407", + "modified_by": "Administrator", + "module": null, + "name": "Employee-sponsor_", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-06-08 12:01:37.102285", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "gross_salary", + "fieldtype": "Currency", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 86, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "salary_information", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Gross Salary", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-06-08 12:01:37.102285", + "modified_by": "Administrator", + "module": null, + "name": "Employee-gross_salary", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 1, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-06-08 15:35:43.218904", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "bfat_details", + "fieldtype": "Section Break", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 116, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "hc_location", + "is_system_generated": 0, + "is_virtual": 0, + "label": "BFAT Details", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-06-08 15:35:43.218904", + "modified_by": "Administrator", + "module": null, + "name": "Employee-bfat_details", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-06-09 08:16:01.437678", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "column_break_uf94t", + "fieldtype": "Column Break", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 89, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "ctc", + "is_system_generated": 0, + "is_virtual": 0, + "label": null, + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-06-09 08:16:01.437678", + "modified_by": "Administrator", + "module": null, + "name": "Employee-column_break_uf94t", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-06-09 08:16:41.084651", + "default": "WPS", + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "wps", + "fieldtype": "Select", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 92, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "salary_mode", + "is_system_generated": 0, + "is_virtual": 0, + "label": "WPS", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-06-09 08:16:41.084651", + "modified_by": "Administrator", + "module": null, + "name": "Employee-wps", + "no_copy": 0, + "non_negative": 0, + "options": "WPS\nNON-WPS", + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-06-09 08:25:13.127950", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "bfat_certificate__number", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 117, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "bfat_details", + "is_system_generated": 0, + "is_virtual": 0, + "label": "BFAT Certificate Number", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-06-09 08:25:13.127950", + "modified_by": "Administrator", + "module": null, + "name": "Employee-bfat_certificate__number", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-06-09 08:25:13.313876", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "bfat_issue_date", + "fieldtype": "Date", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 118, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "bfat_certificate__number", + "is_system_generated": 0, + "is_virtual": 0, + "label": "BFAT Issue Date", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-06-09 08:25:13.313876", + "modified_by": "Administrator", + "module": null, + "name": "Employee-bfat_issue_date", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-06-09 08:25:13.525402", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "bfat_expiry_date", + "fieldtype": "Date", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 119, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "bfat_issue_date", + "is_system_generated": 0, + "is_virtual": 0, + "label": "BFAT Expiry Date", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-06-09 08:25:13.525402", + "modified_by": "Administrator", + "module": null, + "name": "Employee-bfat_expiry_date", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 1, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-06-09 08:42:54.558415", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "ec_detalis", + "fieldtype": "Section Break", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 120, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "bfat_expiry_date", + "is_system_generated": 0, + "is_virtual": 0, + "label": "EC Detalis", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-06-09 08:42:54.558415", + "modified_by": "Administrator", + "module": null, + "name": "Employee-ec_detalis", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-06-09 08:42:54.745997", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "ec_date", + "fieldtype": "Date", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 121, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "ec_detalis", + "is_system_generated": 0, + "is_virtual": 0, + "label": "EC Date", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-06-09 08:42:54.745997", + "modified_by": "Administrator", + "module": null, + "name": "Employee-ec_date", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-06-09 08:42:55.003021", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "duration", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 122, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "ec_date", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Duration", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-06-09 08:42:55.003021", + "modified_by": "Administrator", + "module": null, + "name": "Employee-duration", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-06-09 08:42:55.244348", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "ec_expiry_date", + "fieldtype": "Date", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 123, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "duration", + "is_system_generated": 0, + "is_virtual": 0, + "label": "EC Expiry Date", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-06-09 08:42:55.244348", + "modified_by": "Administrator", + "module": null, + "name": "Employee-ec_expiry_date", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 0, + "unique": 0, + "width": null + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "allow_in_quick_entry": 0, + "allow_on_submit": 0, + "bold": 0, + "collapsible": 0, + "collapsible_depends_on": null, + "columns": 0, + "creation": "2023-06-09 12:27:56.173462", + "default": null, + "depends_on": null, + "description": null, + "docstatus": 0, + "dt": "Employee", + "fetch_from": null, + "fetch_if_empty": 0, + "fieldname": "number_of_years_in_service", + "fieldtype": "Data", + "hidden": 0, + "hide_border": 0, + "hide_days": 0, + "hide_seconds": 0, + "idx": 18, + "ignore_user_permissions": 0, + "ignore_xss_filter": 0, + "in_global_search": 0, + "in_list_view": 0, + "in_preview": 0, + "in_standard_filter": 0, + "insert_after": "date_of_joining", + "is_system_generated": 0, + "is_virtual": 0, + "label": "Number of Years in Service", + "length": 0, + "mandatory_depends_on": null, + "modified": "2023-06-09 12:27:56.173462", + "modified_by": "Administrator", + "module": null, + "name": "Employee-number_of_years_in_service", + "no_copy": 0, + "non_negative": 0, + "options": null, + "owner": "Administrator", + "permlevel": 0, + "precision": "", + "print_hide": 0, + "print_hide_if_no_value": 0, + "print_width": null, + "read_only": 0, + "read_only_depends_on": null, + "report_hide": 0, + "reqd": 0, + "search_index": 0, + "sort_options": 0, + "translatable": 1, + "unique": 0, + "width": null + } + ], + "custom_perms": [ + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "amend": 0, + "cancel": 0, + "create": 0, + "creation": "2022-02-21 11:54:09.632218", + "delete": 0, + "docstatus": 0, + "email": 1, + "export": 0, + "idx": 1, + "if_owner": 0, + "import": 0, + "modified": "2023-01-05 17:46:34.416830", + "modified_by": "Administrator", + "name": "1a745499f6", + "owner": "Administrator", + "parent": "Employee", + "permlevel": 0, + "print": 1, + "read": 1, + "report": 1, + "role": "Employee", + "select": 0, + "set_user_permissions": 0, + "share": 0, + "submit": 0, + "write": 0 + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "amend": 0, + "cancel": 0, + "create": 1, + "creation": "2022-02-21 11:54:09.632218", + "delete": 1, + "docstatus": 0, + "email": 1, + "export": 1, + "idx": 2, + "if_owner": 0, + "import": 1, + "modified": "2023-01-05 17:46:34.424410", + "modified_by": "Administrator", + "name": "a28208e083", + "owner": "Administrator", + "parent": "Employee", + "permlevel": 0, + "print": 1, + "read": 1, + "report": 1, + "role": "HR User", + "select": 0, + "set_user_permissions": 0, + "share": 1, + "submit": 0, + "write": 1 + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "amend": 0, + "cancel": 0, + "create": 1, + "creation": "2022-02-21 11:54:09.632218", + "delete": 1, + "docstatus": 0, + "email": 1, + "export": 1, + "idx": 3, + "if_owner": 0, + "import": 1, + "modified": "2023-01-05 17:46:34.431790", + "modified_by": "Administrator", + "name": "02b4cf5675", + "owner": "Administrator", + "parent": "Employee", + "permlevel": 0, + "print": 1, + "read": 1, + "report": 1, + "role": "HR Manager", + "select": 0, + "set_user_permissions": 1, + "share": 1, + "submit": 0, + "write": 1 + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "amend": 0, + "cancel": 0, + "create": 0, + "creation": "2023-01-18 15:19:14.266199", + "delete": 0, + "docstatus": 0, + "email": 0, + "export": 0, + "idx": 0, + "if_owner": 0, + "import": 0, + "modified": "2023-01-18 15:19:14.266199", + "modified_by": "Administrator", + "name": "d86fc04884", + "owner": "Administrator", + "parent": "Employee", + "permlevel": 0, + "print": 0, + "read": 1, + "report": 0, + "role": "Guest", + "select": 1, + "set_user_permissions": 0, + "share": 0, + "submit": 0, + "write": 0 + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "amend": 0, + "cancel": 0, + "create": 0, + "creation": "2023-01-05 17:46:34.440774", + "delete": 0, + "docstatus": 0, + "email": 1, + "export": 1, + "idx": 0, + "if_owner": 0, + "import": 0, + "modified": "2023-07-25 10:04:16.970428", + "modified_by": "Administrator", + "name": "561c39c47f", + "owner": "Administrator", + "parent": "Employee", + "permlevel": 0, + "print": 1, + "read": 1, + "report": 0, + "role": "Employee Self Service", + "select": 0, + "set_user_permissions": 0, + "share": 1, + "submit": 0, + "write": 1 + } + ], + "doctype": "Employee", + "links": [], + "property_setters": [ + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "creation": "2023-07-25 10:04:08.084633", + "default_value": null, + "doc_type": "Employee", + "docstatus": 0, + "doctype_or_field": "DocField", + "field_name": "naming_series", + "idx": 0, + "is_system_generated": 0, + "modified": "2023-07-25 10:04:08.084633", + "modified_by": "Administrator", + "module": null, + "name": "Employee-naming_series-options", + "owner": null, + "property": "options", + "property_type": "Text", + "row_name": null, + "value": "HR-EMP-" + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "creation": "2023-07-17 14:02:19.191286", + "default_value": null, + "doc_type": "Employee", + "docstatus": 0, + "doctype_or_field": "DocField", + "field_name": "employee_number", + "idx": 0, + "is_system_generated": 0, + "modified": "2023-07-17 14:02:19.191286", + "modified_by": "Administrator", + "module": null, + "name": "Employee-employee_number-hidden", + "owner": "Administrator", + "property": "hidden", + "property_type": "Check", + "row_name": null, + "value": "1" + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "creation": "2023-07-17 14:02:19.170912", + "default_value": null, + "doc_type": "Employee", + "docstatus": 0, + "doctype_or_field": "DocField", + "field_name": "employee_number", + "idx": 0, + "is_system_generated": 0, + "modified": "2023-07-17 14:02:19.170912", + "modified_by": "Administrator", + "module": null, + "name": "Employee-employee_number-reqd", + "owner": "Administrator", + "property": "reqd", + "property_type": "Check", + "row_name": null, + "value": "0" + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "creation": "2023-07-17 14:02:19.111837", + "default_value": null, + "doc_type": "Employee", + "docstatus": 0, + "doctype_or_field": "DocField", + "field_name": "naming_series", + "idx": 0, + "is_system_generated": 0, + "modified": "2023-07-17 14:02:19.111837", + "modified_by": "Administrator", + "module": null, + "name": "Employee-naming_series-reqd", + "owner": "Administrator", + "property": "reqd", + "property_type": "Check", + "row_name": null, + "value": "1" + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "creation": "2023-07-17 14:02:19.034568", + "default_value": null, + "doc_type": "Employee", + "docstatus": 0, + "doctype_or_field": "DocField", + "field_name": "naming_series", + "idx": 0, + "is_system_generated": 0, + "modified": "2023-07-17 14:02:19.034568", + "modified_by": "Administrator", + "module": null, + "name": "Employee-naming_series-hidden", + "owner": "Administrator", + "property": "hidden", + "property_type": "Check", + "row_name": null, + "value": "0" + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "creation": "2023-06-08 13:38:36.827953", + "default_value": null, + "doc_type": "Employee", + "docstatus": 0, + "doctype_or_field": "DocField", + "field_name": "salary_currency", + "idx": 0, + "is_system_generated": 0, + "modified": "2023-06-08 13:38:36.827953", + "modified_by": "Administrator", + "module": null, + "name": "Employee-salary_currency-depends_on", + "owner": "Administrator", + "property": "depends_on", + "property_type": "Data", + "row_name": null, + "value": "eval:doc.salary_mode == 'Bank'" + }, + { + "_assign": null, + "_comments": null, + "_liked_by": null, + "_user_tags": null, + "creation": "2023-05-31 10:13:37.962161", + "default_value": null, + "doc_type": "Employee", + "docstatus": 0, + "doctype_or_field": "DocField", + "field_name": "passport_details_section", + "idx": 0, + "is_system_generated": 0, + "modified": "2023-05-31 10:13:37.962161", + "modified_by": "Administrator", + "module": null, + "name": "Employee-passport_details_section-collapsible", + "owner": "Administrator", + "property": "collapsible", + "property_type": "Check", + "row_name": null, + "value": "1" + } + ], + "sync_on_migrate": 1 +} \ No newline at end of file diff --git a/castle/gauth.py b/castle/gauth.py new file mode 100644 index 0000000..67f7394 --- /dev/null +++ b/castle/gauth.py @@ -0,0 +1,82 @@ +import requests +import json +import frappe + +def getToken(self): + try: + if not username or not password: + frappe.throw("Username and password are required.") + + # Authenticate user credentials + user = frappe.get_doc("User", {"email": username}) + if user and frappe.utils.password.check_password(user.password, password): + # Successful login, generate access token + token = frappe.generate_hash(length=40) # Generate a random access token + frappe.cache().hset("user_tokens", token, user.name) # Store the token in Redis cache + return {"access_token": token} + else: + # Failed login + frappe.throw("Invalid login credentials.") + except Exception as e: + frappe.throw("An error occurred during login.") + + +from frappe.integrations.oauth2 import get_token +@frappe.whitelist(allow_guest=True) +def generate_custom_token(username, password): + try: + if not username or not password: + frappe.throw("Username and password are required.") + #so basically we are going to use inbuilt frappe oauth2 and generate token from it by passing creds + # Use Frappe's oauth2.grant_password function to generate tokens + client_id = "5fed5aada3" # Replace with your OAuth client ID + client_secret = "708c75201b" # Replace with your OAuth client secret + url = "https://castle.erpgulf.com:1813/api/method/castle.gauth.get_token" + payload = {'username': username, + 'password': password, + 'grant_type': 'password', + 'client_id': client_id, + 'client_secret': client_secret} + files=[] + headers = { + 'Content-Type': 'application/json' + } + response = requests.request("POST", url, data=payload, files=files) + return json.loads(response.text) + + + except Exception as e: + frappe.throw("An error occurred during login.") + +from frappe.auth import LoginManager +@frappe.whitelist(allow_guest=True) +def generate_access_token(username, password): + #from frappe.utils.password import check_password + try: + #if not username or not password: + # frappe.throw("Username and password are required.") + + # Authenticate user credentials + login_manager = LoginManager() + user=login_manager.authenticateCustom(user=username,pwd=password) + + response_data = { + "access_token": frappe.session.sid, + "user": user + } + frappe.response["message"]=response_data + #else: + # Failed login + # return {"error": "Invalid login credentials."} + except Exception as e: + frappe.throw("An error occurred during login.") +@frappe.whitelist(allow_guest=True) +def get_all_users(): + try: + # Get all users + users = frappe.get_all("User", fields="*", filters={"enabled": 1}) + + # Return the list of users as JSON + return {"users": users} + except Exception as e: + frappe.throw("An error occurred while fetching users.") \ No newline at end of file diff --git a/castle/hooks.py b/castle/hooks.py index ed82a8a..5a94f69 100644 --- a/castle/hooks.py +++ b/castle/hooks.py @@ -29,7 +29,6 @@ # page_js = {"page" : "public/js/file.js"} # include js in doctype views -# doctype_js = {"doctype" : "public/js/doctype.js"} # doctype_list_js = {"doctype" : "public/js/doctype_list.js"} # doctype_tree_js = {"doctype" : "public/js/doctype_tree.js"} # doctype_calendar_js = {"doctype" : "public/js/doctype_calendar.js"} @@ -215,3 +214,6 @@ # auth_hooks = [ # "castle.auth.validate" # ] + + +doctype_js = {"Employee" : "public/js/employee.js"} diff --git a/castle/public/js/employee.js b/castle/public/js/employee.js new file mode 100644 index 0000000..f3404b5 --- /dev/null +++ b/castle/public/js/employee.js @@ -0,0 +1,61 @@ +// Copyright (c) 2020, ERPGulf . visit our website www.ERPGulf.com for more details +// License: MIT. See LICENSE + +//calculating year of service from joining date , and age from date of birth DOB + +frappe.ui.form.on("Employee", "refresh", function(frm) { + + var today = new Date(); + + // this is how you get data from form + var dateOfBirth = new Date(frm.doc.date_of_birth); + + + var duration = today.getFullYear() - dateOfBirth.getFullYear(); + var m = today.getMonth() - dateOfBirth.getMonth(); + if (m < 0 || (m === 0 && today.getDate() < dateOfBirth.getDate())) { + duration--; + } + frm.set_value('age', duration); + + var dateOfJoining = new Date(frm.doc.date_of_joining); + var yearOfSservice = today.getFullYear() - dateOfJoining.getFullYear(); + var m = today.getMonth() - dateOfJoining.getMonth(); + if (m < 0 || (m === 0 && today.getDate() < dateOfJoining.getDate())) { + yearOfSservice--; + frm.set_value('number_of_years_in_service', yearOfSservice); + } + +}); + +frappe.ui.form.on('Employee', { + + "date_of_birth": function(frm) { + var today = new Date(); + var dateOfBirth = new Date(frm.doc.date_of_birth); + + var duration = today.getFullYear() - dateOfBirth.getFullYear(); + var m = today.getMonth() - dateOfBirth.getMonth(); + if (m < 0 || (m === 0 && today.getDate() < dateOfBirth.getDate())) { + duration--; + } + frm.set_value('age', duration); + } + +}); + +frappe.ui.form.on('Employee', { + + "date_of_joining": function(frm) { + var today = new Date(); + var dateOfJoining = new Date(frm.doc.date_of_joining); + + var yearOfSservice = today.getFullYear() - dateOfJoining.getFullYear(); + var m = today.getMonth() - dateOfJoining.getMonth(); + if (m < 0 || (m === 0 && today.getDate() < dateOfJoining.getDate())) { + yearOfSservice--; + } + frm.set_value('number_of_years_in_service', yearOfSservice); + } + +}); diff --git a/castle/www/__init__.py b/castle/www/__init__.py new file mode 100644 index 0000000..e69de29