Skip to content

Commit

Permalink
Merge pull request #725 from odisha-muktasoft/UCE,-765-2
Browse files Browse the repository at this point in the history
UCEM-765 : updated locality code for wage seeker modification
  • Loading branch information
Tulika-eGov authored Oct 18, 2024
2 parents 7f30f19 + f15699f commit 6227fe8
Showing 1 changed file with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -88,15 +88,19 @@ const requestCriteria = {
const wards = []
const localities = {}
data?.TenantBoundary[0]?.boundary.sort((a, b) => a.code.localeCompare(b.code)).forEach((item) => {
localities[item?.code] = item?.children.map(item => ({ code: item.code, name: t(`${headerLocale}_ADMIN_${item?.code}`), i18nKey: `${headerLocale}_ADMIN_${item?.code}`, label : item?.label }))
localities[item?.code] = item?.children.map(item => ({ code: item.code, name: t(`${headerLocale}_ADMIN_${item?.code}`), i18nKey: `${headerLocale}_ADMIN_${item?.code}`, label : t(`${headerLocale}_ADMIN_${item?.code}`)}))
wards.push({ code: item.code, name: t(`${headerLocale}_ADMIN_${item?.code}`), i18nKey: `${headerLocale}_ADMIN_${item?.code}` })
});
return {
wards, localities
}
}
},true);
const filteredLocalities = wardsAndLocalities?.localities[selectedWard];
// const filteredLocalities = wardsAndLocalities?.localities[selectedWard];
let filteredLocalities = []
wardsAndLocalities ? Object.values(wardsAndLocalities?.localities).forEach(localities => {
filteredLocalities = filteredLocalities.concat(localities)
}) : []

//wage seeker form config
const config = useMemo(
Expand All @@ -120,7 +124,7 @@ const requestCriteria = {
},
{
key : 'locDetails_locality',
value : [filteredLocalities]
value : [filteredLocalities.sort((a, b) => a.code.localeCompare(b.code))]
},
{
key : "basicDetails_wageSeekerId",
Expand Down

0 comments on commit 6227fe8

Please sign in to comment.