Skip to content

Commit

Permalink
Merge pull request #945 from egovernments/ISTE--398-FIX
Browse files Browse the repository at this point in the history
Iste  398 fix
  • Loading branch information
pradeepkumarcm-egov authored Sep 12, 2024
2 parents 8d1ce01 + fdd58ea commit b087198
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -155,11 +155,13 @@ const SearchUserForm = ({ uniqueTenants, setUniqueTenants, roles, setUniqueRoles
const filteredResult = filterKeys(result, requiredKeys);
const resultInTree = buildTree(filteredResult, hierarchy);
const excludeCodes = ["HRMS_ADMIN", "LOC_ADMIN", "MDMS_ADMIN", "EMPLOYEE", "SYSTEM"];
const DIV_ADMIN = Digit.UserService.hasAccess(["DIV_ADMIN"]);

setRolesOptions(
data?.MdmsRes?.["ws-services-masters"]?.["WSServiceRoles"]?.filter(
(row) =>
!excludeCodes.includes(row?.code) &&
(row?.name === "Secretary" || row?.name === "Sarpanch" || row?.name === "Revenue Collector" || row?.name === "DIVISION ADMIN")
(row?.name === "Secretary" || row?.name === "Sarpanch" || row?.name === "Revenue Collector" || !DIV_ADMIN && row?.name === "DIVISION ADMIN")
)
);
//updating to state roles as requested
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,9 +88,7 @@ const HRMSCard = () => {
category: t("SEARCH_USER_HEADER"),
},

DIV_ADMIN
? {}
: {
{
label: t("HR_STATE_ REPORTS"),
link: `/${window?.contextPath}/employee/hrms/dashboard?moduleName=dashboard&pageName=state`,
category: t("HR_DASHBOARD_HEADER"),
Expand All @@ -100,6 +98,11 @@ const HRMSCard = () => {
link: `/${window?.contextPath}/employee/hrms/dashboard?moduleName=dashboard&pageName=rate-master`,
category: t("HR_DASHBOARD_HEADER"),
},
{
label: t("HR_ROLLOUT_DASHBOARD"),
link: `/${window?.contextPath}/employee/hrms/dashboard?moduleName=dashboard&pageName=rollout`,
category: t("HR_DASHBOARD_HEADER"),
},
...moduleForSomeDIVAdmin,
...moduleForSomeSTATEUser,
...moduleForDivisionUser,
Expand Down

0 comments on commit b087198

Please sign in to comment.