Skip to content

Commit

Permalink
Null check for Hierarchy level
Browse files Browse the repository at this point in the history
  • Loading branch information
abishekTa-egov committed Dec 17, 2024
1 parent 0464fd3 commit 46fe9f1
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -191,8 +191,8 @@ const FacilityCatchmentMapping = () => {
{`${t("HCM_MICROPLAN_MICROPLAN_NAME_LABEL")}: ${planObject?.name || t("NO_NAME_AVAILABLE")}`}
</div>
<div>
{`${t("LOGGED_IN_AS")} ${userName} - ${t(userRole)}(${t(planEmployee?.planData[0].hierarchyLevel.toUpperCase())})`}

{`${t("LOGGED_IN_AS")} ${userName} - ${t(userRole)}${planEmployee?.planData?.[0]?.hierarchyLevel ?
` (${t(planEmployee.planData[0].hierarchyLevel.toUpperCase())})` : ""}`}
</div>

</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -836,7 +836,9 @@ const PlanInbox = () => {
<div className="mp-heading-bold">
{`${t("HCM_MICROPLAN_MICROPLAN_NAME_LABEL")}: ${campaignObject?.campaignName || t("NO_NAME_AVAILABLE")}`}
</div>
<div>{`${t("LOGGED_IN_AS")} ${userName} - ${t(userRole)}(${t(planEmployee?.planData[0].hierarchyLevel.toUpperCase())})`}</div>
<div>{`${t("LOGGED_IN_AS")} ${userName} - ${t(userRole)}${planEmployee?.planData?.[0]?.hierarchyLevel ?
` (${t(planEmployee.planData[0].hierarchyLevel.toUpperCase())})` : ""}`}
</div>
</div>
</div>
<GenericKpiFromDSS module="MICROPLAN" status={selectedFilter} planId={microplanId} refetchTrigger={refetchTrigger} campaignType={campaignObject?.projectType} planEmployee={planEmployee} boundariesForKpi={defaultBoundaries}/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -611,7 +611,10 @@ const PopInbox = () => {
{`${t("HCM_MICROPLAN_MICROPLAN_NAME_LABEL")}: ${planObject?.name || t("NO_NAME_AVAILABLE")}`}
</div>
<div>
{`${t("LOGGED_IN_AS")} ${userName} - ${t(userRole)}(${t(planEmployee?.planData[0].hierarchyLevel.toUpperCase())})`}
{`${t("LOGGED_IN_AS")} ${userName} - ${t(userRole)}${planEmployee?.planData
? ` (${t(planEmployee.planData[0].hierarchyLevel.toUpperCase())})` : ""}`
}

</div>

</div>
Expand Down

0 comments on commit 46fe9f1

Please sign in to comment.