From a637f086aeffc1cc1b4a27e1a81b2d6a232770f8 Mon Sep 17 00:00:00 2001 From: Abishek Date: Wed, 10 Jun 2026 15:36:59 +0530 Subject: [PATCH 1/3] fix(payroll): use Salary Component Account for company filtering in Employee Incentive Employee Incentive filtered Salary Components using the Salary Component.company field, which triggered field-level permission checks and caused a Permission Error for users without access to that field. Updated the filtering logic to derive company-specific Salary Components from Salary Component Account instead of directly accessing Salary Component.company. This preserves the intended filtering behavior while preventing permission errors when selecting Salary Components in Employee Incentive. Fixes #4690 --- hrms/payroll/doctype/employee_incentive/employee_incentive.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hrms/payroll/doctype/employee_incentive/employee_incentive.js b/hrms/payroll/doctype/employee_incentive/employee_incentive.js index 49de854752..b4356b2d0d 100644 --- a/hrms/payroll/doctype/employee_incentive/employee_incentive.js +++ b/hrms/payroll/doctype/employee_incentive/employee_incentive.js @@ -47,7 +47,8 @@ frappe.ui.form.on("Employee Incentive", { if (!frm.doc.company) return; frm.set_query("salary_component", function () { return { - filters: { type: "earning" }, + filters: { type: "earning", company: frm.doc.company }, + query: "hrms.payroll.doctype.salary_structure.salary_structure.get_salary_component", }; }); }, From eea1fab68199e423f61eadce2345570a92dba60c Mon Sep 17 00:00:00 2001 From: Abishek Date: Wed, 10 Jun 2026 15:50:11 +0530 Subject: [PATCH 2/3] fix: Filter the Earning component in Employee Incentive --- hrms/payroll/doctype/employee_incentive/employee_incentive.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hrms/payroll/doctype/employee_incentive/employee_incentive.js b/hrms/payroll/doctype/employee_incentive/employee_incentive.js index b4356b2d0d..1694eb6980 100644 --- a/hrms/payroll/doctype/employee_incentive/employee_incentive.js +++ b/hrms/payroll/doctype/employee_incentive/employee_incentive.js @@ -47,7 +47,7 @@ frappe.ui.form.on("Employee Incentive", { if (!frm.doc.company) return; frm.set_query("salary_component", function () { return { - filters: { type: "earning", company: frm.doc.company }, + filters: { component_type: "Earning", company: frm.doc.company }, query: "hrms.payroll.doctype.salary_structure.salary_structure.get_salary_component", }; }); From 4e7a20a6f19970ddb456899151152c500a8fbbb7 Mon Sep 17 00:00:00 2001 From: Asmita Hase Date: Fri, 19 Jun 2026 11:47:04 +0530 Subject: [PATCH 3/3] fix: package frontend and roster assets from public dir --- .github/workflows/build-and-commit-assets.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-and-commit-assets.yml b/.github/workflows/build-and-commit-assets.yml index 11ffc911da..059a5d27f1 100644 --- a/.github/workflows/build-and-commit-assets.yml +++ b/.github/workflows/build-and-commit-assets.yml @@ -64,7 +64,7 @@ jobs: - name: Package assets working-directory: apps/hrms - run: tar czf hrms-assets.tar.gz -C ../../sites/assets/hrms dist frontend roster + run: tar czf hrms-assets.tar.gz -C ../../sites/assets/hrms dist -C "$PWD/hrms/public" frontend roster - name: Upload to rolling release working-directory: apps/hrms