@asaleh37/ui-base 25.8.31-1 → 25.8.31-2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +3 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +2 -2
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/util/AppUtils.ts +18 -0
package/dist/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../node_modules/style-inject/dist/style-inject.es.js","../src/hooks/UseMobile.tsx","../src/redux/features/common/AppLayoutSlice.ts","../src/redux/features/common/LoadingMaskSlice.ts","../src/hooks/useLoadingMask.tsx","../src/redux/features/common/UserSessionSlice.ts","../src/hooks/useAxios.tsx","../src/hooks/UseConfirmationWindow.tsx","../src/hooks/UseSession.tsx","../src/hooks/UseWindow.tsx","../src/redux/features/common/CommonStoreSlice.ts","../src/hooks/useApiActions.ts","../src/components/templates/DataEntryTemplates/TemplateDataForm/FormFields/TemplateTextField.tsx","../src/components/templates/TransferList.tsx","../src/components/templates/DataEntryTemplates/TemplateDataForm/FormFields/CheckBox.tsx","../src/components/templates/DataEntryTemplates/TemplateDataForm/FormFields/ComboBox.tsx","../src/util/constants.ts","../src/components/templates/DataEntryTemplates/TemplateDataForm/FormFields/Datefield.tsx","../src/components/templates/DataEntryTemplates/TemplateDataForm/FormFields/DatetimeField.tsx","../src/components/templates/DataEntryTemplates/TemplateDataForm/FormFields/SystemLookupCombobox.tsx","../src/components/templates/DataEntryTemplates/TemplateDataGrid/DataGridColumnsUtil.tsx","../src/components/templates/DataEntryTemplates/DataEntryUtil.ts","../node_modules/@mui/utils/esm/formatMuiErrorMessage/formatMuiErrorMessage.js","../node_modules/prop-types/node_modules/react-is/index.js","../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../node_modules/object-assign/index.js","../node_modules/prop-types/lib/ReactPropTypesSecret.js","../node_modules/prop-types/lib/has.js","../node_modules/prop-types/checkPropTypes.js","../node_modules/prop-types/factoryWithTypeCheckers.js","../node_modules/prop-types/factoryWithThrowingShims.js","../node_modules/prop-types/index.js","../node_modules/react-is/cjs/react-is.production.js","../node_modules/react-is/cjs/react-is.development.js","../node_modules/react-is/index.js","../node_modules/@mui/utils/esm/deepmerge/deepmerge.js","../node_modules/@mui/system/esm/createBreakpoints/createBreakpoints.js","../node_modules/@mui/system/esm/cssContainerQueries/cssContainerQueries.js","../node_modules/@mui/system/esm/createTheme/shape.js","../node_modules/@mui/system/esm/responsivePropType/responsivePropType.js","../node_modules/@mui/system/esm/merge/merge.js","../node_modules/@mui/system/esm/breakpoints/breakpoints.js","../node_modules/@mui/utils/esm/capitalize/capitalize.js","../node_modules/@mui/system/esm/style/style.js","../node_modules/@mui/system/esm/spacing/spacing.js","../node_modules/@mui/system/esm/memoize/memoize.js","../node_modules/@mui/system/esm/compose/compose.js","../node_modules/@mui/system/esm/borders/borders.js","../node_modules/@mui/system/esm/cssGrid/cssGrid.js","../node_modules/@mui/system/esm/palette/palette.js","../node_modules/@mui/system/esm/sizing/sizing.js","../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../node_modules/@mui/system/esm/createTheme/applyStyles.js","../node_modules/@mui/system/esm/useThemeWithoutDefault/useThemeWithoutDefault.js","../node_modules/@mui/system/esm/useTheme/useTheme.js","../node_modules/@mui/system/esm/createTheme/createTheme.js","../node_modules/@mui/system/esm/createTheme/createSpacing.js","../node_modules/@mui/system/esm/styleFunctionSx/extendSxProp.js","../node_modules/@mui/utils/esm/ClassNameGenerator/ClassNameGenerator.js","../node_modules/clsx/dist/clsx.mjs","../node_modules/@mui/utils/esm/generateUtilityClass/generateUtilityClass.js","../node_modules/@mui/system/esm/Box/boxClasses.js","../node_modules/@mui/system/esm/Box/Box.js","../node_modules/@mui/system/esm/createBox/createBox.js","../node_modules/@mui/styled-engine/esm/index.js","../node_modules/@mui/utils/esm/generateUtilityClasses/generateUtilityClasses.js","../src/util/AppUtils.ts","../src/components/templates/DataEntryTemplates/TemplateDataForm/FormElementField.tsx","../src/components/templates/DataEntryTemplates/TemplateDataForm/FormAction.tsx","../src/components/templates/DataEntryTemplates/TemplateDataForm/FormElementGroup.tsx","../src/components/templates/attachment/AttachmentImageViewer.tsx","../src/components/templates/attachment/AttachmentCard.tsx","../src/components/templates/attachment/AttachmentPanel.tsx","../src/components/templates/workflow/WorkflowDocumentTimeLine.tsx","../src/components/templates/DataEntryTemplates/TemplateDataGrid/TemplateGridMultiRecordAction.tsx","../src/components/templates/DataEntryTemplates/TemplateDataGrid/TemplateGridTopBar.tsx","../src/components/templates/DataEntryTemplates/TemplateDataGrid/TemplateGridRecordAction.tsx","../src/components/templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid.tsx","../src/hooks/useLookupGridColumn.tsx","../src/components/templates/report/ExcelReportViewer.tsx","../src/hooks/useParameterPanel.tsx","../src/components/templates/report/ReportViewer.tsx","../src/components/templates/workflow/WorkflowDocumentPanel.tsx","../src/components/templates/DataEntryTemplates/TemplateDataForm/TemplateForm.tsx","../src/components/templates/workflow/WorkflowRouteComponent.tsx","../src/components/templates/visuals/charts/TemplateBarChart.tsx","../src/components/templates/visuals/charts/TemplateDataCard.tsx","../src/components/templates/visuals/charts/TemplateGauge.tsx","../src/components/templates/visuals/charts/TemplateLineChart.tsx","../src/components/templates/visuals/charts/TemplateLineProgress.tsx","../src/components/templates/visuals/charts/TemplatePieChart.tsx","../src/components/templates/visuals/WidgetViewer.tsx","../src/components/templates/visuals/DashboardViewer.tsx","../src/components/templates/visuals/DashboardRouteView.tsx","../src/components/common/ChangeOrgForm.tsx","../src/redux/features/common/SideBarSlice.ts","../src/hooks/useInterval.tsx","../src/components/common/NotificationItem.tsx","../src/layout/NotificationButton.tsx","../src/components/administration/admin/ChangePasswordPanel.tsx","../src/layout/TopBar.tsx","../src/locales/i18n.ts","../src/layout/DrawerHeader.tsx","../src/navigationItems/index.tsx","../src/navigationItems/Administration/index.tsx","../src/navigationItems/Administration/adminNavigationItems.tsx","../src/layout/NavigationTree.tsx","../src/layout/SideBar.tsx","../src/components/common/LayoutHandlers.tsx","../src/components/administration/admin/OrgMemberRoleForm.tsx","../src/components/administration/admin/OrganizationMemberGrid.tsx","../src/components/administration/admin/OrganizationRankGrid.tsx","../src/components/administration/admin/OrganizationUnitGrid.tsx","../src/components/administration/admin/OrganizationUnitTypeGrid.tsx","../src/components/administration/admin/SystemApplicationAuthorityGrid.tsx","../src/components/administration/admin/SystemApplicationModuleGrid.tsx","../src/components/administration/admin/RoleAuthoritiesForm.tsx","../src/components/administration/admin/SystemApplicationRoleGrid.tsx","../src/components/administration/dev/DataQueryParameterGrid.tsx","../src/components/administration/dev/LookupGrid.tsx","../src/components/administration/dev/ReportParameterGrid.tsx","../src/components/administration/dev/AttachmentConfigGrid.tsx","../src/components/administration/dev/ReportGrid.tsx","../src/components/administration/dev/MailRecipientGrid.tsx","../src/components/administration/dev/MailBodyGrid.tsx","../src/components/administration/dev/MailAttachmentGrid.tsx","../src/components/administration/dev/MailSenderConfigGrid.tsx","../src/components/administration/dev/WorkflowDocumentStatusGrid.tsx","../src/components/administration/dev/WorkflowDocumentActionMailGrid.tsx","../src/components/administration/dev/WorkflowDocumentActionGrid.tsx","../src/components/administration/dev/DashboardWidgetGrid.tsx","../src/routes/index.ts","../src/routes/administration/index.ts","../src/routes/administration/adminRoutes.tsx","../src/components/administration/admin/OrganizationGrid.tsx","../src/components/administration/admin/OrganizationMemberRoleGrid.tsx","../src/components/administration/admin/PersonGrid.tsx","../src/components/administration/admin/SystemApplicationGrid.tsx","../src/components/administration/admin/SystemApplicationRoleAuthorityGrid.tsx","../src/components/administration/admin/OrganizationApplicationModuleGrid.tsx","../src/routes/administration/devRoutes.tsx","../src/components/administration/dev/BluePrintGrid.tsx","../src/components/administration/dev/DataQueryGrid.tsx","../src/components/administration/dev/DatasourceConnectionGrid.tsx","../src/components/administration/dev/EntityParameterGrid.tsx","../src/components/administration/dev/MailTemplateGrid.tsx","../src/components/administration/dev/WorkflowDocumentGrid.tsx","../src/components/administration/dev/WidgetGrid.tsx","../src/components/administration/dev/DashboardGrid.tsx","../src/components/administration/dev/WorkflowDocumentMailLogGrid.tsx","../src/components/administration/dev/MailNotificationQueueGrid.tsx","../src/components/administration/dev/NotificationGrid.tsx","../src/components/common/MyNotificationsPanel.tsx","../src/layout/RouteWrapper.tsx","../src/layout/MainContent.tsx","../src/layout/MobileDrawer.tsx","../src/components/common/LoadingMask.tsx","../src/components/common/Login.tsx","../src/components/common/NoLicenseComponent.tsx","../src/layout/Layout.tsx","../src/redux/features/common/AppInfoSlice.ts","../src/redux/features/administration/AdministrationStoresMetaData.ts","../src/components/App.tsx","../src/locales/english/index.ts","../src/locales/arabic/index.ts","../src/components/BaseApp.tsx"],"sourcesContent":["function styleInject(css, ref) {\n if ( ref === void 0 ) ref = {};\n var insertAt = ref.insertAt;\n\n if (!css || typeof document === 'undefined') { return; }\n\n var head = document.head || document.getElementsByTagName('head')[0];\n var style = document.createElement('style');\n style.type = 'text/css';\n\n if (insertAt === 'top') {\n if (head.firstChild) {\n head.insertBefore(style, head.firstChild);\n } else {\n head.appendChild(style);\n }\n } else {\n head.appendChild(style);\n }\n\n if (style.styleSheet) {\n style.styleSheet.cssText = css;\n } else {\n style.appendChild(document.createTextNode(css));\n }\n}\n\nexport default styleInject;\n","import { useEffect, useState } from \"react\";\n\nexport const useIsMobile = (breakpoint = 768) => {\n const [isMobile, setIsMobile] = useState(window.innerWidth < breakpoint);\n\n useEffect(() => {\n const handleResize = () => setIsMobile(window.innerWidth < breakpoint);\n window.addEventListener(\"resize\", handleResize);\n return () => window.removeEventListener(\"resize\", handleResize);\n }, [breakpoint]);\n\n return isMobile;\n};\n","import { createSlice } from \"@reduxjs/toolkit\";\n\nexport const DRAWER_WIDTH = 350;\n\ninterface AppLayoutState {\n themeMode: \"light\" | \"dark\" | string;\n appDirection: \"ltr\" | \"rtl\";\n}\n\nconst initialState: AppLayoutState = {\n themeMode: localStorage.getItem(\"themeMode\") || \"light\",\n appDirection: localStorage.getItem(\"language\") == \"ar\" ? \"rtl\" : \"ltr\",\n};\n\nconst AppLayoutSlice = createSlice({\n name: \"AppLayout\",\n initialState,\n reducers: {\n setThemeMode: (state, action) => {\n state.themeMode = action.payload;\n },\n setAppDirection: (state, action) => {\n state.appDirection = action.payload;\n },\n },\n});\n\nexport const AppLayoutActions = AppLayoutSlice.actions;\nexport default AppLayoutSlice.reducer;\n","import { createSlice, PayloadAction } from \"@reduxjs/toolkit\";\n\ninterface LoadingMaskStateValue {\n value: { isOpened: boolean; message?: string | null };\n}\n\nconst initialState: LoadingMaskStateValue = {\n value: { isOpened: false, message: null },\n};\n\nconst loadingMaskSlice = createSlice({\n name: \"loadingMask\",\n initialState,\n reducers: {\n showLoadingMask: (\n state,\n action: PayloadAction<string | null | undefined>\n ) => {\n state.value.isOpened = true;\n state.value.message = action.payload;\n },\n hideLoadingMask: (state) => {\n state.value.isOpened = false;\n state.value.message = null;\n },\n },\n});\n\nexport const { showLoadingMask, hideLoadingMask } = loadingMaskSlice.actions;\nexport default loadingMaskSlice.reducer;\n","import { useDispatch } from \"react-redux\";\nimport { hideLoadingMask, showLoadingMask } from \"../redux/features/common/LoadingMaskSlice\";\n\n\nconst useLoadingMask = () => {\n const dispatch = useDispatch();\n const show = (message?: string) => {\n dispatch(showLoadingMask(message));\n };\n const hide = () => {\n dispatch(hideLoadingMask());\n };\n return { show, hide };\n};\n\nexport default useLoadingMask;\n","import { createSlice } from \"@reduxjs/toolkit\";\n\nexport interface OrganizationProps {\n organizationCode?: string;\n organizationName?: string;\n}\n\nexport interface UserSessionProps {\n value: {\n isAuthenticated: boolean | null;\n employeeNumber?: string;\n employeeName?: string;\n mobileNumber?: string;\n email?: string;\n isEmployeeArchived?: string;\n organizationCode?: string;\n organizationUnitId?: string;\n organizationUnitArName?: string;\n organizationUnitEnName?: string;\n organizationRankId?: string;\n rankCode?: string;\n rankName?: string;\n rankOrder?: string;\n currentOrganization?: any;\n userOrganizations?: Array<OrganizationProps>;\n authorities: Array<{ authority: string }>;\n };\n}\n\nconst initialState: UserSessionProps = {\n value: {\n isAuthenticated: null,\n authorities: [],\n },\n};\n\nconst UserSessionSlice = createSlice({\n name: \"UserSession\",\n initialState,\n reducers: {\n setAuthenticated: (state, action) => {\n state.value = action.payload;\n },\n setUnAuthenticated: (state) => {\n state.value = {\n isAuthenticated: false,\n authorities: [],\n };\n },\n },\n});\n\nexport const UserSessionActions = UserSessionSlice.actions;\nexport default UserSessionSlice.reducer;\n","import { toast } from \"react-toastify\";\nimport axios, { ResponseType } from \"axios\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport useLoadingMask from \"./useLoadingMask\";\nimport { UserSessionActions } from \"../redux/features/common/UserSessionSlice\";\n\nexport interface APIRequest {\n endPointURI: string;\n parameters?: any;\n data?: any;\n showMask?: Boolean;\n loadingMessage?: string;\n successCallBkFn?: Function;\n failureCallBkFn?: Function;\n headers?: any;\n responseType?: ResponseType;\n}\n\nexport interface UploadAttachmentRequest {\n endPointURI: string;\n showMask?: Boolean;\n parameters?: any;\n loadingMessage?: string;\n successCallBkFn?: Function;\n failureCallBkFn?: Function;\n files: FileList;\n}\n\nconst useAxios = () => {\n const mask = useLoadingMask();\n const dispatch = useDispatch();\n const apiBaseUrl = useSelector(\n (state: any) => state.AppInfo.value.apiBaseUrl\n );\n const axiosInstance = axios.create({\n baseURL: apiBaseUrl,\n timeout: 600000,\n withCredentials: true,\n });\n\n axiosInstance.defaults.withCredentials = true;\n axiosInstance.interceptors.request.use(\n (config) => {\n const token = localStorage.getItem(\"TOKEN\");\n if (token) {\n config.headers.Authorization = `Bearer ${token}`;\n }\n return config;\n },\n (error) => Promise.reject(error)\n );\n axiosInstance.interceptors.response.use(\n (response: any) => {\n return response;\n },\n (error: any) => {\n if (\n error\n ? error.response\n ? error.response.status\n ? error.response.status === 401\n : false\n : false\n : false\n ) {\n dispatch(UserSessionActions.setUnAuthenticated());\n toast.error(\"your session is now expired, you need to login again\", {\n autoClose: false,\n });\n } else if (\n error\n ? error.response\n ? error.response.status\n ? error.response.status === 402\n : false\n : false\n : false\n ) {\n dispatch(UserSessionActions.setUnAuthenticated());\n toast.error(\n \"Your license is missing or has expired,Please reach out to your vendor for assistance.\"\n );\n } else if (\n error\n ? error.response\n ? error.response.status\n ? error.response.status === 403\n : false\n : false\n : false\n ) {\n toast.error(\"you aren't authorized to process this request\");\n } else if (\n error\n ? error.response\n ? error.response.status\n ? error.response.status === 500\n : false\n : false\n : false\n ) {\n if (error.response.data instanceof Blob) {\n const blob = error.response.data;\n blob.text().then((text) => {\n toast.error(text);\n });\n } else {\n toast.error(error.response.data);\n }\n } else {\n toast.error(\n \"failed to communicate with the server ... try again later\"\n );\n }\n return \"ERROR\";\n }\n );\n const handleGetRequest = async (props: APIRequest) => {\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.show(props.loadingMessage);\n }\n const response: any = await axiosInstance.get(props.endPointURI, {\n params: { ...props.parameters },\n withCredentials: true,\n headers: props.headers,\n responseType: props?.responseType,\n });\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.hide();\n }\n if (response !== \"ERROR\") {\n if (\n props.successCallBkFn !== undefined &&\n props.successCallBkFn != null\n ) {\n props.successCallBkFn(response);\n }\n return response;\n } else {\n if (\n props.failureCallBkFn !== undefined &&\n props.failureCallBkFn != null\n ) {\n props.failureCallBkFn(response);\n }\n return \"ERROR\";\n }\n };\n\n const HandleDownloadHTTPPostPDF = async (\n props: APIRequest = { endPointURI: \"\", parameters: {}, data: {} }\n ) => {\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.show(props.loadingMessage);\n }\n const response: any = await axiosInstance.post(\n props.endPointURI,\n props.data,\n {\n responseType: \"blob\",\n }\n );\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.hide();\n }\n if (response !== \"ERROR\") {\n if (\n props.successCallBkFn !== undefined &&\n props.successCallBkFn != null\n ) {\n props.successCallBkFn(response);\n }\n return response;\n } else {\n if (\n props.failureCallBkFn !== undefined &&\n props.failureCallBkFn != null\n ) {\n props.failureCallBkFn(response);\n }\n return \"ERROR\";\n }\n };\n const handlePostRequest = async (props: APIRequest) => {\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.show(props.loadingMessage);\n }\n let response: any = await axiosInstance.post(\n props.endPointURI,\n props.data,\n {\n params: props.parameters,\n responseType: props?.responseType,\n headers: props?.headers,\n }\n );\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.hide();\n }\n if (response !== \"ERROR\") {\n if (\n props.successCallBkFn !== undefined &&\n props.successCallBkFn != null\n ) {\n props.successCallBkFn(response);\n }\n return response;\n } else {\n if (\n props.failureCallBkFn !== undefined &&\n props.failureCallBkFn != null\n ) {\n props.failureCallBkFn(response);\n }\n return \"ERROR\";\n }\n };\n const handleDeleteRequest = async (props: APIRequest) => {\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.show(props.loadingMessage);\n }\n let response: any = await axiosInstance.delete(props.endPointURI, {\n params: {\n ...props.parameters,\n },\n responseType: props?.responseType,\n headers: props?.headers,\n });\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.hide();\n }\n if (response !== \"ERROR\") {\n if (\n props.successCallBkFn !== undefined &&\n props.successCallBkFn != null\n ) {\n props.successCallBkFn(response);\n }\n return response;\n } else {\n if (\n props.failureCallBkFn !== undefined &&\n props.failureCallBkFn != null\n ) {\n props.failureCallBkFn(response);\n }\n return \"ERROR\";\n }\n };\n\n const handleUploadRequest = async (props: UploadAttachmentRequest) => {\n if (props.files === null || props.files.length === 0) {\n toast.error(\"You must add files to upload\");\n return \"ERROR\";\n }\n const formData = new FormData();\n for (const file of props.files) {\n formData.append(\"files\", file);\n }\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.show(props.loadingMessage);\n }\n let response: any = await axiosInstance.post(props.endPointURI, formData, {\n params: props?.parameters,\n headers: {\n \"Content-Type\": \"multipart/form-data\",\n },\n });\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.hide();\n }\n if (response !== \"ERROR\") {\n if (\n props.successCallBkFn !== undefined &&\n props.successCallBkFn != null\n ) {\n props.successCallBkFn(response);\n }\n return response;\n } else {\n if (\n props.failureCallBkFn !== undefined &&\n props.failureCallBkFn != null\n ) {\n props.failureCallBkFn(response);\n }\n return \"ERROR\";\n }\n };\n return {\n handleGetRequest,\n handlePostRequest,\n handleDeleteRequest,\n HandleDownloadHTTPPostPDF,\n handleUploadRequest,\n };\n};\n\nexport default useAxios;\n","import {\n Button,\n Dialog,\n DialogActions,\n DialogContent,\n DialogContentText,\n DialogTitle,\n} from \"@mui/material\";\nimport { useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\ninterface ConfirmationWindowProps {\n title: string;\n body: string;\n onConfirmationCallBk: () => void;\n}\n\nexport const useConfirmationWindow = (props: ConfirmationWindowProps) => {\n const [open, setOpen] = useState<boolean>(false);\n const { t } = useTranslation();\n const ConfirmationWindow: React.FC = () => {\n return (\n <Dialog open={open}>\n <DialogTitle>{props.title}</DialogTitle>\n <DialogContent>\n <DialogContentText>{props.body}</DialogContentText>\n </DialogContent>\n <DialogActions>\n <Button\n variant=\"contained\"\n sx={{marginRight:2,marginLeft:2}}\n color=\"primary\"\n onClick={() => {\n setOpen(false);\n }}\n >\n {t(\"NO_LABEL\")}\n </Button>\n <Button\n variant=\"contained\"\n sx={{marginRight:2,marginLeft:2}}\n color=\"error\"\n onClick={() => {\n props.onConfirmationCallBk();\n setOpen(false);\n }}\n autoFocus\n >\n {t(\"YES_LABEL\")}\n </Button>\n </DialogActions>\n </Dialog>\n );\n };\n return { ConfirmationWindow, open, setOpen };\n};\n","import { useSelector } from \"react-redux\";\n\nconst useSession = () => {\n const UserSession = useSelector((state: any) => state.UserSession);\n const UserInfo = UserSession.value;\n\n const isCurrentOrganizationAuthorizedToModule = (\n moduleCode: string\n ): Boolean => {\n if (UserInfo?.currentOrganization?.systemApplicationModules) {\n for (const subscripedModule of UserInfo.currentOrganization\n .systemApplicationModules) {\n if (subscripedModule.toLowerCase() == moduleCode.toLowerCase()) {\n return true;\n }\n }\n }\n return false;\n };\n const isUserAuthorized = (authorityCode: string): boolean => {\n if (UserSession?.value?.authorities) {\n for (let grantedAuthority of UserSession.value.authorities) {\n if (\n authorityCode === \"DEVELOPMENT_ADMIN\" &&\n (grantedAuthority?.authority === \"DEVELOPMENT_ADMIN\" ||\n grantedAuthority?.authority === \"ORGANIZATION_ADMIN\")\n ) {\n return true;\n } else if (\n authorityCode === \"ORGANIZATION_ADMIN\" &&\n grantedAuthority?.authority === \"ORGANIZATION_ADMIN\"\n ) {\n return true;\n } else if (\n authorityCode !== \"DEVELOPMENT_ADMIN\" &&\n authorityCode !== \"ORGANIZATION_ADMIN\"\n ) {\n if (\n grantedAuthority?.authority === \"ORGANIZATION_ADMIN\" ||\n grantedAuthority?.authority === \"DEVELOPMENT_ADMIN\" ||\n grantedAuthority?.authority === \"SYSTEM_ADMIN\" ||\n grantedAuthority?.authority === authorityCode\n ) {\n return true;\n }\n }\n }\n }\n return false;\n };\n return {\n UserSession,\n isUserAuthorized,\n isCurrentOrganizationAuthorizedToModule,\n UserInfo,\n };\n};\n\nexport default useSession;\n","import { useEffect, useState } from \"react\";\nimport {\n AppBar,\n Box,\n IconButton,\n Modal,\n Paper,\n Toolbar,\n Typography,\n} from \"@mui/material\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { IconProp } from \"@fortawesome/fontawesome-svg-core\";\nimport { useSelector } from \"react-redux\";\n\nexport interface TemplateWindowProp {\n height?: any;\n width?: any;\n minWidth?: any;\n minHeight?: any;\n windowIcon?: IconProp;\n windowTitle?: string;\n onCloseCallBack?: any;\n}\n\ninterface WindowProps {\n children?: React.ReactNode;\n}\n\nexport const useWindow = (props: TemplateWindowProp) => {\n const [windowState, setWindowState] = useState(false);\n const appDirection = useSelector(\n (state: any) => state.AppLayout.appDirection\n );\n const Window: React.FC<WindowProps> = (windowProps: WindowProps) => {\n return (\n <Modal\n open={windowState}\n sx={{ zIndex: (theme) => theme.zIndex.drawer }}\n onClose={() => {\n if (!windowState && props?.onCloseCallBack) {\n props.onCloseCallBack();\n }\n }}\n >\n <Box\n dir={appDirection}\n sx={{\n position: \"absolute\",\n top: \"50%\",\n left: \"50%\",\n maxHeight: \"90%\",\n transform: \"translate(-50%, -50%)\",\n height: props?.height || \"80%\",\n width: props?.width || \"90%\",\n minWidth: props.minWidth || 400,\n minHeight: props.minHeight || 200,\n overflow: \"hidden\",\n bgcolor: \"modalBackground.main\",\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n }}\n >\n <AppBar position=\"static\">\n <Toolbar variant=\"dense\">\n <FontAwesomeIcon\n icon={props?.windowIcon || \"window-maximize\"}\n style={{ marginRight: 5 }}\n />\n <Typography variant=\"h6\" color=\"inherit\" component=\"div\">\n {props?.windowTitle || \"window\"}\n </Typography>\n <div style={{ flexGrow: 1 }}></div>\n <IconButton\n onClick={() => {\n setWindowState(false);\n if (\n props.onCloseCallBack != undefined &&\n props.onCloseCallBack != null\n ) {\n props.onCloseCallBack();\n }\n }}\n color=\"secondary\"\n >\n <FontAwesomeIcon icon=\"xmark-square\" />\n </IconButton>\n </Toolbar>\n </AppBar>\n <Paper\n sx={{\n // flexGrow: 1,\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n width: \"100%\",\n height: \"100%\",\n padding: 1,\n // justifyContent: \"center\",\n overflow: \"hidden\",\n }}\n >\n {windowProps?.children}\n </Paper>\n </Box>\n </Modal>\n );\n };\n return { windowState, setWindowState, Window };\n};\n","import { createSlice, PayloadAction } from \"@reduxjs/toolkit\";\n\nexport type CommonStores = {\n [key: string]: StoreMetaData;\n};\n\nexport type CommonStoresInterface = {\n stores: { [key: string]: StoreMetaData };\n storeKeys: Array<String>;\n};\n\ninterface setStoreDataProps {\n storeKey: string;\n data: Array<any>;\n}\n\nexport type StoreMetaData = {\n url: string;\n data: Array<any>;\n autoLoad: boolean;\n authority?: string;\n};\n\nexport const commonStoresInitialState: CommonStoresInterface = {\n stores: {},\n storeKeys: [],\n};\n\nconst commonStoreSlice = createSlice({\n name: \"commonStores\",\n initialState: commonStoresInitialState,\n reducers: {\n setStoresMetaData: (state, action) => {\n state.stores = action.payload;\n state.storeKeys = Object.keys(action.payload);\n },\n setStoreData: (state, action: PayloadAction<setStoreDataProps>) => {\n state.stores[action.payload.storeKey].data = action.payload.data;\n },\n },\n});\n\nexport const { setStoreData, setStoresMetaData } = commonStoreSlice.actions;\nexport default commonStoreSlice.reducer;\n","import { useDispatch, useSelector } from \"react-redux\";\nimport useSession from \"./UseSession\";\nimport useAxios from \"./useAxios\";\nimport { setStoreData } from \"../redux/features/common/CommonStoreSlice\";\n\nexport type ApiActionsProps = {\n findAll?: string;\n commonStoreKey?: string;\n setData?: any;\n findById?: string;\n findByIdParamName?: string;\n save?: string;\n deleteById?: string;\n deleteByIdParamName?: string;\n};\n\nexport type ApiActions = {\n reloadData: (params?: any) => Promise<void>;\n saveRecord: (record: any) => Promise<any | null>;\n loadRecordById: (recordId: any) => Promise<any>;\n deleteRecordById: (recordId: any) => Promise<boolean>;\n};\n\nconst useApiActions: (apiActionsProps: ApiActionsProps) => ApiActions = (\n apiActionsProps: ApiActionsProps\n) => {\n const CommonStores = useSelector((state: any) => state.commonStores.stores);\n const dispatch = useDispatch();\n const session = useSession();\n const { handleGetRequest, handlePostRequest, handleDeleteRequest } =\n useAxios();\n const reloadData = async (params?: any) => {\n if (apiActionsProps?.commonStoreKey) {\n const storeKeys = Object.keys(CommonStores);\n for (const storeKey of storeKeys) {\n if (storeKey === apiActionsProps.commonStoreKey) {\n if (\n (CommonStores[storeKey]?.authority === undefined ||\n CommonStores[storeKey]?.authority === null ||\n session.isUserAuthorized(CommonStores[storeKey]?.authority)) &&\n CommonStores[storeKey]?.url != \"\"\n ) {\n await handleGetRequest({\n endPointURI: CommonStores[storeKey].url,\n showMask: false,\n successCallBkFn: (response: any) => {\n dispatch(setStoreData({ storeKey, data: response.data }));\n apiActionsProps.setData(response.data);\n },\n failureCallBkFn: () => {\n dispatch(setStoreData({ storeKey, data: [] }));\n apiActionsProps.setData([]);\n },\n });\n break;\n }\n }\n }\n } else if (apiActionsProps?.findAll) {\n await handleGetRequest({\n endPointURI: apiActionsProps.findAll,\n showMask: true,\n parameters: params || {},\n successCallBkFn: (response: any) => {\n apiActionsProps.setData(response.data);\n },\n });\n }\n };\n const saveRecord = async (record: any) => {\n let savedRecord = null;\n if (apiActionsProps?.save) {\n await handlePostRequest({\n endPointURI: apiActionsProps.save,\n data: record,\n showMask: true,\n successCallBkFn: (response: any) => {\n savedRecord = response.data;\n },\n });\n }\n return savedRecord;\n };\n const loadRecordById = async (recordId: any) => {\n let record: any = null;\n if (apiActionsProps?.findById) {\n const parameters: any = {};\n const keyParameterName = apiActionsProps?.findByIdParamName || \"id\";\n parameters[keyParameterName] = recordId;\n await handleGetRequest({\n endPointURI: apiActionsProps.findById,\n showMask: true,\n parameters,\n successCallBkFn: (response: any) => {\n record = response.data;\n },\n });\n }\n return record;\n };\n const deleteRecordById = async (recordId: any) => {\n let result = true;\n if (apiActionsProps?.deleteById) {\n const parameters: any = {};\n const keyParameterName = apiActionsProps?.deleteByIdParamName || \"id\";\n parameters[keyParameterName] = recordId;\n await handleDeleteRequest({\n endPointURI: apiActionsProps.deleteById,\n showMask: true,\n parameters,\n successCallBkFn: () => {\n result = true;\n },\n failureCallBkFn: () => {\n result = false;\n },\n });\n }\n return result;\n };\n return { reloadData, loadRecordById, saveRecord, deleteRecordById };\n};\n\nexport default useApiActions;\n","import { TextField, TextFieldProps } from \"@mui/material\";\nimport { useTranslation } from \"react-i18next\";\n\nconst TemplateTextField: React.FC<Omit<TextFieldProps, \"outlined\">> = (\n props\n) => {\n const { t } = useTranslation();\n return (\n <TextField\n {...props}\n slotProps={{ inputLabel: { shrink: true, sx: { fontWeight: \"bold\" } } }}\n label={<>{props?.label ? t(props.label) : \"\"}</>}\n helperText={props?.helperText ? t(props.helperText) : undefined}\n />\n );\n};\n\nexport default TemplateTextField;\n","import * as React from \"react\";\nimport List from \"@mui/material/List\";\nimport Card from \"@mui/material/Card\";\nimport CardHeader from \"@mui/material/CardHeader\";\nimport ListItemText from \"@mui/material/ListItemText\";\nimport ListItemIcon from \"@mui/material/ListItemIcon\";\nimport Checkbox from \"@mui/material/Checkbox\";\nimport Button from \"@mui/material/Button\";\nimport Divider from \"@mui/material/Divider\";\nimport { Box, Grid2, ListItemButton } from \"@mui/material\";\nimport TemplateTextField from \"./DataEntryTemplates/TemplateDataForm/FormFields/TemplateTextField\";\n\nfunction not(a, b) {\n return a.filter((value) => b.indexOf(value) === -1);\n}\n\nfunction intersection(a, b) {\n return a.filter((value) => b.indexOf(value) !== -1);\n}\n\nfunction union(a, b) {\n return [...a, ...not(b, a)];\n}\n\nexport type TransferListProps = {\n valueField: string;\n displayField: string;\n options: Array<any>;\n selectedOptions: Array<any>;\n setSelection: any;\n};\n\nconst TransferList: React.FC<TransferListProps> = ({\n valueField = \"id\",\n displayField = \"name\",\n options = [],\n selectedOptions = [],\n setSelection,\n}) => {\n const [checked, setChecked] = React.useState([]);\n const [left, setLeft] = React.useState<Array<any>>([]);\n const [right, setRight] = React.useState<Array<any>>([]);\n const [leftFilterValue, setLeftFilterValue] = React.useState<string>(\"\");\n const [rightFilterValue, setRightFilterValue] = React.useState<string>(\"\");\n\n const leftChecked = intersection(checked, left);\n const rightChecked = intersection(checked, right);\n\n React.useEffect(() => {\n if (options) {\n setLeft([...options]);\n }\n }, [options]);\n React.useEffect(() => {\n if (selectedOptions) {\n setRight([...selectedOptions]);\n }\n }, [selectedOptions]);\n\n const handleToggle = (value) => () => {\n const currentIndex = checked.indexOf(value);\n const newChecked = [...checked];\n\n if (currentIndex === -1) {\n newChecked.push(value);\n } else {\n newChecked.splice(currentIndex, 1);\n }\n\n setChecked(newChecked);\n };\n\n const numberOfChecked = (items) => intersection(checked, items).length;\n\n const handleToggleAll = (items) => () => {\n if (numberOfChecked(items) === items.length) {\n setChecked(not(checked, items));\n } else {\n setChecked(union(checked, items));\n }\n };\n\n const handleCheckedRight = () => {\n setRight((oldState) => {\n let newState = right.concat(leftChecked);\n setSelection(newState);\n return newState;\n });\n setLeft(not(left, leftChecked));\n setChecked(not(checked, leftChecked));\n };\n\n const handleCheckedLeft = () => {\n setLeft(left.concat(rightChecked));\n setRight((oldState) => {\n let newState = not(right, rightChecked);\n setSelection(newState);\n return newState;\n });\n setChecked(not(checked, rightChecked));\n };\n\n const customList = (\n title: string,\n unfilteredItems: Array<any>,\n side: \"left\" | \"right\"\n ) => {\n const items = unfilteredItems.filter((option: any) => {\n if (option[displayField]) {\n const value: string = option[displayField];\n if (\n side === \"left\" &&\n value\n .toLocaleLowerCase()\n .includes(leftFilterValue.toLocaleLowerCase())\n ) {\n return true;\n } else if (\n side === \"right\" &&\n value\n .toLocaleLowerCase()\n .includes(rightFilterValue.toLocaleLowerCase())\n ) {\n return true;\n }\n }\n return false;\n });\n return (\n <Card sx={{ height: \"100%\" }}>\n <CardHeader\n sx={{ px: 2, py: 1 }}\n avatar={\n <Checkbox\n onClick={handleToggleAll(items)}\n checked={\n numberOfChecked(items) === items.length && items.length !== 0\n }\n indeterminate={\n numberOfChecked(items) !== items.length &&\n numberOfChecked(items) !== 0\n }\n disabled={items.length === 0}\n inputProps={{\n \"aria-label\": \"all items selected\",\n }}\n />\n }\n title={title}\n subheader={`${numberOfChecked(unfilteredItems)} / ${\n unfilteredItems.length\n } Selected`}\n />\n <Box sx={{ width: \"100%\", padding: 1 }}>\n <TemplateTextField\n fullWidth\n label=\"search\"\n value={side === \"left\" ? leftFilterValue : rightFilterValue}\n onChange={(event) => {\n if (side === \"left\") {\n setLeftFilterValue(event.target.value);\n } else {\n setRightFilterValue(event.target.value);\n }\n }}\n />\n </Box>\n <Divider />\n <List\n sx={{\n width: \"100%\",\n height: \"80%\",\n bgcolor: \"secondary\",\n overflow: \"auto\",\n }}\n dense\n component=\"div\"\n role=\"list\"\n >\n {items.map((value) => {\n const labelId = `transfer-list-all-item-${value[valueField]}-label`;\n\n return (\n <ListItemButton\n key={value[valueField]}\n role=\"listitem\"\n onClick={handleToggle(value)}\n sx={{ cursor: \"pointer\" }}\n >\n <ListItemIcon>\n <Checkbox\n checked={checked.indexOf(value) !== -1}\n tabIndex={-1}\n disableRipple\n />\n </ListItemIcon>\n <ListItemText\n id={value[valueField]}\n primary={value[displayField]}\n />\n </ListItemButton>\n );\n })}\n </List>\n </Card>\n );\n };\n return (\n <Grid2\n container\n spacing={2}\n sx={{\n flexGrow: 1,\n overflow: \"auto\",\n margin: 1,\n display: \"flex\",\n width: \"100%\",\n }}\n justifyContent=\"center\"\n alignItems=\"center\"\n >\n <Grid2 sx={{ height: \"100%\", flex: 1 }}>\n {customList(\"Available Items\", left, \"left\")}\n </Grid2>\n <Grid2>\n <Grid2 container direction=\"column\" alignItems=\"center\">\n <Button\n sx={{ my: 0.5 }}\n variant=\"outlined\"\n size=\"small\"\n onClick={handleCheckedRight}\n disabled={leftChecked.length === 0}\n aria-label=\"move selected right\"\n >\n >\n </Button>\n <Button\n sx={{ my: 0.5 }}\n variant=\"outlined\"\n size=\"small\"\n onClick={handleCheckedLeft}\n disabled={rightChecked.length === 0}\n aria-label=\"move selected left\"\n >\n <\n </Button>\n </Grid2>\n </Grid2>\n <Grid2 sx={{ height: \"100%\", flex: 1 }}>\n {customList(\"Currently Selected\", right, \"right\")}\n </Grid2>\n </Grid2>\n );\n};\n\nexport default TransferList;\n","import { Checkbox, FormControlLabel } from \"@mui/material\";\nimport { useTranslation } from \"react-i18next\";\n\ninterface CheckBoxProps {\n value: any;\n disabled?: boolean;\n required?: boolean;\n hidden?: boolean;\n label: string;\n checkedValue?: any;\n unCheckedValue?: any;\n onChangeCallBack: Function;\n sx?: any;\n}\n\nconst CheckBox: React.FC<CheckBoxProps> = (props) => {\n const { t } = useTranslation();\n return (\n <FormControlLabel\n sx={props.sx}\n hidden={props?.hidden || false}\n disabled={props.disabled || false}\n required={props.required || false}\n control={\n <Checkbox\n checked={\n props?.checkedValue == props.value ||\n props.value === \"true\" ||\n props.value == \"1\"\n ? true\n : false\n }\n onChange={(e) => {\n if (\n props.onChangeCallBack !== undefined &&\n props.onChangeCallBack != null\n ) {\n if (e.target.checked) {\n if (\n props.checkedValue !== undefined &&\n props.checkedValue != null\n ) {\n props.onChangeCallBack(props.checkedValue);\n } else {\n props.onChangeCallBack(true);\n }\n } else {\n if (\n props.unCheckedValue !== undefined &&\n props.unCheckedValue != null\n ) {\n props.onChangeCallBack(props.unCheckedValue);\n } else {\n props.onChangeCallBack(false);\n }\n }\n }\n }}\n />\n }\n label={t(props.label)}\n />\n );\n};\n\nexport default CheckBox;\n","import { useSelector } from \"react-redux\";\nimport { Autocomplete, Popper, TextField } from \"@mui/material\";\nimport { useTranslation } from \"react-i18next\";\n\ninterface ComboBoxProps {\n value: any;\n onChangeCallBack: Function;\n label: string;\n disabled?: boolean;\n required?: boolean;\n options: Array<any>;\n errorMessage?: any;\n hidden?: boolean;\n displayField: string;\n valueField: string;\n sx?: any;\n}\n\nconst ComboBox: React.FC<ComboBoxProps> = (props) => {\n const AppLayoutState = useSelector((state: any) => state.AppLayout);\n const { t } = useTranslation();\n const getValue = (v: string) => {\n for (let option of props.options) {\n if (option[props.valueField] == v) {\n return option;\n }\n }\n return null;\n };\n return (\n <Autocomplete\n sx={props.sx}\n value={getValue(props.value)}\n options={props.options}\n disabled={props.disabled}\n hidden={props?.hidden || false}\n onChange={(event, newValue) => {\n if (\n props.onChangeCallBack !== undefined &&\n props.onChangeCallBack != null\n ) {\n if (newValue != null) {\n let v = newValue[props.valueField];\n props.onChangeCallBack(v, newValue);\n } else {\n props.onChangeCallBack(null, null);\n }\n }\n }}\n clearOnBlur\n handleHomeEndKeys\n getOptionLabel={(option) => {\n return option != null ? t(option[props.displayField]) : \"\";\n }}\n renderOption={(props1, option) => {\n return (\n <li {...props1}>\n {option != null ? t(option[props.displayField]) : \"\"}\n </li>\n );\n }}\n slots={{\n popper: (props: any) => (\n <Popper\n {...props}\n style={{ ...props.style, direction: AppLayoutState.appDirection }}\n />\n ),\n }}\n renderInput={(params) => {\n return (\n <TextField\n {...params}\n required={props.required || false}\n variant=\"outlined\"\n slotProps={{\n inputLabel: { shrink: true, sx: { fontWeight: \"bold\" } },\n }}\n label={t(props.label)}\n error={\n props.errorMessage != null && props.errorMessage !== undefined\n ? true\n : false\n }\n helperText={\n props.errorMessage != null && props.errorMessage !== undefined\n ? t(props.errorMessage)\n : \"\"\n }\n />\n );\n }}\n />\n );\n};\n\nexport default ComboBox;\n","export const DATE_FORMAT = \"YYYY-MM-DD\";\nexport const DATE_TIME_FORMAT = \"YYYY-MM-DD HH:mm:ss\";\nexport const LIGHT_THEME_INITIAL_MAIN_COLOR = \"#37505C\";\nexport const LIGHT_THEME_INITIAL_SECANDARY_COLOR = \"#ff6d00\";\nexport const DARK_THEME_INITIAL_MAIN_COLOR = \"#ea690e\";\nexport const DARK_THEME_INITIAL_SECANDARY_COLOR = \"#74776B\";\n","import { DatePicker, LocalizationProvider } from \"@mui/x-date-pickers\";\nimport { AdapterMoment } from \"@mui/x-date-pickers/AdapterMoment\";\nimport moment from \"moment\";\nimport { DATE_FORMAT } from \"../../../../../util/constants\";\nimport { useTranslation } from \"react-i18next\";\nimport TemplateTextField from \"./TemplateTextField\";\n\ninterface DatefieldProps {\n value: string | null;\n label: string;\n disabled?: boolean;\n required?: boolean;\n hidden?: boolean;\n sx?: any;\n format?: string;\n errorMessage?: any;\n onChangeCallBack: Function;\n [x: string | number | symbol]: unknown;\n}\n\nconst Datefield: React.FC<DatefieldProps> = (props) => {\n const { t } = useTranslation();\n if (props?.hidden) {\n return <></>;\n }\n return (\n <LocalizationProvider dateAdapter={AdapterMoment}>\n <DatePicker\n value={\n props.value != null && props.value !== undefined && props.value !== \"\"\n ? moment(props.value, props?.format || DATE_FORMAT)\n : null\n }\n sx={{ ...props.sx, display: props?.hidden ? \"none\" : undefined }}\n label={t(props.label)}\n format={props?.format || DATE_FORMAT}\n disabled={props.disabled}\n onChange={(momentValue) => {\n let v = null;\n if (momentValue != null && momentValue.isValid()) {\n v = momentValue.format(props?.format || DATE_FORMAT);\n }\n if (\n props.onChangeCallBack !== undefined &&\n props.onChangeCallBack != null\n ) {\n props.onChangeCallBack(v);\n }\n }}\n slotProps={{\n textField: {\n InputLabelProps: { shrink: true, sx: { fontWeight: \"bold\" } },\n variant: \"outlined\",\n required: props.required,\n error:\n props.errorMessage !== undefined && props.errorMessage != null,\n helperText:\n props.errorMessage !== undefined && props.errorMessage != null ? (\n <>{t(props.errorMessage)}</>\n ) : (\n <></>\n ),\n },\n }}\n />\n </LocalizationProvider>\n );\n};\n\nexport default Datefield;\n","import { DateTimePicker, LocalizationProvider } from \"@mui/x-date-pickers\";\nimport { AdapterMoment } from \"@mui/x-date-pickers/AdapterMoment\";\nimport moment from \"moment\";\nimport { useTranslation } from \"react-i18next\";\nimport { DATE_TIME_FORMAT } from \"../../../../../util/constants\";\nimport TemplateTextField from \"./TemplateTextField\";\nimport { Hidden, TextField } from \"@mui/material\";\n\ninterface DatetimeFieldProps {\n value: string | null;\n label: string;\n disabled?: boolean;\n required?: boolean;\n hidden?: boolean;\n format?: string;\n sx?: any;\n errorMessage?: any;\n onChangeCallBack: Function;\n [x: string | number | symbol]: unknown;\n}\n\nconst DatetimeField: React.FC<DatetimeFieldProps> = (props) => {\n const { t } = useTranslation();\n if (props?.hidden) {\n return <></>;\n }\n return (\n <LocalizationProvider dateAdapter={AdapterMoment}>\n <DateTimePicker\n value={\n props.value != null && props.value !== undefined && props.value !== \"\"\n ? moment(props.value, props?.format || DATE_TIME_FORMAT)\n : null\n }\n label={t(props.label)}\n sx={{ ...props.sx, display: props?.hidden ? \"none\" : undefined }}\n format={props?.format || DATE_TIME_FORMAT}\n disabled={props.disabled}\n onChange={(momentValue) => {\n let v = null;\n if (momentValue != null && momentValue.isValid()) {\n v = momentValue.format(props?.format || DATE_TIME_FORMAT);\n }\n if (\n props.onChangeCallBack !== undefined &&\n props.onChangeCallBack != null\n ) {\n props.onChangeCallBack(v);\n }\n }}\n slotProps={{\n textField: {\n InputLabelProps: { shrink: true, sx: { fontWeight: \"bold\" } },\n variant: \"outlined\",\n required: props.required,\n error:\n props.errorMessage !== undefined && props.errorMessage != null,\n helperText:\n props.errorMessage !== undefined && props.errorMessage != null ? (\n <>{t(props.errorMessage)}</>\n ) : (\n <></>\n ),\n },\n }}\n />\n </LocalizationProvider>\n );\n};\n\nexport default DatetimeField;\n","import { useEffect, useState } from \"react\";\nimport { useAxios, useSession } from \"../../../../../hooks\";\nimport ComboBox from \"./ComboBox\";\nimport { useSelector } from \"react-redux\";\n\ntype SystemLookupListProps = {\n lookupType: string;\n value: any;\n onChangeCallBack: Function;\n label: string;\n disabled?: boolean;\n required?: boolean;\n hidden?: boolean;\n errorMessage?: any;\n sx?: any;\n};\n\nconst SystemLookupCombobox: React.FC<SystemLookupListProps> = (props) => {\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const session = useSession();\n const [options, setOptions] = useState<Array<any>>([]);\n const { handleGetRequest } = useAxios();\n\n const loadLookupOptions = async () => {\n await handleGetRequest({\n endPointURI: \"api/v1/public/system/lookup\",\n showMask: true,\n parameters: { lookupType: props.lookupType },\n successCallBkFn: (response: any) => {\n setOptions(response.data);\n },\n failureCallBkFn: () => {\n setOptions([]);\n },\n });\n };\n\n useEffect(() => {\n if (props.lookupType) {\n loadLookupOptions();\n }\n }, [props.lookupType, session.UserSession]);\n\n return (\n <ComboBox\n {...props}\n options={options}\n displayField={\n AppLayout.appDirection === \"ltr\" ? \"lookupEnDisplay\" : \"lookupArDisplay\"\n }\n valueField=\"lookupValue\"\n />\n );\n};\n\nexport default SystemLookupCombobox;\n","import moment from \"moment\";\nimport { TemplateGridColDef } from \"../DataEntryTypes\";\nimport Datefield from \"../TemplateDataForm/FormFields/Datefield\";\nimport { DATE_FORMAT, DATE_TIME_FORMAT } from \"../../../../util/constants\";\nimport DatetimeField from \"../TemplateDataForm/FormFields/DatetimeField\";\nimport ComboBox from \"../TemplateDataForm/FormFields/ComboBox\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport CheckBox from \"../TemplateDataForm/FormFields/CheckBox\";\n\nexport const generateDateColumn: any = (colDef: TemplateGridColDef) => {\n const column: TemplateGridColDef = {\n ...colDef,\n type: \"string\",\n renderEditCell: (params: any) => {\n return (\n <Datefield\n sx={{ width: \"100%\" }}\n label=\"\"\n value={params.value}\n onChangeCallBack={(v: any) => {\n params.api.setEditCellValue({\n id: params.id,\n field: params.field,\n value: v,\n });\n }}\n />\n );\n },\n valueParser: (value: any, row: any, column: any) => {\n let v = null;\n if (value !== null) {\n v = moment(value).format(DATE_FORMAT);\n }\n return v;\n },\n valueFormatter: (value: any, row: any, column: any) => {\n return row[column.field];\n },\n };\n return column;\n};\n\nexport const generateDateTimeColumn: any = (colDef: TemplateGridColDef) => {\n const column: TemplateGridColDef = {\n ...colDef,\n type: \"string\",\n renderEditCell: (params: any) => {\n return (\n <DatetimeField\n sx={{ width: \"100%\" }}\n label=\"\"\n value={params.value}\n onChangeCallBack={(v: any) => {\n params.api.setEditCellValue({\n id: params.id,\n field: params.field,\n value: v,\n });\n }}\n />\n );\n },\n valueParser: (value: any, row: any, column: any) => {\n let v = null;\n if (value !== null) {\n v = moment(value).format(DATE_TIME_FORMAT);\n }\n return v;\n },\n valueFormatter: (value: any, row: any, column: any) => {\n return row[column.field];\n },\n };\n return column;\n};\n\ntype ComboBoxColumnProps = TemplateGridColDef & {\n lookupType?: string;\n options: Array<any>;\n displayField: string;\n valueField: string;\n};\nexport const generateComboColumn: (\n props: ComboBoxColumnProps\n) => TemplateGridColDef = (colDef: ComboBoxColumnProps) => {\n const column: TemplateGridColDef = {\n ...colDef,\n type: \"custom\",\n valueGetter: (value) => {\n if (value) {\n return value;\n }\n return value;\n },\n renderCell: (parameters: any) => {\n let record = null;\n try {\n record = parameters.colDef.options.find(\n (item: any) => item[parameters.colDef.valueField] == parameters.value\n );\n } catch (e) {}\n return (\n <div>\n {record != null\n ? record[parameters.colDef.displayField]\n : parameters.value}\n </div>\n );\n },\n\n renderEditCell: (params: any) => {\n return (\n <ComboBox\n {...params}\n sx={{ width: \"100%\" }}\n options={params.colDef.options}\n valueField={params.colDef.valueField}\n displayField={params.colDef.displayField}\n onChangeCallBack={(v: any, selectedRecord: any) => {\n if (v === null) {\n params.api.setEditCellValue({\n id: params.id,\n field: params.field,\n value: null,\n });\n }\n params.api.setEditCellValue({\n id: params.id,\n field: params.field,\n value: v,\n });\n }}\n />\n );\n },\n };\n return column;\n};\n\ntype CheckBoxColumnProps = TemplateGridColDef & {\n checkedValue?: string;\n unCheckedValue?: string;\n};\n\nexport const generateCheckBoxColumn: (\n props: CheckBoxColumnProps\n) => TemplateGridColDef = (colDef: CheckBoxColumnProps) => {\n return {\n ...colDef,\n type: \"custom\",\n valueGetter: (value) => {\n if (value == null || value == undefined) {\n return null;\n } else {\n return value;\n }\n },\n renderCell: (parameters: any) => {\n const value = parameters?.value;\n if (\n value === colDef.checkedValue ||\n value === \"true\" ||\n value === 1 ||\n value === true\n ) {\n return <FontAwesomeIcon icon=\"check\" color=\"green\" />;\n } else {\n return <FontAwesomeIcon icon=\"xmark\" color=\"red\" />;\n }\n },\n renderEditCell: (params: any) => {\n return (\n <CheckBox\n {...params}\n checkedValue={colDef?.checkedValue || true}\n unCheckedValue={colDef?.unCheckedValue || false}\n onChangeCallBack={(v: any) => {\n params.api.setEditCellValue({\n id: params.id,\n field: params.field,\n value: v,\n });\n }}\n />\n );\n },\n };\n};\n","import { GridRowSelectionModel } from \"@mui/x-data-grid-premium\";\nimport {\n FormElementProps,\n RecordFieldProps,\n TemplateGridColDef,\n} from \"./DataEntryTypes\";\nimport {\n generateCheckBoxColumn,\n generateComboColumn,\n generateDateColumn,\n generateDateTimeColumn,\n} from \"./TemplateDataGrid/DataGridColumnsUtil\";\nimport * as z from \"zod\";\nimport { TFunction } from \"i18next\";\n\nexport const getElementFields: (\n element: FormElementProps\n) => Array<RecordFieldProps> = (element: FormElementProps) => {\n const fields: Array<RecordFieldProps> = [];\n if (element.type === \"field\" && element.mode === \"props\" && element?.props) {\n fields.push(element.props);\n } else if (\n element.type === \"group\" &&\n element?.props &&\n element?.props?.elements\n ) {\n for (const childElement of element.props.elements) {\n fields.push(...getElementFields(childElement));\n }\n }\n return fields;\n};\n\nexport const getAllFields: (\n elements: Array<FormElementProps>\n) => Array<RecordFieldProps> = (elements: Array<FormElementProps>) => {\n const fields: Array<RecordFieldProps> = [];\n for (const element of elements) {\n fields.push(...getElementFields(element));\n }\n return fields;\n};\n\nexport const constructGridColumnsFromFields: (\n fields: Array<RecordFieldProps>,\n isDefaultEditable: boolean,\n t: TFunction<\"translation\", undefined>\n) => Array<TemplateGridColDef> = (fields, isDefaultEditable, t) => {\n const columns: Array<TemplateGridColDef> = [];\n\n for (const tableField of fields) {\n if (\n tableField?.fieldType === \"text\" ||\n tableField?.fieldType === \"number\"\n ) {\n const column: TemplateGridColDef = {\n ...tableField?.gridProps?.muiProps,\n editable:\n tableField?.gridProps?.muiProps?.editable != undefined\n ? tableField?.gridProps?.muiProps?.editable\n : isDefaultEditable,\n type: tableField?.fieldType == \"number\" ? \"number\" : \"string\",\n field: tableField?.fieldName,\n headerName: t(tableField?.fieldLabel || tableField?.fieldName),\n headerAlign: \"center\",\n align: \"center\",\n hidden: tableField?.hidden,\n searchable: tableField?.gridProps?.searchable,\n flex: tableField?.gridProps?.muiProps?.flex || 1,\n minWidth: tableField?.gridProps?.muiProps?.width\n ? tableField?.gridProps?.muiProps?.width\n : 200,\n };\n\n columns.push(column);\n } else if (tableField?.fieldType === \"date\") {\n const column: TemplateGridColDef = generateDateColumn({\n ...tableField?.gridProps?.muiProps,\n editable:\n tableField?.gridProps?.muiProps?.editable != undefined\n ? tableField?.gridProps?.muiProps?.editable\n : isDefaultEditable,\n field: tableField?.fieldName,\n headerName: t(tableField?.fieldLabel || tableField?.fieldName),\n headerAlign: \"center\",\n align: \"center\",\n hidden: tableField?.hidden,\n searchable: tableField?.gridProps?.searchable,\n flex: tableField?.gridProps?.muiProps?.flex || 1,\n minWidth: tableField?.gridProps?.muiProps?.width\n ? tableField?.gridProps?.muiProps?.width\n : 200,\n });\n columns.push(column);\n } else if (tableField?.fieldType === \"datetime\") {\n const column: TemplateGridColDef = generateDateTimeColumn({\n ...tableField?.gridProps?.muiProps,\n editable:\n tableField?.gridProps?.muiProps?.editable != undefined\n ? tableField?.gridProps?.muiProps?.editable\n : isDefaultEditable,\n field: tableField?.fieldName,\n headerName: t(tableField?.fieldLabel || tableField?.fieldName),\n headerAlign: \"center\",\n align: \"center\",\n hidden: tableField?.hidden,\n searchable: tableField?.gridProps?.searchable,\n flex: tableField?.gridProps?.muiProps?.flex || 1,\n minWidth: tableField?.gridProps?.muiProps?.width\n ? tableField?.gridProps?.muiProps?.width\n : 200,\n });\n columns.push(column);\n } else if (tableField?.fieldType === \"checkbox\") {\n const column = generateCheckBoxColumn({\n ...tableField?.gridProps?.muiProps,\n editable:\n tableField?.gridProps?.muiProps?.editable != undefined\n ? tableField?.gridProps?.muiProps?.editable\n : isDefaultEditable,\n field: tableField?.fieldName,\n headerName: t(tableField?.fieldLabel || tableField?.fieldName),\n headerAlign: \"center\",\n align: \"center\",\n hidden: tableField?.hidden,\n searchable: tableField?.gridProps?.searchable,\n checkedValue: tableField?.checkedValue,\n unCheckedValue: tableField?.unCheckedValue,\n width: 150,\n });\n columns.push(column);\n } else if (tableField?.fieldType === \"combobox\") {\n const column: TemplateGridColDef = generateComboColumn({\n ...tableField?.gridProps?.muiProps,\n editable:\n tableField?.gridProps?.muiProps?.editable != undefined\n ? tableField?.gridProps?.muiProps?.editable\n : isDefaultEditable,\n field: tableField?.fieldName,\n headerName: t(tableField?.fieldLabel || tableField?.fieldName),\n headerAlign: \"center\",\n align: \"center\",\n hidden: tableField?.hidden,\n searchable: tableField?.gridProps?.searchable,\n valueField: tableField?.optionValueField || \"value\",\n displayField: tableField?.optionDisplayField || \"display\",\n options: tableField?.options || [],\n flex: tableField?.gridProps?.muiProps?.flex || 1,\n minWidth: tableField?.gridProps?.muiProps?.width\n ? tableField?.gridProps?.muiProps?.width\n : 200,\n });\n columns.push(column);\n } else if (tableField?.fieldType === \"lookup\") {\n const column: TemplateGridColDef = generateComboColumn({\n ...tableField?.gridProps?.muiProps,\n editable:\n tableField?.gridProps?.muiProps?.editable != undefined\n ? tableField?.gridProps?.muiProps?.editable\n : isDefaultEditable,\n lookupType: tableField?.lookupType,\n field: tableField?.fieldName,\n headerName: t(tableField?.fieldLabel || tableField?.fieldName),\n headerAlign: \"center\",\n align: \"center\",\n hidden: tableField?.hidden,\n searchable: tableField?.gridProps?.searchable,\n valueField: tableField?.optionValueField || \"value\",\n displayField: tableField?.optionDisplayField || \"display\",\n options: tableField?.options || [],\n flex: tableField?.gridProps?.muiProps?.flex || 1,\n minWidth: tableField?.gridProps?.muiProps?.width\n ? tableField?.gridProps?.muiProps?.width\n : 200,\n });\n columns.push(column);\n } else {\n const column: TemplateGridColDef = {\n field: tableField.fieldName,\n ...tableField?.gridProps?.muiProps,\n };\n columns.push(column);\n }\n }\n return columns;\n};\n\nexport const constructValidationSchema = (fields: Array<RecordFieldProps>) => {\n const validationSchemaObj: any = {};\n for (const field of fields) {\n if (field?.fieldName) {\n const fieldName = field.fieldName;\n if (field.fieldType === \"number\") {\n if (field?.required === true) {\n validationSchemaObj[fieldName] = z.number({\n required_error: \"This field is required\",\n invalid_type_error: \"This field must be a number\",\n });\n } else {\n validationSchemaObj[fieldName] = z.number().optional().nullable();\n }\n } else if (field.fieldType === \"checkbox\") {\n if (field?.required === true) {\n validationSchemaObj[fieldName] = z.boolean({\n required_error: \"This field is required\",\n });\n } else {\n validationSchemaObj[fieldName] = z.boolean().optional().nullable();\n }\n } else if (field.fieldType === \"combobox\") {\n if (field?.comboboxValueDataType) {\n if (field?.comboboxValueDataType === \"number\") {\n if (field?.required === true) {\n validationSchemaObj[fieldName] = z.number({\n required_error: \"This field is required\",\n invalid_type_error: \"This field must be a number\",\n });\n } else {\n validationSchemaObj[fieldName] = z.number().optional().nullable();\n }\n } else if (field?.comboboxValueDataType === \"string\") {\n if (field?.required === true) {\n validationSchemaObj[fieldName] = z\n .string({ message: \"This field is required\" })\n .min(1, \"This field is required\");\n } else {\n validationSchemaObj[fieldName] = z.string().optional().nullable();\n }\n }\n } else {\n if (field?.required === true) {\n validationSchemaObj[fieldName] = z.number({\n required_error: \"This field is required\",\n invalid_type_error: \"This field must be a number\",\n });\n } else {\n validationSchemaObj[fieldName] = z.number().optional().nullable();\n }\n }\n } else {\n if (field?.required === true) {\n validationSchemaObj[fieldName] = z\n .string({ message: \"This field is required\" })\n .min(1, \"This field is required\");\n } else {\n validationSchemaObj[fieldName] = z.string().optional().nullable();\n }\n }\n }\n }\n return validationSchemaObj;\n};\n\nexport type GridSelection = {\n selectedRecords: Array<any>;\n selectedRecordIds: Array<any>;\n};\n\nexport const getGridSelection: (\n rowSelectionModel: GridRowSelectionModel,\n data: Array<any>,\n keyColumnName: string\n) => GridSelection = (\n rowSelectionModel: GridRowSelectionModel,\n data: Array<any>,\n keyColumnName: string\n) => {\n const sRecords = [];\n const sRecordIds = [];\n if (\n rowSelectionModel.type === \"exclude\" &&\n rowSelectionModel.ids.size === 0\n ) {\n for (const record of data) {\n sRecords.push(record);\n sRecordIds.push(record[keyColumnName]);\n }\n } else {\n if (rowSelectionModel?.ids) {\n for (const selectedId of rowSelectionModel.ids) {\n const record = data.find((x) => x[keyColumnName] === selectedId);\n sRecords.push(record);\n sRecordIds.push(selectedId);\n }\n }\n }\n return { selectedRecords: sRecords, selectedRecordIds: sRecordIds };\n};\n","/**\n * WARNING: Don't import this directly. It's imported by the code generated by\n * `@mui/interal-babel-plugin-minify-errors`. Make sure to always use string literals in `Error`\n * constructors to ensure the plugin works as expected. Supported patterns include:\n * throw new Error('My message');\n * throw new Error(`My message: ${foo}`);\n * throw new Error(`My message: ${foo}` + 'another string');\n * ...\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code, ...args) {\n const url = new URL(`https://mui.com/production-error/?code=${code}`);\n args.forEach(arg => url.searchParams.append('args[]', arg));\n return `Minified MUI error #${code}; visit ${url} for the full message.`;\n}","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<<anonymous>>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","/**\n * @license React\n * react-is.production.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\nvar REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_PORTAL_TYPE = Symbol.for(\"react.portal\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\"),\n REACT_STRICT_MODE_TYPE = Symbol.for(\"react.strict_mode\"),\n REACT_PROFILER_TYPE = Symbol.for(\"react.profiler\");\nSymbol.for(\"react.provider\");\nvar REACT_CONSUMER_TYPE = Symbol.for(\"react.consumer\"),\n REACT_CONTEXT_TYPE = Symbol.for(\"react.context\"),\n REACT_FORWARD_REF_TYPE = Symbol.for(\"react.forward_ref\"),\n REACT_SUSPENSE_TYPE = Symbol.for(\"react.suspense\"),\n REACT_SUSPENSE_LIST_TYPE = Symbol.for(\"react.suspense_list\"),\n REACT_MEMO_TYPE = Symbol.for(\"react.memo\"),\n REACT_LAZY_TYPE = Symbol.for(\"react.lazy\"),\n REACT_VIEW_TRANSITION_TYPE = Symbol.for(\"react.view_transition\"),\n REACT_CLIENT_REFERENCE = Symbol.for(\"react.client.reference\");\nfunction typeOf(object) {\n if (\"object\" === typeof object && null !== object) {\n var $$typeof = object.$$typeof;\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n switch (((object = object.type), object)) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n case REACT_VIEW_TRANSITION_TYPE:\n return object;\n default:\n switch (((object = object && object.$$typeof), object)) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n return object;\n case REACT_CONSUMER_TYPE:\n return object;\n default:\n return $$typeof;\n }\n }\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n}\nexports.ContextConsumer = REACT_CONSUMER_TYPE;\nexports.ContextProvider = REACT_CONTEXT_TYPE;\nexports.Element = REACT_ELEMENT_TYPE;\nexports.ForwardRef = REACT_FORWARD_REF_TYPE;\nexports.Fragment = REACT_FRAGMENT_TYPE;\nexports.Lazy = REACT_LAZY_TYPE;\nexports.Memo = REACT_MEMO_TYPE;\nexports.Portal = REACT_PORTAL_TYPE;\nexports.Profiler = REACT_PROFILER_TYPE;\nexports.StrictMode = REACT_STRICT_MODE_TYPE;\nexports.Suspense = REACT_SUSPENSE_TYPE;\nexports.SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nexports.isContextConsumer = function (object) {\n return typeOf(object) === REACT_CONSUMER_TYPE;\n};\nexports.isContextProvider = function (object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n};\nexports.isElement = function (object) {\n return (\n \"object\" === typeof object &&\n null !== object &&\n object.$$typeof === REACT_ELEMENT_TYPE\n );\n};\nexports.isForwardRef = function (object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n};\nexports.isFragment = function (object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n};\nexports.isLazy = function (object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n};\nexports.isMemo = function (object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n};\nexports.isPortal = function (object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n};\nexports.isProfiler = function (object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n};\nexports.isStrictMode = function (object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n};\nexports.isSuspense = function (object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n};\nexports.isSuspenseList = function (object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n};\nexports.isValidElementType = function (type) {\n return \"string\" === typeof type ||\n \"function\" === typeof type ||\n type === REACT_FRAGMENT_TYPE ||\n type === REACT_PROFILER_TYPE ||\n type === REACT_STRICT_MODE_TYPE ||\n type === REACT_SUSPENSE_TYPE ||\n type === REACT_SUSPENSE_LIST_TYPE ||\n (\"object\" === typeof type &&\n null !== type &&\n (type.$$typeof === REACT_LAZY_TYPE ||\n type.$$typeof === REACT_MEMO_TYPE ||\n type.$$typeof === REACT_CONTEXT_TYPE ||\n type.$$typeof === REACT_CONSUMER_TYPE ||\n type.$$typeof === REACT_FORWARD_REF_TYPE ||\n type.$$typeof === REACT_CLIENT_REFERENCE ||\n void 0 !== type.getModuleId))\n ? !0\n : !1;\n};\nexports.typeOf = typeOf;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\n\"production\" !== process.env.NODE_ENV &&\n (function () {\n function typeOf(object) {\n if (\"object\" === typeof object && null !== object) {\n var $$typeof = object.$$typeof;\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n switch (((object = object.type), object)) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n case REACT_VIEW_TRANSITION_TYPE:\n return object;\n default:\n switch (((object = object && object.$$typeof), object)) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n return object;\n case REACT_CONSUMER_TYPE:\n return object;\n default:\n return $$typeof;\n }\n }\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n }\n var REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_PORTAL_TYPE = Symbol.for(\"react.portal\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\"),\n REACT_STRICT_MODE_TYPE = Symbol.for(\"react.strict_mode\"),\n REACT_PROFILER_TYPE = Symbol.for(\"react.profiler\");\n Symbol.for(\"react.provider\");\n var REACT_CONSUMER_TYPE = Symbol.for(\"react.consumer\"),\n REACT_CONTEXT_TYPE = Symbol.for(\"react.context\"),\n REACT_FORWARD_REF_TYPE = Symbol.for(\"react.forward_ref\"),\n REACT_SUSPENSE_TYPE = Symbol.for(\"react.suspense\"),\n REACT_SUSPENSE_LIST_TYPE = Symbol.for(\"react.suspense_list\"),\n REACT_MEMO_TYPE = Symbol.for(\"react.memo\"),\n REACT_LAZY_TYPE = Symbol.for(\"react.lazy\"),\n REACT_VIEW_TRANSITION_TYPE = Symbol.for(\"react.view_transition\"),\n REACT_CLIENT_REFERENCE = Symbol.for(\"react.client.reference\");\n exports.ContextConsumer = REACT_CONSUMER_TYPE;\n exports.ContextProvider = REACT_CONTEXT_TYPE;\n exports.Element = REACT_ELEMENT_TYPE;\n exports.ForwardRef = REACT_FORWARD_REF_TYPE;\n exports.Fragment = REACT_FRAGMENT_TYPE;\n exports.Lazy = REACT_LAZY_TYPE;\n exports.Memo = REACT_MEMO_TYPE;\n exports.Portal = REACT_PORTAL_TYPE;\n exports.Profiler = REACT_PROFILER_TYPE;\n exports.StrictMode = REACT_STRICT_MODE_TYPE;\n exports.Suspense = REACT_SUSPENSE_TYPE;\n exports.SuspenseList = REACT_SUSPENSE_LIST_TYPE;\n exports.isContextConsumer = function (object) {\n return typeOf(object) === REACT_CONSUMER_TYPE;\n };\n exports.isContextProvider = function (object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n };\n exports.isElement = function (object) {\n return (\n \"object\" === typeof object &&\n null !== object &&\n object.$$typeof === REACT_ELEMENT_TYPE\n );\n };\n exports.isForwardRef = function (object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n };\n exports.isFragment = function (object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n };\n exports.isLazy = function (object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n };\n exports.isMemo = function (object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n };\n exports.isPortal = function (object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n };\n exports.isProfiler = function (object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n };\n exports.isStrictMode = function (object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n };\n exports.isSuspense = function (object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n };\n exports.isSuspenseList = function (object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n };\n exports.isValidElementType = function (type) {\n return \"string\" === typeof type ||\n \"function\" === typeof type ||\n type === REACT_FRAGMENT_TYPE ||\n type === REACT_PROFILER_TYPE ||\n type === REACT_STRICT_MODE_TYPE ||\n type === REACT_SUSPENSE_TYPE ||\n type === REACT_SUSPENSE_LIST_TYPE ||\n (\"object\" === typeof type &&\n null !== type &&\n (type.$$typeof === REACT_LAZY_TYPE ||\n type.$$typeof === REACT_MEMO_TYPE ||\n type.$$typeof === REACT_CONTEXT_TYPE ||\n type.$$typeof === REACT_CONSUMER_TYPE ||\n type.$$typeof === REACT_FORWARD_REF_TYPE ||\n type.$$typeof === REACT_CLIENT_REFERENCE ||\n void 0 !== type.getModuleId))\n ? !0\n : !1;\n };\n exports.typeOf = typeOf;\n })();\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import * as React from 'react';\nimport { isValidElementType } from 'react-is';\n\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (/*#__PURE__*/React.isValidElement(source) || isValidElementType(source) || !isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\n\n/**\n * Merge objects deeply.\n * It will shallow copy React elements.\n *\n * If `options.clone` is set to `false` the source object will be merged directly into the target object.\n *\n * @example\n * ```ts\n * deepmerge({ a: { b: 1 }, d: 2 }, { a: { c: 2 }, d: 4 });\n * // => { a: { b: 1, c: 2 }, d: 4 }\n * ````\n *\n * @param target The target object.\n * @param source The source object.\n * @param options The merge options.\n * @param options.clone Set to `false` to merge the source object directly into the target object.\n * @returns The merged object.\n */\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? {\n ...target\n } : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n if (/*#__PURE__*/React.isValidElement(source[key]) || isValidElementType(source[key])) {\n output[key] = source[key];\n } else if (isPlainObject(source[key]) &&\n // Avoid prototype pollution\n Object.prototype.hasOwnProperty.call(target, key) && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return {\n ...acc,\n [obj.key]: obj.val\n };\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5,\n ...other\n } = breakpoints;\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return {\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit,\n ...other\n };\n}","import _formatErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/**\n * For using in `sx` prop to sort the breakpoint from low to high.\n * Note: this function does not work and will not support multiple units.\n * e.g. input: { '@container (min-width:300px)': '1rem', '@container (min-width:40rem)': '2rem' }\n * output: { '@container (min-width:40rem)': '2rem', '@container (min-width:300px)': '1rem' } // since 40 < 300 eventhough 40rem > 300px\n */\nexport function sortContainerQueries(theme, css) {\n if (!theme.containerQueries) {\n return css;\n }\n const sorted = Object.keys(css).filter(key => key.startsWith('@container')).sort((a, b) => {\n const regex = /min-width:\\s*([0-9.]+)/;\n return +(a.match(regex)?.[1] || 0) - +(b.match(regex)?.[1] || 0);\n });\n if (!sorted.length) {\n return css;\n }\n return sorted.reduce((acc, key) => {\n const value = css[key];\n delete acc[key];\n acc[key] = value;\n return acc;\n }, {\n ...css\n });\n}\nexport function isCqShorthand(breakpointKeys, value) {\n return value === '@' || value.startsWith('@') && (breakpointKeys.some(key => value.startsWith(`@${key}`)) || !!value.match(/^@\\d/));\n}\nexport function getContainerQuery(theme, shorthand) {\n const matches = shorthand.match(/^@([^/]+)?\\/?(.+)?$/);\n if (!matches) {\n if (process.env.NODE_ENV !== 'production') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The provided shorthand ${`(${shorthand})`} is invalid. The format should be \\`@<breakpoint | number>\\` or \\`@<breakpoint | number>/<container>\\`.\\n` + 'For example, `@sm` or `@600` or `@40rem/sidebar`.' : _formatErrorMessage(18, `(${shorthand})`));\n }\n return null;\n }\n const [, containerQuery, containerName] = matches;\n const value = Number.isNaN(+containerQuery) ? containerQuery || 0 : +containerQuery;\n return theme.containerQueries(containerName).up(value);\n}\nexport default function cssContainerQueries(themeInput) {\n const toContainerQuery = (mediaQuery, name) => mediaQuery.replace('@media', name ? `@container ${name}` : '@container');\n function attachCq(node, name) {\n node.up = (...args) => toContainerQuery(themeInput.breakpoints.up(...args), name);\n node.down = (...args) => toContainerQuery(themeInput.breakpoints.down(...args), name);\n node.between = (...args) => toContainerQuery(themeInput.breakpoints.between(...args), name);\n node.only = (...args) => toContainerQuery(themeInput.breakpoints.only(...args), name);\n node.not = (...args) => {\n const result = toContainerQuery(themeInput.breakpoints.not(...args), name);\n if (result.includes('not all and')) {\n // `@container` does not work with `not all and`, so need to invert the logic\n return result.replace('not all and ', '').replace('min-width:', 'width<').replace('max-width:', 'width>').replace('and', 'or');\n }\n return result;\n };\n }\n const node = {};\n const containerQueries = name => {\n attachCq(node, name);\n return node;\n };\n attachCq(containerQueries);\n return {\n ...themeInput,\n containerQueries\n };\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from \"../merge/index.js\";\nimport { isCqShorthand, getContainerQuery } from \"../cssContainerQueries/index.js\";\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nconst defaultContainerQueries = {\n containerQueries: containerName => ({\n up: key => {\n let result = typeof key === 'number' ? key : values[key] || key;\n if (typeof result === 'number') {\n result = `${result}px`;\n }\n return containerName ? `@container ${containerName} (min-width:${result})` : `@container (min-width:${result})`;\n }\n })\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n if (isCqShorthand(themeBreakpoints.keys, breakpoint)) {\n const containerKey = getContainerQuery(theme.containerQueries ? theme : defaultContainerQueries, breakpoint);\n if (containerKey) {\n acc[containerKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n }\n }\n // key is breakpoint\n else if (Object.keys(themeBreakpoints.values || values).includes(breakpoint)) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction({\n theme,\n ...props[key]\n });\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? {\n ...styleFunction.propTypes,\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n } : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n const breakpointsInOrder = breakpointsInput.keys?.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import _formatErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? 'MUI: `capitalize(string)` expects a string argument.' : _formatErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from \"../responsivePropType/index.js\";\nimport { handleBreakpoints } from \"../breakpoints/index.js\";\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","import responsivePropType from \"../responsivePropType/index.js\";\nimport { handleBreakpoints } from \"../breakpoints/index.js\";\nimport { getPath } from \"../style/index.js\";\nimport merge from \"../merge/index.js\";\nimport memoize from \"../memoize/index.js\";\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n const themeSpacing = getPath(theme, themeKey, true) ?? defaultValue;\n if (typeof themeSpacing === 'number' || typeof themeSpacing === 'string') {\n return val => {\n if (typeof val === 'string') {\n return val;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof val !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${val}.`);\n }\n }\n if (typeof themeSpacing === 'string') {\n if (themeSpacing.startsWith('var(') && val === 0) {\n return 0;\n }\n if (themeSpacing.startsWith('var(') && val === 1) {\n return themeSpacing;\n }\n return `calc(${val} * ${themeSpacing})`;\n }\n return themeSpacing * val;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return val => {\n if (typeof val === 'string') {\n return val;\n }\n const abs = Math.abs(val);\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n const transformed = themeSpacing[abs];\n if (val >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n if (typeof transformed === 'string' && transformed.startsWith('var(')) {\n return `calc(-1 * ${transformed})`;\n }\n return `-${transformed}`;\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n return transformer(propValue);\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (!keys.includes(prop)) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import merge from \"../merge/index.js\";\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from \"../responsivePropType/index.js\";\nimport style from \"../style/index.js\";\nimport compose from \"../compose/index.js\";\nimport { createUnaryUnit, getValue } from \"../spacing/index.js\";\nimport { handleBreakpoints } from \"../breakpoints/index.js\";\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from \"../style/index.js\";\nimport compose from \"../compose/index.js\";\nimport { createUnaryUnit, getValue } from \"../spacing/index.js\";\nimport { handleBreakpoints } from \"../breakpoints/index.js\";\nimport responsivePropType from \"../responsivePropType/index.js\";\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from \"../style/index.js\";\nimport compose from \"../compose/index.js\";\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from \"../style/index.js\";\nimport compose from \"../compose/index.js\";\nimport { handleBreakpoints, values as breakpointsValues } from \"../breakpoints/index.js\";\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n const breakpoint = props.theme?.breakpoints?.values?.[propValue] || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (props.theme?.breakpoints?.unit !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from \"../spacing/index.js\";\nimport { borderRadius, borderTransform } from \"../borders/index.js\";\nimport { gap, rowGap, columnGap } from \"../cssGrid/index.js\";\nimport { paletteTransform } from \"../palette/index.js\";\nimport { maxWidth, sizingTransform } from \"../sizing/index.js\";\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n font: {\n themeKey: 'font'\n },\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from \"../merge/index.js\";\nimport { getPath, getStyleValue as getValue } from \"../style/index.js\";\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from \"../breakpoints/index.js\";\nimport { sortContainerQueries } from \"../cssContainerQueries/index.js\";\nimport defaultSxConfig from \"./defaultSxConfig.js\";\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n const {\n sx,\n theme = {},\n nested\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = theme.unstable_sxConfig ?? defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme,\n nested: true\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n if (!nested && theme.modularCssLayers) {\n return {\n '@layer sx': sortContainerQueries(theme, removeUnusedBreakpoints(breakpointsKeys, css))\n };\n }\n return sortContainerQueries(theme, removeUnusedBreakpoints(breakpointsKeys, css));\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/customization/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * With the styled function:\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * With the sx prop:\n * ✅ [{ background: '#e5e5e5' }, theme => theme.applyStyles('dark', { background: '#1c1c1c' })]\n * 🚫 { background: '#e5e5e5', ...theme => theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * <Box sx={[\n * { background: '#e5e5e5' },\n * theme => theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars) {\n if (!theme.colorSchemes?.[key] || typeof theme.getColorSchemeSelector !== 'function') {\n return {};\n }\n // If CssVarsProvider is used as a provider, returns '*:where({selector}) &'\n let selector = theme.getColorSchemeSelector(key);\n if (selector === '&') {\n return styles;\n }\n if (selector.includes('data-') || selector.includes('.')) {\n // '*' is required as a workaround for Emotion issue (https://github.com/emotion-js/emotion/issues/2836)\n selector = `*:where(${selector.replace(/\\s*&$/, '')}) &`;\n }\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from \"../createTheme/index.js\";\nimport useThemeWithoutDefault from \"../useThemeWithoutDefault/index.js\";\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from \"../createBreakpoints/createBreakpoints.js\";\nimport cssContainerQueries from \"../cssContainerQueries/index.js\";\nimport shape from \"./shape.js\";\nimport createSpacing from \"./createSpacing.js\";\nimport styleFunctionSx from \"../styleFunctionSx/styleFunctionSx.js\";\nimport defaultSxConfig from \"../styleFunctionSx/defaultSxConfig.js\";\nimport applyStyles from \"./applyStyles.js\";\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {},\n ...other\n } = options;\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: {\n mode: 'light',\n ...paletteInput\n },\n spacing,\n shape: {\n ...shape,\n ...shapeInput\n }\n }, other);\n muiTheme = cssContainerQueries(muiTheme);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = {\n ...defaultSxConfig,\n ...other?.unstable_sxConfig\n };\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","import { createUnarySpacing } from \"../spacing/index.js\";\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8,\n// Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n// Smaller components, such as icons, can align to a 4dp grid.\n// https://m2.material.io/design/layout/understanding-layout.html\ntransform = createUnarySpacing({\n spacing: spacingInput\n})) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import { isPlainObject } from '@mui/utils/deepmerge';\nimport defaultSxConfig from \"./defaultSxConfig.js\";\nconst splitProps = props => {\n const result = {\n systemProps: {},\n otherProps: {}\n };\n const config = props?.theme?.unstable_sxConfig ?? defaultSxConfig;\n Object.keys(props).forEach(prop => {\n if (config[prop]) {\n result.systemProps[prop] = props[prop];\n } else {\n result.otherProps[prop] = props[prop];\n }\n });\n return result;\n};\nexport default function extendSxProp(props) {\n const {\n sx: inSx,\n ...other\n } = props;\n const {\n systemProps,\n otherProps\n } = splitProps(other);\n let finalSx;\n if (Array.isArray(inSx)) {\n finalSx = [systemProps, ...inSx];\n } else if (typeof inSx === 'function') {\n finalSx = (...args) => {\n const result = inSx(...args);\n if (!isPlainObject(result)) {\n return systemProps;\n }\n return {\n ...systemProps,\n ...result\n };\n };\n } else {\n finalSx = {\n ...systemProps,\n ...inSx\n };\n }\n return {\n ...otherProps,\n sx: finalSx\n };\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","function r(e){var t,f,n=\"\";if(\"string\"==typeof e||\"number\"==typeof e)n+=e;else if(\"object\"==typeof e)if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(f=r(e[t]))&&(n&&(n+=\" \"),n+=f)}else for(f in e)e[f]&&(n&&(n+=\" \"),n+=f);return n}export function clsx(){for(var e,t,f=0,n=\"\",o=arguments.length;f<o;f++)(e=arguments[f])&&(t=r(e))&&(n&&(n+=\" \"),n+=t);return n}export default clsx;","import ClassNameGenerator from \"../ClassNameGenerator/index.js\";\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nconst boxClasses = generateUtilityClasses('MuiBox', ['root']);\nexport default boxClasses;","'use client';\n\nimport PropTypes from 'prop-types';\nimport ClassNameGenerator from '@mui/utils/ClassNameGenerator';\nimport createBox from \"../createBox/index.js\";\nimport boxClasses from \"./boxClasses.js\";\nconst Box = createBox({\n defaultClassName: boxClasses.root,\n generateClassName: ClassNameGenerator.generate\n});\nprocess.env.NODE_ENV !== \"production\" ? Box.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * @ignore\n */\n children: PropTypes.node,\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object])\n} : void 0;\nexport default Box;","'use client';\n\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport styled from '@mui/styled-engine';\nimport styleFunctionSx, { extendSxProp } from \"../styleFunctionSx/index.js\";\nimport useTheme from \"../useTheme/index.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createBox(options = {}) {\n const {\n themeId,\n defaultTheme,\n defaultClassName = 'MuiBox-root',\n generateClassName\n } = options;\n const BoxRoot = styled('div', {\n shouldForwardProp: prop => prop !== 'theme' && prop !== 'sx' && prop !== 'as'\n })(styleFunctionSx);\n const Box = /*#__PURE__*/React.forwardRef(function Box(inProps, ref) {\n const theme = useTheme(defaultTheme);\n const {\n className,\n component = 'div',\n ...other\n } = extendSxProp(inProps);\n return /*#__PURE__*/_jsx(BoxRoot, {\n as: component,\n ref: ref,\n className: clsx(className, generateClassName ? generateClassName(defaultClassName) : defaultClassName),\n theme: themeId ? theme[themeId] || theme : theme,\n ...other\n });\n });\n return Box;\n}","/**\n * @mui/styled-engine v7.3.1\n *\n * @license MIT\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use client';\n\n/* eslint-disable no-underscore-dangle */\nimport emStyled from '@emotion/styled';\nimport { serializeStyles as emSerializeStyles } from '@emotion/serialize';\nexport default function styled(tag, options) {\n const stylesFactory = emStyled(tag, options);\n if (process.env.NODE_ENV !== 'production') {\n return (...styles) => {\n const component = typeof tag === 'string' ? `\"${tag}\"` : 'component';\n if (styles.length === 0) {\n console.error([`MUI: Seems like you called \\`styled(${component})()\\` without a \\`style\\` argument.`, 'You must provide a `styles` argument: `styled(\"div\")(styleYouForgotToPass)`.'].join('\\n'));\n } else if (styles.some(style => style === undefined)) {\n console.error(`MUI: the styled(${component})(...args) API requires all its args to be defined.`);\n }\n return stylesFactory(...styles);\n };\n }\n return stylesFactory;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function internal_mutateStyles(tag, processor) {\n // Emotion attaches all the styles as `__emotion_styles`.\n // Ref: https://github.com/emotion-js/emotion/blob/16d971d0da229596d6bcc39d282ba9753c9ee7cf/packages/styled/src/base.js#L186\n if (Array.isArray(tag.__emotion_styles)) {\n tag.__emotion_styles = processor(tag.__emotion_styles);\n }\n}\n\n// Emotion only accepts an array, but we want to avoid allocations\nconst wrapper = [];\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function internal_serializeStyles(styles) {\n wrapper[0] = styles;\n return emSerializeStyles(wrapper);\n}\nexport { ThemeContext, keyframes, css } from '@emotion/react';\nexport { default as StyledEngineProvider } from \"./StyledEngineProvider/index.js\";\nexport { default as GlobalStyles } from \"./GlobalStyles/index.js\";","import generateUtilityClass from \"../generateUtilityClass/index.js\";\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","import { FormElementProps } from \"../components\";\n\nexport function hasDigitsOnly(str: string) {\n return /^\\d+$/.test(str);\n}\n\nexport function isNumber(value: any) {\n return typeof value === \"number\" && !isNaN(value);\n}\n\nexport function isNumeric(value: string) {\n return (\n typeof value === \"string\" && value.trim() !== \"\" && !isNaN(Number(value))\n );\n}\n\nexport function capitalizeFirstLetter(str: string) {\n if (!str) return \"\";\n return str.charAt(0).toUpperCase() + str.slice(1);\n}\n\nexport function isValidEmail(email) {\n const re = /^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$/;\n return re.test(email);\n}\n\nexport function timeAgo(dateInput, appDirection: \"ltr\" | \"rtl\") {\n const date = new Date(dateInput);\n const now = new Date();\n const diffInSeconds = Math.floor((date - now) / 1000); // Note: future is positive\n const absDiff = Math.abs(diffInSeconds);\n\n const locale = appDirection === \"rtl\" ? \"ar\" : \"en\";\n\n const rtf = new Intl.RelativeTimeFormat(locale, { numeric: \"auto\" });\n\n const units = [\n { unit: \"year\", seconds: 31536000 },\n { unit: \"month\", seconds: 2592000 },\n { unit: \"week\", seconds: 604800 },\n { unit: \"day\", seconds: 86400 },\n { unit: \"hour\", seconds: 3600 },\n { unit: \"minute\", seconds: 60 },\n { unit: \"second\", seconds: 1 },\n ];\n\n for (const { unit, seconds } of units) {\n const delta = Math.floor(diffInSeconds / seconds);\n if (Math.abs(delta) > 1) {\n return rtf.format(delta, unit);\n }\n }\n\n return locale === \"ar\" ? \"الآن\" : \"just now\";\n}\n","import { Grid2 } from \"@mui/material\";\nimport TemplateTextField from \"./FormFields/TemplateTextField\";\nimport Datefield from \"./FormFields/Datefield\";\nimport DatetimeField from \"./FormFields/DatetimeField\";\nimport ComboBox from \"./FormFields/ComboBox\";\nimport CheckBox from \"./FormFields/CheckBox\";\nimport { DATE_FORMAT, DATE_TIME_FORMAT } from \"../../../../util/constants\";\nimport { isNumeric } from \"../../../../util/AppUtils\";\nimport { FormElementFieldProps } from \"../DataEntryTypes\";\nimport SystemLookupCombobox from \"./FormFields/SystemLookupCombobox\";\n\nconst FormElementField: React.FC<FormElementFieldProps> = (\n element: FormElementFieldProps\n) => {\n if (element?.fieldInfo) {\n const props = element.fieldInfo;\n const formManager = element?.formManager || null;\n const formActions = element?.formActions || null;\n const formValues = element?.formValues || null;\n const fieldName: any = element?.fieldInfo?.fieldName || null;\n const fieldType = element?.fieldInfo?.fieldType || null;\n if (!(props && formManager && formValues && fieldName && fieldType)) {\n return <></>;\n }\n\n const getFieldLabel = () => {\n if (element?.fieldInfo?.formProps?.fieldLabelFn) {\n return element.fieldInfo.formProps.fieldLabelFn(formValues);\n } else if (element?.fieldInfo?.fieldLabel) {\n return element?.fieldInfo?.fieldLabel;\n }\n };\n return !element.hiddenFields.includes(fieldName) ? (\n <Grid2\n size={\n props?.formProps?.fieldSize || {\n lg: 12,\n md: 12,\n sm: 12,\n }\n }\n sx={{\n padding: 1,\n width: \"100%\",\n }}\n >\n {fieldType === \"text\" || fieldType === \"number\" ? (\n <TemplateTextField\n {...props.muiTextFieldProps}\n fullWidth\n type={fieldType}\n disabled={\n props?.disabled || element.disabledFields.includes(fieldName)\n ? true\n : false\n }\n // hidden={\n // props?.hidden || element.hiddenFields.includes(fieldName)\n // ? true\n // : false\n // }\n label={getFieldLabel()}\n value={formValues[fieldName]}\n onChange={(event) => {\n let newValue = null;\n if (event.target.value != \"\") {\n if (fieldType === \"number\" && isNumeric(event.target.value)) {\n newValue = Number(event.target.value);\n } else {\n newValue = event.target.value;\n }\n }\n formManager.setValue(fieldName, newValue);\n if (element?.formValuesChangeCallBk) {\n element?.formValuesChangeCallBk(\n formValues,\n formActions,\n formManager,\n fieldName,\n newValue\n );\n }\n }}\n sx={{\n \"& .MuiInputBase-root\": {\n height: `${props?.formProps?.fieldHeight}px` || undefined,\n },\n \"& .MuiInputBase-input\": {\n height: \"100% !important\", // forces full height usage\n },\n ...props?.formProps?.style,\n }}\n error={formManager.formState.errors[fieldName] != undefined}\n helperText={formManager?.formState?.errors[\n fieldName\n ]?.message?.toString()}\n />\n ) : props?.fieldType === \"date\" ? (\n <Datefield\n format={props?.dateFormat || DATE_FORMAT}\n sx={props?.formProps?.style || { width: \"100%\" }}\n disabled={\n props?.disabled || element.disabledFields.includes(fieldName)\n ? true\n : false\n }\n // hidden={\n // props?.hidden || element.hiddenFields.includes(fieldName)\n // ? true\n // : false\n // }\n label={getFieldLabel()}\n onChangeCallBack={(v: any) => {\n formManager.setValue(fieldName, v);\n if (element?.formValuesChangeCallBk) {\n element?.formValuesChangeCallBk(\n formValues,\n formActions,\n formManager,\n fieldName,\n v\n );\n }\n }}\n value={formValues[fieldName]}\n error={formManager.formState.errors[fieldName] != undefined}\n errorMessage={formManager?.formState?.errors[\n fieldName\n ]?.message?.toString()}\n />\n ) : props?.fieldType === \"datetime\" ? (\n <DatetimeField\n format={props?.dateFormat || DATE_TIME_FORMAT}\n sx={props?.formProps?.style || { width: \"100%\" }}\n disabled={\n props?.disabled || element.disabledFields.includes(fieldName)\n ? true\n : false\n }\n label={getFieldLabel()}\n onChangeCallBack={(v: any) => {\n formManager.setValue(fieldName, v);\n if (element?.formValuesChangeCallBk) {\n element?.formValuesChangeCallBk(\n formValues,\n formActions,\n formManager,\n fieldName,\n v\n );\n }\n }}\n // hidden={\n // props?.hidden || element.hiddenFields.includes(fieldName)\n // ? true\n // : false\n // }\n value={formValues[fieldName]}\n error={formManager.formState.errors[fieldName] != undefined}\n errorMessage={formManager?.formState?.errors[\n fieldName\n ]?.message?.toString()}\n />\n ) : props?.fieldType === \"checkbox\" ? (\n <CheckBox\n label={getFieldLabel()}\n onChangeCallBack={(v: any) => {\n formManager.setValue(fieldName, v);\n if (element?.formValuesChangeCallBk) {\n element?.formValuesChangeCallBk(\n formValues,\n formActions,\n formManager,\n fieldName,\n v\n );\n }\n }}\n // hidden={\n // props?.hidden || element.hiddenFields.includes(fieldName)\n // ? true\n // : false\n // }\n value={formValues[fieldName]}\n checkedValue={props?.checkedValue || true}\n unCheckedValue={props?.unCheckedValue || false}\n disabled={\n props?.disabled || element.disabledFields.includes(fieldName)\n ? true\n : false\n }\n sx={props?.formProps?.style}\n />\n ) : props?.fieldType === \"combobox\" ? (\n <ComboBox\n sx={props?.formProps?.style || { width: \"100%\" }}\n label={getFieldLabel()}\n disabled={\n props?.disabled || element.disabledFields.includes(fieldName)\n ? true\n : false\n }\n // hidden={\n // props?.hidden || element.hiddenFields.includes(fieldName)\n // ? true\n // : false\n // }\n onChangeCallBack={(v: any, selectedRecord: any) => {\n let newValue = null;\n if (v) {\n newValue = v;\n }\n formManager.setValue(fieldName, newValue);\n if (element?.formValuesChangeCallBk) {\n element?.formValuesChangeCallBk(\n formValues,\n formActions,\n formManager,\n fieldName,\n v,\n selectedRecord\n );\n }\n }}\n options={props?.options || []}\n displayField={props?.optionDisplayField || \"\"}\n valueField={props?.optionValueField || \"\"}\n value={formValues[fieldName]}\n errorMessage={formManager?.formState?.errors[\n fieldName\n ]?.message?.toString()}\n />\n ) : props?.fieldType === \"lookup\" ? (\n <SystemLookupCombobox\n sx={props?.formProps?.style || { width: \"100%\" }}\n label={getFieldLabel()}\n disabled={\n props?.disabled || element.disabledFields.includes(fieldName)\n ? true\n : false\n }\n // hidden={\n // props?.hidden || element.hiddenFields.includes(fieldName)\n // ? true\n // : false\n // }\n onChangeCallBack={(v: any, selectedRecord: any) => {\n let newValue = null;\n if (v) {\n newValue = v;\n }\n formManager.setValue(fieldName, newValue);\n if (element?.formValuesChangeCallBk) {\n element?.formValuesChangeCallBk(\n formValues,\n formActions,\n formManager,\n fieldName,\n v,\n selectedRecord\n );\n }\n }}\n lookupType={props.lookupType}\n value={formValues[fieldName]}\n errorMessage={formManager?.formState?.errors[\n fieldName\n ]?.message?.toString()}\n />\n ) : null}\n </Grid2>\n ) : (\n <></>\n );\n } else {\n return <></>;\n }\n};\n\nexport default FormElementField;\n","import { Button } from \"@mui/material\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { RecordAction } from \"../DataEntryTypes\";\nimport useSession from \"../../../../hooks/UseSession\";\nimport { useConfirmationWindow } from \"../../../../hooks/UseConfirmationWindow\";\n\nconst FormAction: React.FC<RecordAction> = (action: RecordAction) => {\n const session = useSession();\n const { ConfirmationWindow, setOpen: setConfirmationWindowState } =\n useConfirmationWindow({\n body: action?.confirmationMessage || \"\",\n title: \"Confirmation\",\n onConfirmationCallBk: () => {\n action?.actionFn(action?.record);\n },\n });\n if (\n action?.authority === undefined ||\n action?.authority === null ||\n session.isUserAuthorized(action.authority)\n ) {\n return (\n <>\n <ConfirmationWindow />\n <Button\n variant={action?.formActionProps?.actionButtonVariant}\n color={action?.formActionProps?.actionButtonColor}\n onClick={() => {\n if (action?.actionFn) {\n if (action?.preActionValidation) {\n if (!action.preActionValidation(action.record)) {\n return;\n }\n }\n if (action?.isConfirmationRequired === true) {\n setConfirmationWindowState(true);\n } else {\n action?.actionFn(action.record);\n }\n }\n }}\n >\n {action?.icon ? (\n <FontAwesomeIcon\n icon={action.icon}\n style={{ marginRight: 5, marginLeft: 5 }}\n />\n ) : (\n <></>\n )}\n <div>{action?.label}</div>\n </Button>\n </>\n );\n } else {\n return <></>;\n }\n};\n\nexport default FormAction;\n","import { Grid2 } from \"@mui/material\";\nimport FormElementField from \"./FormElementField\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport FormAction from \"./FormAction\";\nimport {\n FormElementGroupProps,\n FormElementProps,\n RecordAction,\n} from \"../DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\n\nconst FormElementGroup: React.FC<FormElementGroupProps> = (\n props: FormElementGroupProps\n) => {\n const { t } = useTranslation();\n return (\n <>\n <Grid2 container sx={props?.style} alignItems=\"flex-start\">\n {props?.label ? (\n <Grid2\n size={12}\n sx={{\n padding: 1,\n fontWeight: \"bold\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n }}\n >\n {props?.icon ? (\n <>\n <FontAwesomeIcon\n icon={props.icon}\n style={{ marginRight: 5, marginLeft: 5 }}\n />\n <div>{t(props.label)}</div>\n </>\n ) : (\n <>{t(props.label)}</>\n )}\n </Grid2>\n ) : (\n <></>\n )}\n {props?.elements\n ? props.elements.map((element: FormElementProps) => {\n if (element.type === \"group\") {\n return (\n <FormElementGroup\n {...element.props}\n formManager={props.formManager}\n formValues={props.formValues}\n formActions={props.formActions}\n hiddenFields={props.hiddenFields}\n disabledFields={props.disabledFields}\n />\n );\n } else if (element.type === \"field\" && element.mode === \"props\") {\n return (\n <FormElementField\n fieldInfo={element.props}\n formManager={props.formManager}\n formValues={props.formValues}\n formActions={props.formActions}\n hiddenFields={props.hiddenFields}\n disabledFields={props.disabledFields}\n />\n );\n } else if (element.type === \"field\" && element.mode === \"node\") {\n return (\n <Grid2\n size={\n element?.props?.formProps?.fieldSize || {\n lg: 3,\n md: 6,\n sm: 12,\n }\n }\n sx={{ padding: 1, width: \"100%\" }}\n >\n <element.node\n formManager={props.formManager}\n formValues={props.formValues}\n formActions={props.formActions}\n />\n </Grid2>\n );\n }\n })\n : null}\n\n {props?.actions ? (\n <Grid2 size={{ sm: 12 }} sx={{ padding: 1 }}>\n {props.actions.map((action: RecordAction) => {\n return <FormAction {...action} record={props.formValues} />;\n })}\n </Grid2>\n ) : (\n <></>\n )}\n </Grid2>\n </>\n );\n};\n\nexport default FormElementGroup;\n","import { useEffect, useState } from \"react\";\nimport { useSelector } from \"react-redux\";\nimport { Avatar, SxProps } from \"@mui/material\";\n\ntype AttachmentImageViewerProps = {\n attachmentId?: number;\n attachmentCode?: string;\n refKey?: string;\n category?: string;\n showAsAvatar?: boolean;\n onErrorImage?: string;\n style?: SxProps;\n};\n\nconst AttachmentImageViewer: React.FC<AttachmentImageViewerProps> = (props) => {\n const apiBaseUrl = useSelector(\n (state: any) => state.AppInfo.value.apiBaseUrl\n );\n const [imgSrc, setImgSrc] = useState(null);\n const handleImageSrc = () => {\n let imagePath = apiBaseUrl + \"/api/v1/attachment/\";\n if (props?.attachmentId) {\n imagePath += \"download?attachmentId=\" + props.attachmentId;\n } else {\n imagePath += `downloadImage?attachmentCode=${props.attachmentCode}&refKey=${props.refKey}`;\n if (props?.category) {\n imagePath += `&category=${props.category}`;\n }\n }\n setImgSrc(imagePath);\n };\n useEffect(() => {\n handleImageSrc();\n }, [props]);\n {\n /* </Avatar>\n src={imgSrc}\n loading={}\n sx={props.style}\n onError={() => {\n if (props?.onErrorImage) {\n setImgSrc(props.onErrorImage);\n } else {\n setImgSrc(\"/no_image.png\");\n }\n }}\n /> */\n }\n return props?.showAsAvatar ? (\n <Avatar\n sx={props.style}\n onError={() => {\n if (props?.onErrorImage) {\n setImgSrc(props.onErrorImage);\n } else {\n setImgSrc(\"/no_image.png\");\n }\n }}\n src={imgSrc}\n />\n ) : (\n <img\n src={imgSrc}\n loading=\"lazy\"\n alt=\"image\"\n onError={() => {\n if (props?.onErrorImage) {\n setImgSrc(props.onErrorImage);\n } else {\n setImgSrc(\"/no_image.png\");\n }\n }}\n style={{\n width: \"100%\",\n height: \"100%\",\n objectFit: \"cover\",\n display: \"block\",\n }}\n />\n );\n};\n\nexport default AttachmentImageViewer;\n","import Card from \"@mui/material/Card\";\nimport CardActions from \"@mui/material/CardActions\";\nimport CardContent from \"@mui/material/CardContent\";\nimport CardMedia from \"@mui/material/CardMedia\";\nimport Button from \"@mui/material/Button\";\nimport Typography from \"@mui/material/Typography\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { IconButton, Tooltip } from \"@mui/material\";\nimport { useAxios, useConfirmationWindow, useSession } from \"../../../hooks\";\nimport AttachmentImageViewer from \"./AttachmentImageViewer\";\n\nexport type attachment = {\n attachmentCode: string;\n setAttachmentConfig: (props: any) => void;\n id: number;\n attachmentConfigId: number;\n attachmentSize: number;\n category: string;\n docType: string;\n fileName: string;\n refKey: string;\n allowDelete?: boolean;\n downloadAuthorityKey?: string;\n remark: string;\n};\n\nconst AttachmentCard: React.FC<attachment> = (props) => {\n const { handleGetRequest, handleDeleteRequest } = useAxios();\n const { isUserAuthorized } = useSession();\n let allowDownload = true;\n if (props?.downloadAuthorityKey) {\n allowDownload = isUserAuthorized(props.downloadAuthorityKey);\n }\n const handleDelete = async () => {\n await handleDeleteRequest({\n endPointURI: \"api/v1/attachment/archive\",\n parameters: {\n attachmentCode: props.attachmentCode,\n refKey: props.refKey,\n attachmentId: props.id,\n },\n successCallBkFn: (response) => {\n props.setAttachmentConfig(response.data);\n },\n showMask: true,\n });\n };\n const { ConfirmationWindow, setOpen } = useConfirmationWindow({\n title: \"Confirmation\",\n body: \"Are you sure you want to delete this attachment?\",\n onConfirmationCallBk: () => {\n handleDelete();\n },\n });\n\n const handleDownload = async () => {\n await handleGetRequest({\n endPointURI: \"api/v1/attachment/download\",\n parameters: {\n attachmentId: props.id,\n },\n showMask: true,\n responseType: \"blob\",\n successCallBkFn: (response) => {\n const url = window.URL.createObjectURL(new Blob([response.data]));\n const link = document.createElement(\"a\");\n link.href = url;\n link.setAttribute(\"download\", props.fileName);\n document.body.appendChild(link);\n link.click();\n link.remove();\n },\n });\n };\n\n return (\n <>\n <ConfirmationWindow />\n <Card sx={{ width: 300, border: \"0.5px solid gray\" }}>\n <CardMedia\n sx={{\n height: 140,\n width: 300,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n {props?.docType.toLocaleLowerCase().includes(\"image\") ? (\n <AttachmentImageViewer attachmentId={props.id} />\n ) : (\n <FontAwesomeIcon icon=\"file\" size=\"3x\" />\n )}\n </CardMedia>\n <CardContent>\n <Typography gutterBottom variant=\"h6\" component=\"div\">\n {props.fileName}\n </Typography>\n <Typography variant=\"body2\" sx={{ color: \"text.secondary\" }}>\n {`File Size: ${props?.attachmentSize || \"unknown\"} kb`}\n </Typography>\n <Typography variant=\"body2\" sx={{ color: \"text.secondary\" }}>\n {`File Type: ${props?.category || \"NA\"}`}\n </Typography>\n <Typography variant=\"body2\" sx={{ color: \"text.secondary\" }}>\n {props.remark}\n </Typography>\n </CardContent>\n <CardActions>\n {props?.allowDelete ? (\n <IconButton\n size=\"small\"\n onClick={() => {\n setOpen(true);\n }}\n >\n <Tooltip title=\"Delete Attachment\">\n <FontAwesomeIcon icon=\"trash\" />\n </Tooltip>\n </IconButton>\n ) : (\n <></>\n )}\n\n <div style={{ flex: 1 }}></div>\n {allowDownload ? (\n <IconButton size=\"small\" onClick={handleDownload}>\n <Tooltip title=\"Download Attachment\">\n <FontAwesomeIcon icon=\"download\" />\n </Tooltip>\n </IconButton>\n ) : (\n <></>\n )}\n </CardActions>\n </Card>\n </>\n );\n};\n\nexport default AttachmentCard;\n","import { useEffect, useState } from \"react\";\nimport { useAxios, useSession } from \"../../../hooks\";\nimport { toast } from \"react-toastify\";\nimport { Box, Button, Grid2, Paper } from \"@mui/material\";\nimport ComboBox from \"../DataEntryTemplates/TemplateDataForm/FormFields/ComboBox\";\nimport TemplateTextField from \"../DataEntryTemplates/TemplateDataForm/FormFields/TemplateTextField\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport AttachmentCard from \"./AttachmentCard\";\n\nexport type AttachmentPanelProps = {\n attachmentCode: string;\n enableAttachment?: boolean;\n refKey: string;\n};\n\ntype AttachmentConfig = {\n id: number;\n attachmentCode: string;\n uploadDirectory: string;\n storageType: \"FILE_SYSTEM\" | \"SFTP\";\n maxAllowedNumberOfFiles: number;\n isCategoryRequired?: boolean;\n attachmentCategories?: string;\n uploadAuthorityKey?: string;\n downloadAuthorityKey?: string;\n allowedFileTypes?: string;\n refKeyAttachments?: Array<any>;\n};\n\nconst AttachmentPanel: React.FC<AttachmentPanelProps> = (props) => {\n const { handleUploadRequest, handleGetRequest } = useAxios();\n const [files, setFiles] = useState<FileList | null>(null);\n const [attachmentCategories, setAttachmentCategories] = useState<\n Array<string>\n >([]);\n const [remark, setRemark] = useState(null);\n const [selectedCategory, setSelectedCategory] = useState(null);\n const [allowedTypes, setAllowedTypes] = useState<Array<string>>([]);\n const [attachmentConfig, setAttachmentConfig] =\n useState<AttachmentConfig>(null);\n\n const loadAttachmentConfig = async () => {\n await handleGetRequest({\n endPointURI: \"api/v1/attachment/info\",\n showMask: true,\n parameters: {\n attachmentCode: props.attachmentCode,\n refKey: props.refKey,\n },\n successCallBkFn: (response: any) => {\n setAttachmentConfig(response.data);\n },\n });\n };\n\n const handleChange = (e: React.ChangeEvent<HTMLInputElement>) => {\n if (e.target.files) {\n for (const file of e.target.files) {\n const fileExt = getFileExtension(file.name);\n if (allowedTypes.length > 0 && !allowedTypes.includes(fileExt)) {\n toast.error(fileExt + \" is not allowed\");\n return;\n }\n }\n }\n setFiles(e.target.files);\n };\n const { isUserAuthorized } = useSession();\n\n const handleUpload = async () => {\n let existingAttachments = attachmentConfig?.refKeyAttachments.length || 0;\n if (\n attachmentConfig?.maxAllowedNumberOfFiles &&\n files.length + existingAttachments >\n attachmentConfig.maxAllowedNumberOfFiles\n ) {\n toast.error(\n \"Maximum number of attachments is \" +\n attachmentConfig.maxAllowedNumberOfFiles\n );\n return;\n }\n if (\n attachmentConfig?.isCategoryRequired === true &&\n attachmentCategories.length > 0 &&\n (selectedCategory == null ||\n selectedCategory === undefined ||\n selectedCategory === \"\")\n ) {\n toast.error(\"You must selected document type to process your request\");\n return;\n }\n if (!files) {\n toast.error(\"You must add files to upload\");\n return;\n }\n debugger;\n for (const file of files) {\n if (file.type.startsWith(\"image/\")) {\n const MAX_SIZE_KB = 600;\n const maxSizeBytes = MAX_SIZE_KB * 1024;\n if (file.size > maxSizeBytes) {\n toast.error(\n `File ${file.name} is too large. Max allowed is ${MAX_SIZE_KB}KB.`\n );\n return;\n }\n }\n }\n\n await handleUploadRequest({\n endPointURI: \"api/v1/attachment/upload\",\n showMask: true,\n loadingMessage: \"Uploading files ... please wait\",\n parameters: {\n refKey: props.refKey,\n attachmentCode: props.attachmentCode,\n remark,\n category: selectedCategory,\n },\n files,\n successCallBkFn: (response) => {\n setAttachmentConfig(response.data);\n setFiles(null);\n setSelectedCategory(null);\n setRemark(null);\n toast.success(\"Your request has been process successfully\");\n },\n });\n };\n const getFileExtension = (name: string) => {\n return name.split(\".\").pop()?.toLowerCase() || \"\";\n };\n\n useEffect(() => {\n loadAttachmentConfig();\n }, [props.refKey, props.attachmentCode]);\n\n useEffect(() => {\n if (attachmentConfig?.allowedFileTypes) {\n setAllowedTypes(attachmentConfig.allowedFileTypes.split(\",\"));\n } else {\n setAllowedTypes([]);\n }\n if (attachmentConfig?.attachmentCategories) {\n const cats = [];\n for (const category of attachmentConfig.attachmentCategories.split(\",\")) {\n cats.push({ value: category });\n }\n setAttachmentCategories(cats);\n } else {\n setAttachmentCategories([]);\n }\n }, [attachmentConfig]);\n let showAttachments = true;\n if (\n attachmentConfig?.downloadAuthorityKey &&\n !isUserAuthorized(attachmentConfig?.downloadAuthorityKey)\n ) {\n showAttachments = false;\n }\n let allowUpload = true;\n if (props?.enableAttachment === false) {\n allowUpload = false;\n }\n if (\n attachmentConfig?.uploadAuthorityKey &&\n !isUserAuthorized(attachmentConfig.uploadAuthorityKey)\n ) {\n allowUpload = false;\n }\n\n return (\n <Paper\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n width: \"100%\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n overflow: \"hidden\",\n flexGrow: 1,\n }}\n >\n {allowUpload ? (\n <>\n {attachmentConfig?.maxAllowedNumberOfFiles === undefined ||\n attachmentConfig?.maxAllowedNumberOfFiles === null ||\n attachmentConfig?.maxAllowedNumberOfFiles >\n attachmentConfig.refKeyAttachments.length ? (\n <>\n <h3>\n <FontAwesomeIcon\n icon=\"paperclip\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n Attachment Uploader\n </h3>\n <input\n type=\"file\"\n style={{ margin: 20 }}\n accept={attachmentConfig?.allowedFileTypes}\n multiple\n onChange={handleChange}\n />\n {attachmentCategories.length > 0 ? (\n <ComboBox\n label=\"Attachment Type\"\n sx={{ width: 300, m: 1 }}\n options={attachmentCategories}\n displayField=\"value\"\n valueField=\"value\"\n value={selectedCategory}\n onChangeCallBack={(v) => {\n setSelectedCategory(v);\n }}\n />\n ) : (\n <></>\n )}\n\n <TemplateTextField\n label=\"Remark\"\n value={remark}\n onChange={(event) => setRemark(event.target.value)}\n multiline={true}\n sx={{ width: 300, m: 1 }}\n rows={3}\n />\n <Button sx={{ m: 1 }} variant=\"contained\" onClick={handleUpload}>\n Upload\n </Button>\n </>\n ) : (\n <></>\n )}\n </>\n ) : (\n <></>\n )}\n\n {showAttachments && attachmentConfig?.refKeyAttachments?.length > 0 ? (\n <>\n <h3>\n <FontAwesomeIcon\n style={{ marginRight: 10, marginLeft: 10 }}\n icon=\"paperclip\"\n />\n Attachments\n </h3>\n <Grid2\n container\n spacing={2}\n sx={{ overflow: \"auto\", padding: 1, justifyContent: \"center\" }}\n >\n {attachmentConfig?.refKeyAttachments.map((refKeyAttachment) => {\n return (\n <Grid2\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <AttachmentCard\n {...refKeyAttachment}\n attachmentCode={props.attachmentCode}\n setAttachmentConfig={setAttachmentConfig}\n downloadAuthorityKey={attachmentConfig.downloadAuthorityKey}\n allowDelete={allowUpload}\n />\n </Grid2>\n );\n })}\n </Grid2>\n </>\n ) : (\n <></>\n )}\n </Paper>\n );\n};\n\nexport default AttachmentPanel;\n","import Typography from \"@mui/material/Typography\";\nimport { workflowDocumentActionHistory } from \"./WorkflowDocumentPanel\";\nimport { useSelector } from \"react-redux\";\nimport { Avatar, Box, Divider, Paper, Stack } from \"@mui/material\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { useTranslation } from \"react-i18next\";\nimport AttachmentImageViewer from \"../attachment/AttachmentImageViewer\";\n\ntype WorkflowDocumentTimeLineProp = {\n actionHistory: Array<workflowDocumentActionHistory>;\n};\n\nconst WorkflowDocumentTimeLine: React.FC<WorkflowDocumentTimeLineProp> = (\n props\n) => {\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const { t } = useTranslation();\n return (\n <Paper\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n flexGrow: 1,\n padding: 1,\n margin: 1,\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <Box\n sx={{\n width: \"100%\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontSize: 18,\n fontWeight: \"bold\",\n }}\n >\n <FontAwesomeIcon\n icon=\"history\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n {t(\"WF_ACTION_HISTORY_LABEL\")}\n </Box>\n <Box\n sx={{\n flexGrow: 1,\n width: \"100%\",\n display: \"flex\",\n flexDirection: \"column\",\n overflowY: \"auto\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n }}\n >\n {props.actionHistory.map((actionHistoryRecord, index) => {\n return (\n <>\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n width: \"100%\",\n marginBottom: 2,\n }}\n >\n <Box\n sx={{\n display: \"flex\",\n flex: 1,\n flexDirection: \"column\",\n alignItems: \"flex-end\",\n justifyContent: \"center\",\n }}\n >\n <Box sx={{ marginBottom: 0.2 }}>\n {actionHistoryRecord.actionTime}\n </Box>\n <Typography>\n via {actionHistoryRecord.actionMethod}\n </Typography>\n </Box>\n <Box\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"center\",\n position: \"relative\",\n marginRight: 2,\n marginLeft: 2,\n }}\n >\n <AttachmentImageViewer\n showAsAvatar={true}\n attachmentCode=\"EMPLOYEE_PHOTOS\"\n refKey={actionHistoryRecord?.personId + \"\" || \"0\"}\n style={{ m: 1, width: 70, height: 70 }}\n />\n {index !== props.actionHistory.length - 1 ? (\n <Box sx={{ marginTop: 11, position: \"absolute\" }}>|</Box>\n ) : (\n <></>\n )}\n </Box>\n <Box\n sx={{\n display: \"flex\",\n flex: 1,\n flexDirection: \"column\",\n alignItems: \"flex-start\",\n justifyContent: \"center\",\n }}\n >\n <Box sx={{ width: \"100%\" }}>\n {AppLayout.appDirection === \"ltr\"\n ? `${actionHistoryRecord?.documentActionEnName}`\n : `${actionHistoryRecord?.documentActionArName}`}\n {actionHistoryRecord?.actionComment\n ? \" - \" + actionHistoryRecord.actionComment\n : \"\"}\n </Box>\n <Box sx={{ width: \"100%\" }}>\n {AppLayout.appDirection === \"ltr\"\n ? `${actionHistoryRecord?.employeeEnName}`\n : `${actionHistoryRecord?.employeeArName}`}\n </Box>\n </Box>\n </Box>\n </>\n );\n })}\n </Box>\n </Paper>\n );\n};\n\nexport default WorkflowDocumentTimeLine;\n","import { Button } from \"@mui/material\";\nimport { RecordAction } from \"../DataEntryTypes\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { toast } from \"react-toastify\";\nimport { useTranslation } from \"react-i18next\";\nimport useSession from \"../../../../hooks/UseSession\";\nimport { useConfirmationWindow } from \"../../../../hooks/UseConfirmationWindow\";\n\nconst TemplateGridMultiRecordAction: React.FC<RecordAction> = (\n rowAction: RecordAction\n) => {\n const { t } = useTranslation();\n const session = useSession();\n const { ConfirmationWindow, setOpen } = useConfirmationWindow({\n body: t(rowAction?.confirmationMessage || \"ACTION_CONFIRMATION\"),\n title: t(\"CONFIRMATION\"),\n onConfirmationCallBk: async () => {\n await rowAction?.actionFn(\n rowAction.recordsToProcessActionOn,\n rowAction.recordIdsToProcessActionOn\n );\n if (rowAction?.reloadData) {\n rowAction.reloadData();\n }\n },\n });\n let isActionAllowed = true;\n if (rowAction.authority) {\n isActionAllowed = session.isUserAuthorized(rowAction.authority);\n }\n\n if (isActionAllowed) {\n return (\n <>\n <ConfirmationWindow />\n <Button\n onClick={async () => {\n if (\n rowAction?.recordsToProcessActionOn &&\n rowAction?.recordsToProcessActionOn.length > 0\n ) {\n if (rowAction?.preActionValidation) {\n for (const record of rowAction.recordsToProcessActionOn) {\n if (!rowAction.preActionValidation(record)) {\n return;\n }\n }\n }\n if (rowAction?.isConfirmationRequired === true) {\n setOpen(true);\n } else {\n await rowAction.actionFn(\n rowAction.recordsToProcessActionOn,\n rowAction.recordIdsToProcessActionOn\n );\n if (rowAction?.reloadData) {\n rowAction.reloadData();\n }\n }\n } else {\n toast.error(t(\"AT_LEAST_ONE_RECORD_SELECTED_MESSAGE\"));\n }\n }}\n variant={\n rowAction?.label\n ? \"outlined\"\n : rowAction?.formActionProps?.actionButtonVariant\n ? rowAction.formActionProps.actionButtonVariant\n : \"text\"\n }\n size=\"small\"\n color={rowAction?.formActionProps?.actionButtonColor || \"primary\"}\n >\n {rowAction?.icon ? (\n <FontAwesomeIcon\n style={{ marginRight: 5, marginLeft: 5 }}\n icon={rowAction.icon}\n />\n ) : (\n <></>\n )}\n {rowAction?.label ? t(rowAction.label) : <></>}\n </Button>\n </>\n );\n }\n};\n\nexport default TemplateGridMultiRecordAction;\n","import {\n Badge,\n Box,\n Button,\n Divider,\n IconButton,\n InputAdornment,\n MenuItem,\n styled,\n TextField,\n Tooltip,\n} from \"@mui/material\";\nimport {\n Toolbar,\n ToolbarButton,\n ColumnsPanelTrigger,\n FilterPanelTrigger,\n QuickFilter,\n QuickFilterControl,\n QuickFilterClear,\n QuickFilterTrigger,\n GridViewColumnIcon,\n GridFilterListIcon,\n ExportExcel,\n} from \"@mui/x-data-grid-premium\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport TemplateGridMultiRecordAction from \"./TemplateGridMultiRecordAction\";\nimport { getGridSelection } from \"../DataEntryUtil\";\nimport { useTranslation } from \"react-i18next\";\nimport { TemplateGridTopBarProps } from \"../DataEntryTypes\";\nimport useSession from \"../../../../hooks/UseSession\";\n\ntype OwnerState = {\n expanded: boolean;\n};\n\nconst StyledQuickFilter = styled(QuickFilter)({\n display: \"grid\",\n alignItems: \"center\",\n});\n\nconst StyledToolbarButton = styled(ToolbarButton)<{ ownerState: OwnerState }>(\n ({ theme, ownerState }) => ({\n gridArea: \"1 / 1\",\n width: \"min-content\",\n height: \"min-content\",\n zIndex: 1,\n opacity: ownerState.expanded ? 0 : 1,\n pointerEvents: ownerState.expanded ? \"none\" : \"auto\",\n transition: theme.transitions.create([\"opacity\"]),\n })\n);\n\nconst StyledTextField = styled(TextField)<{\n ownerState: OwnerState;\n}>(({ theme, ownerState }) => ({\n gridArea: \"1 / 1\",\n overflowX: \"clip\",\n width: ownerState.expanded ? 260 : \"var(--trigger-width)\",\n opacity: ownerState.expanded ? 1 : 0,\n transition: theme.transitions.create([\"width\", \"opacity\"]),\n}));\n\nconst TemplateGridTopBar: React.FC<TemplateGridTopBarProps> = (\n props: TemplateGridTopBarProps\n) => {\n const { t } = useTranslation();\n const session = useSession();\n const isCreationAuthorized = props?.templateProps?.editAction?.authority\n ? session.isUserAuthorized(props.templateProps.editAction.authority)\n : true;\n const isCreationEnabled = props?.templateProps?.disableDefaultAction || true;\n const gridSelection = getGridSelection(\n props?.templateProps?.rowSelectionModel || {\n ids: new Set(),\n type: \"include\",\n },\n props?.templateProps?.data || [],\n props?.templateProps?.keyColumnName || \"id\"\n );\n return (\n <Toolbar>\n {isCreationEnabled &&\n isCreationAuthorized &&\n props?.templateProps?.editMode?.editMode != \"none\" ? (\n <Button onClick={props?.handleCreateNewRecord}>\n <FontAwesomeIcon\n icon=\"add\"\n style={{ marginRight: 5, marginLeft: 5 }}\n />\n {t(\"ADD_BTN_LABEL\")}\n </Button>\n ) : (\n <></>\n )}\n {props?.templateProps?.rowActions ? (\n props.templateProps.rowActions.map((rowAction, index) =>\n rowAction?.gridActionProps?.multiRecord === true ? (\n <TemplateGridMultiRecordAction\n {...rowAction}\n key={index}\n reloadData={async () => {\n props.templateProps.apiActions.reloadData(\n props?.templateProps?.gridLoadParametersValues\n );\n }}\n recordIdsToProcessActionOn={gridSelection.selectedRecordIds}\n recordsToProcessActionOn={gridSelection.selectedRecords}\n />\n ) : null\n )\n ) : (\n <></>\n )}\n <Box sx={{ flex: 1, mx: 0.5, my: 0.5, padding: 1 }}>\n {props?.templateProps?.tBar}\n </Box>\n\n <Tooltip title=\"Columns\">\n <ColumnsPanelTrigger render={<ToolbarButton />}>\n <GridViewColumnIcon fontSize=\"small\" />\n </ColumnsPanelTrigger>\n </Tooltip>\n\n <Tooltip title=\"Filters\">\n <FilterPanelTrigger\n render={(props, state) => (\n <ToolbarButton {...props} color=\"default\">\n <Badge\n badgeContent={state.filterCount}\n color=\"primary\"\n variant=\"dot\"\n >\n <GridFilterListIcon fontSize=\"small\" />\n </Badge>\n </ToolbarButton>\n )}\n />\n </Tooltip>\n\n {props?.templateProps?.gridStateKey ? (\n <Tooltip title={t(\"RESET_GRID_STATE\")}>\n <IconButton onClick={props?.clearGridState}>\n <FontAwesomeIcon icon=\"eraser\" />\n </IconButton>\n </Tooltip>\n ) : (\n <></>\n )}\n\n <Divider\n orientation=\"vertical\"\n variant=\"middle\"\n flexItem\n sx={{ mx: 0.5 }}\n />\n\n <Tooltip title={t(\"EXPORT_EXECL_LABEL\")}>\n <ExportExcel render={<MenuItem />}>\n <FontAwesomeIcon icon=\"file-excel\" color=\"green\" />\n </ExportExcel>\n </Tooltip>\n\n <StyledQuickFilter>\n <QuickFilterTrigger\n render={(triggerProps, state) => (\n <Tooltip title={t(\"SEARCH_BTN_LABEL\")} enterDelay={0}>\n <StyledToolbarButton\n {...triggerProps}\n ownerState={{ expanded: state.expanded }}\n color=\"default\"\n aria-disabled={state.expanded}\n >\n <FontAwesomeIcon icon=\"search\" />\n </StyledToolbarButton>\n </Tooltip>\n )}\n />\n <QuickFilterControl\n render={({ ref, ...controlProps }, state) => (\n <StyledTextField\n {...controlProps}\n ownerState={{ expanded: state.expanded }}\n inputRef={ref}\n aria-label=\"Search\"\n placeholder={`${t(\"SEARCH_BTN_LABEL\")}...`}\n size=\"small\"\n slotProps={{\n input: {\n startAdornment: (\n <InputAdornment position=\"start\">\n <FontAwesomeIcon icon=\"search\" />\n </InputAdornment>\n ),\n endAdornment: state.value ? (\n <InputAdornment position=\"end\">\n <QuickFilterClear\n edge=\"end\"\n size=\"small\"\n aria-label=\"Clear search\"\n // material={{ sx: { marginRight: -0.75 } }}\n >\n <FontAwesomeIcon icon=\"xmark\" />\n </QuickFilterClear>\n </InputAdornment>\n ) : null,\n ...controlProps.slotProps?.input,\n },\n ...controlProps.slotProps,\n }}\n />\n )}\n />\n </StyledQuickFilter>\n\n <IconButton\n onClick={() => {\n props.templateProps.apiActions.reloadData(\n props?.templateProps?.gridLoadParametersValues\n );\n }}\n >\n <FontAwesomeIcon icon=\"refresh\" />\n </IconButton>\n </Toolbar>\n );\n};\n\nexport default TemplateGridTopBar;\n","import { Tooltip } from \"@mui/material\";\nimport { GridActionsCellItem } from \"@mui/x-data-grid-premium\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { RecordAction } from \"../DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport useSession from \"../../../../hooks/UseSession\";\nimport { useConfirmationWindow } from \"../../../../hooks/UseConfirmationWindow\";\n\nconst TemplateGridRecordAction: React.FC<RecordAction> = (\n rowAction: RecordAction\n) => {\n const { t } = useTranslation();\n const session = useSession();\n const { ConfirmationWindow, setOpen } = useConfirmationWindow({\n body: t(rowAction?.confirmationMessage || \"ACTION_CONFIRMATION\"),\n title: t(\"CONFIRMATION\"),\n onConfirmationCallBk: async () => {\n await rowAction?.actionFn(rowAction.record);\n if (rowAction?.reloadData) {\n rowAction.reloadData();\n }\n },\n });\n let isActionAllowed = true;\n if (rowAction.authority) {\n isActionAllowed = session.isUserAuthorized(rowAction.authority);\n }\n let iconStyle: any = {};\n if (rowAction?.getActionIconStyleForRecord) {\n iconStyle = rowAction.getActionIconStyleForRecord(rowAction.record);\n }\n let isActionVisibleForRecord = true;\n if (rowAction?.isActionVisibleForRecord) {\n isActionVisibleForRecord = rowAction?.isActionVisibleForRecord(\n rowAction.record\n );\n }\n let isActionDisabledForRecord = false;\n if (rowAction?.isActionDisabledForRecord) {\n isActionDisabledForRecord = rowAction.isActionDisabledForRecord(\n rowAction.record\n );\n }\n if (isActionAllowed && isActionVisibleForRecord) {\n return (\n <>\n <ConfirmationWindow />\n <GridActionsCellItem\n disabled={isActionDisabledForRecord}\n icon={\n <Tooltip title={rowAction?.label ? t(rowAction.label) : \"\"}>\n <FontAwesomeIcon\n icon={rowAction.icon}\n style={{\n ...iconStyle,\n color: isActionDisabledForRecord\n ? \"gray\"\n : iconStyle?.color != undefined\n ? iconStyle.color\n : undefined,\n }}\n />\n </Tooltip>\n }\n showInMenu={rowAction?.gridActionProps?.showInMenu || false}\n label={\"\"}\n className=\"textPrimary\"\n color=\"inherit\"\n onClick={async () => {\n if (!isActionDisabledForRecord) {\n if (rowAction?.preActionValidation) {\n if (!rowAction.preActionValidation(rowAction.record)) {\n return;\n }\n }\n if (rowAction?.isConfirmationRequired === true) {\n setOpen(true);\n } else {\n await rowAction.actionFn(rowAction.record);\n if (\n rowAction?.gridActionProps?.reloadGridAfterAction === true &&\n rowAction?.reloadData\n ) {\n rowAction.reloadData();\n }\n }\n }\n }}\n />\n </>\n );\n }\n};\n\nexport default TemplateGridRecordAction;\n","import {\n DataGridPremium,\n GridActionsCellItem,\n GridActionsCellItemProps,\n GridColumnOrderChangeParams,\n GridColumnResizeParams,\n GridColumnVisibilityModel,\n GridEventListener,\n GridExpandMoreIcon,\n GridPinnedColumnFields,\n GridRowGroupingModel,\n GridRowModes,\n GridRowModesModel,\n GridRowParams,\n GridRowSelectionModel,\n} from \"@mui/x-data-grid-premium\";\nimport { TemplateGridColDef, TemplateGridProps } from \"../DataEntryTypes\";\nimport TemplateGridTopBar from \"./TemplateGridTopBar\";\nimport { useNavigate } from \"react-router-dom\";\nimport React, { useEffect, useState } from \"react\";\nimport { z } from \"zod\";\nimport {\n constructGridColumnsFromFields,\n constructValidationSchema,\n getAllFields,\n} from \"../DataEntryUtil\";\nimport { toast } from \"react-toastify\";\nimport {\n Accordion,\n AccordionDetails,\n AccordionSummary,\n Box,\n Divider,\n IconButton,\n Tooltip,\n Typography,\n} from \"@mui/material\";\nimport { capitalizeFirstLetter, isNumber } from \"../../../../util/AppUtils\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport TemplateGridRecordAction from \"./TemplateGridRecordAction\";\nimport TemplateForm from \"../TemplateDataForm/TemplateForm\";\nimport { useSelector } from \"react-redux\";\nimport { useTranslation } from \"react-i18next\";\nimport useSession from \"../../../../hooks/UseSession\";\nimport { useConfirmationWindow } from \"../../../../hooks/UseConfirmationWindow\";\nimport { useWindow } from \"../../../../hooks/UseWindow\";\nimport { useAxios } from \"../../../../hooks\";\nimport useLookupGridColumn from \"../../../../hooks/useLookupGridColumn\";\nimport { ContinuousColorLegend } from \"@mui/x-charts\";\nimport AttachmentPanel from \"../../attachment/AttachmentPanel\";\nimport WorkflowDocumentPanel from \"../../workflow/WorkflowDocumentPanel\";\nlet currentNewRecordIndex = -1;\n\ninterface GridState {\n columnVisibilityModel?: GridColumnVisibilityModel;\n columnOrder?: string[];\n columnWidths?: { [key: string]: number };\n columnGroupingModel?: GridRowGroupingModel;\n pinnedColumns?: GridPinnedColumnFields;\n}\n\nconst loadGridState = (gridStateKey: string): GridState => {\n try {\n const saved = localStorage.getItem(gridStateKey);\n return saved ? JSON.parse(saved) : {};\n } catch (e) {\n console.error(\"Failed to load grid state\", e);\n return {};\n }\n};\n\nconst saveGridState = (gridStateKey: string, statePart: GridState) => {\n const current = loadGridState(gridStateKey);\n localStorage.setItem(\n gridStateKey,\n JSON.stringify({ ...current, ...statePart })\n );\n};\n\nconst PIN_FIXED_COLUMNS = [\"__check__\", \"actions\"];\n\nconst TemplateGrid: React.FC<TemplateGridProps> = (props) => {\n const { t } = useTranslation();\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const [selectedRecord, setSelectedRecord] = useState<any>({});\n const [attachmentPanelEnabledForRecord, setAttachmentPanelEnabledForRecord] =\n useState<boolean>(true);\n const { getLookupOptions } = useLookupGridColumn();\n const { Window: AttachmentWindow, setWindowState: setAttachmentWindowState } =\n useWindow({\n windowTitle: t(props.gridTitle) + \" Attachments\",\n windowIcon: \"paperclip\",\n width: \"fit-content\",\n height: \"fit-content\",\n minHeight: 500,\n minWidth: \"50%\",\n onCloseCallBack: () => {\n props?.apiActions?.reloadData(props.gridLoadParametersValues);\n },\n });\n const { Window: WorkFlowWindow, setWindowState: setWorkFlowWindowState } =\n useWindow({\n windowTitle: t(props.gridTitle) + \" Approvals\",\n windowIcon: \"stamp\",\n width: \"fit-content\",\n height: \"fit-content\",\n minHeight: 500,\n minWidth: \"80%\",\n onCloseCallBack: () => {\n props?.apiActions?.reloadData(props.gridLoadParametersValues);\n },\n });\n const [generatedColumns, setGeneratedColumns] = useState<\n Array<TemplateGridColDef>\n >([]);\n const fields = getAllFields(props.formElements);\n const hiddenFields = [];\n const savedState = React.useMemo<GridState>(\n () => (props?.gridStateKey ? loadGridState(props.gridStateKey) : {}),\n []\n );\n for (const field of fields) {\n if (field?.gridProps?.hidden === true) {\n hiddenFields.push(field.fieldName);\n }\n }\n let initialVisibilityState: GridColumnVisibilityModel = {};\n if (savedState?.columnVisibilityModel) {\n initialVisibilityState = savedState.columnVisibilityModel;\n const existingFields = Object.keys(initialVisibilityState);\n for (const field of hiddenFields) {\n if (!existingFields.includes(field)) {\n initialVisibilityState[field] = false;\n }\n }\n } else {\n for (const field of hiddenFields) {\n initialVisibilityState[field] = false;\n }\n }\n\n const themeDirection = useSelector(\n (state: any) => state.AppLayout.appDirection\n );\n\n const clearGridState = () => {\n if (props?.gridStateKey) {\n localStorage.removeItem(props.gridStateKey);\n }\n setColumnVisibilityModel({});\n setColumnOrder([]);\n setColumnWidths({});\n setGridRowGroupingModel([]);\n setPinnedColumns({\n left: [...(themeDirection === \"ltr\" ? PIN_FIXED_COLUMNS : [])],\n right: [...(themeDirection === \"rtl\" ? PIN_FIXED_COLUMNS : [])],\n });\n };\n const [columnVisibilityModel, setColumnVisibilityModel] =\n React.useState<GridColumnVisibilityModel>(initialVisibilityState);\n const [columnOrder, setColumnOrder] = React.useState<string[]>(\n savedState.columnOrder || []\n );\n const [columnWidths, setColumnWidths] = React.useState<{\n [key: string]: number;\n }>(savedState.columnWidths || {});\n const [gridRowGroupingModel, setGridRowGroupingModel] =\n useState<GridRowGroupingModel>(savedState.columnGroupingModel || []);\n let newLeft = savedState?.pinnedColumns?.left || [];\n newLeft = newLeft.filter(\n (record: any) => !PIN_FIXED_COLUMNS.includes(record)\n );\n let newRight = savedState?.pinnedColumns?.right || [] || [];\n newRight = newRight.filter(\n (record: any) => !PIN_FIXED_COLUMNS.includes(record)\n );\n\n const [pinnedColumns, setPinnedColumns] = useState<GridPinnedColumnFields>({\n left: [...(themeDirection === \"ltr\" ? PIN_FIXED_COLUMNS : []), ...newLeft],\n right: [\n ...(themeDirection === \"rtl\" ? PIN_FIXED_COLUMNS : []),\n ...newRight,\n ],\n });\n\n const session = useSession();\n const navigate = useNavigate();\n const [recordToDelete, setRecordToDelete] = useState<any>(null);\n const [recordToEdit, setRecordToEdit] = useState<any>(null);\n const [rowModesModel, setRowModesModel] = useState<GridRowModesModel>({});\n const adjustGridColumns = async () => {\n let gridColumns = constructGridColumnsFromFields(\n fields,\n props?.editMode?.editMode === \"row\" || false,\n t\n );\n for (let gridColumn of gridColumns) {\n if (gridColumn?.lookupType) {\n gridColumn.displayField =\n AppLayout.appDirection === \"ltr\"\n ? \"lookupEnDisplay\"\n : \"lookupArDisplay\";\n gridColumn.options = await getLookupOptions(gridColumn.lookupType);\n gridColumn.valueField = \"lookupValue\";\n }\n }\n setGeneratedColumns(gridColumns);\n };\n const [rowSelectionModel, setRowSelectionModel] =\n useState<GridRowSelectionModel>({ ids: new Set(), type: \"include\" });\n let keyColumnName: string = \"id\";\n if (props?.keyColumnName) {\n keyColumnName = props?.keyColumnName;\n }\n const setData = props.setData;\n let validationSchema = null;\n if (props?.validationSchema) {\n validationSchema = props.validationSchema;\n } else {\n validationSchema = z.object(constructValidationSchema(fields));\n }\n\n let isEditAllowed = true;\n if (props?.editAction?.authority) {\n isEditAllowed = session.isUserAuthorized(props.editAction.authority);\n }\n let isDeleteAllowed = true;\n if (props?.deleteAction?.authority) {\n isDeleteAllowed = session.isUserAuthorized(props.deleteAction.authority);\n }\n\n const handleRowModesModelChange = (newModel: GridRowModesModel) => {\n setRowModesModel(newModel);\n };\n\n const handlePinnedColumnsChange = (newModel: GridPinnedColumnFields) => {\n let newLeft = newModel?.left || [];\n newLeft = newLeft.filter(\n (record: any) => !PIN_FIXED_COLUMNS.includes(record)\n );\n let newRight = newModel?.right || [];\n newRight = newRight.filter(\n (record: any) => !PIN_FIXED_COLUMNS.includes(record)\n );\n const newPinedColumns: GridPinnedColumnFields = {\n left: [\n ...(themeDirection === \"ltr\" ? PIN_FIXED_COLUMNS : []),\n ...newLeft,\n ],\n right: [\n ...(themeDirection === \"rtl\" ? PIN_FIXED_COLUMNS : []),\n ...newRight,\n ],\n };\n setPinnedColumns(newPinedColumns);\n if (props?.gridStateKey) {\n saveGridState(props.gridStateKey, { pinnedColumns: newPinedColumns });\n }\n };\n\n const handleDeleteRecord = async () => {\n let result = true;\n if (!(recordToDelete && recordToDelete?.isNew === true)) {\n result = await props.apiActions.deleteRecordById(\n recordToDelete[keyColumnName]\n );\n }\n if (result) {\n if (props?.deleteAction?.postActionCallBack) {\n await props.deleteAction.postActionCallBack(recordToDelete);\n }\n\n setData((oldData: any) => {\n const newData = oldData.filter(\n (record: any) =>\n record[keyColumnName] != recordToDelete[keyColumnName]\n );\n return newData;\n });\n }\n };\n\n const { ConfirmationWindow, setOpen: setConfirmationWindowOpened } =\n useConfirmationWindow({\n title: \"Confirmation\",\n body: \"Are you sure you want to delete this record ?\",\n onConfirmationCallBk: handleDeleteRecord,\n });\n\n let formModalHeight = undefined;\n let formModalWidth = undefined;\n let formModalMinHeight = undefined;\n let formModalMinWidth = undefined;\n let formModalIcon = undefined;\n let formModalTitle = undefined;\n\n if (props?.editMode?.editMode === \"modal\") {\n formModalHeight = props?.editMode?.specs?.modalHeight || \"fit-content\";\n formModalWidth = props?.editMode?.specs?.modalWidth || \"300\";\n formModalMinHeight = props?.editMode?.specs?.modalMinHeight;\n formModalMinWidth = props?.editMode?.specs?.modalMinWidth;\n formModalIcon = props?.editMode?.specs?.modalIcon || \"window\";\n formModalTitle = props?.editMode?.specs?.modalTitle || \"Record Form\";\n }\n\n const { Window: FormWindow, setWindowState: setFormWindowState } = useWindow({\n height: formModalHeight,\n minHeight: formModalMinHeight,\n minWidth: formModalMinWidth,\n onCloseCallBack: () => {\n props.apiActions.reloadData(props?.gridLoadParametersValues);\n },\n width: formModalWidth,\n windowIcon: formModalIcon,\n windowTitle: formModalTitle,\n });\n\n const handleCreateNewRecord = () => {\n if (props?.editMode?.editMode === \"form\") {\n navigate(props.editMode.specs.formRoute);\n } else if (props?.editMode?.editMode === \"modal\") {\n setRecordToEdit(null);\n setFormWindowState(true);\n } else if (props?.editMode?.editMode === \"row\") {\n currentNewRecordIndex = currentNewRecordIndex - 1;\n const newRecord: any = {};\n newRecord[keyColumnName] = currentNewRecordIndex;\n newRecord.isNew = true;\n for (const gridColumn of generatedColumns) {\n if (\n gridColumn?.type != \"actions\" &&\n gridColumn?.field != keyColumnName\n ) {\n if (gridColumn?.field) {\n newRecord[gridColumn.field] = null;\n }\n }\n }\n setData((oldRows: any) => [newRecord, ...oldRows]);\n setRowModesModel((oldModel: any) => ({\n ...oldModel,\n [currentNewRecordIndex]: { mode: GridRowModes.Edit },\n }));\n }\n };\n\n const handleEditRecord = async (record: any) => {\n if (record) {\n setRecordToEdit(record);\n if (props.editMode.editMode === \"form\") {\n navigate(props.editMode.specs.formRoute + \"/\" + record[keyColumnName]);\n } else if (props.editMode.editMode === \"modal\") {\n setFormWindowState(true);\n } else if (props?.editMode?.editMode === \"row\") {\n const id = record[keyColumnName];\n setRowModesModel({\n ...rowModesModel,\n [id]: { mode: GridRowModes.Edit },\n });\n }\n }\n };\n\n const validateRecord = (record: any) => {\n try {\n validationSchema.parse(record);\n } catch (err) {\n console.log(\"validateRecord err\", err);\n let errorMessage: any = null;\n if (err instanceof z.ZodError) {\n errorMessage = err.errors\n .map(\n (error) => \"Error in field (\" + error.path + \") : \" + error.message\n )\n .join(\",\");\n } else {\n errorMessage = \"invalid record data\";\n }\n return errorMessage;\n }\n };\n\n const handleSaveRowClick = (record: any) => {\n const id = record[keyColumnName];\n setRowModesModel({\n ...rowModesModel,\n [id]: { mode: GridRowModes.View },\n });\n };\n\n const processRowUpdate = async (record: any) => {\n if (props.editMode.editMode === \"row\") {\n let savedRecord: any = null;\n const errorMessage = validateRecord(record);\n if (errorMessage) {\n const errors = errorMessage.split(\",\");\n toast.error(\n <div style={{}}>\n {errors.map((error: any) => (\n <>\n <div>{error}</div>\n <Divider />\n </>\n ))}\n </div>\n );\n throw new Error(errorMessage);\n }\n if (props?.editAction?.preActionValidation) {\n if (!props.editAction.preActionValidation(record)) {\n throw new Error(\"error on the configured presave validation\");\n }\n }\n const requestObject: any = { ...record };\n if (\n record[keyColumnName] &&\n isNumber(record[keyColumnName]) &&\n Number(record[keyColumnName]) < 0\n ) {\n requestObject[keyColumnName] = null;\n }\n savedRecord = await props.apiActions.saveRecord(requestObject);\n if (savedRecord == null) {\n throw new Error(\n \"Failed to process your request, contact your administrator\"\n );\n }\n if (props?.editAction?.postActionCallBack) {\n await props.editAction.postActionCallBack(record);\n }\n if (record?.isNew === true) {\n setData((oldData: any) => {\n const newData = oldData.filter(\n (x: any) => x[keyColumnName] !== record[keyColumnName]\n );\n return [savedRecord, ...newData];\n });\n }\n if (\n props?.editMode?.reloadAfterSave === true &&\n props?.apiActions?.reloadData\n ) {\n props?.apiActions?.reloadData(props?.gridLoadParametersValues);\n }\n return savedRecord;\n }\n };\n\n const handleCancelRowEditClick = (record: any) => {\n const id = record[keyColumnName];\n if (id && isNumber(id) && id < 0) {\n setRowModesModel({\n ...rowModesModel,\n [id]: { mode: GridRowModes.View, ignoreModifications: true },\n });\n setData((oldData: any) => {\n const newData = oldData.filter(\n (record: any) => record[keyColumnName] != id\n );\n return newData;\n });\n } else {\n setRowModesModel({\n ...rowModesModel,\n [id]: { mode: GridRowModes.View, ignoreModifications: true },\n });\n }\n };\n\n const getActionColumnActions = (params: GridRowParams<any>) => {\n const record: any = params.row;\n const actions: Array<React.ReactElement<GridActionsCellItemProps>> = [];\n if (props?.editMode?.editMode != \"none\") {\n if (\n props?.disableDefaultAction === undefined ||\n !props.disableDefaultAction\n ) {\n const isInEditMode: boolean =\n rowModesModel[record[keyColumnName]]?.mode === GridRowModes.Edit;\n if (props.editMode.editMode === \"row\" && isInEditMode) {\n if (isEditAllowed) {\n actions.push(\n <GridActionsCellItem\n icon={<FontAwesomeIcon icon=\"save\" />}\n label={t(\"SAVE_BTN_LABEL\")}\n onClick={() => {\n handleSaveRowClick(record);\n }}\n />\n );\n actions.push(\n <GridActionsCellItem\n icon={<FontAwesomeIcon icon=\"cancel\" />}\n label={t(\"CANCEL_BTN_LABEL\")}\n onClick={() => {\n handleCancelRowEditClick(record);\n }}\n color=\"inherit\"\n />\n );\n }\n } else {\n if (props?.editAction && props?.editAction?.isEnabled === true) {\n let isEditActionVisibleForRecord = true;\n if (props?.editAction?.isActionVisibleForRecord) {\n isEditActionVisibleForRecord =\n props?.editAction?.isActionVisibleForRecord(record);\n }\n let isActionEditDisabledForRecord = false;\n if (props?.editAction?.isActionDisabledForRecord) {\n isActionEditDisabledForRecord =\n props?.editAction?.isActionDisabledForRecord(record);\n }\n if (isEditAllowed && isEditActionVisibleForRecord) {\n actions.push(\n <GridActionsCellItem\n disabled={isActionEditDisabledForRecord}\n icon={\n <Tooltip title={t(\"EDIT_BTN_LABEL\")}>\n <FontAwesomeIcon\n icon={\"edit\"}\n style={{\n color: isActionEditDisabledForRecord\n ? \"gray\"\n : undefined,\n }}\n />\n </Tooltip>\n }\n showInMenu={\n props?.editAction?.gridActionProps?.showInMenu || false\n }\n label={t(\"EDIT_BTN_LABEL\")}\n className=\"textPrimary\"\n color=\"inherit\"\n onClick={() => {\n if (isEditAllowed && !isActionEditDisabledForRecord) {\n handleEditRecord(record);\n }\n }}\n />\n );\n }\n }\n if (props?.deleteAction && props?.deleteAction?.isEnabled === true) {\n let isDeleteActionVisibleForRecord = true;\n if (props?.deleteAction?.isActionVisibleForRecord) {\n isDeleteActionVisibleForRecord =\n props?.deleteAction?.isActionVisibleForRecord(record);\n }\n let isDeleteActionDisabledForRecord = false;\n if (props?.deleteAction?.isActionDisabledForRecord) {\n isDeleteActionDisabledForRecord =\n props?.deleteAction?.isActionDisabledForRecord(record);\n }\n if (isDeleteAllowed && isDeleteActionVisibleForRecord) {\n actions.push(\n <GridActionsCellItem\n disabled={isDeleteActionDisabledForRecord}\n icon={\n <Tooltip title={t(\"DELETE_BTN_LABEL\")}>\n <FontAwesomeIcon\n icon={\"trash\"}\n style={{\n color: isDeleteActionDisabledForRecord\n ? \"gray\"\n : undefined,\n }}\n />\n </Tooltip>\n }\n showInMenu={\n props?.deleteAction?.gridActionProps?.showInMenu || false\n }\n label={t(\"DELETE_BTN_LABEL\")}\n className=\"textPrimary\"\n color=\"inherit\"\n onClick={() => {\n if (isDeleteAllowed && !isDeleteActionDisabledForRecord) {\n if (props?.deleteAction?.preActionValidation) {\n if (!props.deleteAction.preActionValidation(record)) {\n return;\n }\n }\n setRecordToDelete(record);\n setConfirmationWindowOpened(true);\n }\n }}\n />\n );\n }\n }\n }\n }\n }\n if (\n record[props?.keyColumnName || \"id\"] &&\n record[props?.keyColumnName || \"id\"] > 0 &&\n props?.attachment\n ) {\n actions?.push(\n <GridActionsCellItem\n icon={\n <Tooltip title={\"Attachments\"}>\n <FontAwesomeIcon icon={\"paperclip\"} />\n </Tooltip>\n }\n label={\"Attachments\"}\n className=\"textPrimary\"\n color=\"inherit\"\n onClick={() => {\n setSelectedRecord(record);\n if (props?.attachment?.enableAttachFn) {\n setAttachmentPanelEnabledForRecord(\n props.attachment.enableAttachFn(record)\n );\n } else {\n setAttachmentPanelEnabledForRecord(true);\n }\n setAttachmentWindowState(true);\n }}\n />\n );\n }\n if (\n record[props?.keyColumnName || \"id\"] &&\n record[props?.keyColumnName || \"id\"] > 0 &&\n props?.workFlowDocumentCode\n ) {\n actions?.push(\n <GridActionsCellItem\n icon={\n <Tooltip title={\"Approvals\"}>\n <FontAwesomeIcon icon={\"stamp\"} />\n </Tooltip>\n }\n label={\"Approvals\"}\n className=\"textPrimary\"\n color=\"inherit\"\n onClick={() => {\n setSelectedRecord(record);\n setWorkFlowWindowState(true);\n }}\n />\n );\n }\n if (\n record[props?.keyColumnName || \"id\"] &&\n record[props?.keyColumnName || \"id\"] > 0 &&\n props?.rowActions\n ) {\n for (const rowAction of props.rowActions) {\n if (\n !(\n rowAction?.gridActionProps?.multiRecord &&\n rowAction?.gridActionProps?.multiRecord === true\n )\n ) {\n actions.push(\n <TemplateGridRecordAction\n {...rowAction}\n record={record}\n reloadData={async () => {\n props.apiActions.reloadData(props?.gridLoadParametersValues);\n }}\n />\n );\n }\n }\n }\n\n return actions;\n };\n\n const actionColumn: TemplateGridColDef = {\n type: \"actions\",\n field: \"actions\",\n headerName: \"\",\n headerAlign: \"center\",\n width:\n (props?.rowActions ? props.rowActions.length * 30 : 0) +\n (props?.editAction && props?.editAction?.isEnabled ? 30 : 0) +\n (props?.deleteAction && props?.deleteAction?.isEnabled ? 30 : 0) +\n (props?.attachment ? 30 : 0) +\n (props?.workFlowDocumentCode ? 30 : 0),\n getActions: getActionColumnActions,\n };\n\n let structuredColumns: Array<TemplateGridColDef> = [];\n if (\n props?.disableDefaultAction === undefined ||\n !props.disableDefaultAction ||\n (props?.rowActions && props?.rowActions.length > 0)\n ) {\n structuredColumns.push(actionColumn);\n }\n\n structuredColumns = [...structuredColumns, ...generatedColumns];\n const handleRowSelection = (gridSelectionModel: GridRowSelectionModel) => {\n setRowSelectionModel(gridSelectionModel);\n };\n useEffect(() => {\n if (props?.autoLoad === undefined || props.autoLoad === true) {\n props.apiActions.reloadData(props?.gridLoadParametersValues);\n }\n adjustGridColumns();\n }, []);\n\n useEffect(() => {\n props.apiActions.reloadData(props?.gridLoadParametersValues);\n }, [session.UserInfo?.currentOrganization]);\n\n useEffect(() => {\n adjustGridColumns();\n }, [themeDirection, props.formElements]);\n\n const handleColumnVisibilityChange = (model: GridColumnVisibilityModel) => {\n setColumnVisibilityModel(model);\n if (props?.gridStateKey) {\n saveGridState(props.gridStateKey, { columnVisibilityModel: model });\n }\n };\n\n const handleColumnOrderChange: GridEventListener<\"columnOrderChange\"> = (\n params: GridColumnOrderChangeParams\n ) => {\n const { column, targetIndex } = params;\n setColumnOrder((prevOrder) => {\n const currentOrder = prevOrder.length\n ? [...prevOrder]\n : structuredColumns.map((col) => col.field);\n const fromIndex = currentOrder.indexOf(column.field);\n if (fromIndex === -1) return currentOrder;\n\n currentOrder.splice(fromIndex, 1); // remove\n currentOrder.splice(targetIndex, 0, column.field); // insert at new index\n\n if (props?.gridStateKey) {\n saveGridState(props.gridStateKey, { columnOrder: currentOrder });\n }\n\n return currentOrder;\n });\n };\n\n const handleRowGroupChange = (model: GridRowGroupingModel) => {\n setGridRowGroupingModel(model);\n if (props?.gridStateKey) {\n saveGridState(props.gridStateKey, { columnGroupingModel: model });\n }\n };\n\n // const handleColumnWidthChange: GridEventListener<\"columnWidthChange\"> = (\n // params: GridColumnResizeParams\n // ) => {\n // const updatedWidths = {\n // ...columnWidths,\n // [params.colDef.field]: params.width,\n // };\n // setColumnWidths(updatedWidths);\n // if (props?.gridStateKey) {\n // saveGridState(props.gridStateKey, { columnWidths: updatedWidths });\n // }\n // };\n\n const adjustedColumns: Array<TemplateGridColDef> = React.useMemo(() => {\n const baseCols = structuredColumns.map((col) => ({\n ...col,\n }));\n\n // Reorder based on saved columnOrder\n if (columnOrder.length) {\n const fieldToCol = new Map(baseCols.map((col) => [col.field, col]));\n return columnOrder.map((field) => fieldToCol.get(field)!).filter(Boolean);\n }\n return baseCols;\n }, [columnOrder, columnWidths, structuredColumns]);\n\n return (\n <>\n <ConfirmationWindow />\n {props?.editMode?.editMode === \"modal\" ? (\n <FormWindow>\n {props?.editMode?.specs?.formComponent ? (\n <props.editMode.specs.formComponent\n recordIdToEdit={\n recordToEdit ? recordToEdit[keyColumnName] : undefined\n }\n formCloseCallBk={() => {\n setFormWindowState(false);\n props.apiActions.reloadData(props?.gridLoadParametersValues);\n }}\n />\n ) : (\n <TemplateForm\n keyColumnName={props.keyColumnName}\n attachment={props.attachment}\n formValuesChangeCallBk={props?.formProps?.formValuesChangeCallBk}\n recordIdToEdit={\n recordToEdit ? recordToEdit[keyColumnName] : undefined\n }\n formCloseCallBk={() => {\n setFormWindowState(false);\n props.apiActions.reloadData(props?.gridLoadParametersValues);\n }}\n elements={props.formElements}\n apiActions={props.apiActions}\n editAuthorityKey={props?.editAction?.authority}\n formSavedSuccessfullyCallBk={\n props?.editAction?.postActionCallBack\n }\n preSaveValidation={props?.editAction?.preActionValidation}\n actions={props?.rowActions}\n />\n )}\n </FormWindow>\n ) : (\n <></>\n )}\n {props?.hideInfoBar === undefined && !props?.hideInfoBar ? (\n <Box sx={{ display: \"flex\" }}>\n {props?.hideBackButton === undefined && !props?.hideBackButton ? (\n <IconButton\n onClick={() => {\n navigate(-1, { replace: true });\n }}\n >\n <FontAwesomeIcon\n icon={themeDirection === \"ltr\" ? \"arrow-left\" : \"arrow-right\"}\n />\n </IconButton>\n ) : (\n <></>\n )}\n <Box\n sx={{\n flex: 1,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n {props?.girdIcon ? (\n <FontAwesomeIcon\n icon={props.girdIcon}\n style={{ marginRight: 5, marginLeft: 5 }}\n />\n ) : (\n <></>\n )}\n <Typography variant=\"h5\">\n {props?.gridTitle\n ? capitalizeFirstLetter(t(props?.gridTitle))\n : \"\"}\n </Typography>\n </Box>\n </Box>\n ) : (\n <></>\n )}\n\n {props?.gridLoadParameters &&\n props?.gridLoadParameters.length > 0 &&\n props?.gridLoadParametersValues &&\n props?.setGridLoadParametersValues ? (\n <Accordion defaultExpanded sx={{ width: \"100%\" }}>\n <AccordionSummary expandIcon={<GridExpandMoreIcon />}>\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <FontAwesomeIcon\n style={{ marginLeft: 5, marginRight: 5 }}\n icon=\"search\"\n />\n <Typography component=\"span\">Filters</Typography>\n </Box>\n </AccordionSummary>\n <AccordionDetails>\n <Box>\n <TemplateForm\n saveButtonSpecs={{\n label: t(\"SEARCH_BTN_LABEL\"),\n icon: \"search\",\n actionButtonVariant: \"outlined\",\n actionButtonColor: \"success\",\n }}\n cancelButtonSpecs={{\n label: t(\"RESET_BTN_LABEL\"),\n icon: \"eraser\",\n actionButtonVariant: \"outlined\",\n actionButtonColor: \"error\",\n }}\n apiActions={{\n deleteRecordById: async () => {\n return true;\n },\n saveRecord: async (params) => {\n if (params != undefined) {\n props.setGridLoadParametersValues(params);\n } else {\n props.setGridLoadParametersValues({});\n }\n props.apiActions.reloadData(params);\n },\n reloadData: async () => {},\n loadRecordById: async () => {},\n }}\n elements={props.gridLoadParameters}\n />\n </Box>\n </AccordionDetails>\n </Accordion>\n ) : (\n <></>\n )}\n {props?.attachment ? (\n <AttachmentWindow>\n <AttachmentPanel\n attachmentCode={props.attachment.attachmentCode}\n refKey={selectedRecord[props?.keyColumnName || \"id\"]}\n enableAttachment={attachmentPanelEnabledForRecord}\n />\n </AttachmentWindow>\n ) : (\n <></>\n )}\n {props?.workFlowDocumentCode ? (\n <WorkFlowWindow>\n <WorkflowDocumentPanel\n workFlowDocumentCode={props.workFlowDocumentCode}\n refDocumentId={selectedRecord[props?.keyColumnName || \"id\"]}\n postActionCallBk={() => {\n setWorkFlowWindowState(false);\n props.apiActions.reloadData(props.gridLoadParametersValues);\n }}\n cancelActionCallBk={() => {\n setWorkFlowWindowState(false);\n props.apiActions.reloadData(props.gridLoadParametersValues);\n }}\n />\n </WorkFlowWindow>\n ) : (\n <></>\n )}\n <DataGridPremium\n {...props?.muiProps}\n slots={{ toolbar: TemplateGridTopBar }}\n slotProps={{\n toolbar: {\n templateProps: {\n ...props,\n rowSelectionModel: rowSelectionModel,\n data: props?.data,\n },\n handleCreateNewRecord,\n clearGridState,\n } as any,\n }}\n getRowId={(record: any) => {\n return record[keyColumnName];\n }}\n showToolbar={true}\n rows={props?.data}\n columns={adjustedColumns}\n checkboxSelection\n editMode=\"row\"\n onRowEditStop={(params, event) => {\n if (params.reason === \"rowFocusOut\") {\n event.defaultMuiPrevented = true;\n }\n }}\n rowModesModel={\n props.editMode.editMode == \"row\" ? rowModesModel : undefined\n }\n onRowModesModelChange={\n props.editMode.editMode == \"row\"\n ? handleRowModesModelChange\n : undefined\n }\n rowGroupingColumnMode=\"multiple\"\n processRowUpdate={processRowUpdate}\n rowSelectionModel={rowSelectionModel}\n onRowSelectionModelChange={handleRowSelection}\n columnVisibilityModel={columnVisibilityModel}\n onColumnVisibilityModelChange={handleColumnVisibilityChange}\n onColumnOrderChange={handleColumnOrderChange}\n // onColumnWidthChange={handleColumnWidthChange}\n rowGroupingModel={gridRowGroupingModel}\n onRowGroupingModelChange={(model: GridRowGroupingModel) => {\n handleRowGroupChange(model);\n }}\n // pinnedColumns={pinnedColumns}\n // onPinnedColumnsChange={handlePinnedColumnsChange}\n sx={{ width: \"100%\" }}\n />\n </>\n );\n};\n\nexport default TemplateGrid;\n","import { useSelector } from \"react-redux\";\nimport { TemplateGridColDef } from \"../components\";\nimport useAxios from \"./useAxios\";\n\nconst useLookupGridColumn = () => {\n const { handleGetRequest } = useAxios();\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const getLookupOptions = async (lookupType: string) => {\n let options = [];\n await handleGetRequest({\n endPointURI: \"api/v1/public/system/lookup\",\n showMask: true,\n parameters: { lookupType },\n successCallBkFn: (response: any) => {\n options = response.data;\n },\n });\n return options;\n };\n const generateLookupGridColumn = async (props: TemplateGridColDef) => {\n let options = await getLookupOptions(props.lookupType);\n return {\n ...props,\n options,\n displayField:\n AppLayout.appDirection === \"ltr\"\n ? \"lookupEnDisplay\"\n : \"lookupArDisplay\",\n valueField: \"lookupValue\",\n };\n };\n return { generateLookupGridColumn, getLookupOptions };\n};\n\nexport default useLookupGridColumn;\n","import { useEffect, useState } from \"react\";\nimport TemplateGrid from \"../DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../DataEntryTemplates/DataEntryTypes\";\n\ntype ExcelReportViewerProps = {\n reportData: Array<any>;\n setReportData: (data) => void;\n reloadReport: () => void;\n gridLoadParameters?: Array<FormElementProps>;\n gridLoadParametersValues?: { [key: string]: any };\n setGridLoadParametersValues?: any;\n};\n\nconst getGridColumnsFromRecord = (data: Array<any>) => {\n if (data.length === 0) {\n return [];\n }\n const formElements: Array<FormElementProps> = [];\n for (const key of Object.keys(data[0])) {\n const formElement: FormElementProps = {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: key,\n fieldName: key,\n fieldType: \"text\",\n },\n };\n formElements.push(formElement);\n }\n debugger;\n return formElements;\n};\n\nconst ExcelReportViewer: React.FC<ExcelReportViewerProps> = (props) => {\n const [data, setData] = useState([]);\n useEffect(() => {\n const newData = props.reportData.map((record, index) => {\n return { ...record, report_record_data_key: index };\n });\n setData(newData);\n }, [props.reportData]);\n return (\n <TemplateGrid\n data={data}\n disableDefaultAction={true}\n setData={props.setReportData}\n formElements={getGridColumnsFromRecord(props.reportData)}\n gridLoadParameters={props.gridLoadParameters}\n gridLoadParametersValues={props.gridLoadParametersValues}\n setGridLoadParametersValues={props.setGridLoadParametersValues}\n editMode={{ editMode: \"none\" }}\n girdIcon={\"file-excel\"}\n gridTitle=\"Report\"\n autoLoad={true}\n keyColumnName={\"report_record_data_key\"}\n hideInfoBar={true}\n apiActions={{\n deleteRecordById: async () => {\n return true;\n },\n loadRecordById: async () => {},\n reloadData: async () => {\n props.reloadReport();\n },\n saveRecord: async () => {},\n }}\n />\n );\n};\n\nexport default ExcelReportViewer;\n","import { useEffect, useState } from \"react\";\nimport {\n Accordion,\n AccordionDetails,\n AccordionSummary,\n Box,\n FontAwesomeIcon,\n FormElementProps,\n TemplateForm,\n Typography,\n} from \"../components\";\nimport { useTranslation } from \"react-i18next\";\n\nexport type EntityParameter = {\n parameterCode: string;\n parameterLabel: string;\n parameterValueFormat?: string;\n parameterValueField?: string;\n parameterDisplayField?: string;\n parameterDataset?: Array<any>;\n parameterDataQueryId?: number;\n hidden?: boolean;\n mandatory?: boolean;\n defaultValue?: any;\n parameterType:\n | \"text\"\n | \"number\"\n | \"date\"\n | \"datetime\"\n | \"combobox\"\n | \"checkbox\"\n | \"html\"\n | \"lookup\";\n};\n\nexport const getFormElementsFromParameters = (\n parameters: Array<EntityParameter>,\n parameterValues: any\n) => {\n const formElements: Array<FormElementProps> = [];\n for (const parameter of parameters) {\n const formElement: FormElementProps = {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: parameter?.parameterLabel,\n fieldName: parameter?.parameterCode,\n fieldType: parameter?.parameterType,\n hidden: parameter?.hidden,\n formProps: { fieldSize: { lg: 4, md: 6, sm: 12 } },\n required: parameter?.mandatory,\n defaultValue:\n parameterValues[parameter?.parameterCode] || parameter?.defaultValue,\n },\n };\n formElements.push(formElement);\n }\n return formElements;\n};\n\ninterface UseParameterPanelProps {\n parameters: Array<EntityParameter>;\n initialParameterValues?: any;\n}\n\nexport const useParameterPanel = (props: UseParameterPanelProps) => {\n console.log(\"useParameterPanel\", \"useParameterPanel called\");\n const [parametersValues, setParametersValues] = useState<any>({\n ...props?.initialParameterValues,\n });\n // const [panelElements, setPanelElements] = useState<Array<FormElementProps>>(\n // []\n // );\n const panelElements = getFormElementsFromParameters(\n props.parameters,\n parametersValues\n );\n // useEffect(() => {\n // setPanelElements(\n // getFormElementsFromParameters(props.parameters, parametersValues)\n // );\n // }, [props.parameters]);\n\n const ParameterPanel: React.FC<{\n searchBtnClickCallBk: (params: any) => Promise<void>;\n }> = ({ searchBtnClickCallBk }) => {\n const { t } = useTranslation();\n return (\n <Accordion defaultExpanded sx={{ width: \"100%\" }}>\n <AccordionSummary\n expandIcon={\n <FontAwesomeIcon\n icon={{ prefix: \"far\", iconName: \"square-caret-down\" }}\n />\n }\n >\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <FontAwesomeIcon\n style={{ marginLeft: 5, marginRight: 5 }}\n icon=\"search\"\n />\n <Typography component=\"span\">Filters</Typography>\n </Box>\n </AccordionSummary>\n <AccordionDetails>\n <Box>\n <TemplateForm\n saveButtonSpecs={{\n label: t(\"Filter\"),\n icon: \"search\",\n actionButtonVariant: \"outlined\",\n actionButtonColor: \"success\",\n }}\n cancelButtonSpecs={{\n label: t(\"RESET_BTN_LABEL\"),\n icon: \"eraser\",\n hidden: true,\n actionButtonVariant: \"outlined\",\n actionButtonColor: \"error\",\n }}\n actions={[\n {\n label: t(\"RESET_BTN_LABEL\"),\n icon: \"eraser\",\n isIdRequired: false,\n formActionProps: { enabled: true },\n actionFn: async (data, recordIdsToProcessActionOn) => {\n setParametersValues({});\n },\n },\n ]}\n apiActions={{\n deleteRecordById: async () => {\n return true;\n },\n saveRecord: async (params) => {\n if (params != undefined) {\n setParametersValues(params);\n } else {\n setParametersValues({});\n }\n if (searchBtnClickCallBk) {\n await searchBtnClickCallBk(parametersValues);\n }\n },\n reloadData: async () => {},\n loadRecordById: async () => {},\n }}\n elements={panelElements}\n />\n </Box>\n </AccordionDetails>\n </Accordion>\n );\n };\n return {\n ParameterPanel,\n parametersValues,\n setParametersValues,\n panelElements,\n };\n};\n","import { useEffect, useState } from \"react\";\nimport { useAxios } from \"../../../hooks\";\n\nimport { Box, IconButton } from \"@mui/material\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport ExcelReportViewer from \"./ExcelReportViewer\";\nimport { useParameterPanel } from \"../../../hooks/useParameterPanel\";\n\ntype ReportViewerState =\n | \"ERROR\"\n | \"WAITING_REPORT_CODE\"\n | \"LOADING_METADATA\"\n | \"WAITING_PARAMETER_INPUT\"\n | \"WAITING_RESULT\"\n | \"SHOWING_RESULT\";\n\ntype ReportViewerProps = {\n reportCode: string;\n resultMode: \"Request\" | \"App\";\n reportParametersValues?: { [key: string]: any };\n byPassParameterEntry?: boolean;\n jasperOutPutFileType?: \"pdf\" | \"word\" | \"excel\";\n};\n\nconst ReportViewer: React.FC<ReportViewerProps> = (props) => {\n const [blobUrl, setBlobUrl] = useState(null);\n const [errorMessage, setErrorMessage] = useState(null);\n const [excelReportData, setExcelReportData] = useState<Array<any>>([]);\n const [reportViewerState, setReportViewerState] = useState<ReportViewerState>(\n \"WAITING_REPORT_CODE\"\n );\n const { handleGetRequest, handlePostRequest, HandleDownloadHTTPPostPDF } =\n useAxios();\n const [reportInfo, setReportInfo] = useState<any>(null);\n const {\n ParameterPanel,\n parametersValues,\n panelElements,\n setParametersValues,\n } = useParameterPanel({\n parameters: reportInfo?.reportParameters || [],\n initialParameterValues: { ...props?.reportParametersValues },\n });\n const loadReportData = async () => {\n setReportViewerState(\"LOADING_METADATA\");\n await handleGetRequest({\n endPointURI: \"api/v1/public/report/metadata\",\n showMask: true,\n parameters: { reportCode: props.reportCode },\n successCallBkFn: (response: any) => {\n setReportInfo(response.data);\n if (\n props?.byPassParameterEntry === true ||\n response.data.reportParameters.length == 0\n ) {\n runReport(parametersValues);\n setReportViewerState(\"WAITING_RESULT\");\n } else {\n setReportViewerState(\"WAITING_PARAMETER_INPUT\");\n }\n },\n failureCallBkFn: (response) => {\n setErrorMessage(\n \"Failed loading report metadata ... contact your administrator\"\n );\n setReportViewerState(\"ERROR\");\n },\n });\n };\n\n const runReport = async (params) => {\n setReportViewerState(\"WAITING_RESULT\");\n if (reportInfo?.reportType === \"Excel\") {\n await handlePostRequest({\n endPointURI: \"api/v1/public/report/run\",\n showMask: true,\n data: {\n reportCode: props.reportCode,\n parameters: params,\n resultMode: props.resultMode,\n jasperOutPutFileType: props.jasperOutPutFileType,\n },\n successCallBkFn: (response: any) => {\n setReportViewerState(\"SHOWING_RESULT\");\n setExcelReportData(response.data);\n },\n });\n } else if (reportInfo?.reportType) {\n await HandleDownloadHTTPPostPDF({\n endPointURI: \"api/v1/public/report/run\",\n showMask: true,\n data: {\n reportCode: props.reportCode,\n parameters: params,\n resultMode: props.resultMode,\n jasperOutPutFileType: props.jasperOutPutFileType,\n },\n successCallBkFn: (response: any) => {\n setReportViewerState(\"SHOWING_RESULT\");\n const contentDisposition = response.headers[\"content-disposition\"];\n debugger;\n let filename = \"downloaded_file\";\n if (\n contentDisposition &&\n contentDisposition.indexOf(\"filename=\") !== -1\n ) {\n const match = contentDisposition.match(/filename=\"?([^\"]+)\"?/);\n if (match && match[1]) filename = match[1];\n }\n if (filename.includes(\"pdf\")) {\n const file = new Blob([response.data], { type: \"application/pdf\" });\n const url = URL.createObjectURL(file);\n setBlobUrl(url);\n } else {\n const blob = new Blob([response.data], {\n type: response.headers[\"content-type\"],\n });\n // Create a temporary anchor element\n const url = window.URL.createObjectURL(blob);\n const link = document.createElement(\"a\");\n link.href = url;\n // Optional: Try to get filename from response headers\n\n link.download = filename;\n document.body.appendChild(link);\n link.click();\n\n // Clean up\n document.body.removeChild(link);\n window.URL.revokeObjectURL(url);\n }\n },\n failureCallBkFn: (response) => {\n setErrorMessage(\n \"Failed To run report ... contact your administrator\"\n );\n setReportViewerState(\"ERROR\");\n },\n });\n }\n };\n\n useEffect(() => {\n if (props?.reportCode) {\n loadReportData();\n }\n }, [\n props.reportCode,\n props.byPassParameterEntry,\n props.reportParametersValues,\n props.jasperOutPutFileType,\n props.resultMode,\n ]);\n\n return (\n <>\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n width: \"100%\",\n }}\n >\n <Box sx={{ flex: 1, textAlign: \"center\", marginBottom: 1 }}>\n <FontAwesomeIcon\n icon={\n reportInfo?.reportType === \"Excel\" ? \"file-excel\" : \"file-pdf\"\n }\n color={reportInfo?.reportType === \"Excel\" ? \"darkgreen\" : \"darkred\"}\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n {reportInfo?.reportName}\n </Box>\n {reportInfo?.reportType != \"Excel\" ? (\n reportViewerState === \"SHOWING_RESULT\" ? (\n <>\n {props?.byPassParameterEntry === true ? (\n <></>\n ) : reportInfo?.reportParameters.length > 0 ? (\n <IconButton\n onClick={() => {\n setReportViewerState(\"WAITING_PARAMETER_INPUT\");\n }}\n >\n <FontAwesomeIcon icon=\"filter\" />\n </IconButton>\n ) : (\n <></>\n )}\n <IconButton>\n <FontAwesomeIcon\n icon=\"refresh\"\n onClick={() => {\n runReport(parametersValues);\n }}\n />\n </IconButton>\n </>\n ) : (\n <></>\n )\n ) : (\n <></>\n )}\n </Box>\n <Box\n sx={{\n flexGrow: 1,\n width: \"100%\",\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n }}\n >\n {reportViewerState === \"WAITING_PARAMETER_INPUT\" &&\n reportInfo?.reportType != \"Excel\" ? (\n <ParameterPanel searchBtnClickCallBk={runReport} />\n ) : reportViewerState === \"SHOWING_RESULT\" ||\n ((reportViewerState === \"WAITING_PARAMETER_INPUT\" ||\n reportViewerState === \"WAITING_RESULT\") &&\n reportInfo?.reportType === \"Excel\") ? (\n reportInfo?.reportType === \"Excel\" ? (\n <ExcelReportViewer\n reportData={excelReportData}\n setReportData={setExcelReportData}\n reloadReport={async () => {\n runReport(parametersValues);\n }}\n gridLoadParameters={panelElements}\n gridLoadParametersValues={parametersValues}\n setGridLoadParametersValues={setParametersValues}\n />\n ) : (\n <iframe\n src={blobUrl}\n width=\"100%\"\n height=\"100%\"\n title=\"PDF Preview\"\n style={{ border: \"1px solid #ccc\", marginTop: \"20px\" }}\n ></iframe>\n )\n ) : reportViewerState === \"ERROR\" ? (\n <Box\n sx={{\n display: \"flex\",\n flex: 1,\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <FontAwesomeIcon\n icon=\"circle-exclamation\"\n color=\"darkred\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n {errorMessage}\n </Box>\n ) : (\n <></>\n )}\n </Box>\n </>\n );\n};\n\nexport default ReportViewer;\n","import { useEffect, useState } from \"react\";\nimport { useAxios, useSession, useWindow } from \"../../../hooks\";\nimport {\n Avatar,\n Box,\n Button,\n Divider,\n Grid2,\n IconButton,\n Paper,\n} from \"@mui/material\";\nimport TemplateTextField from \"../DataEntryTemplates/TemplateDataForm/FormFields/TemplateTextField\";\nimport ComboBox from \"../DataEntryTemplates/TemplateDataForm/FormFields/ComboBox\";\nimport { useSelector } from \"react-redux\";\nimport { useTranslation } from \"react-i18next\";\nimport WorkflowDocumentTimeLine from \"./WorkflowDocumentTimeLine\";\nimport { toast } from \"react-toastify\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport ReportViewer from \"../report/ReportViewer\";\nimport AttachmentImageViewer from \"../attachment/AttachmentImageViewer\";\nimport { useNavigate } from \"react-router-dom\";\n\nexport type WorkflowDocumentPanelProps = {\n workFlowDocumentCode: string;\n refDocumentId: any;\n postActionCallBk?: () => void;\n cancelActionCallBk?: () => void;\n};\n\nexport type workflowDocumentAction = {\n id: number;\n document_action_code: string;\n document_action_ar_name: string;\n document_action_en_name: string;\n post_action_endpoint?: string;\n pre_action_endpoint?: string;\n next_document_status_id?: number;\n next_action_takers?: Array<person>;\n require_comment: any;\n};\n\nexport type person = {\n id: number;\n email: string;\n employeeArName: string;\n employeeEnName: string;\n mobileNumber: string;\n username: string;\n};\n\nexport type workflowDocumentActionHistory = {\n id: number;\n actionTime: string;\n actionMethod: string;\n actionComment: string;\n documentActionArName: string;\n documentActionEnName: string;\n employeeArName: string;\n employeeEnName: string;\n personId: number;\n};\n\ntype WorkflowDocumentInfo = {\n workflowDocument: any;\n referencedDocument: any;\n workflowDocumentReport: any;\n workflowDocumentStatus: any;\n actionsHistory: Array<workflowDocumentActionHistory>;\n nextActions: Array<workflowDocumentAction>;\n nextActionTakers: any;\n};\n\nconst WorkflowDocumentPanel: React.FC<WorkflowDocumentPanelProps> = (props) => {\n const navigate = useNavigate();\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const { isUserAuthorized, UserInfo } = useSession();\n const { handleGetRequest, handlePostRequest } = useAxios();\n const [action, setAction] = useState<workflowDocumentAction>(null);\n const [authorizedActions, setAuthorizedActions] = useState<\n Array<workflowDocumentAction>\n >([]);\n const { t } = useTranslation();\n const [actionComment, setActionComment] = useState(null);\n const [workflowDocumentInfo, setWorkflowDocumentInfo] =\n useState<WorkflowDocumentInfo>({\n referencedDocument: null,\n workflowDocumentReport: null,\n workflowDocument: null,\n workflowDocumentStatus: null,\n actionsHistory: [],\n nextActionTakers: null,\n nextActions: [],\n });\n const { Window: ReporTViewWindow, setWindowState: setReportViewWindowState } =\n useWindow({\n windowTitle:\n AppLayout.appDirection === \"ltr\"\n ? workflowDocumentInfo?.workflowDocument &&\n workflowDocumentInfo?.referencedDocument\n ? `${workflowDocumentInfo?.workflowDocument?.documentEnName} # ${\n workflowDocumentInfo?.referencedDocument[\n workflowDocumentInfo?.workflowDocument?.documentNumberField\n ]\n }`\n : \"Document\"\n : workflowDocumentInfo?.workflowDocument &&\n workflowDocumentInfo?.referencedDocument\n ? `${workflowDocumentInfo?.workflowDocument?.documentArName} # ${\n workflowDocumentInfo?.referencedDocument[\n workflowDocumentInfo?.workflowDocument?.documentNumberField\n ]\n }`\n : \"وثيقة\",\n windowIcon: \"eye\",\n width: \"80%\",\n });\n const loadWorkFlowDocumentInfo = async () => {\n await handleGetRequest({\n endPointURI: \"api/v1/public/workflow/doc/info\",\n showMask: true,\n parameters: {\n workflowDocumentCode: props.workFlowDocumentCode,\n refDocumentId: props.refDocumentId,\n },\n successCallBkFn: (response: any) => {\n setWorkflowDocumentInfo(response.data);\n },\n failureCallBkFn: () => {\n setWorkflowDocumentInfo({\n referencedDocument: null,\n workflowDocumentReport: null,\n workflowDocument: null,\n workflowDocumentStatus: null,\n actionsHistory: [],\n nextActions: [],\n nextActionTakers: null,\n });\n },\n });\n };\n\n const validateBeforeProcessWorkflowDocumentAction = async () => {\n if (\n action === undefined ||\n action === null ||\n action?.id === undefined ||\n action?.id === null\n ) {\n toast.error(\"You must select action to process\");\n return;\n }\n if (\n (action.require_comment === true ||\n action.require_comment === 1 ||\n action.require_comment === \"true\") &&\n (actionComment === null || actionComment === \"\")\n ) {\n toast.error(\"You must enter comment for the action to be processed\");\n return;\n }\n if (action?.pre_action_endpoint) {\n await handlePostRequest({\n endPointURI: action.pre_action_endpoint,\n showMask: true,\n loadingMessage: \"Processing pre action validation ... please wait\",\n parameters: {\n refDocumentId: props.refDocumentId,\n actionId: action.id,\n },\n successCallBkFn: () => {\n processWorkflowDocumentAction();\n },\n });\n return;\n }\n processWorkflowDocumentAction();\n };\n const processWorkflowDocumentAction = async () => {\n await handlePostRequest({\n endPointURI: \"api/v1/public/workflow/doc/action\",\n showMask: true,\n data: {\n workflowDocumentId: workflowDocumentInfo?.workflowDocument?.id,\n refDocumentId: props.refDocumentId,\n actionId: action.id,\n refDocumentStatus:\n workflowDocumentInfo?.workflowDocumentStatus?.documentStatusCode,\n actionComment: actionComment,\n },\n successCallBkFn: async (response) => {\n if (action?.post_action_endpoint) {\n await handlePostRequest({\n endPointURI: action.post_action_endpoint,\n showMask: true,\n loadingMessage: \"Processing post action process ... please wait\",\n parameters: {\n refDocumentId: props.refDocumentId,\n actionId: action.id,\n },\n successCallBkFn: () => {\n loadWorkFlowDocumentInfo();\n if (props?.postActionCallBk) {\n props.postActionCallBk();\n }\n },\n });\n return;\n }\n loadWorkFlowDocumentInfo();\n },\n });\n };\n\n const adjustAuthorizedActions = () => {\n if (workflowDocumentInfo?.nextActions?.length > 0) {\n setAuthorizedActions(\n workflowDocumentInfo.nextActions.filter((action) => {\n if (\n !(\n workflowDocumentInfo?.workflowDocumentStatus\n ?.nextActionTakersAuthority ||\n workflowDocumentInfo?.nextActionTakers\n )\n ) {\n return true;\n }\n if (\n workflowDocumentInfo?.workflowDocumentStatus\n ?.nextActionTakersAuthority\n ) {\n if (\n isUserAuthorized(\n workflowDocumentInfo.workflowDocumentStatus\n .nextActionTakersAuthority\n )\n ) {\n return true;\n }\n }\n if (workflowDocumentInfo?.nextActionTakers) {\n for (const actionTaker of workflowDocumentInfo.nextActionTakers) {\n if (\n UserInfo?.username === actionTaker?.username ||\n UserInfo?.username === actionTaker?.USERNAME\n ) {\n return true;\n }\n }\n }\n return false;\n })\n );\n } else {\n setAuthorizedActions([]);\n }\n };\n\n useEffect(() => {\n if (props.refDocumentId && props.workFlowDocumentCode) {\n loadWorkFlowDocumentInfo();\n }\n }, [props.refDocumentId, props.workFlowDocumentCode]);\n\n useEffect(() => {\n if (workflowDocumentInfo?.nextActions) {\n adjustAuthorizedActions();\n } else {\n setAuthorizedActions([]);\n }\n }, [workflowDocumentInfo.nextActions, workflowDocumentInfo.nextActionTakers]);\n return (\n <>\n {workflowDocumentInfo?.workflowDocumentReport?.id ? (\n <ReporTViewWindow>\n <ReportViewer\n reportCode={\n workflowDocumentInfo?.workflowDocumentReport?.reportCode\n }\n resultMode=\"App\"\n byPassParameterEntry={true}\n reportParametersValues={{ doc_id: props.refDocumentId + \"\" }}\n />\n </ReporTViewWindow>\n ) : (\n <></>\n )}\n\n {workflowDocumentInfo?.workflowDocument ? (\n <Box\n sx={{\n width: \"100%\",\n textAlign: \"center\",\n fontSize: 20,\n fontWeight: \"bold\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <IconButton\n onClick={() => {\n navigate(-1, { replace: true });\n }}\n >\n <FontAwesomeIcon icon=\"arrow-left\" />\n </IconButton>\n <Box sx={{ flex: 1 }}></Box>\n <FontAwesomeIcon\n icon=\"file\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n {AppLayout.appDirection === \"ltr\"\n ? `${workflowDocumentInfo?.workflowDocument?.documentEnName} # ${\n workflowDocumentInfo?.referencedDocument[\n workflowDocumentInfo?.workflowDocument?.documentNumberField\n ]\n }`\n : `${workflowDocumentInfo?.workflowDocument?.documentArName} # ${\n workflowDocumentInfo?.referencedDocument[\n workflowDocumentInfo?.workflowDocument?.documentNumberField\n ]\n }`}\n {workflowDocumentInfo?.workflowDocumentStatus\n ? AppLayout.appDirection === \"ltr\"\n ? ` ( ${workflowDocumentInfo?.workflowDocumentStatus?.documentStatusEnName} )`\n : ` ( ${workflowDocumentInfo?.workflowDocumentStatus?.documentStatusArName} )`\n : \"\"}\n <Box sx={{ flex: 1 }}></Box>\n {workflowDocumentInfo?.workflowDocumentReport?.id ? (\n <Button\n onClick={() => {\n setReportViewWindowState(true);\n }}\n variant=\"outlined\"\n startIcon={<FontAwesomeIcon icon=\"eye\" />}\n >\n {t(\"VIEW_LABEL\")}\n </Button>\n ) : (\n <></>\n )}\n </Box>\n ) : (\n <></>\n )}\n\n <Box\n sx={{\n flex: 1,\n width: \"100%\",\n overflow: \"hidden\",\n display: \"flex\",\n // flexDirection: \"column\",\n }}\n >\n {authorizedActions?.length > 0 ? (\n <Paper\n sx={{\n padding: 2,\n display: \"flex\",\n flex: 1,\n margin: 1,\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n overflow: \"hidden\",\n }}\n >\n <ComboBox\n sx={{ marginBottom: 2, width: 400 }}\n label={t(\"WE_AVAILABLE_ACTIONS_LABEL\")}\n displayField={\n AppLayout.appDirection === \"ltr\"\n ? \"document_action_en_name\"\n : \"document_action_ar_name\"\n }\n valueField={\"id\"}\n value={action?.id}\n options={authorizedActions}\n onChangeCallBack={(v, selectedRecord) => {\n setAction(selectedRecord);\n }}\n />\n {/* <ComboBox\n sx={{ marginBottom: 2, width: 400 }}\n label={t(\"WE_NEXT_APPROVER_LABEL\")}\n displayField={\n AppLayout.appDirection === \"ltr\"\n ? \"employeeEnName\"\n : \"employeeArName\"\n }\n valueField={\"id\"}\n value={nextActionTaker?.id}\n options={action?.nextActionTakers || []}\n onChangeCallBack={(v, selectedRecord) => {\n setNextActionTaker(selectedRecord);\n }}\n /> */}\n <TemplateTextField\n sx={{ width: 400 }}\n rows={3}\n value={actionComment}\n onChange={(event) => {\n setActionComment(event.target.value);\n }}\n multiline={true}\n label={t(\"WF_COMMENT_LABEL\")}\n />\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <Button\n color=\"success\"\n variant=\"contained\"\n sx={{ width: 200, m: 1 }}\n onClick={validateBeforeProcessWorkflowDocumentAction}\n >\n {t(\"WF_TAKE_ACTION_BTN_LABEL\")}\n </Button>\n {props?.cancelActionCallBk ? (\n <Button\n variant=\"contained\"\n sx={{ width: 200, m: 1 }}\n color=\"error\"\n onClick={() => {\n if (props?.cancelActionCallBk) {\n props.cancelActionCallBk();\n }\n }}\n >\n {t(\"WF_CANCEL_BTN_LABEL\")}\n </Button>\n ) : (\n <></>\n )}\n </Box>\n {workflowDocumentInfo?.nextActionTakers &&\n workflowDocumentInfo.nextActionTakers.length > 0 ? (\n <>\n <Divider\n variant=\"fullWidth\"\n flexItem\n sx={{ marginTop: 1, marginBottom: 1 }}\n >\n <Box\n sx={{\n width: \"100%\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontSize: 18,\n fontWeight: \"bold\",\n }}\n >\n <FontAwesomeIcon\n icon=\"users\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />{\" \"}\n {t(\"WF_WAITING_FOR_LABEL\")}\n </Box>\n </Divider>\n\n <Box\n sx={{\n flex: 1,\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n overflow: \"auto\",\n padding: 1,\n width: \"100%\",\n }}\n >\n {workflowDocumentInfo.nextActionTakers.map(\n (nextActionTaker: any) => {\n return (\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n border: \"1px dotted black\",\n width: 400,\n marginBottom: 2,\n padding: 2,\n }}\n >\n <AttachmentImageViewer\n showAsAvatar={true}\n attachmentCode=\"EMPLOYEE_PHOTOS\"\n refKey={nextActionTaker?.id || \"0\"}\n style={{\n marginRight: 2,\n marginLeft: 2,\n width: 60,\n height: 60,\n }}\n />\n <Box\n sx={{\n flex: 2,\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"flex-start\",\n justifyContent: \"center\",\n }}\n >\n <div>\n {AppLayout.appDirection === \"ltr\"\n ? nextActionTaker?.employee_en_name\n : nextActionTaker?.employee_ar_name}\n </div>\n <div>\n {nextActionTaker?.email ? (\n <>\n <FontAwesomeIcon\n icon=\"envelope\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n {nextActionTaker?.email}\n </>\n ) : (\n <></>\n )}\n </div>\n <div>\n {nextActionTaker?.mobile_number ? (\n <>\n <FontAwesomeIcon\n icon=\"mobile\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n {nextActionTaker?.mobile_number}\n </>\n ) : (\n <></>\n )}\n </div>\n </Box>\n </Box>\n );\n }\n )}\n </Box>\n </>\n ) : (\n <></>\n )}\n </Paper>\n ) : (\n <></>\n )}\n {workflowDocumentInfo?.actionsHistory.length > 0 ? (\n <WorkflowDocumentTimeLine\n actionHistory={workflowDocumentInfo.actionsHistory}\n />\n ) : (\n <Paper\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n flexGrow: 1,\n padding: 2,\n margin: 1,\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <Box\n sx={{\n width: \"100%\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontSize: 18,\n fontWeight: \"bold\",\n }}\n >\n <FontAwesomeIcon\n icon=\"history\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n {t(\"WF_ACTION_HISTORY_LABEL\")}\n </Box>\n <Box\n sx={{\n flex: 1,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n No Action Log available\n </Box>\n </Paper>\n )}\n </Box>\n </>\n );\n};\n\nexport default WorkflowDocumentPanel;\n","import { Box } from \"@mui/system\";\nimport React, { useEffect, useState } from \"react\";\nimport * as z from \"zod\";\nimport { useForm } from \"react-hook-form\";\nimport { zodResolver } from \"@hookform/resolvers/zod\";\nimport { useParams } from \"react-router-dom\";\nimport { Button, Grid2, Icon, IconButton, Tooltip } from \"@mui/material\";\nimport { toast } from \"react-toastify\";\nimport FormElementGroup from \"./FormElementGroup\";\nimport FormElementField from \"./FormElementField\";\nimport FormAction from \"./FormAction\";\nimport { constructValidationSchema, getAllFields } from \"../DataEntryUtil\";\nimport {\n FormElementProps,\n RecordAction,\n TemplateFormProps,\n} from \"../DataEntryTypes\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { useTranslation } from \"react-i18next\";\nimport { useWindow } from \"../../../../hooks\";\nimport AttachmentPanel from \"../../attachment/AttachmentPanel\";\nimport WorkflowDocumentPanel from \"../../workflow/WorkflowDocumentPanel\";\n\nconst TemplateForm: React.FC<TemplateFormProps> = (\n props: TemplateFormProps\n) => {\n const { Window: AttachmentWindow, setWindowState: setAttachmentWindowState } =\n useWindow({\n windowTitle: \"Attachments\",\n windowIcon: \"paperclip\",\n width: \"fit-content\",\n height: \"fit-content\",\n minHeight: 500,\n minWidth: 400,\n });\n const { Window: WorkflowWindow, setWindowState: setWorkflowWindowState } =\n useWindow({\n windowTitle: \"Approvals\",\n windowIcon: \"stamp\",\n width: \"fit-content\",\n height: \"fit-content\",\n minHeight: 500,\n minWidth: 400,\n });\n const [attachmentPanelEnabledForRecord, setAttachmentPanelEnabledForRecord] =\n useState<boolean>(true);\n const { t } = useTranslation();\n const fields = getAllFields(props.elements);\n const initiallyHiddenFields = [];\n for (const field of fields) {\n if (field?.hidden) {\n initiallyHiddenFields.push(field.fieldName);\n }\n }\n const [hiddenFields, setHiddenFields] = useState<string[]>(\n initiallyHiddenFields\n );\n const initialValues: any = {};\n for (const element of props.elements) {\n if (\n element?.type === \"field\" &&\n element?.mode === \"props\" &&\n element?.props?.defaultValue\n ) {\n initialValues[element.props.fieldName] = element.props.defaultValue;\n }\n }\n const [disabledFields, setDisabledFields] = useState<string[]>([]);\n let formSchema = null;\n if (props?.validationSchema) {\n formSchema = props.validationSchema;\n } else {\n formSchema = z.object(constructValidationSchema(fields));\n }\n type FormData = z.infer<typeof formSchema>;\n const formManager = useForm<FormData>({\n resolver: zodResolver(formSchema),\n defaultValues: initialValues,\n });\n const formValues = formManager.watch();\n const pathParameters = useParams();\n const formRouteRecordIdParamName: any = props?.formRouteRecordIdParamName;\n\n const loadRecord = async () => {\n let idToLoad = null;\n if (props?.recordIdToEdit) {\n idToLoad = props.recordIdToEdit;\n } else if (\n formRouteRecordIdParamName &&\n pathParameters[formRouteRecordIdParamName]\n ) {\n idToLoad = pathParameters[formRouteRecordIdParamName];\n }\n if (idToLoad) {\n const retrievedRecord: any = await props.apiActions.loadRecordById(\n idToLoad\n );\n if (retrievedRecord) {\n formManager.reset({ ...retrievedRecord });\n if (props?.formValuesChangeCallBk) {\n props?.formValuesChangeCallBk(\n { ...retrievedRecord },\n formActions,\n formManager\n );\n }\n for (const field of fields) {\n if (\n field?.fieldType === \"combobox\" &&\n retrievedRecord[field.fieldName]\n ) {\n if (\n field?.comboboxValueDataType &&\n field?.comboboxValueDataType === \"string\"\n ) {\n formManager.setValue(\n field.fieldName,\n retrievedRecord[field.fieldName] + \"\"\n );\n } else {\n formManager.setValue(\n field.fieldName,\n retrievedRecord[field.fieldName]\n );\n }\n }\n }\n }\n } else {\n formManager.reset({});\n }\n };\n\n const saveRecord = async (record: any) => {\n if (props?.preSaveValidation && !props.preSaveValidation(record)) {\n return;\n }\n if (record) {\n const savedRecord: any = await props.apiActions.saveRecord(record);\n if (savedRecord) {\n formManager.reset({ ...savedRecord });\n if (props?.formSavedSuccessfullyCallBk) {\n props.formSavedSuccessfullyCallBk(savedRecord);\n }\n if (props?.formCloseCallBk) {\n props.formCloseCallBk();\n }\n }\n }\n };\n\n const formActions = {\n setFieldValue: (fieldName: string, fieldValue: any) => {\n formManager.setValue(fieldName, fieldValue);\n },\n hideField: (fieldName: string) => {\n setHiddenFields((oldValues) => {\n const newValues = [...oldValues, fieldName];\n return newValues;\n });\n },\n showField: (fieldName: string) => {\n setHiddenFields((oldValues) => {\n const newValues = oldValues.filter((x) => x !== fieldName);\n return newValues;\n });\n },\n disableField: (fieldName: string) => {\n setDisabledFields((oldValues) => {\n const newValues = [...oldValues, fieldName];\n return newValues;\n });\n },\n enableField: (fieldName: string) => {\n setDisabledFields((oldValues) => {\n const newValues = oldValues.filter((x) => x !== fieldName);\n return newValues;\n });\n },\n };\n\n useEffect(() => {\n loadRecord();\n }, [props?.recordIdToEdit]);\n\n useEffect(() => {\n if (props?.attachment && props?.attachment?.enableAttachFn) {\n setAttachmentPanelEnabledForRecord(\n props.attachment.enableAttachFn(formValues)\n );\n } else {\n setAttachmentPanelEnabledForRecord(true);\n }\n }, [formValues]);\n return (\n <>\n {props?.attachment ? (\n <AttachmentWindow>\n <AttachmentPanel\n attachmentCode={props.attachment.attachmentCode}\n refKey={formValues[props?.keyColumnName || \"id\"]}\n enableAttachment={attachmentPanelEnabledForRecord}\n />\n </AttachmentWindow>\n ) : (\n <></>\n )}\n {props?.workFlowDocumentCode ? (\n <WorkflowWindow>\n <WorkflowDocumentPanel\n workFlowDocumentCode={props.workFlowDocumentCode}\n refDocumentId={formValues[props?.keyColumnName || \"id\"]}\n postActionCallBk={() => {\n setWorkflowWindowState(false);\n loadRecord();\n }}\n cancelActionCallBk={() => {\n setWorkflowWindowState(false);\n }}\n />\n </WorkflowWindow>\n ) : (\n <></>\n )}\n\n <Box\n sx={{\n display: \"flex\",\n flex: 1,\n width: \"100%\",\n height: \"fit-content\",\n flexDirection: \"column\",\n alignItems: \"center\",\n overflow: \"auto\",\n }}\n >\n <Grid2 sx={{ width: \"100%\" }} container>\n {props.elements.map((formElement: FormElementProps, index) => {\n if (formElement.type === \"group\") {\n return (\n <FormElementGroup\n key={index}\n {...formElement.props}\n formManager={formManager}\n formValues={formValues}\n formActions={formActions}\n hiddenFields={hiddenFields}\n disabledFields={disabledFields}\n />\n );\n } else if (\n formElement.type === \"field\" &&\n formElement.mode === \"props\"\n ) {\n return (\n <FormElementField\n key={index}\n fieldInfo={formElement.props}\n formManager={formManager}\n formValues={formValues}\n formActions={formActions}\n hiddenFields={hiddenFields}\n disabledFields={disabledFields}\n formValuesChangeCallBk={props.formValuesChangeCallBk}\n />\n );\n } else if (\n formElement.type === \"field\" &&\n formElement.mode === \"node\"\n ) {\n return (\n <Grid2\n key={index}\n size={\n formElement?.props?.formProps?.fieldSize || {\n lg: 3,\n md: 6,\n xs: 12,\n }\n }\n sx={{ padding: 1, width: \"100%\" }}\n >\n <formElement.node\n formManager={formManager}\n formValues={formValues}\n />\n </Grid2>\n );\n }\n })}\n </Grid2>\n </Box>\n\n <Box\n sx={{\n display: \"flex\",\n width: \"100%\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n }}\n >\n {formValues[props?.keyColumnName || \"id\"] ? (\n props?.attachment ? (\n <Tooltip title=\"Attachments\">\n <IconButton\n onClick={() => {\n setAttachmentWindowState(true);\n }}\n >\n <FontAwesomeIcon icon=\"paperclip\" />\n </IconButton>\n </Tooltip>\n ) : null\n ) : null}\n {formValues[props?.keyColumnName || \"id\"] ? (\n props?.workFlowDocumentCode ? (\n <Tooltip title=\"Approvals\">\n <IconButton\n onClick={() => {\n setWorkflowWindowState(true);\n }}\n >\n <FontAwesomeIcon icon=\"stamp\" />\n </IconButton>\n </Tooltip>\n ) : null\n ) : null}\n {props?.actions ? (\n props.actions.map((action: RecordAction) => {\n if (action?.isIdRequired === false) {\n return <FormAction {...action} record={formValues} />;\n } else if (formValues[props?.keyColumnName || \"id\"]) {\n if (action?.formActionProps?.enabled === true) {\n return <FormAction {...action} record={formValues} />;\n } else {\n return <></>;\n }\n }\n })\n ) : (\n <></>\n )}\n <div style={{ flex: 1 }}></div>\n {props?.saveButtonSpecs?.hidden ? (\n <></>\n ) : (\n <Button\n variant={\n props?.saveButtonSpecs?.actionButtonVariant\n ? props.saveButtonSpecs.actionButtonVariant\n : \"contained\"\n }\n sx={{ m: 1 }}\n startIcon={\n props?.saveButtonSpecs?.icon ? (\n <FontAwesomeIcon icon={props.saveButtonSpecs.icon} />\n ) : null\n }\n color={\n props?.saveButtonSpecs?.actionButtonColor\n ? props.saveButtonSpecs.actionButtonColor\n : \"primary\"\n }\n onClick={formManager.handleSubmit(\n (values) => {\n saveRecord(values);\n },\n (errors) => {\n toast.error(\n \"Form Data is not valid, make sure you have all field with valid data\"\n );\n console.log(\"form validation error\", errors);\n }\n )}\n >\n {t(props?.saveButtonSpecs?.label || \"SAVE_BTN_LABEL\")}\n </Button>\n )}\n\n {props?.cancelButtonSpecs?.hidden ? (\n <></>\n ) : (\n <Button\n variant={\n props?.cancelButtonSpecs?.actionButtonVariant\n ? props.cancelButtonSpecs.actionButtonVariant\n : \"contained\"\n }\n startIcon={\n props?.cancelButtonSpecs?.icon ? (\n <FontAwesomeIcon icon={props.cancelButtonSpecs.icon} />\n ) : null\n }\n color={\n props?.cancelButtonSpecs?.actionButtonColor\n ? props.cancelButtonSpecs.actionButtonColor\n : \"error\"\n }\n sx={{ m: 1 }}\n onClick={() => {\n if (props?.formCloseCallBk) {\n props.formCloseCallBk();\n }\n formManager.reset(initialValues);\n }}\n >\n {t(props?.cancelButtonSpecs?.label || \"CANCEL_BTN_LABEL\")}\n </Button>\n )}\n </Box>\n </>\n );\n};\n\nexport default TemplateForm;\n","import { useParams } from \"react-router-dom\";\nimport WorkflowDocumentPanel from \"./WorkflowDocumentPanel\";\n\nconst WorkflowRouteComponent: React.FC = () => {\n const { workflowDocumentCode, refDocumentId } = useParams();\n return (\n <WorkflowDocumentPanel\n workFlowDocumentCode={workflowDocumentCode}\n refDocumentId={refDocumentId}\n />\n );\n};\n\nexport default WorkflowRouteComponent;\n","import { BarChart } from \"@mui/x-charts\";\nimport { WidgetProps } from \"../DashboardViewer\";\n\n\nconst TemplateBarChart: React.FC<WidgetProps> = (props) => {\n return (\n <BarChart\n dataset={props.data}\n xAxis={[\n {\n dataKey: props.valueField,\n scaleType: \"band\",\n label: props.valueLabel,\n },\n ]}\n series={props.labelField?.split(\",\").map((labelField) => {\n return { dataKey: labelField, label: labelField };\n })}\n />\n );\n};\n\nexport default TemplateBarChart;\n","import { Box, Paper, Typography } from \"@mui/material\";\nimport { SingleRecordWidgetProps } from \"../DashboardViewer\";\n\n\nconst TemplateDataCard: React.FC<SingleRecordWidgetProps> = (props: any) => {\n return (\n <Paper\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n height: 150,\n padding: 1,\n flexGrow: 1,\n justifyContent: \"center\",\n alignItems: \"center\",\n }}\n >\n <Box\n sx={{\n display: \"flex\",\n width: \"100%\",\n justifyContent: \"space-evenly\",\n alignItems: \"center\",\n }}\n >\n <div>{props.record[props.valueField]}</div>\n </Box>\n <Typography sx={{ fontSize: 16, fontWeight: \"bold\" }}>\n {props.record[props.labelField]}\n </Typography>\n </Paper>\n );\n};\n\nexport default TemplateDataCard;\n","import { Gauge } from \"@mui/x-charts\";\nimport { SingleRecordWidgetProps } from \"../DashboardViewer\";\nimport { Typography } from \"@mui/material\";\n\nconst TemplateGauge: React.FC<SingleRecordWidgetProps> = (props: any) => {\n return (\n <>\n <Typography sx={{ fontSize: 16, fontWeight: \"bold\" }}>\n {props.record[props.labelField]}\n </Typography>\n <Gauge\n width={200}\n height={200}\n value={props.record[props.valueField]}\n valueMax={props.total}\n />\n </>\n );\n};\n\nexport default TemplateGauge;\n","import { LineChart } from \"@mui/x-charts\";\nimport { WidgetProps } from \"../DashboardViewer\";\n\nconst TemplateLineChart: React.FC<WidgetProps> = (props) => {\n return (\n <LineChart\n dataset={props.data}\n xAxis={[\n {\n dataKey: props.valueField,\n scaleType: \"band\",\n label: props.valueLabel,\n },\n ]}\n series={props.labelField?.split(\",\").map((labelField) => {\n return { dataKey: labelField, label: labelField };\n })}\n />\n );\n};\n\nexport default TemplateLineChart;\n","import * as React from \"react\";\nimport LinearProgress, {\n LinearProgressProps,\n} from \"@mui/material/LinearProgress\";\nimport Typography from \"@mui/material/Typography\";\nimport Box from \"@mui/material/Box\";\nimport { SingleRecordWidgetProps } from \"../DashboardViewer\";\n\nfunction LinearProgressWithLabel(\n props: LinearProgressProps & { value: number }\n) {\n return (\n <Box sx={{ display: \"flex\", alignItems: \"center\" }}>\n <Box sx={{ width: \"100%\", mr: 1 }}>\n <LinearProgress variant=\"determinate\" {...props} />\n </Box>\n <Box sx={{ minWidth: 35 }}>\n <Typography\n variant=\"body2\"\n sx={{ color: \"text.secondary\" }}\n >{`${Math.round(props.value)}%`}</Typography>\n </Box>\n </Box>\n );\n}\n\nconst TemplateLineProgress: React.FC<SingleRecordWidgetProps> = (\n props: any\n) => {\n return (\n <Box sx={{ width: \"100%\" }}>\n <Typography sx={{ fontSize: 16, fontWeight: \"bold\" }}>\n {props.record[props.labelField]}\n </Typography>\n <LinearProgressWithLabel\n value={100 * (props.record[props.valueField] / props.total)}\n />\n </Box>\n );\n};\n\nexport default TemplateLineProgress;\n","import { PieChart } from \"@mui/x-charts/PieChart\";\nimport { WidgetProps } from \"../DashboardViewer\";\n\nconst TemplatePieChart: React.FC<WidgetProps> = (props) => {\n // construct data object\n const chartData = props.data.map((record: any, index: any) => {\n return {\n id: index,\n value: record[props.valueField],\n label: record[props.labelField] + \"\",\n };\n });\n return (\n <PieChart\n series={[\n {\n data: chartData,\n },\n ]}\n />\n );\n};\n\nexport default TemplatePieChart;\n","import { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { WidgetType } from \"../../administration/dev/WidgetGrid\";\nimport { Backdrop, Box, CircularProgress, Grid2 } from \"@mui/material\";\nimport { useEffect, useState } from \"react\";\nimport LoadingMask from \"../../common/LoadingMask\";\nimport { useTranslation } from \"react-i18next\";\nimport { useSelector } from \"react-redux\";\nimport { useAxios } from \"../../../hooks\";\nimport TemplateLineChart from \"./charts/TemplateLineChart\";\nimport TemplateBarChart from \"./charts/TemplateBarChart\";\nimport TemplatePieChart from \"./charts/TemplatePieChart\";\nimport TemplateDataCard from \"./charts/TemplateDataCard\";\nimport TemplateGauge from \"./charts/TemplateGauge\";\nimport TemplateLineProgress from \"./charts/TemplateLineProgress\";\n\nexport type Widget = {\n loadWidget: boolean;\n loadCounter: number;\n widgetName: string;\n widgetDescription: string;\n title: string;\n icon: any;\n dataQueryId: number;\n widgetType: WidgetType;\n width: any;\n height: any;\n horizontalAxisField: any;\n horizontalAxisLabel: any;\n verticalAxisField: string;\n verticalAxisLabel: string;\n seriesKeys: any;\n parameterValues: {\n [key: string]: any;\n };\n};\n\nconst WidgetViewer: React.FC<Widget> = (props) => {\n const [isWidgetLoading, setWidgetLoading] = useState(true);\n const [data, setData] = useState([]);\n const { handleGetRequest } = useAxios();\n const getWidgetData = async () => {\n setWidgetLoading(true);\n await handleGetRequest({\n endPointURI: \"api/v1/dev/query/result\",\n showMask: false,\n parameters: {\n queryId: props.dataQueryId,\n ...props.parameterValues,\n },\n successCallBkFn: (response) => {\n setWidgetLoading(false);\n setData(response.data);\n },\n failureCallBkFn: () => {\n setWidgetLoading(false);\n setData([]);\n },\n });\n };\n useEffect(() => {\n if (props.loadWidget) {\n getWidgetData();\n } else {\n setWidgetLoading(false);\n }\n }, [props.loadWidget, props.loadCounter]);\n\n let total = 0;\n if (data.length == 1) {\n total = 100;\n } else {\n if (\n props.widgetType === \"CircularProgress\" ||\n props.widgetType === \"LinearProgress\"\n ) {\n for (const record of data) {\n total += record[props.verticalAxisField];\n }\n }\n }\n\n return (\n <>\n {props.widgetType === \"LineChart\" ||\n props.widgetType === \"PieChart\" ||\n props.widgetType === \"ColumnChart\" ? (\n <Box>\n <FontAwesomeIcon\n style={{ marginRight: 10, marginLeft: 10 }}\n icon={props?.icon || \"chart-pie\"}\n />\n {props?.title}\n </Box>\n ) : (\n <></>\n )}\n\n <Box\n sx={{\n flex: 1,\n padding: 1,\n height: \"90%\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n width: \"90%\",\n }}\n >\n {isWidgetLoading ? (\n <>\n <FontAwesomeIcon\n icon={{ prefix: \"fas\", iconName: \"arrows-spin\" }}\n style={{ marginRight: 10, marginLeft: 10 }}\n spin\n size=\"2x\"\n />\n <div>Loading</div>\n </>\n ) : props.widgetType === \"ColumnChart\" ? (\n <TemplateBarChart\n data={data}\n widgetTitle={props.title}\n labelField={props.verticalAxisField}\n valueField={props.horizontalAxisField}\n valueLabel={props.horizontalAxisLabel}\n widgetType=\"Line\"\n />\n ) : props.widgetType === \"LineChart\" ? (\n <TemplateLineChart\n data={data}\n widgetTitle={props.title}\n labelField={props.verticalAxisField}\n valueField={props.horizontalAxisField}\n valueLabel={props.horizontalAxisLabel}\n widgetType=\"Line\"\n />\n ) : props.widgetType === \"PieChart\" ? (\n <TemplatePieChart\n data={data}\n widgetTitle={props.title}\n labelField={props.horizontalAxisField}\n valueField={props.verticalAxisField}\n widgetType=\"Pie\"\n />\n ) : (\n <Grid2\n container\n sx={{\n width: \"100%\",\n alignItems: \"flex-start\",\n justifyContent: \"flex-start\",\n }}\n spacing={2}\n size={{ xs: 12 }}\n >\n <Grid2 size={{ xs: 12 }} sx={{ textAlign: \"center\" }}>\n {props.title}\n </Grid2>\n\n {data.map((record, index) => {\n if (props.widgetType === \"Card\") {\n return (\n <Grid2 size={{ md: 3, xs: 12 }}>\n <TemplateDataCard\n key={index}\n widgetTitle={\"\"}\n record={record}\n labelField={props.horizontalAxisField}\n valueField={props.verticalAxisField}\n />\n </Grid2>\n );\n } else if (props.widgetType === \"CircularProgress\") {\n return (\n <Grid2 size={{ md: 3, xs: 12 }}>\n <TemplateGauge\n key={index}\n widgetTitle={\"\"}\n record={record}\n labelField={props.horizontalAxisField}\n valueField={props.verticalAxisField}\n total={total}\n />\n </Grid2>\n );\n } else if (props.widgetType === \"LinearProgress\") {\n return (\n <Grid2 size={{ md: 3, xs: 12 }}>\n <TemplateLineProgress\n key={index}\n widgetTitle={\"\"}\n record={record}\n labelField={props.horizontalAxisField}\n valueField={props.verticalAxisField}\n total={total}\n />\n </Grid2>\n );\n }\n })}\n </Grid2>\n )}\n </Box>\n </>\n );\n};\n\nexport default WidgetViewer;\n","import { Box, Grid2, IconButton } from \"@mui/material\";\nimport { useEffect, useState } from \"react\";\nimport { useAxios } from \"../../../hooks\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport WidgetViewer, { Widget } from \"./WidgetViewer\";\nimport { useNavigate } from \"react-router-dom\";\nimport { useParameterPanel } from \"../../../hooks/useParameterPanel\";\n\ntype DashboardViewerProps = {\n dashboardCode: string;\n parameters?: { [key: string]: any };\n};\n\nexport interface WidgetProps {\n widgetTitle?: string;\n widgetType: \"Line\" | \"Bar\" | \"Pie\" | \"Card\" | \"Gauge\" | \"Progress\";\n data: any;\n valueLabel?: string;\n valueField: string; //x-axis field in case of line/bar chart\n labelField: string; //y-axis field in case of line/bar chart, it can also be a comma separated string for multiple series\n}\n\nexport interface SingleRecordWidgetProps {\n widgetTitle?: string;\n record: object;\n valueField: string;\n labelField: string;\n total?: number;\n}\n\ntype DashboardInfo = {\n dashboardCode: string;\n dashboardName: string;\n dashboardTitle: string;\n widgets: Array<Widget>;\n dashboardParameters: Array<any>;\n};\n\nconst DashboardViewer: React.FC<DashboardViewerProps> = (props) => {\n const [dashboardInfo, setDashboardInfo] = useState<DashboardInfo>({\n dashboardCode: \"\",\n dashboardName: \"\",\n dashboardTitle: \"\",\n dashboardParameters: [],\n widgets: [],\n });\n const { ParameterPanel, parametersValues } = useParameterPanel({\n parameters: dashboardInfo?.dashboardParameters || [],\n initialParameterValues: {},\n });\n const [loadCounter, setLoadCounter] = useState(0);\n const [loadDashboard, setLoadDashboard] = useState<boolean>(false);\n useEffect(() => {\n if (\n dashboardInfo.dashboardCode != undefined &&\n dashboardInfo.dashboardCode != null &&\n dashboardInfo.dashboardCode != \"\"\n ) {\n setLoadDashboard(false);\n let shouldLoadWidgets = true;\n if (dashboardInfo?.dashboardParameters.length > 0) {\n for (const parameter of dashboardInfo?.dashboardParameters) {\n if (parameter?.mandatory === true) {\n if (\n parametersValues[parameter.parameterCode] === undefined ||\n parametersValues[parameter.parameterCode] === null ||\n parametersValues[parameter.parameterCode] === \"\"\n ) {\n shouldLoadWidgets = false;\n break;\n }\n }\n }\n }\n if (shouldLoadWidgets) {\n setLoadDashboard(shouldLoadWidgets);\n }\n setLoadCounter(loadCounter + 1);\n }\n }, [dashboardInfo?.dashboardParameters, parametersValues]);\n const navigate = useNavigate();\n const { handleGetRequest, handlePostRequest } = useAxios();\n const loadDashboardInfo = async () => {\n await handleGetRequest({\n endPointURI: \"api/v1/dev/dashboard/metadata\",\n showMask: true,\n parameters: {\n dashboardCode: props.dashboardCode,\n },\n successCallBkFn: (response) => {\n setDashboardInfo(response.data);\n },\n failureCallBkFn: () => {\n setDashboardInfo(null);\n },\n });\n };\n useEffect(() => {\n if (props.dashboardCode) {\n loadDashboardInfo();\n }\n }, [props.dashboardCode, props.parameters]);\n return (\n <>\n {dashboardInfo ? (\n <>\n <Box\n sx={{\n fontSize: 20,\n fontWeight: \"bold\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <IconButton\n onClick={() => {\n navigate(-1, { replace: true });\n }}\n >\n <FontAwesomeIcon icon=\"arrow-left\" />\n </IconButton>\n <Box sx={{ flex: 1 }}></Box>\n <FontAwesomeIcon\n style={{ marginLeft: 10, marginRight: 10 }}\n icon={\"square-poll-vertical\"}\n />\n <Box>{dashboardInfo?.dashboardTitle}</Box>\n <Box sx={{ flex: 1 }}></Box>\n </Box>\n {dashboardInfo?.dashboardParameters.length > 0 ? (\n <ParameterPanel searchBtnClickCallBk={async (params) => {\n setLoadCounter(loadCounter + 1);\n }} />\n ) : (\n <></>\n )}\n <Grid2\n container\n spacing={1}\n sx={{\n // flexGrow: 1,\n height: \"fit-content\",\n overflowY: \"auto\",\n padding: 1,\n }}\n >\n {dashboardInfo?.widgets.map((widget, index) => {\n return (\n <Grid2\n key={index}\n sx={{\n alignItems: \"center\",\n justifyContent: \"center\",\n padding: 1,\n display: \"flex\",\n overflow: \"auto\",\n flexDirection:\n widget.widgetType != \"Card\" ? \"column\" : undefined,\n height: widget?.height || 300,\n }}\n size={{ md: widget?.width, sm: 12 }}\n >\n <WidgetViewer\n {...widget}\n parameterValues={parametersValues}\n loadWidget={loadDashboard}\n />\n </Grid2>\n );\n })}\n </Grid2>\n </>\n ) : (\n <Box\n sx={{\n flex: 1,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontSize: 24,\n fontWeight: \"bold\",\n }}\n >\n No Dashboard Found\n </Box>\n )}\n </>\n );\n};\n\nexport default DashboardViewer;\n","import { useParams } from \"react-router-dom\";\nimport DashboardViewer from \"./DashboardViewer\";\n\nconst DashboardRouteView: React.FC = () => {\n const { dashboardCode } = useParams();\n return <DashboardViewer dashboardCode={dashboardCode} />;\n};\n\nexport default DashboardRouteView;\n","import { useState } from \"react\";\nimport { useAxios, useSession } from \"../../hooks\";\nimport { ComboBox } from \"../templates\";\nimport { Box, Button } from \"@mui/material\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { UserSessionActions } from \"../../redux/features/common/UserSessionSlice\";\n\ntype ChangeOrgFormProps = {\n successChangeCallBackFn: () => void;\n};\n\nconst ChangeOrgForm: React.FC<ChangeOrgFormProps> = (props) => {\n const { UserSession } = useSession();\n const AppLayoutState = useSelector((state: any) => state.AppLayout);\n const dispatch = useDispatch();\n const { handlePostRequest } = useAxios();\n const [newOrgId, setNewOrgId] = useState(\n UserSession.value.currentOrganization.id\n );\n return (\n <Box\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n width: \"100%\",\n alignItems: \"center\",\n justifyContent: \"center\",\n padding: 1,\n }}\n >\n <ComboBox\n sx={{ width: \"100%\" }}\n displayField={\n AppLayoutState.appDirection === \"ltr\"\n ? \"organizationEnName\"\n : \"organizationArName\"\n }\n valueField=\"id\"\n label=\"\"\n options={UserSession.value.userOrganizations}\n value={newOrgId}\n onChangeCallBack={(value) => {\n setNewOrgId(value);\n }}\n />\n <Button\n sx={{ m: 1 }}\n variant=\"contained\"\n disabled={\n newOrgId == null ||\n newOrgId === UserSession.value.currentOrganization.id\n }\n onClick={async () => {\n await handlePostRequest({\n endPointURI: \"api/auth/changeCurrentOrg\",\n showMask: true,\n parameters: {\n username: UserSession.value.username,\n orgId: newOrgId,\n },\n data: {},\n successCallBkFn: (response) => {\n const UserSession = {\n ...response.data,\n isAuthenticated: true,\n };\n dispatch(UserSessionActions.setAuthenticated(UserSession));\n if (props.successChangeCallBackFn) {\n props.successChangeCallBackFn();\n }\n },\n });\n }}\n >\n Change Organization\n </Button>\n </Box>\n );\n};\n\nexport default ChangeOrgForm;\n","import { createSlice } from \"@reduxjs/toolkit\";\n\nexport const DRAWER_WIDTH = 350;\n\ninterface SideBarState {\n isOpened: boolean;\n}\n\nconst initialState: SideBarState = {\n isOpened: false,\n};\n\nconst SideBarSlice = createSlice({\n name: \"SideBar\",\n initialState,\n reducers: {\n toggleSideBarState: (state) => {\n state.isOpened = !state.isOpened;\n },\n setSideBarState: (state, action) => {\n state.isOpened = action.payload;\n },\n },\n});\n\nexport const { toggleSideBarState, setSideBarState } = SideBarSlice.actions;\nexport default SideBarSlice.reducer;\n","import { useEffect, useRef } from \"react\";\n\nexport default function useInterval(\n callback: () => void,\n delay: number | null\n) {\n const savedCallback = useRef<() => void>(callback);\n\n // Remember the latest callback\n useEffect(() => {\n savedCallback.current = callback;\n }, [callback]);\n\n // Set up the interval\n useEffect(() => {\n if (delay === null) return;\n\n const tick = () => savedCallback.current?.();\n\n const id = setInterval(tick, delay);\n return () => clearInterval(id);\n }, [delay]);\n}\n","import { IconProp } from \"@fortawesome/fontawesome-svg-core\";\nimport { Box, Button, Divider, keyframes, Typography } from \"@mui/material\";\nimport { useSelector } from \"react-redux\";\nimport { useNavigate } from \"react-router-dom\";\nimport { useAxios, useSession } from \"../../hooks\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { timeAgo } from \"../../util\";\n\nconst beatFade = keyframes`\n 0% { transform: scale(1); opacity: 1; }\n 25% { transform: scale(1); opacity: 0.6; }\n 50% { transform: scale(1); opacity: 1; }\n 75% { transform: scale(1); opacity: 0.6; }\n 100% { transform: scale(1); opacity: 1; }\n`;\n\nexport type Notification = {\n id: number;\n notificationIcon?: IconProp;\n notificationIconColor?: string;\n notificationEnText: string;\n notificationArText: string;\n notificationTextColor?: string;\n notificationAction?: \"NAVIGATION\";\n notificationActionPayload?: string;\n isNotified?: boolean;\n createTime: string;\n setOpen?: (state: boolean) => void;\n showDivider?: boolean;\n};\nconst NotificationItem: React.FC<Notification> = (notification) => {\n const navigate = useNavigate();\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const { handlePostRequest } = useAxios();\n const acknowledgeNotification = (notificationId) => {\n handlePostRequest({\n endPointURI: \"api/v1/public/notification/notified\",\n showMask: false,\n parameters: { notificationQueueId: notificationId },\n });\n };\n return (\n <>\n <Button\n fullWidth\n onClick={() => {\n if (\n notification?.notificationAction === \"NAVIGATION\" &&\n notification?.notificationActionPayload\n ) {\n navigate(notification.notificationActionPayload);\n }\n if (!notification?.isNotified) {\n acknowledgeNotification(notification.id);\n }\n if (notification?.setOpen) {\n notification.setOpen(false);\n }\n }}\n sx={{\n marginBottom: 1,\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n color: notification?.notificationTextColor,\n display: \"flex\",\n flexDirection: \"column\",\n cursor: \"pointer\",\n }}\n >\n <Box\n sx={{\n cursor: \"pointer\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n width: \"100%\",\n }}\n >\n {notification?.notificationIcon ? (\n <FontAwesomeIcon\n icon={notification.notificationIcon}\n style={{\n marginRight: 10,\n marginLeft: 10,\n color: notification?.notificationIconColor,\n }}\n />\n ) : (\n <></>\n )}\n {AppLayout.appDirection === \"ltr\"\n ? notification.notificationEnText\n : notification.notificationArText}\n <Box sx={{ flex: 1 }}></Box>\n {!notification?.isNotified ? (\n <Typography\n color=\"warning\"\n sx={{\n animation: `${beatFade} 2s infinite ease-in-out`,\n textTransform: \"none\",\n display: \"inline-block\",\n }}\n >\n <FontAwesomeIcon\n icon=\"bell\"\n style={{ marginRight: 5, marginLeft: 5 }}\n />\n {AppLayout.appDirection === \"ltr\" ? \"New\" : \"جديد\"}\n </Typography>\n ) : (\n <></>\n )}\n </Box>\n <Box\n sx={{\n width: \"100%\",\n fontSize: 12,\n display: \"flex\",\n justifyContent: \"flex-end\",\n alignItems: \"center\",\n cursor: \"pointer\",\n }}\n >\n <Box sx={{ marginRight: 1, marginLeft: 1 }}>\n {timeAgo(notification.createTime, AppLayout.appDirection)}\n </Box>\n <Box sx={{ flex: 1 }}></Box>\n <Box sx={{ marginRight: 1, marginLeft: 1 }}>\n {notification.createTime}\n </Box>\n </Box>\n </Button>\n {notification?.showDivider ? <Divider flexItem /> : <></>}\n </>\n );\n};\n\nexport default NotificationItem;\n","import { IconProp } from \"@fortawesome/fontawesome-svg-core\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport {\n Badge,\n Box,\n Button,\n ClickAwayListener,\n Divider,\n Fade,\n IconButton,\n keyframes,\n Paper,\n Popper,\n PopperPlacementType,\n Typography,\n} from \"@mui/material\";\nimport { useEffect, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport { useSelector } from \"react-redux\";\nimport { useNavigate } from \"react-router-dom\";\nimport { timeAgo } from \"../util\";\nimport useInterval from \"../hooks/useInterval\";\nimport { useAxios, useSession } from \"../hooks\";\nimport { toast } from \"react-toastify\";\nimport NotificationItem, {\n Notification,\n} from \"../components/common/NotificationItem\";\n\nexport const notificationsCheckIntervalSeconds = 1;\n\nconst NotificationButton: React.FC = () => {\n const { UserInfo } = useSession();\n const [anchorEl, setAnchorEl] = useState<HTMLButtonElement | null>(null);\n const { handleGetRequest, handlePostRequest } = useAxios();\n const navigate = useNavigate();\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const [open, setOpen] = useState(false);\n const [notifications, setNotifications] = useState<Array<Notification>>([]);\n const loadUseNotifications = () => {\n if (UserInfo.isAuthenticated === true) {\n handleGetRequest({\n endPointURI: \"api/v1/public/notifications/new\",\n showMask: false,\n successCallBkFn: (response: any) => {\n if (response.data.length > notifications.length) {\n toast.info(\n AppLayout.appDirection === \"ltr\"\n ? `You have new notifications`\n : `لديك اشعارات جديدة`,\n {\n autoClose: 3000,\n position:\n AppLayout.appDirection === \"ltr\"\n ? \"bottom-right\"\n : \"bottom-left\",\n closeOnClick: true,\n }\n );\n }\n setNotifications(response.data);\n },\n });\n }\n };\n\n useInterval(() => {\n loadUseNotifications();\n }, notificationsCheckIntervalSeconds * 1000);\n\n const handleClick = (event: React.MouseEvent<HTMLButtonElement>) => {\n setAnchorEl(event.currentTarget);\n setOpen(!open);\n };\n return (\n <ClickAwayListener\n onClickAway={() => {\n setOpen(false);\n }}\n >\n <div style={{ cursor: \"pointer\" }}>\n <IconButton\n color=\"inherit\"\n onClick={handleClick}\n sx={{ marginRight: 1, marginLeft: 1 }}\n >\n <Badge\n anchorOrigin={{\n vertical: \"top\",\n horizontal: AppLayout.appDirection === \"ltr\" ? \"right\" : \"left\",\n }}\n badgeContent={\n notifications.filter(\n (notificaiton) =>\n notificaiton.isNotified === undefined ||\n notificaiton.isNotified === null\n ).length\n }\n color=\"error\"\n >\n <FontAwesomeIcon icon=\"bell\" />\n </Badge>\n </IconButton>\n\n <Popper\n // Note: The following zIndex style is specifically for documentation purposes and may not be necessary in your application.\n sx={{\n zIndex: 1200,\n width: \"fit-content\",\n minWidth: 350,\n display: \"flex\",\n flexDirection: \"column\",\n }}\n open={open}\n anchorEl={anchorEl}\n dir={AppLayout.appDirection}\n placement={\"bottom\"}\n transition\n >\n {({ TransitionProps }) => (\n <Fade {...TransitionProps} timeout={350}>\n <Paper\n sx={{\n padding: 1,\n m: 1,\n maxHeight: 500,\n overflow: \"hidden\",\n display: \"flex\",\n flexDirection: \"column\",\n }}\n >\n <Divider variant=\"fullWidth\" flexItem>\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n marginTop: 2,\n marginBottom: 1,\n }}\n >\n <FontAwesomeIcon\n icon=\"bell\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n {AppLayout.appDirection === \"ltr\"\n ? \"Notifications\"\n : \"الاشعارات\"}\n </Box>\n </Divider>\n {notifications.length == 0 ? (\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n flex: 1,\n justifyContent: \"center\",\n }}\n >\n <Box>\n {AppLayout.appDirection === \"ltr\"\n ? \"You don't have any notifications\"\n : \"لا يوجد اشعارات\"}\n </Box>\n </Box>\n ) : (\n <></>\n )}\n <Box\n sx={{\n flex: 1,\n display: \"flex\",\n flexDirection: \"column\",\n overflowY: \"auto\",\n }}\n >\n {notifications.map((notification, index) => {\n return (\n <NotificationItem\n {...notification}\n setOpen={setOpen}\n showDivider={index < notifications.length - 1}\n />\n );\n })}\n </Box>\n <Divider variant=\"fullWidth\" flexItem>\n <Button\n sx={{ textTransform: \"none\" }}\n onClick={() => {\n navigate(\"myNotifications\");\n }}\n >\n {AppLayout.appDirection === \"ltr\"\n ? \"Show Old Notifications\"\n : \"عرض الاشعارات القديمة\"}\n </Button>\n </Divider>\n </Paper>\n </Fade>\n )}\n </Popper>\n </div>\n </ClickAwayListener>\n );\n};\n\nexport default NotificationButton;\n","import { Box, Button, Divider, Paper } from \"@mui/material\";\nimport { TemplateTextField } from \"../../templates\";\nimport { useState } from \"react\";\nimport { toast } from \"react-toastify\";\nimport { useAxios } from \"../../../hooks\";\n\ninterface ChangePasswordPanelProps {\n selectedPerson: any;\n isSelfService: boolean;\n onSuccessCallBk: () => void;\n}\n\nconst ChangePasswordPanel: React.FC<ChangePasswordPanelProps> = (props) => {\n const [currentPassword, setCurrentPassword] = useState(\"\");\n const [password1, setPassword1] = useState(\"\");\n const [password2, setPassword2] = useState(\"\");\n const { handlePostRequest } = useAxios();\n const handleChangePasswordRequest = async () => {\n if (props.isSelfService) {\n if (currentPassword === null || currentPassword.trim() === \"\") {\n toast.error(\n \"You must enter your current password to process your request\"\n );\n return;\n }\n }\n if (\n password1 === null ||\n password1 === \"\" ||\n password2 === null ||\n password2 === \"\" ||\n password1 != password2\n ) {\n toast.error(\n \"You must enter new password in required fields and must be identical\"\n );\n return;\n }\n await handlePostRequest({\n endPointURI: props.isSelfService\n ? \"api/v1/ss/changeMyPassword\"\n : \"api/v1/admin/changeUserPassword\",\n data: {\n personId: props?.selectedPerson?.id,\n currentPassword,\n newPassword: password1,\n },\n successCallBkFn: () => {\n props.onSuccessCallBk();\n toast.success(\"Your request has been processed successfully\");\n },\n showMask: true,\n });\n };\n return (\n <Paper\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"center\",\n width: 400,\n padding: 1,\n }}\n >\n <Box\n sx={{\n m: 1,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n width: \"100%\",\n fontWeight: \"bold\",\n fontSize: 16,\n }}\n >\n Changing Password For : {props?.selectedPerson?.employeeEnName}\n </Box>\n <Divider variant=\"fullWidth\" sx={{ width: \"100%\", marginBottom: 2 }} />\n {props.isSelfService ? (\n <TemplateTextField\n label=\"Current Password\"\n value={currentPassword}\n onChange={(e) => {\n setCurrentPassword(e.target.value);\n }}\n sx={{ m: 1 }}\n fullWidth\n type=\"password\"\n />\n ) : (\n <></>\n )}\n\n <TemplateTextField\n label=\"New Password\"\n value={password1}\n onChange={(e) => {\n setPassword1(e.target.value);\n }}\n sx={{ m: 1 }}\n fullWidth\n type=\"password\"\n />\n <TemplateTextField\n label=\"Confirm New Password\"\n value={password2}\n onChange={(e) => {\n setPassword2(e.target.value);\n }}\n sx={{ m: 1 }}\n fullWidth\n type=\"password\"\n />\n <Button\n sx={{ m: 1 }}\n variant=\"contained\"\n onClick={() => {\n handleChangePasswordRequest();\n }}\n >\n Change Password\n </Button>\n </Paper>\n );\n};\n\nexport default ChangePasswordPanel;\n","import {\n Avatar,\n Box,\n IconButton,\n Menu,\n MenuItem,\n styled,\n Tooltip,\n Typography,\n} from \"@mui/material\";\nimport MuiAppBar, { AppBarProps as MuiAppBarProps } from \"@mui/material/AppBar\";\nimport Toolbar from \"@mui/material/Toolbar\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { useIsMobile } from \"../hooks/UseMobile\";\nimport {\n AppLayoutActions,\n DRAWER_WIDTH,\n} from \"../redux/features/common/AppLayoutSlice\";\nimport useAxios from \"../hooks/useAxios\";\nimport { UserSessionActions } from \"../redux/features/common/UserSessionSlice\";\nimport i18n, { changeLanguage } from \"../locales/i18n\";\nimport { useSession, useWindow } from \"../hooks\";\nimport ChangeOrgForm from \"../components/common/ChangeOrgForm\";\nimport { toggleSideBarState } from \"../redux/features/common/SideBarSlice\";\nimport AttachmentImageViewer from \"../components/templates/attachment/AttachmentImageViewer\";\nimport NotificationButton from \"./NotificationButton\";\nimport { useState } from \"react\";\nimport ChangePasswordPanel from \"../components/administration/admin/ChangePasswordPanel\";\n\ninterface AppBarProps extends MuiAppBarProps {\n open?: boolean;\n}\n\nconst AppBar = styled(MuiAppBar, {\n shouldForwardProp: (prop) => prop !== \"open\",\n})<AppBarProps>(({ theme }) => {\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const isMobile = useIsMobile();\n return {\n transition: theme.transitions.create([\"margin\", \"width\"], {\n easing: theme.transitions.easing.sharp,\n duration: theme.transitions.duration.leavingScreen,\n }),\n variants: [\n {\n props: ({ open }) => open,\n style: {\n width: !isMobile ? `calc(100% - ${DRAWER_WIDTH}px)` : undefined,\n marginLeft:\n !isMobile && AppLayout.appDirection === \"ltr\"\n ? `${DRAWER_WIDTH}px`\n : undefined,\n marginRight:\n !isMobile && AppLayout.appDirection === \"rtl\"\n ? `${DRAWER_WIDTH}px`\n : undefined,\n transition: theme.transitions.create([\"margin\", \"width\"], {\n easing: theme.transitions.easing.easeOut,\n duration: theme.transitions.duration.enteringScreen,\n }),\n },\n },\n ],\n };\n});\n\nconst TopBar: React.FC = () => {\n const { Window: ChangeOrgWindow, setWindowState: setChangeOrgWindowState } =\n useWindow({\n windowTitle: \"Change Current Organization\",\n windowIcon: \"globe\",\n width: \"fit-content\",\n height: \"fit-content\",\n });\n const AppInfo = useSelector((state: any) => state.AppInfo.value);\n const [anchorElUser, setAnchorElUser] = useState<null | HTMLElement>(null);\n const handleCloseUserMenu = () => {\n setAnchorElUser(null);\n };\n const handleOpenUserMenu = (event: React.MouseEvent<HTMLElement>) => {\n setAnchorElUser(event.currentTarget);\n };\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const SideBarState = useSelector((state: any) => state.SideBar);\n const { UserSession } = useSession();\n const currentOrganization = UserSession.value.currentOrganization;\n const {\n Window: ChangePasswordWindow,\n setWindowState: setChangePasswordWindow,\n } = useWindow({\n windowIcon: \"key\",\n windowTitle: \"Change Password\",\n width: \"fit-content\",\n height: \"fit-content\",\n });\n const { handleGetRequest } = useAxios();\n const isMobile = useIsMobile();\n const dispatch = useDispatch();\n const handleLogout = async () => {\n try {\n await handleGetRequest({ endPointURI: \"api/auth/logout\" });\n } catch (error) {}\n dispatch(UserSessionActions.setUnAuthenticated());\n };\n const toggleSideBar = () => {\n dispatch(toggleSideBarState());\n };\n return (\n <>\n <ChangePasswordWindow>\n <ChangePasswordPanel\n selectedPerson={UserSession.value}\n isSelfService={true}\n onSuccessCallBk={() => {\n setChangePasswordWindow(false);\n }}\n />\n </ChangePasswordWindow>\n <Menu\n sx={{ mt: \"45px\" }}\n id=\"menu-appbar\"\n anchorEl={anchorElUser}\n anchorOrigin={{\n vertical: \"top\",\n horizontal: \"right\",\n }}\n keepMounted\n transformOrigin={{\n vertical: \"top\",\n horizontal: \"right\",\n }}\n open={Boolean(anchorElUser)}\n onClose={handleCloseUserMenu}\n >\n <MenuItem\n onClick={() => {\n setChangePasswordWindow(true);\n handleCloseUserMenu();\n }}\n >\n <Typography sx={{ textAlign: \"center\" }}>Change Password</Typography>\n </MenuItem>\n </Menu>\n <ChangeOrgWindow>\n <ChangeOrgForm\n successChangeCallBackFn={() => {\n setChangeOrgWindowState(false);\n }}\n />\n </ChangeOrgWindow>\n <AppBar position=\"fixed\" open={SideBarState.isOpened}>\n <Toolbar>\n <IconButton\n color=\"inherit\"\n aria-label=\"open drawer\"\n onClick={toggleSideBar}\n edge=\"start\"\n sx={[\n {\n mr: AppLayout.appDirection === \"ltr\" ? 2 : undefined,\n ml: AppLayout.appDirection === \"rtl\" ? 2 : undefined,\n },\n SideBarState.isOpened && { display: \"none\" },\n ]}\n >\n <FontAwesomeIcon icon=\"bars\" />\n </IconButton>\n <AttachmentImageViewer\n showAsAvatar={true}\n attachmentCode=\"ORGANIZATION_LOGOS\"\n refKey={UserSession.value.currentOrganization.id + \"\"}\n onErrorImage=\"/logo.png\"\n style={{\n marginRight: 1,\n marginLeft: 1,\n }}\n />\n {/* <Avatar\n src={AppInfo.appLogo}\n sx={{ marginRight: 1, marginLeft: 1 }}\n /> */}\n <Typography variant=\"h6\" noWrap component=\"div\" sx={{ flex: 1 }}>\n {isMobile\n ? \"\"\n : `${AppInfo.appName} - ${\n AppLayout.appDirection === \"ltr\"\n ? currentOrganization?.organizationEnName\n : currentOrganization?.organizationArName\n }`}\n </Typography>\n <Tooltip\n title={\n AppLayout.themeMode === \"light\"\n ? \"Switch Theme to Dark\"\n : \"Switch Theme to Light\"\n }\n >\n <IconButton\n color=\"inherit\"\n onClick={() => {\n dispatch(\n AppLayoutActions.setThemeMode(\n AppLayout.themeMode === \"light\" ? \"dark\" : \"light\"\n )\n );\n localStorage.setItem(\n \"themeMode\",\n AppLayout.themeMode === \"light\" ? \"dark\" : \"light\"\n );\n }}\n >\n {AppLayout.themeMode === \"light\" ? (\n <FontAwesomeIcon icon=\"moon\" />\n ) : (\n <FontAwesomeIcon icon={{ prefix: \"far\", iconName: \"sun\" }} />\n )}\n </IconButton>\n </Tooltip>\n <Tooltip\n title={\n i18n.language === \"ar\"\n ? \"Change Language To English\"\n : \"Change Language To Arabic\"\n }\n >\n <IconButton\n color=\"inherit\"\n onClick={() => {\n let nextLanguage = i18n.language === \"ar\" ? \"en\" : \"ar\";\n changeLanguage(nextLanguage);\n dispatch(\n AppLayoutActions.setAppDirection(\n nextLanguage === \"ar\" ? \"rtl\" : \"ltr\"\n )\n );\n }}\n >\n <FontAwesomeIcon icon=\"language\" />\n </IconButton>\n </Tooltip>\n {UserSession.value?.userOrganizations &&\n UserSession.value?.userOrganizations.length > 1 ? (\n <Tooltip title=\"Change Current Organization\">\n <IconButton\n color=\"inherit\"\n onClick={() => {\n setChangeOrgWindowState(true);\n }}\n >\n <FontAwesomeIcon icon=\"globe\" />\n </IconButton>\n </Tooltip>\n ) : (\n <></>\n )}\n {AppInfo?.enableUINotifications === true ? (\n <NotificationButton />\n ) : (\n <></>\n )}\n <div onClick={handleOpenUserMenu} style={{ cursor: \"pointer\" }}>\n <AttachmentImageViewer\n showAsAvatar={true}\n onErrorImage=\"/no_user.png\"\n attachmentCode=\"EMPLOYEE_PHOTOS\"\n refKey={UserSession.value?.id + \"\"}\n />\n </div>\n\n <div\n style={{ marginLeft: 5, marginRight: 5, cursor: \"pointer\" }}\n onClick={handleOpenUserMenu}\n >\n {isMobile ? \"\" : UserSession.value?.username}\n </div>\n <IconButton color=\"inherit\" onClick={handleLogout}>\n <FontAwesomeIcon\n rotation={AppLayout.appDirection === \"rtl\" ? 180 : undefined}\n icon=\"arrow-right-from-bracket\"\n />\n </IconButton>\n </Toolbar>\n </AppBar>\n </>\n );\n};\n\nexport default TopBar;\n","import i18n from \"i18next\";\n\nexport const changeLanguage = (lng: string) => {\n i18n.changeLanguage(lng);\n localStorage.setItem(\"language\", lng); // Persist user choice\n};\n\nexport default i18n;\n","import { styled } from \"@mui/material\";\n\nexport const DrawerHeader = styled(\"div\")(({ theme }) => ({\n display: \"flex\",\n alignItems: \"center\", \n // padding: theme.spacing(0, 1),\n // necessary for content to be below app bar\n ...theme.mixins.toolbar,\n justifyContent: \"flex-end\",\n}));\n","import { TreeViewBaseItem } from \"@mui/x-tree-view/models\";\nimport { AdministrationItems } from \"./Administration\";\nimport { IconProp } from \"@fortawesome/fontawesome-svg-core\";\n\nexport type ExtendedTreeItemProps = {\n icon: IconProp;\n id: string;\n label: string;\n action?: \"NAVIGATION\";\n authority?: string;\n applicationModule?: string;\n actionPayload?: {\n path?: string;\n parameters?: object;\n };\n children?: ExtendedTreeItemProps[];\n};\n\nexport const findNavigationItemById = (\n id: string,\n nodes: ExtendedTreeItemProps[]\n): ExtendedTreeItemProps | undefined => {\n for (const node of nodes) {\n if (node.id === id) return node;\n if (node.children) {\n const found = findNavigationItemById(id, node.children);\n if (found) return found;\n }\n }\n return undefined;\n};\n\nexport const NavigationItems: TreeViewBaseItem<ExtendedTreeItemProps>[] = [\n ...AdministrationItems\n];\n","import { TreeViewBaseItem } from \"@mui/x-tree-view/models\";\nimport { ExtendedTreeItemProps } from \"..\";\nimport { adminNavigationItems } from \"./adminNavigationItems\";\n\nexport const AdministrationItems: TreeViewBaseItem<ExtendedTreeItemProps>[] = [\n {\n id: \"home\",\n icon: \"home\",\n label: \"Home\",\n action: \"NAVIGATION\",\n actionPayload: {\n path: \"/\",\n },\n },\n ...adminNavigationItems,\n];\n","import { TreeViewBaseItem } from \"@mui/x-tree-view/models\";\nimport { ExtendedTreeItemProps } from \"..\";\n\nexport const adminNavigationItems: TreeViewBaseItem<ExtendedTreeItemProps>[] = [\n {\n id: \"system_admin\",\n label: \"System Administration\",\n authority: \"SYSTEM_ADMIN\",\n icon: \"cog\",\n children: [\n {\n id: \"system_admin.Person\",\n label: \"PERSON_PLURAL\",\n authority: \"SYSTEM_ADMIN\",\n icon: \"users\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"admin/persons\" },\n },\n {\n id: \"system_admin.devtools.rolesx\",\n label: \"ROLES\",\n icon: \"tag\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/system/roles\" },\n },\n {\n id: \"development_admin.SystemApplication\",\n label: \"SYSTEM_APPLICATION_PLURAL\",\n authority: \"ORGANIZATION_ADMIN\",\n icon: \"window-restore\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"admin/systemapplications\" },\n },\n {\n id: \"development_admin.organizations\",\n label: \"ORGANIZATION_PLURAL\",\n authority: \"ORGANIZATION_ADMIN\",\n icon: \"globe\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"admin/organizations\" },\n },\n {\n id: \"development_admin.organization\",\n label: \"Organization Info\",\n authority: \"DEVELOPMENT_ADMIN\",\n icon: \"globe\",\n children: [\n {\n id: \"development_admin.organization.modules\",\n label: \"Subscriped Modules\",\n icon: \"layer-group\",\n authority: \"ORGANIZATION_ADMIN\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"admin/org/apps\" },\n },\n {\n id: \"development_admin.organization.unitTypes\",\n label: \"Organization Unit Types\",\n icon: \"tags\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"admin/org/unit/types\" },\n },\n {\n id: \"development_admin.organization.units\",\n label: \"Organization Units\",\n icon: \"folder-tree\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"admin/org/units\" },\n },\n {\n id: \"development_admin.organization.ranks\",\n label: \"Organization Ranks\",\n icon: \"street-view\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"admin/org/ranks\" },\n },\n ],\n },\n\n {\n id: \"system_admin.devtools\",\n label: \"DEVELOPMENT_TOOLS\",\n authority: \"DEVELOPMENT_ADMIN\",\n icon: \"code\",\n children: [\n {\n id: \"system_admin.devtools.modules\",\n label: \"System Modules\",\n icon: \"layer-group\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/system/modules\" },\n },\n {\n id: \"system_admin.devtools.authorities\",\n label: \"System Authorities\",\n icon: \"key\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/system/authorities\" },\n },\n {\n id: \"system_admin.devtools.roles\",\n label: \"System Roles\",\n icon: \"tag\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/system/roles\" },\n },\n {\n id: \"system_admin.devtools.lookups\",\n label: \"System Lookups\",\n icon: \"list-check\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/system/lookups\" },\n },\n {\n id: \"system_admin.devtools.DatasourceConnection\",\n label: \"DATASOURCE_CONNECTION_PLURAL\",\n icon: \"plug\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/datasourceconnections\" },\n },\n {\n id: \"system_admin.devtools.EntityParameter\",\n label: \"ENTITY_PARAMETER_PLURAL\",\n icon: \"p\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/entityparameters\" },\n },\n {\n id: \"system_admin.devtools.DataQuery\",\n label: \"DATA_QUERY_PLURAL\",\n icon: \"file-code\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/dataqueries\" },\n },\n {\n id: \"system_admin.devtools.Report\",\n label: \"REPORT_PLURAL\",\n icon: \"file\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/reports\" },\n },\n {\n id: \"system_admin.devtools.MailConfig\",\n label: \"Mail Sender Config\",\n icon: { iconName: \"paper-plane\", prefix: \"fas\" },\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/mailsender/config\" },\n },\n {\n id: \"system_admin.devtools.MailTemplate\",\n label: \"MAIL_TEMPLATE_PLURAL\",\n icon: \"envelope\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/mailtemplates\" },\n },\n {\n id: \"system_admin.devtools.WorkflowDocument\",\n label: \"WORKFLOW_DOCUMENT_PLURAL\",\n icon: \"chart-diagram\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/workflowdocuments\" },\n },\n {\n id: \"system_admin.devtools.Widget\",\n label: \"WIDGET_PLURAL\",\n icon: \"chart-pie\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/widgets\" },\n },\n {\n id: \"system_admin.devtools.Dashboard\",\n label: \"DASHBOARD_PLURAL\",\n icon: \"square-poll-vertical\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/dashboards\" },\n },\n {\n id: \"system_admin.devtools.AttachmentConfig\",\n label: \"ATTACHMENT_CONFIG_PLURAL\",\n icon: \"paperclip\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/attachmentconfigs\" },\n },\n {\n id: \"system_admin.devtools.BluePrint\",\n label: \"BLUE_PRINT_PLURAL\",\n icon: \"fingerprint\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/blueprints\" },\n },\n {\n id: \"system_admin.devtools.Notification\",\n label: \"NOTIFICATION_PLURAL\",\n icon: \"bell\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/notifications\" },\n },\n ],\n },\n {\n id: \"system_admin.followup\",\n label: \"SYSTEM_MONITORING\",\n authority: \"DEVELOPMENT_ADMIN\",\n icon: \"tv\",\n children: [\n {\n id: \"system_admin.WorkflowDocumentMailLog\",\n label: \"Action Mail Logs\",\n icon: \"envelopes-bulk\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/workflowdocumentmaillogs\" },\n },\n {\n id: \"system_admin.MailNotificationQueue\",\n label: \"Mail Notification Queue\",\n icon: \"envelope-open-text\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/mailnotificationqueues\" },\n },\n {\n id: \"system_admin.NotificationQueue\",\n label: \"NOTIFICATION_QUEUE_PLURAL\",\n icon: \"bell\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/notificationqueues\" },\n },\n ],\n },\n ],\n },\n];\n","import * as React from \"react\";\nimport clsx from \"clsx\";\nimport { animated, useSpring } from \"@react-spring/web\";\nimport { styled, alpha } from \"@mui/material/styles\";\nimport { TransitionProps } from \"@mui/material/transitions\";\nimport Box from \"@mui/material/Box\";\nimport Collapse from \"@mui/material/Collapse\";\nimport Typography from \"@mui/material/Typography\";\nimport { RichTreeView } from \"@mui/x-tree-view/RichTreeView\";\nimport { treeItemClasses } from \"@mui/x-tree-view/TreeItem\";\nimport {\n useTreeItem2,\n UseTreeItem2Parameters,\n} from \"@mui/x-tree-view/useTreeItem2\";\nimport {\n TreeItem2Checkbox,\n TreeItem2Content,\n TreeItem2IconContainer,\n TreeItem2Label,\n TreeItem2Root,\n} from \"@mui/x-tree-view/TreeItem2\";\nimport { TreeItem2Icon } from \"@mui/x-tree-view/TreeItem2Icon\";\nimport { TreeItem2Provider } from \"@mui/x-tree-view/TreeItem2Provider\";\nimport { TreeItem2DragAndDropOverlay } from \"@mui/x-tree-view/TreeItem2DragAndDropOverlay\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { useNavigate } from \"react-router-dom\";\nimport { useTranslation } from \"react-i18next\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { IconProp } from \"@fortawesome/fontawesome-svg-core\";\nimport { useIsMobile } from \"../hooks/UseMobile\";\nimport useSession from \"../hooks/UseSession\";\nimport { findNavigationItemById, NavigationItems } from \"../navigationItems\";\nimport { DRAWER_WIDTH } from \"../redux/features/common/AppLayoutSlice\";\n\nfunction DotIcon() {\n return (\n <Box\n sx={{\n width: 6,\n height: 6,\n borderRadius: \"70%\",\n bgcolor: \"warning.main\",\n display: \"inline-block\",\n verticalAlign: \"middle\",\n zIndex: 1,\n mx: 1,\n }}\n />\n );\n}\ndeclare module \"react\" {\n interface CSSProperties {\n \"--tree-view-color\"?: string;\n \"--tree-view-bg-color\"?: string;\n }\n}\n\nconst StyledTreeItemRoot = styled(TreeItem2Root)(({ theme }) => ({\n color: theme.palette.grey[400],\n position: \"relative\",\n [`& .${treeItemClasses.groupTransition}`]: {\n marginLeft: theme.spacing(2.5),\n },\n ...theme.applyStyles(\"light\", {\n color: theme.palette.grey[800],\n }),\n})) as unknown as typeof TreeItem2Root;\n\nconst CustomTreeItemContent = styled(TreeItem2Content)(({ theme }) => ({\n flexDirection: \"row-reverse\",\n borderRadius: theme.spacing(0.7),\n marginBottom: theme.spacing(0.5),\n marginTop: theme.spacing(0.5),\n padding: theme.spacing(0.5),\n paddingRight: theme.spacing(1),\n [`&.Mui-expanded `]: {\n \"&:not(.Mui-focused, .Mui-selected, .Mui-selected.Mui-focused) .labelIcon\":\n {\n color: theme.palette.primary.dark,\n ...theme.applyStyles(\"light\", {\n color: theme.palette.primary.main,\n }),\n },\n \"&::before\": {\n content: '\"\"',\n display: \"block\",\n position: \"absolute\",\n left: \"16px\",\n top: \"44px\",\n height: \"calc(100% - 48px)\",\n width: \"1.5px\",\n backgroundColor: theme.palette.grey[700],\n ...theme.applyStyles(\"light\", {\n backgroundColor: theme.palette.grey[300],\n }),\n },\n },\n \"&:hover\": {\n backgroundColor: alpha(theme.palette.primary.main, 0.1),\n color: \"white\",\n ...theme.applyStyles(\"light\", {\n color: theme.palette.primary.main,\n }),\n },\n [`&.Mui-focused, &.Mui-selected, &.Mui-selected.Mui-focused`]: {\n backgroundColor: theme.palette.primary.dark,\n color: theme.palette.primary.contrastText,\n ...theme.applyStyles(\"light\", {\n backgroundColor: theme.palette.primary.main,\n }),\n },\n}));\n\nconst AnimatedCollapse = animated(Collapse);\n\nfunction TransitionComponent(props: TransitionProps) {\n const style = useSpring({\n to: {\n opacity: props.in ? 1 : 0,\n transform: `translate3d(0,${props.in ? 0 : 20}px,0)`,\n },\n });\n\n return <AnimatedCollapse style={style} {...props} />;\n}\n\nconst StyledTreeItemLabelText = styled(Typography)({\n color: \"inherit\",\n fontWeight: 500,\n}) as unknown as typeof Typography;\n\ninterface CustomLabelProps {\n children: any;\n icon: IconProp;\n expandable?: boolean;\n}\n\nfunction CustomLabel({\n icon,\n expandable,\n children,\n ...other\n}: CustomLabelProps) {\n const { t } = useTranslation();\n const appLayoutState = useSelector((state: any) => state.AppLayout);\n return (\n <TreeItem2Label\n {...other}\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n padding: 1,\n }}\n >\n <FontAwesomeIcon\n style={{\n marginRight: appLayoutState.appDirection === \"ltr\" ? 7 : undefined,\n marginLeft: appLayoutState.appDirection === \"rtl\" ? 7 : undefined,\n fontSize: \"1.2rem\",\n }}\n icon={icon}\n />\n <StyledTreeItemLabelText variant=\"body2\" sx={{ fontSize: 16 }}>\n {t(children)}\n </StyledTreeItemLabelText>\n {expandable && <DotIcon />}\n </TreeItem2Label>\n );\n}\n\nconst isExpandable = (reactChildren: React.ReactNode) => {\n if (Array.isArray(reactChildren)) {\n return reactChildren.length > 0 && reactChildren.some(isExpandable);\n }\n return Boolean(reactChildren);\n};\n\ninterface CustomTreeItemProps\n extends Omit<UseTreeItem2Parameters, \"rootRef\">,\n Omit<React.HTMLAttributes<HTMLLIElement>, \"onFocus\"> {}\n\nconst CustomTreeItem = React.forwardRef(function CustomTreeItem(\n props: CustomTreeItemProps,\n ref: React.Ref<HTMLLIElement>\n) {\n const { id, itemId, label, disabled, children, ...other } = props;\n const {\n getRootProps,\n getContentProps,\n getIconContainerProps,\n getCheckboxProps,\n getLabelProps,\n getGroupTransitionProps,\n getDragAndDropOverlayProps,\n status,\n publicAPI,\n } = useTreeItem2({ id, itemId, children, label, disabled, rootRef: ref });\n const item = publicAPI.getItem(itemId);\n const expandable = isExpandable(children);\n return (\n <TreeItem2Provider itemId={itemId}>\n <StyledTreeItemRoot {...getRootProps(other)}>\n <CustomTreeItemContent\n {...getContentProps({\n className: clsx(\"content\", {\n \"Mui-expanded\": status.expanded,\n \"Mui-selected\": status.selected,\n \"Mui-focused\": status.focused,\n \"Mui-disabled\": status.disabled,\n }),\n })}\n >\n <TreeItem2IconContainer {...getIconContainerProps()}>\n <TreeItem2Icon status={status} />\n </TreeItem2IconContainer>\n <TreeItem2Checkbox {...getCheckboxProps()} />\n <CustomLabel\n {...getLabelProps({\n icon: item?.icon || \"book\",\n expandable: expandable && status.expanded,\n })}\n />\n <TreeItem2DragAndDropOverlay {...getDragAndDropOverlayProps()} />\n </CustomTreeItemContent>\n {children && <TransitionComponent {...getGroupTransitionProps()} />}\n </StyledTreeItemRoot>\n </TreeItem2Provider>\n );\n});\n\nexport default function NavigationTree() {\n const navigate = useNavigate();\n const appLayoutState = useSelector((state: any) => state.AppLayout);\n const AppInfo = useSelector((state: any) => state.AppInfo.value);\n const dispatch = useDispatch();\n const isMobile = useIsMobile();\n const { isUserAuthorized, isCurrentOrganizationAuthorizedToModule } =\n useSession();\n const filterData = (data) => {\n const parentItems = [];\n for (let parentItem of data) {\n if (\n (parentItem.authority === undefined ||\n parentItem.authority == null ||\n isUserAuthorized(parentItem.authority)) &&\n (parentItem.applicationModule === undefined ||\n parentItem.applicationModule === null ||\n isCurrentOrganizationAuthorizedToModule(parentItem.applicationModule))\n ) {\n let newParentItem = structuredClone(parentItem);\n if (parentItem?.children) {\n newParentItem.children = filterData(parentItem.children);\n }\n parentItems.push(newParentItem);\n }\n }\n return parentItems;\n };\n\n const mergedNavigationItems = [];\n if (AppInfo.enableAdministrationModule) {\n mergedNavigationItems.push(...structuredClone(NavigationItems));\n }\n mergedNavigationItems.push(\n ...structuredClone(AppInfo.businessNavigationItems)\n );\n const authoriedNavigationItems = filterData(mergedNavigationItems);\n return (\n <RichTreeView\n items={authoriedNavigationItems}\n onItemClick={(event, itemId) => {\n const navigationItem = findNavigationItemById(\n itemId,\n mergedNavigationItems\n );\n if (\n navigationItem?.action === \"NAVIGATION\" &&\n navigationItem?.actionPayload != null &&\n (navigationItem.children === undefined ||\n navigationItem.children === null ||\n navigationItem.children.length == 0)\n ) {\n navigate(navigationItem?.actionPayload?.path || \"\");\n }\n }}\n sx={{\n height: \"fit-content\",\n flexGrow: 1,\n maxWidth: DRAWER_WIDTH,\n direction: appLayoutState.appDirection,\n maxHeight: isMobile ? 300 : undefined,\n overflowY: \"auto\",\n overflowX: \"auto\",\n }}\n slots={{ item: CustomTreeItem }}\n />\n );\n}\n","import Divider from \"@mui/material/Divider\";\nimport IconButton from \"@mui/material/IconButton\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport Drawer from \"@mui/material/Drawer\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { DrawerHeader } from \"./DrawerHeader\";\nimport { Box, Typography, useTheme } from \"@mui/material\";\nimport { DRAWER_WIDTH } from \"../redux/features/common/AppLayoutSlice\";\nimport NavigationTree from \"./NavigationTree\";\nimport { useSession } from \"../hooks\";\nimport { toggleSideBarState } from \"../redux/features/common/SideBarSlice\";\n\nconst SideBar: React.FC = () => {\n const AppInfo = useSelector((state: any) => state.AppInfo.value);\n const { UserSession } = useSession();\n const currentOrganization = UserSession.value.currentOrganization;\n const theme = useTheme();\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const SideBarState = useSelector((state: any) => state.SideBar);\n const dispatch = useDispatch();\n const toggleSideBar = () => {\n dispatch(toggleSideBarState());\n };\n return (\n <Drawer\n sx={{\n width: DRAWER_WIDTH,\n flexShrink: 0,\n \"& .MuiDrawer-paper\": {\n width: DRAWER_WIDTH,\n boxSizing: \"border-box\",\n },\n }}\n variant=\"persistent\"\n anchor={AppLayout.appDirection === \"ltr\" ? \"left\" : \"right\"}\n open={SideBarState.isOpened}\n >\n <DrawerHeader>\n <Box sx={{ width: \"100%\" }}>\n <Typography\n color=\"primary\"\n sx={{\n width: \"100%\",\n textAlign: \"center\",\n fontSize: 18,\n fontWeight: \"bold\",\n }}\n >\n System Content\n </Typography>\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"space-around\",\n marginTop: 1,\n }}\n >\n <Typography sx={{ fontSize: 12 }} color=\"textDisabled\">\n {`${AppInfo.appName} - ${\n AppLayout.appDirection === \"ltr\"\n ? currentOrganization?.organizationEnName\n : currentOrganization?.organizationArName\n }`}\n </Typography>\n <Typography sx={{ fontSize: 12 }} color=\"textDisabled\">\n V.{AppInfo.appVersion}\n </Typography>\n </Box>\n </Box>\n <IconButton onClick={toggleSideBar}>\n {theme.direction === \"ltr\" ? (\n <FontAwesomeIcon icon=\"angle-left\" />\n ) : (\n <FontAwesomeIcon icon=\"angle-right\" />\n )}\n </IconButton>\n </DrawerHeader>\n <Divider />\n <NavigationTree />\n </Drawer>\n );\n};\n\nexport default SideBar;\n","import rtlPlugin from \"stylis-plugin-rtl\";\nimport { prefixer } from \"stylis\";\nimport createCache from \"@emotion/cache\";\n\nexport const cacheRtl = createCache({\n key: \"muirtl\",\n stylisPlugins: [prefixer, rtlPlugin],\n});\n\nexport const cacheLtr = createCache({\n key: \"mui\",\n});","import { useEffect, useState } from \"react\";\nimport TransferList from \"../../templates/TransferList\";\nimport { Box, Button } from \"@mui/material\";\nimport { toast } from \"react-toastify\";\nimport { useAxios } from \"../../../hooks\";\n\ntype OrgMemberRoleFormProps = {\n selectedRecord: any;\n closeModalFn: () => void;\n};\n\nconst OrgMemberRoleForm: React.FC<OrgMemberRoleFormProps> = (props) => {\n const [selectedOptions, setSelectedOptions] = useState([]);\n const [availableOptions, setAvailableOptions] = useState([]);\n const { handlePostRequest, handleGetRequest } = useAxios();\n\n const getOrgMemberRoles = async () => {\n await handleGetRequest({\n endPointURI: \"api/v1/admin/organization/member/roles\",\n showMask: true,\n parameters: {\n orgMemberId: props.selectedRecord.id,\n organizationId: props.selectedRecord.organizationId,\n },\n successCallBkFn: (response: any) => {\n setSelectedOptions(response.data.currentRoles);\n setAvailableOptions(response.data.availableRoles);\n },\n });\n };\n\n useEffect(() => {\n if (props.selectedRecord) {\n getOrgMemberRoles();\n }\n }, [props.selectedRecord]);\n const saveOrgMemberRoles = async () => {\n await handlePostRequest({\n endPointURI: \"api/v1/admin/organization/member/roles\",\n showMask: true,\n parameters: { orgMemberId: props.selectedRecord.id },\n data: selectedOptions,\n successCallBkFn: () => {\n toast.success(\"Your request has been proccesed successfully\");\n if (props.closeModalFn) {\n props.closeModalFn();\n }\n },\n });\n };\n return (\n <>\n <TransferList\n displayField=\"roleName\"\n options={availableOptions}\n valueField=\"id\"\n selectedOptions={selectedOptions}\n setSelection={setSelectedOptions}\n />\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n }}\n >\n <Button\n variant=\"contained\"\n onClick={saveOrgMemberRoles}\n sx={{ marginRight: 1, marginLeft: 1 }}\n >\n Save\n </Button>\n <Button variant=\"contained\" color=\"error\" onClick={props.closeModalFn}>\n Cancel\n </Button>\n </Box>\n </>\n );\n};\n\nexport default OrgMemberRoleForm;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useWindow } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useSelector } from \"react-redux\";\nimport OrgMemberRoleForm from \"./OrgMemberRoleForm\";\n\ntype OrganizationMemberGridProps = {\n selectedPerson: any;\n};\nconst OrganizationMemberGrid: React.FC<OrganizationMemberGridProps> = (\n props\n) => {\n const [selectedRecord, setSelectedRecord] = useState<any>(null);\n const {\n Window: OrganizationMemberRolesWindow,\n setWindowState: setOrganizationMemberRolesWindowState,\n } = useWindow({\n windowIcon: \"tag\",\n windowTitle: \"Organization Member Roles\",\n width: \"50%\",\n });\n const SystemOrganizations = useSelector(\n (state: any) => state.commonStores.stores.SystemOrganizations.data\n );\n const SystemOrganizationRanks = useSelector(\n (state: any) => state.commonStores.stores.SystemOrganizationRanks.data\n );\n const SystemOrganizationUnits = useSelector(\n (state: any) => state.commonStores.stores.SystemOrganizationUnits.data\n );\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/admin/organizationmember/all\",\n deleteById: \"api/v1/admin/organizationmember\",\n save: \"api/v1/admin/organizationmember\",\n findById: \"api/v1/admin/organizationmember\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_MEMBER_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_MEMBER_IS_DEFAULT\",\n fieldName: \"isDefault\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_MEMBER_ORGANIZATION_ID\",\n fieldName: \"organizationId\",\n required: true,\n fieldType: \"combobox\",\n options: SystemOrganizations,\n optionValueField: \"id\",\n optionDisplayField: \"organizationEnName\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_MEMBER_ORGANIZATION_RANK_ID\",\n fieldName: \"organizationRankId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemOrganizationRanks,\n optionValueField: \"id\",\n optionDisplayField: \"rankDisplay\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_MEMBER_ORGANIZATION_UNIT_ID\",\n fieldName: \"organizationUnitId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemOrganizationUnits,\n optionValueField: \"id\",\n optionDisplayField: \"fullPath\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Membership number\",\n fieldName: \"organizationMembershipNumber\",\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n hidden: true,\n gridProps: {\n hidden: true,\n },\n fieldLabel: \"ORGANIZATION_MEMBER_PERSON_ID\",\n fieldName: \"personId\",\n required: false,\n fieldType: \"number\",\n },\n },\n ];\n\n return (\n <>\n <OrganizationMemberRolesWindow>\n <OrgMemberRoleForm\n selectedRecord={selectedRecord}\n closeModalFn={() => {\n setOrganizationMemberRolesWindowState(false);\n }}\n />\n </OrganizationMemberRolesWindow>\n <TemplateGrid\n apiActions={apiActions}\n hideInfoBar={true}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n rowActions={[\n {\n icon: \"tag\",\n label: \"Roles\",\n actionFn: async (data) => {\n setSelectedRecord(data);\n setOrganizationMemberRolesWindowState(true);\n },\n },\n ]}\n gridLoadParametersValues={{ personId: props.selectedPerson.id }}\n keyColumnName={\"id\"}\n gridTitle=\"ORGANIZATION_MEMBER_PLURAL\"\n girdIcon=\"table-cells\"\n editAction={{\n isEnabled: true,\n authority: \"ORGANIZATION_MEMBER_EDIT\",\n preActionValidation: async (data) => {\n data.personId = props.selectedPerson.id;\n return true;\n },\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"ORGANIZATION_MEMBER_DELETE\",\n }}\n />\n </>\n );\n};\n\nexport default OrganizationMemberGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useAxios } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { setStoreData } from \"../../../redux/features/common/CommonStoreSlice\";\n\nconst OrganizationRankGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"CurrentOrganizationRanks\",\n deleteById: \"api/v1/admin/organizationrank\",\n save: \"api/v1/admin/organizationrank\",\n findById: \"api/v1/admin/organizationrank\",\n setData: setData,\n });\n\n const { handleGetRequest } = useAxios();\n const SystemOrganizationRanks = useSelector(\n (state: any) => state.commonStores.stores.SystemOrganizationRanks\n );\n const dispatch = useDispatch();\n const loadOrganizationRanks = async () => {\n await handleGetRequest({\n endPointURI: SystemOrganizationRanks.url,\n showMask: false,\n successCallBkFn: (response) => {\n dispatch(\n setStoreData({\n storeKey: \"SystemOrganizationRanks\",\n data: response.data,\n })\n );\n },\n failureCallBkFn: () => {\n dispatch(\n setStoreData({ storeKey: \"SystemOrganizationRanks\", data: [] })\n );\n },\n });\n };\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n hidden: true,\n gridProps: { hidden: true },\n fieldLabel: \"ORGANIZATION_RANK_ORGANIZATION_ID\",\n fieldName: \"organizationId\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_RANK_RANK_ORDER\",\n fieldName: \"rankOrder\",\n required: true,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_RANK_RANK_CODE\",\n fieldName: \"rankCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_RANK_RANK_AR_NAME\",\n fieldName: \"rankArName\",\n required: true,\n fieldType: \"text\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_RANK_RANK_EN_NAME\",\n fieldName: \"rankEnName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_RANK_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n setData={setData}\n editMode={{ editMode: \"row\", reloadAfterSave: true }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"ORGANIZATION_RANK_PLURAL\"\n girdIcon=\"street-view\"\n editAction={{\n isEnabled: true,\n authority: \"ORGANIZATION_RANK_EDIT\",\n postActionCallBack: () => {\n loadOrganizationRanks();\n },\n }}\n deleteAction={{ isEnabled: true, authority: \"ORGANIZATION_RANK_DELETE\" }}\n />\n );\n};\n\nexport default OrganizationRankGrid;\n","import { useEffect, useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useAxios } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { setStoreData } from \"../../../redux/features/common/CommonStoreSlice\";\n\nconst OrganizationUnitGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const { handleGetRequest } = useAxios();\n const SystemOrganizationUnits = useSelector(\n (state: any) => state.commonStores.stores.SystemOrganizationUnits\n );\n const dispatch = useDispatch();\n const loadOrganizationUnits = async () => {\n await handleGetRequest({\n endPointURI: SystemOrganizationUnits.url,\n showMask: false,\n successCallBkFn: (response) => {\n dispatch(\n setStoreData({\n storeKey: \"SystemOrganizationUnits\",\n data: response.data,\n })\n );\n },\n failureCallBkFn: () => {\n dispatch(\n setStoreData({ storeKey: \"SystemOrganizationUnits\", data: [] })\n );\n },\n });\n };\n const apiActions = useApiActions({\n findAll: \"api/v1/public/organizationunit/all\",\n deleteById: \"api/v1/admin/organizationunit\",\n save: \"api/v1/admin/organizationunit\",\n findById: \"api/v1/admin/organizationunit\",\n setData: setData,\n });\n\n const organizationUnitTypes = useSelector(\n (state: any) => state.commonStores.stores.SystemOrganizationUnitType.data\n );\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n hidden: true,\n gridProps: { hidden: true },\n fieldLabel: \"ORGANIZATION_UNIT_ORGANIZATION_ID\",\n fieldName: \"organizationId\",\n required: false,\n fieldType: \"number\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_ORGANIZATION_UNIT_TYPE_ID\",\n fieldName: \"organizationUnitTypeId\",\n required: true,\n fieldType: \"combobox\",\n options: organizationUnitTypes,\n optionValueField: \"id\",\n optionDisplayField: \"unitTypeEnName\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_ORGANIZATION_UNIT_AR_NAME\",\n fieldName: \"organizationUnitArName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_ORGANIZATION_UNIT_EN_NAME\",\n fieldName: \"organizationUnitEnName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_ORGANIZATION_UNIT_PARENT_ID\",\n fieldName: \"organizationUnitParentId\",\n required: false,\n fieldType: \"combobox\",\n options: data,\n optionValueField: \"id\",\n optionDisplayField: \"organizationUnitEnName\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"ORGANIZATION_UNIT_PLURAL\"\n girdIcon=\"folder-tree\"\n editAction={{\n isEnabled: true,\n authority: \"ORGANIZATION_UNIT_EDIT\",\n postActionCallBack: () => {\n loadOrganizationUnits();\n },\n }}\n deleteAction={{ isEnabled: true, authority: \"ORGANIZATION_UNIT_DELETE\" }}\n />\n );\n};\n\nexport default OrganizationUnitGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\n\nconst OrganizationUnitTypeGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"SystemOrganizationUnitType\",\n deleteById: \"api/v1/admin/organizationunittype\",\n save: \"api/v1/admin/organizationunittype\",\n findById: \"api/v1/admin/organizationunittype\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_TYPE_ORGANIZATION_ID\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n fieldName: \"organizationId\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_TYPE_ORGANIZATION_UNIT_TYPE_ORDER\",\n fieldName: \"organizationUnitTypeOrder\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_TYPE_UNIT_TYPE_CODE\",\n fieldName: \"unitTypeCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_TYPE_UNIT_TYPE_AR_NAME\",\n fieldName: \"unitTypeArName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_TYPE_UNIT_TYPE_EN_NAME\",\n fieldName: \"unitTypeEnName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_TYPE_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n setData={setData}\n editMode={{ editMode: \"row\", reloadAfterSave: true }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"ORGANIZATION_UNIT_TYPE_PLURAL\"\n girdIcon=\"tags\"\n editAction={{\n isEnabled: true,\n authority: \"ORGANIZATION_UNIT_TYPE_EDIT\",\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"ORGANIZATION_UNIT_TYPE_DELETE\",\n }}\n />\n );\n};\n\nexport default OrganizationUnitTypeGrid;\n","import { useEffect, useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useAxios } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useSelector } from \"react-redux\";\n\nconst SystemApplicationAuthorityGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"SystemApplicationAuthorities\",\n deleteById: \"api/v1/admin/systemapplicationauthority\",\n save: \"api/v1/admin/systemapplicationauthority\",\n findById: \"api/v1/admin/systemapplicationauthority\",\n setData: setData,\n });\n\n const SystemApplicationModules = useSelector(\n (state: any) => state.commonStores.stores.SystemApplicationModules.data\n );\n const { handleGetRequest } = useAxios();\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_AUTHORITY_SYSTEM_APPLICATION_ID\",\n fieldName: \"systemApplicationId\",\n required: false,\n hidden: true,\n gridProps: { hidden: true },\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_AUTHORITY_SYSTEM_MODULE_ID\",\n fieldName: \"systemModuleId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemApplicationModules,\n optionValueField: \"id\",\n optionDisplayField: \"moduleName\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_AUTHORITY_AUTHORITY_NAME\",\n fieldName: \"authorityName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_AUTHORITY_AUTHORITY_CODE\",\n fieldName: \"authorityCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_AUTHORITY_AUTHORITY_DESCRIPTION\",\n fieldName: \"authorityDescription\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_AUTHORITY_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"SYSTEM_APPLICATION_AUTHORITY_PLURAL\"\n girdIcon=\"key\"\n editAction={{\n isEnabled: true,\n authority: \"SYSTEM_APPLICATION_AUTHORITY_EDIT\",\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"SYSTEM_APPLICATION_AUTHORITY_DELETE\",\n }}\n />\n );\n};\n\nexport default SystemApplicationAuthorityGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\n\nconst SystemApplicationModuleGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"SystemApplicationModules\",\n deleteById: \"api/v1/admin/systemapplicationmodule\",\n save: \"api/v1/admin/systemapplicationmodule\",\n findById: \"api/v1/admin/systemapplicationmodule\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_MODULE_MODULE_CODE\",\n fieldName: \"moduleCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_MODULE_MODULE_NAME\",\n fieldName: \"moduleName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_MODULE_MODULE_DESCRIPTION\",\n fieldName: \"moduleDescription\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_MODULE_SYSTEM_APPLICATION_ID\",\n fieldName: \"systemApplicationId\",\n hidden: true,\n gridProps: { hidden: true },\n required: false,\n fieldType: \"text\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\", reloadAfterSave: true }}\n formElements={formElements}\n keyColumnName={\"id\"}\n hideInfoBar={true}\n gridTitle=\"SYSTEM_APPLICATION_MODULE_PLURAL\"\n girdIcon=\"layer-group\"\n editAction={{\n isEnabled: true,\n authority: \"SYSTEM_APPLICATION_MODULE_EDIT\",\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"SYSTEM_APPLICATION_MODULE_DELETE\",\n }}\n />\n );\n};\n\nexport default SystemApplicationModuleGrid;\n","import { useEffect, useState } from \"react\";\nimport TransferList from \"../../templates/TransferList\";\nimport { Box, Button } from \"@mui/material\";\nimport { toast } from \"react-toastify\";\nimport { useAxios } from \"../../../hooks\";\n\ntype RoleAuthoritiesFormProps = {\n roleId: number;\n closeModalFn: () => void;\n};\n\nconst RoleAuthoritiesForm: React.FC<RoleAuthoritiesFormProps> = (props) => {\n const [selectedOptions, setSelectedOptions] = useState([]);\n const [availableAuthorities, setAvailableAuthorities] = useState([]);\n const { handlePostRequest, handleGetRequest } = useAxios();\n\n const getRoleAuthorities = async () => {\n await handleGetRequest({\n endPointURI: \"api/v1/admin/systemApplicationRoleAuthorities\",\n showMask: true,\n parameters: {\n roleId: props.roleId,\n },\n successCallBkFn: (response: any) => {\n setSelectedOptions(response.data.selectedAuthorities);\n setAvailableAuthorities(response.data.availableAuthorities);\n },\n });\n };\n\n useEffect(() => {\n if (props.roleId) {\n getRoleAuthorities();\n }\n }, [props.roleId]);\n const saveRoleAuthorities = async () => {\n await handlePostRequest({\n endPointURI: \"api/v1/admin/systemApplicationRoleAuthorities\",\n showMask: true,\n parameters: { roleId: props.roleId },\n data: selectedOptions,\n successCallBkFn: () => {\n toast.success(\"Your request has been proccesed successfully\");\n if (props.closeModalFn) {\n props.closeModalFn();\n }\n },\n });\n };\n return (\n <>\n <TransferList\n displayField=\"authorityName\"\n options={availableAuthorities}\n valueField=\"id\"\n selectedOptions={selectedOptions}\n setSelection={setSelectedOptions}\n />\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n }}\n >\n <Button\n variant=\"contained\"\n onClick={saveRoleAuthorities}\n sx={{ marginRight: 1, marginLeft: 1 }}\n >\n Save\n </Button>\n <Button variant=\"contained\" color=\"error\" onClick={props.closeModalFn}>\n Cancel\n </Button>\n </Box>\n </>\n );\n};\n\nexport default RoleAuthoritiesForm;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useWindow } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport RoleAuthoritiesForm from \"./RoleAuthoritiesForm\";\n\nconst SystemApplicationRoleGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const [selectedRole, setSelectedRole] = useState(null);\n const {\n Window: RoleaAuthoritiesWindow,\n setWindowState: setRoleAuthoritiesWindowState,\n } = useWindow({\n windowTitle: \"System Application Role Authorities\",\n windowIcon: \"key\",\n width: \"50%\",\n });\n const apiActions = useApiActions({\n commonStoreKey: \"SystemApplicationRoles\",\n deleteById: \"api/v1/admin/systemapplicationrole\",\n save: \"api/v1/admin/systemapplicationrole\",\n findById: \"api/v1/admin/systemapplicationrole\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_ROLE_SYSTEM_APPLICATION_ID\",\n fieldName: \"systemApplicationId\",\n required: false,\n hidden: true,\n gridProps: { hidden: true },\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_ROLE_ROLE_NAME\",\n fieldName: \"roleName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_ROLE_ROLE_DESCRIPTION\",\n fieldName: \"roleDescription\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_ROLE_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <>\n <RoleaAuthoritiesWindow>\n <RoleAuthoritiesForm\n roleId={selectedRole?.id}\n closeModalFn={() => {\n setRoleAuthoritiesWindowState(false);\n }}\n />\n </RoleaAuthoritiesWindow>\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n setData={setData}\n editMode={{ editMode: \"row\", reloadAfterSave: true }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"SYSTEM_APPLICATION_ROLE_PLURAL\"\n girdIcon=\"tag\"\n rowActions={[\n {\n icon: \"key\",\n actionFn: async (data) => {\n setSelectedRole(data);\n setRoleAuthoritiesWindowState(true);\n },\n label: \"Authorities\",\n },\n ]}\n editAction={{\n isEnabled: true,\n authority: \"SYSTEM_APPLICATION_ROLE_EDIT\",\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"SYSTEM_APPLICATION_ROLE_DELETE\",\n }}\n />\n </>\n );\n};\n\nexport default SystemApplicationRoleGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\n\ntype DataQueryParameterGridProps = {\n selectedRecord: any;\n};\n\nconst DataQueryParameterGrid: React.FC<DataQueryParameterGridProps> = (\n props\n) => {\n const SystemEntityParameters = useSelector(\n (state: any) => state.commonStores.stores.SystemEntityParameters.data\n );\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/dataqueryparameter/all\",\n deleteById: \"api/v1/dev/dataqueryparameter\",\n save: \"api/v1/dev/dataqueryparameter\",\n findById: \"api/v1/dev/dataqueryparameter\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_PARAMETER_DATA_QUERY_ID\",\n fieldName: \"dataQueryId\",\n required: false,\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_PARAMETER_ENTITY_PARAMETER_ID\",\n fieldName: \"entityParameterId\",\n required: true,\n fieldType: \"combobox\",\n options: SystemEntityParameters,\n optionValueField: \"id\",\n optionDisplayField: \"parameterCode\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_PARAMETER_DEFAULT_VALUE\",\n fieldName: \"defaultValue\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_PARAMETER_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_PARAMETER_HIDDEN\",\n fieldName: \"hidden\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_PARAMETER_MANDATORY\",\n fieldName: \"mandatory\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n hideInfoBar={true}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridLoadParametersValues={{ dataQueryId: props.selectedRecord.id }}\n gridTitle={t(\"DATA_QUERY_PARAMETER_PLURAL\")}\n girdIcon=\"table-cells\"\n editAction={{\n isEnabled: true,\n authority: \"DATA_QUERY_PARAMETER_EDIT\",\n preActionValidation: async (data) => {\n data.dataQueryId = props.selectedRecord.id;\n return true;\n },\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"DATA_QUERY_PARAMETER_DELETE\",\n }}\n />\n );\n};\n\nexport default DataQueryParameterGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\n\nconst LookupGrid: React.FC = () => {\n const SystemOrganizations = useSelector(\n (state: any) => state.commonStores.stores.SystemOrganizations.data\n );\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/lookup/all\",\n deleteById: \"api/v1/dev/lookup\",\n save: \"api/v1/dev/lookup\",\n findById: \"api/v1/dev/lookup\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Organization\",\n fieldName: \"organizationId\",\n options: SystemOrganizations,\n optionDisplayField: \"organizationEnName\",\n optionValueField: \"id\",\n required: false,\n fieldType: \"combobox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"LOOKUP_LOOKUP_TYPE\",\n fieldName: \"lookupType\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"LOOKUP_LOOKUP_AR_DISPLAY\",\n fieldName: \"lookupArDisplay\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"LOOKUP_LOOKUP_EN_DISPLAY\",\n fieldName: \"lookupEnDisplay\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"LOOKUP_LOOKUP_VALUE\",\n fieldName: \"lookupValue\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"LOOKUP_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"System Application\",\n fieldName: \"systemApplicationId\",\n hidden: true,\n gridProps: { hidden: true },\n required: false,\n fieldType: \"number\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n hideInfoBar={true}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"LOOKUP_PLURAL\")}\n girdIcon=\"list-check\"\n editAction={{\n isEnabled: true,\n authority: \"LOOKUP_EDIT\",\n }}\n deleteAction={{ isEnabled: true, authority: \"LOOKUP_DELETE\" }}\n />\n );\n};\n\nexport default LookupGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\n\ntype ReportParameterGridProps = {\n selectedRecord: any;\n};\n\nconst ReportParameterGrid: React.FC<ReportParameterGridProps> = (props) => {\n const { t } = useTranslation();\n const SystemEntityParameters = useSelector(\n (state: any) => state.commonStores.stores.SystemEntityParameters.data\n );\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/reportparameter/all\",\n deleteById: \"api/v1/dev/reportparameter\",\n save: \"api/v1/dev/reportparameter\",\n findById: \"api/v1/dev/reportparameter\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_PARAMETER_ENTITY_PARAMETER_ID\",\n fieldName: \"entityParameterId\",\n required: true,\n fieldType: \"combobox\",\n options: SystemEntityParameters,\n optionValueField: \"id\",\n optionDisplayField: \"parameterCode\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_PARAMETER_DEFAULT_VALUE\",\n fieldName: \"defaultValue\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_PARAMETER_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_PARAMETER_HIDDEN\",\n fieldName: \"hidden\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_PARAMETER_MANDATORY\",\n fieldName: \"mandatory\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_PARAMETER_REPORT_ID\",\n fieldName: \"reportId\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"number\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n setData={setData}\n gridLoadParametersValues={{ reportId: props.selectedRecord.id }}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"REPORT_PARAMETER_PLURAL\")}\n girdIcon=\"p\"\n editAction={{\n isEnabled: true,\n authority: \"REPORT_PARAMETER_EDIT\",\n preActionValidation: async (data) => {\n data.reportId = props.selectedRecord.id;\n return true;\n },\n }}\n deleteAction={{ isEnabled: true, authority: \"REPORT_PARAMETER_DELETE\" }}\n />\n );\n};\n\nexport default ReportParameterGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\n\nexport const storageTypes = [{ value: \"FILE_SYSTEM\" }, { value: \"SFTP\" }];\n\nconst AttachmentConfigGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/attachmentconfig/all\",\n deleteById: \"api/v1/dev/attachmentconfig\",\n save: \"api/v1/dev/attachmentconfig\",\n findById: \"api/v1/dev/attachmentconfig\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_ATTACHMENT_CODE\",\n fieldName: \"attachmentCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_RELATED_DATABASE_TABLE\",\n fieldName: \"relatedDatabaseTable\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_STORAGE_TYPE\",\n fieldName: \"storageType\",\n required: true,\n fieldType: \"combobox\",\n comboboxValueDataType: \"string\",\n options: storageTypes,\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Include App Code in attachment path\",\n fieldName: \"includeAppCodeInPath\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_UPLOAD_DIRECTORY\",\n fieldName: \"uploadDirectory\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_ALLOWED_FILE_TYPES\",\n fieldName: \"allowedFileTypes\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_ATTACHMENT_CATEGORIES\",\n fieldName: \"attachmentCategories\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Is Category Mandatory\",\n fieldName: \"isCategoryRequired\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_MAX_ALLOWED_NUMBER_OF_FILES\",\n fieldName: \"maxAllowedNumberOfFiles\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_DOWNLOAD_AUTHORITY_KEY\",\n fieldName: \"downloadAuthorityKey\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_UPLOAD_AUTHORITY_KEY\",\n fieldName: \"uploadAuthorityKey\",\n required: false,\n fieldType: \"text\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalIcon: \"paperclip\",\n modalTitle: \"Attachment Configuration\",\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"ATTACHMENT_CONFIG_PLURAL\")}\n girdIcon=\"paperclip\"\n editAction={{ isEnabled: true, authority: \"ATTACHMENT_CONFIG_EDIT\" }}\n deleteAction={{ isEnabled: true, authority: \"ATTACHMENT_CONFIG_DELETE\" }}\n />\n );\n};\n\nexport default AttachmentConfigGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useWindow } from \"../../../hooks\";\nimport {\n FormElementProps,\n FormValueChangeCallBk,\n} from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { UseFormReturn } from \"react-hook-form\";\nimport { useSelector } from \"react-redux\";\nimport { toast } from \"react-toastify\";\nimport ReportParameterGrid from \"./ReportParameterGrid\";\nimport ReportViewer from \"../../templates/report/ReportViewer\";\nimport { storageTypes } from \"./AttachmentConfigGrid\";\n\nexport type ReportType = \"Jasper\" | \"Excel\" | \"Blueprint\";\n\nconst adjustFormAfterValueChange: FormValueChangeCallBk = (\n formValues,\n formActions,\n formManager,\n fieldName,\n newValue\n) => {\n if (fieldName) {\n if (fieldName === \"useSysDatasource\" && newValue == true) {\n formActions.hideField(\"datasourceConId\");\n formManager.setValue(\"datasourceConId\", null);\n } else {\n formActions.showField(\"datasourceConId\");\n }\n\n if (fieldName === \"reportType\") {\n if (newValue === \"Blueprint\") {\n formActions.hideField(\"storageType\");\n formActions.hideField(\"includeAppCodeInPath\");\n formActions.hideField(\"useSysDatasource\");\n formActions.hideField(\"datasourceConId\");\n formActions.hideField(\"reportExcelDataQueryId\");\n formActions.hideField(\"reportJasperName\");\n formActions.showField(\"reportBluePrintId\");\n } else if (newValue === \"Jasper\") {\n formActions.showField(\"storageType\");\n formActions.showField(\"includeAppCodeInPath\");\n formActions.showField(\"useSysDatasource\");\n formActions.showField(\"datasourceConId\");\n formActions.hideField(\"reportExcelDataQueryId\");\n formActions.showField(\"reportJasperName\");\n formActions.hideField(\"reportBluePrintId\");\n } else if (newValue === \"Excel\") {\n formActions.hideField(\"storageType\");\n formActions.hideField(\"includeAppCodeInPath\");\n formActions.hideField(\"useSysDatasource\");\n formActions.hideField(\"datasourceConId\");\n formActions.showField(\"reportExcelDataQueryId\");\n formActions.hideField(\"reportJasperName\");\n formActions.hideField(\"reportBluePrintId\");\n } else {\n formActions.hideField(\"storageType\");\n formActions.hideField(\"includeAppCodeInPath\");\n formActions.hideField(\"useSysDatasource\");\n formActions.hideField(\"datasourceConId\");\n formActions.hideField(\"reportExcelDataQueryId\");\n formActions.hideField(\"reportJasperName\");\n formActions.hideField(\"reportBluePrintId\");\n }\n }\n } else {\n if (formValues?.useSysCon) {\n formActions.hideField(\"datasourceConId\");\n }\n if (formValues?.reportType) {\n if (formValues?.reportType === \"Blueprint\") {\n formActions.hideField(\"storageType\");\n formActions.hideField(\"includeAppCodeInPath\");\n formActions.hideField(\"useSysDatasource\");\n formActions.hideField(\"datasourceConId\");\n formActions.hideField(\"reportExcelDataQueryId\");\n formActions.hideField(\"reportJasperName\");\n formActions.showField(\"reportBluePrintId\");\n } else if (formValues?.reportType === \"Jasper\") {\n formActions.showField(\"storageType\");\n formActions.showField(\"includeAppCodeInPath\");\n formActions.showField(\"useSysDatasource\");\n formActions.showField(\"datasourceConId\");\n formActions.hideField(\"reportExcelDataQueryId\");\n formActions.showField(\"reportJasperName\");\n formActions.hideField(\"reportBluePrintId\");\n } else if (formValues?.reportType === \"Excel\") {\n formActions.hideField(\"storageType\");\n formActions.hideField(\"includeAppCodeInPath\");\n formActions.hideField(\"useSysDatasource\");\n formActions.hideField(\"datasourceConId\");\n formActions.showField(\"reportExcelDataQueryId\");\n formActions.hideField(\"reportJasperName\");\n formActions.hideField(\"reportBluePrintId\");\n }\n } else {\n formActions.hideField(\"storageType\");\n formActions.hideField(\"includeAppCodeInPath\");\n formActions.hideField(\"useSysDatasource\");\n formActions.hideField(\"datasourceConId\");\n formActions.hideField(\"reportExcelDataQueryId\");\n formActions.hideField(\"reportJasperName\");\n formActions.hideField(\"reportBluePrintId\");\n }\n }\n};\n\nconst ReportGrid: React.FC = () => {\n const { t } = useTranslation();\n const [selectedRecord, setSelectedRecord] = useState(null);\n const {\n Window: ReporTrialWindow,\n setWindowState: setReportTrialWindowState,\n } = useWindow({\n windowTitle: \"Report View\",\n windowIcon: \"eye\",\n width: \"80%\",\n });\n const {\n Window: ReportParameterWindow,\n setWindowState: setReportParameterWindowState,\n } = useWindow({\n windowTitle: \"Report Parameters\",\n windowIcon: \"p\",\n width: \"80%\",\n });\n const [data, setData] = useState([]);\n const SystemDataSources = useSelector(\n (state: any) => state.commonStores.stores.SystemDataSources.data\n );\n const SystemDataQueries = useSelector(\n (state: any) => state.commonStores.stores.SystemDataQueries.data\n );\n const SystemBluePrints = useSelector(\n (state: any) => state.commonStores.stores.SystemBluePrints.data\n );\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/report/all\",\n deleteById: \"api/v1/dev/report\",\n save: \"api/v1/dev/report\",\n findById: \"api/v1/dev/report\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_REPORT_TYPE\",\n fieldName: \"reportType\",\n options: [\n { value: \"Excel\" },\n { value: \"Jasper\" },\n { value: \"Blueprint\" },\n ],\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n required: true,\n fieldType: \"combobox\",\n comboboxValueDataType: \"string\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_REPORT_CODE\",\n fieldName: \"reportCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_REPORT_NAME\",\n fieldName: \"reportName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_STORAGE_TYPE\",\n fieldName: \"storageType\",\n required: false,\n hidden: true,\n gridProps: {\n hidden: true,\n },\n comboboxValueDataType: \"string\",\n fieldType: \"combobox\",\n options: storageTypes,\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_REPORT_CATEGORY\",\n fieldName: \"reportCategory\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Authority Code\",\n fieldName: \"reportAuthorityCode\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_REPORT_EXPORT_NAME\",\n fieldName: \"reportExportName\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_USE_SYS_DATASOURCE\",\n fieldName: \"useSysDatasource\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_DATASOURCE_CON_ID\",\n fieldName: \"datasourceConId\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"combobox\",\n options: SystemDataSources,\n optionValueField: \"id\",\n optionDisplayField: \"connectionName\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_REPORT_BLUE_PRINT_ID\",\n fieldName: \"reportBluePrintId\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"combobox\",\n options: SystemBluePrints,\n optionDisplayField: \"bluePrintCode\",\n optionValueField: \"id\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_REPORT_EXCEL_DATA_QUERY_ID\",\n fieldName: \"reportExcelDataQueryId\",\n hidden: true,\n required: false,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionValueField: \"id\",\n optionDisplayField: \"queryName\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_REPORT_JASPER_NAME\",\n fieldName: \"reportJasperName\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Include App Code in attachment path\",\n fieldName: \"includeAppCodeInPath\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Active\",\n fieldName: \"isActive\",\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <>\n <ReporTrialWindow>\n <ReportViewer\n reportCode={selectedRecord?.reportCode}\n resultMode=\"App\"\n />\n </ReporTrialWindow>\n <ReportParameterWindow>\n <ReportParameterGrid selectedRecord={selectedRecord} />\n </ReportParameterWindow>\n <TemplateGrid\n attachment={{\n attachmentCode: \"JASPER_REPORTS\",\n enableAttachFn(record) {\n if (record?.reportType === \"Jasper\") {\n return true;\n } else {\n return false;\n }\n },\n }}\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalTitle: \"Report\",\n modalIcon: \"file\",\n modalWidth: 300,\n },\n }}\n rowActions={[\n {\n icon: \"p\",\n label: \"Report Parameters\",\n isActionVisibleForRecord: (record) => {\n return record.reportType === \"Jasper\";\n },\n actionFn: async (data, recordIdsToProcessActionOn) => {\n setSelectedRecord(data);\n setReportParameterWindowState(true);\n },\n },\n {\n icon: \"eye\",\n label: \"View Report\",\n actionFn: async (data, recordIdsToProcessActionOn) => {\n setSelectedRecord(data);\n setReportTrialWindowState(true);\n },\n },\n ]}\n formProps={{ formValuesChangeCallBk: adjustFormAfterValueChange }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"REPORT_PLURAL\")}\n girdIcon=\"table-cells\"\n editAction={{\n isEnabled: true,\n authority: \"REPORT_EDIT\",\n preActionValidation: (record) => {\n if (\n record?.reportType === \"Jasper\" &&\n record?.useSysDatasource === false &&\n !record?.datasourceConId\n ) {\n toast.error(\"You must choose the datasource\");\n return false;\n }\n if (record?.reportType === \"Jasper\" && !record?.reportJasperName) {\n toast.error(\"You must enter the jasper report name\");\n return false;\n }\n\n if (\n record?.reportType === \"Blueprint\" &&\n !record?.reportBluePrintId\n ) {\n toast.error(\"You must choose the report blueprint\");\n return false;\n }\n if (\n record?.reportType === \"Excel\" &&\n !record?.reportExcelDataQueryId\n ) {\n toast.error(\"You must choose the report query\");\n return false;\n }\n return true;\n },\n }}\n deleteAction={{ isEnabled: true, authority: \"REPORT_DELETE\" }}\n />\n </>\n );\n};\n\nexport default ReportGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { isValidEmail } from \"../../../util\";\nimport { toast } from \"react-toastify\";\n\ntype MailRecipientGridProps = {\n selectedRecord: any;\n callBkFn: () => void;\n};\n\nconst MailRecipientGrid: React.FC<MailRecipientGridProps> = (props) => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/mailrecipient/all\",\n deleteById: \"api/v1/dev/mailrecipient\",\n save: \"api/v1/dev/mailrecipient\",\n findById: \"api/v1/dev/mailrecipient\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_RECIPIENT_MAIL_TEMPLATE_ID\",\n fieldName: \"mailTemplateId\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_RECIPIENT_RECIPIENT_TYPE\",\n fieldName: \"recipientType\",\n required: true,\n fieldType: \"combobox\",\n options: [{ value: \"To\" }, { value: \"CC\" }],\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n comboboxValueDataType: \"string\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_RECIPIENT_RECIPIENT_MAIL\",\n fieldName: \"recipientMail\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_RECIPIENT_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n gridLoadParametersValues={{ mailTemplateId: props.selectedRecord.id }}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"MAIL_RECIPIENT_PLURAL\")}\n girdIcon=\"users\"\n editAction={{\n isEnabled: true,\n authority: \"MAIL_RECIPIENT_EDIT\",\n preActionValidation: (record) => {\n if (record?.recipientMail && !isValidEmail(record.recipientMail)) {\n toast.error(\"You must enter a valid email address\");\n return false;\n }\n record.mailTemplateId = props.selectedRecord.id;\n return true;\n },\n }}\n deleteAction={{ isEnabled: true, authority: \"MAIL_RECIPIENT_DELETE\" }}\n />\n );\n};\n\nexport default MailRecipientGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\n\ntype MailBodyGridProps = {\n selectedRecord: any;\n callBkFn: () => void;\n};\n\nconst MailBodyGrid: React.FC<MailBodyGridProps> = (props) => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const SystemDataQueries = useSelector(\n (state: any) => state.commonStores.stores.SystemDataQueries.data\n );\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/mailbody/all\",\n deleteById: \"api/v1/dev/mailbody\",\n save: \"api/v1/dev/mailbody\",\n findById: \"api/v1/dev/mailbody\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_BODY_BODY_NAME\",\n fieldName: \"bodyName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_BODY_BODY_ORDER\",\n fieldName: \"bodyOrder\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_BODY_BODY_CONTENT\",\n fieldName: \"bodyContent\",\n required: true,\n fieldType: \"text\",\n muiTextFieldProps: { multiline: true, rows: 6 },\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_BODY_BODY_CONTENT_DATA_QUERY_ID\",\n fieldName: \"bodyContentDataQueryId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionDisplayField: \"queryName\",\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_BODY_PRINT_FOR_EACH_RECORD\",\n fieldName: \"printForEachRecord\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_BODY_IS_MAIN\",\n fieldName: \"isMain\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_BODY_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_BODY_MAIL_TEMPLATE_ID\",\n fieldName: \"mailTemplateId\",\n required: false,\n hidden: true,\n gridProps: {\n hidden: true,\n },\n fieldType: \"number\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n gridLoadParametersValues={{ mailTemplateId: props.selectedRecord.id }}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalIcon: { prefix: \"fas\", iconName: \"envelope-open-text\" },\n modalTitle: \"Mail Body\",\n modalWidth: \"50%\",\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"MAIL_BODY_PLURAL\")}\n girdIcon={{ prefix: \"fas\", iconName: \"envelope-open-text\" }}\n editAction={{\n isEnabled: true,\n authority: \"MAIL_BODY_EDIT\",\n preActionValidation: async (record) => {\n record.mailTemplateId = props.selectedRecord.id;\n return true;\n },\n }}\n deleteAction={{ isEnabled: true, authority: \"MAIL_BODY_DELETE\" }}\n />\n );\n};\n\nexport default MailBodyGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\n\ntype MailAttachmentGridProps = {\n selectedRecord: any;\n callBkFn: () => void;\n};\n\nconst MailAttachmentGrid: React.FC<MailAttachmentGridProps> = (props) => {\n const SystemReports = useSelector(\n (state: any) => state.commonStores.stores.SystemReports.data\n );\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/mailattachment/all\",\n deleteById: \"api/v1/dev/mailattachment\",\n save: \"api/v1/dev/mailattachment\",\n findById: \"api/v1/dev/mailattachment\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n options: SystemReports,\n optionValueField: \"id\",\n optionDisplayField: \"reportName\",\n fieldLabel: \"REPORT_REPORT_NAME\",\n fieldName: \"reportId\",\n required: true,\n fieldType: \"combobox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_ATTACHMENT_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_ATTACHMENT_MAIL_TEMPLATE_ID\",\n fieldName: \"mailTemplateId\",\n required: false,\n hidden: true,\n gridProps: { hidden: true },\n fieldType: \"number\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n gridLoadParametersValues={{ mailTemplateId: props.selectedRecord.id }}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"MAIL_ATTACHMENT_PLURAL\")}\n girdIcon=\"paperclip\"\n editAction={{\n isEnabled: true,\n authority: \"MAIL_ATTACHMENT_EDIT\",\n preActionValidation: (record) => {\n record.mailTemplateId = props.selectedRecord.id;\n return true;\n },\n }}\n deleteAction={{ isEnabled: true, authority: \"MAIL_ATTACHMENT_DELETE\" }}\n />\n );\n};\n\nexport default MailAttachmentGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport {\n FormActionProps,\n FormElementProps,\n} from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { UseFormReturn } from \"react-hook-form\";\n\ntype ValidationCritria = {\n isVisible: boolean;\n isMandatory: boolean;\n};\n\nexport type EngineType = \"Gmail\" | \"Azure\";\n\ntype ReportValidationOptions = {\n mailHost: ValidationCritria;\n mailPort: ValidationCritria;\n mailUsername: ValidationCritria;\n mailPassword: ValidationCritria; \n mailProtocol: ValidationCritria;\n isMailSmtpAuthEnabled: ValidationCritria;\n isMailStarttlsEnabled: ValidationCritria;\n isSmtpSSlEnabled: ValidationCritria;\n azureGraphApiClientId: ValidationCritria;\n azureGraphApiClientSecret: ValidationCritria;\n azureGraphApiTenantId: ValidationCritria;\n azureGraphApiScope: ValidationCritria;\n azureGraphApiEmailId: ValidationCritria;\n};\n\ntype validationObjectType = {\n [key in EngineType]: ReportValidationOptions;\n};\n\nconst validationObject: validationObjectType = {\n Gmail: {\n mailHost: { isMandatory: true, isVisible: true },\n mailPort: { isMandatory: true, isVisible: true },\n mailUsername: { isMandatory: true, isVisible: true },\n mailPassword: { isMandatory: true, isVisible: true }, \n mailProtocol: { isMandatory: true, isVisible: true },\n isMailSmtpAuthEnabled: { isMandatory: true, isVisible: true },\n isMailStarttlsEnabled: { isMandatory: true, isVisible: true },\n isSmtpSSlEnabled: { isMandatory: true, isVisible: true },\n azureGraphApiClientId: { isMandatory: false, isVisible: false },\n azureGraphApiClientSecret: { isMandatory: false, isVisible: false },\n azureGraphApiTenantId: { isMandatory: false, isVisible: false },\n azureGraphApiScope: { isMandatory: false, isVisible: false },\n azureGraphApiEmailId: { isMandatory: false, isVisible: false },\n },\n Azure: {\n mailHost: { isMandatory: false, isVisible: false },\n mailPort: { isMandatory: false, isVisible: false },\n mailUsername: { isMandatory: false, isVisible: false },\n mailPassword: { isMandatory: false, isVisible: false }, \n mailProtocol: { isMandatory: false, isVisible: false },\n isMailSmtpAuthEnabled: { isMandatory: false, isVisible: false },\n isMailStarttlsEnabled: { isMandatory: false, isVisible: false },\n isSmtpSSlEnabled: { isMandatory: false, isVisible: false },\n azureGraphApiClientId: { isMandatory: true, isVisible: true },\n azureGraphApiClientSecret: { isMandatory: true, isVisible: true },\n azureGraphApiTenantId: { isMandatory: true, isVisible: true },\n azureGraphApiScope: { isMandatory: true, isVisible: true },\n azureGraphApiEmailId: { isMandatory: true, isVisible: true },\n },\n};\n\nconst adjustFormAccordingToEngineType = (\n value: any,\n formActions: FormActionProps,\n formManager: UseFormReturn\n) => {\n if (value && validationObject[value]) {\n const validationObjects: ReportValidationOptions = validationObject[value];\n const fields = Object.keys(validationObjects);\n for (const field of fields) {\n const validationCritria: ValidationCritria = validationObjects[field];\n if (validationCritria.isVisible) {\n formActions.showField(field);\n } else {\n formActions.hideField(field);\n formManager.setValue(field, null);\n }\n }\n } else {\n formActions.hideField(\"mailHost\");\n formManager.setValue(\"mailHost\", null);\n formActions.hideField(\"mailPort\");\n formManager.setValue(\"mailPort\", null);\n formActions.hideField(\"mailUsername\");\n formManager.setValue(\"mailUsername\", null);\n formActions.hideField(\"mailPassword\");\n formManager.setValue(\"mailPassword\", null); \n formActions.hideField(\"mailProtocol\");\n formManager.setValue(\"mailProtocol\", null);\n formActions.hideField(\"isMailSmtpAuthEnabled\");\n formManager.setValue(\"isMailSmtpAuthEnabled\", null);\n formActions.hideField(\"isMailStarttlsEnabled\");\n formManager.setValue(\"isMailStarttlsEnabled\", null);\n formActions.hideField(\"isSmtpSSlEnabled\");\n formManager.setValue(\"isSmtpSSlEnabled\", null);\n formActions.hideField(\"azureGraphApiClientId\");\n formManager.setValue(\"azureGraphApiClientId\", null);\n formActions.hideField(\"azureGraphApiClientSecret\");\n formManager.setValue(\"azureGraphApiClientSecret\", null);\n formActions.hideField(\"azureGraphApiTenantId\");\n formManager.setValue(\"azureGraphApiTenantId\", null);\n formActions.hideField(\"azureGraphApiScope\");\n formManager.setValue(\"azureGraphApiScope\", null);\n formActions.hideField(\"azureGraphApiEmailId\");\n formManager.setValue(\"azureGraphApiEmailId\", null);\n }\n};\n\nconst MailSenderConfigGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/mailsenderconfig/all\",\n deleteById: \"api/v1/dev/mailsenderconfig\",\n save: \"api/v1/dev/mailsenderconfig\",\n findById: \"api/v1/dev/mailsenderconfig\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Name\",\n fieldName: \"configName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Engine\",\n fieldName: \"mailEngine\",\n required: true,\n fieldType: \"combobox\",\n comboboxValueDataType: \"string\",\n options: [{ value: \"Gmail\" }, { value: \"Azure\" }],\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n formProps: {\n onValueChangeCallBack(\n formValues,\n value,\n formManager,\n formActions,\n selectedRecord\n ) {\n adjustFormAccordingToEngineType(value, formActions, formManager);\n },\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Hostname\",\n fieldName: \"mailHost\",\n required: false,\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"port\",\n fieldName: \"mailPort\",\n required: false,\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"username\",\n fieldName: \"mailUsername\",\n required: false,\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"password\",\n fieldName: \"mailPassword\",\n required: false,\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Workflow Approval Receive Email\",\n fieldName: \"workFlowApprovalReceiveEmail\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Protocol\",\n fieldName: \"mailProtocol\",\n required: false,\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Enable Smtp Auth\",\n fieldName: \"isMailSmtpAuthEnabled\",\n required: false,\n fieldType: \"checkbox\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Enable Start TLS\",\n fieldName: \"isMailStarttlsEnabled\",\n required: false,\n fieldType: \"checkbox\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Enable SSL\",\n fieldName: \"isSmtpSSlEnabled\",\n required: false,\n fieldType: \"checkbox\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Azure Graph API Client Id\",\n fieldName: \"azureGraphApiClientId\",\n required: false,\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Azure Graph API Secret\",\n fieldName: \"azureGraphApiClientSecret\",\n required: false,\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Azure Graph API Tenant Id\",\n fieldName: \"azureGraphApiTenantId\",\n required: false,\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Azure Graph API Scope\",\n fieldName: \"azureGraphApiScope\",\n required: false,\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Azure Graph API Email Id\",\n fieldName: \"azureGraphApiEmailId\",\n required: false,\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Default\",\n fieldName: \"isDefault\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Active\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalIcon: { iconName: \"paper-plane\", prefix: \"fas\" },\n modalTitle: \"Mail Sender Configuration\",\n modalWidth: 300,\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"Mail Sender Configuration\")}\n girdIcon={{ iconName: \"paper-plane\", prefix: \"fas\" }}\n editAction={{ isEnabled: true, authority: \"MAIL_SENDER_CONFIG_EDIT\" }}\n deleteAction={{ isEnabled: true, authority: \"MAIL_SENDER_CONFIG_DELETE\" }}\n formLoadCallBk={(\n formActions: FormActionProps,\n formManager: UseFormReturn,\n record: any\n ) => {\n adjustFormAccordingToEngineType(\n record.mailEngine,\n formActions,\n formManager\n );\n }}\n />\n );\n};\n\nexport default MailSenderConfigGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\n\ntype WorkflowDocumentStatusGridProps = {\n selectedRecord: any;\n};\n\nconst WorkflowDocumentStatusGrid: React.FC<WorkflowDocumentStatusGridProps> = (\n props\n) => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/workflowdocumentstatus/all\",\n deleteById: \"api/v1/dev/workflowdocumentstatus\",\n save: \"api/v1/dev/workflowdocumentstatus\",\n findById: \"api/v1/dev/workflowdocumentstatus\",\n setData: setData,\n });\n const SystemDataQueries = useSelector(\n (state: any) => state.commonStores.stores.SystemDataQueries.data\n );\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_STATUS_DOCUMENT_STATUS_CODE\",\n fieldName: \"documentStatusCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Status Arabic Name\",\n fieldName: \"documentStatusArName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Status English Name\",\n fieldName: \"documentStatusEnName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_STATUS_DOCUMENT_STATUS_ORDER\",\n fieldName: \"documentStatusOrder\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_STATUS_IS_ZERO_STATE\",\n fieldName: \"isZeroState\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"Next Actions Query (must return array of actions in table named workflow_document_action)\",\n fieldName: \"nextActionsQueryId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionValueField: \"id\",\n optionDisplayField: \"queryName\",\n gridProps: { hidden: true },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"Next Action Takers Query (must return array of persons in table named person)\",\n fieldName: \"nextActionTakersQueryId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionValueField: \"id\",\n optionDisplayField: \"queryName\",\n gridProps: { hidden: true },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Next Action Takers Authority\",\n fieldName: \"nextActionTakersAuthority\",\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_STATUS_WORKFLOW_DOCUMENT_ID\",\n fieldName: \"workflowDocumentId\",\n required: false,\n hidden: true,\n gridProps: { hidden: true },\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_STATUS_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n hideInfoBar={true}\n gridLoadParametersValues={{\n workflowDocumentId: props.selectedRecord.id,\n }}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalIcon: \"tag\",\n modalTitle: \"Workflow Document Status\",\n modalWidth: 600,\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"WORKFLOW_DOCUMENT_STATUS_PLURAL\")}\n girdIcon=\"tags\"\n editAction={{\n isEnabled: true,\n authority: \"WORKFLOW_DOCUMENT_STATUS_EDIT\",\n preActionValidation: (record) => {\n record.workflowDocumentId = props.selectedRecord.id;\n return true;\n },\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"WORKFLOW_DOCUMENT_STATUS_DELETE\",\n }}\n />\n );\n};\n\nexport default WorkflowDocumentStatusGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\n\ntype WorkflowDocumentActionMailGridProps = {\n selectedRecord: any;\n};\n\nconst WorkflowDocumentActionMailGrid: React.FC<\n WorkflowDocumentActionMailGridProps\n> = (props) => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/workflowdocumentactionmail/all\",\n deleteById: \"api/v1/dev/workflowdocumentactionmail\",\n save: \"api/v1/dev/workflowdocumentactionmail\",\n findById: \"api/v1/dev/workflowdocumentactionmail\",\n setData: setData,\n });\n\n const SystemMailTemplates = useSelector(\n (state: any) => state.commonStores.stores.SystemMailTemplates.data\n );\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_ACTION_MAIL_DOCUMENT_ACTION_ID\",\n fieldName: \"documentActionId\",\n required: false,\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_ACTION_MAIL_MAIL_TEMPLATE_ID\",\n fieldName: \"mailTemplateId\",\n required: true,\n fieldType: \"combobox\",\n options: SystemMailTemplates,\n optionDisplayField: \"mailTemplateName\",\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_ACTION_MAIL_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n gridLoadParametersValues={{ actionId: props.selectedRecord.id }}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"WORKFLOW_DOCUMENT_ACTION_MAIL_PLURAL\")}\n girdIcon=\"table-cells\"\n editAction={{\n isEnabled: true,\n authority: \"WORKFLOW_DOCUMENT_ACTION_MAIL_EDIT\",\n preActionValidation: (record) => {\n record.documentActionId = props.selectedRecord.id;\n return true;\n },\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"WORKFLOW_DOCUMENT_ACTION_MAIL_DELETE\",\n }}\n />\n );\n};\n\nexport default WorkflowDocumentActionMailGrid;\n","import { useEffect, useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions, useAxios, useWindow } from \"../../../hooks\";\nimport WorkflowDocumentActionMailGrid from \"./WorkflowDocumentActionMailGrid\";\n\ntype WorkflowDocumentActionGridProps = {\n selectedRecord: any;\n};\n\nconst WorkflowDocumentActionGrid: React.FC<WorkflowDocumentActionGridProps> = (\n props\n) => {\n const [selectedRecord, setSelectedRecord] = useState<any>(null);\n const {\n Window: ActionMailsWindow,\n setWindowState: setActionMailWindowState,\n } = useWindow({\n windowTitle: \"Action Mail Notification\",\n windowIcon: \"envelope\",\n width: \"50%\",\n });\n const { t } = useTranslation();\n const { handleGetRequest } = useAxios();\n const [workflowStates, setWorkflowStates] = useState<Array<any>>([]);\n const loadWorkFlowDocumentStates = async () => {\n await handleGetRequest({\n endPointURI: \"api/v1/dev/workflowdocumentstatus/all\",\n showMask: true,\n parameters: {\n workflowDocumentId: props.selectedRecord.id,\n },\n successCallBkFn: (response: any) => {\n setWorkflowStates(response.data);\n },\n });\n };\n useEffect(() => {\n loadWorkFlowDocumentStates();\n }, [props.selectedRecord]);\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/workflowdocumentaction/all\",\n deleteById: \"api/v1/dev/workflowdocumentaction\",\n save: \"api/v1/dev/workflowdocumentaction\",\n findById: \"api/v1/dev/workflowdocumentaction\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_ACTION_DOCUMENT_ACTION_CODE\",\n fieldName: \"documentActionCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Action Arabic Name\",\n fieldName: \"documentActionArName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Action English Name\",\n fieldName: \"documentActionEnName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_ACTION_NEXT_DOCUMENT_STATUS_ID\",\n fieldName: \"nextDocumentStatusId\",\n required: true,\n fieldType: \"combobox\",\n options: workflowStates,\n optionDisplayField: \"documentStatusCode\",\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"Post Action Endpoint ( system will call it with post method and parameters refDocumentId , workflowActionId)\",\n fieldName: \"postActionEndpoint\",\n required: false,\n fieldType: \"text\",\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"Pre Action Endpoint ( system will call it with post method and parameters refDocumentId , workflowActionId)\",\n fieldName: \"preActionEndpoint\",\n required: false,\n fieldType: \"text\",\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_ACTION_REQUIRE_COMMENT\",\n fieldName: \"requireComment\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_ACTION_WORKFLOW_DOCUMENT_ID\",\n fieldName: \"workflowDocumentId\",\n required: false,\n fieldType: \"number\",\n hidden: true,\n gridProps: { hidden: true },\n },\n },\n ];\n\n return (\n <>\n <ActionMailsWindow>\n <WorkflowDocumentActionMailGrid selectedRecord={selectedRecord} />\n </ActionMailsWindow>\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n gridLoadParametersValues={{\n workflowDocumentId: props.selectedRecord.id,\n }}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalIcon: \"stamp\",\n modalTitle: \"Workflow Document Action\",\n modalWidth: 700,\n },\n }}\n rowActions={[\n {\n label: \"Action Mail Notifications\",\n icon: \"envelope\",\n actionFn: async (data) => {\n setSelectedRecord(data);\n setActionMailWindowState(true);\n },\n },\n ]}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"WORKFLOW_DOCUMENT_ACTION_PLURAL\")}\n girdIcon=\"stamp\"\n editAction={{\n isEnabled: true,\n authority: \"WORKFLOW_DOCUMENT_ACTION_EDIT\",\n preActionValidation: (record) => {\n record.workflowDocumentId = props.selectedRecord.id;\n return true;\n },\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"WORKFLOW_DOCUMENT_ACTION_DELETE\",\n }}\n />\n </>\n );\n};\n\nexport default WorkflowDocumentActionGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\n\ntype DashboardWidgetGridProps = {\n selectedRecord: any;\n};\n\nconst DashboardWidgetGrid: React.FC<DashboardWidgetGridProps> = (props) => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const SystemWidgets = useSelector(\n (state: any) => state.commonStores.stores.SystemWidgets.data\n );\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/dashboardwidget/all\",\n deleteById: \"api/v1/dev/dashboardwidget\",\n save: \"api/v1/dev/dashboardwidget\",\n findById: \"api/v1/dev/dashboardwidget\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DASHBOARD_WIDGET_DASHBOARD_ID\",\n fieldName: \"dashboardId\",\n required: false,\n hidden: true,\n gridProps: { hidden: true },\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DASHBOARD_WIDGET_WIDGET_ID\",\n fieldName: \"widgetId\",\n required: true,\n fieldType: \"combobox\",\n options: SystemWidgets,\n optionValueField: \"id\",\n optionDisplayField: \"widgetName\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DASHBOARD_WIDGET_WIDGET_ORDER\",\n fieldName: \"widgetOrder\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DASHBOARD_WIDGET_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n hideInfoBar={true}\n formElements={formElements}\n gridLoadParametersValues={{ dashboardId: props.selectedRecord.id }}\n keyColumnName={\"id\"}\n gridTitle={t(\"DASHBOARD_WIDGET_PLURAL\")}\n girdIcon=\"table-cells\"\n editAction={{\n isEnabled: true,\n authority: \"DASHBOARD_WIDGET_EDIT\",\n preActionValidation: async (data) => {\n data.dashboardId = props.selectedRecord.id;\n return true;\n },\n }}\n deleteAction={{ isEnabled: true, authority: \"DASHBOARD_WIDGET_DELETE\" }}\n />\n );\n};\n\nexport default DashboardWidgetGrid;\n","\nimport { ADMINISTRATION_ROUTES } from \"./administration\";\nimport { SystemRoute } from \"./types\";\n\nexport const SYSTEM_ROUTES: Array<SystemRoute> = [...ADMINISTRATION_ROUTES];\n","import { SystemRoute } from \"../types\";\nimport { adminRoutes } from \"./adminRoutes\";\nimport { devRoutes } from \"./devRoutes\";\n\nexport const ADMINISTRATION_ROUTES: Array<SystemRoute> = [\n ...adminRoutes,\n ...devRoutes,\n];\n","import { SystemRoute } from \"../types\";\nimport OrganizationGrid from \"../../components/administration/admin/OrganizationGrid\";\nimport OrganizationMemberGrid from \"../../components/administration/admin/OrganizationMemberGrid\";\nimport OrganizationMemberRoleGrid from \"../../components/administration/admin/OrganizationMemberRoleGrid\";\nimport OrganizationRankGrid from \"../../components/administration/admin/OrganizationRankGrid\";\nimport OrganizationUnitGrid from \"../../components/administration/admin/OrganizationUnitGrid\";\nimport OrganizationUnitTypeGrid from \"../../components/administration/admin/OrganizationUnitTypeGrid\";\nimport PersonGrid from \"../../components/administration/admin/PersonGrid\";\nimport SystemApplicationGrid from \"../../components/administration/admin/SystemApplicationGrid\";\nimport SystemApplicationAuthorityGrid from \"../../components/administration/admin/SystemApplicationAuthorityGrid\";\nimport SystemApplicationModuleGrid from \"../../components/administration/admin/SystemApplicationModuleGrid\";\nimport SystemApplicationRoleGrid from \"../../components/administration/admin/SystemApplicationRoleGrid\";\nimport SystemApplicationRoleAuthorityGrid from \"../../components/administration/admin/SystemApplicationRoleAuthorityGrid\";\nimport OrganizationApplicationModuleGrid from \"../../components/administration/admin/OrganizationApplicationModuleGrid\";\nexport const adminRoutes: Array<SystemRoute> = [\n {\n path: \"admin/organizations\",\n component: OrganizationGrid,\n authority: \"ORGANIZATION_VIEW\",\n },\n {\n path: \"admin/organizationmembers\",\n component: OrganizationMemberGrid,\n authority: \"ORGANIZATION_MEMBER_VIEW\",\n },\n {\n path: \"admin/organizationmemberroles\",\n component: OrganizationMemberRoleGrid,\n authority: \"ORGANIZATION_MEMBER_ROLE_VIEW\",\n },\n {\n path: \"admin/organizationranks\",\n component: OrganizationRankGrid,\n authority: \"ORGANIZATION_RANK_VIEW\",\n },\n {\n path: \"admin/organizationunits\",\n component: OrganizationUnitGrid,\n authority: \"ORGANIZATION_UNIT_VIEW\",\n },\n {\n path: \"admin/organizationunittypes\",\n component: OrganizationUnitTypeGrid,\n authority: \"ORGANIZATION_UNIT_TYPE_VIEW\",\n },\n {\n path: \"admin/persons\",\n component: PersonGrid,\n authority: \"PERSON_VIEW\",\n },\n {\n path: \"admin/systemapplications\",\n component: SystemApplicationGrid,\n authority: \"SYSTEM_APPLICATION_VIEW\",\n },\n {\n path: \"admin/systemapplicationauthorities\",\n component: SystemApplicationAuthorityGrid,\n authority: \"SYSTEM_APPLICATION_AUTHORITY_VIEW\",\n },\n {\n path: \"admin/systemapplicationmodules\",\n component: SystemApplicationModuleGrid,\n authority: \"SYSTEM_APPLICATION_MODULE_VIEW\",\n },\n {\n path: \"admin/systemapplicationroles\",\n component: SystemApplicationRoleGrid,\n authority: \"SYSTEM_APPLICATION_ROLE_VIEW\",\n },\n {\n path: \"admin/systemapplicationroleauthorities\",\n component: SystemApplicationRoleAuthorityGrid,\n authority: \"SYSTEM_APPLICATION_ROLE_AUTHORITY_VIEW\",\n },\n {\n path: \"admin/org/apps\",\n component: OrganizationApplicationModuleGrid,\n authority: \"ORGANIZATION_ADMIN\",\n },\n {\n path: \"admin/org/unit/types\",\n component: OrganizationUnitTypeGrid,\n authority: \"DEVELOPMENT_ADMIN\",\n },\n {\n path: \"admin/org/units\",\n component: OrganizationUnitGrid,\n authority: \"DEVELOPMENT_ADMIN\",\n },\n {\n path: \"admin/org/ranks\",\n component: OrganizationRankGrid,\n authority: \"DEVELOPMENT_ADMIN\",\n },\n];\n\n// import { adminRoutes } from \"./adminRoutes\";\n// [...adminRoutes]\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useWindow } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport OrganizationApplicationModuleGrid from \"./OrganizationApplicationModuleGrid\";\nimport OrganizationUnitTypeGrid from \"./OrganizationUnitTypeGrid\";\nimport OrganizationUnitGrid from \"./OrganizationUnitGrid\";\nimport OrganizationRankGrid from \"./OrganizationRankGrid\";\nimport { Box } from \"@mui/material\";\nimport { AttachmentImageViewer } from \"../../templates\";\n\nconst OrganizationGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"SystemOrganizations\",\n deleteById: \"api/v1/org/admin/organization\",\n save: \"api/v1/org/admin/organization\",\n findById: \"api/v1/org/admin/organization\",\n setData: setData,\n });\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Logo\",\n fieldName: \"custom\",\n fieldType: \"custom\",\n gridProps: {\n muiProps: {\n align: \"center\",\n headerAlign: \"center\",\n renderCell: (params) => {\n return (\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n height: \"100%\",\n }}\n >\n <AttachmentImageViewer\n showAsAvatar={true}\n attachmentCode=\"ORGANIZATION_LOGOS\"\n refKey={params.id + \"\"}\n />\n </Box>\n );\n },\n },\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_ORGANIZATION_CODE\",\n fieldName: \"organizationCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_ORGANIZATION_AR_NAME\",\n fieldName: \"organizationArName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_ORGANIZATION_EN_NAME\",\n fieldName: \"organizationEnName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <>\n <TemplateGrid\n attachment={{ attachmentCode: \"ORGANIZATION_LOGOS\" }}\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"ORGANIZATION_PLURAL\"\n girdIcon=\"globe\"\n editAction={{ isEnabled: true, authority: \"ORGANIZATION_EDIT\" }}\n deleteAction={{ isEnabled: true, authority: \"ORGANIZATION_DELETE\" }}\n />\n </>\n );\n};\n\nexport default OrganizationGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport {useApiActions} from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\n\nconst OrganizationMemberRoleGrid: React.FC = () => {\n\tconst { t } = useTranslation();\n\tconst [data, setData] = useState([]);\n const apiActions = useApiActions({\n \tfindAll: \"api/v1/admin/organizationmemberrole/all\",\n \tdeleteById: \"api/v1/admin/organizationmemberrole\",\n \tsave: \"api/v1/admin/organizationmemberrole\",\n\t\tfindById: \"api/v1/admin/organizationmemberrole\",\n \tsetData: setData,\n \t});\n\t\n\tconst formElements: Array<FormElementProps> = [\n\t\t\t\t\t\t\t\t\t\t\t{\n \t\t\t\ttype: \"field\",\n \t\t\t\tmode: \"props\",\n \t\t\t\tprops: {\n \t\t\t\tfieldLabel: \"ORGANIZATION_MEMBER_ROLE_IS_ACTIVE\",\n \t\t\t\tfieldName: \"isActive\",\n \t\t\t\trequired: false,\n \t\t\t\tfieldType: \"checkbox\",\n \t\t\t\t},\n \t\t\t},\n\t\t\t\t\t \t\t\t \t\t\t \t\t\t \t\t\t\t\t\t\t\t\t\t{\n \t\t\t\ttype: \"field\",\n \t\t\t\tmode: \"props\",\n \t\t\t\tprops: {\n \t\t\t\tfieldLabel: \"ORGANIZATION_MEMBER_ROLE_END_DATE\",\n \t\t\t\tfieldName: \"endDate\",\n \t\t\t\trequired: false,\n \t\t\t\tfieldType: \"datetime\",\n \t\t\t\t},\n \t\t\t},\n\t\t\t\t\t \t\t\t \t\t\t \t\t\t\t\t\t \t\t\t{\n \t\t\t\ttype: \"field\",\n \t\t\t\tmode: \"props\",\n \t\t\t\tprops: {\n \t\t\t\tfieldLabel: \"ORGANIZATION_MEMBER_ROLE_ORGANIZATION_MEMBER_ID\",\n \t\t\t\tfieldName: \"organizationMemberId\",\n \t\t\t\trequired: true,\n \t\t\t\tfieldType: \"text\",\n \t\t\t\t},\n \t\t\t},\t\t\t\n\t\t\t\t\t \t\t\t\t\t\t\t\t\t\t{\n \t\t\t\ttype: \"field\",\n \t\t\t\tmode: \"props\",\n \t\t\t\tprops: {\n \t\t\t\tfieldLabel: \"ORGANIZATION_MEMBER_ROLE_START_DATE\",\n \t\t\t\tfieldName: \"startDate\",\n \t\t\t\trequired: false,\n \t\t\t\tfieldType: \"datetime\",\n \t\t\t\t},\n \t\t\t},\n\t\t\t\t\t \t\t\t\t\t\t \t\t\t{\n \t\t\t\ttype: \"field\",\n \t\t\t\tmode: \"props\",\n \t\t\t\tprops: {\n \t\t\t\tfieldLabel: \"ORGANIZATION_MEMBER_ROLE_SYSTEM_APPLICATION_ROLE_ID\",\n \t\t\t\tfieldName: \"systemApplicationRoleId\",\n \t\t\t\trequired: true,\n \t\t\t\tfieldType: \"text\",\n \t\t\t\t},\n \t\t\t},\t\t\t\n\t\t\t\t\t \t\t\t \t\t\t \t\t\t \t\t];\n\n\treturn (\n \t<TemplateGrid\n \t\tapiActions={apiActions}\n \t\tdata={data}\n \t\tsetData={setData}\n \t\teditMode={{ editMode: \"row\"}}\n \t\tformElements={formElements}\n\t\t\tkeyColumnName={\"id\"}\n \t\tgridTitle=\"ORGANIZATION_MEMBER_ROLE_PLURAL\"\n \t\tgirdIcon=\"table-cells\"\n \t\teditAction={{ isEnabled: true, authority: \"ORGANIZATION_MEMBER_ROLE_EDIT\" }}\n \t\tdeleteAction={{ isEnabled: true, authority: \"ORGANIZATION_MEMBER_ROLE_DELETE\" }}\n \t/>\n );\n};\n\nexport default OrganizationMemberRoleGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useSession, useWindow } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { toast } from \"react-toastify\";\nimport OrganizationMemberGrid from \"./OrganizationMemberGrid\";\nimport { Box } from \"@mui/material\";\nimport AttachmentImageViewer from \"../../templates/attachment/AttachmentImageViewer\";\nimport { useSelector } from \"react-redux\";\nimport OrgMemberRoleForm from \"./OrgMemberRoleForm\";\nimport ChangePasswordPanel from \"./ChangePasswordPanel\";\n\nconst PersonGrid: React.FC = () => {\n const { t } = useTranslation();\n const [selectedPerson, setSelectedPerson] = useState<any>(null);\n const { UserInfo } = useSession();\n const CurrentOrganizationRanks = useSelector(\n (state: any) => state.commonStores.stores.CurrentOrganizationRanks.data\n );\n const CurrentOrganizationUnits = useSelector(\n (state: any) => state.commonStores.stores.CurrentOrganizationUnits.data\n );\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/public/person/all\",\n deleteById: \"api/v1/admin/person\",\n save: \"api/v1/admin/person\",\n findById: \"api/v1/admin/person\",\n setData: setData,\n });\n const [selectedRecord, setSelectedRecord] = useState<any>(null);\n const {\n Window: OrganizationMembersWindow,\n setWindowState: setOrganizationMemberWindowState,\n } = useWindow({\n windowTitle: \"Organizations Membership\",\n windowIcon: \"globe\",\n });\n const {\n Window: OrganizationMemberRolesWindow,\n setWindowState: setOrganizationMemberRolesWindowState,\n } = useWindow({\n windowIcon: \"tag\",\n windowTitle: \"Organization Member Roles\",\n width: \"50%\",\n });\n const {\n Window: ChangePasswordWindow,\n setWindowState: setChangePasswordWindow,\n } = useWindow({\n windowIcon: \"key\",\n windowTitle: \"Change Password\",\n width: \"fit-content\",\n height: \"fit-content\",\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n hidden: true,\n fieldLabel: \"id\",\n fieldName: \"id\",\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n hidden: true,\n fieldLabel: \"organizationMemberId\",\n fieldName: \"organizationMemberId\",\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Image\",\n fieldName: \"custom\",\n fieldType: \"custom\",\n gridProps: {\n muiProps: {\n align: \"center\",\n headerAlign: \"center\",\n renderCell: (params) => {\n return (\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n height: \"100%\",\n }}\n >\n <AttachmentImageViewer\n showAsAvatar={true}\n attachmentCode=\"EMPLOYEE_PHOTOS\"\n refKey={params.id + \"\"}\n />\n </Box>\n );\n },\n },\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"PERSON_EMPLOYEE_AR_NAME\",\n fieldName: \"employeeArName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"PERSON_EMPLOYEE_EN_NAME\",\n fieldName: \"employeeEnName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"PERSON_EMAIL\",\n fieldName: \"email\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"PERSON_MOBILE_NUMBER\",\n fieldName: \"mobileNumber\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_MEMBER_ORGANIZATION_RANK_ID\",\n fieldName: \"organizationRankId\",\n required: false,\n fieldType: \"combobox\",\n options: CurrentOrganizationRanks,\n optionValueField: \"id\",\n optionDisplayField: \"rankEnName\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_MEMBER_ORGANIZATION_UNIT_ID\",\n fieldName: \"organizationUnitId\",\n required: false,\n fieldType: \"combobox\",\n options: CurrentOrganizationUnits,\n optionValueField: \"id\",\n optionDisplayField: \"organizationUnitEnName\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Membership number\",\n fieldName: \"organizationMembershipNumber\",\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n hidden: true,\n gridProps: { hidden: true },\n fieldLabel: \"PERSON_PASSWORD\",\n fieldName: \"password\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"PERSON_USERNAME\",\n fieldName: \"username\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n hidden: true,\n fieldLabel: \"Ref Source\",\n fieldName: \"refSource\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n hidden: true,\n fieldLabel: \"PERSON_EMPLOYEE_NUMBER\",\n fieldName: \"refSyncNumber\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"PERSON_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <>\n <OrganizationMemberRolesWindow>\n <OrgMemberRoleForm\n selectedRecord={selectedRecord}\n closeModalFn={() => {\n setOrganizationMemberRolesWindowState(false);\n }}\n />\n </OrganizationMemberRolesWindow>\n <OrganizationMembersWindow>\n <OrganizationMemberGrid selectedPerson={selectedPerson} />\n </OrganizationMembersWindow>\n <ChangePasswordWindow>\n <ChangePasswordPanel\n selectedPerson={selectedPerson}\n isSelfService={false}\n onSuccessCallBk={() => {\n setChangePasswordWindow(false);\n }}\n />\n </ChangePasswordWindow>\n <TemplateGrid\n attachment={{ attachmentCode: \"EMPLOYEE_PHOTOS\" }}\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalIcon: \"user\",\n modalTitle: \"Person Profile\",\n modalWidth: 300,\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"PERSON_PLURAL\"\n rowActions={[\n {\n icon: \"key\",\n label: \"Change User Password\",\n actionFn: async (data) => {\n setSelectedPerson(data);\n setChangePasswordWindow(true);\n },\n },\n {\n icon: \"tags\",\n label: \"Current Organization User Roles\",\n isActionDisabledForRecord: (data) => {\n return !data?.organizationMemberId;\n },\n actionFn: async (data) => {\n setSelectedRecord({\n organizationId: UserInfo?.currentOrganization?.id,\n id: data?.organizationMemberId,\n });\n setOrganizationMemberRolesWindowState(true);\n },\n },\n {\n icon: \"globe\",\n label: \"User Organizations\",\n actionFn: async (data) => {\n setSelectedPerson(data);\n setOrganizationMemberWindowState(true);\n },\n },\n ]}\n girdIcon=\"users\"\n editAction={{\n isEnabled: true,\n authority: \"PERSON_EDIT\",\n preActionValidation: (data) => {\n if (\n data.refSource != undefined &&\n data.refSource != null &&\n data.refSource != \"\"\n ) {\n toast.error(\n \"This Person Was synced from other system therefore you can't modify this record\"\n );\n return false;\n }\n return true;\n },\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"PERSON_DELETE\",\n preActionValidation: (data) => {\n if (\n data.refSource != undefined &&\n data.refSource != null &&\n data.refSource != \"\"\n ) {\n toast.error(\n \"This Person Was synced from other system therefore you can't modify this record\"\n );\n return false;\n }\n return true;\n },\n }}\n />\n </>\n );\n};\n\nexport default PersonGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useWindow } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\n\nconst SystemApplicationGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/org/admin/systemapplication/all\",\n deleteById: \"api/v1/org/admin/systemapplication\",\n save: \"api/v1/org/admin/systemapplication\",\n findById: \"api/v1/org/admin/systemapplication\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_APPLICATION_CODE\",\n fieldName: \"applicationCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_APPLICATION_NAME\",\n fieldName: \"applicationName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_APPLICATION_DESCRIPTION\",\n fieldName: \"applicationDescription\",\n required: false,\n fieldType: \"text\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <>\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"SYSTEM_APPLICATION_PLURAL\"\n girdIcon=\"window-restore\"\n editAction={{ isEnabled: true, authority: \"SYSTEM_APPLICATION_EDIT\" }}\n deleteAction={{\n isEnabled: true,\n authority: \"SYSTEM_APPLICATION_DELETE\",\n }}\n />\n </>\n );\n};\n\nexport default SystemApplicationGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\n\nconst SystemApplicationRoleAuthorityGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/admin/systemapplicationroleauthority/all\",\n deleteById: \"api/v1/admin/systemapplicationroleauthority\",\n save: \"api/v1/admin/systemapplicationroleauthority\",\n findById: \"api/v1/admin/systemapplicationroleauthority\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_ROLE_AUTHORITY_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"SYSTEM_APPLICATION_ROLE_AUTHORITY_SYSTEM_APPLICATION_AUTHORITY_ID\",\n fieldName: \"systemApplicationAuthorityId\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"SYSTEM_APPLICATION_ROLE_AUTHORITY_SYSTEM_APPLICATION_ROLE_ID\",\n fieldName: \"systemApplicationRoleId\",\n required: true,\n fieldType: \"text\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"SYSTEM_APPLICATION_ROLE_AUTHORITY_PLURAL\"\n girdIcon=\"table-cells\"\n editAction={{\n isEnabled: true,\n authority: \"SYSTEM_APPLICATION_ROLE_AUTHORITY_EDIT\",\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"SYSTEM_APPLICATION_ROLE_AUTHORITY_DELETE\",\n }}\n />\n );\n};\n\nexport default SystemApplicationRoleAuthorityGrid;\n","import { useEffect, useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useAxios } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useSelector } from \"react-redux\";\n\nconst OrganizationApplicationModuleGrid: React.FC = () => {\n const { t } = useTranslation();\n const { handleGetRequest } = useAxios();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/org/admin/organizationapplicationmodule/all\",\n deleteById: \"api/org/v1/admin/organizationapplicationmodule\",\n save: \"api/v1/org/admin/organizationapplicationmodule\",\n findById: \"api/org/v1/admin/organizationapplicationmodule\",\n setData: setData,\n });\n const SystemApplicationModules = useSelector(\n (state: any) => state.commonStores.stores.SystemApplicationModules.data\n );\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"ORGANIZATION_APPLICATION_MODULE_SYSTEM_APPLICATION_MODULE_ID\",\n fieldName: \"systemApplicationModuleId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemApplicationModules,\n optionDisplayField: \"moduleName\",\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n hidden: true,\n gridProps: {\n hidden: true,\n },\n fieldLabel: \"ORGANIZATION_APPLICATION_MODULE_ORGANIZATION_ID\",\n fieldName: \"organizationId\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_APPLICATION_MODULE_SUBSCRIPTION_DATE\",\n fieldName: \"subscriptionDate\",\n required: true,\n fieldType: \"date\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_APPLICATION_MODULE_EXPIRATION_DATE\",\n fieldName: \"expirationDate\",\n required: false,\n fieldType: \"date\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_APPLICATION_MODULE_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"ORGANIZATION_APPLICATION_MODULE_PLURAL\"\n girdIcon=\"layer-group\"\n editAction={{\n isEnabled: true,\n authority: \"ORGANIZATION_APPLICATION_MODULE_EDIT\",\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"ORGANIZATION_APPLICATION_MODULE_DELETE\",\n }}\n />\n );\n};\n\nexport default OrganizationApplicationModuleGrid;\n","import { SystemRoute } from \"../types\";\nimport BluePrintGrid from \"../../components/administration/dev/BluePrintGrid\";\nimport DataQueryGrid from \"../../components/administration/dev/DataQueryGrid\";\nimport DatasourceConnectionGrid from \"../../components/administration/dev/DatasourceConnectionGrid\";\nimport EntityParameterGrid from \"../../components/administration/dev/EntityParameterGrid\";\n\nimport LookupGrid from \"../../components/administration/dev/LookupGrid\";\n\nimport ReportGrid from \"../../components/administration/dev/ReportGrid\";\nimport MailTemplateGrid from \"../../components/administration/dev/MailTemplateGrid\";\nimport MailSenderConfigGrid from \"../../components/administration/dev/MailSenderConfigGrid\";\nimport WorkflowDocumentGrid from \"../../components/administration/dev/WorkflowDocumentGrid\";\nimport WidgetGrid from \"../../components/administration/dev/WidgetGrid\";\nimport DashboardGrid from \"../../components/administration/dev/DashboardGrid\";\nimport DashboardRouteView from \"../../components/templates/visuals/DashboardRouteView\";\nimport WorkflowDocumentMailLogGrid from \"../../components/administration/dev/WorkflowDocumentMailLogGrid\";\nimport MailNotificationQueueGrid from \"../../components/administration/dev/MailNotificationQueueGrid\";\nimport SystemApplicationAuthorityGrid from \"../../components/administration/admin/SystemApplicationAuthorityGrid\";\nimport SystemApplicationRoleGrid from \"../../components/administration/admin/SystemApplicationRoleGrid\";\nimport SystemApplicationModuleGrid from \"../../components/administration/admin/SystemApplicationModuleGrid\";\nimport AttachmentConfigGrid from \"../../components/administration/dev/AttachmentConfigGrid\";\nimport NotificationGrid from \"../../components/administration/dev/NotificationGrid\";\nimport MyNotificationsPanel from \"../../components/common/MyNotificationsPanel\";\nimport WorkflowRouteComponent from \"../../components/templates/workflow/WorkflowRouteComponent\";\n\nexport const devRoutes: Array<SystemRoute> = [\n {\n path: \"dev/blueprints\",\n component: BluePrintGrid,\n authority: \"BLUE_PRINT_VIEW\",\n },\n {\n path: \"dev/dataqueries\",\n component: DataQueryGrid,\n authority: \"DATA_QUERY_VIEW\",\n },\n {\n path: \"dev/datasourceconnections\",\n component: DatasourceConnectionGrid,\n authority: \"DATASOURCE_CONNECTION_VIEW\",\n },\n {\n path: \"dev/entityparameters\",\n component: EntityParameterGrid,\n authority: \"ENTITY_PARAMETER_VIEW\",\n },\n {\n path: \"dev/lookups\",\n component: LookupGrid,\n authority: \"LOOKUP_VIEW\",\n },\n {\n path: \"dev/reports\",\n component: ReportGrid,\n authority: \"REPORT_VIEW\",\n },\n {\n path: \"dev/mailtemplates\",\n component: MailTemplateGrid,\n authority: \"MAILTEMPLATE_VIEW\",\n },\n {\n path: \"dev/mailsender/config\",\n component: MailSenderConfigGrid,\n authority: \"MAILTEMPLATE_VIEW\",\n },\n {\n path: \"dev/workflowdocuments\",\n component: WorkflowDocumentGrid,\n authority: \"WORKFLOW_DOCUMENT_VIEW\",\n },\n {\n path: \"dev/widgets\",\n component: WidgetGrid,\n authority: \"WIDGET_VIEW\",\n },\n {\n path: \"dev/dashboards\",\n component: DashboardGrid,\n authority: \"DASHBOARD_VIEW\",\n },\n {\n path: \"dashboard/:dashboardCode\",\n component: DashboardRouteView,\n },\n {\n path: \"dev/workflowdocumentmaillogs\",\n component: WorkflowDocumentMailLogGrid,\n },\n {\n path: \"dev/mailnotificationqueues\",\n component: MailNotificationQueueGrid,\n },\n {\n path: \"dev/system/authorities\",\n component: SystemApplicationAuthorityGrid,\n },\n {\n path: \"dev/system/roles\",\n component: SystemApplicationRoleGrid,\n },\n {\n path: \"dev/system/lookups\",\n component: LookupGrid,\n },\n {\n path: \"dev/system/modules\",\n component: SystemApplicationModuleGrid,\n },\n {\n path: \"dev/attachmentconfigs\",\n component: AttachmentConfigGrid,\n },\n {\n path: \"dev/notifications\",\n component: NotificationGrid,\n },\n {\n path: \"myNotifications\",\n component: MyNotificationsPanel,\n },\n {\n path: \"workflow/:workflowDocumentCode/:refDocumentId\",\n component: WorkflowRouteComponent,\n },\n];\n\n// import { devRoutes } from \"./devRoutes\";\n// [...devRoutes]\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useSelector } from \"react-redux\";\n\nconst BluePrintGrid: React.FC = () => {\n const { t } = useTranslation();\n const SystemDataQueries = useSelector(\n (state: any) => state.commonStores.stores.SystemDataQueries.data\n );\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"SystemBluePrints\",\n deleteById: \"api/v1/dev/blueprint\",\n save: \"api/v1/dev/blueprint\",\n findById: \"api/v1/dev/blueprint\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"BLUE_PRINT_BLUE_PRINT_CODE\",\n fieldName: \"bluePrintCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"BLUE_PRINT_QUERY_ID\",\n fieldName: \"queryId\",\n required: true,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionDisplayField: \"queryName\",\n optionValueField: \"id\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\", reloadAfterSave: true }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"BLUE_PRINT_PLURAL\")}\n girdIcon=\"table-cells\"\n editAction={{ isEnabled: true, authority: \"BLUE_PRINT_EDIT\" }}\n deleteAction={{ isEnabled: true, authority: \"BLUE_PRINT_DELETE\" }}\n />\n );\n};\n\nexport default BluePrintGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useWindow } from \"../../../hooks\";\nimport {\n FormElementProps,\n FormValueChangeCallBk,\n} from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useSelector } from \"react-redux\";\nimport DataQueryParametersForm from \"./DataQueryParametersForm\";\nimport DataQueryParameterGrid from \"./DataQueryParameterGrid\";\n\nconst DataQueryGrid: React.FC = () => {\n const [selectedRecord, setSelectedRecord] = useState<any>(null);\n const {\n Window: DataQueryParameterWindow,\n setWindowState: setDataQueryParameterWindow,\n } = useWindow({\n width: \"50%\",\n windowTitle: \"Data query parameters\",\n windowIcon: \"p\",\n });\n const SystemDataSources = useSelector(\n (state: any) => state.commonStores.stores.SystemDataSources.data\n );\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"SystemDataQueries\",\n deleteById: \"api/v1/dev/dataquery\",\n save: \"api/v1/dev/dataquery\",\n findById: \"api/v1/dev/dataquery\",\n setData: setData,\n });\n\n const adjustFormAfterValueChange: FormValueChangeCallBk = (\n formValues,\n formActions,\n formManager,\n fieldName,\n newValue\n ) => {\n if (fieldName) {\n if (fieldName === \"useSysCon\" && newValue == true) {\n formActions.hideField(\"datasourceConId\");\n formManager.setValue(\"datasourceConId\", null);\n } else {\n formActions.showField(\"datasourceConId\");\n }\n } else {\n if (formValues?.useSysCon) {\n formActions.hideField(\"datasourceConId\");\n }\n }\n };\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_QUERY_NAME\",\n fieldName: \"queryName\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_USE_SYS_CON\",\n fieldName: \"useSysCon\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_DATASOURCE_CON_ID\",\n fieldName: \"datasourceConId\",\n required: false,\n options: SystemDataSources,\n optionDisplayField: \"connectionName\",\n optionValueField: \"id\",\n fieldType: \"combobox\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_QUERY_STR\",\n fieldName: \"queryStr\",\n formProps: { fieldHeight: 400 },\n gridProps: {\n hidden: true,\n },\n muiTextFieldProps: {\n multiline: true,\n rows: 4,\n },\n required: false,\n fieldType: \"text\",\n },\n },\n ];\n\n return (\n <>\n <DataQueryParameterWindow>\n <DataQueryParameterGrid selectedRecord={selectedRecord} />\n </DataQueryParameterWindow>\n <TemplateGrid\n apiActions={apiActions}\n rowActions={[\n {\n label: \"Query Parameters\",\n actionFn: async (data) => {\n setSelectedRecord(data);\n setDataQueryParameterWindow(true);\n },\n icon: \"p\",\n },\n ]}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalTitle: \"System Query\",\n modalWidth: 600,\n modalIcon: \"file-code\",\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"DATA_QUERY_PLURAL\")}\n girdIcon=\"table-cells\"\n editAction={{ isEnabled: true, authority: \"DATA_QUERY_EDIT\" }}\n deleteAction={{ isEnabled: true, authority: \"DATA_QUERY_DELETE\" }}\n formProps={{ formValuesChangeCallBk: adjustFormAfterValueChange }}\n />\n </>\n );\n};\n\nexport default DataQueryGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useAxios } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useSelector } from \"react-redux\";\nimport { toast } from \"react-toastify\";\n\nconst DatasourceConnectionGrid: React.FC = () => {\n const { handleGetRequest } = useAxios();\n const SystemDataSourceType = useSelector(\n (state: any) => state.commonStores.stores.SystemDataSourceType.data\n );\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n deleteById: \"api/v1/dev/datasourceconnection\",\n save: \"api/v1/dev/datasourceconnection\",\n findById: \"api/v1/dev/datasourceconnection\",\n setData: setData,\n commonStoreKey: \"SystemDataSources\",\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ID\",\n fieldName: \"id\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATASOURCE_CONNECTION_CONNECTION_NAME\",\n fieldName: \"connectionName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATASOURCE_CONNECTION_DATASOURCE_TYPE\",\n fieldName: \"datasourceType\",\n required: true,\n fieldType: \"combobox\",\n options: SystemDataSourceType,\n comboboxValueDataType: \"string\",\n optionValueField: \"value\",\n optionDisplayField: \"value\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATASOURCE_CONNECTION_DATASOURCE_URL\",\n fieldName: \"datasourceUrl\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATASOURCE_CONNECTION_DATASOURCE_USERNAME\",\n fieldName: \"datasourceUsername\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATASOURCE_CONNECTION_DATASOURCE_PASSWORD\",\n fieldName: \"datasourcePassword\",\n required: true,\n fieldType: \"text\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATASOURCE_CONNECTION_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalTitle: \"Datasource Connection\",\n modalIcon: \"plug\",\n modalWidth: 300,\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"DATASOURCE_CONNECTION_PLURAL\")}\n girdIcon=\"plug\"\n rowActions={[\n {\n icon: \"plug\",\n label: \"test connection\",\n actionFn: async (data) => {\n await handleGetRequest({\n endPointURI: \"api/v1/dev/datasourceConnection/test\",\n showMask: true,\n parameters: {\n id: data.id,\n },\n // loadingMessage: \"checking datasource connectivity\",\n successCallBkFn: (response: any) => {\n toast.success(response.data);\n },\n });\n },\n },\n ]}\n editAction={{ isEnabled: true, authority: \"DATASOURCE_CONNECTION_EDIT\" }}\n deleteAction={{\n isEnabled: true,\n authority: \"DATASOURCE_CONNECTION_DELETE\",\n }}\n />\n );\n};\n\nexport default DatasourceConnectionGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions } from \"../../../hooks\";\nimport {\n FormElementProps,\n FormValueChangeCallBk,\n} from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useSelector } from \"react-redux\";\nimport { DATE_FORMAT, DATE_TIME_FORMAT } from \"../../../util\";\n\nconst EntityParameterGrid: React.FC = () => {\n const { t } = useTranslation();\n const SystemParameterTypes = useSelector(\n (state: any) => state.commonStores.stores.SystemParameterTypes.data\n );\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"SystemEntityParameters\",\n deleteById: \"api/v1/dev/entityparameter\",\n save: \"api/v1/dev/entityparameter\",\n findById: \"api/v1/dev/entityparameter\",\n setData: setData,\n });\n\n const SystemDataQueries = useSelector(\n (state: any) => state.commonStores.stores.SystemDataQueries.data\n );\n const adjustFormAccordingFormValues: FormValueChangeCallBk = (\n formValues: any,\n formActions,\n formManager,\n fieldName,\n newValue,\n selectedRecord\n ) => {\n if (fieldName) {\n if (fieldName === \"parameterType\") {\n if (newValue === \"combobox\") {\n formManager.setValue(\"parameterValueFormat\", null);\n formActions.showField(\"parameterDataQueryId\");\n formActions.showField(\"parameterDataset\");\n formActions.showField(\"parameterDisplayField\");\n formActions.showField(\"parameterValueField\");\n formActions.hideField(\"parameterValueFormat\");\n } else {\n formActions.hideField(\"parameterDataQueryId\");\n formActions.hideField(\"parameterDataset\");\n formActions.hideField(\"parameterDisplayField\");\n formActions.hideField(\"parameterValueField\");\n }\n if (newValue === \"date\" || newValue === \"datetime\") {\n formActions.showField(\"parameterValueFormat\");\n if (newValue === \"date\") {\n formManager.setValue(\"parameterValueFormat\", DATE_FORMAT);\n } else {\n formManager.setValue(\"parameterValueFormat\", DATE_TIME_FORMAT);\n }\n } else {\n formActions.hideField(\"parameterValueFormat\");\n formManager.setValue(\"parameterValueFormat\", null);\n }\n } else if (fieldName == \"parameterDataQueryId\") {\n if (newValue != null && newValue != \"\") {\n formManager.setValue(\"parameterDataset\", null);\n formActions.hideField(\"parameterDataset\");\n } else {\n formActions.showField(\"parameterDataset\");\n }\n } else if (fieldName == \"parameterDataset\") {\n if (newValue != null && newValue != \"\") {\n formManager.setValue(\"parameterDataQueryId\", null);\n formActions.hideField(\"parameterDataQueryId\");\n } else {\n formActions.showField(\"parameterDataQueryId\");\n }\n }\n } else { \n if (formValues?.parameterType === \"combobox\") {\n formManager.setValue(\"parameterValueFormat\", null);\n formActions.showField(\"parameterDataQueryId\");\n formActions.showField(\"parameterDataset\");\n formActions.showField(\"parameterDisplayField\");\n formActions.showField(\"parameterValueField\");\n formActions.hideField(\"parameterValueFormat\"); \n } else if (formValues?.parameterType === \"date\") {\n formActions.hideField(\"parameterDataQueryId\");\n formActions.hideField(\"parameterDataset\");\n formActions.hideField(\"parameterDisplayField\");\n formActions.hideField(\"parameterValueField\");\n formActions.showField(\"parameterValueFormat\");\n formManager.setValue(\"parameterValueFormat\", DATE_FORMAT);\n } else if (formValues?.parameterType === \"datetime\") {\n formActions.hideField(\"parameterDataQueryId\");\n formActions.hideField(\"parameterDataset\");\n formActions.hideField(\"parameterDisplayField\");\n formActions.hideField(\"parameterValueField\");\n formActions.showField(\"parameterValueFormat\");\n formManager.setValue(\"parameterValueFormat\", DATE_TIME_FORMAT);\n } else {\n formManager.setValue(\"parameterValueFormat\", null);\n formActions.hideField(\"parameterDataQueryId\");\n formActions.hideField(\"parameterDataset\");\n formActions.hideField(\"parameterDisplayField\");\n formActions.hideField(\"parameterValueField\");\n formActions.hideField(\"parameterValueFormat\");\n }\n }\n };\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ENTITY_PARAMETER_PARAMETER_CODE\",\n fieldName: \"parameterCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ENTITY_PARAMETER_PARAMETER_LABEL\",\n fieldName: \"parameterLabel\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ENTITY_PARAMETER_PARAMETER_TYPE\",\n fieldName: \"parameterType\",\n required: true,\n fieldType: \"combobox\",\n options: SystemParameterTypes,\n comboboxValueDataType: \"string\",\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ENTITY_PARAMETER_PARAMETER_DATA_QUERY_ID\",\n fieldName: \"parameterDataQueryId\",\n hidden: true,\n required: false,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionDisplayField: \"queryName\",\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ENTITY_PARAMETER_PARAMETER_DATASET\",\n fieldName: \"parameterDataset\",\n hidden: true,\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ENTITY_PARAMETER_PARAMETER_DISPLAY_FIELD\",\n fieldName: \"parameterDisplayField\",\n hidden: true,\n required: false,\n fieldType: \"text\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ENTITY_PARAMETER_PARAMETER_VALUE_FIELD\",\n fieldName: \"parameterValueField\",\n hidden: true,\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ENTITY_PARAMETER_PARAMETER_VALUE_FORMAT\",\n fieldName: \"parameterValueFormat\",\n required: false,\n hidden: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ENTITY_PARAMETER_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalTitle: \"Entity Parameter\",\n modalIcon: \"p\",\n modalWidth: 300,\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"ENTITY_PARAMETER_PLURAL\")}\n girdIcon=\"p\"\n formProps={{ formValuesChangeCallBk: adjustFormAccordingFormValues }}\n editAction={{ isEnabled: true, authority: \"ENTITY_PARAMETER_EDIT\" }}\n deleteAction={{ isEnabled: true, authority: \"ENTITY_PARAMETER_DELETE\" }}\n />\n );\n};\n\nexport default EntityParameterGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\n\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions, useWindow } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\nimport { toast } from \"react-toastify\";\nimport MailRecipientGrid from \"./MailRecipientGrid\";\nimport MailBodyGrid from \"./MailBodyGrid\";\nimport MailAttachmentGrid from \"./MailAttachmentGrid\";\n\nconst MailTemplateGrid: React.FC = () => {\n const SystemDataQueries = useSelector(\n (state: any) => state.commonStores.stores.SystemDataQueries.data\n );\n const SystemTimeIntervals = useSelector(\n (state: any) => state.commonStores.stores.SystemTimeIntervals.data\n );\n const [selectedRecord, setSelectedRecord] = useState<any>(null);\n const {\n Window: MailRecipentsWindow,\n setWindowState: setMailRecipientsWindowState,\n } = useWindow({ windowTitle: \"Mail Receipents\", windowIcon: \"users\" });\n const { Window: MailBodiesWindow, setWindowState: setMailBodiesWindowState } =\n useWindow({\n windowTitle: \"Mail Bodies\",\n windowIcon: { prefix: \"fas\", iconName: \"envelope-open-text\" },\n });\n const {\n Window: MailAttachmentWindow,\n setWindowState: setMailAttachmentWindowState,\n } = useWindow({\n windowTitle: \"Mail Attachment\",\n windowIcon: \"paperclip\",\n width: 500,\n });\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"SystemMailTemplates\",\n deleteById: \"api/v1/dev/mailtemplate\",\n save: \"api/v1/dev/mailtemplate\",\n findById: \"api/v1/dev/mailtemplate\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_TEMPLATE_MAIL_TEMPLATE_CODE\",\n fieldName: \"mailTemplateCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_TEMPLATE_MAIL_TEMPLATE_NAME\",\n fieldName: \"mailTemplateName\",\n required: true,\n fieldType: \"text\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_TEMPLATE_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"group\",\n props: {\n label: \"subject\",\n icon: \"users\",\n style: { padding: 1, border: \"0.5px dashed black\", margin: 1 },\n elements: [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_TEMPLATE_MAIL_SUBJECT\",\n fieldName: \"mailSubject\",\n required: true,\n fieldType: \"text\",\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_TEMPLATE_SUBJECT_DATA_QUERY_ID\",\n fieldName: \"subjectDataQueryId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionDisplayField: \"queryName\",\n optionValueField: \"id\",\n gridProps: {\n hidden: true,\n },\n },\n },\n ],\n },\n },\n\n {\n type: \"group\",\n props: {\n label: \"Recipients\",\n icon: \"users\",\n style: { padding: 1, border: \"0.5px dashed black\", margin: 1 },\n elements: [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"To Recipient Query (must return list of objects with property email)\",\n fieldName: \"mailToDataQueryId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionDisplayField: \"queryName\",\n optionValueField: \"id\",\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"CC Recipient Query (must return list of objects with property email)\",\n fieldName: \"mailCcDataQueryId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionDisplayField: \"queryName\",\n optionValueField: \"id\",\n gridProps: {\n hidden: true,\n },\n },\n },\n ],\n },\n },\n {\n type: \"group\",\n props: {\n label: \"Periodical Configuration\",\n icon: \"history\",\n style: { padding: 1, border: \"0.5px dashed black\", margin: 1 },\n elements: [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_TEMPLATE_PERIODICAL\",\n fieldName: \"periodical\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_TEMPLATE_PERIOD_TYPE\",\n fieldName: \"periodType\",\n options: SystemTimeIntervals,\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n required: false,\n fieldType: \"combobox\",\n comboboxValueDataType: \"string\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_TEMPLATE_PERIOD_VALUE\",\n fieldName: \"periodValue\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_TEMPLATE_START_SENDING_AT\",\n fieldName: \"startSendingAt\",\n required: false,\n fieldType: \"datetime\",\n },\n },\n ],\n },\n },\n ];\n\n return (\n <>\n <MailRecipentsWindow>\n <MailRecipientGrid\n selectedRecord={selectedRecord}\n callBkFn={() => {\n setMailRecipientsWindowState(false);\n }}\n />\n </MailRecipentsWindow>\n <MailBodiesWindow>\n <MailBodyGrid\n selectedRecord={selectedRecord}\n callBkFn={() => {\n setMailRecipientsWindowState(false);\n }}\n />\n </MailBodiesWindow>\n <MailAttachmentWindow>\n <MailAttachmentGrid\n selectedRecord={selectedRecord}\n callBkFn={() => {\n setMailAttachmentWindowState(false);\n }}\n />\n </MailAttachmentWindow>\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalWidth: 300,\n modalTitle: \"Mail Template\",\n modalIcon: \"envelope\",\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"MAIL_TEMPLATE_PLURAL\")}\n girdIcon=\"envelope\"\n rowActions={[\n {\n icon: \"users\",\n label: \"Recipients\",\n actionFn: async (data) => {\n setSelectedRecord(data);\n setMailRecipientsWindowState(true);\n },\n },\n {\n icon: { prefix: \"fas\", iconName: \"envelope-open-text\" },\n label: \"Mail Body\",\n actionFn: async (data) => {\n setSelectedRecord(data);\n setMailBodiesWindowState(true);\n },\n },\n {\n icon: \"paperclip\",\n label: \"Mail Attachments\",\n actionFn: async (data) => {\n setSelectedRecord(data);\n setMailAttachmentWindowState(true);\n },\n },\n ]}\n editAction={{\n isEnabled: true,\n authority: \"MAIL_TEMPLATE_EDIT\",\n preActionValidation: (record) => {\n if (record?.periodical === true && !record?.periodType) {\n toast.error(\n \"You must specifiy the period type since this email is periodical\"\n );\n return false;\n }\n if (record?.periodical === true && !record?.periodValue) {\n toast.error(\n \"You must specifiy the period value since this email is periodical\"\n );\n return false;\n }\n if (record?.periodical === true && !record?.startSendingAt) {\n toast.error(\n \"You must specifiy the start sending time since this email is periodical\"\n );\n return false;\n }\n\n return true;\n },\n }}\n deleteAction={{ isEnabled: true, authority: \"MAIL_TEMPLATE_DELETE\" }}\n />\n </>\n );\n};\n\nexport default MailTemplateGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions, useWindow } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\nimport WorkflowDocumentStatusGrid from \"./WorkflowDocumentStatusGrid\";\nimport WorkflowDocumentActionGrid from \"./WorkflowDocumentActionGrid\";\n\nconst WorkflowDocumentGrid: React.FC = () => {\n const [selectedRecord, setSelectedRecord] = useState<any>(null);\n const {\n Window: WorkflowStatusWindow,\n setWindowState: setWorkflowStatusWindowState,\n } = useWindow({\n windowTitle: \"Document Status\",\n windowIcon: \"tag\",\n });\n const {\n Window: WorkflowActionWindow,\n setWindowState: setWorkflowActionWindowState,\n } = useWindow({\n windowTitle: \"Document Action\",\n windowIcon: \"stamp\",\n });\n const SystemOrganizations = useSelector(\n (state: any) => state.commonStores.stores.SystemOrganizations.data\n );\n const SystemReports = useSelector(\n (state: any) => state.commonStores.stores.SystemReports.data\n );\n const SystemDataSources = useSelector(\n (state: any) => state.commonStores.stores.SystemDataSources.data\n );\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/workflowdocument/all\",\n deleteById: \"api/v1/dev/workflowdocument\",\n save: \"api/v1/dev/workflowdocument\",\n findById: \"api/v1/dev/workflowdocument\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_ORG_CODE\",\n fieldName: \"orgCode\",\n required: false,\n fieldType: \"combobox\",\n options: SystemOrganizations,\n optionDisplayField: \"organizationCode\",\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_DOCUMENT_CODE\",\n fieldName: \"documentCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Workflow Document En Display Name\",\n fieldName: \"documentEnName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Workflow Document Ar Display Name\",\n fieldName: \"documentArName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"Report To be Attached For The Document ( will be passed a parameter called doc_id)\",\n fieldName: \"documentReportId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemReports,\n optionDisplayField: \"reportName\",\n optionValueField: \"id\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_APPROVAL_ALLOWED\",\n fieldName: \"mailApprovalAllowed\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"group\",\n props: {\n icon: \"bell\",\n style: { border: \"1px dashed black\", padding: 1, marginBottom: 1 },\n label: \"App Visual Notifications\",\n elements: [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_APP_NOTIFICATION_ICON\",\n fieldName: \"appNotificationIcon\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_APP_NOTIFICATION_STYLE\",\n fieldName: \"appNotificationStyle\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_APP_VIEW_ROUTE\",\n fieldName: \"appViewRoute\",\n required: false,\n fieldType: \"text\",\n },\n },\n ],\n },\n },\n\n {\n type: \"group\",\n props: {\n icon: \"database\",\n style: { border: \"1px dashed black\", padding: 1, marginBottom: 1 },\n label: \"Related Document Database\",\n elements: [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_USE_SYSTEM_CON\",\n fieldName: \"useSystemCon\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_DOCUMENT_CON_ID\",\n fieldName: \"documentConId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemDataSources,\n optionDisplayField: \"connectionName\",\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_DOCUMENT_DATABASE_NAME\",\n fieldName: \"documentDatabaseName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_DOCUMENT_DATABASE_TABLE\",\n fieldName: \"documentDatabaseTable\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_DOCUMENT_ID_FIELD\",\n fieldName: \"documentIdField\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_DOCUMENT_STATUS_FIELD\",\n fieldName: \"documentStatusField\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_DOCUMENT_NUMBER_FIELD\",\n fieldName: \"documentNumberField\",\n required: true,\n fieldType: \"text\",\n },\n },\n ],\n },\n },\n ];\n\n return (\n <>\n <WorkflowStatusWindow>\n <WorkflowDocumentStatusGrid selectedRecord={selectedRecord} />\n </WorkflowStatusWindow>\n <WorkflowActionWindow>\n <WorkflowDocumentActionGrid selectedRecord={selectedRecord} />\n </WorkflowActionWindow>\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n rowActions={[\n {\n icon: \"tag\",\n label: \"Document States\",\n actionFn: async (data) => {\n setSelectedRecord(data);\n setWorkflowStatusWindowState(true);\n },\n },\n {\n icon: \"stamp\",\n label: \"Document Actions\",\n actionFn: async (data) => {\n setSelectedRecord(data);\n setWorkflowActionWindowState(true);\n },\n },\n ]}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalIcon: \"chart-diagram\",\n modalTitle: t(\"WORKFLOW_DOCUMENT_SINGULAR\"),\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"WORKFLOW_DOCUMENT_PLURAL\")}\n girdIcon=\"chart-diagram\"\n editAction={{ isEnabled: true, authority: \"WORKFLOW_DOCUMENT_EDIT\" }}\n deleteAction={{\n isEnabled: true,\n authority: \"WORKFLOW_DOCUMENT_DELETE\",\n }}\n />\n </>\n );\n};\n\nexport default WorkflowDocumentGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport {\n FormActionProps,\n FormElementProps,\n FormValueChangeCallBk,\n} from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\nimport { UseFormReturn } from \"react-hook-form\";\n\nexport type WidgetType =\n | \"LineChart\"\n | \"ColumnChart\"\n | \"PieChart\"\n | \"Card\"\n | \"CircularProgress\"\n | \"LinearProgress\";\n\nconst adjustFormAfterValueChange: FormValueChangeCallBk = (\n formValues,\n formActions,\n formManager,\n fieldName,\n newValue\n) => {\n if (fieldName) {\n if (fieldName === \"widgetType\") {\n if (newValue === \"LineChart\") {\n formActions.showField(\"height\");\n formActions.showField(\"width\");\n formActions.showField(\"horizontalAxisField\");\n formActions.showField(\"horizontalAxisLabel\");\n formActions.showField(\"seriesKeys\");\n formActions.showField(\"verticalAxisField\");\n formActions.showField(\"verticalAxisLabel\");\n } else if (newValue === \"ColumnChart\") {\n formActions.showField(\"height\");\n formActions.showField(\"width\");\n formActions.showField(\"horizontalAxisField\");\n formActions.showField(\"horizontalAxisLabel\");\n formActions.hideField(\"seriesKeys\");\n formActions.showField(\"verticalAxisField\");\n formActions.showField(\"verticalAxisLabel\");\n } else if (newValue === \"PieChart\") {\n formActions.showField(\"height\");\n formActions.showField(\"width\");\n formActions.showField(\"horizontalAxisField\");\n formActions.hideField(\"horizontalAxisLabel\");\n formActions.hideField(\"seriesKeys\");\n formActions.showField(\"verticalAxisField\");\n formActions.hideField(\"verticalAxisLabel\");\n } else if (newValue === \"Card\") {\n formActions.showField(\"height\");\n formActions.showField(\"width\");\n formActions.showField(\"horizontalAxisField\");\n formActions.hideField(\"horizontalAxisLabel\");\n formActions.hideField(\"seriesKeys\");\n formActions.showField(\"verticalAxisField\");\n formActions.hideField(\"verticalAxisLabel\");\n } else if (newValue === \"CircularProgress\") {\n formActions.hideField(\"height\");\n formActions.hideField(\"width\");\n formActions.hideField(\"horizontalAxisField\");\n formActions.hideField(\"horizontalAxisLabel\");\n formActions.hideField(\"seriesKeys\");\n formActions.hideField(\"verticalAxisField\");\n formActions.hideField(\"verticalAxisLabel\");\n } else if (newValue === \"LinearProgress\") {\n formActions.hideField(\"height\");\n formActions.hideField(\"width\");\n formActions.hideField(\"horizontalAxisField\");\n formActions.hideField(\"horizontalAxisLabel\");\n formActions.hideField(\"seriesKeys\");\n formActions.hideField(\"verticalAxisField\");\n formActions.hideField(\"verticalAxisLabel\");\n } else {\n formActions.hideField(\"height\");\n formManager.setValue(\"height\", null);\n formActions.hideField(\"width\");\n formManager.setValue(\"width\", null);\n formActions.hideField(\"horizontalAxisField\");\n formManager.setValue(\"horizontalAxisField\", null);\n formActions.hideField(\"horizontalAxisLabel\");\n formManager.setValue(\"horizontalAxisLabel\", null);\n formActions.hideField(\"seriesKeys\");\n formManager.setValue(\"seriesKeys\", null);\n formActions.hideField(\"verticalAxisField\");\n formManager.setValue(\"verticalAxisField\", null);\n formActions.hideField(\"verticalAxisLabel\");\n formManager.setValue(\"verticalAxisLabel\", null);\n }\n }\n } else {\n }\n};\n\nconst WidgetGrid: React.FC = () => {\n const { t } = useTranslation();\n const SystemDataQueries = useSelector(\n (state: any) => state.commonStores.stores.SystemDataQueries.data\n );\n const SystemWidgetTypes = useSelector(\n (state: any) => state.commonStores.stores.SystemWidgetTypes.data\n );\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"SystemWidgets\",\n deleteById: \"api/v1/dev/widget\",\n save: \"api/v1/dev/widget\",\n findById: \"api/v1/dev/widget\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_WIDGET_TYPE\",\n fieldName: \"widgetType\",\n required: true,\n fieldType: \"combobox\",\n comboboxValueDataType: \"string\",\n options: SystemWidgetTypes,\n optionDisplayField: \"name\",\n optionValueField: \"name\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Query\",\n fieldName: \"dataQueryId\",\n required: true,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionDisplayField: \"queryName\",\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_WIDGET_NAME\",\n fieldName: \"widgetName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_ICON\",\n fieldName: \"icon\",\n required: false,\n fieldType: \"text\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_TITLE\",\n fieldName: \"title\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_WIDGET_DESCRIPTION\",\n fieldName: \"widgetDescription\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_HEIGHT\",\n fieldName: \"height\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_WIDTH\",\n fieldName: \"width\",\n required: false,\n fieldType: \"combobox\",\n options: [\n { value: 1 },\n { value: 2 },\n { value: 3 },\n { value: 4 },\n { value: 5 },\n { value: 6 },\n { value: 7 },\n { value: 8 },\n { value: 9 },\n { value: 10 },\n { value: 11 },\n { value: 12 },\n ],\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"group\",\n props: {\n style: { padding: 1, border: \"1px solid black\", width: \"100%\" },\n label: \"Data Specs\",\n elements: [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_HORIZONTAL_AXIS_FIELD\",\n fieldName: \"horizontalAxisField\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_HORIZONTAL_AXIS_LABEL\",\n fieldName: \"horizontalAxisLabel\",\n required: true,\n fieldType: \"text\",\n },\n },\n\n // {\n // type: \"field\",\n // mode: \"props\",\n // props: {\n // fieldLabel: \"WIDGET_SERIES_KEYS\",\n // fieldName: \"seriesKeys\",\n // required: false,\n // fieldType: \"text\",\n // },\n // },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_VERTICAL_AXIS_FIELD\",\n fieldName: \"verticalAxisField\",\n required: true,\n fieldType: \"text\",\n },\n },\n // {\n // type: \"field\",\n // mode: \"props\",\n // props: {\n // fieldLabel: \"WIDGET_VERTICAL_AXIS_LABEL\",\n // fieldName: \"verticalAxisLabel\",\n // required: false,\n // fieldType: \"text\",\n // },\n // },\n ],\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: { modalIcon: \"chart-pie\", modalTitle: \"Widget\" },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"WIDGET_PLURAL\")}\n girdIcon=\"chart-pie\"\n editAction={{ isEnabled: true, authority: \"WIDGET_EDIT\" }}\n deleteAction={{ isEnabled: true, authority: \"WIDGET_DELETE\" }}\n // formProps={{ formValuesChangeCallBk: adjustFormAfterValueChange }}\n />\n );\n};\n\nexport default WidgetGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions, useWindow } from \"../../../hooks\";\nimport DashboardWidgetGrid from \"./DashboardWidgetGrid\";\nimport { useNavigate } from \"react-router-dom\";\n\nconst DashboardGrid: React.FC = () => {\n const { t } = useTranslation();\n const [selectedRecord, setSelectedRecord] = useState<any>(null);\n const { Window: WidgetsWindows, setWindowState: setWidgetsWindowState } =\n useWindow({\n windowTitle: \"Dashboard Widgets\",\n windowIcon: \"chart-pie\",\n });\n const [data, setData] = useState([]);\n const navigate = useNavigate();\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/dashboard/all\",\n deleteById: \"api/v1/dev/dashboard\",\n save: \"api/v1/dev/dashboard\",\n findById: \"api/v1/dev/dashboard\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DASHBOARD_DASHBOARD_CODE\",\n fieldName: \"dashboardCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DASHBOARD_DASHBOARD_NAME\",\n fieldName: \"dashboardName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DASHBOARD_DASHBOARD_TITLE\",\n fieldName: \"dashboardTitle\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DASHBOARD_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <>\n <WidgetsWindows>\n <DashboardWidgetGrid selectedRecord={selectedRecord} />\n </WidgetsWindows>\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n rowActions={[\n {\n label: \"Widgets\",\n icon: \"chart-pie\",\n actionFn: async (data) => {\n setSelectedRecord(data);\n setWidgetsWindowState(true);\n },\n },\n {\n label: \"View\",\n icon: \"eye\",\n actionFn: async (data) => {\n navigate(\"/dashboard/\" + data.dashboardCode);\n },\n },\n ]}\n gridTitle={t(\"DASHBOARD_PLURAL\")}\n girdIcon=\"square-poll-vertical\"\n editAction={{ isEnabled: true, authority: \"DASHBOARD_EDIT\" }}\n deleteAction={{ isEnabled: true, authority: \"DASHBOARD_DELETE\" }}\n />\n </>\n );\n};\n\nexport default DashboardGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\n\nconst WorkflowDocumentMailLogGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/workflowdocumentmaillog/all\",\n deleteById: \"api/v1/dev/workflowdocumentmaillog\",\n save: \"api/v1/dev/workflowdocumentmaillog\",\n findById: \"api/v1/dev/workflowdocumentmaillog\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_GRAPH_API_MSG_ID\",\n fieldName: \"graphApiMsgId\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_IS_PROCESSED\",\n fieldName: \"isProcessed\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_MAIL_ACTION_CODE\",\n fieldName: \"mailActionCode\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_MAIL_BODY_CONTENT\",\n fieldName: \"mailBodyContent\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_MAIL_FROM\",\n fieldName: \"mailFrom\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_MAIL_SUBJECT\",\n fieldName: \"mailSubject\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_PROCESS_MESSAGE\",\n fieldName: \"processMessage\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_PROCESS_TIME\",\n fieldName: \"processTime\",\n required: false,\n fieldType: \"datetime\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_REF_DOC_ID\",\n fieldName: \"refDocId\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_WORKFLOW_DOCUMENT_ID\",\n fieldName: \"workflowDocumentId\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_MAIL_RECEIVE_TIME\",\n fieldName: \"mailReceiveTime\",\n required: false,\n fieldType: \"datetime\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"WORKFLOW_DOCUMENT_MAIL_LOG_PLURAL\")}\n girdIcon=\"table-cells\"\n editAction={{\n isEnabled: true,\n authority: \"WORKFLOW_DOCUMENT_MAIL_LOG_EDIT\",\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"WORKFLOW_DOCUMENT_MAIL_LOG_DELETE\",\n }}\n />\n );\n};\n\nexport default WorkflowDocumentMailLogGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions, useAxios, useConfirmationWindow } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\n\nconst MailNotificationQueueGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const { handlePostRequest } = useAxios();\n\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/mailnotificationqueue/all\",\n deleteById: \"api/v1/dev/mailnotificationqueue\",\n save: \"api/v1/dev/mailnotificationqueue\",\n findById: \"api/v1/dev/mailnotificationqueue\",\n setData: setData,\n });\n const SystemMailTemplates = useSelector(\n (state: any) => state.commonStores.stores.SystemMailTemplates.data\n );\n\n const resendMail = async (id: any) => {\n await handlePostRequest({\n endPointURI: \"api/v1/public/mailNotification/resend\",\n showMask: true,\n parameters: {\n mailNotificationQueueId: id,\n },\n successCallBkFn: (response: any) => {\n apiActions.reloadData();\n },\n });\n };\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_NOTIFICATION_QUEUE_MAIL_TEMPLATE_ID\",\n fieldName: \"mailTemplateId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemMailTemplates,\n optionDisplayField: \"mailTemplateName\",\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_NOTIFICATION_QUEUE_CUSTOM_MAIL_ATTACHED_REPORT_ID\",\n fieldName: \"customMailAttachedReportId\",\n required: false,\n hidden: true,\n gridProps: {\n hidden: true,\n },\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_NOTIFICATION_QUEUE_CUSTOM_MAIL_BODY\",\n fieldName: \"customMailBody\",\n required: false,\n hidden: true,\n gridProps: {\n hidden: true,\n },\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_NOTIFICATION_QUEUE_CUSTOM_MAIL_SUBJECT\",\n fieldName: \"customMailSubject\",\n required: false,\n hidden: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_NOTIFICATION_QUEUE_CUSTOM_RECIPIENTS\",\n fieldName: \"customRecipients\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_NOTIFICATION_QUEUE_IS_NOTIFIED\",\n fieldName: \"isNotified\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_NOTIFICATION_QUEUE_NOTIFICATION_TIME\",\n fieldName: \"notificationTime\",\n required: false,\n fieldType: \"datetime\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_NOTIFICATION_QUEUE_NOTIFICATION_MESSAGE\",\n fieldName: \"notificationMessage\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_NOTIFICATION_QUEUE_MAIL_PARAMETERS\",\n fieldName: \"mailParameters\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"text\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n disableDefaultAction={true}\n data={data}\n setData={setData}\n editMode={{ editMode: \"none\" }}\n formElements={formElements}\n rowActions={[\n {\n actionFn: async (data) => {\n resendMail(data.id);\n },\n label: \"Resend\",\n icon: \"repeat\",\n confirmationMessage: \"Are you sure you want to resend this email ?\",\n isConfirmationRequired: true,\n },\n ]}\n keyColumnName={\"id\"}\n gridTitle={t(\"MAIL_NOTIFICATION_QUEUE_PLURAL\")}\n girdIcon=\"table-cells\"\n editAction={{\n isEnabled: true,\n authority: \"MAIL_NOTIFICATION_QUEUE_EDIT\",\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"MAIL_NOTIFICATION_QUEUE_DELETE\",\n }}\n />\n );\n};\n\nexport default MailNotificationQueueGrid;\n","import { useEffect, useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\nimport { Box } from \"@mui/material\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport useInterval from \"../../../hooks/useInterval\";\n\nconst NotificationGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const SystemTimeIntervals = useSelector(\n (state: any) => state.commonStores.stores.SystemTimeIntervals.data\n );\n const SystemDataQueries = useSelector(\n (state: any) => state.commonStores.stores.SystemDataQueries.data\n );\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/notification/all\",\n deleteById: \"api/v1/dev/notification\",\n save: \"api/v1/dev/notification\",\n findById: \"api/v1/dev/notification\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_NOTIFICATION_CODE\",\n fieldName: \"notificationCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"Notification Data Query ( will be passed a parameter call last_run_time represents last check time)\",\n fieldName: \"notificationQueryId\",\n required: true,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionDisplayField: \"queryName\",\n gridProps: {\n hidden: true,\n },\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"Users to notify Query (must have username property in the result set)\",\n fieldName: \"usersToNotifyQueryId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionDisplayField: \"queryName\",\n gridProps: {\n hidden: true,\n },\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_AUTHORITY_TO_NOTIFY\",\n fieldName: \"authorityToNotify\",\n required: false,\n gridProps: {\n hidden: true,\n },\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Interval Type\",\n fieldName: \"intervalType\",\n fieldType: \"combobox\",\n comboboxValueDataType: \"string\",\n options: SystemTimeIntervals,\n gridProps: {\n hidden: true,\n },\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Interval Value (minmum value 20 seconds)\",\n fieldName: \"intervalValue\",\n gridProps: {\n hidden: true,\n },\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Start Notifing Date\",\n fieldName: \"startNotificationFrom\",\n gridProps: {\n hidden: true,\n },\n fieldType: \"datetime\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_SYSTEM_APPLICATION_ID\",\n fieldName: \"systemApplicationId\",\n hidden: true,\n gridProps: { hidden: true },\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_NOTIFICATION_ICON\",\n fieldName: \"notificationIcon\",\n required: true,\n fieldType: \"text\",\n gridProps: {\n muiProps: {\n renderCell: (params: any) => {\n return (\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n color: params?.row?.notificationIconColor,\n justifyContent: \"center\",\n height: \"100%\",\n }}\n >\n {params?.row?.notificationIcon ? (\n <FontAwesomeIcon icon={params.row.notificationIcon} />\n ) : (\n <></>\n )}\n </Box>\n );\n },\n },\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_NOTIFICATION_AR_TEXT\",\n fieldName: \"notificationArText\",\n required: true,\n fieldType: \"text\",\n gridProps: {\n muiProps: {\n renderCell: (params: any) => {\n return (\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n color: params?.row?.notificationTextColor,\n justifyContent: \"center\",\n height: \"100%\",\n }}\n >\n {params?.row?.notificationArText}\n </Box>\n );\n },\n },\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_NOTIFICATION_EN_TEXT\",\n fieldName: \"notificationEnText\",\n required: true,\n fieldType: \"text\",\n gridProps: {\n muiProps: {\n renderCell: (params: any) => {\n return (\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n color: params?.row?.notificationTextColor,\n justifyContent: \"center\",\n height: \"100%\",\n }}\n >\n {params?.row?.notificationEnText}\n </Box>\n );\n },\n },\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Last Runtime\",\n disabled: true,\n fieldName: \"lastIntervalRun\",\n fieldType: \"datetime\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Last Successful Runtime\",\n fieldName: \"lastSuccessfulRun\",\n disabled: true,\n fieldType: \"datetime\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Last Run Message\",\n fieldName: \"lastRunMessage\",\n disabled: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_NOTIFICATION_TEXT_COLOR\",\n fieldName: \"notificationTextColor\",\n required: false,\n gridProps: {\n hidden: true,\n },\n fieldType: \"text\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_NOTIFICATION_ICON_COLOR\",\n fieldName: \"notificationIconColor\",\n required: false,\n gridProps: {\n hidden: true,\n },\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_NOTIFICATION_ACTION\",\n fieldName: \"notificationAction\",\n required: false,\n fieldType: \"combobox\",\n comboboxValueDataType: \"string\",\n options: [{ value: \"NAVIGATION\" }],\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"Action Payload (must be a rout in case of NAVIGATION with parameter values betweem @@)\",\n fieldName: \"notificationActionPayload\",\n required: false,\n fieldType: \"text\",\n gridProps: {\n hidden: true,\n },\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"Organization Id Field on the Notification Query result set if it supports it\",\n fieldName: \"organizationIdField\",\n required: false,\n fieldType: \"text\",\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalIcon: \"bell\",\n modalTitle: \"System Notification\",\n modalWidth: \"300\",\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"NOTIFICATION_PLURAL\")}\n girdIcon=\"bell\"\n editAction={{ isEnabled: true, authority: \"NOTIFICATION_EDIT\" }}\n deleteAction={{ isEnabled: true, authority: \"NOTIFICATION_DELETE\" }}\n />\n );\n};\n\nexport default NotificationGrid;\n","import { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { Box, Button } from \"@mui/material\";\nimport { useSelector } from \"react-redux\";\nimport { useAxios, useSession } from \"../../hooks\";\nimport { useState } from \"react\";\nimport useInterval from \"../../hooks/useInterval\";\nimport { notificationsCheckIntervalSeconds } from \"../../layout/NotificationButton\";\nimport NotificationItem from \"./NotificationItem\";\n\nconst MyNotificationsPanel: React.FC = () => {\n const { UserInfo } = useSession();\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const { handleGetRequest, handlePostRequest } = useAxios();\n const [notifications, setNotifications] = useState<Array<Notification>>([]);\n const AppInfo = useSelector((state: any) => state.AppInfo.value);\n const acknowledgeAllCurrentNotifications = async () => {\n await handlePostRequest({\n endPointURI: \"api/v1/public/notification/all/notified\",\n showMask: true,\n });\n };\n\n const archiveAllCurrentNotifications = async () => {\n await handlePostRequest({\n endPointURI: \"api/v1/public/notification/all/archive\",\n showMask: true,\n });\n };\n\n const loadUserNotifications = () => {\n if (UserInfo.isAuthenticated === true) {\n handleGetRequest({\n endPointURI: \"api/v1/public/notifications\",\n showMask: false,\n successCallBkFn: (response: any) => {\n setNotifications(response.data);\n },\n });\n }\n };\n if (AppInfo?.enableUINotifications === true) {\n useInterval(\n loadUserNotifications,\n notificationsCheckIntervalSeconds * 1000\n );\n }\n\n return (\n <>\n <Box\n sx={{ display: \"flex\", alignItems: \"center\", justifyContent: \"center\" }}\n >\n <Box sx={{ flex: 1 }}></Box>\n <h3>\n <FontAwesomeIcon\n icon=\"bell\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n {AppLayout.appDirection === \"ltr\" ? \"Notifications\" : \"الاشعارات\"}\n </h3>\n <Box sx={{ flex: 1 }}></Box>\n <Button\n sx={{ textTransform: \"none\" }}\n onClick={acknowledgeAllCurrentNotifications}\n >\n Mark All Read\n </Button>\n <Button\n color=\"error\"\n sx={{ textTransform: \"none\" }}\n onClick={archiveAllCurrentNotifications}\n >\n Delete All\n </Button>\n </Box>\n <Box\n sx={{\n flex: 1,\n width: \"100%\",\n display: \"flex\",\n overflowY: \"auto\",\n }}\n >\n <Box\n sx={{\n flexGrow: 1,\n width: \"fit-content\",\n display: \"flex\",\n flexDirection: \"column\",\n overflowY: \"auto\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n }}\n >\n {notifications.map((notification: Notification, index) => {\n return (\n <NotificationItem\n {...notification}\n showDivider={index < notifications.length - 1}\n />\n );\n })}\n </Box>\n </Box>\n </>\n );\n};\n\nexport default MyNotificationsPanel;\n","import { Box } from \"@mui/material\";\nimport { useSession } from \"../hooks\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\n\ntype RouteWrapperProps = {\n authority?: string;\n applicationModule?: string;\n children?: React.ReactNode;\n};\nconst RouteWrapper: React.FC<RouteWrapperProps> = (props) => {\n const { isUserAuthorized, isCurrentOrganizationAuthorizedToModule } =\n useSession();\n if (\n props?.applicationModule &&\n !isCurrentOrganizationAuthorizedToModule(props?.applicationModule)\n ) {\n return (\n <Box\n sx={{\n flex: 1,\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"center\",\n color: \"red\",\n }}\n >\n <h2>\n <FontAwesomeIcon\n style={{ marginRight: 10, marginLeft: 10 }}\n icon=\"cancel\"\n />\n Your organization didn't subscribe for this system module\n </h2>\n </Box>\n );\n }\n if (props?.authority && !isUserAuthorized(props.authority)) {\n return (\n <Box\n sx={{\n flex: 1,\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"center\",\n color: \"red\",\n }}\n >\n <h2>\n <FontAwesomeIcon\n style={{ marginRight: 10, marginLeft: 10 }}\n icon=\"cancel\"\n />\n You aren't authorized to access this page\n </h2>\n </Box>\n );\n }\n return <>{props.children}</>;\n};\n\nexport default RouteWrapper;\n","import { Box } from \"@mui/material\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { CacheProvider } from \"@emotion/react\";\nimport { Route, Routes } from \"react-router-dom\";\nimport { cacheLtr, cacheRtl } from \"../components/common/LayoutHandlers\";\nimport { SYSTEM_ROUTES } from \"../routes\";\nimport { SystemRoute } from \"../routes/types\";\nimport RouteWrapper from \"./RouteWrapper\";\nimport { useAxios, useLoadingMask, useSession } from \"../hooks\";\nimport { useEffect, useState } from \"react\";\nimport { setStoreData } from \"../redux/features/common/CommonStoreSlice\";\n\nconst MainContent: React.FC = () => {\n const AppLayoutState = useSelector((state: any) => state.AppLayout);\n const AppInfo = useSelector((state: any) => state.AppInfo.value);\n const businessRoutes = useSelector(\n (state: any) => state.AppInfo.value.businessRoutes\n );\n const { UserInfo } = useSession();\n const dispatch = useDispatch();\n const { show, hide } = useLoadingMask();\n const commonStores = useSelector((state: any) => state.commonStores);\n const [isAutoLoadLoaded, setAutoLoadLoaded] = useState<boolean>(false);\n const { isUserAuthorized } = useSession();\n const { handleGetRequest } = useAxios();\n const loadCommonStores = async () => {\n show(\"Loading ... please wait\");\n setAutoLoadLoaded(false);\n const stores = commonStores.stores;\n const storeKeys = commonStores.storeKeys;\n for (let storeKey of storeKeys) {\n if (\n (stores[storeKey]?.authority === undefined ||\n stores[storeKey]?.authority === null ||\n isUserAuthorized(stores[storeKey]?.authority)) &&\n stores[storeKey]?.url != \"\" &&\n stores[storeKey].autoLoad === true\n ) {\n handleGetRequest({\n endPointURI: stores[storeKey].url,\n showMask: false,\n successCallBkFn: (response) => {\n dispatch(setStoreData({ storeKey, data: response.data }));\n },\n failureCallBkFn: () => {\n dispatch(setStoreData({ storeKey, data: [] }));\n },\n });\n }\n }\n setAutoLoadLoaded(true);\n hide();\n };\n\n useEffect(() => {\n if (commonStores?.storeKeys) {\n loadCommonStores();\n }\n }, [commonStores.storeKeys, UserInfo?.currentOrganization]);\n return (\n <CacheProvider\n value={AppLayoutState.appDirection === \"ltr\" ? cacheLtr : cacheRtl}\n >\n {/* {isAutoLoadLoaded ? ( */}\n <Box\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n // alignItems: \"center\",\n justifyContent: \"flex-start\",\n flex: 1,\n overflow: \"hidden\",\n padding: 3,\n }}\n >\n <Routes>\n {AppInfo.enableAdministrationModule\n ? SYSTEM_ROUTES.map((route: SystemRoute, index) => {\n return (\n <Route\n key={\"adm\" + index}\n path={route.path}\n element={\n <RouteWrapper\n authority={route.authority}\n applicationModule={route.applicationModule}\n >\n <route.component />\n </RouteWrapper>\n }\n />\n );\n })\n : null}\n {businessRoutes.map((route: SystemRoute, index) => {\n return (\n <Route\n key={\"bs\" + index}\n path={route.path}\n element={\n <RouteWrapper authority={route.authority}>\n <route.component />\n </RouteWrapper>\n }\n />\n );\n })}\n </Routes>\n </Box>\n </CacheProvider>\n );\n};\n\nexport default MainContent;\n","import { styled } from \"@mui/material/styles\";\nimport { grey } from \"@mui/material/colors\";\nimport SwipeableDrawer from \"@mui/material/SwipeableDrawer\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { Box, Typography } from \"@mui/material\";\nimport { AppLayoutActions } from \"../redux/features/common/AppLayoutSlice\";\nimport NavigationTree from \"./NavigationTree\";\nimport { setSideBarState } from \"../redux/features/common/SideBarSlice\";\n\nconst drawerBleeding = 56;\n\ninterface Props {\n /**\n * Injected by the documentation to work in an iframe.\n * You won't need it on your project.\n */\n window?: () => Window;\n}\n\nconst Puller = styled(\"div\")(({ theme }) => ({\n width: 30,\n height: 6,\n margin: 10,\n backgroundColor: grey[300],\n borderRadius: 3,\n // position: \"absolute\",\n top: 8,\n // left: \"calc(50% - 15px)\",\n ...theme.applyStyles(\"dark\", {\n backgroundColor: grey[900],\n }),\n}));\n\nexport default function MobileDrawer(props: Props) {\n const { window } = props;\n const SideBarState = useSelector((state: any) => state.SideBar);\n const AppInfo = useSelector((state: any) => state.AppInfo.value);\n const dispatch = useDispatch();\n const toggleDrawer = (newState: boolean) => {\n dispatch(setSideBarState(newState));\n };\n // This is used only for the example\n const container =\n window !== undefined ? () => window().document.body : undefined;\n\n return (\n <SwipeableDrawer\n container={container}\n anchor=\"bottom\"\n open={SideBarState.isOpened}\n onClose={() => {\n toggleDrawer(false);\n }}\n onOpen={() => {\n toggleDrawer(true);\n }}\n swipeAreaWidth={drawerBleeding}\n disableSwipeToOpen={false}\n ModalProps={{\n keepMounted: true,\n }}\n >\n <Box\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n height: \"100%\",\n overflow: \"hidden\",\n }}\n >\n <Puller />\n <Box\n sx={{\n flexGrow: 1,\n display: \"flex\",\n justifyContent: \"center\",\n width: \"99%\",\n overflowY: \"auto\",\n }}\n >\n <NavigationTree />\n </Box>\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"space-around\",\n marginTop: 1,\n width: \"100%\",\n }}\n >\n <Typography sx={{ fontSize: 12 }} color=\"textDisabled\">\n {AppInfo.appName}\n </Typography>\n <Typography sx={{ fontSize: 12 }} color=\"textDisabled\">\n V.{AppInfo.appVersion}\n </Typography>\n </Box>\n </Box>\n </SwipeableDrawer>\n );\n}\n","import { useSelector } from \"react-redux\";\nimport { Backdrop, CircularProgress } from \"@mui/material\";\nimport { useTranslation } from \"react-i18next\";\n\nconst LoadingMask: React.FC = () => {\n const { t } = useTranslation();\n const loadingMask = useSelector((state: any) => state.loadingMask.value);\n const AppLayoutState = useSelector((state: any) => state.AppLayout);\n\n return (\n <Backdrop\n dir={AppLayoutState.appDirection}\n sx={{ color: \"#fff\", zIndex: (theme) => theme.zIndex.drawer + 1 }}\n open={loadingMask.isOpened}\n >\n <CircularProgress color=\"inherit\" />\n <div style={{ marginRight: 10, marginLeft: 10 }}>\n {loadingMask?.message || t(\"DEFAULT_LOADING_MESSAGE\")}\n </div>\n </Backdrop>\n );\n};\n\nexport default LoadingMask;\n","import {\n Box,\n Button,\n CircularProgress,\n createTheme,\n Paper,\n TextField,\n Typography,\n} from \"@mui/material\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { ThemeProvider } from \"@emotion/react\";\nimport { useEffect, useState } from \"react\";\nimport axios from \"axios\";\nimport { toast } from \"react-toastify\";\nimport { UserSessionActions } from \"../../redux/features/common/UserSessionSlice\";\nimport {\n DARK_THEME_INITIAL_MAIN_COLOR,\n DARK_THEME_INITIAL_SECANDARY_COLOR,\n} from \"../../util\";\n\nconst Login: React.FC = () => {\n const appInfo = useSelector((state: any) => state.AppInfo.value);\n const [username, setUsername] = useState(\"\");\n const [password, setPassword] = useState(\"\");\n const [isLoginInProcess, setIsLoginInProcess] = useState(false);\n const UserSessionState = useSelector((state: any) => state.UserSession.value);\n const dispatch = useDispatch();\n const handleLogin = async () => {\n if (username == null || username == \"\") {\n toast.error(\"username is required to proceed\");\n return;\n }\n if (password == null || password == \"\") {\n toast.error(\"password is required to proceed\");\n return;\n }\n setIsLoginInProcess(true);\n let response: any = null;\n try {\n response = await axios.post(\n `${appInfo.apiBaseUrl}/api/auth/login`,\n {\n username,\n password,\n },\n {\n withCredentials: true,\n }\n );\n if (response.data != null && response.data !== \"\") {\n setIsLoginInProcess(false);\n const UserSession = {\n ...response.data,\n isAuthenticated: true,\n };\n if (response?.data?.token) {\n localStorage.setItem(\"TOKEN\", response.data.token);\n }\n dispatch(UserSessionActions.setAuthenticated(UserSession));\n }\n } catch (e: any) {\n setIsLoginInProcess(false);\n toast.error(\n e?.response?.data ||\n \"failed to authenticate, contact your administrator\"\n );\n }\n };\n const userSession = useSelector((state: any) => state.UserSession.value);\n const loginTheme = createTheme({\n components: {\n MuiCssBaseline: {\n styleOverrides: `\n /* Custom Scrollbar */\n * {\n scrollbar-width: thin;\n scrollbar-color: ${\n appInfo.appTheme?.dark?.primaryColor ||\n DARK_THEME_INITIAL_MAIN_COLOR\n } #121212;\n }\n \n /* Webkit Browsers */\n *::-webkit-scrollbar {\n width: 12px;\n height: 10px;\n } \n `,\n },\n },\n palette: {\n mode: \"dark\",\n primary: {\n main:\n appInfo.appTheme?.dark?.primaryColor || DARK_THEME_INITIAL_MAIN_COLOR,\n },\n secondary: {\n main:\n appInfo.appTheme?.dark?.secondaryColor ||\n DARK_THEME_INITIAL_SECANDARY_COLOR,\n },\n },\n });\n const checkUserSession = async () => {\n if (appInfo?.apiBaseUrl) {\n if (userSession.isAuthenticated == null) {\n const token = localStorage.getItem(\"TOKEN\");\n try {\n let response = await axios.get(\n `${appInfo.apiBaseUrl}/api/auth/userInfo`,\n {\n withCredentials: true,\n headers: { Authorization: `Bearer ${token}` },\n }\n );\n if (response != null && response.data != null) {\n const UserSession = {\n ...response.data,\n isAuthenticated: true,\n };\n dispatch(UserSessionActions.setAuthenticated(UserSession));\n } else {\n dispatch(UserSessionActions.setUnAuthenticated());\n }\n } catch (error) {\n dispatch(UserSessionActions.setUnAuthenticated());\n }\n }\n }\n };\n useEffect(() => {\n console.log(\"checking usersession on reload\", userSession);\n console.log(\"checking usersession app info\", appInfo);\n checkUserSession();\n }, [appInfo, userSession.isAuthenticated]);\n\n return (\n <ThemeProvider theme={loginTheme}>\n <Paper\n sx={{\n display: \"flex\",\n height: \"100vh\",\n width: \"100%\",\n borderRadius: 0,\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n {UserSessionState.isAuthenticated == false ? (\n <Box\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <img src={appInfo?.appLogo} width={150} height={150} />\n <Typography sx={{ m: 1 }} variant=\"h4\" color=\"textSecondary\">\n {appInfo?.appName}\n </Typography>\n <Typography\n sx={{\n paddingRight: 1,\n width: \"100%\",\n textAlign: \"right\",\n fontSize: 10,\n }}\n variant=\"caption\"\n color=\"textSecondary\"\n >\n V.{appInfo.appVersion}\n </Typography>\n <TextField\n label=\"username\"\n sx={{ width: 300, m: 1 }}\n value={username}\n onChange={(event) => {\n setUsername(event.target.value);\n }}\n onKeyDown={(event) => {\n if (event.key === \"Enter\") {\n handleLogin();\n }\n }}\n />\n <TextField\n label=\"password\"\n sx={{ width: 300, m: 1 }}\n value={password}\n type=\"password\"\n onChange={(event) => {\n setPassword(event.target.value);\n }}\n onKeyDown={(event) => {\n if (event.key === \"Enter\") {\n handleLogin();\n }\n }}\n />\n <Button\n loading={isLoginInProcess}\n onClick={handleLogin}\n variant=\"contained\"\n color=\"primary\"\n sx={{ m: 1 }}\n >\n login\n </Button>\n </Box>\n ) : (\n <>\n <CircularProgress sx={{ marginRight: 1 }} />\n <div>You will be redirected shortly ... please wait</div>\n </>\n )}\n </Paper>\n </ThemeProvider>\n );\n};\n\nexport default Login;\n","import { Box, Typography } from \"@mui/material\";\nimport {\n AppInfo,\n LicenseCheckObject,\n} from \"../../redux/features/common/AppInfoSlice\";\nimport { useSelector } from \"react-redux\";\nimport { useEffect, useState } from \"react\";\nimport { useAxios } from \"../../hooks\";\n\nconst NoLicenseComponent: React.FC = () => {\n const [licenseCheckObj, setLicenseCheckObject] = useState<LicenseCheckObject>(\n { isLicensed: true, lastLicenseCheckMessage: \"\", lastLicenseCheckTime: \"\" }\n );\n const { handleGetRequest } = useAxios();\n const appInfo: AppInfo = useSelector((state: any) => state.AppInfo.value);\n const checkSystemLicense = async () => {\n if (appInfo?.checkLicense?.endpoint) {\n await handleGetRequest({\n endPointURI: appInfo.checkLicense?.endpoint,\n successCallBkFn: (response) => {\n setLicenseCheckObject(response.data);\n },\n });\n }\n };\n\n useEffect(() => {\n if (appInfo?.checkLicense?.endpoint) {\n const interval = appInfo?.checkLicense?.interval || 60000;\n const intervalId = setInterval(() => {\n checkSystemLicense();\n }, interval);\n return () => {\n clearInterval(intervalId);\n console.log(\"Interval cleared\");\n };\n }\n }, [appInfo]);\n return !licenseCheckObj.isLicensed ? (\n <Box\n sx={{\n flex: 1,\n width: \"100%\",\n height: \"100%\",\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"center\",\n position: \"fixed\",\n top: 0,\n background: \"rgba(235, 235, 235, 0.8)\",\n left: 0,\n zIndex: 9999,\n }}\n >\n <img src={appInfo.appLogo} style={{ height: 200, width: 200 }} />\n <Typography variant=\"h5\">\n {appInfo.appName} - {appInfo.appVersion}\n </Typography>\n <Typography variant=\"h6\" color=\"error\">\n Your license is missing or has expired.\n </Typography>\n <Typography variant=\"h6\" color=\"error\">\n Please reach out to your vendor for assistance.\n </Typography>\n <Typography>\n License Check @{licenseCheckObj?.lastLicenseCheckTime || \"--------\"}\n </Typography>\n <Typography>\n License Check Result :{\" \"}\n {licenseCheckObj?.lastLicenseCheckMessage || \"--------\"}\n </Typography>\n </Box>\n ) : (\n <></>\n );\n};\n\nexport default NoLicenseComponent;\n","import { styled, useTheme } from \"@mui/material/styles\";\nimport CssBaseline from \"@mui/material/CssBaseline\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport TopBar from \"./TopBar\";\nimport { DrawerHeader } from \"./DrawerHeader\";\nimport SideBar from \"./SideBar\";\nimport MainContent from \"./MainContent\";\nimport { BrowserRouter } from \"react-router-dom\";\nimport MobileDrawer from \"./MobileDrawer\";\nimport { ToastContainer } from \"react-toastify\";\nimport { useIsMobile } from \"../hooks/UseMobile\";\nimport { DRAWER_WIDTH } from \"../redux/features/common/AppLayoutSlice\";\nimport { UserSessionProps } from \"../redux/features/common/UserSessionSlice\";\nimport LoadingMask from \"../components/common/LoadingMask\";\nimport Login from \"../components/common/Login\";\nimport NoLicenseComponent from \"../components/common/NoLicenseComponent\";\n\nconst Main = styled(\"main\", {\n shouldForwardProp: (prop) => prop !== \"open\",\n})<{\n open?: boolean;\n}>(({ theme: any, open }) => {\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const theme = useTheme();\n const isMobile = useIsMobile();\n\n return {\n display: \"flex\",\n flexDirection: \"column\",\n overflow: \"hidden\",\n flexGrow: 1,\n width: !isMobile && open ? `calc(100% - ${DRAWER_WIDTH}px)` : \"100%\",\n direction: AppLayout.appDirection,\n justifyContent: \"flex-start\",\n transition:\n open === true\n ? theme.transitions.create([\"margin\", \"width\"], {\n easing: theme.transitions.easing.easeOut,\n duration: theme.transitions.duration.enteringScreen,\n })\n : theme.transitions.create([\"margin\", \"width\"], {\n easing: theme.transitions.easing.sharp,\n duration: theme.transitions.duration.leavingScreen,\n }),\n marginLeft:\n !isMobile && AppLayout.appDirection === \"ltr\" && open === true\n ? DRAWER_WIDTH + \"px\"\n : 0,\n marginRight:\n !isMobile && AppLayout.appDirection === \"rtl\" && open === true\n ? DRAWER_WIDTH + \"px\"\n : 0,\n };\n});\n\nexport default function Layout() {\n const SideBarState = useSelector((state: any) => state.SideBar);\n\n const isMobile = useIsMobile();\n const UserSession: UserSessionProps = useSelector(\n (state: any) => state.UserSession\n );\n const AppLayout = useSelector((state: any) => state.AppLayout);\n return (\n <BrowserRouter>\n <ToastContainer\n rtl={AppLayout.appDirection === \"rtl\"}\n draggable={true}\n position=\"bottom-center\"\n />\n <LoadingMask />\n {UserSession.value.isAuthenticated === true ? (\n // licenseCheckObj?.isLicensed ? (\n <Main open={SideBarState.isOpened}>\n <CssBaseline />\n <TopBar />\n {!isMobile ? <SideBar /> : null}\n {isMobile ? <MobileDrawer /> : null}\n <DrawerHeader />\n <MainContent />\n <NoLicenseComponent />\n </Main>\n ) : (\n <Login />\n )}\n </BrowserRouter>\n );\n}\n","import { createSlice, Reducer } from \"@reduxjs/toolkit\";\nimport { SystemRoute } from \"../../../routes/types\";\nimport { ExtendedTreeItemProps } from \"../../../navigationItems\";\nimport { StoreMetaData } from \"./CommonStoreSlice\";\n\nexport type LicenseCheckObject = {\n isLicensed: boolean;\n lastLicenseCheckMessage: string;\n lastLicenseCheckTime: string;\n};\n\nexport type AppInfo = {\n documentTitle: string | null;\n apiBaseUrl: string | null;\n appName: string | null;\n appVersion: string | null;\n appLogo: any | null;\n businessLocals?: {\n ar: { [key: string]: string };\n en: { [key: string]: string };\n };\n businessRoutes?: Array<SystemRoute>;\n businessNavigationItems?: Array<ExtendedTreeItemProps>;\n businessReduxReducers?: { [key: string]: Reducer<any> };\n businessCommonStoresMetaData?: { [key: string]: StoreMetaData };\n muiPremiumKey: string;\n enableAdministrationModule: boolean;\n enableUINotifications: Boolean;\n appTheme?: {\n light: { primaryColor: string; secondaryColor: string };\n dark: { primaryColor: string; secondaryColor: string };\n };\n checkLicense?: { endpoint: string; interval: number };\n};\n\nexport type AppInfoProp = {\n value: AppInfo;\n};\n\nconst initialState: AppInfoProp = {\n value: {\n documentTitle: null,\n apiBaseUrl: null,\n appName: null,\n appVersion: null,\n appLogo: null,\n muiPremiumKey: null,\n enableAdministrationModule: false,\n enableUINotifications: false,\n businessRoutes: [],\n businessNavigationItems: [],\n businessReduxReducers: {},\n businessCommonStoresMetaData: {},\n appTheme: {\n light: { primaryColor: \"#37505C\", secondaryColor: \"#ff6d00\" },\n dark: { primaryColor: \"#ea690e\", secondaryColor: \"#74776B\" },\n },\n },\n};\n\nconst AppInfoSlice = createSlice({\n name: \"AppInfo\",\n initialState: initialState,\n reducers: {\n setAppInfo: (state, action) => {\n state.value = action.payload;\n },\n },\n});\n\nexport const AppInfoActions = AppInfoSlice.actions;\nexport default AppInfoSlice.reducer;\n","import { CommonStores } from \"../common/CommonStoreSlice\";\n\nexport const ADMINISTRATION_STORES: CommonStores = {\n SystemDataSourceType: {\n autoLoad: false,\n data: [{ value: \"Mysql\" }, { value: \"Oracle\" }, { value: \"DB2\" }],\n url: \"\",\n },\n SystemParameterTypes: {\n autoLoad: false,\n url: \"\",\n data: [\n { value: \"text\" },\n { value: \"number\" },\n { value: \"date\" },\n { value: \"datetime\" },\n { value: \"combobox\" },\n { value: \"checkbox\" },\n { value: \"html\" },\n { value: \"lookup\" },\n ],\n },\n SystemReportTypes: {\n autoLoad: false,\n url: \"\",\n data: [{ value: \"Excel\" }, { value: \"Jasper\" }, { value: \"Blueprint\" }],\n },\n SystemWidgetTypes: {\n autoLoad: false,\n url: \"\",\n data: [\n { name: \"LineChart\" },\n { name: \"ColumnChart\" },\n { name: \"PieChart\" },\n { name: \"Card\" },\n { name: \"CircularProgress\" },\n { name: \"LinearProgress\" },\n ],\n },\n SystemTimeIntervals: {\n autoLoad: false,\n url: \"\",\n data: [\n { value: \"second\" },\n { value: \"minute\" },\n { value: \"hour\" },\n { value: \"day\" },\n { value: \"week\" },\n { value: \"month\" },\n { value: \"year\" },\n ],\n },\n SystemMailRecipientTypes: {\n autoLoad: false,\n url: \"\",\n data: [{ name: \"To\" }, { name: \"CC\" }],\n },\n SystemOrganizations: {\n autoLoad: true,\n url: \"api/v1/public/organization/all\",\n data: [],\n },\n SystemOrganizationRanks: {\n autoLoad: true,\n url: \"api/v1/public/organization/ranks/all\",\n data: [],\n },\n CurrentOrganizationRanks: {\n autoLoad: true,\n url: \"api/v1/public/organizationrank/all\",\n data: [],\n },\n SystemOrganizationUnits: {\n autoLoad: true,\n url: \"api/v1/public/organization/units/all\",\n data: [],\n },\n CurrentOrganizationUnits: {\n autoLoad: true,\n url: \"api/v1/public/organizationunit/all\",\n data: [],\n },\n SystemOrganizationUnitType: {\n autoLoad: true,\n url: \"api/v1/public/organizationunittype/all\",\n data: [],\n },\n SystemDataSources: {\n autoLoad: true,\n data: [],\n authority: \"DEVELOPMENT_ADMIN\",\n url: \"api/v1/dev/datasourceconnection/all\",\n },\n SystemDataQueries: {\n autoLoad: true,\n data: [],\n authority: \"DEVELOPMENT_ADMIN\",\n url: \"api/v1/dev/dataquery/all\",\n },\n SystemBluePrints: {\n autoLoad: true,\n data: [],\n authority: \"DEVELOPMENT_ADMIN\",\n url: \"api/v1/dev/blueprint/all\",\n },\n SystemReports: {\n autoLoad: true,\n data: [],\n authority: \"DEVELOPMENT_ADMIN\",\n url: \"api/v1/dev/report/all\",\n },\n SystemEntityParameters: {\n autoLoad: true,\n data: [],\n authority: \"DEVELOPMENT_ADMIN\",\n url: \"api/v1/dev/entityparameter/all\",\n },\n SystemMailTemplates: {\n autoLoad: true,\n data: [],\n authority: \"DEVELOPMENT_ADMIN\",\n url: \"api/v1/dev/mailtemplate/all\",\n },\n SystemWidgets: {\n autoLoad: true,\n data: [],\n authority: \"DEVELOPMENT_ADMIN\",\n url: \"api/v1/dev/widget/all\",\n },\n SystemApplicationModules: {\n autoLoad: true,\n data: [],\n authority: \"SYSTEM_ADMIN\",\n url: \"api/v1/admin/systemapplicationmodule/application/all\",\n },\n SystemApplicationAuthorities: {\n autoLoad: true,\n data: [],\n authority: \"SYSTEM_ADMIN\",\n url: \"api/v1/admin/systemapplicationauthority/all\",\n },\n SystemApplicationRoles: {\n autoLoad: true,\n data: [],\n authority: \"SYSTEM_ADMIN\",\n url: \"api/v1/admin/systemapplicationrole/all\",\n },\n};\n","import { useDispatch, useSelector } from \"react-redux\";\nimport { createTheme, ThemeOptions } from \"@mui/material\";\nimport { ThemeProvider } from \"@emotion/react\";\nimport React, { useEffect } from \"react\";\nimport Layout from \"../layout/Layout\";\nimport { AppInfo, AppInfoActions } from \"../redux/features/common/AppInfoSlice\";\nimport { LicenseInfo } from \"@mui/x-license\";\nimport {\n DARK_THEME_INITIAL_MAIN_COLOR,\n DARK_THEME_INITIAL_SECANDARY_COLOR,\n LIGHT_THEME_INITIAL_MAIN_COLOR,\n LIGHT_THEME_INITIAL_SECANDARY_COLOR,\n} from \"../util\";\nimport { setStoresMetaData } from \"../redux/features/common/CommonStoreSlice\";\nimport { ADMINISTRATION_STORES } from \"../redux/features/administration/AdministrationStoresMetaData\";\n\nconst App: React.FC<AppInfo> = (props: AppInfo) => {\n const dispatch = useDispatch();\n LicenseInfo.setLicenseKey(props.muiPremiumKey);\n const LightThemeOptions: ThemeOptions = {\n components: {\n MuiCssBaseline: {\n styleOverrides: `\n /* Custom Scrollbar */\n * {\n scrollbar-width: thin;\n scrollbar-color: ${\n props.appTheme?.light?.primaryColor ||\n LIGHT_THEME_INITIAL_MAIN_COLOR\n } #ffffff;\n }\n \n /* Webkit Browsers */\n *::-webkit-scrollbar {\n width: 12px;\n height: 10px;\n } \n `,\n },\n },\n palette: {\n mode: \"light\",\n primary: {\n main:\n props.appTheme?.light?.primaryColor || LIGHT_THEME_INITIAL_MAIN_COLOR,\n },\n secondary: {\n main:\n props.appTheme?.light?.secondaryColor ||\n LIGHT_THEME_INITIAL_SECANDARY_COLOR,\n },\n background: {\n default: \"#f5f5f5\",\n paper: \"#f5f5f5\",\n },\n },\n };\n const DarkThemeOptions: ThemeOptions = {\n components: {\n MuiCssBaseline: {\n styleOverrides: `\n /* Custom Scrollbar */\n * {\n scrollbar-width: thin;\n scrollbar-color: ${\n props.appTheme?.dark?.primaryColor || DARK_THEME_INITIAL_MAIN_COLOR\n } #121212;\n }\n \n /* Webkit Browsers */\n *::-webkit-scrollbar {\n width: 12px;\n height: 10px;\n } \n `,\n },\n },\n palette: {\n mode: \"dark\",\n primary: {\n main:\n props.appTheme?.dark?.primaryColor || DARK_THEME_INITIAL_MAIN_COLOR,\n },\n secondary: {\n main:\n props.appTheme?.dark?.secondaryColor ||\n DARK_THEME_INITIAL_SECANDARY_COLOR,\n },\n },\n };\n\n const AppLayoutState = useSelector((state: any) => state.AppLayout);\n let themeOptions = { ...LightThemeOptions };\n if (AppLayoutState.themeMode === \"dark\") {\n themeOptions = { ...DarkThemeOptions };\n }\n const theme = createTheme({\n direction: AppLayoutState.appDirection,\n ...themeOptions,\n });\n useEffect(() => {\n document.title = props.documentTitle;\n dispatch(AppInfoActions.setAppInfo(props));\n let commonStores = {};\n if (props.enableAdministrationModule) {\n commonStores = { ...ADMINISTRATION_STORES };\n }\n if (props.businessCommonStoresMetaData) {\n commonStores = {\n ...commonStores,\n ...props.businessCommonStoresMetaData,\n };\n }\n dispatch(setStoresMetaData(commonStores));\n }, [props]);\n return (\n <ThemeProvider theme={theme}>\n <Layout />\n </ThemeProvider>\n );\n};\n\nexport default App;\n","import common from \"./common.json\";\nimport AdminLocalsEn from \"./adminLocalsEn.json\";\nimport devLocalsEn from \"./devLocalsEn.json\";\n\nexport const ENGLISH_TRANS = {\n ...common,\n ...AdminLocalsEn,\n ...devLocalsEn,\n};\n","import common from \"./common.json\";\nimport adminLocalsAr from \"./adminLocalsAr.json\";\nimport devLocalAr from \"./devLocalsAr.json\";\n\nexport const ARABIC_TRANS = {\n ...common,\n ...adminLocalsAr,\n ...devLocalAr,\n};\n","import { Provider } from \"react-redux\";\nimport { library } from \"@fortawesome/fontawesome-svg-core\";\nimport { fab } from \"@fortawesome/free-brands-svg-icons\";\nimport { far } from \"@fortawesome/free-regular-svg-icons\";\nimport { fas } from \"@fortawesome/free-solid-svg-icons\";\nimport \"../styles/index.css\";\nimport \"react-toastify/dist/ReactToastify.css\";\nimport App from \"./App\";\nimport { AppInfo } from \"../redux/features/common/AppInfoSlice\";\nimport AppLayoutReducer from \"../redux/features/common/AppLayoutSlice\";\nimport UserSessionReducer from \"../redux/features/common/UserSessionSlice\";\nimport LoadingMaskReducer from \"../redux/features/common/LoadingMaskSlice\";\nimport CommonStoreReducer from \"../redux/features/common/CommonStoreSlice\";\nimport AppInfoReducer from \"../redux/features/common/AppInfoSlice\";\nimport SideBarReducer from \"../redux/features/common/SideBarSlice\";\nimport { configureStore } from \"@reduxjs/toolkit\";\nimport i18n from \"../locales/i18n\";\nimport { initReactI18next } from \"react-i18next\";\nimport { ENGLISH_TRANS } from \"../locales/english\";\nimport { ARABIC_TRANS } from \"../locales/arabic\";\nimport { useEffect, useState } from \"react\";\n\nlibrary.add(fab);\nlibrary.add(far);\nlibrary.add(fas);\n\nexport const BaseApp: React.FC<AppInfo> = (props) => {\n // let store = null;\n const [systemReducers, setSystemReducers] = useState<any>({\n AppLayout: AppLayoutReducer,\n UserSession: UserSessionReducer,\n loadingMask: LoadingMaskReducer,\n commonStores: CommonStoreReducer,\n SideBar: SideBarReducer,\n AppInfo: AppInfoReducer,\n });\n const store = configureStore({\n reducer: systemReducers,\n });\n const [isAppInitialized, setIsAppInitialized] = useState<boolean>(false);\n const initializeApp = () => {\n const reducers = {\n AppLayout: AppLayoutReducer,\n UserSession: UserSessionReducer,\n loadingMask: LoadingMaskReducer,\n commonStores: CommonStoreReducer,\n SideBar: SideBarReducer,\n AppInfo: AppInfoReducer,\n ...props?.businessReduxReducers,\n };\n setSystemReducers((state) => {\n return { ...reducers };\n });\n const resources = {\n en: { translation: { ...ENGLISH_TRANS, ...props?.businessLocals?.en } },\n ar: { translation: { ...ARABIC_TRANS, ...props?.businessLocals?.ar } },\n };\n i18n.use(initReactI18next).init({\n resources: resources, // Where we're gonna put translations' files\n lng: localStorage.getItem(\"language\") || \"en\", // Set the initial language of the App\n fallbackLng: \"en\",\n });\n setIsAppInitialized(true);\n };\n useEffect(() => {\n initializeApp();\n }, [props]);\n return isAppInitialized ? (\n <Provider store={store}>\n <App {...props} />\n </Provider>\n ) : (\n <></>\n );\n};\n"],"names":["css","ref","insertAt","document","head","getElementsByTagName","style","createElement","type","firstChild","insertBefore","appendChild","styleSheet","cssText","createTextNode","useIsMobile","breakpoint","isMobile","setIsMobile","useState","window","innerWidth","useEffect","handleResize","addEventListener","removeEventListener","DRAWER_WIDTH","AppLayoutSlice","createSlice","name","themeMode","localStorage","getItem","appDirection","reducers","setThemeMode","state","action","payload","setAppDirection","AppLayoutActions","actions","AppLayoutReducer","reducer","loadingMaskSlice","value","isOpened","message","showLoadingMask","hideLoadingMask","LoadingMaskReducer","useLoadingMask","dispatch","useDispatch","show","hide","UserSessionSlice","isAuthenticated","authorities","setAuthenticated","setUnAuthenticated","UserSessionActions","UserSessionReducer","useAxios","mask","apiBaseUrl","useSelector","AppInfo","axiosInstance","axios","create","baseURL","timeout","withCredentials","defaults","interceptors","request","use","config","token","headers","Authorization","error","Promise","reject","response","status","toast","autoClose","data","Blob","text","then","handleGetRequest","async","props","undefined","showMask","loadingMessage","get","endPointURI","params","parameters","responseType","successCallBkFn","failureCallBkFn","handlePostRequest","post","handleDeleteRequest","delete","HandleDownloadHTTPPostPDF","handleUploadRequest","files","length","formData","FormData","file","append","useConfirmationWindow","open","setOpen","t","useTranslation","ConfirmationWindow","_jsxs","Dialog","children","_jsx","DialogTitle","title","DialogContent","DialogContentText","body","DialogActions","Button","variant","sx","marginRight","marginLeft","color","onClick","onConfirmationCallBk","autoFocus","useSession","UserSession","UserInfo","isUserAuthorized","authorityCode","grantedAuthority","authority","isCurrentOrganizationAuthorizedToModule","moduleCode","currentOrganization","systemApplicationModules","subscripedModule","toLowerCase","useWindow","windowState","setWindowState","AppLayout","Window","windowProps","Modal","zIndex","theme","drawer","onClose","onCloseCallBack","Box","dir","position","top","left","maxHeight","transform","height","width","minWidth","minHeight","overflow","bgcolor","display","flexDirection","alignItems","justifyContent","AppBar","Toolbar","FontAwesomeIcon","icon","windowIcon","Typography","component","windowTitle","flexGrow","IconButton","Paper","padding","commonStoreSlice","initialState","stores","storeKeys","setStoresMetaData","Object","keys","setStoreData","storeKey","CommonStoreReducer","useApiActions","apiActionsProps","CommonStores","commonStores","session","reloadData","commonStoreKey","url","setData","findAll","loadRecordById","recordId","record","findById","findByIdParamName","saveRecord","savedRecord","save","deleteRecordById","result","deleteById","deleteByIdParamName","TemplateTextField","TextField","slotProps","inputLabel","shrink","fontWeight","label","_Fragment","helperText","not","a","b","filter","indexOf","intersection","TransferList","valueField","displayField","options","selectedOptions","setSelection","checked","setChecked","React","setLeft","right","setRight","leftFilterValue","setLeftFilterValue","rightFilterValue","setRightFilterValue","leftChecked","rightChecked","handleToggle","currentIndex","newChecked","push","splice","numberOfChecked","items","handleToggleAll","customList","unfilteredItems","side","option","toLocaleLowerCase","includes","Card","CardHeader","px","py","avatar","Checkbox","indeterminate","disabled","inputProps","subheader","fullWidth","onChange","event","target","Divider","List","dense","role","map","ListItemButton","cursor","ListItemIcon","tabIndex","disableRipple","ListItemText","id","primary","Grid2","container","spacing","margin","flex","direction","my","size","oldState","newState","concat","CheckBox","FormControlLabel","hidden","required","control","checkedValue","e","onChangeCallBack","unCheckedValue","ComboBox","AppLayoutState","Autocomplete","v","getValue","newValue","clearOnBlur","handleHomeEndKeys","getOptionLabel","renderOption","props1","slots","popper","Popper","renderInput","errorMessage","DATE_FORMAT","DATE_TIME_FORMAT","LIGHT_THEME_INITIAL_MAIN_COLOR","LIGHT_THEME_INITIAL_SECANDARY_COLOR","DARK_THEME_INITIAL_MAIN_COLOR","DARK_THEME_INITIAL_SECANDARY_COLOR","Datefield","LocalizationProvider","dateAdapter","AdapterMoment","DatePicker","moment","format","momentValue","isValid","textField","InputLabelProps","DatetimeField","DateTimePicker","SystemLookupCombobox","setOptions","lookupType","loadLookupOptions","generateDateColumn","colDef","renderEditCell","api","setEditCellValue","field","valueParser","row","column","valueFormatter","generateDateTimeColumn","generateComboColumn","valueGetter","renderCell","find","item","selectedRecord","generateCheckBoxColumn","getElementFields","element","fields","mode","elements","childElement","getAllFields","constructGridColumnsFromFields","isDefaultEditable","columns","tableField","fieldType","gridProps","muiProps","editable","fieldName","headerName","fieldLabel","headerAlign","align","searchable","optionValueField","optionDisplayField","constructValidationSchema","validationSchemaObj","z","number","required_error","invalid_type_error","optional","nullable","boolean","comboboxValueDataType","string","min","getGridSelection","rowSelectionModel","keyColumnName","sRecords","sRecordIds","ids","selectedId","x","selectedRecords","selectedRecordIds","formatMuiErrorMessage","code","args","URL","forEach","arg","searchParams","process","env","NODE_ENV","reactIsModule","exports","Symbol","for","c","d","f","g","h","k","l","m","n","p","q","r","w","y","u","$$typeof","A","reactIs_production_min","AsyncMode","ConcurrentMode","ContextConsumer","Element","ForwardRef","Fragment","Lazy","Portal","Profiler","StrictMode","Suspense","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isProfiler","isStrictMode","isSuspense","isValidElementType","typeOf","require$$0","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","object","$$typeofType","ContextProvider","Memo","hasWarnedAboutDeprecatedIsAsyncMode","reactIs_development","console","isPortal","getOwnPropertySymbols","hasOwnProperty","prototype","propIsEnumerable","propertyIsEnumerable","objectAssign","assign","test1","String","getOwnPropertyNames","test2","i","fromCharCode","join","test3","split","letter","err","shouldUseNative","source","from","symbols","to","val","TypeError","toObject","s","arguments","key","call","ReactPropTypesSecret_1","has","Function","bind","printWarning","ReactPropTypesSecret","loggedTypeFailures","require$$1","Error","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","ex","stack","resetWarningCache","checkPropTypes_1","ReactIs","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","iterator","ANONYMOUS","ReactPropTypes","array","createPrimitiveTypeChecker","bigint","bool","func","symbol","any","createChainableTypeChecker","arrayOf","typeChecker","propName","propFullName","PropTypeError","propValue","Array","isArray","getPropType","elementType","instanceOf","expectedClass","expectedClassName","constructor","node","isNode","objectOf","propType","oneOf","expectedValues","is","valuesString","JSON","stringify","getPreciseType","oneOfType","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedType","shape","shapeTypes","invalidValidatorError","exact","allKeys","this","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","secret","cacheKey","chainedCheckType","every","iteratorFn","maybeIterable","getIteratorFn","step","entries","next","done","entry","RegExp","isSymbol","Date","PropTypes","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","REACT_CONSUMER_TYPE","REACT_VIEW_TRANSITION_TYPE","REACT_CLIENT_REFERENCE","reactIs_production","SuspenseList","isSuspenseList","getModuleId","isPlainObject","getPrototypeOf","toStringTag","deepClone","output","deepmerge","clone","createBreakpoints","breakpoints","xs","sm","md","lg","xl","unit","other","sortedValues","breakpointsAsArray","sort","breakpoint1","breakpoint2","reduce","acc","obj","sortBreakpointsValues","up","down","between","start","end","endIndex","only","keyIndex","replace","sortContainerQueries","containerQueries","sorted","startsWith","regex","match","borderRadius","responsivePropType","merge","defaultBreakpoints","defaultContainerQueries","containerName","handleBreakpoints","styleFromPropValue","themeBreakpoints","index","breakpointKeys","some","containerKey","shorthand","matches","_formatErrorMessage","containerQuery","Number","isNaN","getContainerQuery","cssKey","removeUnusedBreakpoints","breakpointOutput","capitalize","charAt","toUpperCase","slice","getPath","path","checkVars","vars","getStyleValue","themeMapping","propValueFinal","userValue","prop","cssProperty","themeKey","fn","propTypes","filterProps","properties","directions","aliases","marginX","marginY","paddingX","paddingY","getCssProperties","cache","memoize","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","defaultValue","themeSpacing","abs","Math","isInteger","transformed","createUnarySpacing","transformer","resolveCssProperty","cssProperties","getStyleFromPropValue","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","gap","columnGap","rowGap","paletteTransform","sizingTransform","maxWidth","breakpointsValues","defaultSxConfig","backgroundColor","pt","pr","pb","pl","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd","mt","mr","mb","ml","mx","marginTop","marginBottom","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd","displayPrint","textOverflow","visibility","whiteSpace","flexBasis","flexWrap","alignContent","order","flexShrink","alignSelf","justifyItems","justifySelf","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","bottom","boxShadow","boxSizing","font","fontFamily","fontSize","fontStyle","letterSpacing","textTransform","lineHeight","textAlign","typography","styleFunctionSx","getThemeValue","nested","unstable_sxConfig","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsInput","breakpointsInOrder","createEmptyBreakpointObject","breakpointsKeys","styleKey","maybeFn","objects","union","Set","objectsHaveSameKeys","modularCssLayers","unstable_createStyleFunctionSx","applyStyles","colorSchemes","getColorSchemeSelector","selector","palette","useTheme","defaultTheme","contextTheme","useContext","ThemeContext","systemDefaultTheme","paletteInput","spacingInput","shapeInput","mui","argsInput","argument","createSpacing","muiTheme","components","themeInput","toContainerQuery","mediaQuery","attachCq","cssContainerQueries","unstable_sx","createTheme","extendSxProp","inSx","systemProps","otherProps","splitProps","finalSx","defaultGenerator","ClassNameGenerator","generate","configure","generator","reset","createClassNameGenerator","o","clsx","globalStateClasses","active","completed","expanded","focused","focusVisible","readOnly","selected","themeId","defaultClassName","generateClassName","BoxRoot","tag","stylesFactory","emStyled","styled","shouldForwardProp","forwardRef","inProps","useThemeWithoutDefault","className","as","createBox","globalStatePrefix","slot","globalStateClass","generateUtilityClass","generateUtilityClasses","root","hasDigitsOnly","str","test","isNumber","isNumeric","trim","capitalizeFirstLetter","isValidEmail","email","timeAgo","dateInput","date","now","diffInSeconds","floor","locale","rtf","Intl","RelativeTimeFormat","numeric","units","seconds","delta","FormElementField","fieldInfo","formManager","formActions","formValues","getFieldLabel","formProps","fieldLabelFn","hiddenFields","fieldSize","muiTextFieldProps","disabledFields","setValue","formValuesChangeCallBk","fieldHeight","formState","errors","toString","dateFormat","FormAction","setConfirmationWindowState","confirmationMessage","actionFn","formActionProps","actionButtonVariant","actionButtonColor","preActionValidation","isConfirmationRequired","FormElementGroup","AttachmentImageViewer","imgSrc","setImgSrc","imagePath","attachmentId","attachmentCode","refKey","category","handleImageSrc","showAsAvatar","Avatar","onError","onErrorImage","src","loading","alt","objectFit","AttachmentCard","allowDownload","downloadAuthorityKey","setAttachmentConfig","handleDelete","CardMedia","docType","CardContent","gutterBottom","fileName","attachmentSize","remark","CardActions","allowDelete","Tooltip","createObjectURL","link","href","setAttribute","click","remove","AttachmentPanel","setFiles","attachmentCategories","setAttachmentCategories","setRemark","selectedCategory","setSelectedCategory","allowedTypes","setAllowedTypes","attachmentConfig","getFileExtension","pop","loadAttachmentConfig","allowedFileTypes","cats","showAttachments","allowUpload","enableAttachment","uploadAuthorityKey","maxAllowedNumberOfFiles","refKeyAttachments","accept","multiple","fileExt","multiline","rows","existingAttachments","isCategoryRequired","MAX_SIZE_KB","maxSizeBytes","success","refKeyAttachment","WorkflowDocumentTimeLine","overflowY","actionHistory","actionHistoryRecord","actionTime","actionMethod","personId","documentActionEnName","documentActionArName","actionComment","employeeEnName","employeeArName","TemplateGridMultiRecordAction","rowAction","recordsToProcessActionOn","recordIdsToProcessActionOn","isActionAllowed","StyledQuickFilter","QuickFilter","StyledToolbarButton","ToolbarButton","ownerState","opacity","pointerEvents","transition","transitions","StyledTextField","overflowX","TemplateGridTopBar","isCreationAuthorized","templateProps","editAction","gridSelection","editMode","handleCreateNewRecord","rowActions","gridActionProps","multiRecord","_createElement","apiActions","gridLoadParametersValues","tBar","ColumnsPanelTrigger","render","GridViewColumnIcon","FilterPanelTrigger","Badge","badgeContent","filterCount","GridFilterListIcon","gridStateKey","clearGridState","orientation","flexItem","ExportExcel","MenuItem","QuickFilterTrigger","triggerProps","enterDelay","QuickFilterControl","controlProps","inputRef","placeholder","input","startAdornment","InputAdornment","endAdornment","QuickFilterClear","edge","TemplateGridRecordAction","iconStyle","getActionIconStyleForRecord","isActionVisibleForRecord","isActionDisabledForRecord","GridActionsCellItem","showInMenu","reloadGridAfterAction","currentNewRecordIndex","loadGridState","saved","parse","saveGridState","statePart","current","setItem","PIN_FIXED_COLUMNS","TemplateGrid","setSelectedRecord","attachmentPanelEnabledForRecord","setAttachmentPanelEnabledForRecord","getLookupOptions","generateLookupGridColumn","useLookupGridColumn","AttachmentWindow","setAttachmentWindowState","gridTitle","WorkFlowWindow","setWorkFlowWindowState","generatedColumns","setGeneratedColumns","formElements","savedState","useMemo","initialVisibilityState","columnVisibilityModel","existingFields","themeDirection","setColumnVisibilityModel","columnOrder","setColumnOrder","columnWidths","setColumnWidths","gridRowGroupingModel","setGridRowGroupingModel","columnGroupingModel","newLeft","pinnedColumns","newRight","setPinnedColumns","navigate","useNavigate","recordToDelete","setRecordToDelete","recordToEdit","setRecordToEdit","rowModesModel","setRowModesModel","adjustGridColumns","gridColumns","setRowSelectionModel","validationSchema","isEditAllowed","isDeleteAllowed","deleteAction","setConfirmationWindowOpened","isNew","postActionCallBack","oldData","formModalHeight","formModalWidth","formModalMinHeight","formModalMinWidth","formModalIcon","formModalTitle","specs","modalHeight","modalWidth","modalMinHeight","modalMinWidth","modalIcon","modalTitle","FormWindow","setFormWindowState","actionColumn","isEnabled","attachment","workFlowDocumentCode","getActions","disableDefaultAction","isInEditMode","GridRowModes","Edit","View","handleSaveRowClick","ignoreModifications","newData","handleCancelRowEditClick","isEditActionVisibleForRecord","isActionEditDisabledForRecord","formRoute","handleEditRecord","isDeleteActionVisibleForRecord","isDeleteActionDisabledForRecord","enableAttachFn","structuredColumns","autoLoad","adjustedColumns","baseCols","col","fieldToCol","Map","Boolean","formComponent","recordIdToEdit","formCloseCallBk","TemplateForm","editAuthorityKey","formSavedSuccessfullyCallBk","preSaveValidation","hideInfoBar","hideBackButton","girdIcon","gridLoadParameters","setGridLoadParametersValues","Accordion","defaultExpanded","AccordionSummary","expandIcon","GridExpandMoreIcon","AccordionDetails","saveButtonSpecs","cancelButtonSpecs","WorkflowDocumentPanel","refDocumentId","postActionCallBk","cancelActionCallBk","DataGridPremium","toolbar","newRecord","oldRows","oldModel","removeItem","getRowId","showToolbar","checkboxSelection","onRowEditStop","reason","defaultMuiPrevented","onRowModesModelChange","newModel","rowGroupingColumnMode","processRowUpdate","log","ZodError","validateRecord","requestObject","reloadAfterSave","onRowSelectionModelChange","gridSelectionModel","onColumnVisibilityModelChange","model","onColumnOrderChange","targetIndex","prevOrder","currentOrder","fromIndex","rowGroupingModel","onRowGroupingModelChange","handleRowGroupChange","getGridColumnsFromRecord","formElement","ExcelReportViewer","reportData","report_record_data_key","setReportData","reloadReport","useParameterPanel","parametersValues","setParametersValues","initialParameterValues","panelElements","parameterValues","parameter","parameterLabel","parameterCode","parameterType","mandatory","getFormElementsFromParameters","ParameterPanel","searchBtnClickCallBk","prefix","iconName","isIdRequired","enabled","ReportViewer","blobUrl","setBlobUrl","setErrorMessage","excelReportData","setExcelReportData","reportViewerState","setReportViewerState","reportInfo","setReportInfo","reportParameters","reportParametersValues","runReport","reportType","reportCode","resultMode","jasperOutPutFileType","contentDisposition","filename","blob","download","removeChild","revokeObjectURL","byPassParameterEntry","loadReportData","reportName","setAction","authorizedActions","setAuthorizedActions","setActionComment","workflowDocumentInfo","setWorkflowDocumentInfo","referencedDocument","workflowDocumentReport","workflowDocument","workflowDocumentStatus","actionsHistory","nextActionTakers","nextActions","ReporTViewWindow","setReportViewWindowState","documentEnName","documentNumberField","documentArName","loadWorkFlowDocumentInfo","workflowDocumentCode","processWorkflowDocumentAction","workflowDocumentId","actionId","refDocumentStatus","documentStatusCode","post_action_endpoint","nextActionTakersAuthority","actionTaker","username","USERNAME","doc_id","documentStatusEnName","documentStatusArName","startIcon","require_comment","pre_action_endpoint","nextActionTaker","employee_en_name","employee_ar_name","mobile_number","WorkflowWindow","setWorkflowWindowState","initiallyHiddenFields","setHiddenFields","initialValues","setDisabledFields","formSchema","useForm","resolver","zodResolver","defaultValues","watch","pathParameters","useParams","formRouteRecordIdParamName","loadRecord","idToLoad","retrievedRecord","setFieldValue","fieldValue","hideField","oldValues","showField","disableField","enableField","handleSubmit","WorkflowRouteComponent","TemplateBarChart","BarChart","dataset","xAxis","dataKey","scaleType","valueLabel","series","labelField","TemplateDataCard","TemplateGauge","Gauge","valueMax","total","TemplateLineChart","LineChart","LinearProgressWithLabel","LinearProgress","round","TemplateLineProgress","TemplatePieChart","chartData","PieChart","WidgetViewer","isWidgetLoading","setWidgetLoading","loadWidget","queryId","dataQueryId","getWidgetData","loadCounter","widgetType","verticalAxisField","spin","widgetTitle","horizontalAxisField","horizontalAxisLabel","DashboardViewer","dashboardInfo","setDashboardInfo","dashboardCode","dashboardName","dashboardTitle","dashboardParameters","widgets","setLoadCounter","loadDashboard","setLoadDashboard","shouldLoadWidgets","loadDashboardInfo","widget","DashboardRouteView","ChangeOrgForm","newOrgId","setNewOrgId","userOrganizations","orgId","successChangeCallBackFn","SideBarSlice","toggleSideBarState","setSideBarState","SideBarReducer","useInterval","callback","delay","savedCallback","useRef","setInterval","clearInterval","beatFade","keyframes","NotificationItem","notification","notificationId","notificationAction","notificationActionPayload","isNotified","notificationQueueId","notificationTextColor","notificationIcon","notificationIconColor","notificationEnText","notificationArText","animation","createTime","showDivider","NotificationButton","anchorEl","setAnchorEl","notifications","setNotifications","info","closeOnClick","notificationsCheckIntervalSeconds","ClickAwayListener","onClickAway","currentTarget","anchorOrigin","vertical","horizontal","notificaiton","placement","TransitionProps","Fade","ChangePasswordPanel","currentPassword","setCurrentPassword","password1","setPassword1","password2","setPassword2","selectedPerson","isSelfService","newPassword","onSuccessCallBk","handleChangePasswordRequest","MuiAppBar","easing","sharp","duration","leavingScreen","variants","easeOut","enteringScreen","TopBar","ChangeOrgWindow","setChangeOrgWindowState","anchorElUser","setAnchorElUser","handleCloseUserMenu","handleOpenUserMenu","SideBarState","SideBar","ChangePasswordWindow","setChangePasswordWindow","Menu","keepMounted","transformOrigin","noWrap","appName","organizationEnName","organizationArName","i18n","language","nextLanguage","lng","changeLanguage","enableUINotifications","rotation","DrawerHeader","mixins","findNavigationItemById","nodes","found","NavigationItems","actionPayload","DotIcon","verticalAlign","StyledTreeItemRoot","TreeItem2Root","grey","treeItemClasses","groupTransition","CustomTreeItemContent","TreeItem2Content","dark","main","content","alpha","contrastText","AnimatedCollapse","animated","Collapse","TransitionComponent","useSpring","in","StyledTreeItemLabelText","CustomLabel","expandable","appLayoutState","TreeItem2Label","isExpandable","reactChildren","CustomTreeItem","itemId","getRootProps","getContentProps","getIconContainerProps","getCheckboxProps","getLabelProps","getGroupTransitionProps","getDragAndDropOverlayProps","publicAPI","useTreeItem2","rootRef","TreeItem2Provider","TreeItem2IconContainer","TreeItem2Icon","TreeItem2Checkbox","TreeItem2DragAndDropOverlay","NavigationTree","filterData","parentItems","parentItem","applicationModule","newParentItem","structuredClone","mergedNavigationItems","enableAdministrationModule","businessNavigationItems","authoriedNavigationItems","RichTreeView","onItemClick","navigationItem","Drawer","anchor","appVersion","cacheRtl","createCache","stylisPlugins","prefixer","rtlPlugin","cacheLtr","OrgMemberRoleForm","setSelectedOptions","availableOptions","setAvailableOptions","orgMemberId","organizationId","currentRoles","availableRoles","getOrgMemberRoles","closeModalFn","OrganizationMemberGrid","OrganizationMemberRolesWindow","setOrganizationMemberRolesWindowState","SystemOrganizations","SystemOrganizationRanks","SystemOrganizationUnits","OrganizationRankGrid","loadOrganizationRanks","OrganizationUnitGrid","organizationUnitTypes","SystemOrganizationUnitType","loadOrganizationUnits","OrganizationUnitTypeGrid","SystemApplicationAuthorityGrid","SystemApplicationModules","SystemApplicationModuleGrid","RoleAuthoritiesForm","availableAuthorities","setAvailableAuthorities","roleId","selectedAuthorities","getRoleAuthorities","SystemApplicationRoleGrid","selectedRole","setSelectedRole","RoleaAuthoritiesWindow","setRoleAuthoritiesWindowState","DataQueryParameterGrid","SystemEntityParameters","LookupGrid","ReportParameterGrid","reportId","storageTypes","adjustFormAfterValueChange","useSysCon","MailRecipientGrid","mailTemplateId","recipientMail","MailBodyGrid","SystemDataQueries","MailAttachmentGrid","SystemReports","validationObject","Gmail","mailHost","isMandatory","isVisible","mailPort","mailUsername","mailPassword","mailProtocol","isMailSmtpAuthEnabled","isMailStarttlsEnabled","isSmtpSSlEnabled","azureGraphApiClientId","azureGraphApiClientSecret","azureGraphApiTenantId","azureGraphApiScope","azureGraphApiEmailId","Azure","adjustFormAccordingToEngineType","validationObjects","WorkflowDocumentStatusGrid","WorkflowDocumentActionMailGrid","SystemMailTemplates","documentActionId","WorkflowDocumentActionGrid","ActionMailsWindow","setActionMailWindowState","workflowStates","setWorkflowStates","loadWorkFlowDocumentStates","DashboardWidgetGrid","SystemWidgets","dashboardId","SYSTEM_ROUTES","setSelectedPerson","CurrentOrganizationRanks","CurrentOrganizationUnits","OrganizationMembersWindow","setOrganizationMemberWindowState","organizationMemberId","refSource","DataQueryParameterWindow","setDataQueryParameterWindow","SystemDataSources","SystemDataSourceType","SystemParameterTypes","ReporTrialWindow","setReportTrialWindowState","ReportParameterWindow","setReportParameterWindowState","SystemBluePrints","useSysDatasource","datasourceConId","reportJasperName","reportBluePrintId","reportExcelDataQueryId","SystemTimeIntervals","MailRecipentsWindow","setMailRecipientsWindowState","MailBodiesWindow","setMailBodiesWindowState","MailAttachmentWindow","setMailAttachmentWindowState","callBkFn","periodical","periodType","periodValue","startSendingAt","onValueChangeCallBack","formLoadCallBk","mailEngine","WorkflowStatusWindow","setWorkflowStatusWindowState","WorkflowActionWindow","setWorkflowActionWindowState","SystemWidgetTypes","WidgetsWindows","setWidgetsWindowState","mailNotificationQueueId","resendMail","loadUserNotifications","RouteWrapper","MainContent","businessRoutes","isAutoLoadLoaded","setAutoLoadLoaded","loadCommonStores","CacheProvider","Routes","route","Route","Puller","MobileDrawer","toggleDrawer","SwipeableDrawer","onOpen","swipeAreaWidth","disableSwipeToOpen","ModalProps","LoadingMask","loadingMask","Backdrop","CircularProgress","Login","appInfo","setUsername","password","setPassword","isLoginInProcess","setIsLoginInProcess","UserSessionState","handleLogin","userSession","loginTheme","MuiCssBaseline","styleOverrides","appTheme","primaryColor","secondary","secondaryColor","checkUserSession","ThemeProvider","appLogo","onKeyDown","NoLicenseComponent","licenseCheckObj","setLicenseCheckObject","isLicensed","lastLicenseCheckMessage","lastLicenseCheckTime","checkLicense","endpoint","intervalId","checkSystemLicense","interval","background","Main","Layout","BrowserRouter","ToastContainer","rtl","draggable","CssBaseline","AppInfoSlice","documentTitle","muiPremiumKey","businessReduxReducers","businessCommonStoresMetaData","light","setAppInfo","AppInfoActions","AppInfoReducer","ADMINISTRATION_STORES","SystemReportTypes","SystemMailRecipientTypes","SystemApplicationAuthorities","SystemApplicationRoles","App","LicenseInfo","setLicenseKey","LightThemeOptions","default","paper","DarkThemeOptions","themeOptions","ENGLISH_TRANS","common","AdminLocalsEn","ARABIC_TRANS","adminLocalsAr","library","add","fab","far","fas","BaseApp","systemReducers","setSystemReducers","store","configureStore","isAppInitialized","setIsAppInitialized","resources","en","translation","businessLocals","ar","initReactI18next","init","fallbackLng","initializeApp","Provider"],"mappings":"0oJAAA,SAAqBA,EAAKC,QACX,IAARA,IAAiBA,EAAM,CAAA,GAC5B,IAAIC,EAAWD,EAAIC,SAEnB,GAAgC,oBAAbC,SAAnB,CAEA,IAAIC,EAAOD,SAASC,MAAQD,SAASE,qBAAqB,QAAQ,GAC9DC,EAAQH,SAASI,cAAc,SACnCD,EAAME,KAAO,WAEI,QAAbN,GACEE,EAAKK,WACPL,EAAKM,aAAaJ,EAAOF,EAAKK,YAKhCL,EAAKO,YAAYL,GAGfA,EAAMM,WACRN,EAAMM,WAAWC,QAAUb,EAE3BM,EAAMK,YAAYR,SAASW,eAAed,GAnBW,CAqBzD,kRCvBae,GAAc,CAACC,EAAa,OACvC,MAAOC,EAAUC,GAAeC,GAASC,OAAOC,WAAaL,GAQ7D,OANAM,GAAU,KACR,MAAMC,EAAe,IAAML,EAAYE,OAAOC,WAAaL,GAE3D,OADAI,OAAOI,iBAAiB,SAAUD,GAC3B,IAAMH,OAAOK,oBAAoB,SAAUF,IACjD,CAACP,IAEGC,GCTIS,GAAe,IAYtBC,GAAiBC,GAAY,CACjCC,KAAM,yBAN6B,CACnCC,UAAWC,aAAaC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AAQC,GAAe,CAC3BlyD,QAAS+xD,KAEJI,EAAkBC,GAAuB5zD,IAAkB,GA4BlE,OAHAG,GAAU,KAxBY,MACpB,MAAMY,EAAW,CACf6H,UAAWrH,GACXsG,YAAalF,GACbgsD,YAAa5sD,GACbgK,aAAcJ,GACd6zC,QAASvE,GACTj4C,QAAS8uD,MACNltD,GAAO6sD,uBAEZ+B,EAAmBvyD,IACV,IAAKF,KAEd,MAAM8yD,EAAY,CAChBC,GAAI,CAAEC,YAAa,IAAKnB,MAAkBhuD,GAAOovD,gBAAgBF,KACjEG,GAAI,CAAEF,YAAa,IAAKhB,MAAiBnuD,GAAOovD,gBAAgBC,MAElE/T,GAAKx8C,IAAIwwD,IAAkBC,KAAK,CAC9BN,UAAWA,EACXxT,IAAKz/C,aAAaC,QAAQ,aAAe,KACzCuzD,YAAa,OAEfR,GAAoB,IAGpBS,IACC,CAACzvD,IACG+uD,EACL/sD,EAAC0tD,EAAQ,CAACb,MAAOA,EAAK9sD,SACpBC,EAACwrD,GAAG,IAAKxtD,MAGXgC,EAAA6G,EAAA,CAAA","x_google_ignoreList":[0,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67]}
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../node_modules/style-inject/dist/style-inject.es.js","../src/hooks/UseMobile.tsx","../src/redux/features/common/AppLayoutSlice.ts","../src/redux/features/common/LoadingMaskSlice.ts","../src/hooks/useLoadingMask.tsx","../src/redux/features/common/UserSessionSlice.ts","../src/hooks/useAxios.tsx","../src/hooks/UseConfirmationWindow.tsx","../src/hooks/UseSession.tsx","../src/hooks/UseWindow.tsx","../src/redux/features/common/CommonStoreSlice.ts","../src/hooks/useApiActions.ts","../src/components/templates/DataEntryTemplates/TemplateDataForm/FormFields/TemplateTextField.tsx","../src/components/templates/TransferList.tsx","../src/components/templates/DataEntryTemplates/TemplateDataForm/FormFields/CheckBox.tsx","../src/components/templates/DataEntryTemplates/TemplateDataForm/FormFields/ComboBox.tsx","../src/util/constants.ts","../src/components/templates/DataEntryTemplates/TemplateDataForm/FormFields/Datefield.tsx","../src/components/templates/DataEntryTemplates/TemplateDataForm/FormFields/DatetimeField.tsx","../src/components/templates/DataEntryTemplates/TemplateDataForm/FormFields/SystemLookupCombobox.tsx","../src/components/templates/DataEntryTemplates/TemplateDataGrid/DataGridColumnsUtil.tsx","../src/components/templates/DataEntryTemplates/DataEntryUtil.ts","../node_modules/@mui/utils/esm/formatMuiErrorMessage/formatMuiErrorMessage.js","../node_modules/prop-types/node_modules/react-is/index.js","../node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.js","../node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js","../node_modules/object-assign/index.js","../node_modules/prop-types/lib/ReactPropTypesSecret.js","../node_modules/prop-types/lib/has.js","../node_modules/prop-types/checkPropTypes.js","../node_modules/prop-types/factoryWithTypeCheckers.js","../node_modules/prop-types/factoryWithThrowingShims.js","../node_modules/prop-types/index.js","../node_modules/react-is/cjs/react-is.production.js","../node_modules/react-is/cjs/react-is.development.js","../node_modules/react-is/index.js","../node_modules/@mui/utils/esm/deepmerge/deepmerge.js","../node_modules/@mui/system/esm/createBreakpoints/createBreakpoints.js","../node_modules/@mui/system/esm/cssContainerQueries/cssContainerQueries.js","../node_modules/@mui/system/esm/createTheme/shape.js","../node_modules/@mui/system/esm/responsivePropType/responsivePropType.js","../node_modules/@mui/system/esm/merge/merge.js","../node_modules/@mui/system/esm/breakpoints/breakpoints.js","../node_modules/@mui/utils/esm/capitalize/capitalize.js","../node_modules/@mui/system/esm/style/style.js","../node_modules/@mui/system/esm/spacing/spacing.js","../node_modules/@mui/system/esm/memoize/memoize.js","../node_modules/@mui/system/esm/compose/compose.js","../node_modules/@mui/system/esm/borders/borders.js","../node_modules/@mui/system/esm/cssGrid/cssGrid.js","../node_modules/@mui/system/esm/palette/palette.js","../node_modules/@mui/system/esm/sizing/sizing.js","../node_modules/@mui/system/esm/styleFunctionSx/defaultSxConfig.js","../node_modules/@mui/system/esm/styleFunctionSx/styleFunctionSx.js","../node_modules/@mui/system/esm/createTheme/applyStyles.js","../node_modules/@mui/system/esm/useThemeWithoutDefault/useThemeWithoutDefault.js","../node_modules/@mui/system/esm/useTheme/useTheme.js","../node_modules/@mui/system/esm/createTheme/createTheme.js","../node_modules/@mui/system/esm/createTheme/createSpacing.js","../node_modules/@mui/system/esm/styleFunctionSx/extendSxProp.js","../node_modules/@mui/utils/esm/ClassNameGenerator/ClassNameGenerator.js","../node_modules/clsx/dist/clsx.mjs","../node_modules/@mui/utils/esm/generateUtilityClass/generateUtilityClass.js","../node_modules/@mui/system/esm/Box/boxClasses.js","../node_modules/@mui/system/esm/Box/Box.js","../node_modules/@mui/system/esm/createBox/createBox.js","../node_modules/@mui/styled-engine/esm/index.js","../node_modules/@mui/utils/esm/generateUtilityClasses/generateUtilityClasses.js","../src/util/AppUtils.ts","../src/components/templates/DataEntryTemplates/TemplateDataForm/FormElementField.tsx","../src/components/templates/DataEntryTemplates/TemplateDataForm/FormAction.tsx","../src/components/templates/DataEntryTemplates/TemplateDataForm/FormElementGroup.tsx","../src/components/templates/attachment/AttachmentImageViewer.tsx","../src/components/templates/attachment/AttachmentCard.tsx","../src/components/templates/attachment/AttachmentPanel.tsx","../src/components/templates/workflow/WorkflowDocumentTimeLine.tsx","../src/components/templates/DataEntryTemplates/TemplateDataGrid/TemplateGridMultiRecordAction.tsx","../src/components/templates/DataEntryTemplates/TemplateDataGrid/TemplateGridTopBar.tsx","../src/components/templates/DataEntryTemplates/TemplateDataGrid/TemplateGridRecordAction.tsx","../src/components/templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid.tsx","../src/hooks/useLookupGridColumn.tsx","../src/components/templates/report/ExcelReportViewer.tsx","../src/hooks/useParameterPanel.tsx","../src/components/templates/report/ReportViewer.tsx","../src/components/templates/workflow/WorkflowDocumentPanel.tsx","../src/components/templates/DataEntryTemplates/TemplateDataForm/TemplateForm.tsx","../src/components/templates/workflow/WorkflowRouteComponent.tsx","../src/components/templates/visuals/charts/TemplateBarChart.tsx","../src/components/templates/visuals/charts/TemplateDataCard.tsx","../src/components/templates/visuals/charts/TemplateGauge.tsx","../src/components/templates/visuals/charts/TemplateLineChart.tsx","../src/components/templates/visuals/charts/TemplateLineProgress.tsx","../src/components/templates/visuals/charts/TemplatePieChart.tsx","../src/components/templates/visuals/WidgetViewer.tsx","../src/components/templates/visuals/DashboardViewer.tsx","../src/components/templates/visuals/DashboardRouteView.tsx","../src/components/common/ChangeOrgForm.tsx","../src/redux/features/common/SideBarSlice.ts","../src/hooks/useInterval.tsx","../src/components/common/NotificationItem.tsx","../src/layout/NotificationButton.tsx","../src/components/administration/admin/ChangePasswordPanel.tsx","../src/layout/TopBar.tsx","../src/locales/i18n.ts","../src/layout/DrawerHeader.tsx","../src/navigationItems/index.tsx","../src/navigationItems/Administration/index.tsx","../src/navigationItems/Administration/adminNavigationItems.tsx","../src/layout/NavigationTree.tsx","../src/layout/SideBar.tsx","../src/components/common/LayoutHandlers.tsx","../src/components/administration/admin/OrgMemberRoleForm.tsx","../src/components/administration/admin/OrganizationMemberGrid.tsx","../src/components/administration/admin/OrganizationRankGrid.tsx","../src/components/administration/admin/OrganizationUnitGrid.tsx","../src/components/administration/admin/OrganizationUnitTypeGrid.tsx","../src/components/administration/admin/SystemApplicationAuthorityGrid.tsx","../src/components/administration/admin/SystemApplicationModuleGrid.tsx","../src/components/administration/admin/RoleAuthoritiesForm.tsx","../src/components/administration/admin/SystemApplicationRoleGrid.tsx","../src/components/administration/dev/DataQueryParameterGrid.tsx","../src/components/administration/dev/LookupGrid.tsx","../src/components/administration/dev/ReportParameterGrid.tsx","../src/components/administration/dev/AttachmentConfigGrid.tsx","../src/components/administration/dev/ReportGrid.tsx","../src/components/administration/dev/MailRecipientGrid.tsx","../src/components/administration/dev/MailBodyGrid.tsx","../src/components/administration/dev/MailAttachmentGrid.tsx","../src/components/administration/dev/MailSenderConfigGrid.tsx","../src/components/administration/dev/WorkflowDocumentStatusGrid.tsx","../src/components/administration/dev/WorkflowDocumentActionMailGrid.tsx","../src/components/administration/dev/WorkflowDocumentActionGrid.tsx","../src/components/administration/dev/DashboardWidgetGrid.tsx","../src/routes/index.ts","../src/routes/administration/index.ts","../src/routes/administration/adminRoutes.tsx","../src/components/administration/admin/OrganizationGrid.tsx","../src/components/administration/admin/OrganizationMemberRoleGrid.tsx","../src/components/administration/admin/PersonGrid.tsx","../src/components/administration/admin/SystemApplicationGrid.tsx","../src/components/administration/admin/SystemApplicationRoleAuthorityGrid.tsx","../src/components/administration/admin/OrganizationApplicationModuleGrid.tsx","../src/routes/administration/devRoutes.tsx","../src/components/administration/dev/BluePrintGrid.tsx","../src/components/administration/dev/DataQueryGrid.tsx","../src/components/administration/dev/DatasourceConnectionGrid.tsx","../src/components/administration/dev/EntityParameterGrid.tsx","../src/components/administration/dev/MailTemplateGrid.tsx","../src/components/administration/dev/WorkflowDocumentGrid.tsx","../src/components/administration/dev/WidgetGrid.tsx","../src/components/administration/dev/DashboardGrid.tsx","../src/components/administration/dev/WorkflowDocumentMailLogGrid.tsx","../src/components/administration/dev/MailNotificationQueueGrid.tsx","../src/components/administration/dev/NotificationGrid.tsx","../src/components/common/MyNotificationsPanel.tsx","../src/layout/RouteWrapper.tsx","../src/layout/MainContent.tsx","../src/layout/MobileDrawer.tsx","../src/components/common/LoadingMask.tsx","../src/components/common/Login.tsx","../src/components/common/NoLicenseComponent.tsx","../src/layout/Layout.tsx","../src/redux/features/common/AppInfoSlice.ts","../src/redux/features/administration/AdministrationStoresMetaData.ts","../src/components/App.tsx","../src/locales/english/index.ts","../src/locales/arabic/index.ts","../src/components/BaseApp.tsx"],"sourcesContent":["function styleInject(css, ref) {\n if ( ref === void 0 ) ref = {};\n var insertAt = ref.insertAt;\n\n if (!css || typeof document === 'undefined') { return; }\n\n var head = document.head || document.getElementsByTagName('head')[0];\n var style = document.createElement('style');\n style.type = 'text/css';\n\n if (insertAt === 'top') {\n if (head.firstChild) {\n head.insertBefore(style, head.firstChild);\n } else {\n head.appendChild(style);\n }\n } else {\n head.appendChild(style);\n }\n\n if (style.styleSheet) {\n style.styleSheet.cssText = css;\n } else {\n style.appendChild(document.createTextNode(css));\n }\n}\n\nexport default styleInject;\n","import { useEffect, useState } from \"react\";\n\nexport const useIsMobile = (breakpoint = 768) => {\n const [isMobile, setIsMobile] = useState(window.innerWidth < breakpoint);\n\n useEffect(() => {\n const handleResize = () => setIsMobile(window.innerWidth < breakpoint);\n window.addEventListener(\"resize\", handleResize);\n return () => window.removeEventListener(\"resize\", handleResize);\n }, [breakpoint]);\n\n return isMobile;\n};\n","import { createSlice } from \"@reduxjs/toolkit\";\n\nexport const DRAWER_WIDTH = 350;\n\ninterface AppLayoutState {\n themeMode: \"light\" | \"dark\" | string;\n appDirection: \"ltr\" | \"rtl\";\n}\n\nconst initialState: AppLayoutState = {\n themeMode: localStorage.getItem(\"themeMode\") || \"light\",\n appDirection: localStorage.getItem(\"language\") == \"ar\" ? \"rtl\" : \"ltr\",\n};\n\nconst AppLayoutSlice = createSlice({\n name: \"AppLayout\",\n initialState,\n reducers: {\n setThemeMode: (state, action) => {\n state.themeMode = action.payload;\n },\n setAppDirection: (state, action) => {\n state.appDirection = action.payload;\n },\n },\n});\n\nexport const AppLayoutActions = AppLayoutSlice.actions;\nexport default AppLayoutSlice.reducer;\n","import { createSlice, PayloadAction } from \"@reduxjs/toolkit\";\n\ninterface LoadingMaskStateValue {\n value: { isOpened: boolean; message?: string | null };\n}\n\nconst initialState: LoadingMaskStateValue = {\n value: { isOpened: false, message: null },\n};\n\nconst loadingMaskSlice = createSlice({\n name: \"loadingMask\",\n initialState,\n reducers: {\n showLoadingMask: (\n state,\n action: PayloadAction<string | null | undefined>\n ) => {\n state.value.isOpened = true;\n state.value.message = action.payload;\n },\n hideLoadingMask: (state) => {\n state.value.isOpened = false;\n state.value.message = null;\n },\n },\n});\n\nexport const { showLoadingMask, hideLoadingMask } = loadingMaskSlice.actions;\nexport default loadingMaskSlice.reducer;\n","import { useDispatch } from \"react-redux\";\nimport { hideLoadingMask, showLoadingMask } from \"../redux/features/common/LoadingMaskSlice\";\n\n\nconst useLoadingMask = () => {\n const dispatch = useDispatch();\n const show = (message?: string) => {\n dispatch(showLoadingMask(message));\n };\n const hide = () => {\n dispatch(hideLoadingMask());\n };\n return { show, hide };\n};\n\nexport default useLoadingMask;\n","import { createSlice } from \"@reduxjs/toolkit\";\n\nexport interface OrganizationProps {\n organizationCode?: string;\n organizationName?: string;\n}\n\nexport interface UserSessionProps {\n value: {\n isAuthenticated: boolean | null;\n employeeNumber?: string;\n employeeName?: string;\n mobileNumber?: string;\n email?: string;\n isEmployeeArchived?: string;\n organizationCode?: string;\n organizationUnitId?: string;\n organizationUnitArName?: string;\n organizationUnitEnName?: string;\n organizationRankId?: string;\n rankCode?: string;\n rankName?: string;\n rankOrder?: string;\n currentOrganization?: any;\n userOrganizations?: Array<OrganizationProps>;\n authorities: Array<{ authority: string }>;\n };\n}\n\nconst initialState: UserSessionProps = {\n value: {\n isAuthenticated: null,\n authorities: [],\n },\n};\n\nconst UserSessionSlice = createSlice({\n name: \"UserSession\",\n initialState,\n reducers: {\n setAuthenticated: (state, action) => {\n state.value = action.payload;\n },\n setUnAuthenticated: (state) => {\n state.value = {\n isAuthenticated: false,\n authorities: [],\n };\n },\n },\n});\n\nexport const UserSessionActions = UserSessionSlice.actions;\nexport default UserSessionSlice.reducer;\n","import { toast } from \"react-toastify\";\nimport axios, { ResponseType } from \"axios\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport useLoadingMask from \"./useLoadingMask\";\nimport { UserSessionActions } from \"../redux/features/common/UserSessionSlice\";\n\nexport interface APIRequest {\n endPointURI: string;\n parameters?: any;\n data?: any;\n showMask?: Boolean;\n loadingMessage?: string;\n successCallBkFn?: Function;\n failureCallBkFn?: Function;\n headers?: any;\n responseType?: ResponseType;\n}\n\nexport interface UploadAttachmentRequest {\n endPointURI: string;\n showMask?: Boolean;\n parameters?: any;\n loadingMessage?: string;\n successCallBkFn?: Function;\n failureCallBkFn?: Function;\n files: FileList;\n}\n\nconst useAxios = () => {\n const mask = useLoadingMask();\n const dispatch = useDispatch();\n const apiBaseUrl = useSelector(\n (state: any) => state.AppInfo.value.apiBaseUrl\n );\n const axiosInstance = axios.create({\n baseURL: apiBaseUrl,\n timeout: 600000,\n withCredentials: true,\n });\n\n axiosInstance.defaults.withCredentials = true;\n axiosInstance.interceptors.request.use(\n (config) => {\n const token = localStorage.getItem(\"TOKEN\");\n if (token) {\n config.headers.Authorization = `Bearer ${token}`;\n }\n return config;\n },\n (error) => Promise.reject(error)\n );\n axiosInstance.interceptors.response.use(\n (response: any) => {\n return response;\n },\n (error: any) => {\n if (\n error\n ? error.response\n ? error.response.status\n ? error.response.status === 401\n : false\n : false\n : false\n ) {\n dispatch(UserSessionActions.setUnAuthenticated());\n toast.error(\"your session is now expired, you need to login again\", {\n autoClose: false,\n });\n } else if (\n error\n ? error.response\n ? error.response.status\n ? error.response.status === 402\n : false\n : false\n : false\n ) {\n dispatch(UserSessionActions.setUnAuthenticated());\n toast.error(\n \"Your license is missing or has expired,Please reach out to your vendor for assistance.\"\n );\n } else if (\n error\n ? error.response\n ? error.response.status\n ? error.response.status === 403\n : false\n : false\n : false\n ) {\n toast.error(\"you aren't authorized to process this request\");\n } else if (\n error\n ? error.response\n ? error.response.status\n ? error.response.status === 500\n : false\n : false\n : false\n ) {\n if (error.response.data instanceof Blob) {\n const blob = error.response.data;\n blob.text().then((text) => {\n toast.error(text);\n });\n } else {\n toast.error(error.response.data);\n }\n } else {\n toast.error(\n \"failed to communicate with the server ... try again later\"\n );\n }\n return \"ERROR\";\n }\n );\n const handleGetRequest = async (props: APIRequest) => {\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.show(props.loadingMessage);\n }\n const response: any = await axiosInstance.get(props.endPointURI, {\n params: { ...props.parameters },\n withCredentials: true,\n headers: props.headers,\n responseType: props?.responseType,\n });\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.hide();\n }\n if (response !== \"ERROR\") {\n if (\n props.successCallBkFn !== undefined &&\n props.successCallBkFn != null\n ) {\n props.successCallBkFn(response);\n }\n return response;\n } else {\n if (\n props.failureCallBkFn !== undefined &&\n props.failureCallBkFn != null\n ) {\n props.failureCallBkFn(response);\n }\n return \"ERROR\";\n }\n };\n\n const HandleDownloadHTTPPostPDF = async (\n props: APIRequest = { endPointURI: \"\", parameters: {}, data: {} }\n ) => {\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.show(props.loadingMessage);\n }\n const response: any = await axiosInstance.post(\n props.endPointURI,\n props.data,\n {\n responseType: \"blob\",\n }\n );\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.hide();\n }\n if (response !== \"ERROR\") {\n if (\n props.successCallBkFn !== undefined &&\n props.successCallBkFn != null\n ) {\n props.successCallBkFn(response);\n }\n return response;\n } else {\n if (\n props.failureCallBkFn !== undefined &&\n props.failureCallBkFn != null\n ) {\n props.failureCallBkFn(response);\n }\n return \"ERROR\";\n }\n };\n const handlePostRequest = async (props: APIRequest) => {\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.show(props.loadingMessage);\n }\n let response: any = await axiosInstance.post(\n props.endPointURI,\n props.data,\n {\n params: props.parameters,\n responseType: props?.responseType,\n headers: props?.headers,\n }\n );\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.hide();\n }\n if (response !== \"ERROR\") {\n if (\n props.successCallBkFn !== undefined &&\n props.successCallBkFn != null\n ) {\n props.successCallBkFn(response);\n }\n return response;\n } else {\n if (\n props.failureCallBkFn !== undefined &&\n props.failureCallBkFn != null\n ) {\n props.failureCallBkFn(response);\n }\n return \"ERROR\";\n }\n };\n const handleDeleteRequest = async (props: APIRequest) => {\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.show(props.loadingMessage);\n }\n let response: any = await axiosInstance.delete(props.endPointURI, {\n params: {\n ...props.parameters,\n },\n responseType: props?.responseType,\n headers: props?.headers,\n });\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.hide();\n }\n if (response !== \"ERROR\") {\n if (\n props.successCallBkFn !== undefined &&\n props.successCallBkFn != null\n ) {\n props.successCallBkFn(response);\n }\n return response;\n } else {\n if (\n props.failureCallBkFn !== undefined &&\n props.failureCallBkFn != null\n ) {\n props.failureCallBkFn(response);\n }\n return \"ERROR\";\n }\n };\n\n const handleUploadRequest = async (props: UploadAttachmentRequest) => {\n if (props.files === null || props.files.length === 0) {\n toast.error(\"You must add files to upload\");\n return \"ERROR\";\n }\n const formData = new FormData();\n for (const file of props.files) {\n formData.append(\"files\", file);\n }\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.show(props.loadingMessage);\n }\n let response: any = await axiosInstance.post(props.endPointURI, formData, {\n params: props?.parameters,\n headers: {\n \"Content-Type\": \"multipart/form-data\",\n },\n });\n if (\n props.showMask !== undefined &&\n props.showMask != null &&\n props.showMask === true\n ) {\n mask.hide();\n }\n if (response !== \"ERROR\") {\n if (\n props.successCallBkFn !== undefined &&\n props.successCallBkFn != null\n ) {\n props.successCallBkFn(response);\n }\n return response;\n } else {\n if (\n props.failureCallBkFn !== undefined &&\n props.failureCallBkFn != null\n ) {\n props.failureCallBkFn(response);\n }\n return \"ERROR\";\n }\n };\n return {\n handleGetRequest,\n handlePostRequest,\n handleDeleteRequest,\n HandleDownloadHTTPPostPDF,\n handleUploadRequest,\n };\n};\n\nexport default useAxios;\n","import {\n Button,\n Dialog,\n DialogActions,\n DialogContent,\n DialogContentText,\n DialogTitle,\n} from \"@mui/material\";\nimport { useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\ninterface ConfirmationWindowProps {\n title: string;\n body: string;\n onConfirmationCallBk: () => void;\n}\n\nexport const useConfirmationWindow = (props: ConfirmationWindowProps) => {\n const [open, setOpen] = useState<boolean>(false);\n const { t } = useTranslation();\n const ConfirmationWindow: React.FC = () => {\n return (\n <Dialog open={open}>\n <DialogTitle>{props.title}</DialogTitle>\n <DialogContent>\n <DialogContentText>{props.body}</DialogContentText>\n </DialogContent>\n <DialogActions>\n <Button\n variant=\"contained\"\n sx={{marginRight:2,marginLeft:2}}\n color=\"primary\"\n onClick={() => {\n setOpen(false);\n }}\n >\n {t(\"NO_LABEL\")}\n </Button>\n <Button\n variant=\"contained\"\n sx={{marginRight:2,marginLeft:2}}\n color=\"error\"\n onClick={() => {\n props.onConfirmationCallBk();\n setOpen(false);\n }}\n autoFocus\n >\n {t(\"YES_LABEL\")}\n </Button>\n </DialogActions>\n </Dialog>\n );\n };\n return { ConfirmationWindow, open, setOpen };\n};\n","import { useSelector } from \"react-redux\";\n\nconst useSession = () => {\n const UserSession = useSelector((state: any) => state.UserSession);\n const UserInfo = UserSession.value;\n\n const isCurrentOrganizationAuthorizedToModule = (\n moduleCode: string\n ): Boolean => {\n if (UserInfo?.currentOrganization?.systemApplicationModules) {\n for (const subscripedModule of UserInfo.currentOrganization\n .systemApplicationModules) {\n if (subscripedModule.toLowerCase() == moduleCode.toLowerCase()) {\n return true;\n }\n }\n }\n return false;\n };\n const isUserAuthorized = (authorityCode: string): boolean => {\n if (UserSession?.value?.authorities) {\n for (let grantedAuthority of UserSession.value.authorities) {\n if (\n authorityCode === \"DEVELOPMENT_ADMIN\" &&\n (grantedAuthority?.authority === \"DEVELOPMENT_ADMIN\" ||\n grantedAuthority?.authority === \"ORGANIZATION_ADMIN\")\n ) {\n return true;\n } else if (\n authorityCode === \"ORGANIZATION_ADMIN\" &&\n grantedAuthority?.authority === \"ORGANIZATION_ADMIN\"\n ) {\n return true;\n } else if (\n authorityCode !== \"DEVELOPMENT_ADMIN\" &&\n authorityCode !== \"ORGANIZATION_ADMIN\"\n ) {\n if (\n grantedAuthority?.authority === \"ORGANIZATION_ADMIN\" ||\n grantedAuthority?.authority === \"DEVELOPMENT_ADMIN\" ||\n grantedAuthority?.authority === \"SYSTEM_ADMIN\" ||\n grantedAuthority?.authority === authorityCode\n ) {\n return true;\n }\n }\n }\n }\n return false;\n };\n return {\n UserSession,\n isUserAuthorized,\n isCurrentOrganizationAuthorizedToModule,\n UserInfo,\n };\n};\n\nexport default useSession;\n","import { useEffect, useState } from \"react\";\nimport {\n AppBar,\n Box,\n IconButton,\n Modal,\n Paper,\n Toolbar,\n Typography,\n} from \"@mui/material\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { IconProp } from \"@fortawesome/fontawesome-svg-core\";\nimport { useSelector } from \"react-redux\";\n\nexport interface TemplateWindowProp {\n height?: any;\n width?: any;\n minWidth?: any;\n minHeight?: any;\n windowIcon?: IconProp;\n windowTitle?: string;\n onCloseCallBack?: any;\n}\n\ninterface WindowProps {\n children?: React.ReactNode;\n}\n\nexport const useWindow = (props: TemplateWindowProp) => {\n const [windowState, setWindowState] = useState(false);\n const appDirection = useSelector(\n (state: any) => state.AppLayout.appDirection\n );\n const Window: React.FC<WindowProps> = (windowProps: WindowProps) => {\n return (\n <Modal\n open={windowState}\n sx={{ zIndex: (theme) => theme.zIndex.drawer }}\n onClose={() => {\n if (!windowState && props?.onCloseCallBack) {\n props.onCloseCallBack();\n }\n }}\n >\n <Box\n dir={appDirection}\n sx={{\n position: \"absolute\",\n top: \"50%\",\n left: \"50%\",\n maxHeight: \"90%\",\n transform: \"translate(-50%, -50%)\",\n height: props?.height || \"80%\",\n width: props?.width || \"90%\",\n minWidth: props.minWidth || 400,\n minHeight: props.minHeight || 200,\n overflow: \"hidden\",\n bgcolor: \"modalBackground.main\",\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n }}\n >\n <AppBar position=\"static\">\n <Toolbar variant=\"dense\">\n <FontAwesomeIcon\n icon={props?.windowIcon || \"window-maximize\"}\n style={{ marginRight: 5 }}\n />\n <Typography variant=\"h6\" color=\"inherit\" component=\"div\">\n {props?.windowTitle || \"window\"}\n </Typography>\n <div style={{ flexGrow: 1 }}></div>\n <IconButton\n onClick={() => {\n setWindowState(false);\n if (\n props.onCloseCallBack != undefined &&\n props.onCloseCallBack != null\n ) {\n props.onCloseCallBack();\n }\n }}\n color=\"secondary\"\n >\n <FontAwesomeIcon icon=\"xmark-square\" />\n </IconButton>\n </Toolbar>\n </AppBar>\n <Paper\n sx={{\n // flexGrow: 1,\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n width: \"100%\",\n height: \"100%\",\n padding: 1,\n // justifyContent: \"center\",\n overflow: \"hidden\",\n }}\n >\n {windowProps?.children}\n </Paper>\n </Box>\n </Modal>\n );\n };\n return { windowState, setWindowState, Window };\n};\n","import { createSlice, PayloadAction } from \"@reduxjs/toolkit\";\n\nexport type CommonStores = {\n [key: string]: StoreMetaData;\n};\n\nexport type CommonStoresInterface = {\n stores: { [key: string]: StoreMetaData };\n storeKeys: Array<String>;\n};\n\ninterface setStoreDataProps {\n storeKey: string;\n data: Array<any>;\n}\n\nexport type StoreMetaData = {\n url: string;\n data: Array<any>;\n autoLoad: boolean;\n authority?: string;\n};\n\nexport const commonStoresInitialState: CommonStoresInterface = {\n stores: {},\n storeKeys: [],\n};\n\nconst commonStoreSlice = createSlice({\n name: \"commonStores\",\n initialState: commonStoresInitialState,\n reducers: {\n setStoresMetaData: (state, action) => {\n state.stores = action.payload;\n state.storeKeys = Object.keys(action.payload);\n },\n setStoreData: (state, action: PayloadAction<setStoreDataProps>) => {\n state.stores[action.payload.storeKey].data = action.payload.data;\n },\n },\n});\n\nexport const { setStoreData, setStoresMetaData } = commonStoreSlice.actions;\nexport default commonStoreSlice.reducer;\n","import { useDispatch, useSelector } from \"react-redux\";\nimport useSession from \"./UseSession\";\nimport useAxios from \"./useAxios\";\nimport { setStoreData } from \"../redux/features/common/CommonStoreSlice\";\n\nexport type ApiActionsProps = {\n findAll?: string;\n commonStoreKey?: string;\n setData?: any;\n findById?: string;\n findByIdParamName?: string;\n save?: string;\n deleteById?: string;\n deleteByIdParamName?: string;\n};\n\nexport type ApiActions = {\n reloadData: (params?: any) => Promise<void>;\n saveRecord: (record: any) => Promise<any | null>;\n loadRecordById: (recordId: any) => Promise<any>;\n deleteRecordById: (recordId: any) => Promise<boolean>;\n};\n\nconst useApiActions: (apiActionsProps: ApiActionsProps) => ApiActions = (\n apiActionsProps: ApiActionsProps\n) => {\n const CommonStores = useSelector((state: any) => state.commonStores.stores);\n const dispatch = useDispatch();\n const session = useSession();\n const { handleGetRequest, handlePostRequest, handleDeleteRequest } =\n useAxios();\n const reloadData = async (params?: any) => {\n if (apiActionsProps?.commonStoreKey) {\n const storeKeys = Object.keys(CommonStores);\n for (const storeKey of storeKeys) {\n if (storeKey === apiActionsProps.commonStoreKey) {\n if (\n (CommonStores[storeKey]?.authority === undefined ||\n CommonStores[storeKey]?.authority === null ||\n session.isUserAuthorized(CommonStores[storeKey]?.authority)) &&\n CommonStores[storeKey]?.url != \"\"\n ) {\n await handleGetRequest({\n endPointURI: CommonStores[storeKey].url,\n showMask: false,\n successCallBkFn: (response: any) => {\n dispatch(setStoreData({ storeKey, data: response.data }));\n apiActionsProps.setData(response.data);\n },\n failureCallBkFn: () => {\n dispatch(setStoreData({ storeKey, data: [] }));\n apiActionsProps.setData([]);\n },\n });\n break;\n }\n }\n }\n } else if (apiActionsProps?.findAll) {\n await handleGetRequest({\n endPointURI: apiActionsProps.findAll,\n showMask: true,\n parameters: params || {},\n successCallBkFn: (response: any) => {\n apiActionsProps.setData(response.data);\n },\n });\n }\n };\n const saveRecord = async (record: any) => {\n let savedRecord = null;\n if (apiActionsProps?.save) {\n await handlePostRequest({\n endPointURI: apiActionsProps.save,\n data: record,\n showMask: true,\n successCallBkFn: (response: any) => {\n savedRecord = response.data;\n },\n });\n }\n return savedRecord;\n };\n const loadRecordById = async (recordId: any) => {\n let record: any = null;\n if (apiActionsProps?.findById) {\n const parameters: any = {};\n const keyParameterName = apiActionsProps?.findByIdParamName || \"id\";\n parameters[keyParameterName] = recordId;\n await handleGetRequest({\n endPointURI: apiActionsProps.findById,\n showMask: true,\n parameters,\n successCallBkFn: (response: any) => {\n record = response.data;\n },\n });\n }\n return record;\n };\n const deleteRecordById = async (recordId: any) => {\n let result = true;\n if (apiActionsProps?.deleteById) {\n const parameters: any = {};\n const keyParameterName = apiActionsProps?.deleteByIdParamName || \"id\";\n parameters[keyParameterName] = recordId;\n await handleDeleteRequest({\n endPointURI: apiActionsProps.deleteById,\n showMask: true,\n parameters,\n successCallBkFn: () => {\n result = true;\n },\n failureCallBkFn: () => {\n result = false;\n },\n });\n }\n return result;\n };\n return { reloadData, loadRecordById, saveRecord, deleteRecordById };\n};\n\nexport default useApiActions;\n","import { TextField, TextFieldProps } from \"@mui/material\";\nimport { useTranslation } from \"react-i18next\";\n\nconst TemplateTextField: React.FC<Omit<TextFieldProps, \"outlined\">> = (\n props\n) => {\n const { t } = useTranslation();\n return (\n <TextField\n {...props}\n slotProps={{ inputLabel: { shrink: true, sx: { fontWeight: \"bold\" } } }}\n label={<>{props?.label ? t(props.label) : \"\"}</>}\n helperText={props?.helperText ? t(props.helperText) : undefined}\n />\n );\n};\n\nexport default TemplateTextField;\n","import * as React from \"react\";\nimport List from \"@mui/material/List\";\nimport Card from \"@mui/material/Card\";\nimport CardHeader from \"@mui/material/CardHeader\";\nimport ListItemText from \"@mui/material/ListItemText\";\nimport ListItemIcon from \"@mui/material/ListItemIcon\";\nimport Checkbox from \"@mui/material/Checkbox\";\nimport Button from \"@mui/material/Button\";\nimport Divider from \"@mui/material/Divider\";\nimport { Box, Grid2, ListItemButton } from \"@mui/material\";\nimport TemplateTextField from \"./DataEntryTemplates/TemplateDataForm/FormFields/TemplateTextField\";\n\nfunction not(a, b) {\n return a.filter((value) => b.indexOf(value) === -1);\n}\n\nfunction intersection(a, b) {\n return a.filter((value) => b.indexOf(value) !== -1);\n}\n\nfunction union(a, b) {\n return [...a, ...not(b, a)];\n}\n\nexport type TransferListProps = {\n valueField: string;\n displayField: string;\n options: Array<any>;\n selectedOptions: Array<any>;\n setSelection: any;\n};\n\nconst TransferList: React.FC<TransferListProps> = ({\n valueField = \"id\",\n displayField = \"name\",\n options = [],\n selectedOptions = [],\n setSelection,\n}) => {\n const [checked, setChecked] = React.useState([]);\n const [left, setLeft] = React.useState<Array<any>>([]);\n const [right, setRight] = React.useState<Array<any>>([]);\n const [leftFilterValue, setLeftFilterValue] = React.useState<string>(\"\");\n const [rightFilterValue, setRightFilterValue] = React.useState<string>(\"\");\n\n const leftChecked = intersection(checked, left);\n const rightChecked = intersection(checked, right);\n\n React.useEffect(() => {\n if (options) {\n setLeft([...options]);\n }\n }, [options]);\n React.useEffect(() => {\n if (selectedOptions) {\n setRight([...selectedOptions]);\n }\n }, [selectedOptions]);\n\n const handleToggle = (value) => () => {\n const currentIndex = checked.indexOf(value);\n const newChecked = [...checked];\n\n if (currentIndex === -1) {\n newChecked.push(value);\n } else {\n newChecked.splice(currentIndex, 1);\n }\n\n setChecked(newChecked);\n };\n\n const numberOfChecked = (items) => intersection(checked, items).length;\n\n const handleToggleAll = (items) => () => {\n if (numberOfChecked(items) === items.length) {\n setChecked(not(checked, items));\n } else {\n setChecked(union(checked, items));\n }\n };\n\n const handleCheckedRight = () => {\n setRight((oldState) => {\n let newState = right.concat(leftChecked);\n setSelection(newState);\n return newState;\n });\n setLeft(not(left, leftChecked));\n setChecked(not(checked, leftChecked));\n };\n\n const handleCheckedLeft = () => {\n setLeft(left.concat(rightChecked));\n setRight((oldState) => {\n let newState = not(right, rightChecked);\n setSelection(newState);\n return newState;\n });\n setChecked(not(checked, rightChecked));\n };\n\n const customList = (\n title: string,\n unfilteredItems: Array<any>,\n side: \"left\" | \"right\"\n ) => {\n const items = unfilteredItems.filter((option: any) => {\n if (option[displayField]) {\n const value: string = option[displayField];\n if (\n side === \"left\" &&\n value\n .toLocaleLowerCase()\n .includes(leftFilterValue.toLocaleLowerCase())\n ) {\n return true;\n } else if (\n side === \"right\" &&\n value\n .toLocaleLowerCase()\n .includes(rightFilterValue.toLocaleLowerCase())\n ) {\n return true;\n }\n }\n return false;\n });\n return (\n <Card sx={{ height: \"100%\" }}>\n <CardHeader\n sx={{ px: 2, py: 1 }}\n avatar={\n <Checkbox\n onClick={handleToggleAll(items)}\n checked={\n numberOfChecked(items) === items.length && items.length !== 0\n }\n indeterminate={\n numberOfChecked(items) !== items.length &&\n numberOfChecked(items) !== 0\n }\n disabled={items.length === 0}\n inputProps={{\n \"aria-label\": \"all items selected\",\n }}\n />\n }\n title={title}\n subheader={`${numberOfChecked(unfilteredItems)} / ${\n unfilteredItems.length\n } Selected`}\n />\n <Box sx={{ width: \"100%\", padding: 1 }}>\n <TemplateTextField\n fullWidth\n label=\"search\"\n value={side === \"left\" ? leftFilterValue : rightFilterValue}\n onChange={(event) => {\n if (side === \"left\") {\n setLeftFilterValue(event.target.value);\n } else {\n setRightFilterValue(event.target.value);\n }\n }}\n />\n </Box>\n <Divider />\n <List\n sx={{\n width: \"100%\",\n height: \"80%\",\n bgcolor: \"secondary\",\n overflow: \"auto\",\n }}\n dense\n component=\"div\"\n role=\"list\"\n >\n {items.map((value) => {\n const labelId = `transfer-list-all-item-${value[valueField]}-label`;\n\n return (\n <ListItemButton\n key={value[valueField]}\n role=\"listitem\"\n onClick={handleToggle(value)}\n sx={{ cursor: \"pointer\" }}\n >\n <ListItemIcon>\n <Checkbox\n checked={checked.indexOf(value) !== -1}\n tabIndex={-1}\n disableRipple\n />\n </ListItemIcon>\n <ListItemText\n id={value[valueField]}\n primary={value[displayField]}\n />\n </ListItemButton>\n );\n })}\n </List>\n </Card>\n );\n };\n return (\n <Grid2\n container\n spacing={2}\n sx={{\n flexGrow: 1,\n overflow: \"auto\",\n margin: 1,\n display: \"flex\",\n width: \"100%\",\n }}\n justifyContent=\"center\"\n alignItems=\"center\"\n >\n <Grid2 sx={{ height: \"100%\", flex: 1 }}>\n {customList(\"Available Items\", left, \"left\")}\n </Grid2>\n <Grid2>\n <Grid2 container direction=\"column\" alignItems=\"center\">\n <Button\n sx={{ my: 0.5 }}\n variant=\"outlined\"\n size=\"small\"\n onClick={handleCheckedRight}\n disabled={leftChecked.length === 0}\n aria-label=\"move selected right\"\n >\n >\n </Button>\n <Button\n sx={{ my: 0.5 }}\n variant=\"outlined\"\n size=\"small\"\n onClick={handleCheckedLeft}\n disabled={rightChecked.length === 0}\n aria-label=\"move selected left\"\n >\n <\n </Button>\n </Grid2>\n </Grid2>\n <Grid2 sx={{ height: \"100%\", flex: 1 }}>\n {customList(\"Currently Selected\", right, \"right\")}\n </Grid2>\n </Grid2>\n );\n};\n\nexport default TransferList;\n","import { Checkbox, FormControlLabel } from \"@mui/material\";\nimport { useTranslation } from \"react-i18next\";\n\ninterface CheckBoxProps {\n value: any;\n disabled?: boolean;\n required?: boolean;\n hidden?: boolean;\n label: string;\n checkedValue?: any;\n unCheckedValue?: any;\n onChangeCallBack: Function;\n sx?: any;\n}\n\nconst CheckBox: React.FC<CheckBoxProps> = (props) => {\n const { t } = useTranslation();\n return (\n <FormControlLabel\n sx={props.sx}\n hidden={props?.hidden || false}\n disabled={props.disabled || false}\n required={props.required || false}\n control={\n <Checkbox\n checked={\n props?.checkedValue == props.value ||\n props.value === \"true\" ||\n props.value == \"1\"\n ? true\n : false\n }\n onChange={(e) => {\n if (\n props.onChangeCallBack !== undefined &&\n props.onChangeCallBack != null\n ) {\n if (e.target.checked) {\n if (\n props.checkedValue !== undefined &&\n props.checkedValue != null\n ) {\n props.onChangeCallBack(props.checkedValue);\n } else {\n props.onChangeCallBack(true);\n }\n } else {\n if (\n props.unCheckedValue !== undefined &&\n props.unCheckedValue != null\n ) {\n props.onChangeCallBack(props.unCheckedValue);\n } else {\n props.onChangeCallBack(false);\n }\n }\n }\n }}\n />\n }\n label={t(props.label)}\n />\n );\n};\n\nexport default CheckBox;\n","import { useSelector } from \"react-redux\";\nimport { Autocomplete, Popper, TextField } from \"@mui/material\";\nimport { useTranslation } from \"react-i18next\";\n\ninterface ComboBoxProps {\n value: any;\n onChangeCallBack: Function;\n label: string;\n disabled?: boolean;\n required?: boolean;\n options: Array<any>;\n errorMessage?: any;\n hidden?: boolean;\n displayField: string;\n valueField: string;\n sx?: any;\n}\n\nconst ComboBox: React.FC<ComboBoxProps> = (props) => {\n const AppLayoutState = useSelector((state: any) => state.AppLayout);\n const { t } = useTranslation();\n const getValue = (v: string) => {\n for (let option of props.options) {\n if (option[props.valueField] == v) {\n return option;\n }\n }\n return null;\n };\n return (\n <Autocomplete\n sx={props.sx}\n value={getValue(props.value)}\n options={props.options}\n disabled={props.disabled}\n hidden={props?.hidden || false}\n onChange={(event, newValue) => {\n if (\n props.onChangeCallBack !== undefined &&\n props.onChangeCallBack != null\n ) {\n if (newValue != null) {\n let v = newValue[props.valueField];\n props.onChangeCallBack(v, newValue);\n } else {\n props.onChangeCallBack(null, null);\n }\n }\n }}\n clearOnBlur\n handleHomeEndKeys\n getOptionLabel={(option) => {\n return option != null ? t(option[props.displayField]) : \"\";\n }}\n renderOption={(props1, option) => {\n return (\n <li {...props1}>\n {option != null ? t(option[props.displayField]) : \"\"}\n </li>\n );\n }}\n slots={{\n popper: (props: any) => (\n <Popper\n {...props}\n style={{ ...props.style, direction: AppLayoutState.appDirection }}\n />\n ),\n }}\n renderInput={(params) => {\n return (\n <TextField\n {...params}\n required={props.required || false}\n variant=\"outlined\"\n slotProps={{\n inputLabel: { shrink: true, sx: { fontWeight: \"bold\" } },\n }}\n label={t(props.label)}\n error={\n props.errorMessage != null && props.errorMessage !== undefined\n ? true\n : false\n }\n helperText={\n props.errorMessage != null && props.errorMessage !== undefined\n ? t(props.errorMessage)\n : \"\"\n }\n />\n );\n }}\n />\n );\n};\n\nexport default ComboBox;\n","export const DATE_FORMAT = \"YYYY-MM-DD\";\nexport const DATE_TIME_FORMAT = \"YYYY-MM-DD HH:mm:ss\";\nexport const LIGHT_THEME_INITIAL_MAIN_COLOR = \"#37505C\";\nexport const LIGHT_THEME_INITIAL_SECANDARY_COLOR = \"#ff6d00\";\nexport const DARK_THEME_INITIAL_MAIN_COLOR = \"#ea690e\";\nexport const DARK_THEME_INITIAL_SECANDARY_COLOR = \"#74776B\";\n","import { DatePicker, LocalizationProvider } from \"@mui/x-date-pickers\";\nimport { AdapterMoment } from \"@mui/x-date-pickers/AdapterMoment\";\nimport moment from \"moment\";\nimport { DATE_FORMAT } from \"../../../../../util/constants\";\nimport { useTranslation } from \"react-i18next\";\nimport TemplateTextField from \"./TemplateTextField\";\n\ninterface DatefieldProps {\n value: string | null;\n label: string;\n disabled?: boolean;\n required?: boolean;\n hidden?: boolean;\n sx?: any;\n format?: string;\n errorMessage?: any;\n onChangeCallBack: Function;\n [x: string | number | symbol]: unknown;\n}\n\nconst Datefield: React.FC<DatefieldProps> = (props) => {\n const { t } = useTranslation();\n if (props?.hidden) {\n return <></>;\n }\n return (\n <LocalizationProvider dateAdapter={AdapterMoment}>\n <DatePicker\n value={\n props.value != null && props.value !== undefined && props.value !== \"\"\n ? moment(props.value, props?.format || DATE_FORMAT)\n : null\n }\n sx={{ ...props.sx, display: props?.hidden ? \"none\" : undefined }}\n label={t(props.label)}\n format={props?.format || DATE_FORMAT}\n disabled={props.disabled}\n onChange={(momentValue) => {\n let v = null;\n if (momentValue != null && momentValue.isValid()) {\n v = momentValue.format(props?.format || DATE_FORMAT);\n }\n if (\n props.onChangeCallBack !== undefined &&\n props.onChangeCallBack != null\n ) {\n props.onChangeCallBack(v);\n }\n }}\n slotProps={{\n textField: {\n InputLabelProps: { shrink: true, sx: { fontWeight: \"bold\" } },\n variant: \"outlined\",\n required: props.required,\n error:\n props.errorMessage !== undefined && props.errorMessage != null,\n helperText:\n props.errorMessage !== undefined && props.errorMessage != null ? (\n <>{t(props.errorMessage)}</>\n ) : (\n <></>\n ),\n },\n }}\n />\n </LocalizationProvider>\n );\n};\n\nexport default Datefield;\n","import { DateTimePicker, LocalizationProvider } from \"@mui/x-date-pickers\";\nimport { AdapterMoment } from \"@mui/x-date-pickers/AdapterMoment\";\nimport moment from \"moment\";\nimport { useTranslation } from \"react-i18next\";\nimport { DATE_TIME_FORMAT } from \"../../../../../util/constants\";\nimport TemplateTextField from \"./TemplateTextField\";\nimport { Hidden, TextField } from \"@mui/material\";\n\ninterface DatetimeFieldProps {\n value: string | null;\n label: string;\n disabled?: boolean;\n required?: boolean;\n hidden?: boolean;\n format?: string;\n sx?: any;\n errorMessage?: any;\n onChangeCallBack: Function;\n [x: string | number | symbol]: unknown;\n}\n\nconst DatetimeField: React.FC<DatetimeFieldProps> = (props) => {\n const { t } = useTranslation();\n if (props?.hidden) {\n return <></>;\n }\n return (\n <LocalizationProvider dateAdapter={AdapterMoment}>\n <DateTimePicker\n value={\n props.value != null && props.value !== undefined && props.value !== \"\"\n ? moment(props.value, props?.format || DATE_TIME_FORMAT)\n : null\n }\n label={t(props.label)}\n sx={{ ...props.sx, display: props?.hidden ? \"none\" : undefined }}\n format={props?.format || DATE_TIME_FORMAT}\n disabled={props.disabled}\n onChange={(momentValue) => {\n let v = null;\n if (momentValue != null && momentValue.isValid()) {\n v = momentValue.format(props?.format || DATE_TIME_FORMAT);\n }\n if (\n props.onChangeCallBack !== undefined &&\n props.onChangeCallBack != null\n ) {\n props.onChangeCallBack(v);\n }\n }}\n slotProps={{\n textField: {\n InputLabelProps: { shrink: true, sx: { fontWeight: \"bold\" } },\n variant: \"outlined\",\n required: props.required,\n error:\n props.errorMessage !== undefined && props.errorMessage != null,\n helperText:\n props.errorMessage !== undefined && props.errorMessage != null ? (\n <>{t(props.errorMessage)}</>\n ) : (\n <></>\n ),\n },\n }}\n />\n </LocalizationProvider>\n );\n};\n\nexport default DatetimeField;\n","import { useEffect, useState } from \"react\";\nimport { useAxios, useSession } from \"../../../../../hooks\";\nimport ComboBox from \"./ComboBox\";\nimport { useSelector } from \"react-redux\";\n\ntype SystemLookupListProps = {\n lookupType: string;\n value: any;\n onChangeCallBack: Function;\n label: string;\n disabled?: boolean;\n required?: boolean;\n hidden?: boolean;\n errorMessage?: any;\n sx?: any;\n};\n\nconst SystemLookupCombobox: React.FC<SystemLookupListProps> = (props) => {\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const session = useSession();\n const [options, setOptions] = useState<Array<any>>([]);\n const { handleGetRequest } = useAxios();\n\n const loadLookupOptions = async () => {\n await handleGetRequest({\n endPointURI: \"api/v1/public/system/lookup\",\n showMask: true,\n parameters: { lookupType: props.lookupType },\n successCallBkFn: (response: any) => {\n setOptions(response.data);\n },\n failureCallBkFn: () => {\n setOptions([]);\n },\n });\n };\n\n useEffect(() => {\n if (props.lookupType) {\n loadLookupOptions();\n }\n }, [props.lookupType, session.UserSession]);\n\n return (\n <ComboBox\n {...props}\n options={options}\n displayField={\n AppLayout.appDirection === \"ltr\" ? \"lookupEnDisplay\" : \"lookupArDisplay\"\n }\n valueField=\"lookupValue\"\n />\n );\n};\n\nexport default SystemLookupCombobox;\n","import moment from \"moment\";\nimport { TemplateGridColDef } from \"../DataEntryTypes\";\nimport Datefield from \"../TemplateDataForm/FormFields/Datefield\";\nimport { DATE_FORMAT, DATE_TIME_FORMAT } from \"../../../../util/constants\";\nimport DatetimeField from \"../TemplateDataForm/FormFields/DatetimeField\";\nimport ComboBox from \"../TemplateDataForm/FormFields/ComboBox\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport CheckBox from \"../TemplateDataForm/FormFields/CheckBox\";\n\nexport const generateDateColumn: any = (colDef: TemplateGridColDef) => {\n const column: TemplateGridColDef = {\n ...colDef,\n type: \"string\",\n renderEditCell: (params: any) => {\n return (\n <Datefield\n sx={{ width: \"100%\" }}\n label=\"\"\n value={params.value}\n onChangeCallBack={(v: any) => {\n params.api.setEditCellValue({\n id: params.id,\n field: params.field,\n value: v,\n });\n }}\n />\n );\n },\n valueParser: (value: any, row: any, column: any) => {\n let v = null;\n if (value !== null) {\n v = moment(value).format(DATE_FORMAT);\n }\n return v;\n },\n valueFormatter: (value: any, row: any, column: any) => {\n return row[column.field];\n },\n };\n return column;\n};\n\nexport const generateDateTimeColumn: any = (colDef: TemplateGridColDef) => {\n const column: TemplateGridColDef = {\n ...colDef,\n type: \"string\",\n renderEditCell: (params: any) => {\n return (\n <DatetimeField\n sx={{ width: \"100%\" }}\n label=\"\"\n value={params.value}\n onChangeCallBack={(v: any) => {\n params.api.setEditCellValue({\n id: params.id,\n field: params.field,\n value: v,\n });\n }}\n />\n );\n },\n valueParser: (value: any, row: any, column: any) => {\n let v = null;\n if (value !== null) {\n v = moment(value).format(DATE_TIME_FORMAT);\n }\n return v;\n },\n valueFormatter: (value: any, row: any, column: any) => {\n return row[column.field];\n },\n };\n return column;\n};\n\ntype ComboBoxColumnProps = TemplateGridColDef & {\n lookupType?: string;\n options: Array<any>;\n displayField: string;\n valueField: string;\n};\nexport const generateComboColumn: (\n props: ComboBoxColumnProps\n) => TemplateGridColDef = (colDef: ComboBoxColumnProps) => {\n const column: TemplateGridColDef = {\n ...colDef,\n type: \"custom\",\n valueGetter: (value) => {\n if (value) {\n return value;\n }\n return value;\n },\n renderCell: (parameters: any) => {\n let record = null;\n try {\n record = parameters.colDef.options.find(\n (item: any) => item[parameters.colDef.valueField] == parameters.value\n );\n } catch (e) {}\n return (\n <div>\n {record != null\n ? record[parameters.colDef.displayField]\n : parameters.value}\n </div>\n );\n },\n\n renderEditCell: (params: any) => {\n return (\n <ComboBox\n {...params}\n sx={{ width: \"100%\" }}\n options={params.colDef.options}\n valueField={params.colDef.valueField}\n displayField={params.colDef.displayField}\n onChangeCallBack={(v: any, selectedRecord: any) => {\n if (v === null) {\n params.api.setEditCellValue({\n id: params.id,\n field: params.field,\n value: null,\n });\n }\n params.api.setEditCellValue({\n id: params.id,\n field: params.field,\n value: v,\n });\n }}\n />\n );\n },\n };\n return column;\n};\n\ntype CheckBoxColumnProps = TemplateGridColDef & {\n checkedValue?: string;\n unCheckedValue?: string;\n};\n\nexport const generateCheckBoxColumn: (\n props: CheckBoxColumnProps\n) => TemplateGridColDef = (colDef: CheckBoxColumnProps) => {\n return {\n ...colDef,\n type: \"custom\",\n valueGetter: (value) => {\n if (value == null || value == undefined) {\n return null;\n } else {\n return value;\n }\n },\n renderCell: (parameters: any) => {\n const value = parameters?.value;\n if (\n value === colDef.checkedValue ||\n value === \"true\" ||\n value === 1 ||\n value === true\n ) {\n return <FontAwesomeIcon icon=\"check\" color=\"green\" />;\n } else {\n return <FontAwesomeIcon icon=\"xmark\" color=\"red\" />;\n }\n },\n renderEditCell: (params: any) => {\n return (\n <CheckBox\n {...params}\n checkedValue={colDef?.checkedValue || true}\n unCheckedValue={colDef?.unCheckedValue || false}\n onChangeCallBack={(v: any) => {\n params.api.setEditCellValue({\n id: params.id,\n field: params.field,\n value: v,\n });\n }}\n />\n );\n },\n };\n};\n","import { GridRowSelectionModel } from \"@mui/x-data-grid-premium\";\nimport {\n FormElementProps,\n RecordFieldProps,\n TemplateGridColDef,\n} from \"./DataEntryTypes\";\nimport {\n generateCheckBoxColumn,\n generateComboColumn,\n generateDateColumn,\n generateDateTimeColumn,\n} from \"./TemplateDataGrid/DataGridColumnsUtil\";\nimport * as z from \"zod\";\nimport { TFunction } from \"i18next\";\n\nexport const getElementFields: (\n element: FormElementProps\n) => Array<RecordFieldProps> = (element: FormElementProps) => {\n const fields: Array<RecordFieldProps> = [];\n if (element.type === \"field\" && element.mode === \"props\" && element?.props) {\n fields.push(element.props);\n } else if (\n element.type === \"group\" &&\n element?.props &&\n element?.props?.elements\n ) {\n for (const childElement of element.props.elements) {\n fields.push(...getElementFields(childElement));\n }\n }\n return fields;\n};\n\nexport const getAllFields: (\n elements: Array<FormElementProps>\n) => Array<RecordFieldProps> = (elements: Array<FormElementProps>) => {\n const fields: Array<RecordFieldProps> = [];\n for (const element of elements) {\n fields.push(...getElementFields(element));\n }\n return fields;\n};\n\nexport const constructGridColumnsFromFields: (\n fields: Array<RecordFieldProps>,\n isDefaultEditable: boolean,\n t: TFunction<\"translation\", undefined>\n) => Array<TemplateGridColDef> = (fields, isDefaultEditable, t) => {\n const columns: Array<TemplateGridColDef> = [];\n\n for (const tableField of fields) {\n if (\n tableField?.fieldType === \"text\" ||\n tableField?.fieldType === \"number\"\n ) {\n const column: TemplateGridColDef = {\n ...tableField?.gridProps?.muiProps,\n editable:\n tableField?.gridProps?.muiProps?.editable != undefined\n ? tableField?.gridProps?.muiProps?.editable\n : isDefaultEditable,\n type: tableField?.fieldType == \"number\" ? \"number\" : \"string\",\n field: tableField?.fieldName,\n headerName: t(tableField?.fieldLabel || tableField?.fieldName),\n headerAlign: \"center\",\n align: \"center\",\n hidden: tableField?.hidden,\n searchable: tableField?.gridProps?.searchable,\n flex: tableField?.gridProps?.muiProps?.flex || 1,\n minWidth: tableField?.gridProps?.muiProps?.width\n ? tableField?.gridProps?.muiProps?.width\n : 200,\n };\n\n columns.push(column);\n } else if (tableField?.fieldType === \"date\") {\n const column: TemplateGridColDef = generateDateColumn({\n ...tableField?.gridProps?.muiProps,\n editable:\n tableField?.gridProps?.muiProps?.editable != undefined\n ? tableField?.gridProps?.muiProps?.editable\n : isDefaultEditable,\n field: tableField?.fieldName,\n headerName: t(tableField?.fieldLabel || tableField?.fieldName),\n headerAlign: \"center\",\n align: \"center\",\n hidden: tableField?.hidden,\n searchable: tableField?.gridProps?.searchable,\n flex: tableField?.gridProps?.muiProps?.flex || 1,\n minWidth: tableField?.gridProps?.muiProps?.width\n ? tableField?.gridProps?.muiProps?.width\n : 200,\n });\n columns.push(column);\n } else if (tableField?.fieldType === \"datetime\") {\n const column: TemplateGridColDef = generateDateTimeColumn({\n ...tableField?.gridProps?.muiProps,\n editable:\n tableField?.gridProps?.muiProps?.editable != undefined\n ? tableField?.gridProps?.muiProps?.editable\n : isDefaultEditable,\n field: tableField?.fieldName,\n headerName: t(tableField?.fieldLabel || tableField?.fieldName),\n headerAlign: \"center\",\n align: \"center\",\n hidden: tableField?.hidden,\n searchable: tableField?.gridProps?.searchable,\n flex: tableField?.gridProps?.muiProps?.flex || 1,\n minWidth: tableField?.gridProps?.muiProps?.width\n ? tableField?.gridProps?.muiProps?.width\n : 200,\n });\n columns.push(column);\n } else if (tableField?.fieldType === \"checkbox\") {\n const column = generateCheckBoxColumn({\n ...tableField?.gridProps?.muiProps,\n editable:\n tableField?.gridProps?.muiProps?.editable != undefined\n ? tableField?.gridProps?.muiProps?.editable\n : isDefaultEditable,\n field: tableField?.fieldName,\n headerName: t(tableField?.fieldLabel || tableField?.fieldName),\n headerAlign: \"center\",\n align: \"center\",\n hidden: tableField?.hidden,\n searchable: tableField?.gridProps?.searchable,\n checkedValue: tableField?.checkedValue,\n unCheckedValue: tableField?.unCheckedValue,\n width: 150,\n });\n columns.push(column);\n } else if (tableField?.fieldType === \"combobox\") {\n const column: TemplateGridColDef = generateComboColumn({\n ...tableField?.gridProps?.muiProps,\n editable:\n tableField?.gridProps?.muiProps?.editable != undefined\n ? tableField?.gridProps?.muiProps?.editable\n : isDefaultEditable,\n field: tableField?.fieldName,\n headerName: t(tableField?.fieldLabel || tableField?.fieldName),\n headerAlign: \"center\",\n align: \"center\",\n hidden: tableField?.hidden,\n searchable: tableField?.gridProps?.searchable,\n valueField: tableField?.optionValueField || \"value\",\n displayField: tableField?.optionDisplayField || \"display\",\n options: tableField?.options || [],\n flex: tableField?.gridProps?.muiProps?.flex || 1,\n minWidth: tableField?.gridProps?.muiProps?.width\n ? tableField?.gridProps?.muiProps?.width\n : 200,\n });\n columns.push(column);\n } else if (tableField?.fieldType === \"lookup\") {\n const column: TemplateGridColDef = generateComboColumn({\n ...tableField?.gridProps?.muiProps,\n editable:\n tableField?.gridProps?.muiProps?.editable != undefined\n ? tableField?.gridProps?.muiProps?.editable\n : isDefaultEditable,\n lookupType: tableField?.lookupType,\n field: tableField?.fieldName,\n headerName: t(tableField?.fieldLabel || tableField?.fieldName),\n headerAlign: \"center\",\n align: \"center\",\n hidden: tableField?.hidden,\n searchable: tableField?.gridProps?.searchable,\n valueField: tableField?.optionValueField || \"value\",\n displayField: tableField?.optionDisplayField || \"display\",\n options: tableField?.options || [],\n flex: tableField?.gridProps?.muiProps?.flex || 1,\n minWidth: tableField?.gridProps?.muiProps?.width\n ? tableField?.gridProps?.muiProps?.width\n : 200,\n });\n columns.push(column);\n } else {\n const column: TemplateGridColDef = {\n field: tableField.fieldName,\n ...tableField?.gridProps?.muiProps,\n };\n columns.push(column);\n }\n }\n return columns;\n};\n\nexport const constructValidationSchema = (fields: Array<RecordFieldProps>) => {\n const validationSchemaObj: any = {};\n for (const field of fields) {\n if (field?.fieldName) {\n const fieldName = field.fieldName;\n if (field.fieldType === \"number\") {\n if (field?.required === true) {\n validationSchemaObj[fieldName] = z.number({\n required_error: \"This field is required\",\n invalid_type_error: \"This field must be a number\",\n });\n } else {\n validationSchemaObj[fieldName] = z.number().optional().nullable();\n }\n } else if (field.fieldType === \"checkbox\") {\n if (field?.required === true) {\n validationSchemaObj[fieldName] = z.boolean({\n required_error: \"This field is required\",\n });\n } else {\n validationSchemaObj[fieldName] = z.boolean().optional().nullable();\n }\n } else if (field.fieldType === \"combobox\") {\n if (field?.comboboxValueDataType) {\n if (field?.comboboxValueDataType === \"number\") {\n if (field?.required === true) {\n validationSchemaObj[fieldName] = z.number({\n required_error: \"This field is required\",\n invalid_type_error: \"This field must be a number\",\n });\n } else {\n validationSchemaObj[fieldName] = z.number().optional().nullable();\n }\n } else if (field?.comboboxValueDataType === \"string\") {\n if (field?.required === true) {\n validationSchemaObj[fieldName] = z\n .string({ message: \"This field is required\" })\n .min(1, \"This field is required\");\n } else {\n validationSchemaObj[fieldName] = z.string().optional().nullable();\n }\n }\n } else {\n if (field?.required === true) {\n validationSchemaObj[fieldName] = z.number({\n required_error: \"This field is required\",\n invalid_type_error: \"This field must be a number\",\n });\n } else {\n validationSchemaObj[fieldName] = z.number().optional().nullable();\n }\n }\n } else {\n if (field?.required === true) {\n validationSchemaObj[fieldName] = z\n .string({ message: \"This field is required\" })\n .min(1, \"This field is required\");\n } else {\n validationSchemaObj[fieldName] = z.string().optional().nullable();\n }\n }\n }\n }\n return validationSchemaObj;\n};\n\nexport type GridSelection = {\n selectedRecords: Array<any>;\n selectedRecordIds: Array<any>;\n};\n\nexport const getGridSelection: (\n rowSelectionModel: GridRowSelectionModel,\n data: Array<any>,\n keyColumnName: string\n) => GridSelection = (\n rowSelectionModel: GridRowSelectionModel,\n data: Array<any>,\n keyColumnName: string\n) => {\n const sRecords = [];\n const sRecordIds = [];\n if (\n rowSelectionModel.type === \"exclude\" &&\n rowSelectionModel.ids.size === 0\n ) {\n for (const record of data) {\n sRecords.push(record);\n sRecordIds.push(record[keyColumnName]);\n }\n } else {\n if (rowSelectionModel?.ids) {\n for (const selectedId of rowSelectionModel.ids) {\n const record = data.find((x) => x[keyColumnName] === selectedId);\n sRecords.push(record);\n sRecordIds.push(selectedId);\n }\n }\n }\n return { selectedRecords: sRecords, selectedRecordIds: sRecordIds };\n};\n","/**\n * WARNING: Don't import this directly. It's imported by the code generated by\n * `@mui/interal-babel-plugin-minify-errors`. Make sure to always use string literals in `Error`\n * constructors to ensure the plugin works as expected. Supported patterns include:\n * throw new Error('My message');\n * throw new Error(`My message: ${foo}`);\n * throw new Error(`My message: ${foo}` + 'another string');\n * ...\n * @param {number} code\n */\nexport default function formatMuiErrorMessage(code, ...args) {\n const url = new URL(`https://mui.com/production-error/?code=${code}`);\n args.forEach(arg => url.searchParams.append('args[]', arg));\n return `Minified MUI error #${code}; visit ${url} for the full message.`;\n}","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/** @license React v16.13.1\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';var b=\"function\"===typeof Symbol&&Symbol.for,c=b?Symbol.for(\"react.element\"):60103,d=b?Symbol.for(\"react.portal\"):60106,e=b?Symbol.for(\"react.fragment\"):60107,f=b?Symbol.for(\"react.strict_mode\"):60108,g=b?Symbol.for(\"react.profiler\"):60114,h=b?Symbol.for(\"react.provider\"):60109,k=b?Symbol.for(\"react.context\"):60110,l=b?Symbol.for(\"react.async_mode\"):60111,m=b?Symbol.for(\"react.concurrent_mode\"):60111,n=b?Symbol.for(\"react.forward_ref\"):60112,p=b?Symbol.for(\"react.suspense\"):60113,q=b?\nSymbol.for(\"react.suspense_list\"):60120,r=b?Symbol.for(\"react.memo\"):60115,t=b?Symbol.for(\"react.lazy\"):60116,v=b?Symbol.for(\"react.block\"):60121,w=b?Symbol.for(\"react.fundamental\"):60117,x=b?Symbol.for(\"react.responder\"):60118,y=b?Symbol.for(\"react.scope\"):60119;\nfunction z(a){if(\"object\"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;\nexports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};\nexports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};\nexports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||\"object\"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;\n","/** @license React v16.13.1\n * react-is.development.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n\n\nif (process.env.NODE_ENV !== \"production\") {\n (function() {\n'use strict';\n\n// The Symbol used to tag the ReactElement-like types. If there is no native Symbol\n// nor polyfill, then a plain number is used for performance.\nvar hasSymbol = typeof Symbol === 'function' && Symbol.for;\nvar REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;\nvar REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;\nvar REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;\nvar REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;\nvar REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;\nvar REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;\nvar REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary\n// (unstable) APIs that have been removed. Can we remove the symbols?\n\nvar REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;\nvar REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;\nvar REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;\nvar REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;\nvar REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;\nvar REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;\nvar REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;\nvar REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;\nvar REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;\nvar REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;\nvar REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;\n\nfunction isValidElementType(type) {\n return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.\n type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);\n}\n\nfunction typeOf(object) {\n if (typeof object === 'object' && object !== null) {\n var $$typeof = object.$$typeof;\n\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n var type = object.type;\n\n switch (type) {\n case REACT_ASYNC_MODE_TYPE:\n case REACT_CONCURRENT_MODE_TYPE:\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n return type;\n\n default:\n var $$typeofType = type && type.$$typeof;\n\n switch ($$typeofType) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n case REACT_PROVIDER_TYPE:\n return $$typeofType;\n\n default:\n return $$typeof;\n }\n\n }\n\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n\n return undefined;\n} // AsyncMode is deprecated along with isAsyncMode\n\nvar AsyncMode = REACT_ASYNC_MODE_TYPE;\nvar ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;\nvar ContextConsumer = REACT_CONTEXT_TYPE;\nvar ContextProvider = REACT_PROVIDER_TYPE;\nvar Element = REACT_ELEMENT_TYPE;\nvar ForwardRef = REACT_FORWARD_REF_TYPE;\nvar Fragment = REACT_FRAGMENT_TYPE;\nvar Lazy = REACT_LAZY_TYPE;\nvar Memo = REACT_MEMO_TYPE;\nvar Portal = REACT_PORTAL_TYPE;\nvar Profiler = REACT_PROFILER_TYPE;\nvar StrictMode = REACT_STRICT_MODE_TYPE;\nvar Suspense = REACT_SUSPENSE_TYPE;\nvar hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated\n\nfunction isAsyncMode(object) {\n {\n if (!hasWarnedAboutDeprecatedIsAsyncMode) {\n hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint\n\n console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');\n }\n }\n\n return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;\n}\nfunction isConcurrentMode(object) {\n return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;\n}\nfunction isContextConsumer(object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n}\nfunction isContextProvider(object) {\n return typeOf(object) === REACT_PROVIDER_TYPE;\n}\nfunction isElement(object) {\n return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;\n}\nfunction isForwardRef(object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n}\nfunction isFragment(object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n}\nfunction isLazy(object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n}\nfunction isMemo(object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n}\nfunction isPortal(object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n}\nfunction isProfiler(object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n}\nfunction isStrictMode(object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n}\nfunction isSuspense(object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n}\n\nexports.AsyncMode = AsyncMode;\nexports.ConcurrentMode = ConcurrentMode;\nexports.ContextConsumer = ContextConsumer;\nexports.ContextProvider = ContextProvider;\nexports.Element = Element;\nexports.ForwardRef = ForwardRef;\nexports.Fragment = Fragment;\nexports.Lazy = Lazy;\nexports.Memo = Memo;\nexports.Portal = Portal;\nexports.Profiler = Profiler;\nexports.StrictMode = StrictMode;\nexports.Suspense = Suspense;\nexports.isAsyncMode = isAsyncMode;\nexports.isConcurrentMode = isConcurrentMode;\nexports.isContextConsumer = isContextConsumer;\nexports.isContextProvider = isContextProvider;\nexports.isElement = isElement;\nexports.isForwardRef = isForwardRef;\nexports.isFragment = isFragment;\nexports.isLazy = isLazy;\nexports.isMemo = isMemo;\nexports.isPortal = isPortal;\nexports.isProfiler = isProfiler;\nexports.isStrictMode = isStrictMode;\nexports.isSuspense = isSuspense;\nexports.isValidElementType = isValidElementType;\nexports.typeOf = typeOf;\n })();\n}\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';\n\nmodule.exports = ReactPropTypesSecret;\n","module.exports = Function.call.bind(Object.prototype.hasOwnProperty);\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n var loggedTypeFailures = {};\n var has = require('./lib/has');\n\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) { /**/ }\n };\n}\n\n/**\n * Assert that the values match with the type specs.\n * Error messages are memorized and will only be shown once.\n *\n * @param {object} typeSpecs Map of name to a ReactPropType\n * @param {object} values Runtime values that need to be type-checked\n * @param {string} location e.g. \"prop\", \"context\", \"child context\"\n * @param {string} componentName Name of the component for error messages.\n * @param {?Function} getStack Returns the component stack.\n * @private\n */\nfunction checkPropTypes(typeSpecs, values, location, componentName, getStack) {\n if (process.env.NODE_ENV !== 'production') {\n for (var typeSpecName in typeSpecs) {\n if (has(typeSpecs, typeSpecName)) {\n var error;\n // Prop type validation may throw. In case they do, we don't want to\n // fail the render phase where it didn't fail before. So we log it.\n // After these have been cleaned up, we'll let them throw.\n try {\n // This is intentionally an invariant that gets caught. It's the same\n // behavior as without this statement except with a better message.\n if (typeof typeSpecs[typeSpecName] !== 'function') {\n var err = Error(\n (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +\n 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'\n );\n err.name = 'Invariant Violation';\n throw err;\n }\n error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);\n } catch (ex) {\n error = ex;\n }\n if (error && !(error instanceof Error)) {\n printWarning(\n (componentName || 'React class') + ': type specification of ' +\n location + ' `' + typeSpecName + '` is invalid; the type checker ' +\n 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +\n 'You may have forgotten to pass an argument to the type checker ' +\n 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +\n 'shape all require an argument).'\n );\n }\n if (error instanceof Error && !(error.message in loggedTypeFailures)) {\n // Only monitor this failure once because there tends to be a lot of the\n // same error.\n loggedTypeFailures[error.message] = true;\n\n var stack = getStack ? getStack() : '';\n\n printWarning(\n 'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')\n );\n }\n }\n }\n }\n}\n\n/**\n * Resets warning cache when testing.\n *\n * @private\n */\ncheckPropTypes.resetWarningCache = function() {\n if (process.env.NODE_ENV !== 'production') {\n loggedTypeFailures = {};\n }\n}\n\nmodule.exports = checkPropTypes;\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactIs = require('react-is');\nvar assign = require('object-assign');\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\nvar has = require('./lib/has');\nvar checkPropTypes = require('./checkPropTypes');\n\nvar printWarning = function() {};\n\nif (process.env.NODE_ENV !== 'production') {\n printWarning = function(text) {\n var message = 'Warning: ' + text;\n if (typeof console !== 'undefined') {\n console.error(message);\n }\n try {\n // --- Welcome to debugging React ---\n // This error was thrown as a convenience so that you can use this stack\n // to find the callsite that caused this warning to fire.\n throw new Error(message);\n } catch (x) {}\n };\n}\n\nfunction emptyFunctionThatReturnsNull() {\n return null;\n}\n\nmodule.exports = function(isValidElement, throwOnDirectAccess) {\n /* global Symbol */\n var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;\n var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.\n\n /**\n * Returns the iterator method function contained on the iterable object.\n *\n * Be sure to invoke the function with the iterable as context:\n *\n * var iteratorFn = getIteratorFn(myIterable);\n * if (iteratorFn) {\n * var iterator = iteratorFn.call(myIterable);\n * ...\n * }\n *\n * @param {?object} maybeIterable\n * @return {?function}\n */\n function getIteratorFn(maybeIterable) {\n var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);\n if (typeof iteratorFn === 'function') {\n return iteratorFn;\n }\n }\n\n /**\n * Collection of methods that allow declaration and validation of props that are\n * supplied to React components. Example usage:\n *\n * var Props = require('ReactPropTypes');\n * var MyArticle = React.createClass({\n * propTypes: {\n * // An optional string prop named \"description\".\n * description: Props.string,\n *\n * // A required enum prop named \"category\".\n * category: Props.oneOf(['News','Photos']).isRequired,\n *\n * // A prop named \"dialog\" that requires an instance of Dialog.\n * dialog: Props.instanceOf(Dialog).isRequired\n * },\n * render: function() { ... }\n * });\n *\n * A more formal specification of how these methods are used:\n *\n * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)\n * decl := ReactPropTypes.{type}(.isRequired)?\n *\n * Each and every declaration produces a function with the same signature. This\n * allows the creation of custom validation functions. For example:\n *\n * var MyLink = React.createClass({\n * propTypes: {\n * // An optional string or URI prop named \"href\".\n * href: function(props, propName, componentName) {\n * var propValue = props[propName];\n * if (propValue != null && typeof propValue !== 'string' &&\n * !(propValue instanceof URI)) {\n * return new Error(\n * 'Expected a string or an URI for ' + propName + ' in ' +\n * componentName\n * );\n * }\n * }\n * },\n * render: function() {...}\n * });\n *\n * @internal\n */\n\n var ANONYMOUS = '<<anonymous>>';\n\n // Important!\n // Keep this list in sync with production version in `./factoryWithThrowingShims.js`.\n var ReactPropTypes = {\n array: createPrimitiveTypeChecker('array'),\n bigint: createPrimitiveTypeChecker('bigint'),\n bool: createPrimitiveTypeChecker('boolean'),\n func: createPrimitiveTypeChecker('function'),\n number: createPrimitiveTypeChecker('number'),\n object: createPrimitiveTypeChecker('object'),\n string: createPrimitiveTypeChecker('string'),\n symbol: createPrimitiveTypeChecker('symbol'),\n\n any: createAnyTypeChecker(),\n arrayOf: createArrayOfTypeChecker,\n element: createElementTypeChecker(),\n elementType: createElementTypeTypeChecker(),\n instanceOf: createInstanceTypeChecker,\n node: createNodeChecker(),\n objectOf: createObjectOfTypeChecker,\n oneOf: createEnumTypeChecker,\n oneOfType: createUnionTypeChecker,\n shape: createShapeTypeChecker,\n exact: createStrictShapeTypeChecker,\n };\n\n /**\n * inlined Object.is polyfill to avoid requiring consumers ship their own\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\n */\n /*eslint-disable no-self-compare*/\n function is(x, y) {\n // SameValue algorithm\n if (x === y) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return x !== 0 || 1 / x === 1 / y;\n } else {\n // Step 6.a: NaN == NaN\n return x !== x && y !== y;\n }\n }\n /*eslint-enable no-self-compare*/\n\n /**\n * We use an Error-like object for backward compatibility as people may call\n * PropTypes directly and inspect their output. However, we don't use real\n * Errors anymore. We don't inspect their stack anyway, and creating them\n * is prohibitively expensive if they are created too often, such as what\n * happens in oneOfType() for any type before the one that matched.\n */\n function PropTypeError(message, data) {\n this.message = message;\n this.data = data && typeof data === 'object' ? data: {};\n this.stack = '';\n }\n // Make `instanceof Error` still work for returned errors.\n PropTypeError.prototype = Error.prototype;\n\n function createChainableTypeChecker(validate) {\n if (process.env.NODE_ENV !== 'production') {\n var manualPropTypeCallCache = {};\n var manualPropTypeWarningCount = 0;\n }\n function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {\n componentName = componentName || ANONYMOUS;\n propFullName = propFullName || propName;\n\n if (secret !== ReactPropTypesSecret) {\n if (throwOnDirectAccess) {\n // New behavior only for users of `prop-types` package\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use `PropTypes.checkPropTypes()` to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {\n // Old behavior for people using React.PropTypes\n var cacheKey = componentName + ':' + propName;\n if (\n !manualPropTypeCallCache[cacheKey] &&\n // Avoid spamming the console because they are often not actionable except for lib authors\n manualPropTypeWarningCount < 3\n ) {\n printWarning(\n 'You are manually calling a React.PropTypes validation ' +\n 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +\n 'and will throw in the standalone `prop-types` package. ' +\n 'You may be seeing this warning due to a third-party PropTypes ' +\n 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'\n );\n manualPropTypeCallCache[cacheKey] = true;\n manualPropTypeWarningCount++;\n }\n }\n }\n if (props[propName] == null) {\n if (isRequired) {\n if (props[propName] === null) {\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));\n }\n return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));\n }\n return null;\n } else {\n return validate(props, propName, componentName, location, propFullName);\n }\n }\n\n var chainedCheckType = checkType.bind(null, false);\n chainedCheckType.isRequired = checkType.bind(null, true);\n\n return chainedCheckType;\n }\n\n function createPrimitiveTypeChecker(expectedType) {\n function validate(props, propName, componentName, location, propFullName, secret) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== expectedType) {\n // `propValue` being instance of, say, date/regexp, pass the 'object'\n // check, but we can offer a more precise error message here rather than\n // 'of type `object`'.\n var preciseType = getPreciseType(propValue);\n\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),\n {expectedType: expectedType}\n );\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createAnyTypeChecker() {\n return createChainableTypeChecker(emptyFunctionThatReturnsNull);\n }\n\n function createArrayOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');\n }\n var propValue = props[propName];\n if (!Array.isArray(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));\n }\n for (var i = 0; i < propValue.length; i++) {\n var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!isValidElement(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createElementTypeTypeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n if (!ReactIs.isValidElementType(propValue)) {\n var propType = getPropType(propValue);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createInstanceTypeChecker(expectedClass) {\n function validate(props, propName, componentName, location, propFullName) {\n if (!(props[propName] instanceof expectedClass)) {\n var expectedClassName = expectedClass.name || ANONYMOUS;\n var actualClassName = getClassName(props[propName]);\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createEnumTypeChecker(expectedValues) {\n if (!Array.isArray(expectedValues)) {\n if (process.env.NODE_ENV !== 'production') {\n if (arguments.length > 1) {\n printWarning(\n 'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +\n 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'\n );\n } else {\n printWarning('Invalid argument supplied to oneOf, expected an array.');\n }\n }\n return emptyFunctionThatReturnsNull;\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n for (var i = 0; i < expectedValues.length; i++) {\n if (is(propValue, expectedValues[i])) {\n return null;\n }\n }\n\n var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {\n var type = getPreciseType(value);\n if (type === 'symbol') {\n return String(value);\n }\n return value;\n });\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createObjectOfTypeChecker(typeChecker) {\n function validate(props, propName, componentName, location, propFullName) {\n if (typeof typeChecker !== 'function') {\n return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');\n }\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));\n }\n for (var key in propValue) {\n if (has(propValue, key)) {\n var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error instanceof Error) {\n return error;\n }\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createUnionTypeChecker(arrayOfTypeCheckers) {\n if (!Array.isArray(arrayOfTypeCheckers)) {\n process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;\n return emptyFunctionThatReturnsNull;\n }\n\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n if (typeof checker !== 'function') {\n printWarning(\n 'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +\n 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'\n );\n return emptyFunctionThatReturnsNull;\n }\n }\n\n function validate(props, propName, componentName, location, propFullName) {\n var expectedTypes = [];\n for (var i = 0; i < arrayOfTypeCheckers.length; i++) {\n var checker = arrayOfTypeCheckers[i];\n var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);\n if (checkerResult == null) {\n return null;\n }\n if (checkerResult.data && has(checkerResult.data, 'expectedType')) {\n expectedTypes.push(checkerResult.data.expectedType);\n }\n }\n var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));\n }\n return createChainableTypeChecker(validate);\n }\n\n function createNodeChecker() {\n function validate(props, propName, componentName, location, propFullName) {\n if (!isNode(props[propName])) {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function invalidValidatorError(componentName, location, propFullName, key, type) {\n return new PropTypeError(\n (componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +\n 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'\n );\n }\n\n function createShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n for (var key in shapeTypes) {\n var checker = shapeTypes[key];\n if (typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n return createChainableTypeChecker(validate);\n }\n\n function createStrictShapeTypeChecker(shapeTypes) {\n function validate(props, propName, componentName, location, propFullName) {\n var propValue = props[propName];\n var propType = getPropType(propValue);\n if (propType !== 'object') {\n return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));\n }\n // We need to check all keys in case some are required but missing from props.\n var allKeys = assign({}, props[propName], shapeTypes);\n for (var key in allKeys) {\n var checker = shapeTypes[key];\n if (has(shapeTypes, key) && typeof checker !== 'function') {\n return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));\n }\n if (!checker) {\n return new PropTypeError(\n 'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +\n '\\nBad object: ' + JSON.stringify(props[propName], null, ' ') +\n '\\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')\n );\n }\n var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);\n if (error) {\n return error;\n }\n }\n return null;\n }\n\n return createChainableTypeChecker(validate);\n }\n\n function isNode(propValue) {\n switch (typeof propValue) {\n case 'number':\n case 'string':\n case 'undefined':\n return true;\n case 'boolean':\n return !propValue;\n case 'object':\n if (Array.isArray(propValue)) {\n return propValue.every(isNode);\n }\n if (propValue === null || isValidElement(propValue)) {\n return true;\n }\n\n var iteratorFn = getIteratorFn(propValue);\n if (iteratorFn) {\n var iterator = iteratorFn.call(propValue);\n var step;\n if (iteratorFn !== propValue.entries) {\n while (!(step = iterator.next()).done) {\n if (!isNode(step.value)) {\n return false;\n }\n }\n } else {\n // Iterator will provide entry [k,v] tuples rather than values.\n while (!(step = iterator.next()).done) {\n var entry = step.value;\n if (entry) {\n if (!isNode(entry[1])) {\n return false;\n }\n }\n }\n }\n } else {\n return false;\n }\n\n return true;\n default:\n return false;\n }\n }\n\n function isSymbol(propType, propValue) {\n // Native Symbol.\n if (propType === 'symbol') {\n return true;\n }\n\n // falsy value can't be a Symbol\n if (!propValue) {\n return false;\n }\n\n // 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'\n if (propValue['@@toStringTag'] === 'Symbol') {\n return true;\n }\n\n // Fallback for non-spec compliant Symbols which are polyfilled.\n if (typeof Symbol === 'function' && propValue instanceof Symbol) {\n return true;\n }\n\n return false;\n }\n\n // Equivalent of `typeof` but with special handling for array and regexp.\n function getPropType(propValue) {\n var propType = typeof propValue;\n if (Array.isArray(propValue)) {\n return 'array';\n }\n if (propValue instanceof RegExp) {\n // Old webkits (at least until Android 4.0) return 'function' rather than\n // 'object' for typeof a RegExp. We'll normalize this here so that /bla/\n // passes PropTypes.object.\n return 'object';\n }\n if (isSymbol(propType, propValue)) {\n return 'symbol';\n }\n return propType;\n }\n\n // This handles more types than `getPropType`. Only used for error messages.\n // See `createPrimitiveTypeChecker`.\n function getPreciseType(propValue) {\n if (typeof propValue === 'undefined' || propValue === null) {\n return '' + propValue;\n }\n var propType = getPropType(propValue);\n if (propType === 'object') {\n if (propValue instanceof Date) {\n return 'date';\n } else if (propValue instanceof RegExp) {\n return 'regexp';\n }\n }\n return propType;\n }\n\n // Returns a string that is postfixed to a warning about an invalid type.\n // For example, \"undefined\" or \"of type array\"\n function getPostfixForTypeWarning(value) {\n var type = getPreciseType(value);\n switch (type) {\n case 'array':\n case 'object':\n return 'an ' + type;\n case 'boolean':\n case 'date':\n case 'regexp':\n return 'a ' + type;\n default:\n return type;\n }\n }\n\n // Returns class name of the object, if any.\n function getClassName(propValue) {\n if (!propValue.constructor || !propValue.constructor.name) {\n return ANONYMOUS;\n }\n return propValue.constructor.name;\n }\n\n ReactPropTypes.checkPropTypes = checkPropTypes;\n ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\nvar ReactPropTypesSecret = require('./lib/ReactPropTypesSecret');\n\nfunction emptyFunction() {}\nfunction emptyFunctionWithReset() {}\nemptyFunctionWithReset.resetWarningCache = emptyFunction;\n\nmodule.exports = function() {\n function shim(props, propName, componentName, location, propFullName, secret) {\n if (secret === ReactPropTypesSecret) {\n // It is still safe when called from React.\n return;\n }\n var err = new Error(\n 'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +\n 'Use PropTypes.checkPropTypes() to call them. ' +\n 'Read more at http://fb.me/use-check-prop-types'\n );\n err.name = 'Invariant Violation';\n throw err;\n };\n shim.isRequired = shim;\n function getShim() {\n return shim;\n };\n // Important!\n // Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.\n var ReactPropTypes = {\n array: shim,\n bigint: shim,\n bool: shim,\n func: shim,\n number: shim,\n object: shim,\n string: shim,\n symbol: shim,\n\n any: shim,\n arrayOf: getShim,\n element: shim,\n elementType: shim,\n instanceOf: getShim,\n node: shim,\n objectOf: getShim,\n oneOf: getShim,\n oneOfType: getShim,\n shape: getShim,\n exact: getShim,\n\n checkPropTypes: emptyFunctionWithReset,\n resetWarningCache: emptyFunction\n };\n\n ReactPropTypes.PropTypes = ReactPropTypes;\n\n return ReactPropTypes;\n};\n","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nif (process.env.NODE_ENV !== 'production') {\n var ReactIs = require('react-is');\n\n // By explicitly using `prop-types` you are opting into new development behavior.\n // http://fb.me/prop-types-in-prod\n var throwOnDirectAccess = true;\n module.exports = require('./factoryWithTypeCheckers')(ReactIs.isElement, throwOnDirectAccess);\n} else {\n // By explicitly using `prop-types` you are opting into new production behavior.\n // http://fb.me/prop-types-in-prod\n module.exports = require('./factoryWithThrowingShims')();\n}\n","/**\n * @license React\n * react-is.production.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\nvar REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_PORTAL_TYPE = Symbol.for(\"react.portal\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\"),\n REACT_STRICT_MODE_TYPE = Symbol.for(\"react.strict_mode\"),\n REACT_PROFILER_TYPE = Symbol.for(\"react.profiler\");\nSymbol.for(\"react.provider\");\nvar REACT_CONSUMER_TYPE = Symbol.for(\"react.consumer\"),\n REACT_CONTEXT_TYPE = Symbol.for(\"react.context\"),\n REACT_FORWARD_REF_TYPE = Symbol.for(\"react.forward_ref\"),\n REACT_SUSPENSE_TYPE = Symbol.for(\"react.suspense\"),\n REACT_SUSPENSE_LIST_TYPE = Symbol.for(\"react.suspense_list\"),\n REACT_MEMO_TYPE = Symbol.for(\"react.memo\"),\n REACT_LAZY_TYPE = Symbol.for(\"react.lazy\"),\n REACT_VIEW_TRANSITION_TYPE = Symbol.for(\"react.view_transition\"),\n REACT_CLIENT_REFERENCE = Symbol.for(\"react.client.reference\");\nfunction typeOf(object) {\n if (\"object\" === typeof object && null !== object) {\n var $$typeof = object.$$typeof;\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n switch (((object = object.type), object)) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n case REACT_VIEW_TRANSITION_TYPE:\n return object;\n default:\n switch (((object = object && object.$$typeof), object)) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n return object;\n case REACT_CONSUMER_TYPE:\n return object;\n default:\n return $$typeof;\n }\n }\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n}\nexports.ContextConsumer = REACT_CONSUMER_TYPE;\nexports.ContextProvider = REACT_CONTEXT_TYPE;\nexports.Element = REACT_ELEMENT_TYPE;\nexports.ForwardRef = REACT_FORWARD_REF_TYPE;\nexports.Fragment = REACT_FRAGMENT_TYPE;\nexports.Lazy = REACT_LAZY_TYPE;\nexports.Memo = REACT_MEMO_TYPE;\nexports.Portal = REACT_PORTAL_TYPE;\nexports.Profiler = REACT_PROFILER_TYPE;\nexports.StrictMode = REACT_STRICT_MODE_TYPE;\nexports.Suspense = REACT_SUSPENSE_TYPE;\nexports.SuspenseList = REACT_SUSPENSE_LIST_TYPE;\nexports.isContextConsumer = function (object) {\n return typeOf(object) === REACT_CONSUMER_TYPE;\n};\nexports.isContextProvider = function (object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n};\nexports.isElement = function (object) {\n return (\n \"object\" === typeof object &&\n null !== object &&\n object.$$typeof === REACT_ELEMENT_TYPE\n );\n};\nexports.isForwardRef = function (object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n};\nexports.isFragment = function (object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n};\nexports.isLazy = function (object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n};\nexports.isMemo = function (object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n};\nexports.isPortal = function (object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n};\nexports.isProfiler = function (object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n};\nexports.isStrictMode = function (object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n};\nexports.isSuspense = function (object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n};\nexports.isSuspenseList = function (object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n};\nexports.isValidElementType = function (type) {\n return \"string\" === typeof type ||\n \"function\" === typeof type ||\n type === REACT_FRAGMENT_TYPE ||\n type === REACT_PROFILER_TYPE ||\n type === REACT_STRICT_MODE_TYPE ||\n type === REACT_SUSPENSE_TYPE ||\n type === REACT_SUSPENSE_LIST_TYPE ||\n (\"object\" === typeof type &&\n null !== type &&\n (type.$$typeof === REACT_LAZY_TYPE ||\n type.$$typeof === REACT_MEMO_TYPE ||\n type.$$typeof === REACT_CONTEXT_TYPE ||\n type.$$typeof === REACT_CONSUMER_TYPE ||\n type.$$typeof === REACT_FORWARD_REF_TYPE ||\n type.$$typeof === REACT_CLIENT_REFERENCE ||\n void 0 !== type.getModuleId))\n ? !0\n : !1;\n};\nexports.typeOf = typeOf;\n","/**\n * @license React\n * react-is.development.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\n\"production\" !== process.env.NODE_ENV &&\n (function () {\n function typeOf(object) {\n if (\"object\" === typeof object && null !== object) {\n var $$typeof = object.$$typeof;\n switch ($$typeof) {\n case REACT_ELEMENT_TYPE:\n switch (((object = object.type), object)) {\n case REACT_FRAGMENT_TYPE:\n case REACT_PROFILER_TYPE:\n case REACT_STRICT_MODE_TYPE:\n case REACT_SUSPENSE_TYPE:\n case REACT_SUSPENSE_LIST_TYPE:\n case REACT_VIEW_TRANSITION_TYPE:\n return object;\n default:\n switch (((object = object && object.$$typeof), object)) {\n case REACT_CONTEXT_TYPE:\n case REACT_FORWARD_REF_TYPE:\n case REACT_LAZY_TYPE:\n case REACT_MEMO_TYPE:\n return object;\n case REACT_CONSUMER_TYPE:\n return object;\n default:\n return $$typeof;\n }\n }\n case REACT_PORTAL_TYPE:\n return $$typeof;\n }\n }\n }\n var REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_PORTAL_TYPE = Symbol.for(\"react.portal\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\"),\n REACT_STRICT_MODE_TYPE = Symbol.for(\"react.strict_mode\"),\n REACT_PROFILER_TYPE = Symbol.for(\"react.profiler\");\n Symbol.for(\"react.provider\");\n var REACT_CONSUMER_TYPE = Symbol.for(\"react.consumer\"),\n REACT_CONTEXT_TYPE = Symbol.for(\"react.context\"),\n REACT_FORWARD_REF_TYPE = Symbol.for(\"react.forward_ref\"),\n REACT_SUSPENSE_TYPE = Symbol.for(\"react.suspense\"),\n REACT_SUSPENSE_LIST_TYPE = Symbol.for(\"react.suspense_list\"),\n REACT_MEMO_TYPE = Symbol.for(\"react.memo\"),\n REACT_LAZY_TYPE = Symbol.for(\"react.lazy\"),\n REACT_VIEW_TRANSITION_TYPE = Symbol.for(\"react.view_transition\"),\n REACT_CLIENT_REFERENCE = Symbol.for(\"react.client.reference\");\n exports.ContextConsumer = REACT_CONSUMER_TYPE;\n exports.ContextProvider = REACT_CONTEXT_TYPE;\n exports.Element = REACT_ELEMENT_TYPE;\n exports.ForwardRef = REACT_FORWARD_REF_TYPE;\n exports.Fragment = REACT_FRAGMENT_TYPE;\n exports.Lazy = REACT_LAZY_TYPE;\n exports.Memo = REACT_MEMO_TYPE;\n exports.Portal = REACT_PORTAL_TYPE;\n exports.Profiler = REACT_PROFILER_TYPE;\n exports.StrictMode = REACT_STRICT_MODE_TYPE;\n exports.Suspense = REACT_SUSPENSE_TYPE;\n exports.SuspenseList = REACT_SUSPENSE_LIST_TYPE;\n exports.isContextConsumer = function (object) {\n return typeOf(object) === REACT_CONSUMER_TYPE;\n };\n exports.isContextProvider = function (object) {\n return typeOf(object) === REACT_CONTEXT_TYPE;\n };\n exports.isElement = function (object) {\n return (\n \"object\" === typeof object &&\n null !== object &&\n object.$$typeof === REACT_ELEMENT_TYPE\n );\n };\n exports.isForwardRef = function (object) {\n return typeOf(object) === REACT_FORWARD_REF_TYPE;\n };\n exports.isFragment = function (object) {\n return typeOf(object) === REACT_FRAGMENT_TYPE;\n };\n exports.isLazy = function (object) {\n return typeOf(object) === REACT_LAZY_TYPE;\n };\n exports.isMemo = function (object) {\n return typeOf(object) === REACT_MEMO_TYPE;\n };\n exports.isPortal = function (object) {\n return typeOf(object) === REACT_PORTAL_TYPE;\n };\n exports.isProfiler = function (object) {\n return typeOf(object) === REACT_PROFILER_TYPE;\n };\n exports.isStrictMode = function (object) {\n return typeOf(object) === REACT_STRICT_MODE_TYPE;\n };\n exports.isSuspense = function (object) {\n return typeOf(object) === REACT_SUSPENSE_TYPE;\n };\n exports.isSuspenseList = function (object) {\n return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;\n };\n exports.isValidElementType = function (type) {\n return \"string\" === typeof type ||\n \"function\" === typeof type ||\n type === REACT_FRAGMENT_TYPE ||\n type === REACT_PROFILER_TYPE ||\n type === REACT_STRICT_MODE_TYPE ||\n type === REACT_SUSPENSE_TYPE ||\n type === REACT_SUSPENSE_LIST_TYPE ||\n (\"object\" === typeof type &&\n null !== type &&\n (type.$$typeof === REACT_LAZY_TYPE ||\n type.$$typeof === REACT_MEMO_TYPE ||\n type.$$typeof === REACT_CONTEXT_TYPE ||\n type.$$typeof === REACT_CONSUMER_TYPE ||\n type.$$typeof === REACT_FORWARD_REF_TYPE ||\n type.$$typeof === REACT_CLIENT_REFERENCE ||\n void 0 !== type.getModuleId))\n ? !0\n : !1;\n };\n exports.typeOf = typeOf;\n })();\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","import * as React from 'react';\nimport { isValidElementType } from 'react-is';\n\n// https://github.com/sindresorhus/is-plain-obj/blob/main/index.js\nexport function isPlainObject(item) {\n if (typeof item !== 'object' || item === null) {\n return false;\n }\n const prototype = Object.getPrototypeOf(item);\n return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in item) && !(Symbol.iterator in item);\n}\nfunction deepClone(source) {\n if (/*#__PURE__*/React.isValidElement(source) || isValidElementType(source) || !isPlainObject(source)) {\n return source;\n }\n const output = {};\n Object.keys(source).forEach(key => {\n output[key] = deepClone(source[key]);\n });\n return output;\n}\n\n/**\n * Merge objects deeply.\n * It will shallow copy React elements.\n *\n * If `options.clone` is set to `false` the source object will be merged directly into the target object.\n *\n * @example\n * ```ts\n * deepmerge({ a: { b: 1 }, d: 2 }, { a: { c: 2 }, d: 4 });\n * // => { a: { b: 1, c: 2 }, d: 4 }\n * ````\n *\n * @param target The target object.\n * @param source The source object.\n * @param options The merge options.\n * @param options.clone Set to `false` to merge the source object directly into the target object.\n * @returns The merged object.\n */\nexport default function deepmerge(target, source, options = {\n clone: true\n}) {\n const output = options.clone ? {\n ...target\n } : target;\n if (isPlainObject(target) && isPlainObject(source)) {\n Object.keys(source).forEach(key => {\n if (/*#__PURE__*/React.isValidElement(source[key]) || isValidElementType(source[key])) {\n output[key] = source[key];\n } else if (isPlainObject(source[key]) &&\n // Avoid prototype pollution\n Object.prototype.hasOwnProperty.call(target, key) && isPlainObject(target[key])) {\n // Since `output` is a clone of `target` and we have narrowed `target` in this block we can cast to the same type.\n output[key] = deepmerge(target[key], source[key], options);\n } else if (options.clone) {\n output[key] = isPlainObject(source[key]) ? deepClone(source[key]) : source[key];\n } else {\n output[key] = source[key];\n }\n });\n }\n return output;\n}","// Sorted ASC by size. That's important.\n// It can't be configured as it's used statically for propTypes.\nexport const breakpointKeys = ['xs', 'sm', 'md', 'lg', 'xl'];\nconst sortBreakpointsValues = values => {\n const breakpointsAsArray = Object.keys(values).map(key => ({\n key,\n val: values[key]\n })) || [];\n // Sort in ascending order\n breakpointsAsArray.sort((breakpoint1, breakpoint2) => breakpoint1.val - breakpoint2.val);\n return breakpointsAsArray.reduce((acc, obj) => {\n return {\n ...acc,\n [obj.key]: obj.val\n };\n }, {});\n};\n\n// Keep in mind that @media is inclusive by the CSS specification.\nexport default function createBreakpoints(breakpoints) {\n const {\n // The breakpoint **start** at this value.\n // For instance with the first breakpoint xs: [xs, sm).\n values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n },\n unit = 'px',\n step = 5,\n ...other\n } = breakpoints;\n const sortedValues = sortBreakpointsValues(values);\n const keys = Object.keys(sortedValues);\n function up(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (min-width:${value}${unit})`;\n }\n function down(key) {\n const value = typeof values[key] === 'number' ? values[key] : key;\n return `@media (max-width:${value - step / 100}${unit})`;\n }\n function between(start, end) {\n const endIndex = keys.indexOf(end);\n return `@media (min-width:${typeof values[start] === 'number' ? values[start] : start}${unit}) and ` + `(max-width:${(endIndex !== -1 && typeof values[keys[endIndex]] === 'number' ? values[keys[endIndex]] : end) - step / 100}${unit})`;\n }\n function only(key) {\n if (keys.indexOf(key) + 1 < keys.length) {\n return between(key, keys[keys.indexOf(key) + 1]);\n }\n return up(key);\n }\n function not(key) {\n // handle first and last key separately, for better readability\n const keyIndex = keys.indexOf(key);\n if (keyIndex === 0) {\n return up(keys[1]);\n }\n if (keyIndex === keys.length - 1) {\n return down(keys[keyIndex]);\n }\n return between(key, keys[keys.indexOf(key) + 1]).replace('@media', '@media not all and');\n }\n return {\n keys,\n values: sortedValues,\n up,\n down,\n between,\n only,\n not,\n unit,\n ...other\n };\n}","import _formatErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n/**\n * For using in `sx` prop to sort the breakpoint from low to high.\n * Note: this function does not work and will not support multiple units.\n * e.g. input: { '@container (min-width:300px)': '1rem', '@container (min-width:40rem)': '2rem' }\n * output: { '@container (min-width:40rem)': '2rem', '@container (min-width:300px)': '1rem' } // since 40 < 300 eventhough 40rem > 300px\n */\nexport function sortContainerQueries(theme, css) {\n if (!theme.containerQueries) {\n return css;\n }\n const sorted = Object.keys(css).filter(key => key.startsWith('@container')).sort((a, b) => {\n const regex = /min-width:\\s*([0-9.]+)/;\n return +(a.match(regex)?.[1] || 0) - +(b.match(regex)?.[1] || 0);\n });\n if (!sorted.length) {\n return css;\n }\n return sorted.reduce((acc, key) => {\n const value = css[key];\n delete acc[key];\n acc[key] = value;\n return acc;\n }, {\n ...css\n });\n}\nexport function isCqShorthand(breakpointKeys, value) {\n return value === '@' || value.startsWith('@') && (breakpointKeys.some(key => value.startsWith(`@${key}`)) || !!value.match(/^@\\d/));\n}\nexport function getContainerQuery(theme, shorthand) {\n const matches = shorthand.match(/^@([^/]+)?\\/?(.+)?$/);\n if (!matches) {\n if (process.env.NODE_ENV !== 'production') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: The provided shorthand ${`(${shorthand})`} is invalid. The format should be \\`@<breakpoint | number>\\` or \\`@<breakpoint | number>/<container>\\`.\\n` + 'For example, `@sm` or `@600` or `@40rem/sidebar`.' : _formatErrorMessage(18, `(${shorthand})`));\n }\n return null;\n }\n const [, containerQuery, containerName] = matches;\n const value = Number.isNaN(+containerQuery) ? containerQuery || 0 : +containerQuery;\n return theme.containerQueries(containerName).up(value);\n}\nexport default function cssContainerQueries(themeInput) {\n const toContainerQuery = (mediaQuery, name) => mediaQuery.replace('@media', name ? `@container ${name}` : '@container');\n function attachCq(node, name) {\n node.up = (...args) => toContainerQuery(themeInput.breakpoints.up(...args), name);\n node.down = (...args) => toContainerQuery(themeInput.breakpoints.down(...args), name);\n node.between = (...args) => toContainerQuery(themeInput.breakpoints.between(...args), name);\n node.only = (...args) => toContainerQuery(themeInput.breakpoints.only(...args), name);\n node.not = (...args) => {\n const result = toContainerQuery(themeInput.breakpoints.not(...args), name);\n if (result.includes('not all and')) {\n // `@container` does not work with `not all and`, so need to invert the logic\n return result.replace('not all and ', '').replace('min-width:', 'width<').replace('max-width:', 'width>').replace('and', 'or');\n }\n return result;\n };\n }\n const node = {};\n const containerQueries = name => {\n attachCq(node, name);\n return node;\n };\n attachCq(containerQueries);\n return {\n ...themeInput,\n containerQueries\n };\n}","const shape = {\n borderRadius: 4\n};\nexport default shape;","import PropTypes from 'prop-types';\nconst responsivePropType = process.env.NODE_ENV !== 'production' ? PropTypes.oneOfType([PropTypes.number, PropTypes.string, PropTypes.object, PropTypes.array]) : {};\nexport default responsivePropType;","import deepmerge from '@mui/utils/deepmerge';\nfunction merge(acc, item) {\n if (!item) {\n return acc;\n }\n return deepmerge(acc, item, {\n clone: false // No need to clone deep, it's way faster.\n });\n}\nexport default merge;","import PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport merge from \"../merge/index.js\";\nimport { isCqShorthand, getContainerQuery } from \"../cssContainerQueries/index.js\";\n\n// The breakpoint **start** at this value.\n// For instance with the first breakpoint xs: [xs, sm[.\nexport const values = {\n xs: 0,\n // phone\n sm: 600,\n // tablet\n md: 900,\n // small laptop\n lg: 1200,\n // desktop\n xl: 1536 // large screen\n};\nconst defaultBreakpoints = {\n // Sorted ASC by size. That's important.\n // It can't be configured as it's used statically for propTypes.\n keys: ['xs', 'sm', 'md', 'lg', 'xl'],\n up: key => `@media (min-width:${values[key]}px)`\n};\nconst defaultContainerQueries = {\n containerQueries: containerName => ({\n up: key => {\n let result = typeof key === 'number' ? key : values[key] || key;\n if (typeof result === 'number') {\n result = `${result}px`;\n }\n return containerName ? `@container ${containerName} (min-width:${result})` : `@container (min-width:${result})`;\n }\n })\n};\nexport function handleBreakpoints(props, propValue, styleFromPropValue) {\n const theme = props.theme || {};\n if (Array.isArray(propValue)) {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return propValue.reduce((acc, item, index) => {\n acc[themeBreakpoints.up(themeBreakpoints.keys[index])] = styleFromPropValue(propValue[index]);\n return acc;\n }, {});\n }\n if (typeof propValue === 'object') {\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n return Object.keys(propValue).reduce((acc, breakpoint) => {\n if (isCqShorthand(themeBreakpoints.keys, breakpoint)) {\n const containerKey = getContainerQuery(theme.containerQueries ? theme : defaultContainerQueries, breakpoint);\n if (containerKey) {\n acc[containerKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n }\n }\n // key is breakpoint\n else if (Object.keys(themeBreakpoints.values || values).includes(breakpoint)) {\n const mediaKey = themeBreakpoints.up(breakpoint);\n acc[mediaKey] = styleFromPropValue(propValue[breakpoint], breakpoint);\n } else {\n const cssKey = breakpoint;\n acc[cssKey] = propValue[cssKey];\n }\n return acc;\n }, {});\n }\n const output = styleFromPropValue(propValue);\n return output;\n}\nfunction breakpoints(styleFunction) {\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const newStyleFunction = props => {\n const theme = props.theme || {};\n const base = styleFunction(props);\n const themeBreakpoints = theme.breakpoints || defaultBreakpoints;\n const extended = themeBreakpoints.keys.reduce((acc, key) => {\n if (props[key]) {\n acc = acc || {};\n acc[themeBreakpoints.up(key)] = styleFunction({\n theme,\n ...props[key]\n });\n }\n return acc;\n }, null);\n return merge(base, extended);\n };\n newStyleFunction.propTypes = process.env.NODE_ENV !== 'production' ? {\n ...styleFunction.propTypes,\n xs: PropTypes.object,\n sm: PropTypes.object,\n md: PropTypes.object,\n lg: PropTypes.object,\n xl: PropTypes.object\n } : {};\n newStyleFunction.filterProps = ['xs', 'sm', 'md', 'lg', 'xl', ...styleFunction.filterProps];\n return newStyleFunction;\n}\nexport function createEmptyBreakpointObject(breakpointsInput = {}) {\n const breakpointsInOrder = breakpointsInput.keys?.reduce((acc, key) => {\n const breakpointStyleKey = breakpointsInput.up(key);\n acc[breakpointStyleKey] = {};\n return acc;\n }, {});\n return breakpointsInOrder || {};\n}\nexport function removeUnusedBreakpoints(breakpointKeys, style) {\n return breakpointKeys.reduce((acc, key) => {\n const breakpointOutput = acc[key];\n const isBreakpointUnused = !breakpointOutput || Object.keys(breakpointOutput).length === 0;\n if (isBreakpointUnused) {\n delete acc[key];\n }\n return acc;\n }, style);\n}\nexport function mergeBreakpointsInOrder(breakpointsInput, ...styles) {\n const emptyBreakpoints = createEmptyBreakpointObject(breakpointsInput);\n const mergedOutput = [emptyBreakpoints, ...styles].reduce((prev, next) => deepmerge(prev, next), {});\n return removeUnusedBreakpoints(Object.keys(emptyBreakpoints), mergedOutput);\n}\n\n// compute base for responsive values; e.g.,\n// [1,2,3] => {xs: true, sm: true, md: true}\n// {xs: 1, sm: 2, md: 3} => {xs: true, sm: true, md: true}\nexport function computeBreakpointsBase(breakpointValues, themeBreakpoints) {\n // fixed value\n if (typeof breakpointValues !== 'object') {\n return {};\n }\n const base = {};\n const breakpointsKeys = Object.keys(themeBreakpoints);\n if (Array.isArray(breakpointValues)) {\n breakpointsKeys.forEach((breakpoint, i) => {\n if (i < breakpointValues.length) {\n base[breakpoint] = true;\n }\n });\n } else {\n breakpointsKeys.forEach(breakpoint => {\n if (breakpointValues[breakpoint] != null) {\n base[breakpoint] = true;\n }\n });\n }\n return base;\n}\nexport function resolveBreakpointValues({\n values: breakpointValues,\n breakpoints: themeBreakpoints,\n base: customBase\n}) {\n const base = customBase || computeBreakpointsBase(breakpointValues, themeBreakpoints);\n const keys = Object.keys(base);\n if (keys.length === 0) {\n return breakpointValues;\n }\n let previous;\n return keys.reduce((acc, breakpoint, i) => {\n if (Array.isArray(breakpointValues)) {\n acc[breakpoint] = breakpointValues[i] != null ? breakpointValues[i] : breakpointValues[previous];\n previous = i;\n } else if (typeof breakpointValues === 'object') {\n acc[breakpoint] = breakpointValues[breakpoint] != null ? breakpointValues[breakpoint] : breakpointValues[previous];\n previous = breakpoint;\n } else {\n acc[breakpoint] = breakpointValues;\n }\n return acc;\n }, {});\n}\nexport default breakpoints;","import _formatErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\n// It should to be noted that this function isn't equivalent to `text-transform: capitalize`.\n//\n// A strict capitalization should uppercase the first letter of each word in the sentence.\n// We only handle the first word.\nexport default function capitalize(string) {\n if (typeof string !== 'string') {\n throw new Error(process.env.NODE_ENV !== \"production\" ? 'MUI: `capitalize(string)` expects a string argument.' : _formatErrorMessage(7));\n }\n return string.charAt(0).toUpperCase() + string.slice(1);\n}","import capitalize from '@mui/utils/capitalize';\nimport responsivePropType from \"../responsivePropType/index.js\";\nimport { handleBreakpoints } from \"../breakpoints/index.js\";\nexport function getPath(obj, path, checkVars = true) {\n if (!path || typeof path !== 'string') {\n return null;\n }\n\n // Check if CSS variables are used\n if (obj && obj.vars && checkVars) {\n const val = `vars.${path}`.split('.').reduce((acc, item) => acc && acc[item] ? acc[item] : null, obj);\n if (val != null) {\n return val;\n }\n }\n return path.split('.').reduce((acc, item) => {\n if (acc && acc[item] != null) {\n return acc[item];\n }\n return null;\n }, obj);\n}\nexport function getStyleValue(themeMapping, transform, propValueFinal, userValue = propValueFinal) {\n let value;\n if (typeof themeMapping === 'function') {\n value = themeMapping(propValueFinal);\n } else if (Array.isArray(themeMapping)) {\n value = themeMapping[propValueFinal] || userValue;\n } else {\n value = getPath(themeMapping, propValueFinal) || userValue;\n }\n if (transform) {\n value = transform(value, userValue, themeMapping);\n }\n return value;\n}\nfunction style(options) {\n const {\n prop,\n cssProperty = options.prop,\n themeKey,\n transform\n } = options;\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n if (props[prop] == null) {\n return null;\n }\n const propValue = props[prop];\n const theme = props.theme;\n const themeMapping = getPath(theme, themeKey) || {};\n const styleFromPropValue = propValueFinal => {\n let value = getStyleValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getStyleValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, propValue, styleFromPropValue);\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? {\n [prop]: responsivePropType\n } : {};\n fn.filterProps = [prop];\n return fn;\n}\nexport default style;","import responsivePropType from \"../responsivePropType/index.js\";\nimport { handleBreakpoints } from \"../breakpoints/index.js\";\nimport { getPath } from \"../style/index.js\";\nimport merge from \"../merge/index.js\";\nimport memoize from \"../memoize/index.js\";\nconst properties = {\n m: 'margin',\n p: 'padding'\n};\nconst directions = {\n t: 'Top',\n r: 'Right',\n b: 'Bottom',\n l: 'Left',\n x: ['Left', 'Right'],\n y: ['Top', 'Bottom']\n};\nconst aliases = {\n marginX: 'mx',\n marginY: 'my',\n paddingX: 'px',\n paddingY: 'py'\n};\n\n// memoize() impact:\n// From 300,000 ops/sec\n// To 350,000 ops/sec\nconst getCssProperties = memoize(prop => {\n // It's not a shorthand notation.\n if (prop.length > 2) {\n if (aliases[prop]) {\n prop = aliases[prop];\n } else {\n return [prop];\n }\n }\n const [a, b] = prop.split('');\n const property = properties[a];\n const direction = directions[b] || '';\n return Array.isArray(direction) ? direction.map(dir => property + dir) : [property + direction];\n});\nexport const marginKeys = ['m', 'mt', 'mr', 'mb', 'ml', 'mx', 'my', 'margin', 'marginTop', 'marginRight', 'marginBottom', 'marginLeft', 'marginX', 'marginY', 'marginInline', 'marginInlineStart', 'marginInlineEnd', 'marginBlock', 'marginBlockStart', 'marginBlockEnd'];\nexport const paddingKeys = ['p', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'padding', 'paddingTop', 'paddingRight', 'paddingBottom', 'paddingLeft', 'paddingX', 'paddingY', 'paddingInline', 'paddingInlineStart', 'paddingInlineEnd', 'paddingBlock', 'paddingBlockStart', 'paddingBlockEnd'];\nconst spacingKeys = [...marginKeys, ...paddingKeys];\nexport function createUnaryUnit(theme, themeKey, defaultValue, propName) {\n const themeSpacing = getPath(theme, themeKey, true) ?? defaultValue;\n if (typeof themeSpacing === 'number' || typeof themeSpacing === 'string') {\n return val => {\n if (typeof val === 'string') {\n return val;\n }\n if (process.env.NODE_ENV !== 'production') {\n if (typeof val !== 'number') {\n console.error(`MUI: Expected ${propName} argument to be a number or a string, got ${val}.`);\n }\n }\n if (typeof themeSpacing === 'string') {\n if (themeSpacing.startsWith('var(') && val === 0) {\n return 0;\n }\n if (themeSpacing.startsWith('var(') && val === 1) {\n return themeSpacing;\n }\n return `calc(${val} * ${themeSpacing})`;\n }\n return themeSpacing * val;\n };\n }\n if (Array.isArray(themeSpacing)) {\n return val => {\n if (typeof val === 'string') {\n return val;\n }\n const abs = Math.abs(val);\n if (process.env.NODE_ENV !== 'production') {\n if (!Number.isInteger(abs)) {\n console.error([`MUI: The \\`theme.${themeKey}\\` array type cannot be combined with non integer values.` + `You should either use an integer value that can be used as index, or define the \\`theme.${themeKey}\\` as a number.`].join('\\n'));\n } else if (abs > themeSpacing.length - 1) {\n console.error([`MUI: The value provided (${abs}) overflows.`, `The supported values are: ${JSON.stringify(themeSpacing)}.`, `${abs} > ${themeSpacing.length - 1}, you need to add the missing values.`].join('\\n'));\n }\n }\n const transformed = themeSpacing[abs];\n if (val >= 0) {\n return transformed;\n }\n if (typeof transformed === 'number') {\n return -transformed;\n }\n if (typeof transformed === 'string' && transformed.startsWith('var(')) {\n return `calc(-1 * ${transformed})`;\n }\n return `-${transformed}`;\n };\n }\n if (typeof themeSpacing === 'function') {\n return themeSpacing;\n }\n if (process.env.NODE_ENV !== 'production') {\n console.error([`MUI: The \\`theme.${themeKey}\\` value (${themeSpacing}) is invalid.`, 'It should be a number, an array or a function.'].join('\\n'));\n }\n return () => undefined;\n}\nexport function createUnarySpacing(theme) {\n return createUnaryUnit(theme, 'spacing', 8, 'spacing');\n}\nexport function getValue(transformer, propValue) {\n if (typeof propValue === 'string' || propValue == null) {\n return propValue;\n }\n return transformer(propValue);\n}\nexport function getStyleFromPropValue(cssProperties, transformer) {\n return propValue => cssProperties.reduce((acc, cssProperty) => {\n acc[cssProperty] = getValue(transformer, propValue);\n return acc;\n }, {});\n}\nfunction resolveCssProperty(props, keys, prop, transformer) {\n // Using a hash computation over an array iteration could be faster, but with only 28 items,\n // it's doesn't worth the bundle size.\n if (!keys.includes(prop)) {\n return null;\n }\n const cssProperties = getCssProperties(prop);\n const styleFromPropValue = getStyleFromPropValue(cssProperties, transformer);\n const propValue = props[prop];\n return handleBreakpoints(props, propValue, styleFromPropValue);\n}\nfunction style(props, keys) {\n const transformer = createUnarySpacing(props.theme);\n return Object.keys(props).map(prop => resolveCssProperty(props, keys, prop, transformer)).reduce(merge, {});\n}\nexport function margin(props) {\n return style(props, marginKeys);\n}\nmargin.propTypes = process.env.NODE_ENV !== 'production' ? marginKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nmargin.filterProps = marginKeys;\nexport function padding(props) {\n return style(props, paddingKeys);\n}\npadding.propTypes = process.env.NODE_ENV !== 'production' ? paddingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\npadding.filterProps = paddingKeys;\nfunction spacing(props) {\n return style(props, spacingKeys);\n}\nspacing.propTypes = process.env.NODE_ENV !== 'production' ? spacingKeys.reduce((obj, key) => {\n obj[key] = responsivePropType;\n return obj;\n}, {}) : {};\nspacing.filterProps = spacingKeys;\nexport default spacing;","export default function memoize(fn) {\n const cache = {};\n return arg => {\n if (cache[arg] === undefined) {\n cache[arg] = fn(arg);\n }\n return cache[arg];\n };\n}","import merge from \"../merge/index.js\";\nfunction compose(...styles) {\n const handlers = styles.reduce((acc, style) => {\n style.filterProps.forEach(prop => {\n acc[prop] = style;\n });\n return acc;\n }, {});\n\n // false positive\n // eslint-disable-next-line react/function-component-definition\n const fn = props => {\n return Object.keys(props).reduce((acc, prop) => {\n if (handlers[prop]) {\n return merge(acc, handlers[prop](props));\n }\n return acc;\n }, {});\n };\n fn.propTypes = process.env.NODE_ENV !== 'production' ? styles.reduce((acc, style) => Object.assign(acc, style.propTypes), {}) : {};\n fn.filterProps = styles.reduce((acc, style) => acc.concat(style.filterProps), []);\n return fn;\n}\nexport default compose;","import responsivePropType from \"../responsivePropType/index.js\";\nimport style from \"../style/index.js\";\nimport compose from \"../compose/index.js\";\nimport { createUnaryUnit, getValue } from \"../spacing/index.js\";\nimport { handleBreakpoints } from \"../breakpoints/index.js\";\nexport function borderTransform(value) {\n if (typeof value !== 'number') {\n return value;\n }\n return `${value}px solid`;\n}\nfunction createBorderStyle(prop, transform) {\n return style({\n prop,\n themeKey: 'borders',\n transform\n });\n}\nexport const border = createBorderStyle('border', borderTransform);\nexport const borderTop = createBorderStyle('borderTop', borderTransform);\nexport const borderRight = createBorderStyle('borderRight', borderTransform);\nexport const borderBottom = createBorderStyle('borderBottom', borderTransform);\nexport const borderLeft = createBorderStyle('borderLeft', borderTransform);\nexport const borderColor = createBorderStyle('borderColor');\nexport const borderTopColor = createBorderStyle('borderTopColor');\nexport const borderRightColor = createBorderStyle('borderRightColor');\nexport const borderBottomColor = createBorderStyle('borderBottomColor');\nexport const borderLeftColor = createBorderStyle('borderLeftColor');\nexport const outline = createBorderStyle('outline', borderTransform);\nexport const outlineColor = createBorderStyle('outlineColor');\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const borderRadius = props => {\n if (props.borderRadius !== undefined && props.borderRadius !== null) {\n const transformer = createUnaryUnit(props.theme, 'shape.borderRadius', 4, 'borderRadius');\n const styleFromPropValue = propValue => ({\n borderRadius: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.borderRadius, styleFromPropValue);\n }\n return null;\n};\nborderRadius.propTypes = process.env.NODE_ENV !== 'production' ? {\n borderRadius: responsivePropType\n} : {};\nborderRadius.filterProps = ['borderRadius'];\nconst borders = compose(border, borderTop, borderRight, borderBottom, borderLeft, borderColor, borderTopColor, borderRightColor, borderBottomColor, borderLeftColor, borderRadius, outline, outlineColor);\nexport default borders;","import style from \"../style/index.js\";\nimport compose from \"../compose/index.js\";\nimport { createUnaryUnit, getValue } from \"../spacing/index.js\";\nimport { handleBreakpoints } from \"../breakpoints/index.js\";\nimport responsivePropType from \"../responsivePropType/index.js\";\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const gap = props => {\n if (props.gap !== undefined && props.gap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'gap');\n const styleFromPropValue = propValue => ({\n gap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.gap, styleFromPropValue);\n }\n return null;\n};\ngap.propTypes = process.env.NODE_ENV !== 'production' ? {\n gap: responsivePropType\n} : {};\ngap.filterProps = ['gap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const columnGap = props => {\n if (props.columnGap !== undefined && props.columnGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'columnGap');\n const styleFromPropValue = propValue => ({\n columnGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.columnGap, styleFromPropValue);\n }\n return null;\n};\ncolumnGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n columnGap: responsivePropType\n} : {};\ncolumnGap.filterProps = ['columnGap'];\n\n// false positive\n// eslint-disable-next-line react/function-component-definition\nexport const rowGap = props => {\n if (props.rowGap !== undefined && props.rowGap !== null) {\n const transformer = createUnaryUnit(props.theme, 'spacing', 8, 'rowGap');\n const styleFromPropValue = propValue => ({\n rowGap: getValue(transformer, propValue)\n });\n return handleBreakpoints(props, props.rowGap, styleFromPropValue);\n }\n return null;\n};\nrowGap.propTypes = process.env.NODE_ENV !== 'production' ? {\n rowGap: responsivePropType\n} : {};\nrowGap.filterProps = ['rowGap'];\nexport const gridColumn = style({\n prop: 'gridColumn'\n});\nexport const gridRow = style({\n prop: 'gridRow'\n});\nexport const gridAutoFlow = style({\n prop: 'gridAutoFlow'\n});\nexport const gridAutoColumns = style({\n prop: 'gridAutoColumns'\n});\nexport const gridAutoRows = style({\n prop: 'gridAutoRows'\n});\nexport const gridTemplateColumns = style({\n prop: 'gridTemplateColumns'\n});\nexport const gridTemplateRows = style({\n prop: 'gridTemplateRows'\n});\nexport const gridTemplateAreas = style({\n prop: 'gridTemplateAreas'\n});\nexport const gridArea = style({\n prop: 'gridArea'\n});\nconst grid = compose(gap, columnGap, rowGap, gridColumn, gridRow, gridAutoFlow, gridAutoColumns, gridAutoRows, gridTemplateColumns, gridTemplateRows, gridTemplateAreas, gridArea);\nexport default grid;","import style from \"../style/index.js\";\nimport compose from \"../compose/index.js\";\nexport function paletteTransform(value, userValue) {\n if (userValue === 'grey') {\n return userValue;\n }\n return value;\n}\nexport const color = style({\n prop: 'color',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const bgcolor = style({\n prop: 'bgcolor',\n cssProperty: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nexport const backgroundColor = style({\n prop: 'backgroundColor',\n themeKey: 'palette',\n transform: paletteTransform\n});\nconst palette = compose(color, bgcolor, backgroundColor);\nexport default palette;","import style from \"../style/index.js\";\nimport compose from \"../compose/index.js\";\nimport { handleBreakpoints, values as breakpointsValues } from \"../breakpoints/index.js\";\nexport function sizingTransform(value) {\n return value <= 1 && value !== 0 ? `${value * 100}%` : value;\n}\nexport const width = style({\n prop: 'width',\n transform: sizingTransform\n});\nexport const maxWidth = props => {\n if (props.maxWidth !== undefined && props.maxWidth !== null) {\n const styleFromPropValue = propValue => {\n const breakpoint = props.theme?.breakpoints?.values?.[propValue] || breakpointsValues[propValue];\n if (!breakpoint) {\n return {\n maxWidth: sizingTransform(propValue)\n };\n }\n if (props.theme?.breakpoints?.unit !== 'px') {\n return {\n maxWidth: `${breakpoint}${props.theme.breakpoints.unit}`\n };\n }\n return {\n maxWidth: breakpoint\n };\n };\n return handleBreakpoints(props, props.maxWidth, styleFromPropValue);\n }\n return null;\n};\nmaxWidth.filterProps = ['maxWidth'];\nexport const minWidth = style({\n prop: 'minWidth',\n transform: sizingTransform\n});\nexport const height = style({\n prop: 'height',\n transform: sizingTransform\n});\nexport const maxHeight = style({\n prop: 'maxHeight',\n transform: sizingTransform\n});\nexport const minHeight = style({\n prop: 'minHeight',\n transform: sizingTransform\n});\nexport const sizeWidth = style({\n prop: 'size',\n cssProperty: 'width',\n transform: sizingTransform\n});\nexport const sizeHeight = style({\n prop: 'size',\n cssProperty: 'height',\n transform: sizingTransform\n});\nexport const boxSizing = style({\n prop: 'boxSizing'\n});\nconst sizing = compose(width, maxWidth, minWidth, height, maxHeight, minHeight, boxSizing);\nexport default sizing;","import { padding, margin } from \"../spacing/index.js\";\nimport { borderRadius, borderTransform } from \"../borders/index.js\";\nimport { gap, rowGap, columnGap } from \"../cssGrid/index.js\";\nimport { paletteTransform } from \"../palette/index.js\";\nimport { maxWidth, sizingTransform } from \"../sizing/index.js\";\nconst defaultSxConfig = {\n // borders\n border: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderTop: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderRight: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderBottom: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderLeft: {\n themeKey: 'borders',\n transform: borderTransform\n },\n borderColor: {\n themeKey: 'palette'\n },\n borderTopColor: {\n themeKey: 'palette'\n },\n borderRightColor: {\n themeKey: 'palette'\n },\n borderBottomColor: {\n themeKey: 'palette'\n },\n borderLeftColor: {\n themeKey: 'palette'\n },\n outline: {\n themeKey: 'borders',\n transform: borderTransform\n },\n outlineColor: {\n themeKey: 'palette'\n },\n borderRadius: {\n themeKey: 'shape.borderRadius',\n style: borderRadius\n },\n // palette\n color: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n bgcolor: {\n themeKey: 'palette',\n cssProperty: 'backgroundColor',\n transform: paletteTransform\n },\n backgroundColor: {\n themeKey: 'palette',\n transform: paletteTransform\n },\n // spacing\n p: {\n style: padding\n },\n pt: {\n style: padding\n },\n pr: {\n style: padding\n },\n pb: {\n style: padding\n },\n pl: {\n style: padding\n },\n px: {\n style: padding\n },\n py: {\n style: padding\n },\n padding: {\n style: padding\n },\n paddingTop: {\n style: padding\n },\n paddingRight: {\n style: padding\n },\n paddingBottom: {\n style: padding\n },\n paddingLeft: {\n style: padding\n },\n paddingX: {\n style: padding\n },\n paddingY: {\n style: padding\n },\n paddingInline: {\n style: padding\n },\n paddingInlineStart: {\n style: padding\n },\n paddingInlineEnd: {\n style: padding\n },\n paddingBlock: {\n style: padding\n },\n paddingBlockStart: {\n style: padding\n },\n paddingBlockEnd: {\n style: padding\n },\n m: {\n style: margin\n },\n mt: {\n style: margin\n },\n mr: {\n style: margin\n },\n mb: {\n style: margin\n },\n ml: {\n style: margin\n },\n mx: {\n style: margin\n },\n my: {\n style: margin\n },\n margin: {\n style: margin\n },\n marginTop: {\n style: margin\n },\n marginRight: {\n style: margin\n },\n marginBottom: {\n style: margin\n },\n marginLeft: {\n style: margin\n },\n marginX: {\n style: margin\n },\n marginY: {\n style: margin\n },\n marginInline: {\n style: margin\n },\n marginInlineStart: {\n style: margin\n },\n marginInlineEnd: {\n style: margin\n },\n marginBlock: {\n style: margin\n },\n marginBlockStart: {\n style: margin\n },\n marginBlockEnd: {\n style: margin\n },\n // display\n displayPrint: {\n cssProperty: false,\n transform: value => ({\n '@media print': {\n display: value\n }\n })\n },\n display: {},\n overflow: {},\n textOverflow: {},\n visibility: {},\n whiteSpace: {},\n // flexbox\n flexBasis: {},\n flexDirection: {},\n flexWrap: {},\n justifyContent: {},\n alignItems: {},\n alignContent: {},\n order: {},\n flex: {},\n flexGrow: {},\n flexShrink: {},\n alignSelf: {},\n justifyItems: {},\n justifySelf: {},\n // grid\n gap: {\n style: gap\n },\n rowGap: {\n style: rowGap\n },\n columnGap: {\n style: columnGap\n },\n gridColumn: {},\n gridRow: {},\n gridAutoFlow: {},\n gridAutoColumns: {},\n gridAutoRows: {},\n gridTemplateColumns: {},\n gridTemplateRows: {},\n gridTemplateAreas: {},\n gridArea: {},\n // positions\n position: {},\n zIndex: {\n themeKey: 'zIndex'\n },\n top: {},\n right: {},\n bottom: {},\n left: {},\n // shadows\n boxShadow: {\n themeKey: 'shadows'\n },\n // sizing\n width: {\n transform: sizingTransform\n },\n maxWidth: {\n style: maxWidth\n },\n minWidth: {\n transform: sizingTransform\n },\n height: {\n transform: sizingTransform\n },\n maxHeight: {\n transform: sizingTransform\n },\n minHeight: {\n transform: sizingTransform\n },\n boxSizing: {},\n // typography\n font: {\n themeKey: 'font'\n },\n fontFamily: {\n themeKey: 'typography'\n },\n fontSize: {\n themeKey: 'typography'\n },\n fontStyle: {\n themeKey: 'typography'\n },\n fontWeight: {\n themeKey: 'typography'\n },\n letterSpacing: {},\n textTransform: {},\n lineHeight: {},\n textAlign: {},\n typography: {\n cssProperty: false,\n themeKey: 'typography'\n }\n};\nexport default defaultSxConfig;","import capitalize from '@mui/utils/capitalize';\nimport merge from \"../merge/index.js\";\nimport { getPath, getStyleValue as getValue } from \"../style/index.js\";\nimport { handleBreakpoints, createEmptyBreakpointObject, removeUnusedBreakpoints } from \"../breakpoints/index.js\";\nimport { sortContainerQueries } from \"../cssContainerQueries/index.js\";\nimport defaultSxConfig from \"./defaultSxConfig.js\";\nfunction objectsHaveSameKeys(...objects) {\n const allKeys = objects.reduce((keys, object) => keys.concat(Object.keys(object)), []);\n const union = new Set(allKeys);\n return objects.every(object => union.size === Object.keys(object).length);\n}\nfunction callIfFn(maybeFn, arg) {\n return typeof maybeFn === 'function' ? maybeFn(arg) : maybeFn;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function unstable_createStyleFunctionSx() {\n function getThemeValue(prop, val, theme, config) {\n const props = {\n [prop]: val,\n theme\n };\n const options = config[prop];\n if (!options) {\n return {\n [prop]: val\n };\n }\n const {\n cssProperty = prop,\n themeKey,\n transform,\n style\n } = options;\n if (val == null) {\n return null;\n }\n\n // TODO v6: remove, see https://github.com/mui/material-ui/pull/38123\n if (themeKey === 'typography' && val === 'inherit') {\n return {\n [prop]: val\n };\n }\n const themeMapping = getPath(theme, themeKey) || {};\n if (style) {\n return style(props);\n }\n const styleFromPropValue = propValueFinal => {\n let value = getValue(themeMapping, transform, propValueFinal);\n if (propValueFinal === value && typeof propValueFinal === 'string') {\n // Haven't found value\n value = getValue(themeMapping, transform, `${prop}${propValueFinal === 'default' ? '' : capitalize(propValueFinal)}`, propValueFinal);\n }\n if (cssProperty === false) {\n return value;\n }\n return {\n [cssProperty]: value\n };\n };\n return handleBreakpoints(props, val, styleFromPropValue);\n }\n function styleFunctionSx(props) {\n const {\n sx,\n theme = {},\n nested\n } = props || {};\n if (!sx) {\n return null; // Emotion & styled-components will neglect null\n }\n const config = theme.unstable_sxConfig ?? defaultSxConfig;\n\n /*\n * Receive `sxInput` as object or callback\n * and then recursively check keys & values to create media query object styles.\n * (the result will be used in `styled`)\n */\n function traverse(sxInput) {\n let sxObject = sxInput;\n if (typeof sxInput === 'function') {\n sxObject = sxInput(theme);\n } else if (typeof sxInput !== 'object') {\n // value\n return sxInput;\n }\n if (!sxObject) {\n return null;\n }\n const emptyBreakpoints = createEmptyBreakpointObject(theme.breakpoints);\n const breakpointsKeys = Object.keys(emptyBreakpoints);\n let css = emptyBreakpoints;\n Object.keys(sxObject).forEach(styleKey => {\n const value = callIfFn(sxObject[styleKey], theme);\n if (value !== null && value !== undefined) {\n if (typeof value === 'object') {\n if (config[styleKey]) {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n } else {\n const breakpointsValues = handleBreakpoints({\n theme\n }, value, x => ({\n [styleKey]: x\n }));\n if (objectsHaveSameKeys(breakpointsValues, value)) {\n css[styleKey] = styleFunctionSx({\n sx: value,\n theme,\n nested: true\n });\n } else {\n css = merge(css, breakpointsValues);\n }\n }\n } else {\n css = merge(css, getThemeValue(styleKey, value, theme, config));\n }\n }\n });\n if (!nested && theme.modularCssLayers) {\n return {\n '@layer sx': sortContainerQueries(theme, removeUnusedBreakpoints(breakpointsKeys, css))\n };\n }\n return sortContainerQueries(theme, removeUnusedBreakpoints(breakpointsKeys, css));\n }\n return Array.isArray(sx) ? sx.map(traverse) : traverse(sx);\n }\n return styleFunctionSx;\n}\nconst styleFunctionSx = unstable_createStyleFunctionSx();\nstyleFunctionSx.filterProps = ['sx'];\nexport default styleFunctionSx;","/**\n * A universal utility to style components with multiple color modes. Always use it from the theme object.\n * It works with:\n * - [Basic theme](https://mui.com/material-ui/customization/dark-mode/)\n * - [CSS theme variables](https://mui.com/material-ui/customization/css-theme-variables/overview/)\n * - Zero-runtime engine\n *\n * Tips: Use an array over object spread and place `theme.applyStyles()` last.\n *\n * With the styled function:\n * ✅ [{ background: '#e5e5e5' }, theme.applyStyles('dark', { background: '#1c1c1c' })]\n * 🚫 { background: '#e5e5e5', ...theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * With the sx prop:\n * ✅ [{ background: '#e5e5e5' }, theme => theme.applyStyles('dark', { background: '#1c1c1c' })]\n * 🚫 { background: '#e5e5e5', ...theme => theme.applyStyles('dark', { background: '#1c1c1c' })}\n *\n * @example\n * 1. using with `styled`:\n * ```jsx\n * const Component = styled('div')(({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]);\n * ```\n *\n * @example\n * 2. using with `sx` prop:\n * ```jsx\n * <Box sx={[\n * { background: '#e5e5e5' },\n * theme => theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ]}\n * />\n * ```\n *\n * @example\n * 3. theming a component:\n * ```jsx\n * extendTheme({\n * components: {\n * MuiButton: {\n * styleOverrides: {\n * root: ({ theme }) => [\n * { background: '#e5e5e5' },\n * theme.applyStyles('dark', {\n * background: '#1c1c1c',\n * color: '#fff',\n * }),\n * ],\n * },\n * }\n * }\n * })\n *```\n */\nexport default function applyStyles(key, styles) {\n // @ts-expect-error this is 'any' type\n const theme = this;\n if (theme.vars) {\n if (!theme.colorSchemes?.[key] || typeof theme.getColorSchemeSelector !== 'function') {\n return {};\n }\n // If CssVarsProvider is used as a provider, returns '*:where({selector}) &'\n let selector = theme.getColorSchemeSelector(key);\n if (selector === '&') {\n return styles;\n }\n if (selector.includes('data-') || selector.includes('.')) {\n // '*' is required as a workaround for Emotion issue (https://github.com/emotion-js/emotion/issues/2836)\n selector = `*:where(${selector.replace(/\\s*&$/, '')}) &`;\n }\n return {\n [selector]: styles\n };\n }\n if (theme.palette.mode === key) {\n return styles;\n }\n return {};\n}","'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;","'use client';\n\nimport createTheme from \"../createTheme/index.js\";\nimport useThemeWithoutDefault from \"../useThemeWithoutDefault/index.js\";\nexport const systemDefaultTheme = createTheme();\nfunction useTheme(defaultTheme = systemDefaultTheme) {\n return useThemeWithoutDefault(defaultTheme);\n}\nexport default useTheme;","import deepmerge from '@mui/utils/deepmerge';\nimport createBreakpoints from \"../createBreakpoints/createBreakpoints.js\";\nimport cssContainerQueries from \"../cssContainerQueries/index.js\";\nimport shape from \"./shape.js\";\nimport createSpacing from \"./createSpacing.js\";\nimport styleFunctionSx from \"../styleFunctionSx/styleFunctionSx.js\";\nimport defaultSxConfig from \"../styleFunctionSx/defaultSxConfig.js\";\nimport applyStyles from \"./applyStyles.js\";\nfunction createTheme(options = {}, ...args) {\n const {\n breakpoints: breakpointsInput = {},\n palette: paletteInput = {},\n spacing: spacingInput,\n shape: shapeInput = {},\n ...other\n } = options;\n const breakpoints = createBreakpoints(breakpointsInput);\n const spacing = createSpacing(spacingInput);\n let muiTheme = deepmerge({\n breakpoints,\n direction: 'ltr',\n components: {},\n // Inject component definitions.\n palette: {\n mode: 'light',\n ...paletteInput\n },\n spacing,\n shape: {\n ...shape,\n ...shapeInput\n }\n }, other);\n muiTheme = cssContainerQueries(muiTheme);\n muiTheme.applyStyles = applyStyles;\n muiTheme = args.reduce((acc, argument) => deepmerge(acc, argument), muiTheme);\n muiTheme.unstable_sxConfig = {\n ...defaultSxConfig,\n ...other?.unstable_sxConfig\n };\n muiTheme.unstable_sx = function sx(props) {\n return styleFunctionSx({\n sx: props,\n theme: this\n });\n };\n return muiTheme;\n}\nexport default createTheme;","import { createUnarySpacing } from \"../spacing/index.js\";\n\n// The different signatures imply different meaning for their arguments that can't be expressed structurally.\n// We express the difference with variable names.\n\nexport default function createSpacing(spacingInput = 8,\n// Material Design layouts are visually balanced. Most measurements align to an 8dp grid, which aligns both spacing and the overall layout.\n// Smaller components, such as icons, can align to a 4dp grid.\n// https://m2.material.io/design/layout/understanding-layout.html\ntransform = createUnarySpacing({\n spacing: spacingInput\n})) {\n // Already transformed.\n if (spacingInput.mui) {\n return spacingInput;\n }\n const spacing = (...argsInput) => {\n if (process.env.NODE_ENV !== 'production') {\n if (!(argsInput.length <= 4)) {\n console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${argsInput.length}`);\n }\n }\n const args = argsInput.length === 0 ? [1] : argsInput;\n return args.map(argument => {\n const output = transform(argument);\n return typeof output === 'number' ? `${output}px` : output;\n }).join(' ');\n };\n spacing.mui = true;\n return spacing;\n}","import { isPlainObject } from '@mui/utils/deepmerge';\nimport defaultSxConfig from \"./defaultSxConfig.js\";\nconst splitProps = props => {\n const result = {\n systemProps: {},\n otherProps: {}\n };\n const config = props?.theme?.unstable_sxConfig ?? defaultSxConfig;\n Object.keys(props).forEach(prop => {\n if (config[prop]) {\n result.systemProps[prop] = props[prop];\n } else {\n result.otherProps[prop] = props[prop];\n }\n });\n return result;\n};\nexport default function extendSxProp(props) {\n const {\n sx: inSx,\n ...other\n } = props;\n const {\n systemProps,\n otherProps\n } = splitProps(other);\n let finalSx;\n if (Array.isArray(inSx)) {\n finalSx = [systemProps, ...inSx];\n } else if (typeof inSx === 'function') {\n finalSx = (...args) => {\n const result = inSx(...args);\n if (!isPlainObject(result)) {\n return systemProps;\n }\n return {\n ...systemProps,\n ...result\n };\n };\n } else {\n finalSx = {\n ...systemProps,\n ...inSx\n };\n }\n return {\n ...otherProps,\n sx: finalSx\n };\n}","const defaultGenerator = componentName => componentName;\nconst createClassNameGenerator = () => {\n let generate = defaultGenerator;\n return {\n configure(generator) {\n generate = generator;\n },\n generate(componentName) {\n return generate(componentName);\n },\n reset() {\n generate = defaultGenerator;\n }\n };\n};\nconst ClassNameGenerator = createClassNameGenerator();\nexport default ClassNameGenerator;","function r(e){var t,f,n=\"\";if(\"string\"==typeof e||\"number\"==typeof e)n+=e;else if(\"object\"==typeof e)if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(f=r(e[t]))&&(n&&(n+=\" \"),n+=f)}else for(f in e)e[f]&&(n&&(n+=\" \"),n+=f);return n}export function clsx(){for(var e,t,f=0,n=\"\",o=arguments.length;f<o;f++)(e=arguments[f])&&(t=r(e))&&(n&&(n+=\" \"),n+=t);return n}export default clsx;","import ClassNameGenerator from \"../ClassNameGenerator/index.js\";\nexport const globalStateClasses = {\n active: 'active',\n checked: 'checked',\n completed: 'completed',\n disabled: 'disabled',\n error: 'error',\n expanded: 'expanded',\n focused: 'focused',\n focusVisible: 'focusVisible',\n open: 'open',\n readOnly: 'readOnly',\n required: 'required',\n selected: 'selected'\n};\nexport default function generateUtilityClass(componentName, slot, globalStatePrefix = 'Mui') {\n const globalStateClass = globalStateClasses[slot];\n return globalStateClass ? `${globalStatePrefix}-${globalStateClass}` : `${ClassNameGenerator.generate(componentName)}-${slot}`;\n}\nexport function isGlobalState(slot) {\n return globalStateClasses[slot] !== undefined;\n}","import generateUtilityClasses from '@mui/utils/generateUtilityClasses';\nconst boxClasses = generateUtilityClasses('MuiBox', ['root']);\nexport default boxClasses;","'use client';\n\nimport PropTypes from 'prop-types';\nimport ClassNameGenerator from '@mui/utils/ClassNameGenerator';\nimport createBox from \"../createBox/index.js\";\nimport boxClasses from \"./boxClasses.js\";\nconst Box = createBox({\n defaultClassName: boxClasses.root,\n generateClassName: ClassNameGenerator.generate\n});\nprocess.env.NODE_ENV !== \"production\" ? Box.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * @ignore\n */\n children: PropTypes.node,\n /**\n * The component used for the root node.\n * Either a string to use a HTML element or a component.\n */\n component: PropTypes.elementType,\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object])\n} : void 0;\nexport default Box;","'use client';\n\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport styled from '@mui/styled-engine';\nimport styleFunctionSx, { extendSxProp } from \"../styleFunctionSx/index.js\";\nimport useTheme from \"../useTheme/index.js\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport default function createBox(options = {}) {\n const {\n themeId,\n defaultTheme,\n defaultClassName = 'MuiBox-root',\n generateClassName\n } = options;\n const BoxRoot = styled('div', {\n shouldForwardProp: prop => prop !== 'theme' && prop !== 'sx' && prop !== 'as'\n })(styleFunctionSx);\n const Box = /*#__PURE__*/React.forwardRef(function Box(inProps, ref) {\n const theme = useTheme(defaultTheme);\n const {\n className,\n component = 'div',\n ...other\n } = extendSxProp(inProps);\n return /*#__PURE__*/_jsx(BoxRoot, {\n as: component,\n ref: ref,\n className: clsx(className, generateClassName ? generateClassName(defaultClassName) : defaultClassName),\n theme: themeId ? theme[themeId] || theme : theme,\n ...other\n });\n });\n return Box;\n}","/**\n * @mui/styled-engine v7.3.1\n *\n * @license MIT\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use client';\n\n/* eslint-disable no-underscore-dangle */\nimport emStyled from '@emotion/styled';\nimport { serializeStyles as emSerializeStyles } from '@emotion/serialize';\nexport default function styled(tag, options) {\n const stylesFactory = emStyled(tag, options);\n if (process.env.NODE_ENV !== 'production') {\n return (...styles) => {\n const component = typeof tag === 'string' ? `\"${tag}\"` : 'component';\n if (styles.length === 0) {\n console.error([`MUI: Seems like you called \\`styled(${component})()\\` without a \\`style\\` argument.`, 'You must provide a `styles` argument: `styled(\"div\")(styleYouForgotToPass)`.'].join('\\n'));\n } else if (styles.some(style => style === undefined)) {\n console.error(`MUI: the styled(${component})(...args) API requires all its args to be defined.`);\n }\n return stylesFactory(...styles);\n };\n }\n return stylesFactory;\n}\n\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function internal_mutateStyles(tag, processor) {\n // Emotion attaches all the styles as `__emotion_styles`.\n // Ref: https://github.com/emotion-js/emotion/blob/16d971d0da229596d6bcc39d282ba9753c9ee7cf/packages/styled/src/base.js#L186\n if (Array.isArray(tag.__emotion_styles)) {\n tag.__emotion_styles = processor(tag.__emotion_styles);\n }\n}\n\n// Emotion only accepts an array, but we want to avoid allocations\nconst wrapper = [];\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport function internal_serializeStyles(styles) {\n wrapper[0] = styles;\n return emSerializeStyles(wrapper);\n}\nexport { ThemeContext, keyframes, css } from '@emotion/react';\nexport { default as StyledEngineProvider } from \"./StyledEngineProvider/index.js\";\nexport { default as GlobalStyles } from \"./GlobalStyles/index.js\";","import generateUtilityClass from \"../generateUtilityClass/index.js\";\nexport default function generateUtilityClasses(componentName, slots, globalStatePrefix = 'Mui') {\n const result = {};\n slots.forEach(slot => {\n result[slot] = generateUtilityClass(componentName, slot, globalStatePrefix);\n });\n return result;\n}","import moment from \"moment\";\nimport { FormElementProps } from \"../components\";\nimport { DATE_FORMAT } from \"./constants\";\n\nexport function hasDigitsOnly(str: string) {\n return /^\\d+$/.test(str);\n}\n\nexport function isNumber(value: any) {\n return typeof value === \"number\" && !isNaN(value);\n}\n\nexport function isNumeric(value: string) {\n return (\n typeof value === \"string\" && value.trim() !== \"\" && !isNaN(Number(value))\n );\n}\n\nexport function capitalizeFirstLetter(str: string) {\n if (!str) return \"\";\n return str.charAt(0).toUpperCase() + str.slice(1);\n}\n\nexport function isValidEmail(email) {\n const re = /^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$/;\n return re.test(email);\n}\n\nexport function timeAgo(dateInput, appDirection: \"ltr\" | \"rtl\") {\n const date = new Date(dateInput);\n const now = new Date();\n const diffInSeconds = Math.floor((date - now) / 1000); // Note: future is positive\n const absDiff = Math.abs(diffInSeconds);\n\n const locale = appDirection === \"rtl\" ? \"ar\" : \"en\";\n\n const rtf = new Intl.RelativeTimeFormat(locale, { numeric: \"auto\" });\n\n const units = [\n { unit: \"year\", seconds: 31536000 },\n { unit: \"month\", seconds: 2592000 },\n { unit: \"week\", seconds: 604800 },\n { unit: \"day\", seconds: 86400 },\n { unit: \"hour\", seconds: 3600 },\n { unit: \"minute\", seconds: 60 },\n { unit: \"second\", seconds: 1 },\n ];\n\n for (const { unit, seconds } of units) {\n const delta = Math.floor(diffInSeconds / seconds);\n if (Math.abs(delta) > 1) {\n return rtf.format(delta, unit);\n }\n }\n\n return locale === \"ar\" ? \"الآن\" : \"just now\";\n}\n\nexport const formatDate = (date, format) => {\n if (format) {\n return moment(date).format(format);\n } else {\n return moment(date).format(DATE_FORMAT);\n }\n};\n\nexport const parseStringToDate = (dateString, format) => {\n if (format) {\n return moment(dateString, format).toDate();\n } else {\n return moment(dateString, DATE_FORMAT).toDate();\n }\n};\n","import { Grid2 } from \"@mui/material\";\nimport TemplateTextField from \"./FormFields/TemplateTextField\";\nimport Datefield from \"./FormFields/Datefield\";\nimport DatetimeField from \"./FormFields/DatetimeField\";\nimport ComboBox from \"./FormFields/ComboBox\";\nimport CheckBox from \"./FormFields/CheckBox\";\nimport { DATE_FORMAT, DATE_TIME_FORMAT } from \"../../../../util/constants\";\nimport { isNumeric } from \"../../../../util/AppUtils\";\nimport { FormElementFieldProps } from \"../DataEntryTypes\";\nimport SystemLookupCombobox from \"./FormFields/SystemLookupCombobox\";\n\nconst FormElementField: React.FC<FormElementFieldProps> = (\n element: FormElementFieldProps\n) => {\n if (element?.fieldInfo) {\n const props = element.fieldInfo;\n const formManager = element?.formManager || null;\n const formActions = element?.formActions || null;\n const formValues = element?.formValues || null;\n const fieldName: any = element?.fieldInfo?.fieldName || null;\n const fieldType = element?.fieldInfo?.fieldType || null;\n if (!(props && formManager && formValues && fieldName && fieldType)) {\n return <></>;\n }\n\n const getFieldLabel = () => {\n if (element?.fieldInfo?.formProps?.fieldLabelFn) {\n return element.fieldInfo.formProps.fieldLabelFn(formValues);\n } else if (element?.fieldInfo?.fieldLabel) {\n return element?.fieldInfo?.fieldLabel;\n }\n };\n return !element.hiddenFields.includes(fieldName) ? (\n <Grid2\n size={\n props?.formProps?.fieldSize || {\n lg: 12,\n md: 12,\n sm: 12,\n }\n }\n sx={{\n padding: 1,\n width: \"100%\",\n }}\n >\n {fieldType === \"text\" || fieldType === \"number\" ? (\n <TemplateTextField\n {...props.muiTextFieldProps}\n fullWidth\n type={fieldType}\n disabled={\n props?.disabled || element.disabledFields.includes(fieldName)\n ? true\n : false\n }\n // hidden={\n // props?.hidden || element.hiddenFields.includes(fieldName)\n // ? true\n // : false\n // }\n label={getFieldLabel()}\n value={formValues[fieldName]}\n onChange={(event) => {\n let newValue = null;\n if (event.target.value != \"\") {\n if (fieldType === \"number\" && isNumeric(event.target.value)) {\n newValue = Number(event.target.value);\n } else {\n newValue = event.target.value;\n }\n }\n formManager.setValue(fieldName, newValue);\n if (element?.formValuesChangeCallBk) {\n element?.formValuesChangeCallBk(\n formValues,\n formActions,\n formManager,\n fieldName,\n newValue\n );\n }\n }}\n sx={{\n \"& .MuiInputBase-root\": {\n height: `${props?.formProps?.fieldHeight}px` || undefined,\n },\n \"& .MuiInputBase-input\": {\n height: \"100% !important\", // forces full height usage\n },\n ...props?.formProps?.style,\n }}\n error={formManager.formState.errors[fieldName] != undefined}\n helperText={formManager?.formState?.errors[\n fieldName\n ]?.message?.toString()}\n />\n ) : props?.fieldType === \"date\" ? (\n <Datefield\n format={props?.dateFormat || DATE_FORMAT}\n sx={props?.formProps?.style || { width: \"100%\" }}\n disabled={\n props?.disabled || element.disabledFields.includes(fieldName)\n ? true\n : false\n }\n // hidden={\n // props?.hidden || element.hiddenFields.includes(fieldName)\n // ? true\n // : false\n // }\n label={getFieldLabel()}\n onChangeCallBack={(v: any) => {\n formManager.setValue(fieldName, v);\n if (element?.formValuesChangeCallBk) {\n element?.formValuesChangeCallBk(\n formValues,\n formActions,\n formManager,\n fieldName,\n v\n );\n }\n }}\n value={formValues[fieldName]}\n error={formManager.formState.errors[fieldName] != undefined}\n errorMessage={formManager?.formState?.errors[\n fieldName\n ]?.message?.toString()}\n />\n ) : props?.fieldType === \"datetime\" ? (\n <DatetimeField\n format={props?.dateFormat || DATE_TIME_FORMAT}\n sx={props?.formProps?.style || { width: \"100%\" }}\n disabled={\n props?.disabled || element.disabledFields.includes(fieldName)\n ? true\n : false\n }\n label={getFieldLabel()}\n onChangeCallBack={(v: any) => {\n formManager.setValue(fieldName, v);\n if (element?.formValuesChangeCallBk) {\n element?.formValuesChangeCallBk(\n formValues,\n formActions,\n formManager,\n fieldName,\n v\n );\n }\n }}\n // hidden={\n // props?.hidden || element.hiddenFields.includes(fieldName)\n // ? true\n // : false\n // }\n value={formValues[fieldName]}\n error={formManager.formState.errors[fieldName] != undefined}\n errorMessage={formManager?.formState?.errors[\n fieldName\n ]?.message?.toString()}\n />\n ) : props?.fieldType === \"checkbox\" ? (\n <CheckBox\n label={getFieldLabel()}\n onChangeCallBack={(v: any) => {\n formManager.setValue(fieldName, v);\n if (element?.formValuesChangeCallBk) {\n element?.formValuesChangeCallBk(\n formValues,\n formActions,\n formManager,\n fieldName,\n v\n );\n }\n }}\n // hidden={\n // props?.hidden || element.hiddenFields.includes(fieldName)\n // ? true\n // : false\n // }\n value={formValues[fieldName]}\n checkedValue={props?.checkedValue || true}\n unCheckedValue={props?.unCheckedValue || false}\n disabled={\n props?.disabled || element.disabledFields.includes(fieldName)\n ? true\n : false\n }\n sx={props?.formProps?.style}\n />\n ) : props?.fieldType === \"combobox\" ? (\n <ComboBox\n sx={props?.formProps?.style || { width: \"100%\" }}\n label={getFieldLabel()}\n disabled={\n props?.disabled || element.disabledFields.includes(fieldName)\n ? true\n : false\n }\n // hidden={\n // props?.hidden || element.hiddenFields.includes(fieldName)\n // ? true\n // : false\n // }\n onChangeCallBack={(v: any, selectedRecord: any) => {\n let newValue = null;\n if (v) {\n newValue = v;\n }\n formManager.setValue(fieldName, newValue);\n if (element?.formValuesChangeCallBk) {\n element?.formValuesChangeCallBk(\n formValues,\n formActions,\n formManager,\n fieldName,\n v,\n selectedRecord\n );\n }\n }}\n options={props?.options || []}\n displayField={props?.optionDisplayField || \"\"}\n valueField={props?.optionValueField || \"\"}\n value={formValues[fieldName]}\n errorMessage={formManager?.formState?.errors[\n fieldName\n ]?.message?.toString()}\n />\n ) : props?.fieldType === \"lookup\" ? (\n <SystemLookupCombobox\n sx={props?.formProps?.style || { width: \"100%\" }}\n label={getFieldLabel()}\n disabled={\n props?.disabled || element.disabledFields.includes(fieldName)\n ? true\n : false\n }\n // hidden={\n // props?.hidden || element.hiddenFields.includes(fieldName)\n // ? true\n // : false\n // }\n onChangeCallBack={(v: any, selectedRecord: any) => {\n let newValue = null;\n if (v) {\n newValue = v;\n }\n formManager.setValue(fieldName, newValue);\n if (element?.formValuesChangeCallBk) {\n element?.formValuesChangeCallBk(\n formValues,\n formActions,\n formManager,\n fieldName,\n v,\n selectedRecord\n );\n }\n }}\n lookupType={props.lookupType}\n value={formValues[fieldName]}\n errorMessage={formManager?.formState?.errors[\n fieldName\n ]?.message?.toString()}\n />\n ) : null}\n </Grid2>\n ) : (\n <></>\n );\n } else {\n return <></>;\n }\n};\n\nexport default FormElementField;\n","import { Button } from \"@mui/material\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { RecordAction } from \"../DataEntryTypes\";\nimport useSession from \"../../../../hooks/UseSession\";\nimport { useConfirmationWindow } from \"../../../../hooks/UseConfirmationWindow\";\n\nconst FormAction: React.FC<RecordAction> = (action: RecordAction) => {\n const session = useSession();\n const { ConfirmationWindow, setOpen: setConfirmationWindowState } =\n useConfirmationWindow({\n body: action?.confirmationMessage || \"\",\n title: \"Confirmation\",\n onConfirmationCallBk: () => {\n action?.actionFn(action?.record);\n },\n });\n if (\n action?.authority === undefined ||\n action?.authority === null ||\n session.isUserAuthorized(action.authority)\n ) {\n return (\n <>\n <ConfirmationWindow />\n <Button\n variant={action?.formActionProps?.actionButtonVariant}\n color={action?.formActionProps?.actionButtonColor}\n onClick={() => {\n if (action?.actionFn) {\n if (action?.preActionValidation) {\n if (!action.preActionValidation(action.record)) {\n return;\n }\n }\n if (action?.isConfirmationRequired === true) {\n setConfirmationWindowState(true);\n } else {\n action?.actionFn(action.record);\n }\n }\n }}\n >\n {action?.icon ? (\n <FontAwesomeIcon\n icon={action.icon}\n style={{ marginRight: 5, marginLeft: 5 }}\n />\n ) : (\n <></>\n )}\n <div>{action?.label}</div>\n </Button>\n </>\n );\n } else {\n return <></>;\n }\n};\n\nexport default FormAction;\n","import { Grid2 } from \"@mui/material\";\nimport FormElementField from \"./FormElementField\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport FormAction from \"./FormAction\";\nimport {\n FormElementGroupProps,\n FormElementProps,\n RecordAction,\n} from \"../DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\n\nconst FormElementGroup: React.FC<FormElementGroupProps> = (\n props: FormElementGroupProps\n) => {\n const { t } = useTranslation();\n return (\n <>\n <Grid2 container sx={props?.style} alignItems=\"flex-start\">\n {props?.label ? (\n <Grid2\n size={12}\n sx={{\n padding: 1,\n fontWeight: \"bold\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n }}\n >\n {props?.icon ? (\n <>\n <FontAwesomeIcon\n icon={props.icon}\n style={{ marginRight: 5, marginLeft: 5 }}\n />\n <div>{t(props.label)}</div>\n </>\n ) : (\n <>{t(props.label)}</>\n )}\n </Grid2>\n ) : (\n <></>\n )}\n {props?.elements\n ? props.elements.map((element: FormElementProps) => {\n if (element.type === \"group\") {\n return (\n <FormElementGroup\n {...element.props}\n formManager={props.formManager}\n formValues={props.formValues}\n formActions={props.formActions}\n hiddenFields={props.hiddenFields}\n disabledFields={props.disabledFields}\n />\n );\n } else if (element.type === \"field\" && element.mode === \"props\") {\n return (\n <FormElementField\n fieldInfo={element.props}\n formManager={props.formManager}\n formValues={props.formValues}\n formActions={props.formActions}\n hiddenFields={props.hiddenFields}\n disabledFields={props.disabledFields}\n />\n );\n } else if (element.type === \"field\" && element.mode === \"node\") {\n return (\n <Grid2\n size={\n element?.props?.formProps?.fieldSize || {\n lg: 3,\n md: 6,\n sm: 12,\n }\n }\n sx={{ padding: 1, width: \"100%\" }}\n >\n <element.node\n formManager={props.formManager}\n formValues={props.formValues}\n formActions={props.formActions}\n />\n </Grid2>\n );\n }\n })\n : null}\n\n {props?.actions ? (\n <Grid2 size={{ sm: 12 }} sx={{ padding: 1 }}>\n {props.actions.map((action: RecordAction) => {\n return <FormAction {...action} record={props.formValues} />;\n })}\n </Grid2>\n ) : (\n <></>\n )}\n </Grid2>\n </>\n );\n};\n\nexport default FormElementGroup;\n","import { useEffect, useState } from \"react\";\nimport { useSelector } from \"react-redux\";\nimport { Avatar, SxProps } from \"@mui/material\";\n\ntype AttachmentImageViewerProps = {\n attachmentId?: number;\n attachmentCode?: string;\n refKey?: string;\n category?: string;\n showAsAvatar?: boolean;\n onErrorImage?: string;\n style?: SxProps;\n};\n\nconst AttachmentImageViewer: React.FC<AttachmentImageViewerProps> = (props) => {\n const apiBaseUrl = useSelector(\n (state: any) => state.AppInfo.value.apiBaseUrl\n );\n const [imgSrc, setImgSrc] = useState(null);\n const handleImageSrc = () => {\n let imagePath = apiBaseUrl + \"/api/v1/attachment/\";\n if (props?.attachmentId) {\n imagePath += \"download?attachmentId=\" + props.attachmentId;\n } else {\n imagePath += `downloadImage?attachmentCode=${props.attachmentCode}&refKey=${props.refKey}`;\n if (props?.category) {\n imagePath += `&category=${props.category}`;\n }\n }\n setImgSrc(imagePath);\n };\n useEffect(() => {\n handleImageSrc();\n }, [props]);\n {\n /* </Avatar>\n src={imgSrc}\n loading={}\n sx={props.style}\n onError={() => {\n if (props?.onErrorImage) {\n setImgSrc(props.onErrorImage);\n } else {\n setImgSrc(\"/no_image.png\");\n }\n }}\n /> */\n }\n return props?.showAsAvatar ? (\n <Avatar\n sx={props.style}\n onError={() => {\n if (props?.onErrorImage) {\n setImgSrc(props.onErrorImage);\n } else {\n setImgSrc(\"/no_image.png\");\n }\n }}\n src={imgSrc}\n />\n ) : (\n <img\n src={imgSrc}\n loading=\"lazy\"\n alt=\"image\"\n onError={() => {\n if (props?.onErrorImage) {\n setImgSrc(props.onErrorImage);\n } else {\n setImgSrc(\"/no_image.png\");\n }\n }}\n style={{\n width: \"100%\",\n height: \"100%\",\n objectFit: \"cover\",\n display: \"block\",\n }}\n />\n );\n};\n\nexport default AttachmentImageViewer;\n","import Card from \"@mui/material/Card\";\nimport CardActions from \"@mui/material/CardActions\";\nimport CardContent from \"@mui/material/CardContent\";\nimport CardMedia from \"@mui/material/CardMedia\";\nimport Button from \"@mui/material/Button\";\nimport Typography from \"@mui/material/Typography\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { IconButton, Tooltip } from \"@mui/material\";\nimport { useAxios, useConfirmationWindow, useSession } from \"../../../hooks\";\nimport AttachmentImageViewer from \"./AttachmentImageViewer\";\n\nexport type attachment = {\n attachmentCode: string;\n setAttachmentConfig: (props: any) => void;\n id: number;\n attachmentConfigId: number;\n attachmentSize: number;\n category: string;\n docType: string;\n fileName: string;\n refKey: string;\n allowDelete?: boolean;\n downloadAuthorityKey?: string;\n remark: string;\n};\n\nconst AttachmentCard: React.FC<attachment> = (props) => {\n const { handleGetRequest, handleDeleteRequest } = useAxios();\n const { isUserAuthorized } = useSession();\n let allowDownload = true;\n if (props?.downloadAuthorityKey) {\n allowDownload = isUserAuthorized(props.downloadAuthorityKey);\n }\n const handleDelete = async () => {\n await handleDeleteRequest({\n endPointURI: \"api/v1/attachment/archive\",\n parameters: {\n attachmentCode: props.attachmentCode,\n refKey: props.refKey,\n attachmentId: props.id,\n },\n successCallBkFn: (response) => {\n props.setAttachmentConfig(response.data);\n },\n showMask: true,\n });\n };\n const { ConfirmationWindow, setOpen } = useConfirmationWindow({\n title: \"Confirmation\",\n body: \"Are you sure you want to delete this attachment?\",\n onConfirmationCallBk: () => {\n handleDelete();\n },\n });\n\n const handleDownload = async () => {\n await handleGetRequest({\n endPointURI: \"api/v1/attachment/download\",\n parameters: {\n attachmentId: props.id,\n },\n showMask: true,\n responseType: \"blob\",\n successCallBkFn: (response) => {\n const url = window.URL.createObjectURL(new Blob([response.data]));\n const link = document.createElement(\"a\");\n link.href = url;\n link.setAttribute(\"download\", props.fileName);\n document.body.appendChild(link);\n link.click();\n link.remove();\n },\n });\n };\n\n return (\n <>\n <ConfirmationWindow />\n <Card sx={{ width: 300, border: \"0.5px solid gray\" }}>\n <CardMedia\n sx={{\n height: 140,\n width: 300,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n {props?.docType.toLocaleLowerCase().includes(\"image\") ? (\n <AttachmentImageViewer attachmentId={props.id} />\n ) : (\n <FontAwesomeIcon icon=\"file\" size=\"3x\" />\n )}\n </CardMedia>\n <CardContent>\n <Typography gutterBottom variant=\"h6\" component=\"div\">\n {props.fileName}\n </Typography>\n <Typography variant=\"body2\" sx={{ color: \"text.secondary\" }}>\n {`File Size: ${props?.attachmentSize || \"unknown\"} kb`}\n </Typography>\n <Typography variant=\"body2\" sx={{ color: \"text.secondary\" }}>\n {`File Type: ${props?.category || \"NA\"}`}\n </Typography>\n <Typography variant=\"body2\" sx={{ color: \"text.secondary\" }}>\n {props.remark}\n </Typography>\n </CardContent>\n <CardActions>\n {props?.allowDelete ? (\n <IconButton\n size=\"small\"\n onClick={() => {\n setOpen(true);\n }}\n >\n <Tooltip title=\"Delete Attachment\">\n <FontAwesomeIcon icon=\"trash\" />\n </Tooltip>\n </IconButton>\n ) : (\n <></>\n )}\n\n <div style={{ flex: 1 }}></div>\n {allowDownload ? (\n <IconButton size=\"small\" onClick={handleDownload}>\n <Tooltip title=\"Download Attachment\">\n <FontAwesomeIcon icon=\"download\" />\n </Tooltip>\n </IconButton>\n ) : (\n <></>\n )}\n </CardActions>\n </Card>\n </>\n );\n};\n\nexport default AttachmentCard;\n","import { useEffect, useState } from \"react\";\nimport { useAxios, useSession } from \"../../../hooks\";\nimport { toast } from \"react-toastify\";\nimport { Box, Button, Grid2, Paper } from \"@mui/material\";\nimport ComboBox from \"../DataEntryTemplates/TemplateDataForm/FormFields/ComboBox\";\nimport TemplateTextField from \"../DataEntryTemplates/TemplateDataForm/FormFields/TemplateTextField\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport AttachmentCard from \"./AttachmentCard\";\n\nexport type AttachmentPanelProps = {\n attachmentCode: string;\n enableAttachment?: boolean;\n refKey: string;\n};\n\ntype AttachmentConfig = {\n id: number;\n attachmentCode: string;\n uploadDirectory: string;\n storageType: \"FILE_SYSTEM\" | \"SFTP\";\n maxAllowedNumberOfFiles: number;\n isCategoryRequired?: boolean;\n attachmentCategories?: string;\n uploadAuthorityKey?: string;\n downloadAuthorityKey?: string;\n allowedFileTypes?: string;\n refKeyAttachments?: Array<any>;\n};\n\nconst AttachmentPanel: React.FC<AttachmentPanelProps> = (props) => {\n const { handleUploadRequest, handleGetRequest } = useAxios();\n const [files, setFiles] = useState<FileList | null>(null);\n const [attachmentCategories, setAttachmentCategories] = useState<\n Array<string>\n >([]);\n const [remark, setRemark] = useState(null);\n const [selectedCategory, setSelectedCategory] = useState(null);\n const [allowedTypes, setAllowedTypes] = useState<Array<string>>([]);\n const [attachmentConfig, setAttachmentConfig] =\n useState<AttachmentConfig>(null);\n\n const loadAttachmentConfig = async () => {\n await handleGetRequest({\n endPointURI: \"api/v1/attachment/info\",\n showMask: true,\n parameters: {\n attachmentCode: props.attachmentCode,\n refKey: props.refKey,\n },\n successCallBkFn: (response: any) => {\n setAttachmentConfig(response.data);\n },\n });\n };\n\n const handleChange = (e: React.ChangeEvent<HTMLInputElement>) => {\n if (e.target.files) {\n for (const file of e.target.files) {\n const fileExt = getFileExtension(file.name);\n if (allowedTypes.length > 0 && !allowedTypes.includes(fileExt)) {\n toast.error(fileExt + \" is not allowed\");\n return;\n }\n }\n }\n setFiles(e.target.files);\n };\n const { isUserAuthorized } = useSession();\n\n const handleUpload = async () => {\n let existingAttachments = attachmentConfig?.refKeyAttachments.length || 0;\n if (\n attachmentConfig?.maxAllowedNumberOfFiles &&\n files.length + existingAttachments >\n attachmentConfig.maxAllowedNumberOfFiles\n ) {\n toast.error(\n \"Maximum number of attachments is \" +\n attachmentConfig.maxAllowedNumberOfFiles\n );\n return;\n }\n if (\n attachmentConfig?.isCategoryRequired === true &&\n attachmentCategories.length > 0 &&\n (selectedCategory == null ||\n selectedCategory === undefined ||\n selectedCategory === \"\")\n ) {\n toast.error(\"You must selected document type to process your request\");\n return;\n }\n if (!files) {\n toast.error(\"You must add files to upload\");\n return;\n }\n debugger;\n for (const file of files) {\n if (file.type.startsWith(\"image/\")) {\n const MAX_SIZE_KB = 600;\n const maxSizeBytes = MAX_SIZE_KB * 1024;\n if (file.size > maxSizeBytes) {\n toast.error(\n `File ${file.name} is too large. Max allowed is ${MAX_SIZE_KB}KB.`\n );\n return;\n }\n }\n }\n\n await handleUploadRequest({\n endPointURI: \"api/v1/attachment/upload\",\n showMask: true,\n loadingMessage: \"Uploading files ... please wait\",\n parameters: {\n refKey: props.refKey,\n attachmentCode: props.attachmentCode,\n remark,\n category: selectedCategory,\n },\n files,\n successCallBkFn: (response) => {\n setAttachmentConfig(response.data);\n setFiles(null);\n setSelectedCategory(null);\n setRemark(null);\n toast.success(\"Your request has been process successfully\");\n },\n });\n };\n const getFileExtension = (name: string) => {\n return name.split(\".\").pop()?.toLowerCase() || \"\";\n };\n\n useEffect(() => {\n loadAttachmentConfig();\n }, [props.refKey, props.attachmentCode]);\n\n useEffect(() => {\n if (attachmentConfig?.allowedFileTypes) {\n setAllowedTypes(attachmentConfig.allowedFileTypes.split(\",\"));\n } else {\n setAllowedTypes([]);\n }\n if (attachmentConfig?.attachmentCategories) {\n const cats = [];\n for (const category of attachmentConfig.attachmentCategories.split(\",\")) {\n cats.push({ value: category });\n }\n setAttachmentCategories(cats);\n } else {\n setAttachmentCategories([]);\n }\n }, [attachmentConfig]);\n let showAttachments = true;\n if (\n attachmentConfig?.downloadAuthorityKey &&\n !isUserAuthorized(attachmentConfig?.downloadAuthorityKey)\n ) {\n showAttachments = false;\n }\n let allowUpload = true;\n if (props?.enableAttachment === false) {\n allowUpload = false;\n }\n if (\n attachmentConfig?.uploadAuthorityKey &&\n !isUserAuthorized(attachmentConfig.uploadAuthorityKey)\n ) {\n allowUpload = false;\n }\n\n return (\n <Paper\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n width: \"100%\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n overflow: \"hidden\",\n flexGrow: 1,\n }}\n >\n {allowUpload ? (\n <>\n {attachmentConfig?.maxAllowedNumberOfFiles === undefined ||\n attachmentConfig?.maxAllowedNumberOfFiles === null ||\n attachmentConfig?.maxAllowedNumberOfFiles >\n attachmentConfig.refKeyAttachments.length ? (\n <>\n <h3>\n <FontAwesomeIcon\n icon=\"paperclip\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n Attachment Uploader\n </h3>\n <input\n type=\"file\"\n style={{ margin: 20 }}\n accept={attachmentConfig?.allowedFileTypes}\n multiple\n onChange={handleChange}\n />\n {attachmentCategories.length > 0 ? (\n <ComboBox\n label=\"Attachment Type\"\n sx={{ width: 300, m: 1 }}\n options={attachmentCategories}\n displayField=\"value\"\n valueField=\"value\"\n value={selectedCategory}\n onChangeCallBack={(v) => {\n setSelectedCategory(v);\n }}\n />\n ) : (\n <></>\n )}\n\n <TemplateTextField\n label=\"Remark\"\n value={remark}\n onChange={(event) => setRemark(event.target.value)}\n multiline={true}\n sx={{ width: 300, m: 1 }}\n rows={3}\n />\n <Button sx={{ m: 1 }} variant=\"contained\" onClick={handleUpload}>\n Upload\n </Button>\n </>\n ) : (\n <></>\n )}\n </>\n ) : (\n <></>\n )}\n\n {showAttachments && attachmentConfig?.refKeyAttachments?.length > 0 ? (\n <>\n <h3>\n <FontAwesomeIcon\n style={{ marginRight: 10, marginLeft: 10 }}\n icon=\"paperclip\"\n />\n Attachments\n </h3>\n <Grid2\n container\n spacing={2}\n sx={{ overflow: \"auto\", padding: 1, justifyContent: \"center\" }}\n >\n {attachmentConfig?.refKeyAttachments.map((refKeyAttachment) => {\n return (\n <Grid2\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <AttachmentCard\n {...refKeyAttachment}\n attachmentCode={props.attachmentCode}\n setAttachmentConfig={setAttachmentConfig}\n downloadAuthorityKey={attachmentConfig.downloadAuthorityKey}\n allowDelete={allowUpload}\n />\n </Grid2>\n );\n })}\n </Grid2>\n </>\n ) : (\n <></>\n )}\n </Paper>\n );\n};\n\nexport default AttachmentPanel;\n","import Typography from \"@mui/material/Typography\";\nimport { workflowDocumentActionHistory } from \"./WorkflowDocumentPanel\";\nimport { useSelector } from \"react-redux\";\nimport { Avatar, Box, Divider, Paper, Stack } from \"@mui/material\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { useTranslation } from \"react-i18next\";\nimport AttachmentImageViewer from \"../attachment/AttachmentImageViewer\";\n\ntype WorkflowDocumentTimeLineProp = {\n actionHistory: Array<workflowDocumentActionHistory>;\n};\n\nconst WorkflowDocumentTimeLine: React.FC<WorkflowDocumentTimeLineProp> = (\n props\n) => {\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const { t } = useTranslation();\n return (\n <Paper\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n flexGrow: 1,\n padding: 1,\n margin: 1,\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <Box\n sx={{\n width: \"100%\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontSize: 18,\n fontWeight: \"bold\",\n }}\n >\n <FontAwesomeIcon\n icon=\"history\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n {t(\"WF_ACTION_HISTORY_LABEL\")}\n </Box>\n <Box\n sx={{\n flexGrow: 1,\n width: \"100%\",\n display: \"flex\",\n flexDirection: \"column\",\n overflowY: \"auto\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n }}\n >\n {props.actionHistory.map((actionHistoryRecord, index) => {\n return (\n <>\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n width: \"100%\",\n marginBottom: 2,\n }}\n >\n <Box\n sx={{\n display: \"flex\",\n flex: 1,\n flexDirection: \"column\",\n alignItems: \"flex-end\",\n justifyContent: \"center\",\n }}\n >\n <Box sx={{ marginBottom: 0.2 }}>\n {actionHistoryRecord.actionTime}\n </Box>\n <Typography>\n via {actionHistoryRecord.actionMethod}\n </Typography>\n </Box>\n <Box\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"center\",\n position: \"relative\",\n marginRight: 2,\n marginLeft: 2,\n }}\n >\n <AttachmentImageViewer\n showAsAvatar={true}\n attachmentCode=\"EMPLOYEE_PHOTOS\"\n refKey={actionHistoryRecord?.personId + \"\" || \"0\"}\n style={{ m: 1, width: 70, height: 70 }}\n />\n {index !== props.actionHistory.length - 1 ? (\n <Box sx={{ marginTop: 11, position: \"absolute\" }}>|</Box>\n ) : (\n <></>\n )}\n </Box>\n <Box\n sx={{\n display: \"flex\",\n flex: 1,\n flexDirection: \"column\",\n alignItems: \"flex-start\",\n justifyContent: \"center\",\n }}\n >\n <Box sx={{ width: \"100%\" }}>\n {AppLayout.appDirection === \"ltr\"\n ? `${actionHistoryRecord?.documentActionEnName}`\n : `${actionHistoryRecord?.documentActionArName}`}\n {actionHistoryRecord?.actionComment\n ? \" - \" + actionHistoryRecord.actionComment\n : \"\"}\n </Box>\n <Box sx={{ width: \"100%\" }}>\n {AppLayout.appDirection === \"ltr\"\n ? `${actionHistoryRecord?.employeeEnName}`\n : `${actionHistoryRecord?.employeeArName}`}\n </Box>\n </Box>\n </Box>\n </>\n );\n })}\n </Box>\n </Paper>\n );\n};\n\nexport default WorkflowDocumentTimeLine;\n","import { Button } from \"@mui/material\";\nimport { RecordAction } from \"../DataEntryTypes\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { toast } from \"react-toastify\";\nimport { useTranslation } from \"react-i18next\";\nimport useSession from \"../../../../hooks/UseSession\";\nimport { useConfirmationWindow } from \"../../../../hooks/UseConfirmationWindow\";\n\nconst TemplateGridMultiRecordAction: React.FC<RecordAction> = (\n rowAction: RecordAction\n) => {\n const { t } = useTranslation();\n const session = useSession();\n const { ConfirmationWindow, setOpen } = useConfirmationWindow({\n body: t(rowAction?.confirmationMessage || \"ACTION_CONFIRMATION\"),\n title: t(\"CONFIRMATION\"),\n onConfirmationCallBk: async () => {\n await rowAction?.actionFn(\n rowAction.recordsToProcessActionOn,\n rowAction.recordIdsToProcessActionOn\n );\n if (rowAction?.reloadData) {\n rowAction.reloadData();\n }\n },\n });\n let isActionAllowed = true;\n if (rowAction.authority) {\n isActionAllowed = session.isUserAuthorized(rowAction.authority);\n }\n\n if (isActionAllowed) {\n return (\n <>\n <ConfirmationWindow />\n <Button\n onClick={async () => {\n if (\n rowAction?.recordsToProcessActionOn &&\n rowAction?.recordsToProcessActionOn.length > 0\n ) {\n if (rowAction?.preActionValidation) {\n for (const record of rowAction.recordsToProcessActionOn) {\n if (!rowAction.preActionValidation(record)) {\n return;\n }\n }\n }\n if (rowAction?.isConfirmationRequired === true) {\n setOpen(true);\n } else {\n await rowAction.actionFn(\n rowAction.recordsToProcessActionOn,\n rowAction.recordIdsToProcessActionOn\n );\n if (rowAction?.reloadData) {\n rowAction.reloadData();\n }\n }\n } else {\n toast.error(t(\"AT_LEAST_ONE_RECORD_SELECTED_MESSAGE\"));\n }\n }}\n variant={\n rowAction?.label\n ? \"outlined\"\n : rowAction?.formActionProps?.actionButtonVariant\n ? rowAction.formActionProps.actionButtonVariant\n : \"text\"\n }\n size=\"small\"\n color={rowAction?.formActionProps?.actionButtonColor || \"primary\"}\n >\n {rowAction?.icon ? (\n <FontAwesomeIcon\n style={{ marginRight: 5, marginLeft: 5 }}\n icon={rowAction.icon}\n />\n ) : (\n <></>\n )}\n {rowAction?.label ? t(rowAction.label) : <></>}\n </Button>\n </>\n );\n }\n};\n\nexport default TemplateGridMultiRecordAction;\n","import {\n Badge,\n Box,\n Button,\n Divider,\n IconButton,\n InputAdornment,\n MenuItem,\n styled,\n TextField,\n Tooltip,\n} from \"@mui/material\";\nimport {\n Toolbar,\n ToolbarButton,\n ColumnsPanelTrigger,\n FilterPanelTrigger,\n QuickFilter,\n QuickFilterControl,\n QuickFilterClear,\n QuickFilterTrigger,\n GridViewColumnIcon,\n GridFilterListIcon,\n ExportExcel,\n} from \"@mui/x-data-grid-premium\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport TemplateGridMultiRecordAction from \"./TemplateGridMultiRecordAction\";\nimport { getGridSelection } from \"../DataEntryUtil\";\nimport { useTranslation } from \"react-i18next\";\nimport { TemplateGridTopBarProps } from \"../DataEntryTypes\";\nimport useSession from \"../../../../hooks/UseSession\";\n\ntype OwnerState = {\n expanded: boolean;\n};\n\nconst StyledQuickFilter = styled(QuickFilter)({\n display: \"grid\",\n alignItems: \"center\",\n});\n\nconst StyledToolbarButton = styled(ToolbarButton)<{ ownerState: OwnerState }>(\n ({ theme, ownerState }) => ({\n gridArea: \"1 / 1\",\n width: \"min-content\",\n height: \"min-content\",\n zIndex: 1,\n opacity: ownerState.expanded ? 0 : 1,\n pointerEvents: ownerState.expanded ? \"none\" : \"auto\",\n transition: theme.transitions.create([\"opacity\"]),\n })\n);\n\nconst StyledTextField = styled(TextField)<{\n ownerState: OwnerState;\n}>(({ theme, ownerState }) => ({\n gridArea: \"1 / 1\",\n overflowX: \"clip\",\n width: ownerState.expanded ? 260 : \"var(--trigger-width)\",\n opacity: ownerState.expanded ? 1 : 0,\n transition: theme.transitions.create([\"width\", \"opacity\"]),\n}));\n\nconst TemplateGridTopBar: React.FC<TemplateGridTopBarProps> = (\n props: TemplateGridTopBarProps\n) => {\n const { t } = useTranslation();\n const session = useSession();\n const isCreationAuthorized = props?.templateProps?.editAction?.authority\n ? session.isUserAuthorized(props.templateProps.editAction.authority)\n : true;\n const isCreationEnabled = props?.templateProps?.disableDefaultAction || true;\n const gridSelection = getGridSelection(\n props?.templateProps?.rowSelectionModel || {\n ids: new Set(),\n type: \"include\",\n },\n props?.templateProps?.data || [],\n props?.templateProps?.keyColumnName || \"id\"\n );\n return (\n <Toolbar>\n {isCreationEnabled &&\n isCreationAuthorized &&\n props?.templateProps?.editMode?.editMode != \"none\" ? (\n <Button onClick={props?.handleCreateNewRecord}>\n <FontAwesomeIcon\n icon=\"add\"\n style={{ marginRight: 5, marginLeft: 5 }}\n />\n {t(\"ADD_BTN_LABEL\")}\n </Button>\n ) : (\n <></>\n )}\n {props?.templateProps?.rowActions ? (\n props.templateProps.rowActions.map((rowAction, index) =>\n rowAction?.gridActionProps?.multiRecord === true ? (\n <TemplateGridMultiRecordAction\n {...rowAction}\n key={index}\n reloadData={async () => {\n props.templateProps.apiActions.reloadData(\n props?.templateProps?.gridLoadParametersValues\n );\n }}\n recordIdsToProcessActionOn={gridSelection.selectedRecordIds}\n recordsToProcessActionOn={gridSelection.selectedRecords}\n />\n ) : null\n )\n ) : (\n <></>\n )}\n <Box sx={{ flex: 1, mx: 0.5, my: 0.5, padding: 1 }}>\n {props?.templateProps?.tBar}\n </Box>\n\n <Tooltip title=\"Columns\">\n <ColumnsPanelTrigger render={<ToolbarButton />}>\n <GridViewColumnIcon fontSize=\"small\" />\n </ColumnsPanelTrigger>\n </Tooltip>\n\n <Tooltip title=\"Filters\">\n <FilterPanelTrigger\n render={(props, state) => (\n <ToolbarButton {...props} color=\"default\">\n <Badge\n badgeContent={state.filterCount}\n color=\"primary\"\n variant=\"dot\"\n >\n <GridFilterListIcon fontSize=\"small\" />\n </Badge>\n </ToolbarButton>\n )}\n />\n </Tooltip>\n\n {props?.templateProps?.gridStateKey ? (\n <Tooltip title={t(\"RESET_GRID_STATE\")}>\n <IconButton onClick={props?.clearGridState}>\n <FontAwesomeIcon icon=\"eraser\" />\n </IconButton>\n </Tooltip>\n ) : (\n <></>\n )}\n\n <Divider\n orientation=\"vertical\"\n variant=\"middle\"\n flexItem\n sx={{ mx: 0.5 }}\n />\n\n <Tooltip title={t(\"EXPORT_EXECL_LABEL\")}>\n <ExportExcel render={<MenuItem />}>\n <FontAwesomeIcon icon=\"file-excel\" color=\"green\" />\n </ExportExcel>\n </Tooltip>\n\n <StyledQuickFilter>\n <QuickFilterTrigger\n render={(triggerProps, state) => (\n <Tooltip title={t(\"SEARCH_BTN_LABEL\")} enterDelay={0}>\n <StyledToolbarButton\n {...triggerProps}\n ownerState={{ expanded: state.expanded }}\n color=\"default\"\n aria-disabled={state.expanded}\n >\n <FontAwesomeIcon icon=\"search\" />\n </StyledToolbarButton>\n </Tooltip>\n )}\n />\n <QuickFilterControl\n render={({ ref, ...controlProps }, state) => (\n <StyledTextField\n {...controlProps}\n ownerState={{ expanded: state.expanded }}\n inputRef={ref}\n aria-label=\"Search\"\n placeholder={`${t(\"SEARCH_BTN_LABEL\")}...`}\n size=\"small\"\n slotProps={{\n input: {\n startAdornment: (\n <InputAdornment position=\"start\">\n <FontAwesomeIcon icon=\"search\" />\n </InputAdornment>\n ),\n endAdornment: state.value ? (\n <InputAdornment position=\"end\">\n <QuickFilterClear\n edge=\"end\"\n size=\"small\"\n aria-label=\"Clear search\"\n // material={{ sx: { marginRight: -0.75 } }}\n >\n <FontAwesomeIcon icon=\"xmark\" />\n </QuickFilterClear>\n </InputAdornment>\n ) : null,\n ...controlProps.slotProps?.input,\n },\n ...controlProps.slotProps,\n }}\n />\n )}\n />\n </StyledQuickFilter>\n\n <IconButton\n onClick={() => {\n props.templateProps.apiActions.reloadData(\n props?.templateProps?.gridLoadParametersValues\n );\n }}\n >\n <FontAwesomeIcon icon=\"refresh\" />\n </IconButton>\n </Toolbar>\n );\n};\n\nexport default TemplateGridTopBar;\n","import { Tooltip } from \"@mui/material\";\nimport { GridActionsCellItem } from \"@mui/x-data-grid-premium\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { RecordAction } from \"../DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport useSession from \"../../../../hooks/UseSession\";\nimport { useConfirmationWindow } from \"../../../../hooks/UseConfirmationWindow\";\n\nconst TemplateGridRecordAction: React.FC<RecordAction> = (\n rowAction: RecordAction\n) => {\n const { t } = useTranslation();\n const session = useSession();\n const { ConfirmationWindow, setOpen } = useConfirmationWindow({\n body: t(rowAction?.confirmationMessage || \"ACTION_CONFIRMATION\"),\n title: t(\"CONFIRMATION\"),\n onConfirmationCallBk: async () => {\n await rowAction?.actionFn(rowAction.record);\n if (rowAction?.reloadData) {\n rowAction.reloadData();\n }\n },\n });\n let isActionAllowed = true;\n if (rowAction.authority) {\n isActionAllowed = session.isUserAuthorized(rowAction.authority);\n }\n let iconStyle: any = {};\n if (rowAction?.getActionIconStyleForRecord) {\n iconStyle = rowAction.getActionIconStyleForRecord(rowAction.record);\n }\n let isActionVisibleForRecord = true;\n if (rowAction?.isActionVisibleForRecord) {\n isActionVisibleForRecord = rowAction?.isActionVisibleForRecord(\n rowAction.record\n );\n }\n let isActionDisabledForRecord = false;\n if (rowAction?.isActionDisabledForRecord) {\n isActionDisabledForRecord = rowAction.isActionDisabledForRecord(\n rowAction.record\n );\n }\n if (isActionAllowed && isActionVisibleForRecord) {\n return (\n <>\n <ConfirmationWindow />\n <GridActionsCellItem\n disabled={isActionDisabledForRecord}\n icon={\n <Tooltip title={rowAction?.label ? t(rowAction.label) : \"\"}>\n <FontAwesomeIcon\n icon={rowAction.icon}\n style={{\n ...iconStyle,\n color: isActionDisabledForRecord\n ? \"gray\"\n : iconStyle?.color != undefined\n ? iconStyle.color\n : undefined,\n }}\n />\n </Tooltip>\n }\n showInMenu={rowAction?.gridActionProps?.showInMenu || false}\n label={\"\"}\n className=\"textPrimary\"\n color=\"inherit\"\n onClick={async () => {\n if (!isActionDisabledForRecord) {\n if (rowAction?.preActionValidation) {\n if (!rowAction.preActionValidation(rowAction.record)) {\n return;\n }\n }\n if (rowAction?.isConfirmationRequired === true) {\n setOpen(true);\n } else {\n await rowAction.actionFn(rowAction.record);\n if (\n rowAction?.gridActionProps?.reloadGridAfterAction === true &&\n rowAction?.reloadData\n ) {\n rowAction.reloadData();\n }\n }\n }\n }}\n />\n </>\n );\n }\n};\n\nexport default TemplateGridRecordAction;\n","import {\n DataGridPremium,\n GridActionsCellItem,\n GridActionsCellItemProps,\n GridColumnOrderChangeParams,\n GridColumnResizeParams,\n GridColumnVisibilityModel,\n GridEventListener,\n GridExpandMoreIcon,\n GridPinnedColumnFields,\n GridRowGroupingModel,\n GridRowModes,\n GridRowModesModel,\n GridRowParams,\n GridRowSelectionModel,\n} from \"@mui/x-data-grid-premium\";\nimport { TemplateGridColDef, TemplateGridProps } from \"../DataEntryTypes\";\nimport TemplateGridTopBar from \"./TemplateGridTopBar\";\nimport { useNavigate } from \"react-router-dom\";\nimport React, { useEffect, useState } from \"react\";\nimport { z } from \"zod\";\nimport {\n constructGridColumnsFromFields,\n constructValidationSchema,\n getAllFields,\n} from \"../DataEntryUtil\";\nimport { toast } from \"react-toastify\";\nimport {\n Accordion,\n AccordionDetails,\n AccordionSummary,\n Box,\n Divider,\n IconButton,\n Tooltip,\n Typography,\n} from \"@mui/material\";\nimport { capitalizeFirstLetter, isNumber } from \"../../../../util/AppUtils\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport TemplateGridRecordAction from \"./TemplateGridRecordAction\";\nimport TemplateForm from \"../TemplateDataForm/TemplateForm\";\nimport { useSelector } from \"react-redux\";\nimport { useTranslation } from \"react-i18next\";\nimport useSession from \"../../../../hooks/UseSession\";\nimport { useConfirmationWindow } from \"../../../../hooks/UseConfirmationWindow\";\nimport { useWindow } from \"../../../../hooks/UseWindow\";\nimport { useAxios } from \"../../../../hooks\";\nimport useLookupGridColumn from \"../../../../hooks/useLookupGridColumn\";\nimport { ContinuousColorLegend } from \"@mui/x-charts\";\nimport AttachmentPanel from \"../../attachment/AttachmentPanel\";\nimport WorkflowDocumentPanel from \"../../workflow/WorkflowDocumentPanel\";\nlet currentNewRecordIndex = -1;\n\ninterface GridState {\n columnVisibilityModel?: GridColumnVisibilityModel;\n columnOrder?: string[];\n columnWidths?: { [key: string]: number };\n columnGroupingModel?: GridRowGroupingModel;\n pinnedColumns?: GridPinnedColumnFields;\n}\n\nconst loadGridState = (gridStateKey: string): GridState => {\n try {\n const saved = localStorage.getItem(gridStateKey);\n return saved ? JSON.parse(saved) : {};\n } catch (e) {\n console.error(\"Failed to load grid state\", e);\n return {};\n }\n};\n\nconst saveGridState = (gridStateKey: string, statePart: GridState) => {\n const current = loadGridState(gridStateKey);\n localStorage.setItem(\n gridStateKey,\n JSON.stringify({ ...current, ...statePart })\n );\n};\n\nconst PIN_FIXED_COLUMNS = [\"__check__\", \"actions\"];\n\nconst TemplateGrid: React.FC<TemplateGridProps> = (props) => {\n const { t } = useTranslation();\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const [selectedRecord, setSelectedRecord] = useState<any>({});\n const [attachmentPanelEnabledForRecord, setAttachmentPanelEnabledForRecord] =\n useState<boolean>(true);\n const { getLookupOptions } = useLookupGridColumn();\n const { Window: AttachmentWindow, setWindowState: setAttachmentWindowState } =\n useWindow({\n windowTitle: t(props.gridTitle) + \" Attachments\",\n windowIcon: \"paperclip\",\n width: \"fit-content\",\n height: \"fit-content\",\n minHeight: 500,\n minWidth: \"50%\",\n onCloseCallBack: () => {\n props?.apiActions?.reloadData(props.gridLoadParametersValues);\n },\n });\n const { Window: WorkFlowWindow, setWindowState: setWorkFlowWindowState } =\n useWindow({\n windowTitle: t(props.gridTitle) + \" Approvals\",\n windowIcon: \"stamp\",\n width: \"fit-content\",\n height: \"fit-content\",\n minHeight: 500,\n minWidth: \"80%\",\n onCloseCallBack: () => {\n props?.apiActions?.reloadData(props.gridLoadParametersValues);\n },\n });\n const [generatedColumns, setGeneratedColumns] = useState<\n Array<TemplateGridColDef>\n >([]);\n const fields = getAllFields(props.formElements);\n const hiddenFields = [];\n const savedState = React.useMemo<GridState>(\n () => (props?.gridStateKey ? loadGridState(props.gridStateKey) : {}),\n []\n );\n for (const field of fields) {\n if (field?.gridProps?.hidden === true) {\n hiddenFields.push(field.fieldName);\n }\n }\n let initialVisibilityState: GridColumnVisibilityModel = {};\n if (savedState?.columnVisibilityModel) {\n initialVisibilityState = savedState.columnVisibilityModel;\n const existingFields = Object.keys(initialVisibilityState);\n for (const field of hiddenFields) {\n if (!existingFields.includes(field)) {\n initialVisibilityState[field] = false;\n }\n }\n } else {\n for (const field of hiddenFields) {\n initialVisibilityState[field] = false;\n }\n }\n\n const themeDirection = useSelector(\n (state: any) => state.AppLayout.appDirection\n );\n\n const clearGridState = () => {\n if (props?.gridStateKey) {\n localStorage.removeItem(props.gridStateKey);\n }\n setColumnVisibilityModel({});\n setColumnOrder([]);\n setColumnWidths({});\n setGridRowGroupingModel([]);\n setPinnedColumns({\n left: [...(themeDirection === \"ltr\" ? PIN_FIXED_COLUMNS : [])],\n right: [...(themeDirection === \"rtl\" ? PIN_FIXED_COLUMNS : [])],\n });\n };\n const [columnVisibilityModel, setColumnVisibilityModel] =\n React.useState<GridColumnVisibilityModel>(initialVisibilityState);\n const [columnOrder, setColumnOrder] = React.useState<string[]>(\n savedState.columnOrder || []\n );\n const [columnWidths, setColumnWidths] = React.useState<{\n [key: string]: number;\n }>(savedState.columnWidths || {});\n const [gridRowGroupingModel, setGridRowGroupingModel] =\n useState<GridRowGroupingModel>(savedState.columnGroupingModel || []);\n let newLeft = savedState?.pinnedColumns?.left || [];\n newLeft = newLeft.filter(\n (record: any) => !PIN_FIXED_COLUMNS.includes(record)\n );\n let newRight = savedState?.pinnedColumns?.right || [] || [];\n newRight = newRight.filter(\n (record: any) => !PIN_FIXED_COLUMNS.includes(record)\n );\n\n const [pinnedColumns, setPinnedColumns] = useState<GridPinnedColumnFields>({\n left: [...(themeDirection === \"ltr\" ? PIN_FIXED_COLUMNS : []), ...newLeft],\n right: [\n ...(themeDirection === \"rtl\" ? PIN_FIXED_COLUMNS : []),\n ...newRight,\n ],\n });\n\n const session = useSession();\n const navigate = useNavigate();\n const [recordToDelete, setRecordToDelete] = useState<any>(null);\n const [recordToEdit, setRecordToEdit] = useState<any>(null);\n const [rowModesModel, setRowModesModel] = useState<GridRowModesModel>({});\n const adjustGridColumns = async () => {\n let gridColumns = constructGridColumnsFromFields(\n fields,\n props?.editMode?.editMode === \"row\" || false,\n t\n );\n for (let gridColumn of gridColumns) {\n if (gridColumn?.lookupType) {\n gridColumn.displayField =\n AppLayout.appDirection === \"ltr\"\n ? \"lookupEnDisplay\"\n : \"lookupArDisplay\";\n gridColumn.options = await getLookupOptions(gridColumn.lookupType);\n gridColumn.valueField = \"lookupValue\";\n }\n }\n setGeneratedColumns(gridColumns);\n };\n const [rowSelectionModel, setRowSelectionModel] =\n useState<GridRowSelectionModel>({ ids: new Set(), type: \"include\" });\n let keyColumnName: string = \"id\";\n if (props?.keyColumnName) {\n keyColumnName = props?.keyColumnName;\n }\n const setData = props.setData;\n let validationSchema = null;\n if (props?.validationSchema) {\n validationSchema = props.validationSchema;\n } else {\n validationSchema = z.object(constructValidationSchema(fields));\n }\n\n let isEditAllowed = true;\n if (props?.editAction?.authority) {\n isEditAllowed = session.isUserAuthorized(props.editAction.authority);\n }\n let isDeleteAllowed = true;\n if (props?.deleteAction?.authority) {\n isDeleteAllowed = session.isUserAuthorized(props.deleteAction.authority);\n }\n\n const handleRowModesModelChange = (newModel: GridRowModesModel) => {\n setRowModesModel(newModel);\n };\n\n const handlePinnedColumnsChange = (newModel: GridPinnedColumnFields) => {\n let newLeft = newModel?.left || [];\n newLeft = newLeft.filter(\n (record: any) => !PIN_FIXED_COLUMNS.includes(record)\n );\n let newRight = newModel?.right || [];\n newRight = newRight.filter(\n (record: any) => !PIN_FIXED_COLUMNS.includes(record)\n );\n const newPinedColumns: GridPinnedColumnFields = {\n left: [\n ...(themeDirection === \"ltr\" ? PIN_FIXED_COLUMNS : []),\n ...newLeft,\n ],\n right: [\n ...(themeDirection === \"rtl\" ? PIN_FIXED_COLUMNS : []),\n ...newRight,\n ],\n };\n setPinnedColumns(newPinedColumns);\n if (props?.gridStateKey) {\n saveGridState(props.gridStateKey, { pinnedColumns: newPinedColumns });\n }\n };\n\n const handleDeleteRecord = async () => {\n let result = true;\n if (!(recordToDelete && recordToDelete?.isNew === true)) {\n result = await props.apiActions.deleteRecordById(\n recordToDelete[keyColumnName]\n );\n }\n if (result) {\n if (props?.deleteAction?.postActionCallBack) {\n await props.deleteAction.postActionCallBack(recordToDelete);\n }\n\n setData((oldData: any) => {\n const newData = oldData.filter(\n (record: any) =>\n record[keyColumnName] != recordToDelete[keyColumnName]\n );\n return newData;\n });\n }\n };\n\n const { ConfirmationWindow, setOpen: setConfirmationWindowOpened } =\n useConfirmationWindow({\n title: \"Confirmation\",\n body: \"Are you sure you want to delete this record ?\",\n onConfirmationCallBk: handleDeleteRecord,\n });\n\n let formModalHeight = undefined;\n let formModalWidth = undefined;\n let formModalMinHeight = undefined;\n let formModalMinWidth = undefined;\n let formModalIcon = undefined;\n let formModalTitle = undefined;\n\n if (props?.editMode?.editMode === \"modal\") {\n formModalHeight = props?.editMode?.specs?.modalHeight || \"fit-content\";\n formModalWidth = props?.editMode?.specs?.modalWidth || \"300\";\n formModalMinHeight = props?.editMode?.specs?.modalMinHeight;\n formModalMinWidth = props?.editMode?.specs?.modalMinWidth;\n formModalIcon = props?.editMode?.specs?.modalIcon || \"window\";\n formModalTitle = props?.editMode?.specs?.modalTitle || \"Record Form\";\n }\n\n const { Window: FormWindow, setWindowState: setFormWindowState } = useWindow({\n height: formModalHeight,\n minHeight: formModalMinHeight,\n minWidth: formModalMinWidth,\n onCloseCallBack: () => {\n props.apiActions.reloadData(props?.gridLoadParametersValues);\n },\n width: formModalWidth,\n windowIcon: formModalIcon,\n windowTitle: formModalTitle,\n });\n\n const handleCreateNewRecord = () => {\n if (props?.editMode?.editMode === \"form\") {\n navigate(props.editMode.specs.formRoute);\n } else if (props?.editMode?.editMode === \"modal\") {\n setRecordToEdit(null);\n setFormWindowState(true);\n } else if (props?.editMode?.editMode === \"row\") {\n currentNewRecordIndex = currentNewRecordIndex - 1;\n const newRecord: any = {};\n newRecord[keyColumnName] = currentNewRecordIndex;\n newRecord.isNew = true;\n for (const gridColumn of generatedColumns) {\n if (\n gridColumn?.type != \"actions\" &&\n gridColumn?.field != keyColumnName\n ) {\n if (gridColumn?.field) {\n newRecord[gridColumn.field] = null;\n }\n }\n }\n setData((oldRows: any) => [newRecord, ...oldRows]);\n setRowModesModel((oldModel: any) => ({\n ...oldModel,\n [currentNewRecordIndex]: { mode: GridRowModes.Edit },\n }));\n }\n };\n\n const handleEditRecord = async (record: any) => {\n if (record) {\n setRecordToEdit(record);\n if (props.editMode.editMode === \"form\") {\n navigate(props.editMode.specs.formRoute + \"/\" + record[keyColumnName]);\n } else if (props.editMode.editMode === \"modal\") {\n setFormWindowState(true);\n } else if (props?.editMode?.editMode === \"row\") {\n const id = record[keyColumnName];\n setRowModesModel({\n ...rowModesModel,\n [id]: { mode: GridRowModes.Edit },\n });\n }\n }\n };\n\n const validateRecord = (record: any) => {\n try {\n validationSchema.parse(record);\n } catch (err) {\n console.log(\"validateRecord err\", err);\n let errorMessage: any = null;\n if (err instanceof z.ZodError) {\n errorMessage = err.errors\n .map(\n (error) => \"Error in field (\" + error.path + \") : \" + error.message\n )\n .join(\",\");\n } else {\n errorMessage = \"invalid record data\";\n }\n return errorMessage;\n }\n };\n\n const handleSaveRowClick = (record: any) => {\n const id = record[keyColumnName];\n setRowModesModel({\n ...rowModesModel,\n [id]: { mode: GridRowModes.View },\n });\n };\n\n const processRowUpdate = async (record: any) => {\n if (props.editMode.editMode === \"row\") {\n let savedRecord: any = null;\n const errorMessage = validateRecord(record);\n if (errorMessage) {\n const errors = errorMessage.split(\",\");\n toast.error(\n <div style={{}}>\n {errors.map((error: any) => (\n <>\n <div>{error}</div>\n <Divider />\n </>\n ))}\n </div>\n );\n throw new Error(errorMessage);\n }\n if (props?.editAction?.preActionValidation) {\n if (!props.editAction.preActionValidation(record)) {\n throw new Error(\"error on the configured presave validation\");\n }\n }\n const requestObject: any = { ...record };\n if (\n record[keyColumnName] &&\n isNumber(record[keyColumnName]) &&\n Number(record[keyColumnName]) < 0\n ) {\n requestObject[keyColumnName] = null;\n }\n savedRecord = await props.apiActions.saveRecord(requestObject);\n if (savedRecord == null) {\n throw new Error(\n \"Failed to process your request, contact your administrator\"\n );\n }\n if (props?.editAction?.postActionCallBack) {\n await props.editAction.postActionCallBack(record);\n }\n if (record?.isNew === true) {\n setData((oldData: any) => {\n const newData = oldData.filter(\n (x: any) => x[keyColumnName] !== record[keyColumnName]\n );\n return [savedRecord, ...newData];\n });\n }\n if (\n props?.editMode?.reloadAfterSave === true &&\n props?.apiActions?.reloadData\n ) {\n props?.apiActions?.reloadData(props?.gridLoadParametersValues);\n }\n return savedRecord;\n }\n };\n\n const handleCancelRowEditClick = (record: any) => {\n const id = record[keyColumnName];\n if (id && isNumber(id) && id < 0) {\n setRowModesModel({\n ...rowModesModel,\n [id]: { mode: GridRowModes.View, ignoreModifications: true },\n });\n setData((oldData: any) => {\n const newData = oldData.filter(\n (record: any) => record[keyColumnName] != id\n );\n return newData;\n });\n } else {\n setRowModesModel({\n ...rowModesModel,\n [id]: { mode: GridRowModes.View, ignoreModifications: true },\n });\n }\n };\n\n const getActionColumnActions = (params: GridRowParams<any>) => {\n const record: any = params.row;\n const actions: Array<React.ReactElement<GridActionsCellItemProps>> = [];\n if (props?.editMode?.editMode != \"none\") {\n if (\n props?.disableDefaultAction === undefined ||\n !props.disableDefaultAction\n ) {\n const isInEditMode: boolean =\n rowModesModel[record[keyColumnName]]?.mode === GridRowModes.Edit;\n if (props.editMode.editMode === \"row\" && isInEditMode) {\n if (isEditAllowed) {\n actions.push(\n <GridActionsCellItem\n icon={<FontAwesomeIcon icon=\"save\" />}\n label={t(\"SAVE_BTN_LABEL\")}\n onClick={() => {\n handleSaveRowClick(record);\n }}\n />\n );\n actions.push(\n <GridActionsCellItem\n icon={<FontAwesomeIcon icon=\"cancel\" />}\n label={t(\"CANCEL_BTN_LABEL\")}\n onClick={() => {\n handleCancelRowEditClick(record);\n }}\n color=\"inherit\"\n />\n );\n }\n } else {\n if (props?.editAction && props?.editAction?.isEnabled === true) {\n let isEditActionVisibleForRecord = true;\n if (props?.editAction?.isActionVisibleForRecord) {\n isEditActionVisibleForRecord =\n props?.editAction?.isActionVisibleForRecord(record);\n }\n let isActionEditDisabledForRecord = false;\n if (props?.editAction?.isActionDisabledForRecord) {\n isActionEditDisabledForRecord =\n props?.editAction?.isActionDisabledForRecord(record);\n }\n if (isEditAllowed && isEditActionVisibleForRecord) {\n actions.push(\n <GridActionsCellItem\n disabled={isActionEditDisabledForRecord}\n icon={\n <Tooltip title={t(\"EDIT_BTN_LABEL\")}>\n <FontAwesomeIcon\n icon={\"edit\"}\n style={{\n color: isActionEditDisabledForRecord\n ? \"gray\"\n : undefined,\n }}\n />\n </Tooltip>\n }\n showInMenu={\n props?.editAction?.gridActionProps?.showInMenu || false\n }\n label={t(\"EDIT_BTN_LABEL\")}\n className=\"textPrimary\"\n color=\"inherit\"\n onClick={() => {\n if (isEditAllowed && !isActionEditDisabledForRecord) {\n handleEditRecord(record);\n }\n }}\n />\n );\n }\n }\n if (props?.deleteAction && props?.deleteAction?.isEnabled === true) {\n let isDeleteActionVisibleForRecord = true;\n if (props?.deleteAction?.isActionVisibleForRecord) {\n isDeleteActionVisibleForRecord =\n props?.deleteAction?.isActionVisibleForRecord(record);\n }\n let isDeleteActionDisabledForRecord = false;\n if (props?.deleteAction?.isActionDisabledForRecord) {\n isDeleteActionDisabledForRecord =\n props?.deleteAction?.isActionDisabledForRecord(record);\n }\n if (isDeleteAllowed && isDeleteActionVisibleForRecord) {\n actions.push(\n <GridActionsCellItem\n disabled={isDeleteActionDisabledForRecord}\n icon={\n <Tooltip title={t(\"DELETE_BTN_LABEL\")}>\n <FontAwesomeIcon\n icon={\"trash\"}\n style={{\n color: isDeleteActionDisabledForRecord\n ? \"gray\"\n : undefined,\n }}\n />\n </Tooltip>\n }\n showInMenu={\n props?.deleteAction?.gridActionProps?.showInMenu || false\n }\n label={t(\"DELETE_BTN_LABEL\")}\n className=\"textPrimary\"\n color=\"inherit\"\n onClick={() => {\n if (isDeleteAllowed && !isDeleteActionDisabledForRecord) {\n if (props?.deleteAction?.preActionValidation) {\n if (!props.deleteAction.preActionValidation(record)) {\n return;\n }\n }\n setRecordToDelete(record);\n setConfirmationWindowOpened(true);\n }\n }}\n />\n );\n }\n }\n }\n }\n }\n if (\n record[props?.keyColumnName || \"id\"] &&\n record[props?.keyColumnName || \"id\"] > 0 &&\n props?.attachment\n ) {\n actions?.push(\n <GridActionsCellItem\n icon={\n <Tooltip title={\"Attachments\"}>\n <FontAwesomeIcon icon={\"paperclip\"} />\n </Tooltip>\n }\n label={\"Attachments\"}\n className=\"textPrimary\"\n color=\"inherit\"\n onClick={() => {\n setSelectedRecord(record);\n if (props?.attachment?.enableAttachFn) {\n setAttachmentPanelEnabledForRecord(\n props.attachment.enableAttachFn(record)\n );\n } else {\n setAttachmentPanelEnabledForRecord(true);\n }\n setAttachmentWindowState(true);\n }}\n />\n );\n }\n if (\n record[props?.keyColumnName || \"id\"] &&\n record[props?.keyColumnName || \"id\"] > 0 &&\n props?.workFlowDocumentCode\n ) {\n actions?.push(\n <GridActionsCellItem\n icon={\n <Tooltip title={\"Approvals\"}>\n <FontAwesomeIcon icon={\"stamp\"} />\n </Tooltip>\n }\n label={\"Approvals\"}\n className=\"textPrimary\"\n color=\"inherit\"\n onClick={() => {\n setSelectedRecord(record);\n setWorkFlowWindowState(true);\n }}\n />\n );\n }\n if (\n record[props?.keyColumnName || \"id\"] &&\n record[props?.keyColumnName || \"id\"] > 0 &&\n props?.rowActions\n ) {\n for (const rowAction of props.rowActions) {\n if (\n !(\n rowAction?.gridActionProps?.multiRecord &&\n rowAction?.gridActionProps?.multiRecord === true\n )\n ) {\n actions.push(\n <TemplateGridRecordAction\n {...rowAction}\n record={record}\n reloadData={async () => {\n props.apiActions.reloadData(props?.gridLoadParametersValues);\n }}\n />\n );\n }\n }\n }\n\n return actions;\n };\n\n const actionColumn: TemplateGridColDef = {\n type: \"actions\",\n field: \"actions\",\n headerName: \"\",\n headerAlign: \"center\",\n width:\n (props?.rowActions ? props.rowActions.length * 30 : 0) +\n (props?.editAction && props?.editAction?.isEnabled ? 30 : 0) +\n (props?.deleteAction && props?.deleteAction?.isEnabled ? 30 : 0) +\n (props?.attachment ? 30 : 0) +\n (props?.workFlowDocumentCode ? 30 : 0),\n getActions: getActionColumnActions,\n };\n\n let structuredColumns: Array<TemplateGridColDef> = [];\n if (\n props?.disableDefaultAction === undefined ||\n !props.disableDefaultAction ||\n (props?.rowActions && props?.rowActions.length > 0)\n ) {\n structuredColumns.push(actionColumn);\n }\n\n structuredColumns = [...structuredColumns, ...generatedColumns];\n const handleRowSelection = (gridSelectionModel: GridRowSelectionModel) => {\n setRowSelectionModel(gridSelectionModel);\n };\n useEffect(() => {\n if (props?.autoLoad === undefined || props.autoLoad === true) {\n props.apiActions.reloadData(props?.gridLoadParametersValues);\n }\n adjustGridColumns();\n }, []);\n\n useEffect(() => {\n props.apiActions.reloadData(props?.gridLoadParametersValues);\n }, [session.UserInfo?.currentOrganization]);\n\n useEffect(() => {\n adjustGridColumns();\n }, [themeDirection, props.formElements]);\n\n const handleColumnVisibilityChange = (model: GridColumnVisibilityModel) => {\n setColumnVisibilityModel(model);\n if (props?.gridStateKey) {\n saveGridState(props.gridStateKey, { columnVisibilityModel: model });\n }\n };\n\n const handleColumnOrderChange: GridEventListener<\"columnOrderChange\"> = (\n params: GridColumnOrderChangeParams\n ) => {\n const { column, targetIndex } = params;\n setColumnOrder((prevOrder) => {\n const currentOrder = prevOrder.length\n ? [...prevOrder]\n : structuredColumns.map((col) => col.field);\n const fromIndex = currentOrder.indexOf(column.field);\n if (fromIndex === -1) return currentOrder;\n\n currentOrder.splice(fromIndex, 1); // remove\n currentOrder.splice(targetIndex, 0, column.field); // insert at new index\n\n if (props?.gridStateKey) {\n saveGridState(props.gridStateKey, { columnOrder: currentOrder });\n }\n\n return currentOrder;\n });\n };\n\n const handleRowGroupChange = (model: GridRowGroupingModel) => {\n setGridRowGroupingModel(model);\n if (props?.gridStateKey) {\n saveGridState(props.gridStateKey, { columnGroupingModel: model });\n }\n };\n\n // const handleColumnWidthChange: GridEventListener<\"columnWidthChange\"> = (\n // params: GridColumnResizeParams\n // ) => {\n // const updatedWidths = {\n // ...columnWidths,\n // [params.colDef.field]: params.width,\n // };\n // setColumnWidths(updatedWidths);\n // if (props?.gridStateKey) {\n // saveGridState(props.gridStateKey, { columnWidths: updatedWidths });\n // }\n // };\n\n const adjustedColumns: Array<TemplateGridColDef> = React.useMemo(() => {\n const baseCols = structuredColumns.map((col) => ({\n ...col,\n }));\n\n // Reorder based on saved columnOrder\n if (columnOrder.length) {\n const fieldToCol = new Map(baseCols.map((col) => [col.field, col]));\n return columnOrder.map((field) => fieldToCol.get(field)!).filter(Boolean);\n }\n return baseCols;\n }, [columnOrder, columnWidths, structuredColumns]);\n\n return (\n <>\n <ConfirmationWindow />\n {props?.editMode?.editMode === \"modal\" ? (\n <FormWindow>\n {props?.editMode?.specs?.formComponent ? (\n <props.editMode.specs.formComponent\n recordIdToEdit={\n recordToEdit ? recordToEdit[keyColumnName] : undefined\n }\n formCloseCallBk={() => {\n setFormWindowState(false);\n props.apiActions.reloadData(props?.gridLoadParametersValues);\n }}\n />\n ) : (\n <TemplateForm\n keyColumnName={props.keyColumnName}\n attachment={props.attachment}\n formValuesChangeCallBk={props?.formProps?.formValuesChangeCallBk}\n recordIdToEdit={\n recordToEdit ? recordToEdit[keyColumnName] : undefined\n }\n formCloseCallBk={() => {\n setFormWindowState(false);\n props.apiActions.reloadData(props?.gridLoadParametersValues);\n }}\n elements={props.formElements}\n apiActions={props.apiActions}\n editAuthorityKey={props?.editAction?.authority}\n formSavedSuccessfullyCallBk={\n props?.editAction?.postActionCallBack\n }\n preSaveValidation={props?.editAction?.preActionValidation}\n actions={props?.rowActions}\n />\n )}\n </FormWindow>\n ) : (\n <></>\n )}\n {props?.hideInfoBar === undefined && !props?.hideInfoBar ? (\n <Box sx={{ display: \"flex\" }}>\n {props?.hideBackButton === undefined && !props?.hideBackButton ? (\n <IconButton\n onClick={() => {\n navigate(-1, { replace: true });\n }}\n >\n <FontAwesomeIcon\n icon={themeDirection === \"ltr\" ? \"arrow-left\" : \"arrow-right\"}\n />\n </IconButton>\n ) : (\n <></>\n )}\n <Box\n sx={{\n flex: 1,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n {props?.girdIcon ? (\n <FontAwesomeIcon\n icon={props.girdIcon}\n style={{ marginRight: 5, marginLeft: 5 }}\n />\n ) : (\n <></>\n )}\n <Typography variant=\"h5\">\n {props?.gridTitle\n ? capitalizeFirstLetter(t(props?.gridTitle))\n : \"\"}\n </Typography>\n </Box>\n </Box>\n ) : (\n <></>\n )}\n\n {props?.gridLoadParameters &&\n props?.gridLoadParameters.length > 0 &&\n props?.gridLoadParametersValues &&\n props?.setGridLoadParametersValues ? (\n <Accordion defaultExpanded sx={{ width: \"100%\" }}>\n <AccordionSummary expandIcon={<GridExpandMoreIcon />}>\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <FontAwesomeIcon\n style={{ marginLeft: 5, marginRight: 5 }}\n icon=\"search\"\n />\n <Typography component=\"span\">Filters</Typography>\n </Box>\n </AccordionSummary>\n <AccordionDetails>\n <Box>\n <TemplateForm\n saveButtonSpecs={{\n label: t(\"SEARCH_BTN_LABEL\"),\n icon: \"search\",\n actionButtonVariant: \"outlined\",\n actionButtonColor: \"success\",\n }}\n cancelButtonSpecs={{\n label: t(\"RESET_BTN_LABEL\"),\n icon: \"eraser\",\n actionButtonVariant: \"outlined\",\n actionButtonColor: \"error\",\n }}\n apiActions={{\n deleteRecordById: async () => {\n return true;\n },\n saveRecord: async (params) => {\n if (params != undefined) {\n props.setGridLoadParametersValues(params);\n } else {\n props.setGridLoadParametersValues({});\n }\n props.apiActions.reloadData(params);\n },\n reloadData: async () => {},\n loadRecordById: async () => {},\n }}\n elements={props.gridLoadParameters}\n />\n </Box>\n </AccordionDetails>\n </Accordion>\n ) : (\n <></>\n )}\n {props?.attachment ? (\n <AttachmentWindow>\n <AttachmentPanel\n attachmentCode={props.attachment.attachmentCode}\n refKey={selectedRecord[props?.keyColumnName || \"id\"]}\n enableAttachment={attachmentPanelEnabledForRecord}\n />\n </AttachmentWindow>\n ) : (\n <></>\n )}\n {props?.workFlowDocumentCode ? (\n <WorkFlowWindow>\n <WorkflowDocumentPanel\n workFlowDocumentCode={props.workFlowDocumentCode}\n refDocumentId={selectedRecord[props?.keyColumnName || \"id\"]}\n postActionCallBk={() => {\n setWorkFlowWindowState(false);\n props.apiActions.reloadData(props.gridLoadParametersValues);\n }}\n cancelActionCallBk={() => {\n setWorkFlowWindowState(false);\n props.apiActions.reloadData(props.gridLoadParametersValues);\n }}\n />\n </WorkFlowWindow>\n ) : (\n <></>\n )}\n <DataGridPremium\n {...props?.muiProps}\n slots={{ toolbar: TemplateGridTopBar }}\n slotProps={{\n toolbar: {\n templateProps: {\n ...props,\n rowSelectionModel: rowSelectionModel,\n data: props?.data,\n },\n handleCreateNewRecord,\n clearGridState,\n } as any,\n }}\n getRowId={(record: any) => {\n return record[keyColumnName];\n }}\n showToolbar={true}\n rows={props?.data}\n columns={adjustedColumns}\n checkboxSelection\n editMode=\"row\"\n onRowEditStop={(params, event) => {\n if (params.reason === \"rowFocusOut\") {\n event.defaultMuiPrevented = true;\n }\n }}\n rowModesModel={\n props.editMode.editMode == \"row\" ? rowModesModel : undefined\n }\n onRowModesModelChange={\n props.editMode.editMode == \"row\"\n ? handleRowModesModelChange\n : undefined\n }\n rowGroupingColumnMode=\"multiple\"\n processRowUpdate={processRowUpdate}\n rowSelectionModel={rowSelectionModel}\n onRowSelectionModelChange={handleRowSelection}\n columnVisibilityModel={columnVisibilityModel}\n onColumnVisibilityModelChange={handleColumnVisibilityChange}\n onColumnOrderChange={handleColumnOrderChange}\n // onColumnWidthChange={handleColumnWidthChange}\n rowGroupingModel={gridRowGroupingModel}\n onRowGroupingModelChange={(model: GridRowGroupingModel) => {\n handleRowGroupChange(model);\n }}\n // pinnedColumns={pinnedColumns}\n // onPinnedColumnsChange={handlePinnedColumnsChange}\n sx={{ width: \"100%\" }}\n />\n </>\n );\n};\n\nexport default TemplateGrid;\n","import { useSelector } from \"react-redux\";\nimport { TemplateGridColDef } from \"../components\";\nimport useAxios from \"./useAxios\";\n\nconst useLookupGridColumn = () => {\n const { handleGetRequest } = useAxios();\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const getLookupOptions = async (lookupType: string) => {\n let options = [];\n await handleGetRequest({\n endPointURI: \"api/v1/public/system/lookup\",\n showMask: true,\n parameters: { lookupType },\n successCallBkFn: (response: any) => {\n options = response.data;\n },\n });\n return options;\n };\n const generateLookupGridColumn = async (props: TemplateGridColDef) => {\n let options = await getLookupOptions(props.lookupType);\n return {\n ...props,\n options,\n displayField:\n AppLayout.appDirection === \"ltr\"\n ? \"lookupEnDisplay\"\n : \"lookupArDisplay\",\n valueField: \"lookupValue\",\n };\n };\n return { generateLookupGridColumn, getLookupOptions };\n};\n\nexport default useLookupGridColumn;\n","import { useEffect, useState } from \"react\";\nimport TemplateGrid from \"../DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../DataEntryTemplates/DataEntryTypes\";\n\ntype ExcelReportViewerProps = {\n reportData: Array<any>;\n setReportData: (data) => void;\n reloadReport: () => void;\n gridLoadParameters?: Array<FormElementProps>;\n gridLoadParametersValues?: { [key: string]: any };\n setGridLoadParametersValues?: any;\n};\n\nconst getGridColumnsFromRecord = (data: Array<any>) => {\n if (data.length === 0) {\n return [];\n }\n const formElements: Array<FormElementProps> = [];\n for (const key of Object.keys(data[0])) {\n const formElement: FormElementProps = {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: key,\n fieldName: key,\n fieldType: \"text\",\n },\n };\n formElements.push(formElement);\n }\n debugger;\n return formElements;\n};\n\nconst ExcelReportViewer: React.FC<ExcelReportViewerProps> = (props) => {\n const [data, setData] = useState([]);\n useEffect(() => {\n const newData = props.reportData.map((record, index) => {\n return { ...record, report_record_data_key: index };\n });\n setData(newData);\n }, [props.reportData]);\n return (\n <TemplateGrid\n data={data}\n disableDefaultAction={true}\n setData={props.setReportData}\n formElements={getGridColumnsFromRecord(props.reportData)}\n gridLoadParameters={props.gridLoadParameters}\n gridLoadParametersValues={props.gridLoadParametersValues}\n setGridLoadParametersValues={props.setGridLoadParametersValues}\n editMode={{ editMode: \"none\" }}\n girdIcon={\"file-excel\"}\n gridTitle=\"Report\"\n autoLoad={true}\n keyColumnName={\"report_record_data_key\"}\n hideInfoBar={true}\n apiActions={{\n deleteRecordById: async () => {\n return true;\n },\n loadRecordById: async () => {},\n reloadData: async () => {\n props.reloadReport();\n },\n saveRecord: async () => {},\n }}\n />\n );\n};\n\nexport default ExcelReportViewer;\n","import { useEffect, useState } from \"react\";\nimport {\n Accordion,\n AccordionDetails,\n AccordionSummary,\n Box,\n FontAwesomeIcon,\n FormElementProps,\n TemplateForm,\n Typography,\n} from \"../components\";\nimport { useTranslation } from \"react-i18next\";\n\nexport type EntityParameter = {\n parameterCode: string;\n parameterLabel: string;\n parameterValueFormat?: string;\n parameterValueField?: string;\n parameterDisplayField?: string;\n parameterDataset?: Array<any>;\n parameterDataQueryId?: number;\n hidden?: boolean;\n mandatory?: boolean;\n defaultValue?: any;\n parameterType:\n | \"text\"\n | \"number\"\n | \"date\"\n | \"datetime\"\n | \"combobox\"\n | \"checkbox\"\n | \"html\"\n | \"lookup\";\n};\n\nexport const getFormElementsFromParameters = (\n parameters: Array<EntityParameter>,\n parameterValues: any\n) => {\n const formElements: Array<FormElementProps> = [];\n for (const parameter of parameters) {\n const formElement: FormElementProps = {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: parameter?.parameterLabel,\n fieldName: parameter?.parameterCode,\n fieldType: parameter?.parameterType,\n hidden: parameter?.hidden,\n formProps: { fieldSize: { lg: 4, md: 6, sm: 12 } },\n required: parameter?.mandatory,\n defaultValue:\n parameterValues[parameter?.parameterCode] || parameter?.defaultValue,\n },\n };\n formElements.push(formElement);\n }\n return formElements;\n};\n\ninterface UseParameterPanelProps {\n parameters: Array<EntityParameter>;\n initialParameterValues?: any;\n}\n\nexport const useParameterPanel = (props: UseParameterPanelProps) => {\n console.log(\"useParameterPanel\", \"useParameterPanel called\");\n const [parametersValues, setParametersValues] = useState<any>({\n ...props?.initialParameterValues,\n });\n // const [panelElements, setPanelElements] = useState<Array<FormElementProps>>(\n // []\n // );\n const panelElements = getFormElementsFromParameters(\n props.parameters,\n parametersValues\n );\n // useEffect(() => {\n // setPanelElements(\n // getFormElementsFromParameters(props.parameters, parametersValues)\n // );\n // }, [props.parameters]);\n\n const ParameterPanel: React.FC<{\n searchBtnClickCallBk: (params: any) => Promise<void>;\n }> = ({ searchBtnClickCallBk }) => {\n const { t } = useTranslation();\n return (\n <Accordion defaultExpanded sx={{ width: \"100%\" }}>\n <AccordionSummary\n expandIcon={\n <FontAwesomeIcon\n icon={{ prefix: \"far\", iconName: \"square-caret-down\" }}\n />\n }\n >\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <FontAwesomeIcon\n style={{ marginLeft: 5, marginRight: 5 }}\n icon=\"search\"\n />\n <Typography component=\"span\">Filters</Typography>\n </Box>\n </AccordionSummary>\n <AccordionDetails>\n <Box>\n <TemplateForm\n saveButtonSpecs={{\n label: t(\"Filter\"),\n icon: \"search\",\n actionButtonVariant: \"outlined\",\n actionButtonColor: \"success\",\n }}\n cancelButtonSpecs={{\n label: t(\"RESET_BTN_LABEL\"),\n icon: \"eraser\",\n hidden: true,\n actionButtonVariant: \"outlined\",\n actionButtonColor: \"error\",\n }}\n actions={[\n {\n label: t(\"RESET_BTN_LABEL\"),\n icon: \"eraser\",\n isIdRequired: false,\n formActionProps: { enabled: true },\n actionFn: async (data, recordIdsToProcessActionOn) => {\n setParametersValues({});\n },\n },\n ]}\n apiActions={{\n deleteRecordById: async () => {\n return true;\n },\n saveRecord: async (params) => {\n if (params != undefined) {\n setParametersValues(params);\n } else {\n setParametersValues({});\n }\n if (searchBtnClickCallBk) {\n await searchBtnClickCallBk(parametersValues);\n }\n },\n reloadData: async () => {},\n loadRecordById: async () => {},\n }}\n elements={panelElements}\n />\n </Box>\n </AccordionDetails>\n </Accordion>\n );\n };\n return {\n ParameterPanel,\n parametersValues,\n setParametersValues,\n panelElements,\n };\n};\n","import { useEffect, useState } from \"react\";\nimport { useAxios } from \"../../../hooks\";\n\nimport { Box, IconButton } from \"@mui/material\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport ExcelReportViewer from \"./ExcelReportViewer\";\nimport { useParameterPanel } from \"../../../hooks/useParameterPanel\";\n\ntype ReportViewerState =\n | \"ERROR\"\n | \"WAITING_REPORT_CODE\"\n | \"LOADING_METADATA\"\n | \"WAITING_PARAMETER_INPUT\"\n | \"WAITING_RESULT\"\n | \"SHOWING_RESULT\";\n\ntype ReportViewerProps = {\n reportCode: string;\n resultMode: \"Request\" | \"App\";\n reportParametersValues?: { [key: string]: any };\n byPassParameterEntry?: boolean;\n jasperOutPutFileType?: \"pdf\" | \"word\" | \"excel\";\n};\n\nconst ReportViewer: React.FC<ReportViewerProps> = (props) => {\n const [blobUrl, setBlobUrl] = useState(null);\n const [errorMessage, setErrorMessage] = useState(null);\n const [excelReportData, setExcelReportData] = useState<Array<any>>([]);\n const [reportViewerState, setReportViewerState] = useState<ReportViewerState>(\n \"WAITING_REPORT_CODE\"\n );\n const { handleGetRequest, handlePostRequest, HandleDownloadHTTPPostPDF } =\n useAxios();\n const [reportInfo, setReportInfo] = useState<any>(null);\n const {\n ParameterPanel,\n parametersValues,\n panelElements,\n setParametersValues,\n } = useParameterPanel({\n parameters: reportInfo?.reportParameters || [],\n initialParameterValues: { ...props?.reportParametersValues },\n });\n const loadReportData = async () => {\n setReportViewerState(\"LOADING_METADATA\");\n await handleGetRequest({\n endPointURI: \"api/v1/public/report/metadata\",\n showMask: true,\n parameters: { reportCode: props.reportCode },\n successCallBkFn: (response: any) => {\n setReportInfo(response.data);\n if (\n props?.byPassParameterEntry === true ||\n response.data.reportParameters.length == 0\n ) {\n runReport(parametersValues);\n setReportViewerState(\"WAITING_RESULT\");\n } else {\n setReportViewerState(\"WAITING_PARAMETER_INPUT\");\n }\n },\n failureCallBkFn: (response) => {\n setErrorMessage(\n \"Failed loading report metadata ... contact your administrator\"\n );\n setReportViewerState(\"ERROR\");\n },\n });\n };\n\n const runReport = async (params) => {\n setReportViewerState(\"WAITING_RESULT\");\n if (reportInfo?.reportType === \"Excel\") {\n await handlePostRequest({\n endPointURI: \"api/v1/public/report/run\",\n showMask: true,\n data: {\n reportCode: props.reportCode,\n parameters: params,\n resultMode: props.resultMode,\n jasperOutPutFileType: props.jasperOutPutFileType,\n },\n successCallBkFn: (response: any) => {\n setReportViewerState(\"SHOWING_RESULT\");\n setExcelReportData(response.data);\n },\n });\n } else if (reportInfo?.reportType) {\n await HandleDownloadHTTPPostPDF({\n endPointURI: \"api/v1/public/report/run\",\n showMask: true,\n data: {\n reportCode: props.reportCode,\n parameters: params,\n resultMode: props.resultMode,\n jasperOutPutFileType: props.jasperOutPutFileType,\n },\n successCallBkFn: (response: any) => {\n setReportViewerState(\"SHOWING_RESULT\");\n const contentDisposition = response.headers[\"content-disposition\"];\n debugger;\n let filename = \"downloaded_file\";\n if (\n contentDisposition &&\n contentDisposition.indexOf(\"filename=\") !== -1\n ) {\n const match = contentDisposition.match(/filename=\"?([^\"]+)\"?/);\n if (match && match[1]) filename = match[1];\n }\n if (filename.includes(\"pdf\")) {\n const file = new Blob([response.data], { type: \"application/pdf\" });\n const url = URL.createObjectURL(file);\n setBlobUrl(url);\n } else {\n const blob = new Blob([response.data], {\n type: response.headers[\"content-type\"],\n });\n // Create a temporary anchor element\n const url = window.URL.createObjectURL(blob);\n const link = document.createElement(\"a\");\n link.href = url;\n // Optional: Try to get filename from response headers\n\n link.download = filename;\n document.body.appendChild(link);\n link.click();\n\n // Clean up\n document.body.removeChild(link);\n window.URL.revokeObjectURL(url);\n }\n },\n failureCallBkFn: (response) => {\n setErrorMessage(\n \"Failed To run report ... contact your administrator\"\n );\n setReportViewerState(\"ERROR\");\n },\n });\n }\n };\n\n useEffect(() => {\n if (props?.reportCode) {\n loadReportData();\n }\n }, [\n props.reportCode,\n props.byPassParameterEntry,\n props.reportParametersValues,\n props.jasperOutPutFileType,\n props.resultMode,\n ]);\n\n return (\n <>\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n width: \"100%\",\n }}\n >\n <Box sx={{ flex: 1, textAlign: \"center\", marginBottom: 1 }}>\n <FontAwesomeIcon\n icon={\n reportInfo?.reportType === \"Excel\" ? \"file-excel\" : \"file-pdf\"\n }\n color={reportInfo?.reportType === \"Excel\" ? \"darkgreen\" : \"darkred\"}\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n {reportInfo?.reportName}\n </Box>\n {reportInfo?.reportType != \"Excel\" ? (\n reportViewerState === \"SHOWING_RESULT\" ? (\n <>\n {props?.byPassParameterEntry === true ? (\n <></>\n ) : reportInfo?.reportParameters.length > 0 ? (\n <IconButton\n onClick={() => {\n setReportViewerState(\"WAITING_PARAMETER_INPUT\");\n }}\n >\n <FontAwesomeIcon icon=\"filter\" />\n </IconButton>\n ) : (\n <></>\n )}\n <IconButton>\n <FontAwesomeIcon\n icon=\"refresh\"\n onClick={() => {\n runReport(parametersValues);\n }}\n />\n </IconButton>\n </>\n ) : (\n <></>\n )\n ) : (\n <></>\n )}\n </Box>\n <Box\n sx={{\n flexGrow: 1,\n width: \"100%\",\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n }}\n >\n {reportViewerState === \"WAITING_PARAMETER_INPUT\" &&\n reportInfo?.reportType != \"Excel\" ? (\n <ParameterPanel searchBtnClickCallBk={runReport} />\n ) : reportViewerState === \"SHOWING_RESULT\" ||\n ((reportViewerState === \"WAITING_PARAMETER_INPUT\" ||\n reportViewerState === \"WAITING_RESULT\") &&\n reportInfo?.reportType === \"Excel\") ? (\n reportInfo?.reportType === \"Excel\" ? (\n <ExcelReportViewer\n reportData={excelReportData}\n setReportData={setExcelReportData}\n reloadReport={async () => {\n runReport(parametersValues);\n }}\n gridLoadParameters={panelElements}\n gridLoadParametersValues={parametersValues}\n setGridLoadParametersValues={setParametersValues}\n />\n ) : (\n <iframe\n src={blobUrl}\n width=\"100%\"\n height=\"100%\"\n title=\"PDF Preview\"\n style={{ border: \"1px solid #ccc\", marginTop: \"20px\" }}\n ></iframe>\n )\n ) : reportViewerState === \"ERROR\" ? (\n <Box\n sx={{\n display: \"flex\",\n flex: 1,\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <FontAwesomeIcon\n icon=\"circle-exclamation\"\n color=\"darkred\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n {errorMessage}\n </Box>\n ) : (\n <></>\n )}\n </Box>\n </>\n );\n};\n\nexport default ReportViewer;\n","import { useEffect, useState } from \"react\";\nimport { useAxios, useSession, useWindow } from \"../../../hooks\";\nimport {\n Avatar,\n Box,\n Button,\n Divider,\n Grid2,\n IconButton,\n Paper,\n} from \"@mui/material\";\nimport TemplateTextField from \"../DataEntryTemplates/TemplateDataForm/FormFields/TemplateTextField\";\nimport ComboBox from \"../DataEntryTemplates/TemplateDataForm/FormFields/ComboBox\";\nimport { useSelector } from \"react-redux\";\nimport { useTranslation } from \"react-i18next\";\nimport WorkflowDocumentTimeLine from \"./WorkflowDocumentTimeLine\";\nimport { toast } from \"react-toastify\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport ReportViewer from \"../report/ReportViewer\";\nimport AttachmentImageViewer from \"../attachment/AttachmentImageViewer\";\nimport { useNavigate } from \"react-router-dom\";\n\nexport type WorkflowDocumentPanelProps = {\n workFlowDocumentCode: string;\n refDocumentId: any;\n postActionCallBk?: () => void;\n cancelActionCallBk?: () => void;\n};\n\nexport type workflowDocumentAction = {\n id: number;\n document_action_code: string;\n document_action_ar_name: string;\n document_action_en_name: string;\n post_action_endpoint?: string;\n pre_action_endpoint?: string;\n next_document_status_id?: number;\n next_action_takers?: Array<person>;\n require_comment: any;\n};\n\nexport type person = {\n id: number;\n email: string;\n employeeArName: string;\n employeeEnName: string;\n mobileNumber: string;\n username: string;\n};\n\nexport type workflowDocumentActionHistory = {\n id: number;\n actionTime: string;\n actionMethod: string;\n actionComment: string;\n documentActionArName: string;\n documentActionEnName: string;\n employeeArName: string;\n employeeEnName: string;\n personId: number;\n};\n\ntype WorkflowDocumentInfo = {\n workflowDocument: any;\n referencedDocument: any;\n workflowDocumentReport: any;\n workflowDocumentStatus: any;\n actionsHistory: Array<workflowDocumentActionHistory>;\n nextActions: Array<workflowDocumentAction>;\n nextActionTakers: any;\n};\n\nconst WorkflowDocumentPanel: React.FC<WorkflowDocumentPanelProps> = (props) => {\n const navigate = useNavigate();\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const { isUserAuthorized, UserInfo } = useSession();\n const { handleGetRequest, handlePostRequest } = useAxios();\n const [action, setAction] = useState<workflowDocumentAction>(null);\n const [authorizedActions, setAuthorizedActions] = useState<\n Array<workflowDocumentAction>\n >([]);\n const { t } = useTranslation();\n const [actionComment, setActionComment] = useState(null);\n const [workflowDocumentInfo, setWorkflowDocumentInfo] =\n useState<WorkflowDocumentInfo>({\n referencedDocument: null,\n workflowDocumentReport: null,\n workflowDocument: null,\n workflowDocumentStatus: null,\n actionsHistory: [],\n nextActionTakers: null,\n nextActions: [],\n });\n const { Window: ReporTViewWindow, setWindowState: setReportViewWindowState } =\n useWindow({\n windowTitle:\n AppLayout.appDirection === \"ltr\"\n ? workflowDocumentInfo?.workflowDocument &&\n workflowDocumentInfo?.referencedDocument\n ? `${workflowDocumentInfo?.workflowDocument?.documentEnName} # ${\n workflowDocumentInfo?.referencedDocument[\n workflowDocumentInfo?.workflowDocument?.documentNumberField\n ]\n }`\n : \"Document\"\n : workflowDocumentInfo?.workflowDocument &&\n workflowDocumentInfo?.referencedDocument\n ? `${workflowDocumentInfo?.workflowDocument?.documentArName} # ${\n workflowDocumentInfo?.referencedDocument[\n workflowDocumentInfo?.workflowDocument?.documentNumberField\n ]\n }`\n : \"وثيقة\",\n windowIcon: \"eye\",\n width: \"80%\",\n });\n const loadWorkFlowDocumentInfo = async () => {\n await handleGetRequest({\n endPointURI: \"api/v1/public/workflow/doc/info\",\n showMask: true,\n parameters: {\n workflowDocumentCode: props.workFlowDocumentCode,\n refDocumentId: props.refDocumentId,\n },\n successCallBkFn: (response: any) => {\n setWorkflowDocumentInfo(response.data);\n },\n failureCallBkFn: () => {\n setWorkflowDocumentInfo({\n referencedDocument: null,\n workflowDocumentReport: null,\n workflowDocument: null,\n workflowDocumentStatus: null,\n actionsHistory: [],\n nextActions: [],\n nextActionTakers: null,\n });\n },\n });\n };\n\n const validateBeforeProcessWorkflowDocumentAction = async () => {\n if (\n action === undefined ||\n action === null ||\n action?.id === undefined ||\n action?.id === null\n ) {\n toast.error(\"You must select action to process\");\n return;\n }\n if (\n (action.require_comment === true ||\n action.require_comment === 1 ||\n action.require_comment === \"true\") &&\n (actionComment === null || actionComment === \"\")\n ) {\n toast.error(\"You must enter comment for the action to be processed\");\n return;\n }\n if (action?.pre_action_endpoint) {\n await handlePostRequest({\n endPointURI: action.pre_action_endpoint,\n showMask: true,\n loadingMessage: \"Processing pre action validation ... please wait\",\n parameters: {\n refDocumentId: props.refDocumentId,\n actionId: action.id,\n },\n successCallBkFn: () => {\n processWorkflowDocumentAction();\n },\n });\n return;\n }\n processWorkflowDocumentAction();\n };\n const processWorkflowDocumentAction = async () => {\n await handlePostRequest({\n endPointURI: \"api/v1/public/workflow/doc/action\",\n showMask: true,\n data: {\n workflowDocumentId: workflowDocumentInfo?.workflowDocument?.id,\n refDocumentId: props.refDocumentId,\n actionId: action.id,\n refDocumentStatus:\n workflowDocumentInfo?.workflowDocumentStatus?.documentStatusCode,\n actionComment: actionComment,\n },\n successCallBkFn: async (response) => {\n if (action?.post_action_endpoint) {\n await handlePostRequest({\n endPointURI: action.post_action_endpoint,\n showMask: true,\n loadingMessage: \"Processing post action process ... please wait\",\n parameters: {\n refDocumentId: props.refDocumentId,\n actionId: action.id,\n },\n successCallBkFn: () => {\n loadWorkFlowDocumentInfo();\n if (props?.postActionCallBk) {\n props.postActionCallBk();\n }\n },\n });\n return;\n }\n loadWorkFlowDocumentInfo();\n },\n });\n };\n\n const adjustAuthorizedActions = () => {\n if (workflowDocumentInfo?.nextActions?.length > 0) {\n setAuthorizedActions(\n workflowDocumentInfo.nextActions.filter((action) => {\n if (\n !(\n workflowDocumentInfo?.workflowDocumentStatus\n ?.nextActionTakersAuthority ||\n workflowDocumentInfo?.nextActionTakers\n )\n ) {\n return true;\n }\n if (\n workflowDocumentInfo?.workflowDocumentStatus\n ?.nextActionTakersAuthority\n ) {\n if (\n isUserAuthorized(\n workflowDocumentInfo.workflowDocumentStatus\n .nextActionTakersAuthority\n )\n ) {\n return true;\n }\n }\n if (workflowDocumentInfo?.nextActionTakers) {\n for (const actionTaker of workflowDocumentInfo.nextActionTakers) {\n if (\n UserInfo?.username === actionTaker?.username ||\n UserInfo?.username === actionTaker?.USERNAME\n ) {\n return true;\n }\n }\n }\n return false;\n })\n );\n } else {\n setAuthorizedActions([]);\n }\n };\n\n useEffect(() => {\n if (props.refDocumentId && props.workFlowDocumentCode) {\n loadWorkFlowDocumentInfo();\n }\n }, [props.refDocumentId, props.workFlowDocumentCode]);\n\n useEffect(() => {\n if (workflowDocumentInfo?.nextActions) {\n adjustAuthorizedActions();\n } else {\n setAuthorizedActions([]);\n }\n }, [workflowDocumentInfo.nextActions, workflowDocumentInfo.nextActionTakers]);\n return (\n <>\n {workflowDocumentInfo?.workflowDocumentReport?.id ? (\n <ReporTViewWindow>\n <ReportViewer\n reportCode={\n workflowDocumentInfo?.workflowDocumentReport?.reportCode\n }\n resultMode=\"App\"\n byPassParameterEntry={true}\n reportParametersValues={{ doc_id: props.refDocumentId + \"\" }}\n />\n </ReporTViewWindow>\n ) : (\n <></>\n )}\n\n {workflowDocumentInfo?.workflowDocument ? (\n <Box\n sx={{\n width: \"100%\",\n textAlign: \"center\",\n fontSize: 20,\n fontWeight: \"bold\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <IconButton\n onClick={() => {\n navigate(-1, { replace: true });\n }}\n >\n <FontAwesomeIcon icon=\"arrow-left\" />\n </IconButton>\n <Box sx={{ flex: 1 }}></Box>\n <FontAwesomeIcon\n icon=\"file\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n {AppLayout.appDirection === \"ltr\"\n ? `${workflowDocumentInfo?.workflowDocument?.documentEnName} # ${\n workflowDocumentInfo?.referencedDocument[\n workflowDocumentInfo?.workflowDocument?.documentNumberField\n ]\n }`\n : `${workflowDocumentInfo?.workflowDocument?.documentArName} # ${\n workflowDocumentInfo?.referencedDocument[\n workflowDocumentInfo?.workflowDocument?.documentNumberField\n ]\n }`}\n {workflowDocumentInfo?.workflowDocumentStatus\n ? AppLayout.appDirection === \"ltr\"\n ? ` ( ${workflowDocumentInfo?.workflowDocumentStatus?.documentStatusEnName} )`\n : ` ( ${workflowDocumentInfo?.workflowDocumentStatus?.documentStatusArName} )`\n : \"\"}\n <Box sx={{ flex: 1 }}></Box>\n {workflowDocumentInfo?.workflowDocumentReport?.id ? (\n <Button\n onClick={() => {\n setReportViewWindowState(true);\n }}\n variant=\"outlined\"\n startIcon={<FontAwesomeIcon icon=\"eye\" />}\n >\n {t(\"VIEW_LABEL\")}\n </Button>\n ) : (\n <></>\n )}\n </Box>\n ) : (\n <></>\n )}\n\n <Box\n sx={{\n flex: 1,\n width: \"100%\",\n overflow: \"hidden\",\n display: \"flex\",\n // flexDirection: \"column\",\n }}\n >\n {authorizedActions?.length > 0 ? (\n <Paper\n sx={{\n padding: 2,\n display: \"flex\",\n flex: 1,\n margin: 1,\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n overflow: \"hidden\",\n }}\n >\n <ComboBox\n sx={{ marginBottom: 2, width: 400 }}\n label={t(\"WE_AVAILABLE_ACTIONS_LABEL\")}\n displayField={\n AppLayout.appDirection === \"ltr\"\n ? \"document_action_en_name\"\n : \"document_action_ar_name\"\n }\n valueField={\"id\"}\n value={action?.id}\n options={authorizedActions}\n onChangeCallBack={(v, selectedRecord) => {\n setAction(selectedRecord);\n }}\n />\n {/* <ComboBox\n sx={{ marginBottom: 2, width: 400 }}\n label={t(\"WE_NEXT_APPROVER_LABEL\")}\n displayField={\n AppLayout.appDirection === \"ltr\"\n ? \"employeeEnName\"\n : \"employeeArName\"\n }\n valueField={\"id\"}\n value={nextActionTaker?.id}\n options={action?.nextActionTakers || []}\n onChangeCallBack={(v, selectedRecord) => {\n setNextActionTaker(selectedRecord);\n }}\n /> */}\n <TemplateTextField\n sx={{ width: 400 }}\n rows={3}\n value={actionComment}\n onChange={(event) => {\n setActionComment(event.target.value);\n }}\n multiline={true}\n label={t(\"WF_COMMENT_LABEL\")}\n />\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <Button\n color=\"success\"\n variant=\"contained\"\n sx={{ width: 200, m: 1 }}\n onClick={validateBeforeProcessWorkflowDocumentAction}\n >\n {t(\"WF_TAKE_ACTION_BTN_LABEL\")}\n </Button>\n {props?.cancelActionCallBk ? (\n <Button\n variant=\"contained\"\n sx={{ width: 200, m: 1 }}\n color=\"error\"\n onClick={() => {\n if (props?.cancelActionCallBk) {\n props.cancelActionCallBk();\n }\n }}\n >\n {t(\"WF_CANCEL_BTN_LABEL\")}\n </Button>\n ) : (\n <></>\n )}\n </Box>\n {workflowDocumentInfo?.nextActionTakers &&\n workflowDocumentInfo.nextActionTakers.length > 0 ? (\n <>\n <Divider\n variant=\"fullWidth\"\n flexItem\n sx={{ marginTop: 1, marginBottom: 1 }}\n >\n <Box\n sx={{\n width: \"100%\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontSize: 18,\n fontWeight: \"bold\",\n }}\n >\n <FontAwesomeIcon\n icon=\"users\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />{\" \"}\n {t(\"WF_WAITING_FOR_LABEL\")}\n </Box>\n </Divider>\n\n <Box\n sx={{\n flex: 1,\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n overflow: \"auto\",\n padding: 1,\n width: \"100%\",\n }}\n >\n {workflowDocumentInfo.nextActionTakers.map(\n (nextActionTaker: any) => {\n return (\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n border: \"1px dotted black\",\n width: 400,\n marginBottom: 2,\n padding: 2,\n }}\n >\n <AttachmentImageViewer\n showAsAvatar={true}\n attachmentCode=\"EMPLOYEE_PHOTOS\"\n refKey={nextActionTaker?.id || \"0\"}\n style={{\n marginRight: 2,\n marginLeft: 2,\n width: 60,\n height: 60,\n }}\n />\n <Box\n sx={{\n flex: 2,\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"flex-start\",\n justifyContent: \"center\",\n }}\n >\n <div>\n {AppLayout.appDirection === \"ltr\"\n ? nextActionTaker?.employee_en_name\n : nextActionTaker?.employee_ar_name}\n </div>\n <div>\n {nextActionTaker?.email ? (\n <>\n <FontAwesomeIcon\n icon=\"envelope\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n {nextActionTaker?.email}\n </>\n ) : (\n <></>\n )}\n </div>\n <div>\n {nextActionTaker?.mobile_number ? (\n <>\n <FontAwesomeIcon\n icon=\"mobile\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n {nextActionTaker?.mobile_number}\n </>\n ) : (\n <></>\n )}\n </div>\n </Box>\n </Box>\n );\n }\n )}\n </Box>\n </>\n ) : (\n <></>\n )}\n </Paper>\n ) : (\n <></>\n )}\n {workflowDocumentInfo?.actionsHistory.length > 0 ? (\n <WorkflowDocumentTimeLine\n actionHistory={workflowDocumentInfo.actionsHistory}\n />\n ) : (\n <Paper\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n flexGrow: 1,\n padding: 2,\n margin: 1,\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <Box\n sx={{\n width: \"100%\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontSize: 18,\n fontWeight: \"bold\",\n }}\n >\n <FontAwesomeIcon\n icon=\"history\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n {t(\"WF_ACTION_HISTORY_LABEL\")}\n </Box>\n <Box\n sx={{\n flex: 1,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n No Action Log available\n </Box>\n </Paper>\n )}\n </Box>\n </>\n );\n};\n\nexport default WorkflowDocumentPanel;\n","import { Box } from \"@mui/system\";\nimport React, { useEffect, useState } from \"react\";\nimport * as z from \"zod\";\nimport { useForm } from \"react-hook-form\";\nimport { zodResolver } from \"@hookform/resolvers/zod\";\nimport { useParams } from \"react-router-dom\";\nimport { Button, Grid2, Icon, IconButton, Tooltip } from \"@mui/material\";\nimport { toast } from \"react-toastify\";\nimport FormElementGroup from \"./FormElementGroup\";\nimport FormElementField from \"./FormElementField\";\nimport FormAction from \"./FormAction\";\nimport { constructValidationSchema, getAllFields } from \"../DataEntryUtil\";\nimport {\n FormElementProps,\n RecordAction,\n TemplateFormProps,\n} from \"../DataEntryTypes\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { useTranslation } from \"react-i18next\";\nimport { useWindow } from \"../../../../hooks\";\nimport AttachmentPanel from \"../../attachment/AttachmentPanel\";\nimport WorkflowDocumentPanel from \"../../workflow/WorkflowDocumentPanel\";\n\nconst TemplateForm: React.FC<TemplateFormProps> = (\n props: TemplateFormProps\n) => {\n const { Window: AttachmentWindow, setWindowState: setAttachmentWindowState } =\n useWindow({\n windowTitle: \"Attachments\",\n windowIcon: \"paperclip\",\n width: \"fit-content\",\n height: \"fit-content\",\n minHeight: 500,\n minWidth: 400,\n });\n const { Window: WorkflowWindow, setWindowState: setWorkflowWindowState } =\n useWindow({\n windowTitle: \"Approvals\",\n windowIcon: \"stamp\",\n width: \"fit-content\",\n height: \"fit-content\",\n minHeight: 500,\n minWidth: 400,\n });\n const [attachmentPanelEnabledForRecord, setAttachmentPanelEnabledForRecord] =\n useState<boolean>(true);\n const { t } = useTranslation();\n const fields = getAllFields(props.elements);\n const initiallyHiddenFields = [];\n for (const field of fields) {\n if (field?.hidden) {\n initiallyHiddenFields.push(field.fieldName);\n }\n }\n const [hiddenFields, setHiddenFields] = useState<string[]>(\n initiallyHiddenFields\n );\n const initialValues: any = {};\n for (const element of props.elements) {\n if (\n element?.type === \"field\" &&\n element?.mode === \"props\" &&\n element?.props?.defaultValue\n ) {\n initialValues[element.props.fieldName] = element.props.defaultValue;\n }\n }\n const [disabledFields, setDisabledFields] = useState<string[]>([]);\n let formSchema = null;\n if (props?.validationSchema) {\n formSchema = props.validationSchema;\n } else {\n formSchema = z.object(constructValidationSchema(fields));\n }\n type FormData = z.infer<typeof formSchema>;\n const formManager = useForm<FormData>({\n resolver: zodResolver(formSchema),\n defaultValues: initialValues,\n });\n const formValues = formManager.watch();\n const pathParameters = useParams();\n const formRouteRecordIdParamName: any = props?.formRouteRecordIdParamName;\n\n const loadRecord = async () => {\n let idToLoad = null;\n if (props?.recordIdToEdit) {\n idToLoad = props.recordIdToEdit;\n } else if (\n formRouteRecordIdParamName &&\n pathParameters[formRouteRecordIdParamName]\n ) {\n idToLoad = pathParameters[formRouteRecordIdParamName];\n }\n if (idToLoad) {\n const retrievedRecord: any = await props.apiActions.loadRecordById(\n idToLoad\n );\n if (retrievedRecord) {\n formManager.reset({ ...retrievedRecord });\n if (props?.formValuesChangeCallBk) {\n props?.formValuesChangeCallBk(\n { ...retrievedRecord },\n formActions,\n formManager\n );\n }\n for (const field of fields) {\n if (\n field?.fieldType === \"combobox\" &&\n retrievedRecord[field.fieldName]\n ) {\n if (\n field?.comboboxValueDataType &&\n field?.comboboxValueDataType === \"string\"\n ) {\n formManager.setValue(\n field.fieldName,\n retrievedRecord[field.fieldName] + \"\"\n );\n } else {\n formManager.setValue(\n field.fieldName,\n retrievedRecord[field.fieldName]\n );\n }\n }\n }\n }\n } else {\n formManager.reset({});\n }\n };\n\n const saveRecord = async (record: any) => {\n if (props?.preSaveValidation && !props.preSaveValidation(record)) {\n return;\n }\n if (record) {\n const savedRecord: any = await props.apiActions.saveRecord(record);\n if (savedRecord) {\n formManager.reset({ ...savedRecord });\n if (props?.formSavedSuccessfullyCallBk) {\n props.formSavedSuccessfullyCallBk(savedRecord);\n }\n if (props?.formCloseCallBk) {\n props.formCloseCallBk();\n }\n }\n }\n };\n\n const formActions = {\n setFieldValue: (fieldName: string, fieldValue: any) => {\n formManager.setValue(fieldName, fieldValue);\n },\n hideField: (fieldName: string) => {\n setHiddenFields((oldValues) => {\n const newValues = [...oldValues, fieldName];\n return newValues;\n });\n },\n showField: (fieldName: string) => {\n setHiddenFields((oldValues) => {\n const newValues = oldValues.filter((x) => x !== fieldName);\n return newValues;\n });\n },\n disableField: (fieldName: string) => {\n setDisabledFields((oldValues) => {\n const newValues = [...oldValues, fieldName];\n return newValues;\n });\n },\n enableField: (fieldName: string) => {\n setDisabledFields((oldValues) => {\n const newValues = oldValues.filter((x) => x !== fieldName);\n return newValues;\n });\n },\n };\n\n useEffect(() => {\n loadRecord();\n }, [props?.recordIdToEdit]);\n\n useEffect(() => {\n if (props?.attachment && props?.attachment?.enableAttachFn) {\n setAttachmentPanelEnabledForRecord(\n props.attachment.enableAttachFn(formValues)\n );\n } else {\n setAttachmentPanelEnabledForRecord(true);\n }\n }, [formValues]);\n return (\n <>\n {props?.attachment ? (\n <AttachmentWindow>\n <AttachmentPanel\n attachmentCode={props.attachment.attachmentCode}\n refKey={formValues[props?.keyColumnName || \"id\"]}\n enableAttachment={attachmentPanelEnabledForRecord}\n />\n </AttachmentWindow>\n ) : (\n <></>\n )}\n {props?.workFlowDocumentCode ? (\n <WorkflowWindow>\n <WorkflowDocumentPanel\n workFlowDocumentCode={props.workFlowDocumentCode}\n refDocumentId={formValues[props?.keyColumnName || \"id\"]}\n postActionCallBk={() => {\n setWorkflowWindowState(false);\n loadRecord();\n }}\n cancelActionCallBk={() => {\n setWorkflowWindowState(false);\n }}\n />\n </WorkflowWindow>\n ) : (\n <></>\n )}\n\n <Box\n sx={{\n display: \"flex\",\n flex: 1,\n width: \"100%\",\n height: \"fit-content\",\n flexDirection: \"column\",\n alignItems: \"center\",\n overflow: \"auto\",\n }}\n >\n <Grid2 sx={{ width: \"100%\" }} container>\n {props.elements.map((formElement: FormElementProps, index) => {\n if (formElement.type === \"group\") {\n return (\n <FormElementGroup\n key={index}\n {...formElement.props}\n formManager={formManager}\n formValues={formValues}\n formActions={formActions}\n hiddenFields={hiddenFields}\n disabledFields={disabledFields}\n />\n );\n } else if (\n formElement.type === \"field\" &&\n formElement.mode === \"props\"\n ) {\n return (\n <FormElementField\n key={index}\n fieldInfo={formElement.props}\n formManager={formManager}\n formValues={formValues}\n formActions={formActions}\n hiddenFields={hiddenFields}\n disabledFields={disabledFields}\n formValuesChangeCallBk={props.formValuesChangeCallBk}\n />\n );\n } else if (\n formElement.type === \"field\" &&\n formElement.mode === \"node\"\n ) {\n return (\n <Grid2\n key={index}\n size={\n formElement?.props?.formProps?.fieldSize || {\n lg: 3,\n md: 6,\n xs: 12,\n }\n }\n sx={{ padding: 1, width: \"100%\" }}\n >\n <formElement.node\n formManager={formManager}\n formValues={formValues}\n />\n </Grid2>\n );\n }\n })}\n </Grid2>\n </Box>\n\n <Box\n sx={{\n display: \"flex\",\n width: \"100%\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n }}\n >\n {formValues[props?.keyColumnName || \"id\"] ? (\n props?.attachment ? (\n <Tooltip title=\"Attachments\">\n <IconButton\n onClick={() => {\n setAttachmentWindowState(true);\n }}\n >\n <FontAwesomeIcon icon=\"paperclip\" />\n </IconButton>\n </Tooltip>\n ) : null\n ) : null}\n {formValues[props?.keyColumnName || \"id\"] ? (\n props?.workFlowDocumentCode ? (\n <Tooltip title=\"Approvals\">\n <IconButton\n onClick={() => {\n setWorkflowWindowState(true);\n }}\n >\n <FontAwesomeIcon icon=\"stamp\" />\n </IconButton>\n </Tooltip>\n ) : null\n ) : null}\n {props?.actions ? (\n props.actions.map((action: RecordAction) => {\n if (action?.isIdRequired === false) {\n return <FormAction {...action} record={formValues} />;\n } else if (formValues[props?.keyColumnName || \"id\"]) {\n if (action?.formActionProps?.enabled === true) {\n return <FormAction {...action} record={formValues} />;\n } else {\n return <></>;\n }\n }\n })\n ) : (\n <></>\n )}\n <div style={{ flex: 1 }}></div>\n {props?.saveButtonSpecs?.hidden ? (\n <></>\n ) : (\n <Button\n variant={\n props?.saveButtonSpecs?.actionButtonVariant\n ? props.saveButtonSpecs.actionButtonVariant\n : \"contained\"\n }\n sx={{ m: 1 }}\n startIcon={\n props?.saveButtonSpecs?.icon ? (\n <FontAwesomeIcon icon={props.saveButtonSpecs.icon} />\n ) : null\n }\n color={\n props?.saveButtonSpecs?.actionButtonColor\n ? props.saveButtonSpecs.actionButtonColor\n : \"primary\"\n }\n onClick={formManager.handleSubmit(\n (values) => {\n saveRecord(values);\n },\n (errors) => {\n toast.error(\n \"Form Data is not valid, make sure you have all field with valid data\"\n );\n console.log(\"form validation error\", errors);\n }\n )}\n >\n {t(props?.saveButtonSpecs?.label || \"SAVE_BTN_LABEL\")}\n </Button>\n )}\n\n {props?.cancelButtonSpecs?.hidden ? (\n <></>\n ) : (\n <Button\n variant={\n props?.cancelButtonSpecs?.actionButtonVariant\n ? props.cancelButtonSpecs.actionButtonVariant\n : \"contained\"\n }\n startIcon={\n props?.cancelButtonSpecs?.icon ? (\n <FontAwesomeIcon icon={props.cancelButtonSpecs.icon} />\n ) : null\n }\n color={\n props?.cancelButtonSpecs?.actionButtonColor\n ? props.cancelButtonSpecs.actionButtonColor\n : \"error\"\n }\n sx={{ m: 1 }}\n onClick={() => {\n if (props?.formCloseCallBk) {\n props.formCloseCallBk();\n }\n formManager.reset(initialValues);\n }}\n >\n {t(props?.cancelButtonSpecs?.label || \"CANCEL_BTN_LABEL\")}\n </Button>\n )}\n </Box>\n </>\n );\n};\n\nexport default TemplateForm;\n","import { useParams } from \"react-router-dom\";\nimport WorkflowDocumentPanel from \"./WorkflowDocumentPanel\";\n\nconst WorkflowRouteComponent: React.FC = () => {\n const { workflowDocumentCode, refDocumentId } = useParams();\n return (\n <WorkflowDocumentPanel\n workFlowDocumentCode={workflowDocumentCode}\n refDocumentId={refDocumentId}\n />\n );\n};\n\nexport default WorkflowRouteComponent;\n","import { BarChart } from \"@mui/x-charts\";\nimport { WidgetProps } from \"../DashboardViewer\";\n\n\nconst TemplateBarChart: React.FC<WidgetProps> = (props) => {\n return (\n <BarChart\n dataset={props.data}\n xAxis={[\n {\n dataKey: props.valueField,\n scaleType: \"band\",\n label: props.valueLabel,\n },\n ]}\n series={props.labelField?.split(\",\").map((labelField) => {\n return { dataKey: labelField, label: labelField };\n })}\n />\n );\n};\n\nexport default TemplateBarChart;\n","import { Box, Paper, Typography } from \"@mui/material\";\nimport { SingleRecordWidgetProps } from \"../DashboardViewer\";\n\n\nconst TemplateDataCard: React.FC<SingleRecordWidgetProps> = (props: any) => {\n return (\n <Paper\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n height: 150,\n padding: 1,\n flexGrow: 1,\n justifyContent: \"center\",\n alignItems: \"center\",\n }}\n >\n <Box\n sx={{\n display: \"flex\",\n width: \"100%\",\n justifyContent: \"space-evenly\",\n alignItems: \"center\",\n }}\n >\n <div>{props.record[props.valueField]}</div>\n </Box>\n <Typography sx={{ fontSize: 16, fontWeight: \"bold\" }}>\n {props.record[props.labelField]}\n </Typography>\n </Paper>\n );\n};\n\nexport default TemplateDataCard;\n","import { Gauge } from \"@mui/x-charts\";\nimport { SingleRecordWidgetProps } from \"../DashboardViewer\";\nimport { Typography } from \"@mui/material\";\n\nconst TemplateGauge: React.FC<SingleRecordWidgetProps> = (props: any) => {\n return (\n <>\n <Typography sx={{ fontSize: 16, fontWeight: \"bold\" }}>\n {props.record[props.labelField]}\n </Typography>\n <Gauge\n width={200}\n height={200}\n value={props.record[props.valueField]}\n valueMax={props.total}\n />\n </>\n );\n};\n\nexport default TemplateGauge;\n","import { LineChart } from \"@mui/x-charts\";\nimport { WidgetProps } from \"../DashboardViewer\";\n\nconst TemplateLineChart: React.FC<WidgetProps> = (props) => {\n return (\n <LineChart\n dataset={props.data}\n xAxis={[\n {\n dataKey: props.valueField,\n scaleType: \"band\",\n label: props.valueLabel,\n },\n ]}\n series={props.labelField?.split(\",\").map((labelField) => {\n return { dataKey: labelField, label: labelField };\n })}\n />\n );\n};\n\nexport default TemplateLineChart;\n","import * as React from \"react\";\nimport LinearProgress, {\n LinearProgressProps,\n} from \"@mui/material/LinearProgress\";\nimport Typography from \"@mui/material/Typography\";\nimport Box from \"@mui/material/Box\";\nimport { SingleRecordWidgetProps } from \"../DashboardViewer\";\n\nfunction LinearProgressWithLabel(\n props: LinearProgressProps & { value: number }\n) {\n return (\n <Box sx={{ display: \"flex\", alignItems: \"center\" }}>\n <Box sx={{ width: \"100%\", mr: 1 }}>\n <LinearProgress variant=\"determinate\" {...props} />\n </Box>\n <Box sx={{ minWidth: 35 }}>\n <Typography\n variant=\"body2\"\n sx={{ color: \"text.secondary\" }}\n >{`${Math.round(props.value)}%`}</Typography>\n </Box>\n </Box>\n );\n}\n\nconst TemplateLineProgress: React.FC<SingleRecordWidgetProps> = (\n props: any\n) => {\n return (\n <Box sx={{ width: \"100%\" }}>\n <Typography sx={{ fontSize: 16, fontWeight: \"bold\" }}>\n {props.record[props.labelField]}\n </Typography>\n <LinearProgressWithLabel\n value={100 * (props.record[props.valueField] / props.total)}\n />\n </Box>\n );\n};\n\nexport default TemplateLineProgress;\n","import { PieChart } from \"@mui/x-charts/PieChart\";\nimport { WidgetProps } from \"../DashboardViewer\";\n\nconst TemplatePieChart: React.FC<WidgetProps> = (props) => {\n // construct data object\n const chartData = props.data.map((record: any, index: any) => {\n return {\n id: index,\n value: record[props.valueField],\n label: record[props.labelField] + \"\",\n };\n });\n return (\n <PieChart\n series={[\n {\n data: chartData,\n },\n ]}\n />\n );\n};\n\nexport default TemplatePieChart;\n","import { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { WidgetType } from \"../../administration/dev/WidgetGrid\";\nimport { Backdrop, Box, CircularProgress, Grid2 } from \"@mui/material\";\nimport { useEffect, useState } from \"react\";\nimport LoadingMask from \"../../common/LoadingMask\";\nimport { useTranslation } from \"react-i18next\";\nimport { useSelector } from \"react-redux\";\nimport { useAxios } from \"../../../hooks\";\nimport TemplateLineChart from \"./charts/TemplateLineChart\";\nimport TemplateBarChart from \"./charts/TemplateBarChart\";\nimport TemplatePieChart from \"./charts/TemplatePieChart\";\nimport TemplateDataCard from \"./charts/TemplateDataCard\";\nimport TemplateGauge from \"./charts/TemplateGauge\";\nimport TemplateLineProgress from \"./charts/TemplateLineProgress\";\n\nexport type Widget = {\n loadWidget: boolean;\n loadCounter: number;\n widgetName: string;\n widgetDescription: string;\n title: string;\n icon: any;\n dataQueryId: number;\n widgetType: WidgetType;\n width: any;\n height: any;\n horizontalAxisField: any;\n horizontalAxisLabel: any;\n verticalAxisField: string;\n verticalAxisLabel: string;\n seriesKeys: any;\n parameterValues: {\n [key: string]: any;\n };\n};\n\nconst WidgetViewer: React.FC<Widget> = (props) => {\n const [isWidgetLoading, setWidgetLoading] = useState(true);\n const [data, setData] = useState([]);\n const { handleGetRequest } = useAxios();\n const getWidgetData = async () => {\n setWidgetLoading(true);\n await handleGetRequest({\n endPointURI: \"api/v1/dev/query/result\",\n showMask: false,\n parameters: {\n queryId: props.dataQueryId,\n ...props.parameterValues,\n },\n successCallBkFn: (response) => {\n setWidgetLoading(false);\n setData(response.data);\n },\n failureCallBkFn: () => {\n setWidgetLoading(false);\n setData([]);\n },\n });\n };\n useEffect(() => {\n if (props.loadWidget) {\n getWidgetData();\n } else {\n setWidgetLoading(false);\n }\n }, [props.loadWidget, props.loadCounter]);\n\n let total = 0;\n if (data.length == 1) {\n total = 100;\n } else {\n if (\n props.widgetType === \"CircularProgress\" ||\n props.widgetType === \"LinearProgress\"\n ) {\n for (const record of data) {\n total += record[props.verticalAxisField];\n }\n }\n }\n\n return (\n <>\n {props.widgetType === \"LineChart\" ||\n props.widgetType === \"PieChart\" ||\n props.widgetType === \"ColumnChart\" ? (\n <Box>\n <FontAwesomeIcon\n style={{ marginRight: 10, marginLeft: 10 }}\n icon={props?.icon || \"chart-pie\"}\n />\n {props?.title}\n </Box>\n ) : (\n <></>\n )}\n\n <Box\n sx={{\n flex: 1,\n padding: 1,\n height: \"90%\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n width: \"90%\",\n }}\n >\n {isWidgetLoading ? (\n <>\n <FontAwesomeIcon\n icon={{ prefix: \"fas\", iconName: \"arrows-spin\" }}\n style={{ marginRight: 10, marginLeft: 10 }}\n spin\n size=\"2x\"\n />\n <div>Loading</div>\n </>\n ) : props.widgetType === \"ColumnChart\" ? (\n <TemplateBarChart\n data={data}\n widgetTitle={props.title}\n labelField={props.verticalAxisField}\n valueField={props.horizontalAxisField}\n valueLabel={props.horizontalAxisLabel}\n widgetType=\"Line\"\n />\n ) : props.widgetType === \"LineChart\" ? (\n <TemplateLineChart\n data={data}\n widgetTitle={props.title}\n labelField={props.verticalAxisField}\n valueField={props.horizontalAxisField}\n valueLabel={props.horizontalAxisLabel}\n widgetType=\"Line\"\n />\n ) : props.widgetType === \"PieChart\" ? (\n <TemplatePieChart\n data={data}\n widgetTitle={props.title}\n labelField={props.horizontalAxisField}\n valueField={props.verticalAxisField}\n widgetType=\"Pie\"\n />\n ) : (\n <Grid2\n container\n sx={{\n width: \"100%\",\n alignItems: \"flex-start\",\n justifyContent: \"flex-start\",\n }}\n spacing={2}\n size={{ xs: 12 }}\n >\n <Grid2 size={{ xs: 12 }} sx={{ textAlign: \"center\" }}>\n {props.title}\n </Grid2>\n\n {data.map((record, index) => {\n if (props.widgetType === \"Card\") {\n return (\n <Grid2 size={{ md: 3, xs: 12 }}>\n <TemplateDataCard\n key={index}\n widgetTitle={\"\"}\n record={record}\n labelField={props.horizontalAxisField}\n valueField={props.verticalAxisField}\n />\n </Grid2>\n );\n } else if (props.widgetType === \"CircularProgress\") {\n return (\n <Grid2 size={{ md: 3, xs: 12 }}>\n <TemplateGauge\n key={index}\n widgetTitle={\"\"}\n record={record}\n labelField={props.horizontalAxisField}\n valueField={props.verticalAxisField}\n total={total}\n />\n </Grid2>\n );\n } else if (props.widgetType === \"LinearProgress\") {\n return (\n <Grid2 size={{ md: 3, xs: 12 }}>\n <TemplateLineProgress\n key={index}\n widgetTitle={\"\"}\n record={record}\n labelField={props.horizontalAxisField}\n valueField={props.verticalAxisField}\n total={total}\n />\n </Grid2>\n );\n }\n })}\n </Grid2>\n )}\n </Box>\n </>\n );\n};\n\nexport default WidgetViewer;\n","import { Box, Grid2, IconButton } from \"@mui/material\";\nimport { useEffect, useState } from \"react\";\nimport { useAxios } from \"../../../hooks\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport WidgetViewer, { Widget } from \"./WidgetViewer\";\nimport { useNavigate } from \"react-router-dom\";\nimport { useParameterPanel } from \"../../../hooks/useParameterPanel\";\n\ntype DashboardViewerProps = {\n dashboardCode: string;\n parameters?: { [key: string]: any };\n};\n\nexport interface WidgetProps {\n widgetTitle?: string;\n widgetType: \"Line\" | \"Bar\" | \"Pie\" | \"Card\" | \"Gauge\" | \"Progress\";\n data: any;\n valueLabel?: string;\n valueField: string; //x-axis field in case of line/bar chart\n labelField: string; //y-axis field in case of line/bar chart, it can also be a comma separated string for multiple series\n}\n\nexport interface SingleRecordWidgetProps {\n widgetTitle?: string;\n record: object;\n valueField: string;\n labelField: string;\n total?: number;\n}\n\ntype DashboardInfo = {\n dashboardCode: string;\n dashboardName: string;\n dashboardTitle: string;\n widgets: Array<Widget>;\n dashboardParameters: Array<any>;\n};\n\nconst DashboardViewer: React.FC<DashboardViewerProps> = (props) => {\n const [dashboardInfo, setDashboardInfo] = useState<DashboardInfo>({\n dashboardCode: \"\",\n dashboardName: \"\",\n dashboardTitle: \"\",\n dashboardParameters: [],\n widgets: [],\n });\n const { ParameterPanel, parametersValues } = useParameterPanel({\n parameters: dashboardInfo?.dashboardParameters || [],\n initialParameterValues: {},\n });\n const [loadCounter, setLoadCounter] = useState(0);\n const [loadDashboard, setLoadDashboard] = useState<boolean>(false);\n useEffect(() => {\n if (\n dashboardInfo.dashboardCode != undefined &&\n dashboardInfo.dashboardCode != null &&\n dashboardInfo.dashboardCode != \"\"\n ) {\n setLoadDashboard(false);\n let shouldLoadWidgets = true;\n if (dashboardInfo?.dashboardParameters.length > 0) {\n for (const parameter of dashboardInfo?.dashboardParameters) {\n if (parameter?.mandatory === true) {\n if (\n parametersValues[parameter.parameterCode] === undefined ||\n parametersValues[parameter.parameterCode] === null ||\n parametersValues[parameter.parameterCode] === \"\"\n ) {\n shouldLoadWidgets = false;\n break;\n }\n }\n }\n }\n if (shouldLoadWidgets) {\n setLoadDashboard(shouldLoadWidgets);\n }\n setLoadCounter(loadCounter + 1);\n }\n }, [dashboardInfo?.dashboardParameters, parametersValues]);\n const navigate = useNavigate();\n const { handleGetRequest, handlePostRequest } = useAxios();\n const loadDashboardInfo = async () => {\n await handleGetRequest({\n endPointURI: \"api/v1/dev/dashboard/metadata\",\n showMask: true,\n parameters: {\n dashboardCode: props.dashboardCode,\n },\n successCallBkFn: (response) => {\n setDashboardInfo(response.data);\n },\n failureCallBkFn: () => {\n setDashboardInfo(null);\n },\n });\n };\n useEffect(() => {\n if (props.dashboardCode) {\n loadDashboardInfo();\n }\n }, [props.dashboardCode, props.parameters]);\n return (\n <>\n {dashboardInfo ? (\n <>\n <Box\n sx={{\n fontSize: 20,\n fontWeight: \"bold\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <IconButton\n onClick={() => {\n navigate(-1, { replace: true });\n }}\n >\n <FontAwesomeIcon icon=\"arrow-left\" />\n </IconButton>\n <Box sx={{ flex: 1 }}></Box>\n <FontAwesomeIcon\n style={{ marginLeft: 10, marginRight: 10 }}\n icon={\"square-poll-vertical\"}\n />\n <Box>{dashboardInfo?.dashboardTitle}</Box>\n <Box sx={{ flex: 1 }}></Box>\n </Box>\n {dashboardInfo?.dashboardParameters.length > 0 ? (\n <ParameterPanel searchBtnClickCallBk={async (params) => {\n setLoadCounter(loadCounter + 1);\n }} />\n ) : (\n <></>\n )}\n <Grid2\n container\n spacing={1}\n sx={{\n // flexGrow: 1,\n height: \"fit-content\",\n overflowY: \"auto\",\n padding: 1,\n }}\n >\n {dashboardInfo?.widgets.map((widget, index) => {\n return (\n <Grid2\n key={index}\n sx={{\n alignItems: \"center\",\n justifyContent: \"center\",\n padding: 1,\n display: \"flex\",\n overflow: \"auto\",\n flexDirection:\n widget.widgetType != \"Card\" ? \"column\" : undefined,\n height: widget?.height || 300,\n }}\n size={{ md: widget?.width, sm: 12 }}\n >\n <WidgetViewer\n {...widget}\n parameterValues={parametersValues}\n loadWidget={loadDashboard}\n />\n </Grid2>\n );\n })}\n </Grid2>\n </>\n ) : (\n <Box\n sx={{\n flex: 1,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontSize: 24,\n fontWeight: \"bold\",\n }}\n >\n No Dashboard Found\n </Box>\n )}\n </>\n );\n};\n\nexport default DashboardViewer;\n","import { useParams } from \"react-router-dom\";\nimport DashboardViewer from \"./DashboardViewer\";\n\nconst DashboardRouteView: React.FC = () => {\n const { dashboardCode } = useParams();\n return <DashboardViewer dashboardCode={dashboardCode} />;\n};\n\nexport default DashboardRouteView;\n","import { useState } from \"react\";\nimport { useAxios, useSession } from \"../../hooks\";\nimport { ComboBox } from \"../templates\";\nimport { Box, Button } from \"@mui/material\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { UserSessionActions } from \"../../redux/features/common/UserSessionSlice\";\n\ntype ChangeOrgFormProps = {\n successChangeCallBackFn: () => void;\n};\n\nconst ChangeOrgForm: React.FC<ChangeOrgFormProps> = (props) => {\n const { UserSession } = useSession();\n const AppLayoutState = useSelector((state: any) => state.AppLayout);\n const dispatch = useDispatch();\n const { handlePostRequest } = useAxios();\n const [newOrgId, setNewOrgId] = useState(\n UserSession.value.currentOrganization.id\n );\n return (\n <Box\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n width: \"100%\",\n alignItems: \"center\",\n justifyContent: \"center\",\n padding: 1,\n }}\n >\n <ComboBox\n sx={{ width: \"100%\" }}\n displayField={\n AppLayoutState.appDirection === \"ltr\"\n ? \"organizationEnName\"\n : \"organizationArName\"\n }\n valueField=\"id\"\n label=\"\"\n options={UserSession.value.userOrganizations}\n value={newOrgId}\n onChangeCallBack={(value) => {\n setNewOrgId(value);\n }}\n />\n <Button\n sx={{ m: 1 }}\n variant=\"contained\"\n disabled={\n newOrgId == null ||\n newOrgId === UserSession.value.currentOrganization.id\n }\n onClick={async () => {\n await handlePostRequest({\n endPointURI: \"api/auth/changeCurrentOrg\",\n showMask: true,\n parameters: {\n username: UserSession.value.username,\n orgId: newOrgId,\n },\n data: {},\n successCallBkFn: (response) => {\n const UserSession = {\n ...response.data,\n isAuthenticated: true,\n };\n dispatch(UserSessionActions.setAuthenticated(UserSession));\n if (props.successChangeCallBackFn) {\n props.successChangeCallBackFn();\n }\n },\n });\n }}\n >\n Change Organization\n </Button>\n </Box>\n );\n};\n\nexport default ChangeOrgForm;\n","import { createSlice } from \"@reduxjs/toolkit\";\n\nexport const DRAWER_WIDTH = 350;\n\ninterface SideBarState {\n isOpened: boolean;\n}\n\nconst initialState: SideBarState = {\n isOpened: false,\n};\n\nconst SideBarSlice = createSlice({\n name: \"SideBar\",\n initialState,\n reducers: {\n toggleSideBarState: (state) => {\n state.isOpened = !state.isOpened;\n },\n setSideBarState: (state, action) => {\n state.isOpened = action.payload;\n },\n },\n});\n\nexport const { toggleSideBarState, setSideBarState } = SideBarSlice.actions;\nexport default SideBarSlice.reducer;\n","import { useEffect, useRef } from \"react\";\n\nexport default function useInterval(\n callback: () => void,\n delay: number | null\n) {\n const savedCallback = useRef<() => void>(callback);\n\n // Remember the latest callback\n useEffect(() => {\n savedCallback.current = callback;\n }, [callback]);\n\n // Set up the interval\n useEffect(() => {\n if (delay === null) return;\n\n const tick = () => savedCallback.current?.();\n\n const id = setInterval(tick, delay);\n return () => clearInterval(id);\n }, [delay]);\n}\n","import { IconProp } from \"@fortawesome/fontawesome-svg-core\";\nimport { Box, Button, Divider, keyframes, Typography } from \"@mui/material\";\nimport { useSelector } from \"react-redux\";\nimport { useNavigate } from \"react-router-dom\";\nimport { useAxios, useSession } from \"../../hooks\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { timeAgo } from \"../../util\";\n\nconst beatFade = keyframes`\n 0% { transform: scale(1); opacity: 1; }\n 25% { transform: scale(1); opacity: 0.6; }\n 50% { transform: scale(1); opacity: 1; }\n 75% { transform: scale(1); opacity: 0.6; }\n 100% { transform: scale(1); opacity: 1; }\n`;\n\nexport type Notification = {\n id: number;\n notificationIcon?: IconProp;\n notificationIconColor?: string;\n notificationEnText: string;\n notificationArText: string;\n notificationTextColor?: string;\n notificationAction?: \"NAVIGATION\";\n notificationActionPayload?: string;\n isNotified?: boolean;\n createTime: string;\n setOpen?: (state: boolean) => void;\n showDivider?: boolean;\n};\nconst NotificationItem: React.FC<Notification> = (notification) => {\n const navigate = useNavigate();\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const { handlePostRequest } = useAxios();\n const acknowledgeNotification = (notificationId) => {\n handlePostRequest({\n endPointURI: \"api/v1/public/notification/notified\",\n showMask: false,\n parameters: { notificationQueueId: notificationId },\n });\n };\n return (\n <>\n <Button\n fullWidth\n onClick={() => {\n if (\n notification?.notificationAction === \"NAVIGATION\" &&\n notification?.notificationActionPayload\n ) {\n navigate(notification.notificationActionPayload);\n }\n if (!notification?.isNotified) {\n acknowledgeNotification(notification.id);\n }\n if (notification?.setOpen) {\n notification.setOpen(false);\n }\n }}\n sx={{\n marginBottom: 1,\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n color: notification?.notificationTextColor,\n display: \"flex\",\n flexDirection: \"column\",\n cursor: \"pointer\",\n }}\n >\n <Box\n sx={{\n cursor: \"pointer\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n width: \"100%\",\n }}\n >\n {notification?.notificationIcon ? (\n <FontAwesomeIcon\n icon={notification.notificationIcon}\n style={{\n marginRight: 10,\n marginLeft: 10,\n color: notification?.notificationIconColor,\n }}\n />\n ) : (\n <></>\n )}\n {AppLayout.appDirection === \"ltr\"\n ? notification.notificationEnText\n : notification.notificationArText}\n <Box sx={{ flex: 1 }}></Box>\n {!notification?.isNotified ? (\n <Typography\n color=\"warning\"\n sx={{\n animation: `${beatFade} 2s infinite ease-in-out`,\n textTransform: \"none\",\n display: \"inline-block\",\n }}\n >\n <FontAwesomeIcon\n icon=\"bell\"\n style={{ marginRight: 5, marginLeft: 5 }}\n />\n {AppLayout.appDirection === \"ltr\" ? \"New\" : \"جديد\"}\n </Typography>\n ) : (\n <></>\n )}\n </Box>\n <Box\n sx={{\n width: \"100%\",\n fontSize: 12,\n display: \"flex\",\n justifyContent: \"flex-end\",\n alignItems: \"center\",\n cursor: \"pointer\",\n }}\n >\n <Box sx={{ marginRight: 1, marginLeft: 1 }}>\n {timeAgo(notification.createTime, AppLayout.appDirection)}\n </Box>\n <Box sx={{ flex: 1 }}></Box>\n <Box sx={{ marginRight: 1, marginLeft: 1 }}>\n {notification.createTime}\n </Box>\n </Box>\n </Button>\n {notification?.showDivider ? <Divider flexItem /> : <></>}\n </>\n );\n};\n\nexport default NotificationItem;\n","import { IconProp } from \"@fortawesome/fontawesome-svg-core\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport {\n Badge,\n Box,\n Button,\n ClickAwayListener,\n Divider,\n Fade,\n IconButton,\n keyframes,\n Paper,\n Popper,\n PopperPlacementType,\n Typography,\n} from \"@mui/material\";\nimport { useEffect, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport { useSelector } from \"react-redux\";\nimport { useNavigate } from \"react-router-dom\";\nimport { timeAgo } from \"../util\";\nimport useInterval from \"../hooks/useInterval\";\nimport { useAxios, useSession } from \"../hooks\";\nimport { toast } from \"react-toastify\";\nimport NotificationItem, {\n Notification,\n} from \"../components/common/NotificationItem\";\n\nexport const notificationsCheckIntervalSeconds = 1;\n\nconst NotificationButton: React.FC = () => {\n const { UserInfo } = useSession();\n const [anchorEl, setAnchorEl] = useState<HTMLButtonElement | null>(null);\n const { handleGetRequest, handlePostRequest } = useAxios();\n const navigate = useNavigate();\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const [open, setOpen] = useState(false);\n const [notifications, setNotifications] = useState<Array<Notification>>([]);\n const loadUseNotifications = () => {\n if (UserInfo.isAuthenticated === true) {\n handleGetRequest({\n endPointURI: \"api/v1/public/notifications/new\",\n showMask: false,\n successCallBkFn: (response: any) => {\n if (response.data.length > notifications.length) {\n toast.info(\n AppLayout.appDirection === \"ltr\"\n ? `You have new notifications`\n : `لديك اشعارات جديدة`,\n {\n autoClose: 3000,\n position:\n AppLayout.appDirection === \"ltr\"\n ? \"bottom-right\"\n : \"bottom-left\",\n closeOnClick: true,\n }\n );\n }\n setNotifications(response.data);\n },\n });\n }\n };\n\n useInterval(() => {\n loadUseNotifications();\n }, notificationsCheckIntervalSeconds * 1000);\n\n const handleClick = (event: React.MouseEvent<HTMLButtonElement>) => {\n setAnchorEl(event.currentTarget);\n setOpen(!open);\n };\n return (\n <ClickAwayListener\n onClickAway={() => {\n setOpen(false);\n }}\n >\n <div style={{ cursor: \"pointer\" }}>\n <IconButton\n color=\"inherit\"\n onClick={handleClick}\n sx={{ marginRight: 1, marginLeft: 1 }}\n >\n <Badge\n anchorOrigin={{\n vertical: \"top\",\n horizontal: AppLayout.appDirection === \"ltr\" ? \"right\" : \"left\",\n }}\n badgeContent={\n notifications.filter(\n (notificaiton) =>\n notificaiton.isNotified === undefined ||\n notificaiton.isNotified === null\n ).length\n }\n color=\"error\"\n >\n <FontAwesomeIcon icon=\"bell\" />\n </Badge>\n </IconButton>\n\n <Popper\n // Note: The following zIndex style is specifically for documentation purposes and may not be necessary in your application.\n sx={{\n zIndex: 1200,\n width: \"fit-content\",\n minWidth: 350,\n display: \"flex\",\n flexDirection: \"column\",\n }}\n open={open}\n anchorEl={anchorEl}\n dir={AppLayout.appDirection}\n placement={\"bottom\"}\n transition\n >\n {({ TransitionProps }) => (\n <Fade {...TransitionProps} timeout={350}>\n <Paper\n sx={{\n padding: 1,\n m: 1,\n maxHeight: 500,\n overflow: \"hidden\",\n display: \"flex\",\n flexDirection: \"column\",\n }}\n >\n <Divider variant=\"fullWidth\" flexItem>\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n marginTop: 2,\n marginBottom: 1,\n }}\n >\n <FontAwesomeIcon\n icon=\"bell\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n {AppLayout.appDirection === \"ltr\"\n ? \"Notifications\"\n : \"الاشعارات\"}\n </Box>\n </Divider>\n {notifications.length == 0 ? (\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n flex: 1,\n justifyContent: \"center\",\n }}\n >\n <Box>\n {AppLayout.appDirection === \"ltr\"\n ? \"You don't have any notifications\"\n : \"لا يوجد اشعارات\"}\n </Box>\n </Box>\n ) : (\n <></>\n )}\n <Box\n sx={{\n flex: 1,\n display: \"flex\",\n flexDirection: \"column\",\n overflowY: \"auto\",\n }}\n >\n {notifications.map((notification, index) => {\n return (\n <NotificationItem\n {...notification}\n setOpen={setOpen}\n showDivider={index < notifications.length - 1}\n />\n );\n })}\n </Box>\n <Divider variant=\"fullWidth\" flexItem>\n <Button\n sx={{ textTransform: \"none\" }}\n onClick={() => {\n navigate(\"myNotifications\");\n }}\n >\n {AppLayout.appDirection === \"ltr\"\n ? \"Show Old Notifications\"\n : \"عرض الاشعارات القديمة\"}\n </Button>\n </Divider>\n </Paper>\n </Fade>\n )}\n </Popper>\n </div>\n </ClickAwayListener>\n );\n};\n\nexport default NotificationButton;\n","import { Box, Button, Divider, Paper } from \"@mui/material\";\nimport { TemplateTextField } from \"../../templates\";\nimport { useState } from \"react\";\nimport { toast } from \"react-toastify\";\nimport { useAxios } from \"../../../hooks\";\n\ninterface ChangePasswordPanelProps {\n selectedPerson: any;\n isSelfService: boolean;\n onSuccessCallBk: () => void;\n}\n\nconst ChangePasswordPanel: React.FC<ChangePasswordPanelProps> = (props) => {\n const [currentPassword, setCurrentPassword] = useState(\"\");\n const [password1, setPassword1] = useState(\"\");\n const [password2, setPassword2] = useState(\"\");\n const { handlePostRequest } = useAxios();\n const handleChangePasswordRequest = async () => {\n if (props.isSelfService) {\n if (currentPassword === null || currentPassword.trim() === \"\") {\n toast.error(\n \"You must enter your current password to process your request\"\n );\n return;\n }\n }\n if (\n password1 === null ||\n password1 === \"\" ||\n password2 === null ||\n password2 === \"\" ||\n password1 != password2\n ) {\n toast.error(\n \"You must enter new password in required fields and must be identical\"\n );\n return;\n }\n await handlePostRequest({\n endPointURI: props.isSelfService\n ? \"api/v1/ss/changeMyPassword\"\n : \"api/v1/admin/changeUserPassword\",\n data: {\n personId: props?.selectedPerson?.id,\n currentPassword,\n newPassword: password1,\n },\n successCallBkFn: () => {\n props.onSuccessCallBk();\n toast.success(\"Your request has been processed successfully\");\n },\n showMask: true,\n });\n };\n return (\n <Paper\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"center\",\n width: 400,\n padding: 1,\n }}\n >\n <Box\n sx={{\n m: 1,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n width: \"100%\",\n fontWeight: \"bold\",\n fontSize: 16,\n }}\n >\n Changing Password For : {props?.selectedPerson?.employeeEnName}\n </Box>\n <Divider variant=\"fullWidth\" sx={{ width: \"100%\", marginBottom: 2 }} />\n {props.isSelfService ? (\n <TemplateTextField\n label=\"Current Password\"\n value={currentPassword}\n onChange={(e) => {\n setCurrentPassword(e.target.value);\n }}\n sx={{ m: 1 }}\n fullWidth\n type=\"password\"\n />\n ) : (\n <></>\n )}\n\n <TemplateTextField\n label=\"New Password\"\n value={password1}\n onChange={(e) => {\n setPassword1(e.target.value);\n }}\n sx={{ m: 1 }}\n fullWidth\n type=\"password\"\n />\n <TemplateTextField\n label=\"Confirm New Password\"\n value={password2}\n onChange={(e) => {\n setPassword2(e.target.value);\n }}\n sx={{ m: 1 }}\n fullWidth\n type=\"password\"\n />\n <Button\n sx={{ m: 1 }}\n variant=\"contained\"\n onClick={() => {\n handleChangePasswordRequest();\n }}\n >\n Change Password\n </Button>\n </Paper>\n );\n};\n\nexport default ChangePasswordPanel;\n","import {\n Avatar,\n Box,\n IconButton,\n Menu,\n MenuItem,\n styled,\n Tooltip,\n Typography,\n} from \"@mui/material\";\nimport MuiAppBar, { AppBarProps as MuiAppBarProps } from \"@mui/material/AppBar\";\nimport Toolbar from \"@mui/material/Toolbar\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { useIsMobile } from \"../hooks/UseMobile\";\nimport {\n AppLayoutActions,\n DRAWER_WIDTH,\n} from \"../redux/features/common/AppLayoutSlice\";\nimport useAxios from \"../hooks/useAxios\";\nimport { UserSessionActions } from \"../redux/features/common/UserSessionSlice\";\nimport i18n, { changeLanguage } from \"../locales/i18n\";\nimport { useSession, useWindow } from \"../hooks\";\nimport ChangeOrgForm from \"../components/common/ChangeOrgForm\";\nimport { toggleSideBarState } from \"../redux/features/common/SideBarSlice\";\nimport AttachmentImageViewer from \"../components/templates/attachment/AttachmentImageViewer\";\nimport NotificationButton from \"./NotificationButton\";\nimport { useState } from \"react\";\nimport ChangePasswordPanel from \"../components/administration/admin/ChangePasswordPanel\";\n\ninterface AppBarProps extends MuiAppBarProps {\n open?: boolean;\n}\n\nconst AppBar = styled(MuiAppBar, {\n shouldForwardProp: (prop) => prop !== \"open\",\n})<AppBarProps>(({ theme }) => {\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const isMobile = useIsMobile();\n return {\n transition: theme.transitions.create([\"margin\", \"width\"], {\n easing: theme.transitions.easing.sharp,\n duration: theme.transitions.duration.leavingScreen,\n }),\n variants: [\n {\n props: ({ open }) => open,\n style: {\n width: !isMobile ? `calc(100% - ${DRAWER_WIDTH}px)` : undefined,\n marginLeft:\n !isMobile && AppLayout.appDirection === \"ltr\"\n ? `${DRAWER_WIDTH}px`\n : undefined,\n marginRight:\n !isMobile && AppLayout.appDirection === \"rtl\"\n ? `${DRAWER_WIDTH}px`\n : undefined,\n transition: theme.transitions.create([\"margin\", \"width\"], {\n easing: theme.transitions.easing.easeOut,\n duration: theme.transitions.duration.enteringScreen,\n }),\n },\n },\n ],\n };\n});\n\nconst TopBar: React.FC = () => {\n const { Window: ChangeOrgWindow, setWindowState: setChangeOrgWindowState } =\n useWindow({\n windowTitle: \"Change Current Organization\",\n windowIcon: \"globe\",\n width: \"fit-content\",\n height: \"fit-content\",\n });\n const AppInfo = useSelector((state: any) => state.AppInfo.value);\n const [anchorElUser, setAnchorElUser] = useState<null | HTMLElement>(null);\n const handleCloseUserMenu = () => {\n setAnchorElUser(null);\n };\n const handleOpenUserMenu = (event: React.MouseEvent<HTMLElement>) => {\n setAnchorElUser(event.currentTarget);\n };\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const SideBarState = useSelector((state: any) => state.SideBar);\n const { UserSession } = useSession();\n const currentOrganization = UserSession.value.currentOrganization;\n const {\n Window: ChangePasswordWindow,\n setWindowState: setChangePasswordWindow,\n } = useWindow({\n windowIcon: \"key\",\n windowTitle: \"Change Password\",\n width: \"fit-content\",\n height: \"fit-content\",\n });\n const { handleGetRequest } = useAxios();\n const isMobile = useIsMobile();\n const dispatch = useDispatch();\n const handleLogout = async () => {\n try {\n await handleGetRequest({ endPointURI: \"api/auth/logout\" });\n } catch (error) {}\n dispatch(UserSessionActions.setUnAuthenticated());\n };\n const toggleSideBar = () => {\n dispatch(toggleSideBarState());\n };\n return (\n <>\n <ChangePasswordWindow>\n <ChangePasswordPanel\n selectedPerson={UserSession.value}\n isSelfService={true}\n onSuccessCallBk={() => {\n setChangePasswordWindow(false);\n }}\n />\n </ChangePasswordWindow>\n <Menu\n sx={{ mt: \"45px\" }}\n id=\"menu-appbar\"\n anchorEl={anchorElUser}\n anchorOrigin={{\n vertical: \"top\",\n horizontal: \"right\",\n }}\n keepMounted\n transformOrigin={{\n vertical: \"top\",\n horizontal: \"right\",\n }}\n open={Boolean(anchorElUser)}\n onClose={handleCloseUserMenu}\n >\n <MenuItem\n onClick={() => {\n setChangePasswordWindow(true);\n handleCloseUserMenu();\n }}\n >\n <Typography sx={{ textAlign: \"center\" }}>Change Password</Typography>\n </MenuItem>\n </Menu>\n <ChangeOrgWindow>\n <ChangeOrgForm\n successChangeCallBackFn={() => {\n setChangeOrgWindowState(false);\n }}\n />\n </ChangeOrgWindow>\n <AppBar position=\"fixed\" open={SideBarState.isOpened}>\n <Toolbar>\n <IconButton\n color=\"inherit\"\n aria-label=\"open drawer\"\n onClick={toggleSideBar}\n edge=\"start\"\n sx={[\n {\n mr: AppLayout.appDirection === \"ltr\" ? 2 : undefined,\n ml: AppLayout.appDirection === \"rtl\" ? 2 : undefined,\n },\n SideBarState.isOpened && { display: \"none\" },\n ]}\n >\n <FontAwesomeIcon icon=\"bars\" />\n </IconButton>\n <AttachmentImageViewer\n showAsAvatar={true}\n attachmentCode=\"ORGANIZATION_LOGOS\"\n refKey={UserSession.value.currentOrganization.id + \"\"}\n onErrorImage=\"/logo.png\"\n style={{\n marginRight: 1,\n marginLeft: 1,\n }}\n />\n {/* <Avatar\n src={AppInfo.appLogo}\n sx={{ marginRight: 1, marginLeft: 1 }}\n /> */}\n <Typography variant=\"h6\" noWrap component=\"div\" sx={{ flex: 1 }}>\n {isMobile\n ? \"\"\n : `${AppInfo.appName} - ${\n AppLayout.appDirection === \"ltr\"\n ? currentOrganization?.organizationEnName\n : currentOrganization?.organizationArName\n }`}\n </Typography>\n <Tooltip\n title={\n AppLayout.themeMode === \"light\"\n ? \"Switch Theme to Dark\"\n : \"Switch Theme to Light\"\n }\n >\n <IconButton\n color=\"inherit\"\n onClick={() => {\n dispatch(\n AppLayoutActions.setThemeMode(\n AppLayout.themeMode === \"light\" ? \"dark\" : \"light\"\n )\n );\n localStorage.setItem(\n \"themeMode\",\n AppLayout.themeMode === \"light\" ? \"dark\" : \"light\"\n );\n }}\n >\n {AppLayout.themeMode === \"light\" ? (\n <FontAwesomeIcon icon=\"moon\" />\n ) : (\n <FontAwesomeIcon icon={{ prefix: \"far\", iconName: \"sun\" }} />\n )}\n </IconButton>\n </Tooltip>\n <Tooltip\n title={\n i18n.language === \"ar\"\n ? \"Change Language To English\"\n : \"Change Language To Arabic\"\n }\n >\n <IconButton\n color=\"inherit\"\n onClick={() => {\n let nextLanguage = i18n.language === \"ar\" ? \"en\" : \"ar\";\n changeLanguage(nextLanguage);\n dispatch(\n AppLayoutActions.setAppDirection(\n nextLanguage === \"ar\" ? \"rtl\" : \"ltr\"\n )\n );\n }}\n >\n <FontAwesomeIcon icon=\"language\" />\n </IconButton>\n </Tooltip>\n {UserSession.value?.userOrganizations &&\n UserSession.value?.userOrganizations.length > 1 ? (\n <Tooltip title=\"Change Current Organization\">\n <IconButton\n color=\"inherit\"\n onClick={() => {\n setChangeOrgWindowState(true);\n }}\n >\n <FontAwesomeIcon icon=\"globe\" />\n </IconButton>\n </Tooltip>\n ) : (\n <></>\n )}\n {AppInfo?.enableUINotifications === true ? (\n <NotificationButton />\n ) : (\n <></>\n )}\n <div onClick={handleOpenUserMenu} style={{ cursor: \"pointer\" }}>\n <AttachmentImageViewer\n showAsAvatar={true}\n onErrorImage=\"/no_user.png\"\n attachmentCode=\"EMPLOYEE_PHOTOS\"\n refKey={UserSession.value?.id + \"\"}\n />\n </div>\n\n <div\n style={{ marginLeft: 5, marginRight: 5, cursor: \"pointer\" }}\n onClick={handleOpenUserMenu}\n >\n {isMobile ? \"\" : UserSession.value?.username}\n </div>\n <IconButton color=\"inherit\" onClick={handleLogout}>\n <FontAwesomeIcon\n rotation={AppLayout.appDirection === \"rtl\" ? 180 : undefined}\n icon=\"arrow-right-from-bracket\"\n />\n </IconButton>\n </Toolbar>\n </AppBar>\n </>\n );\n};\n\nexport default TopBar;\n","import i18n from \"i18next\";\n\nexport const changeLanguage = (lng: string) => {\n i18n.changeLanguage(lng);\n localStorage.setItem(\"language\", lng); // Persist user choice\n};\n\nexport default i18n;\n","import { styled } from \"@mui/material\";\n\nexport const DrawerHeader = styled(\"div\")(({ theme }) => ({\n display: \"flex\",\n alignItems: \"center\", \n // padding: theme.spacing(0, 1),\n // necessary for content to be below app bar\n ...theme.mixins.toolbar,\n justifyContent: \"flex-end\",\n}));\n","import { TreeViewBaseItem } from \"@mui/x-tree-view/models\";\nimport { AdministrationItems } from \"./Administration\";\nimport { IconProp } from \"@fortawesome/fontawesome-svg-core\";\n\nexport type ExtendedTreeItemProps = {\n icon: IconProp;\n id: string;\n label: string;\n action?: \"NAVIGATION\";\n authority?: string;\n applicationModule?: string;\n actionPayload?: {\n path?: string;\n parameters?: object;\n };\n children?: ExtendedTreeItemProps[];\n};\n\nexport const findNavigationItemById = (\n id: string,\n nodes: ExtendedTreeItemProps[]\n): ExtendedTreeItemProps | undefined => {\n for (const node of nodes) {\n if (node.id === id) return node;\n if (node.children) {\n const found = findNavigationItemById(id, node.children);\n if (found) return found;\n }\n }\n return undefined;\n};\n\nexport const NavigationItems: TreeViewBaseItem<ExtendedTreeItemProps>[] = [\n ...AdministrationItems\n];\n","import { TreeViewBaseItem } from \"@mui/x-tree-view/models\";\nimport { ExtendedTreeItemProps } from \"..\";\nimport { adminNavigationItems } from \"./adminNavigationItems\";\n\nexport const AdministrationItems: TreeViewBaseItem<ExtendedTreeItemProps>[] = [\n {\n id: \"home\",\n icon: \"home\",\n label: \"Home\",\n action: \"NAVIGATION\",\n actionPayload: {\n path: \"/\",\n },\n },\n ...adminNavigationItems,\n];\n","import { TreeViewBaseItem } from \"@mui/x-tree-view/models\";\nimport { ExtendedTreeItemProps } from \"..\";\n\nexport const adminNavigationItems: TreeViewBaseItem<ExtendedTreeItemProps>[] = [\n {\n id: \"system_admin\",\n label: \"System Administration\",\n authority: \"SYSTEM_ADMIN\",\n icon: \"cog\",\n children: [\n {\n id: \"system_admin.Person\",\n label: \"PERSON_PLURAL\",\n authority: \"SYSTEM_ADMIN\",\n icon: \"users\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"admin/persons\" },\n },\n {\n id: \"system_admin.devtools.rolesx\",\n label: \"ROLES\",\n icon: \"tag\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/system/roles\" },\n },\n {\n id: \"development_admin.SystemApplication\",\n label: \"SYSTEM_APPLICATION_PLURAL\",\n authority: \"ORGANIZATION_ADMIN\",\n icon: \"window-restore\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"admin/systemapplications\" },\n },\n {\n id: \"development_admin.organizations\",\n label: \"ORGANIZATION_PLURAL\",\n authority: \"ORGANIZATION_ADMIN\",\n icon: \"globe\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"admin/organizations\" },\n },\n {\n id: \"development_admin.organization\",\n label: \"Organization Info\",\n authority: \"DEVELOPMENT_ADMIN\",\n icon: \"globe\",\n children: [\n {\n id: \"development_admin.organization.modules\",\n label: \"Subscriped Modules\",\n icon: \"layer-group\",\n authority: \"ORGANIZATION_ADMIN\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"admin/org/apps\" },\n },\n {\n id: \"development_admin.organization.unitTypes\",\n label: \"Organization Unit Types\",\n icon: \"tags\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"admin/org/unit/types\" },\n },\n {\n id: \"development_admin.organization.units\",\n label: \"Organization Units\",\n icon: \"folder-tree\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"admin/org/units\" },\n },\n {\n id: \"development_admin.organization.ranks\",\n label: \"Organization Ranks\",\n icon: \"street-view\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"admin/org/ranks\" },\n },\n ],\n },\n\n {\n id: \"system_admin.devtools\",\n label: \"DEVELOPMENT_TOOLS\",\n authority: \"DEVELOPMENT_ADMIN\",\n icon: \"code\",\n children: [\n {\n id: \"system_admin.devtools.modules\",\n label: \"System Modules\",\n icon: \"layer-group\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/system/modules\" },\n },\n {\n id: \"system_admin.devtools.authorities\",\n label: \"System Authorities\",\n icon: \"key\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/system/authorities\" },\n },\n {\n id: \"system_admin.devtools.roles\",\n label: \"System Roles\",\n icon: \"tag\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/system/roles\" },\n },\n {\n id: \"system_admin.devtools.lookups\",\n label: \"System Lookups\",\n icon: \"list-check\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/system/lookups\" },\n },\n {\n id: \"system_admin.devtools.DatasourceConnection\",\n label: \"DATASOURCE_CONNECTION_PLURAL\",\n icon: \"plug\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/datasourceconnections\" },\n },\n {\n id: \"system_admin.devtools.EntityParameter\",\n label: \"ENTITY_PARAMETER_PLURAL\",\n icon: \"p\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/entityparameters\" },\n },\n {\n id: \"system_admin.devtools.DataQuery\",\n label: \"DATA_QUERY_PLURAL\",\n icon: \"file-code\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/dataqueries\" },\n },\n {\n id: \"system_admin.devtools.Report\",\n label: \"REPORT_PLURAL\",\n icon: \"file\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/reports\" },\n },\n {\n id: \"system_admin.devtools.MailConfig\",\n label: \"Mail Sender Config\",\n icon: { iconName: \"paper-plane\", prefix: \"fas\" },\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/mailsender/config\" },\n },\n {\n id: \"system_admin.devtools.MailTemplate\",\n label: \"MAIL_TEMPLATE_PLURAL\",\n icon: \"envelope\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/mailtemplates\" },\n },\n {\n id: \"system_admin.devtools.WorkflowDocument\",\n label: \"WORKFLOW_DOCUMENT_PLURAL\",\n icon: \"chart-diagram\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/workflowdocuments\" },\n },\n {\n id: \"system_admin.devtools.Widget\",\n label: \"WIDGET_PLURAL\",\n icon: \"chart-pie\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/widgets\" },\n },\n {\n id: \"system_admin.devtools.Dashboard\",\n label: \"DASHBOARD_PLURAL\",\n icon: \"square-poll-vertical\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/dashboards\" },\n },\n {\n id: \"system_admin.devtools.AttachmentConfig\",\n label: \"ATTACHMENT_CONFIG_PLURAL\",\n icon: \"paperclip\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/attachmentconfigs\" },\n },\n {\n id: \"system_admin.devtools.BluePrint\",\n label: \"BLUE_PRINT_PLURAL\",\n icon: \"fingerprint\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/blueprints\" },\n },\n {\n id: \"system_admin.devtools.Notification\",\n label: \"NOTIFICATION_PLURAL\",\n icon: \"bell\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/notifications\" },\n },\n ],\n },\n {\n id: \"system_admin.followup\",\n label: \"SYSTEM_MONITORING\",\n authority: \"DEVELOPMENT_ADMIN\",\n icon: \"tv\",\n children: [\n {\n id: \"system_admin.WorkflowDocumentMailLog\",\n label: \"Action Mail Logs\",\n icon: \"envelopes-bulk\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/workflowdocumentmaillogs\" },\n },\n {\n id: \"system_admin.MailNotificationQueue\",\n label: \"Mail Notification Queue\",\n icon: \"envelope-open-text\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/mailnotificationqueues\" },\n },\n {\n id: \"system_admin.NotificationQueue\",\n label: \"NOTIFICATION_QUEUE_PLURAL\",\n icon: \"bell\",\n action: \"NAVIGATION\",\n actionPayload: { path: \"dev/notificationqueues\" },\n },\n ],\n },\n ],\n },\n];\n","import * as React from \"react\";\nimport clsx from \"clsx\";\nimport { animated, useSpring } from \"@react-spring/web\";\nimport { styled, alpha } from \"@mui/material/styles\";\nimport { TransitionProps } from \"@mui/material/transitions\";\nimport Box from \"@mui/material/Box\";\nimport Collapse from \"@mui/material/Collapse\";\nimport Typography from \"@mui/material/Typography\";\nimport { RichTreeView } from \"@mui/x-tree-view/RichTreeView\";\nimport { treeItemClasses } from \"@mui/x-tree-view/TreeItem\";\nimport {\n useTreeItem2,\n UseTreeItem2Parameters,\n} from \"@mui/x-tree-view/useTreeItem2\";\nimport {\n TreeItem2Checkbox,\n TreeItem2Content,\n TreeItem2IconContainer,\n TreeItem2Label,\n TreeItem2Root,\n} from \"@mui/x-tree-view/TreeItem2\";\nimport { TreeItem2Icon } from \"@mui/x-tree-view/TreeItem2Icon\";\nimport { TreeItem2Provider } from \"@mui/x-tree-view/TreeItem2Provider\";\nimport { TreeItem2DragAndDropOverlay } from \"@mui/x-tree-view/TreeItem2DragAndDropOverlay\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { useNavigate } from \"react-router-dom\";\nimport { useTranslation } from \"react-i18next\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { IconProp } from \"@fortawesome/fontawesome-svg-core\";\nimport { useIsMobile } from \"../hooks/UseMobile\";\nimport useSession from \"../hooks/UseSession\";\nimport { findNavigationItemById, NavigationItems } from \"../navigationItems\";\nimport { DRAWER_WIDTH } from \"../redux/features/common/AppLayoutSlice\";\n\nfunction DotIcon() {\n return (\n <Box\n sx={{\n width: 6,\n height: 6,\n borderRadius: \"70%\",\n bgcolor: \"warning.main\",\n display: \"inline-block\",\n verticalAlign: \"middle\",\n zIndex: 1,\n mx: 1,\n }}\n />\n );\n}\ndeclare module \"react\" {\n interface CSSProperties {\n \"--tree-view-color\"?: string;\n \"--tree-view-bg-color\"?: string;\n }\n}\n\nconst StyledTreeItemRoot = styled(TreeItem2Root)(({ theme }) => ({\n color: theme.palette.grey[400],\n position: \"relative\",\n [`& .${treeItemClasses.groupTransition}`]: {\n marginLeft: theme.spacing(2.5),\n },\n ...theme.applyStyles(\"light\", {\n color: theme.palette.grey[800],\n }),\n})) as unknown as typeof TreeItem2Root;\n\nconst CustomTreeItemContent = styled(TreeItem2Content)(({ theme }) => ({\n flexDirection: \"row-reverse\",\n borderRadius: theme.spacing(0.7),\n marginBottom: theme.spacing(0.5),\n marginTop: theme.spacing(0.5),\n padding: theme.spacing(0.5),\n paddingRight: theme.spacing(1),\n [`&.Mui-expanded `]: {\n \"&:not(.Mui-focused, .Mui-selected, .Mui-selected.Mui-focused) .labelIcon\":\n {\n color: theme.palette.primary.dark,\n ...theme.applyStyles(\"light\", {\n color: theme.palette.primary.main,\n }),\n },\n \"&::before\": {\n content: '\"\"',\n display: \"block\",\n position: \"absolute\",\n left: \"16px\",\n top: \"44px\",\n height: \"calc(100% - 48px)\",\n width: \"1.5px\",\n backgroundColor: theme.palette.grey[700],\n ...theme.applyStyles(\"light\", {\n backgroundColor: theme.palette.grey[300],\n }),\n },\n },\n \"&:hover\": {\n backgroundColor: alpha(theme.palette.primary.main, 0.1),\n color: \"white\",\n ...theme.applyStyles(\"light\", {\n color: theme.palette.primary.main,\n }),\n },\n [`&.Mui-focused, &.Mui-selected, &.Mui-selected.Mui-focused`]: {\n backgroundColor: theme.palette.primary.dark,\n color: theme.palette.primary.contrastText,\n ...theme.applyStyles(\"light\", {\n backgroundColor: theme.palette.primary.main,\n }),\n },\n}));\n\nconst AnimatedCollapse = animated(Collapse);\n\nfunction TransitionComponent(props: TransitionProps) {\n const style = useSpring({\n to: {\n opacity: props.in ? 1 : 0,\n transform: `translate3d(0,${props.in ? 0 : 20}px,0)`,\n },\n });\n\n return <AnimatedCollapse style={style} {...props} />;\n}\n\nconst StyledTreeItemLabelText = styled(Typography)({\n color: \"inherit\",\n fontWeight: 500,\n}) as unknown as typeof Typography;\n\ninterface CustomLabelProps {\n children: any;\n icon: IconProp;\n expandable?: boolean;\n}\n\nfunction CustomLabel({\n icon,\n expandable,\n children,\n ...other\n}: CustomLabelProps) {\n const { t } = useTranslation();\n const appLayoutState = useSelector((state: any) => state.AppLayout);\n return (\n <TreeItem2Label\n {...other}\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n padding: 1,\n }}\n >\n <FontAwesomeIcon\n style={{\n marginRight: appLayoutState.appDirection === \"ltr\" ? 7 : undefined,\n marginLeft: appLayoutState.appDirection === \"rtl\" ? 7 : undefined,\n fontSize: \"1.2rem\",\n }}\n icon={icon}\n />\n <StyledTreeItemLabelText variant=\"body2\" sx={{ fontSize: 16 }}>\n {t(children)}\n </StyledTreeItemLabelText>\n {expandable && <DotIcon />}\n </TreeItem2Label>\n );\n}\n\nconst isExpandable = (reactChildren: React.ReactNode) => {\n if (Array.isArray(reactChildren)) {\n return reactChildren.length > 0 && reactChildren.some(isExpandable);\n }\n return Boolean(reactChildren);\n};\n\ninterface CustomTreeItemProps\n extends Omit<UseTreeItem2Parameters, \"rootRef\">,\n Omit<React.HTMLAttributes<HTMLLIElement>, \"onFocus\"> {}\n\nconst CustomTreeItem = React.forwardRef(function CustomTreeItem(\n props: CustomTreeItemProps,\n ref: React.Ref<HTMLLIElement>\n) {\n const { id, itemId, label, disabled, children, ...other } = props;\n const {\n getRootProps,\n getContentProps,\n getIconContainerProps,\n getCheckboxProps,\n getLabelProps,\n getGroupTransitionProps,\n getDragAndDropOverlayProps,\n status,\n publicAPI,\n } = useTreeItem2({ id, itemId, children, label, disabled, rootRef: ref });\n const item = publicAPI.getItem(itemId);\n const expandable = isExpandable(children);\n return (\n <TreeItem2Provider itemId={itemId}>\n <StyledTreeItemRoot {...getRootProps(other)}>\n <CustomTreeItemContent\n {...getContentProps({\n className: clsx(\"content\", {\n \"Mui-expanded\": status.expanded,\n \"Mui-selected\": status.selected,\n \"Mui-focused\": status.focused,\n \"Mui-disabled\": status.disabled,\n }),\n })}\n >\n <TreeItem2IconContainer {...getIconContainerProps()}>\n <TreeItem2Icon status={status} />\n </TreeItem2IconContainer>\n <TreeItem2Checkbox {...getCheckboxProps()} />\n <CustomLabel\n {...getLabelProps({\n icon: item?.icon || \"book\",\n expandable: expandable && status.expanded,\n })}\n />\n <TreeItem2DragAndDropOverlay {...getDragAndDropOverlayProps()} />\n </CustomTreeItemContent>\n {children && <TransitionComponent {...getGroupTransitionProps()} />}\n </StyledTreeItemRoot>\n </TreeItem2Provider>\n );\n});\n\nexport default function NavigationTree() {\n const navigate = useNavigate();\n const appLayoutState = useSelector((state: any) => state.AppLayout);\n const AppInfo = useSelector((state: any) => state.AppInfo.value);\n const dispatch = useDispatch();\n const isMobile = useIsMobile();\n const { isUserAuthorized, isCurrentOrganizationAuthorizedToModule } =\n useSession();\n const filterData = (data) => {\n const parentItems = [];\n for (let parentItem of data) {\n if (\n (parentItem.authority === undefined ||\n parentItem.authority == null ||\n isUserAuthorized(parentItem.authority)) &&\n (parentItem.applicationModule === undefined ||\n parentItem.applicationModule === null ||\n isCurrentOrganizationAuthorizedToModule(parentItem.applicationModule))\n ) {\n let newParentItem = structuredClone(parentItem);\n if (parentItem?.children) {\n newParentItem.children = filterData(parentItem.children);\n }\n parentItems.push(newParentItem);\n }\n }\n return parentItems;\n };\n\n const mergedNavigationItems = [];\n if (AppInfo.enableAdministrationModule) {\n mergedNavigationItems.push(...structuredClone(NavigationItems));\n }\n mergedNavigationItems.push(\n ...structuredClone(AppInfo.businessNavigationItems)\n );\n const authoriedNavigationItems = filterData(mergedNavigationItems);\n return (\n <RichTreeView\n items={authoriedNavigationItems}\n onItemClick={(event, itemId) => {\n const navigationItem = findNavigationItemById(\n itemId,\n mergedNavigationItems\n );\n if (\n navigationItem?.action === \"NAVIGATION\" &&\n navigationItem?.actionPayload != null &&\n (navigationItem.children === undefined ||\n navigationItem.children === null ||\n navigationItem.children.length == 0)\n ) {\n navigate(navigationItem?.actionPayload?.path || \"\");\n }\n }}\n sx={{\n height: \"fit-content\",\n flexGrow: 1,\n maxWidth: DRAWER_WIDTH,\n direction: appLayoutState.appDirection,\n maxHeight: isMobile ? 300 : undefined,\n overflowY: \"auto\",\n overflowX: \"auto\",\n }}\n slots={{ item: CustomTreeItem }}\n />\n );\n}\n","import Divider from \"@mui/material/Divider\";\nimport IconButton from \"@mui/material/IconButton\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport Drawer from \"@mui/material/Drawer\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { DrawerHeader } from \"./DrawerHeader\";\nimport { Box, Typography, useTheme } from \"@mui/material\";\nimport { DRAWER_WIDTH } from \"../redux/features/common/AppLayoutSlice\";\nimport NavigationTree from \"./NavigationTree\";\nimport { useSession } from \"../hooks\";\nimport { toggleSideBarState } from \"../redux/features/common/SideBarSlice\";\n\nconst SideBar: React.FC = () => {\n const AppInfo = useSelector((state: any) => state.AppInfo.value);\n const { UserSession } = useSession();\n const currentOrganization = UserSession.value.currentOrganization;\n const theme = useTheme();\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const SideBarState = useSelector((state: any) => state.SideBar);\n const dispatch = useDispatch();\n const toggleSideBar = () => {\n dispatch(toggleSideBarState());\n };\n return (\n <Drawer\n sx={{\n width: DRAWER_WIDTH,\n flexShrink: 0,\n \"& .MuiDrawer-paper\": {\n width: DRAWER_WIDTH,\n boxSizing: \"border-box\",\n },\n }}\n variant=\"persistent\"\n anchor={AppLayout.appDirection === \"ltr\" ? \"left\" : \"right\"}\n open={SideBarState.isOpened}\n >\n <DrawerHeader>\n <Box sx={{ width: \"100%\" }}>\n <Typography\n color=\"primary\"\n sx={{\n width: \"100%\",\n textAlign: \"center\",\n fontSize: 18,\n fontWeight: \"bold\",\n }}\n >\n System Content\n </Typography>\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"space-around\",\n marginTop: 1,\n }}\n >\n <Typography sx={{ fontSize: 12 }} color=\"textDisabled\">\n {`${AppInfo.appName} - ${\n AppLayout.appDirection === \"ltr\"\n ? currentOrganization?.organizationEnName\n : currentOrganization?.organizationArName\n }`}\n </Typography>\n <Typography sx={{ fontSize: 12 }} color=\"textDisabled\">\n V.{AppInfo.appVersion}\n </Typography>\n </Box>\n </Box>\n <IconButton onClick={toggleSideBar}>\n {theme.direction === \"ltr\" ? (\n <FontAwesomeIcon icon=\"angle-left\" />\n ) : (\n <FontAwesomeIcon icon=\"angle-right\" />\n )}\n </IconButton>\n </DrawerHeader>\n <Divider />\n <NavigationTree />\n </Drawer>\n );\n};\n\nexport default SideBar;\n","import rtlPlugin from \"stylis-plugin-rtl\";\nimport { prefixer } from \"stylis\";\nimport createCache from \"@emotion/cache\";\n\nexport const cacheRtl = createCache({\n key: \"muirtl\",\n stylisPlugins: [prefixer, rtlPlugin],\n});\n\nexport const cacheLtr = createCache({\n key: \"mui\",\n});","import { useEffect, useState } from \"react\";\nimport TransferList from \"../../templates/TransferList\";\nimport { Box, Button } from \"@mui/material\";\nimport { toast } from \"react-toastify\";\nimport { useAxios } from \"../../../hooks\";\n\ntype OrgMemberRoleFormProps = {\n selectedRecord: any;\n closeModalFn: () => void;\n};\n\nconst OrgMemberRoleForm: React.FC<OrgMemberRoleFormProps> = (props) => {\n const [selectedOptions, setSelectedOptions] = useState([]);\n const [availableOptions, setAvailableOptions] = useState([]);\n const { handlePostRequest, handleGetRequest } = useAxios();\n\n const getOrgMemberRoles = async () => {\n await handleGetRequest({\n endPointURI: \"api/v1/admin/organization/member/roles\",\n showMask: true,\n parameters: {\n orgMemberId: props.selectedRecord.id,\n organizationId: props.selectedRecord.organizationId,\n },\n successCallBkFn: (response: any) => {\n setSelectedOptions(response.data.currentRoles);\n setAvailableOptions(response.data.availableRoles);\n },\n });\n };\n\n useEffect(() => {\n if (props.selectedRecord) {\n getOrgMemberRoles();\n }\n }, [props.selectedRecord]);\n const saveOrgMemberRoles = async () => {\n await handlePostRequest({\n endPointURI: \"api/v1/admin/organization/member/roles\",\n showMask: true,\n parameters: { orgMemberId: props.selectedRecord.id },\n data: selectedOptions,\n successCallBkFn: () => {\n toast.success(\"Your request has been proccesed successfully\");\n if (props.closeModalFn) {\n props.closeModalFn();\n }\n },\n });\n };\n return (\n <>\n <TransferList\n displayField=\"roleName\"\n options={availableOptions}\n valueField=\"id\"\n selectedOptions={selectedOptions}\n setSelection={setSelectedOptions}\n />\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n }}\n >\n <Button\n variant=\"contained\"\n onClick={saveOrgMemberRoles}\n sx={{ marginRight: 1, marginLeft: 1 }}\n >\n Save\n </Button>\n <Button variant=\"contained\" color=\"error\" onClick={props.closeModalFn}>\n Cancel\n </Button>\n </Box>\n </>\n );\n};\n\nexport default OrgMemberRoleForm;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useWindow } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useSelector } from \"react-redux\";\nimport OrgMemberRoleForm from \"./OrgMemberRoleForm\";\n\ntype OrganizationMemberGridProps = {\n selectedPerson: any;\n};\nconst OrganizationMemberGrid: React.FC<OrganizationMemberGridProps> = (\n props\n) => {\n const [selectedRecord, setSelectedRecord] = useState<any>(null);\n const {\n Window: OrganizationMemberRolesWindow,\n setWindowState: setOrganizationMemberRolesWindowState,\n } = useWindow({\n windowIcon: \"tag\",\n windowTitle: \"Organization Member Roles\",\n width: \"50%\",\n });\n const SystemOrganizations = useSelector(\n (state: any) => state.commonStores.stores.SystemOrganizations.data\n );\n const SystemOrganizationRanks = useSelector(\n (state: any) => state.commonStores.stores.SystemOrganizationRanks.data\n );\n const SystemOrganizationUnits = useSelector(\n (state: any) => state.commonStores.stores.SystemOrganizationUnits.data\n );\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/admin/organizationmember/all\",\n deleteById: \"api/v1/admin/organizationmember\",\n save: \"api/v1/admin/organizationmember\",\n findById: \"api/v1/admin/organizationmember\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_MEMBER_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_MEMBER_IS_DEFAULT\",\n fieldName: \"isDefault\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_MEMBER_ORGANIZATION_ID\",\n fieldName: \"organizationId\",\n required: true,\n fieldType: \"combobox\",\n options: SystemOrganizations,\n optionValueField: \"id\",\n optionDisplayField: \"organizationEnName\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_MEMBER_ORGANIZATION_RANK_ID\",\n fieldName: \"organizationRankId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemOrganizationRanks,\n optionValueField: \"id\",\n optionDisplayField: \"rankDisplay\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_MEMBER_ORGANIZATION_UNIT_ID\",\n fieldName: \"organizationUnitId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemOrganizationUnits,\n optionValueField: \"id\",\n optionDisplayField: \"fullPath\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Membership number\",\n fieldName: \"organizationMembershipNumber\",\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n hidden: true,\n gridProps: {\n hidden: true,\n },\n fieldLabel: \"ORGANIZATION_MEMBER_PERSON_ID\",\n fieldName: \"personId\",\n required: false,\n fieldType: \"number\",\n },\n },\n ];\n\n return (\n <>\n <OrganizationMemberRolesWindow>\n <OrgMemberRoleForm\n selectedRecord={selectedRecord}\n closeModalFn={() => {\n setOrganizationMemberRolesWindowState(false);\n }}\n />\n </OrganizationMemberRolesWindow>\n <TemplateGrid\n apiActions={apiActions}\n hideInfoBar={true}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n rowActions={[\n {\n icon: \"tag\",\n label: \"Roles\",\n actionFn: async (data) => {\n setSelectedRecord(data);\n setOrganizationMemberRolesWindowState(true);\n },\n },\n ]}\n gridLoadParametersValues={{ personId: props.selectedPerson.id }}\n keyColumnName={\"id\"}\n gridTitle=\"ORGANIZATION_MEMBER_PLURAL\"\n girdIcon=\"table-cells\"\n editAction={{\n isEnabled: true,\n authority: \"ORGANIZATION_MEMBER_EDIT\",\n preActionValidation: async (data) => {\n data.personId = props.selectedPerson.id;\n return true;\n },\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"ORGANIZATION_MEMBER_DELETE\",\n }}\n />\n </>\n );\n};\n\nexport default OrganizationMemberGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useAxios } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { setStoreData } from \"../../../redux/features/common/CommonStoreSlice\";\n\nconst OrganizationRankGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"CurrentOrganizationRanks\",\n deleteById: \"api/v1/admin/organizationrank\",\n save: \"api/v1/admin/organizationrank\",\n findById: \"api/v1/admin/organizationrank\",\n setData: setData,\n });\n\n const { handleGetRequest } = useAxios();\n const SystemOrganizationRanks = useSelector(\n (state: any) => state.commonStores.stores.SystemOrganizationRanks\n );\n const dispatch = useDispatch();\n const loadOrganizationRanks = async () => {\n await handleGetRequest({\n endPointURI: SystemOrganizationRanks.url,\n showMask: false,\n successCallBkFn: (response) => {\n dispatch(\n setStoreData({\n storeKey: \"SystemOrganizationRanks\",\n data: response.data,\n })\n );\n },\n failureCallBkFn: () => {\n dispatch(\n setStoreData({ storeKey: \"SystemOrganizationRanks\", data: [] })\n );\n },\n });\n };\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n hidden: true,\n gridProps: { hidden: true },\n fieldLabel: \"ORGANIZATION_RANK_ORGANIZATION_ID\",\n fieldName: \"organizationId\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_RANK_RANK_ORDER\",\n fieldName: \"rankOrder\",\n required: true,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_RANK_RANK_CODE\",\n fieldName: \"rankCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_RANK_RANK_AR_NAME\",\n fieldName: \"rankArName\",\n required: true,\n fieldType: \"text\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_RANK_RANK_EN_NAME\",\n fieldName: \"rankEnName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_RANK_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n setData={setData}\n editMode={{ editMode: \"row\", reloadAfterSave: true }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"ORGANIZATION_RANK_PLURAL\"\n girdIcon=\"street-view\"\n editAction={{\n isEnabled: true,\n authority: \"ORGANIZATION_RANK_EDIT\",\n postActionCallBack: () => {\n loadOrganizationRanks();\n },\n }}\n deleteAction={{ isEnabled: true, authority: \"ORGANIZATION_RANK_DELETE\" }}\n />\n );\n};\n\nexport default OrganizationRankGrid;\n","import { useEffect, useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useAxios } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { setStoreData } from \"../../../redux/features/common/CommonStoreSlice\";\n\nconst OrganizationUnitGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const { handleGetRequest } = useAxios();\n const SystemOrganizationUnits = useSelector(\n (state: any) => state.commonStores.stores.SystemOrganizationUnits\n );\n const dispatch = useDispatch();\n const loadOrganizationUnits = async () => {\n await handleGetRequest({\n endPointURI: SystemOrganizationUnits.url,\n showMask: false,\n successCallBkFn: (response) => {\n dispatch(\n setStoreData({\n storeKey: \"SystemOrganizationUnits\",\n data: response.data,\n })\n );\n },\n failureCallBkFn: () => {\n dispatch(\n setStoreData({ storeKey: \"SystemOrganizationUnits\", data: [] })\n );\n },\n });\n };\n const apiActions = useApiActions({\n findAll: \"api/v1/public/organizationunit/all\",\n deleteById: \"api/v1/admin/organizationunit\",\n save: \"api/v1/admin/organizationunit\",\n findById: \"api/v1/admin/organizationunit\",\n setData: setData,\n });\n\n const organizationUnitTypes = useSelector(\n (state: any) => state.commonStores.stores.SystemOrganizationUnitType.data\n );\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n hidden: true,\n gridProps: { hidden: true },\n fieldLabel: \"ORGANIZATION_UNIT_ORGANIZATION_ID\",\n fieldName: \"organizationId\",\n required: false,\n fieldType: \"number\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_ORGANIZATION_UNIT_TYPE_ID\",\n fieldName: \"organizationUnitTypeId\",\n required: true,\n fieldType: \"combobox\",\n options: organizationUnitTypes,\n optionValueField: \"id\",\n optionDisplayField: \"unitTypeEnName\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_ORGANIZATION_UNIT_AR_NAME\",\n fieldName: \"organizationUnitArName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_ORGANIZATION_UNIT_EN_NAME\",\n fieldName: \"organizationUnitEnName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_ORGANIZATION_UNIT_PARENT_ID\",\n fieldName: \"organizationUnitParentId\",\n required: false,\n fieldType: \"combobox\",\n options: data,\n optionValueField: \"id\",\n optionDisplayField: \"organizationUnitEnName\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"ORGANIZATION_UNIT_PLURAL\"\n girdIcon=\"folder-tree\"\n editAction={{\n isEnabled: true,\n authority: \"ORGANIZATION_UNIT_EDIT\",\n postActionCallBack: () => {\n loadOrganizationUnits();\n },\n }}\n deleteAction={{ isEnabled: true, authority: \"ORGANIZATION_UNIT_DELETE\" }}\n />\n );\n};\n\nexport default OrganizationUnitGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\n\nconst OrganizationUnitTypeGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"SystemOrganizationUnitType\",\n deleteById: \"api/v1/admin/organizationunittype\",\n save: \"api/v1/admin/organizationunittype\",\n findById: \"api/v1/admin/organizationunittype\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_TYPE_ORGANIZATION_ID\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n fieldName: \"organizationId\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_TYPE_ORGANIZATION_UNIT_TYPE_ORDER\",\n fieldName: \"organizationUnitTypeOrder\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_TYPE_UNIT_TYPE_CODE\",\n fieldName: \"unitTypeCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_TYPE_UNIT_TYPE_AR_NAME\",\n fieldName: \"unitTypeArName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_TYPE_UNIT_TYPE_EN_NAME\",\n fieldName: \"unitTypeEnName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_UNIT_TYPE_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n setData={setData}\n editMode={{ editMode: \"row\", reloadAfterSave: true }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"ORGANIZATION_UNIT_TYPE_PLURAL\"\n girdIcon=\"tags\"\n editAction={{\n isEnabled: true,\n authority: \"ORGANIZATION_UNIT_TYPE_EDIT\",\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"ORGANIZATION_UNIT_TYPE_DELETE\",\n }}\n />\n );\n};\n\nexport default OrganizationUnitTypeGrid;\n","import { useEffect, useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useAxios } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useSelector } from \"react-redux\";\n\nconst SystemApplicationAuthorityGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"SystemApplicationAuthorities\",\n deleteById: \"api/v1/admin/systemapplicationauthority\",\n save: \"api/v1/admin/systemapplicationauthority\",\n findById: \"api/v1/admin/systemapplicationauthority\",\n setData: setData,\n });\n\n const SystemApplicationModules = useSelector(\n (state: any) => state.commonStores.stores.SystemApplicationModules.data\n );\n const { handleGetRequest } = useAxios();\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_AUTHORITY_SYSTEM_APPLICATION_ID\",\n fieldName: \"systemApplicationId\",\n required: false,\n hidden: true,\n gridProps: { hidden: true },\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_AUTHORITY_SYSTEM_MODULE_ID\",\n fieldName: \"systemModuleId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemApplicationModules,\n optionValueField: \"id\",\n optionDisplayField: \"moduleName\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_AUTHORITY_AUTHORITY_NAME\",\n fieldName: \"authorityName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_AUTHORITY_AUTHORITY_CODE\",\n fieldName: \"authorityCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_AUTHORITY_AUTHORITY_DESCRIPTION\",\n fieldName: \"authorityDescription\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_AUTHORITY_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"SYSTEM_APPLICATION_AUTHORITY_PLURAL\"\n girdIcon=\"key\"\n editAction={{\n isEnabled: true,\n authority: \"SYSTEM_APPLICATION_AUTHORITY_EDIT\",\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"SYSTEM_APPLICATION_AUTHORITY_DELETE\",\n }}\n />\n );\n};\n\nexport default SystemApplicationAuthorityGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\n\nconst SystemApplicationModuleGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"SystemApplicationModules\",\n deleteById: \"api/v1/admin/systemapplicationmodule\",\n save: \"api/v1/admin/systemapplicationmodule\",\n findById: \"api/v1/admin/systemapplicationmodule\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_MODULE_MODULE_CODE\",\n fieldName: \"moduleCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_MODULE_MODULE_NAME\",\n fieldName: \"moduleName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_MODULE_MODULE_DESCRIPTION\",\n fieldName: \"moduleDescription\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_MODULE_SYSTEM_APPLICATION_ID\",\n fieldName: \"systemApplicationId\",\n hidden: true,\n gridProps: { hidden: true },\n required: false,\n fieldType: \"text\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\", reloadAfterSave: true }}\n formElements={formElements}\n keyColumnName={\"id\"}\n hideInfoBar={true}\n gridTitle=\"SYSTEM_APPLICATION_MODULE_PLURAL\"\n girdIcon=\"layer-group\"\n editAction={{\n isEnabled: true,\n authority: \"SYSTEM_APPLICATION_MODULE_EDIT\",\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"SYSTEM_APPLICATION_MODULE_DELETE\",\n }}\n />\n );\n};\n\nexport default SystemApplicationModuleGrid;\n","import { useEffect, useState } from \"react\";\nimport TransferList from \"../../templates/TransferList\";\nimport { Box, Button } from \"@mui/material\";\nimport { toast } from \"react-toastify\";\nimport { useAxios } from \"../../../hooks\";\n\ntype RoleAuthoritiesFormProps = {\n roleId: number;\n closeModalFn: () => void;\n};\n\nconst RoleAuthoritiesForm: React.FC<RoleAuthoritiesFormProps> = (props) => {\n const [selectedOptions, setSelectedOptions] = useState([]);\n const [availableAuthorities, setAvailableAuthorities] = useState([]);\n const { handlePostRequest, handleGetRequest } = useAxios();\n\n const getRoleAuthorities = async () => {\n await handleGetRequest({\n endPointURI: \"api/v1/admin/systemApplicationRoleAuthorities\",\n showMask: true,\n parameters: {\n roleId: props.roleId,\n },\n successCallBkFn: (response: any) => {\n setSelectedOptions(response.data.selectedAuthorities);\n setAvailableAuthorities(response.data.availableAuthorities);\n },\n });\n };\n\n useEffect(() => {\n if (props.roleId) {\n getRoleAuthorities();\n }\n }, [props.roleId]);\n const saveRoleAuthorities = async () => {\n await handlePostRequest({\n endPointURI: \"api/v1/admin/systemApplicationRoleAuthorities\",\n showMask: true,\n parameters: { roleId: props.roleId },\n data: selectedOptions,\n successCallBkFn: () => {\n toast.success(\"Your request has been proccesed successfully\");\n if (props.closeModalFn) {\n props.closeModalFn();\n }\n },\n });\n };\n return (\n <>\n <TransferList\n displayField=\"authorityName\"\n options={availableAuthorities}\n valueField=\"id\"\n selectedOptions={selectedOptions}\n setSelection={setSelectedOptions}\n />\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n }}\n >\n <Button\n variant=\"contained\"\n onClick={saveRoleAuthorities}\n sx={{ marginRight: 1, marginLeft: 1 }}\n >\n Save\n </Button>\n <Button variant=\"contained\" color=\"error\" onClick={props.closeModalFn}>\n Cancel\n </Button>\n </Box>\n </>\n );\n};\n\nexport default RoleAuthoritiesForm;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useWindow } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport RoleAuthoritiesForm from \"./RoleAuthoritiesForm\";\n\nconst SystemApplicationRoleGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const [selectedRole, setSelectedRole] = useState(null);\n const {\n Window: RoleaAuthoritiesWindow,\n setWindowState: setRoleAuthoritiesWindowState,\n } = useWindow({\n windowTitle: \"System Application Role Authorities\",\n windowIcon: \"key\",\n width: \"50%\",\n });\n const apiActions = useApiActions({\n commonStoreKey: \"SystemApplicationRoles\",\n deleteById: \"api/v1/admin/systemapplicationrole\",\n save: \"api/v1/admin/systemapplicationrole\",\n findById: \"api/v1/admin/systemapplicationrole\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_ROLE_SYSTEM_APPLICATION_ID\",\n fieldName: \"systemApplicationId\",\n required: false,\n hidden: true,\n gridProps: { hidden: true },\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_ROLE_ROLE_NAME\",\n fieldName: \"roleName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_ROLE_ROLE_DESCRIPTION\",\n fieldName: \"roleDescription\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_ROLE_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <>\n <RoleaAuthoritiesWindow>\n <RoleAuthoritiesForm\n roleId={selectedRole?.id}\n closeModalFn={() => {\n setRoleAuthoritiesWindowState(false);\n }}\n />\n </RoleaAuthoritiesWindow>\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n setData={setData}\n editMode={{ editMode: \"row\", reloadAfterSave: true }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"SYSTEM_APPLICATION_ROLE_PLURAL\"\n girdIcon=\"tag\"\n rowActions={[\n {\n icon: \"key\",\n actionFn: async (data) => {\n setSelectedRole(data);\n setRoleAuthoritiesWindowState(true);\n },\n label: \"Authorities\",\n },\n ]}\n editAction={{\n isEnabled: true,\n authority: \"SYSTEM_APPLICATION_ROLE_EDIT\",\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"SYSTEM_APPLICATION_ROLE_DELETE\",\n }}\n />\n </>\n );\n};\n\nexport default SystemApplicationRoleGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\n\ntype DataQueryParameterGridProps = {\n selectedRecord: any;\n};\n\nconst DataQueryParameterGrid: React.FC<DataQueryParameterGridProps> = (\n props\n) => {\n const SystemEntityParameters = useSelector(\n (state: any) => state.commonStores.stores.SystemEntityParameters.data\n );\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/dataqueryparameter/all\",\n deleteById: \"api/v1/dev/dataqueryparameter\",\n save: \"api/v1/dev/dataqueryparameter\",\n findById: \"api/v1/dev/dataqueryparameter\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_PARAMETER_DATA_QUERY_ID\",\n fieldName: \"dataQueryId\",\n required: false,\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_PARAMETER_ENTITY_PARAMETER_ID\",\n fieldName: \"entityParameterId\",\n required: true,\n fieldType: \"combobox\",\n options: SystemEntityParameters,\n optionValueField: \"id\",\n optionDisplayField: \"parameterCode\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_PARAMETER_DEFAULT_VALUE\",\n fieldName: \"defaultValue\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_PARAMETER_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_PARAMETER_HIDDEN\",\n fieldName: \"hidden\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_PARAMETER_MANDATORY\",\n fieldName: \"mandatory\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n hideInfoBar={true}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridLoadParametersValues={{ dataQueryId: props.selectedRecord.id }}\n gridTitle={t(\"DATA_QUERY_PARAMETER_PLURAL\")}\n girdIcon=\"table-cells\"\n editAction={{\n isEnabled: true,\n authority: \"DATA_QUERY_PARAMETER_EDIT\",\n preActionValidation: async (data) => {\n data.dataQueryId = props.selectedRecord.id;\n return true;\n },\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"DATA_QUERY_PARAMETER_DELETE\",\n }}\n />\n );\n};\n\nexport default DataQueryParameterGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\n\nconst LookupGrid: React.FC = () => {\n const SystemOrganizations = useSelector(\n (state: any) => state.commonStores.stores.SystemOrganizations.data\n );\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/lookup/all\",\n deleteById: \"api/v1/dev/lookup\",\n save: \"api/v1/dev/lookup\",\n findById: \"api/v1/dev/lookup\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Organization\",\n fieldName: \"organizationId\",\n options: SystemOrganizations,\n optionDisplayField: \"organizationEnName\",\n optionValueField: \"id\",\n required: false,\n fieldType: \"combobox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"LOOKUP_LOOKUP_TYPE\",\n fieldName: \"lookupType\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"LOOKUP_LOOKUP_AR_DISPLAY\",\n fieldName: \"lookupArDisplay\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"LOOKUP_LOOKUP_EN_DISPLAY\",\n fieldName: \"lookupEnDisplay\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"LOOKUP_LOOKUP_VALUE\",\n fieldName: \"lookupValue\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"LOOKUP_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"System Application\",\n fieldName: \"systemApplicationId\",\n hidden: true,\n gridProps: { hidden: true },\n required: false,\n fieldType: \"number\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n hideInfoBar={true}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"LOOKUP_PLURAL\")}\n girdIcon=\"list-check\"\n editAction={{\n isEnabled: true,\n authority: \"LOOKUP_EDIT\",\n }}\n deleteAction={{ isEnabled: true, authority: \"LOOKUP_DELETE\" }}\n />\n );\n};\n\nexport default LookupGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\n\ntype ReportParameterGridProps = {\n selectedRecord: any;\n};\n\nconst ReportParameterGrid: React.FC<ReportParameterGridProps> = (props) => {\n const { t } = useTranslation();\n const SystemEntityParameters = useSelector(\n (state: any) => state.commonStores.stores.SystemEntityParameters.data\n );\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/reportparameter/all\",\n deleteById: \"api/v1/dev/reportparameter\",\n save: \"api/v1/dev/reportparameter\",\n findById: \"api/v1/dev/reportparameter\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_PARAMETER_ENTITY_PARAMETER_ID\",\n fieldName: \"entityParameterId\",\n required: true,\n fieldType: \"combobox\",\n options: SystemEntityParameters,\n optionValueField: \"id\",\n optionDisplayField: \"parameterCode\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_PARAMETER_DEFAULT_VALUE\",\n fieldName: \"defaultValue\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_PARAMETER_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_PARAMETER_HIDDEN\",\n fieldName: \"hidden\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_PARAMETER_MANDATORY\",\n fieldName: \"mandatory\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_PARAMETER_REPORT_ID\",\n fieldName: \"reportId\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"number\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n setData={setData}\n gridLoadParametersValues={{ reportId: props.selectedRecord.id }}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"REPORT_PARAMETER_PLURAL\")}\n girdIcon=\"p\"\n editAction={{\n isEnabled: true,\n authority: \"REPORT_PARAMETER_EDIT\",\n preActionValidation: async (data) => {\n data.reportId = props.selectedRecord.id;\n return true;\n },\n }}\n deleteAction={{ isEnabled: true, authority: \"REPORT_PARAMETER_DELETE\" }}\n />\n );\n};\n\nexport default ReportParameterGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\n\nexport const storageTypes = [{ value: \"FILE_SYSTEM\" }, { value: \"SFTP\" }];\n\nconst AttachmentConfigGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/attachmentconfig/all\",\n deleteById: \"api/v1/dev/attachmentconfig\",\n save: \"api/v1/dev/attachmentconfig\",\n findById: \"api/v1/dev/attachmentconfig\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_ATTACHMENT_CODE\",\n fieldName: \"attachmentCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_RELATED_DATABASE_TABLE\",\n fieldName: \"relatedDatabaseTable\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_STORAGE_TYPE\",\n fieldName: \"storageType\",\n required: true,\n fieldType: \"combobox\",\n comboboxValueDataType: \"string\",\n options: storageTypes,\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Include App Code in attachment path\",\n fieldName: \"includeAppCodeInPath\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_UPLOAD_DIRECTORY\",\n fieldName: \"uploadDirectory\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_ALLOWED_FILE_TYPES\",\n fieldName: \"allowedFileTypes\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_ATTACHMENT_CATEGORIES\",\n fieldName: \"attachmentCategories\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Is Category Mandatory\",\n fieldName: \"isCategoryRequired\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_MAX_ALLOWED_NUMBER_OF_FILES\",\n fieldName: \"maxAllowedNumberOfFiles\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_DOWNLOAD_AUTHORITY_KEY\",\n fieldName: \"downloadAuthorityKey\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_UPLOAD_AUTHORITY_KEY\",\n fieldName: \"uploadAuthorityKey\",\n required: false,\n fieldType: \"text\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalIcon: \"paperclip\",\n modalTitle: \"Attachment Configuration\",\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"ATTACHMENT_CONFIG_PLURAL\")}\n girdIcon=\"paperclip\"\n editAction={{ isEnabled: true, authority: \"ATTACHMENT_CONFIG_EDIT\" }}\n deleteAction={{ isEnabled: true, authority: \"ATTACHMENT_CONFIG_DELETE\" }}\n />\n );\n};\n\nexport default AttachmentConfigGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useWindow } from \"../../../hooks\";\nimport {\n FormElementProps,\n FormValueChangeCallBk,\n} from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { UseFormReturn } from \"react-hook-form\";\nimport { useSelector } from \"react-redux\";\nimport { toast } from \"react-toastify\";\nimport ReportParameterGrid from \"./ReportParameterGrid\";\nimport ReportViewer from \"../../templates/report/ReportViewer\";\nimport { storageTypes } from \"./AttachmentConfigGrid\";\n\nexport type ReportType = \"Jasper\" | \"Excel\" | \"Blueprint\";\n\nconst adjustFormAfterValueChange: FormValueChangeCallBk = (\n formValues,\n formActions,\n formManager,\n fieldName,\n newValue\n) => {\n if (fieldName) {\n if (fieldName === \"useSysDatasource\" && newValue == true) {\n formActions.hideField(\"datasourceConId\");\n formManager.setValue(\"datasourceConId\", null);\n } else {\n formActions.showField(\"datasourceConId\");\n }\n\n if (fieldName === \"reportType\") {\n if (newValue === \"Blueprint\") {\n formActions.hideField(\"storageType\");\n formActions.hideField(\"includeAppCodeInPath\");\n formActions.hideField(\"useSysDatasource\");\n formActions.hideField(\"datasourceConId\");\n formActions.hideField(\"reportExcelDataQueryId\");\n formActions.hideField(\"reportJasperName\");\n formActions.showField(\"reportBluePrintId\");\n } else if (newValue === \"Jasper\") {\n formActions.showField(\"storageType\");\n formActions.showField(\"includeAppCodeInPath\");\n formActions.showField(\"useSysDatasource\");\n formActions.showField(\"datasourceConId\");\n formActions.hideField(\"reportExcelDataQueryId\");\n formActions.showField(\"reportJasperName\");\n formActions.hideField(\"reportBluePrintId\");\n } else if (newValue === \"Excel\") {\n formActions.hideField(\"storageType\");\n formActions.hideField(\"includeAppCodeInPath\");\n formActions.hideField(\"useSysDatasource\");\n formActions.hideField(\"datasourceConId\");\n formActions.showField(\"reportExcelDataQueryId\");\n formActions.hideField(\"reportJasperName\");\n formActions.hideField(\"reportBluePrintId\");\n } else {\n formActions.hideField(\"storageType\");\n formActions.hideField(\"includeAppCodeInPath\");\n formActions.hideField(\"useSysDatasource\");\n formActions.hideField(\"datasourceConId\");\n formActions.hideField(\"reportExcelDataQueryId\");\n formActions.hideField(\"reportJasperName\");\n formActions.hideField(\"reportBluePrintId\");\n }\n }\n } else {\n if (formValues?.useSysCon) {\n formActions.hideField(\"datasourceConId\");\n }\n if (formValues?.reportType) {\n if (formValues?.reportType === \"Blueprint\") {\n formActions.hideField(\"storageType\");\n formActions.hideField(\"includeAppCodeInPath\");\n formActions.hideField(\"useSysDatasource\");\n formActions.hideField(\"datasourceConId\");\n formActions.hideField(\"reportExcelDataQueryId\");\n formActions.hideField(\"reportJasperName\");\n formActions.showField(\"reportBluePrintId\");\n } else if (formValues?.reportType === \"Jasper\") {\n formActions.showField(\"storageType\");\n formActions.showField(\"includeAppCodeInPath\");\n formActions.showField(\"useSysDatasource\");\n formActions.showField(\"datasourceConId\");\n formActions.hideField(\"reportExcelDataQueryId\");\n formActions.showField(\"reportJasperName\");\n formActions.hideField(\"reportBluePrintId\");\n } else if (formValues?.reportType === \"Excel\") {\n formActions.hideField(\"storageType\");\n formActions.hideField(\"includeAppCodeInPath\");\n formActions.hideField(\"useSysDatasource\");\n formActions.hideField(\"datasourceConId\");\n formActions.showField(\"reportExcelDataQueryId\");\n formActions.hideField(\"reportJasperName\");\n formActions.hideField(\"reportBluePrintId\");\n }\n } else {\n formActions.hideField(\"storageType\");\n formActions.hideField(\"includeAppCodeInPath\");\n formActions.hideField(\"useSysDatasource\");\n formActions.hideField(\"datasourceConId\");\n formActions.hideField(\"reportExcelDataQueryId\");\n formActions.hideField(\"reportJasperName\");\n formActions.hideField(\"reportBluePrintId\");\n }\n }\n};\n\nconst ReportGrid: React.FC = () => {\n const { t } = useTranslation();\n const [selectedRecord, setSelectedRecord] = useState(null);\n const {\n Window: ReporTrialWindow,\n setWindowState: setReportTrialWindowState,\n } = useWindow({\n windowTitle: \"Report View\",\n windowIcon: \"eye\",\n width: \"80%\",\n });\n const {\n Window: ReportParameterWindow,\n setWindowState: setReportParameterWindowState,\n } = useWindow({\n windowTitle: \"Report Parameters\",\n windowIcon: \"p\",\n width: \"80%\",\n });\n const [data, setData] = useState([]);\n const SystemDataSources = useSelector(\n (state: any) => state.commonStores.stores.SystemDataSources.data\n );\n const SystemDataQueries = useSelector(\n (state: any) => state.commonStores.stores.SystemDataQueries.data\n );\n const SystemBluePrints = useSelector(\n (state: any) => state.commonStores.stores.SystemBluePrints.data\n );\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/report/all\",\n deleteById: \"api/v1/dev/report\",\n save: \"api/v1/dev/report\",\n findById: \"api/v1/dev/report\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_REPORT_TYPE\",\n fieldName: \"reportType\",\n options: [\n { value: \"Excel\" },\n { value: \"Jasper\" },\n { value: \"Blueprint\" },\n ],\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n required: true,\n fieldType: \"combobox\",\n comboboxValueDataType: \"string\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_REPORT_CODE\",\n fieldName: \"reportCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_REPORT_NAME\",\n fieldName: \"reportName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ATTACHMENT_CONFIG_STORAGE_TYPE\",\n fieldName: \"storageType\",\n required: false,\n hidden: true,\n gridProps: {\n hidden: true,\n },\n comboboxValueDataType: \"string\",\n fieldType: \"combobox\",\n options: storageTypes,\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_REPORT_CATEGORY\",\n fieldName: \"reportCategory\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Authority Code\",\n fieldName: \"reportAuthorityCode\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_REPORT_EXPORT_NAME\",\n fieldName: \"reportExportName\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_USE_SYS_DATASOURCE\",\n fieldName: \"useSysDatasource\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_DATASOURCE_CON_ID\",\n fieldName: \"datasourceConId\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"combobox\",\n options: SystemDataSources,\n optionValueField: \"id\",\n optionDisplayField: \"connectionName\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_REPORT_BLUE_PRINT_ID\",\n fieldName: \"reportBluePrintId\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"combobox\",\n options: SystemBluePrints,\n optionDisplayField: \"bluePrintCode\",\n optionValueField: \"id\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_REPORT_EXCEL_DATA_QUERY_ID\",\n fieldName: \"reportExcelDataQueryId\",\n hidden: true,\n required: false,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionValueField: \"id\",\n optionDisplayField: \"queryName\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"REPORT_REPORT_JASPER_NAME\",\n fieldName: \"reportJasperName\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Include App Code in attachment path\",\n fieldName: \"includeAppCodeInPath\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Active\",\n fieldName: \"isActive\",\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <>\n <ReporTrialWindow>\n <ReportViewer\n reportCode={selectedRecord?.reportCode}\n resultMode=\"App\"\n />\n </ReporTrialWindow>\n <ReportParameterWindow>\n <ReportParameterGrid selectedRecord={selectedRecord} />\n </ReportParameterWindow>\n <TemplateGrid\n attachment={{\n attachmentCode: \"JASPER_REPORTS\",\n enableAttachFn(record) {\n if (record?.reportType === \"Jasper\") {\n return true;\n } else {\n return false;\n }\n },\n }}\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalTitle: \"Report\",\n modalIcon: \"file\",\n modalWidth: 300,\n },\n }}\n rowActions={[\n {\n icon: \"p\",\n label: \"Report Parameters\",\n isActionVisibleForRecord: (record) => {\n return record.reportType === \"Jasper\";\n },\n actionFn: async (data, recordIdsToProcessActionOn) => {\n setSelectedRecord(data);\n setReportParameterWindowState(true);\n },\n },\n {\n icon: \"eye\",\n label: \"View Report\",\n actionFn: async (data, recordIdsToProcessActionOn) => {\n setSelectedRecord(data);\n setReportTrialWindowState(true);\n },\n },\n ]}\n formProps={{ formValuesChangeCallBk: adjustFormAfterValueChange }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"REPORT_PLURAL\")}\n girdIcon=\"table-cells\"\n editAction={{\n isEnabled: true,\n authority: \"REPORT_EDIT\",\n preActionValidation: (record) => {\n if (\n record?.reportType === \"Jasper\" &&\n record?.useSysDatasource === false &&\n !record?.datasourceConId\n ) {\n toast.error(\"You must choose the datasource\");\n return false;\n }\n if (record?.reportType === \"Jasper\" && !record?.reportJasperName) {\n toast.error(\"You must enter the jasper report name\");\n return false;\n }\n\n if (\n record?.reportType === \"Blueprint\" &&\n !record?.reportBluePrintId\n ) {\n toast.error(\"You must choose the report blueprint\");\n return false;\n }\n if (\n record?.reportType === \"Excel\" &&\n !record?.reportExcelDataQueryId\n ) {\n toast.error(\"You must choose the report query\");\n return false;\n }\n return true;\n },\n }}\n deleteAction={{ isEnabled: true, authority: \"REPORT_DELETE\" }}\n />\n </>\n );\n};\n\nexport default ReportGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { isValidEmail } from \"../../../util\";\nimport { toast } from \"react-toastify\";\n\ntype MailRecipientGridProps = {\n selectedRecord: any;\n callBkFn: () => void;\n};\n\nconst MailRecipientGrid: React.FC<MailRecipientGridProps> = (props) => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/mailrecipient/all\",\n deleteById: \"api/v1/dev/mailrecipient\",\n save: \"api/v1/dev/mailrecipient\",\n findById: \"api/v1/dev/mailrecipient\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_RECIPIENT_MAIL_TEMPLATE_ID\",\n fieldName: \"mailTemplateId\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_RECIPIENT_RECIPIENT_TYPE\",\n fieldName: \"recipientType\",\n required: true,\n fieldType: \"combobox\",\n options: [{ value: \"To\" }, { value: \"CC\" }],\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n comboboxValueDataType: \"string\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_RECIPIENT_RECIPIENT_MAIL\",\n fieldName: \"recipientMail\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_RECIPIENT_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n gridLoadParametersValues={{ mailTemplateId: props.selectedRecord.id }}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"MAIL_RECIPIENT_PLURAL\")}\n girdIcon=\"users\"\n editAction={{\n isEnabled: true,\n authority: \"MAIL_RECIPIENT_EDIT\",\n preActionValidation: (record) => {\n if (record?.recipientMail && !isValidEmail(record.recipientMail)) {\n toast.error(\"You must enter a valid email address\");\n return false;\n }\n record.mailTemplateId = props.selectedRecord.id;\n return true;\n },\n }}\n deleteAction={{ isEnabled: true, authority: \"MAIL_RECIPIENT_DELETE\" }}\n />\n );\n};\n\nexport default MailRecipientGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\n\ntype MailBodyGridProps = {\n selectedRecord: any;\n callBkFn: () => void;\n};\n\nconst MailBodyGrid: React.FC<MailBodyGridProps> = (props) => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const SystemDataQueries = useSelector(\n (state: any) => state.commonStores.stores.SystemDataQueries.data\n );\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/mailbody/all\",\n deleteById: \"api/v1/dev/mailbody\",\n save: \"api/v1/dev/mailbody\",\n findById: \"api/v1/dev/mailbody\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_BODY_BODY_NAME\",\n fieldName: \"bodyName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_BODY_BODY_ORDER\",\n fieldName: \"bodyOrder\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_BODY_BODY_CONTENT\",\n fieldName: \"bodyContent\",\n required: true,\n fieldType: \"text\",\n muiTextFieldProps: { multiline: true, rows: 6 },\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_BODY_BODY_CONTENT_DATA_QUERY_ID\",\n fieldName: \"bodyContentDataQueryId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionDisplayField: \"queryName\",\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_BODY_PRINT_FOR_EACH_RECORD\",\n fieldName: \"printForEachRecord\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_BODY_IS_MAIN\",\n fieldName: \"isMain\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_BODY_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_BODY_MAIL_TEMPLATE_ID\",\n fieldName: \"mailTemplateId\",\n required: false,\n hidden: true,\n gridProps: {\n hidden: true,\n },\n fieldType: \"number\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n gridLoadParametersValues={{ mailTemplateId: props.selectedRecord.id }}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalIcon: { prefix: \"fas\", iconName: \"envelope-open-text\" },\n modalTitle: \"Mail Body\",\n modalWidth: \"50%\",\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"MAIL_BODY_PLURAL\")}\n girdIcon={{ prefix: \"fas\", iconName: \"envelope-open-text\" }}\n editAction={{\n isEnabled: true,\n authority: \"MAIL_BODY_EDIT\",\n preActionValidation: async (record) => {\n record.mailTemplateId = props.selectedRecord.id;\n return true;\n },\n }}\n deleteAction={{ isEnabled: true, authority: \"MAIL_BODY_DELETE\" }}\n />\n );\n};\n\nexport default MailBodyGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\n\ntype MailAttachmentGridProps = {\n selectedRecord: any;\n callBkFn: () => void;\n};\n\nconst MailAttachmentGrid: React.FC<MailAttachmentGridProps> = (props) => {\n const SystemReports = useSelector(\n (state: any) => state.commonStores.stores.SystemReports.data\n );\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/mailattachment/all\",\n deleteById: \"api/v1/dev/mailattachment\",\n save: \"api/v1/dev/mailattachment\",\n findById: \"api/v1/dev/mailattachment\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n options: SystemReports,\n optionValueField: \"id\",\n optionDisplayField: \"reportName\",\n fieldLabel: \"REPORT_REPORT_NAME\",\n fieldName: \"reportId\",\n required: true,\n fieldType: \"combobox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_ATTACHMENT_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_ATTACHMENT_MAIL_TEMPLATE_ID\",\n fieldName: \"mailTemplateId\",\n required: false,\n hidden: true,\n gridProps: { hidden: true },\n fieldType: \"number\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n gridLoadParametersValues={{ mailTemplateId: props.selectedRecord.id }}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"MAIL_ATTACHMENT_PLURAL\")}\n girdIcon=\"paperclip\"\n editAction={{\n isEnabled: true,\n authority: \"MAIL_ATTACHMENT_EDIT\",\n preActionValidation: (record) => {\n record.mailTemplateId = props.selectedRecord.id;\n return true;\n },\n }}\n deleteAction={{ isEnabled: true, authority: \"MAIL_ATTACHMENT_DELETE\" }}\n />\n );\n};\n\nexport default MailAttachmentGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport {\n FormActionProps,\n FormElementProps,\n} from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { UseFormReturn } from \"react-hook-form\";\n\ntype ValidationCritria = {\n isVisible: boolean;\n isMandatory: boolean;\n};\n\nexport type EngineType = \"Gmail\" | \"Azure\";\n\ntype ReportValidationOptions = {\n mailHost: ValidationCritria;\n mailPort: ValidationCritria;\n mailUsername: ValidationCritria;\n mailPassword: ValidationCritria; \n mailProtocol: ValidationCritria;\n isMailSmtpAuthEnabled: ValidationCritria;\n isMailStarttlsEnabled: ValidationCritria;\n isSmtpSSlEnabled: ValidationCritria;\n azureGraphApiClientId: ValidationCritria;\n azureGraphApiClientSecret: ValidationCritria;\n azureGraphApiTenantId: ValidationCritria;\n azureGraphApiScope: ValidationCritria;\n azureGraphApiEmailId: ValidationCritria;\n};\n\ntype validationObjectType = {\n [key in EngineType]: ReportValidationOptions;\n};\n\nconst validationObject: validationObjectType = {\n Gmail: {\n mailHost: { isMandatory: true, isVisible: true },\n mailPort: { isMandatory: true, isVisible: true },\n mailUsername: { isMandatory: true, isVisible: true },\n mailPassword: { isMandatory: true, isVisible: true }, \n mailProtocol: { isMandatory: true, isVisible: true },\n isMailSmtpAuthEnabled: { isMandatory: true, isVisible: true },\n isMailStarttlsEnabled: { isMandatory: true, isVisible: true },\n isSmtpSSlEnabled: { isMandatory: true, isVisible: true },\n azureGraphApiClientId: { isMandatory: false, isVisible: false },\n azureGraphApiClientSecret: { isMandatory: false, isVisible: false },\n azureGraphApiTenantId: { isMandatory: false, isVisible: false },\n azureGraphApiScope: { isMandatory: false, isVisible: false },\n azureGraphApiEmailId: { isMandatory: false, isVisible: false },\n },\n Azure: {\n mailHost: { isMandatory: false, isVisible: false },\n mailPort: { isMandatory: false, isVisible: false },\n mailUsername: { isMandatory: false, isVisible: false },\n mailPassword: { isMandatory: false, isVisible: false }, \n mailProtocol: { isMandatory: false, isVisible: false },\n isMailSmtpAuthEnabled: { isMandatory: false, isVisible: false },\n isMailStarttlsEnabled: { isMandatory: false, isVisible: false },\n isSmtpSSlEnabled: { isMandatory: false, isVisible: false },\n azureGraphApiClientId: { isMandatory: true, isVisible: true },\n azureGraphApiClientSecret: { isMandatory: true, isVisible: true },\n azureGraphApiTenantId: { isMandatory: true, isVisible: true },\n azureGraphApiScope: { isMandatory: true, isVisible: true },\n azureGraphApiEmailId: { isMandatory: true, isVisible: true },\n },\n};\n\nconst adjustFormAccordingToEngineType = (\n value: any,\n formActions: FormActionProps,\n formManager: UseFormReturn\n) => {\n if (value && validationObject[value]) {\n const validationObjects: ReportValidationOptions = validationObject[value];\n const fields = Object.keys(validationObjects);\n for (const field of fields) {\n const validationCritria: ValidationCritria = validationObjects[field];\n if (validationCritria.isVisible) {\n formActions.showField(field);\n } else {\n formActions.hideField(field);\n formManager.setValue(field, null);\n }\n }\n } else {\n formActions.hideField(\"mailHost\");\n formManager.setValue(\"mailHost\", null);\n formActions.hideField(\"mailPort\");\n formManager.setValue(\"mailPort\", null);\n formActions.hideField(\"mailUsername\");\n formManager.setValue(\"mailUsername\", null);\n formActions.hideField(\"mailPassword\");\n formManager.setValue(\"mailPassword\", null); \n formActions.hideField(\"mailProtocol\");\n formManager.setValue(\"mailProtocol\", null);\n formActions.hideField(\"isMailSmtpAuthEnabled\");\n formManager.setValue(\"isMailSmtpAuthEnabled\", null);\n formActions.hideField(\"isMailStarttlsEnabled\");\n formManager.setValue(\"isMailStarttlsEnabled\", null);\n formActions.hideField(\"isSmtpSSlEnabled\");\n formManager.setValue(\"isSmtpSSlEnabled\", null);\n formActions.hideField(\"azureGraphApiClientId\");\n formManager.setValue(\"azureGraphApiClientId\", null);\n formActions.hideField(\"azureGraphApiClientSecret\");\n formManager.setValue(\"azureGraphApiClientSecret\", null);\n formActions.hideField(\"azureGraphApiTenantId\");\n formManager.setValue(\"azureGraphApiTenantId\", null);\n formActions.hideField(\"azureGraphApiScope\");\n formManager.setValue(\"azureGraphApiScope\", null);\n formActions.hideField(\"azureGraphApiEmailId\");\n formManager.setValue(\"azureGraphApiEmailId\", null);\n }\n};\n\nconst MailSenderConfigGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/mailsenderconfig/all\",\n deleteById: \"api/v1/dev/mailsenderconfig\",\n save: \"api/v1/dev/mailsenderconfig\",\n findById: \"api/v1/dev/mailsenderconfig\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Name\",\n fieldName: \"configName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Engine\",\n fieldName: \"mailEngine\",\n required: true,\n fieldType: \"combobox\",\n comboboxValueDataType: \"string\",\n options: [{ value: \"Gmail\" }, { value: \"Azure\" }],\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n formProps: {\n onValueChangeCallBack(\n formValues,\n value,\n formManager,\n formActions,\n selectedRecord\n ) {\n adjustFormAccordingToEngineType(value, formActions, formManager);\n },\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Hostname\",\n fieldName: \"mailHost\",\n required: false,\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"port\",\n fieldName: \"mailPort\",\n required: false,\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"username\",\n fieldName: \"mailUsername\",\n required: false,\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"password\",\n fieldName: \"mailPassword\",\n required: false,\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Workflow Approval Receive Email\",\n fieldName: \"workFlowApprovalReceiveEmail\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Protocol\",\n fieldName: \"mailProtocol\",\n required: false,\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Enable Smtp Auth\",\n fieldName: \"isMailSmtpAuthEnabled\",\n required: false,\n fieldType: \"checkbox\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Enable Start TLS\",\n fieldName: \"isMailStarttlsEnabled\",\n required: false,\n fieldType: \"checkbox\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Enable SSL\",\n fieldName: \"isSmtpSSlEnabled\",\n required: false,\n fieldType: \"checkbox\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Azure Graph API Client Id\",\n fieldName: \"azureGraphApiClientId\",\n required: false,\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Azure Graph API Secret\",\n fieldName: \"azureGraphApiClientSecret\",\n required: false,\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Azure Graph API Tenant Id\",\n fieldName: \"azureGraphApiTenantId\",\n required: false,\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Azure Graph API Scope\",\n fieldName: \"azureGraphApiScope\",\n required: false,\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Azure Graph API Email Id\",\n fieldName: \"azureGraphApiEmailId\",\n required: false,\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Default\",\n fieldName: \"isDefault\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Active\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalIcon: { iconName: \"paper-plane\", prefix: \"fas\" },\n modalTitle: \"Mail Sender Configuration\",\n modalWidth: 300,\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"Mail Sender Configuration\")}\n girdIcon={{ iconName: \"paper-plane\", prefix: \"fas\" }}\n editAction={{ isEnabled: true, authority: \"MAIL_SENDER_CONFIG_EDIT\" }}\n deleteAction={{ isEnabled: true, authority: \"MAIL_SENDER_CONFIG_DELETE\" }}\n formLoadCallBk={(\n formActions: FormActionProps,\n formManager: UseFormReturn,\n record: any\n ) => {\n adjustFormAccordingToEngineType(\n record.mailEngine,\n formActions,\n formManager\n );\n }}\n />\n );\n};\n\nexport default MailSenderConfigGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\n\ntype WorkflowDocumentStatusGridProps = {\n selectedRecord: any;\n};\n\nconst WorkflowDocumentStatusGrid: React.FC<WorkflowDocumentStatusGridProps> = (\n props\n) => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/workflowdocumentstatus/all\",\n deleteById: \"api/v1/dev/workflowdocumentstatus\",\n save: \"api/v1/dev/workflowdocumentstatus\",\n findById: \"api/v1/dev/workflowdocumentstatus\",\n setData: setData,\n });\n const SystemDataQueries = useSelector(\n (state: any) => state.commonStores.stores.SystemDataQueries.data\n );\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_STATUS_DOCUMENT_STATUS_CODE\",\n fieldName: \"documentStatusCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Status Arabic Name\",\n fieldName: \"documentStatusArName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Status English Name\",\n fieldName: \"documentStatusEnName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_STATUS_DOCUMENT_STATUS_ORDER\",\n fieldName: \"documentStatusOrder\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_STATUS_IS_ZERO_STATE\",\n fieldName: \"isZeroState\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"Next Actions Query (must return array of actions in table named workflow_document_action)\",\n fieldName: \"nextActionsQueryId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionValueField: \"id\",\n optionDisplayField: \"queryName\",\n gridProps: { hidden: true },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"Next Action Takers Query (must return array of persons in table named person)\",\n fieldName: \"nextActionTakersQueryId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionValueField: \"id\",\n optionDisplayField: \"queryName\",\n gridProps: { hidden: true },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Next Action Takers Authority\",\n fieldName: \"nextActionTakersAuthority\",\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_STATUS_WORKFLOW_DOCUMENT_ID\",\n fieldName: \"workflowDocumentId\",\n required: false,\n hidden: true,\n gridProps: { hidden: true },\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_STATUS_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n hideInfoBar={true}\n gridLoadParametersValues={{\n workflowDocumentId: props.selectedRecord.id,\n }}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalIcon: \"tag\",\n modalTitle: \"Workflow Document Status\",\n modalWidth: 600,\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"WORKFLOW_DOCUMENT_STATUS_PLURAL\")}\n girdIcon=\"tags\"\n editAction={{\n isEnabled: true,\n authority: \"WORKFLOW_DOCUMENT_STATUS_EDIT\",\n preActionValidation: (record) => {\n record.workflowDocumentId = props.selectedRecord.id;\n return true;\n },\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"WORKFLOW_DOCUMENT_STATUS_DELETE\",\n }}\n />\n );\n};\n\nexport default WorkflowDocumentStatusGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\n\ntype WorkflowDocumentActionMailGridProps = {\n selectedRecord: any;\n};\n\nconst WorkflowDocumentActionMailGrid: React.FC<\n WorkflowDocumentActionMailGridProps\n> = (props) => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/workflowdocumentactionmail/all\",\n deleteById: \"api/v1/dev/workflowdocumentactionmail\",\n save: \"api/v1/dev/workflowdocumentactionmail\",\n findById: \"api/v1/dev/workflowdocumentactionmail\",\n setData: setData,\n });\n\n const SystemMailTemplates = useSelector(\n (state: any) => state.commonStores.stores.SystemMailTemplates.data\n );\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_ACTION_MAIL_DOCUMENT_ACTION_ID\",\n fieldName: \"documentActionId\",\n required: false,\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_ACTION_MAIL_MAIL_TEMPLATE_ID\",\n fieldName: \"mailTemplateId\",\n required: true,\n fieldType: \"combobox\",\n options: SystemMailTemplates,\n optionDisplayField: \"mailTemplateName\",\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_ACTION_MAIL_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n gridLoadParametersValues={{ actionId: props.selectedRecord.id }}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"WORKFLOW_DOCUMENT_ACTION_MAIL_PLURAL\")}\n girdIcon=\"table-cells\"\n editAction={{\n isEnabled: true,\n authority: \"WORKFLOW_DOCUMENT_ACTION_MAIL_EDIT\",\n preActionValidation: (record) => {\n record.documentActionId = props.selectedRecord.id;\n return true;\n },\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"WORKFLOW_DOCUMENT_ACTION_MAIL_DELETE\",\n }}\n />\n );\n};\n\nexport default WorkflowDocumentActionMailGrid;\n","import { useEffect, useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions, useAxios, useWindow } from \"../../../hooks\";\nimport WorkflowDocumentActionMailGrid from \"./WorkflowDocumentActionMailGrid\";\n\ntype WorkflowDocumentActionGridProps = {\n selectedRecord: any;\n};\n\nconst WorkflowDocumentActionGrid: React.FC<WorkflowDocumentActionGridProps> = (\n props\n) => {\n const [selectedRecord, setSelectedRecord] = useState<any>(null);\n const {\n Window: ActionMailsWindow,\n setWindowState: setActionMailWindowState,\n } = useWindow({\n windowTitle: \"Action Mail Notification\",\n windowIcon: \"envelope\",\n width: \"50%\",\n });\n const { t } = useTranslation();\n const { handleGetRequest } = useAxios();\n const [workflowStates, setWorkflowStates] = useState<Array<any>>([]);\n const loadWorkFlowDocumentStates = async () => {\n await handleGetRequest({\n endPointURI: \"api/v1/dev/workflowdocumentstatus/all\",\n showMask: true,\n parameters: {\n workflowDocumentId: props.selectedRecord.id,\n },\n successCallBkFn: (response: any) => {\n setWorkflowStates(response.data);\n },\n });\n };\n useEffect(() => {\n loadWorkFlowDocumentStates();\n }, [props.selectedRecord]);\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/workflowdocumentaction/all\",\n deleteById: \"api/v1/dev/workflowdocumentaction\",\n save: \"api/v1/dev/workflowdocumentaction\",\n findById: \"api/v1/dev/workflowdocumentaction\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_ACTION_DOCUMENT_ACTION_CODE\",\n fieldName: \"documentActionCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Action Arabic Name\",\n fieldName: \"documentActionArName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Action English Name\",\n fieldName: \"documentActionEnName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_ACTION_NEXT_DOCUMENT_STATUS_ID\",\n fieldName: \"nextDocumentStatusId\",\n required: true,\n fieldType: \"combobox\",\n options: workflowStates,\n optionDisplayField: \"documentStatusCode\",\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"Post Action Endpoint ( system will call it with post method and parameters refDocumentId , workflowActionId)\",\n fieldName: \"postActionEndpoint\",\n required: false,\n fieldType: \"text\",\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"Pre Action Endpoint ( system will call it with post method and parameters refDocumentId , workflowActionId)\",\n fieldName: \"preActionEndpoint\",\n required: false,\n fieldType: \"text\",\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_ACTION_REQUIRE_COMMENT\",\n fieldName: \"requireComment\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_ACTION_WORKFLOW_DOCUMENT_ID\",\n fieldName: \"workflowDocumentId\",\n required: false,\n fieldType: \"number\",\n hidden: true,\n gridProps: { hidden: true },\n },\n },\n ];\n\n return (\n <>\n <ActionMailsWindow>\n <WorkflowDocumentActionMailGrid selectedRecord={selectedRecord} />\n </ActionMailsWindow>\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n gridLoadParametersValues={{\n workflowDocumentId: props.selectedRecord.id,\n }}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalIcon: \"stamp\",\n modalTitle: \"Workflow Document Action\",\n modalWidth: 700,\n },\n }}\n rowActions={[\n {\n label: \"Action Mail Notifications\",\n icon: \"envelope\",\n actionFn: async (data) => {\n setSelectedRecord(data);\n setActionMailWindowState(true);\n },\n },\n ]}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"WORKFLOW_DOCUMENT_ACTION_PLURAL\")}\n girdIcon=\"stamp\"\n editAction={{\n isEnabled: true,\n authority: \"WORKFLOW_DOCUMENT_ACTION_EDIT\",\n preActionValidation: (record) => {\n record.workflowDocumentId = props.selectedRecord.id;\n return true;\n },\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"WORKFLOW_DOCUMENT_ACTION_DELETE\",\n }}\n />\n </>\n );\n};\n\nexport default WorkflowDocumentActionGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\n\ntype DashboardWidgetGridProps = {\n selectedRecord: any;\n};\n\nconst DashboardWidgetGrid: React.FC<DashboardWidgetGridProps> = (props) => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const SystemWidgets = useSelector(\n (state: any) => state.commonStores.stores.SystemWidgets.data\n );\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/dashboardwidget/all\",\n deleteById: \"api/v1/dev/dashboardwidget\",\n save: \"api/v1/dev/dashboardwidget\",\n findById: \"api/v1/dev/dashboardwidget\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DASHBOARD_WIDGET_DASHBOARD_ID\",\n fieldName: \"dashboardId\",\n required: false,\n hidden: true,\n gridProps: { hidden: true },\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DASHBOARD_WIDGET_WIDGET_ID\",\n fieldName: \"widgetId\",\n required: true,\n fieldType: \"combobox\",\n options: SystemWidgets,\n optionValueField: \"id\",\n optionDisplayField: \"widgetName\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DASHBOARD_WIDGET_WIDGET_ORDER\",\n fieldName: \"widgetOrder\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DASHBOARD_WIDGET_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n hideInfoBar={true}\n formElements={formElements}\n gridLoadParametersValues={{ dashboardId: props.selectedRecord.id }}\n keyColumnName={\"id\"}\n gridTitle={t(\"DASHBOARD_WIDGET_PLURAL\")}\n girdIcon=\"table-cells\"\n editAction={{\n isEnabled: true,\n authority: \"DASHBOARD_WIDGET_EDIT\",\n preActionValidation: async (data) => {\n data.dashboardId = props.selectedRecord.id;\n return true;\n },\n }}\n deleteAction={{ isEnabled: true, authority: \"DASHBOARD_WIDGET_DELETE\" }}\n />\n );\n};\n\nexport default DashboardWidgetGrid;\n","\nimport { ADMINISTRATION_ROUTES } from \"./administration\";\nimport { SystemRoute } from \"./types\";\n\nexport const SYSTEM_ROUTES: Array<SystemRoute> = [...ADMINISTRATION_ROUTES];\n","import { SystemRoute } from \"../types\";\nimport { adminRoutes } from \"./adminRoutes\";\nimport { devRoutes } from \"./devRoutes\";\n\nexport const ADMINISTRATION_ROUTES: Array<SystemRoute> = [\n ...adminRoutes,\n ...devRoutes,\n];\n","import { SystemRoute } from \"../types\";\nimport OrganizationGrid from \"../../components/administration/admin/OrganizationGrid\";\nimport OrganizationMemberGrid from \"../../components/administration/admin/OrganizationMemberGrid\";\nimport OrganizationMemberRoleGrid from \"../../components/administration/admin/OrganizationMemberRoleGrid\";\nimport OrganizationRankGrid from \"../../components/administration/admin/OrganizationRankGrid\";\nimport OrganizationUnitGrid from \"../../components/administration/admin/OrganizationUnitGrid\";\nimport OrganizationUnitTypeGrid from \"../../components/administration/admin/OrganizationUnitTypeGrid\";\nimport PersonGrid from \"../../components/administration/admin/PersonGrid\";\nimport SystemApplicationGrid from \"../../components/administration/admin/SystemApplicationGrid\";\nimport SystemApplicationAuthorityGrid from \"../../components/administration/admin/SystemApplicationAuthorityGrid\";\nimport SystemApplicationModuleGrid from \"../../components/administration/admin/SystemApplicationModuleGrid\";\nimport SystemApplicationRoleGrid from \"../../components/administration/admin/SystemApplicationRoleGrid\";\nimport SystemApplicationRoleAuthorityGrid from \"../../components/administration/admin/SystemApplicationRoleAuthorityGrid\";\nimport OrganizationApplicationModuleGrid from \"../../components/administration/admin/OrganizationApplicationModuleGrid\";\nexport const adminRoutes: Array<SystemRoute> = [\n {\n path: \"admin/organizations\",\n component: OrganizationGrid,\n authority: \"ORGANIZATION_VIEW\",\n },\n {\n path: \"admin/organizationmembers\",\n component: OrganizationMemberGrid,\n authority: \"ORGANIZATION_MEMBER_VIEW\",\n },\n {\n path: \"admin/organizationmemberroles\",\n component: OrganizationMemberRoleGrid,\n authority: \"ORGANIZATION_MEMBER_ROLE_VIEW\",\n },\n {\n path: \"admin/organizationranks\",\n component: OrganizationRankGrid,\n authority: \"ORGANIZATION_RANK_VIEW\",\n },\n {\n path: \"admin/organizationunits\",\n component: OrganizationUnitGrid,\n authority: \"ORGANIZATION_UNIT_VIEW\",\n },\n {\n path: \"admin/organizationunittypes\",\n component: OrganizationUnitTypeGrid,\n authority: \"ORGANIZATION_UNIT_TYPE_VIEW\",\n },\n {\n path: \"admin/persons\",\n component: PersonGrid,\n authority: \"PERSON_VIEW\",\n },\n {\n path: \"admin/systemapplications\",\n component: SystemApplicationGrid,\n authority: \"SYSTEM_APPLICATION_VIEW\",\n },\n {\n path: \"admin/systemapplicationauthorities\",\n component: SystemApplicationAuthorityGrid,\n authority: \"SYSTEM_APPLICATION_AUTHORITY_VIEW\",\n },\n {\n path: \"admin/systemapplicationmodules\",\n component: SystemApplicationModuleGrid,\n authority: \"SYSTEM_APPLICATION_MODULE_VIEW\",\n },\n {\n path: \"admin/systemapplicationroles\",\n component: SystemApplicationRoleGrid,\n authority: \"SYSTEM_APPLICATION_ROLE_VIEW\",\n },\n {\n path: \"admin/systemapplicationroleauthorities\",\n component: SystemApplicationRoleAuthorityGrid,\n authority: \"SYSTEM_APPLICATION_ROLE_AUTHORITY_VIEW\",\n },\n {\n path: \"admin/org/apps\",\n component: OrganizationApplicationModuleGrid,\n authority: \"ORGANIZATION_ADMIN\",\n },\n {\n path: \"admin/org/unit/types\",\n component: OrganizationUnitTypeGrid,\n authority: \"DEVELOPMENT_ADMIN\",\n },\n {\n path: \"admin/org/units\",\n component: OrganizationUnitGrid,\n authority: \"DEVELOPMENT_ADMIN\",\n },\n {\n path: \"admin/org/ranks\",\n component: OrganizationRankGrid,\n authority: \"DEVELOPMENT_ADMIN\",\n },\n];\n\n// import { adminRoutes } from \"./adminRoutes\";\n// [...adminRoutes]\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useWindow } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport OrganizationApplicationModuleGrid from \"./OrganizationApplicationModuleGrid\";\nimport OrganizationUnitTypeGrid from \"./OrganizationUnitTypeGrid\";\nimport OrganizationUnitGrid from \"./OrganizationUnitGrid\";\nimport OrganizationRankGrid from \"./OrganizationRankGrid\";\nimport { Box } from \"@mui/material\";\nimport { AttachmentImageViewer } from \"../../templates\";\n\nconst OrganizationGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"SystemOrganizations\",\n deleteById: \"api/v1/org/admin/organization\",\n save: \"api/v1/org/admin/organization\",\n findById: \"api/v1/org/admin/organization\",\n setData: setData,\n });\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Logo\",\n fieldName: \"custom\",\n fieldType: \"custom\",\n gridProps: {\n muiProps: {\n align: \"center\",\n headerAlign: \"center\",\n renderCell: (params) => {\n return (\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n height: \"100%\",\n }}\n >\n <AttachmentImageViewer\n showAsAvatar={true}\n attachmentCode=\"ORGANIZATION_LOGOS\"\n refKey={params.id + \"\"}\n />\n </Box>\n );\n },\n },\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_ORGANIZATION_CODE\",\n fieldName: \"organizationCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_ORGANIZATION_AR_NAME\",\n fieldName: \"organizationArName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_ORGANIZATION_EN_NAME\",\n fieldName: \"organizationEnName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <>\n <TemplateGrid\n attachment={{ attachmentCode: \"ORGANIZATION_LOGOS\" }}\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"ORGANIZATION_PLURAL\"\n girdIcon=\"globe\"\n editAction={{ isEnabled: true, authority: \"ORGANIZATION_EDIT\" }}\n deleteAction={{ isEnabled: true, authority: \"ORGANIZATION_DELETE\" }}\n />\n </>\n );\n};\n\nexport default OrganizationGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport {useApiActions} from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\n\nconst OrganizationMemberRoleGrid: React.FC = () => {\n\tconst { t } = useTranslation();\n\tconst [data, setData] = useState([]);\n const apiActions = useApiActions({\n \tfindAll: \"api/v1/admin/organizationmemberrole/all\",\n \tdeleteById: \"api/v1/admin/organizationmemberrole\",\n \tsave: \"api/v1/admin/organizationmemberrole\",\n\t\tfindById: \"api/v1/admin/organizationmemberrole\",\n \tsetData: setData,\n \t});\n\t\n\tconst formElements: Array<FormElementProps> = [\n\t\t\t\t\t\t\t\t\t\t\t{\n \t\t\t\ttype: \"field\",\n \t\t\t\tmode: \"props\",\n \t\t\t\tprops: {\n \t\t\t\tfieldLabel: \"ORGANIZATION_MEMBER_ROLE_IS_ACTIVE\",\n \t\t\t\tfieldName: \"isActive\",\n \t\t\t\trequired: false,\n \t\t\t\tfieldType: \"checkbox\",\n \t\t\t\t},\n \t\t\t},\n\t\t\t\t\t \t\t\t \t\t\t \t\t\t \t\t\t\t\t\t\t\t\t\t{\n \t\t\t\ttype: \"field\",\n \t\t\t\tmode: \"props\",\n \t\t\t\tprops: {\n \t\t\t\tfieldLabel: \"ORGANIZATION_MEMBER_ROLE_END_DATE\",\n \t\t\t\tfieldName: \"endDate\",\n \t\t\t\trequired: false,\n \t\t\t\tfieldType: \"datetime\",\n \t\t\t\t},\n \t\t\t},\n\t\t\t\t\t \t\t\t \t\t\t \t\t\t\t\t\t \t\t\t{\n \t\t\t\ttype: \"field\",\n \t\t\t\tmode: \"props\",\n \t\t\t\tprops: {\n \t\t\t\tfieldLabel: \"ORGANIZATION_MEMBER_ROLE_ORGANIZATION_MEMBER_ID\",\n \t\t\t\tfieldName: \"organizationMemberId\",\n \t\t\t\trequired: true,\n \t\t\t\tfieldType: \"text\",\n \t\t\t\t},\n \t\t\t},\t\t\t\n\t\t\t\t\t \t\t\t\t\t\t\t\t\t\t{\n \t\t\t\ttype: \"field\",\n \t\t\t\tmode: \"props\",\n \t\t\t\tprops: {\n \t\t\t\tfieldLabel: \"ORGANIZATION_MEMBER_ROLE_START_DATE\",\n \t\t\t\tfieldName: \"startDate\",\n \t\t\t\trequired: false,\n \t\t\t\tfieldType: \"datetime\",\n \t\t\t\t},\n \t\t\t},\n\t\t\t\t\t \t\t\t\t\t\t \t\t\t{\n \t\t\t\ttype: \"field\",\n \t\t\t\tmode: \"props\",\n \t\t\t\tprops: {\n \t\t\t\tfieldLabel: \"ORGANIZATION_MEMBER_ROLE_SYSTEM_APPLICATION_ROLE_ID\",\n \t\t\t\tfieldName: \"systemApplicationRoleId\",\n \t\t\t\trequired: true,\n \t\t\t\tfieldType: \"text\",\n \t\t\t\t},\n \t\t\t},\t\t\t\n\t\t\t\t\t \t\t\t \t\t\t \t\t\t \t\t];\n\n\treturn (\n \t<TemplateGrid\n \t\tapiActions={apiActions}\n \t\tdata={data}\n \t\tsetData={setData}\n \t\teditMode={{ editMode: \"row\"}}\n \t\tformElements={formElements}\n\t\t\tkeyColumnName={\"id\"}\n \t\tgridTitle=\"ORGANIZATION_MEMBER_ROLE_PLURAL\"\n \t\tgirdIcon=\"table-cells\"\n \t\teditAction={{ isEnabled: true, authority: \"ORGANIZATION_MEMBER_ROLE_EDIT\" }}\n \t\tdeleteAction={{ isEnabled: true, authority: \"ORGANIZATION_MEMBER_ROLE_DELETE\" }}\n \t/>\n );\n};\n\nexport default OrganizationMemberRoleGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useSession, useWindow } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { toast } from \"react-toastify\";\nimport OrganizationMemberGrid from \"./OrganizationMemberGrid\";\nimport { Box } from \"@mui/material\";\nimport AttachmentImageViewer from \"../../templates/attachment/AttachmentImageViewer\";\nimport { useSelector } from \"react-redux\";\nimport OrgMemberRoleForm from \"./OrgMemberRoleForm\";\nimport ChangePasswordPanel from \"./ChangePasswordPanel\";\n\nconst PersonGrid: React.FC = () => {\n const { t } = useTranslation();\n const [selectedPerson, setSelectedPerson] = useState<any>(null);\n const { UserInfo } = useSession();\n const CurrentOrganizationRanks = useSelector(\n (state: any) => state.commonStores.stores.CurrentOrganizationRanks.data\n );\n const CurrentOrganizationUnits = useSelector(\n (state: any) => state.commonStores.stores.CurrentOrganizationUnits.data\n );\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/public/person/all\",\n deleteById: \"api/v1/admin/person\",\n save: \"api/v1/admin/person\",\n findById: \"api/v1/admin/person\",\n setData: setData,\n });\n const [selectedRecord, setSelectedRecord] = useState<any>(null);\n const {\n Window: OrganizationMembersWindow,\n setWindowState: setOrganizationMemberWindowState,\n } = useWindow({\n windowTitle: \"Organizations Membership\",\n windowIcon: \"globe\",\n });\n const {\n Window: OrganizationMemberRolesWindow,\n setWindowState: setOrganizationMemberRolesWindowState,\n } = useWindow({\n windowIcon: \"tag\",\n windowTitle: \"Organization Member Roles\",\n width: \"50%\",\n });\n const {\n Window: ChangePasswordWindow,\n setWindowState: setChangePasswordWindow,\n } = useWindow({\n windowIcon: \"key\",\n windowTitle: \"Change Password\",\n width: \"fit-content\",\n height: \"fit-content\",\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n hidden: true,\n fieldLabel: \"id\",\n fieldName: \"id\",\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n hidden: true,\n fieldLabel: \"organizationMemberId\",\n fieldName: \"organizationMemberId\",\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Image\",\n fieldName: \"custom\",\n fieldType: \"custom\",\n gridProps: {\n muiProps: {\n align: \"center\",\n headerAlign: \"center\",\n renderCell: (params) => {\n return (\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n height: \"100%\",\n }}\n >\n <AttachmentImageViewer\n showAsAvatar={true}\n attachmentCode=\"EMPLOYEE_PHOTOS\"\n refKey={params.id + \"\"}\n />\n </Box>\n );\n },\n },\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"PERSON_EMPLOYEE_AR_NAME\",\n fieldName: \"employeeArName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"PERSON_EMPLOYEE_EN_NAME\",\n fieldName: \"employeeEnName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"PERSON_EMAIL\",\n fieldName: \"email\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"PERSON_MOBILE_NUMBER\",\n fieldName: \"mobileNumber\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_MEMBER_ORGANIZATION_RANK_ID\",\n fieldName: \"organizationRankId\",\n required: false,\n fieldType: \"combobox\",\n options: CurrentOrganizationRanks,\n optionValueField: \"id\",\n optionDisplayField: \"rankEnName\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_MEMBER_ORGANIZATION_UNIT_ID\",\n fieldName: \"organizationUnitId\",\n required: false,\n fieldType: \"combobox\",\n options: CurrentOrganizationUnits,\n optionValueField: \"id\",\n optionDisplayField: \"organizationUnitEnName\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Membership number\",\n fieldName: \"organizationMembershipNumber\",\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n hidden: true,\n gridProps: { hidden: true },\n fieldLabel: \"PERSON_PASSWORD\",\n fieldName: \"password\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"PERSON_USERNAME\",\n fieldName: \"username\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n hidden: true,\n fieldLabel: \"Ref Source\",\n fieldName: \"refSource\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n hidden: true,\n fieldLabel: \"PERSON_EMPLOYEE_NUMBER\",\n fieldName: \"refSyncNumber\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"PERSON_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <>\n <OrganizationMemberRolesWindow>\n <OrgMemberRoleForm\n selectedRecord={selectedRecord}\n closeModalFn={() => {\n setOrganizationMemberRolesWindowState(false);\n }}\n />\n </OrganizationMemberRolesWindow>\n <OrganizationMembersWindow>\n <OrganizationMemberGrid selectedPerson={selectedPerson} />\n </OrganizationMembersWindow>\n <ChangePasswordWindow>\n <ChangePasswordPanel\n selectedPerson={selectedPerson}\n isSelfService={false}\n onSuccessCallBk={() => {\n setChangePasswordWindow(false);\n }}\n />\n </ChangePasswordWindow>\n <TemplateGrid\n attachment={{ attachmentCode: \"EMPLOYEE_PHOTOS\" }}\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalIcon: \"user\",\n modalTitle: \"Person Profile\",\n modalWidth: 300,\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"PERSON_PLURAL\"\n rowActions={[\n {\n icon: \"key\",\n label: \"Change User Password\",\n actionFn: async (data) => {\n setSelectedPerson(data);\n setChangePasswordWindow(true);\n },\n },\n {\n icon: \"tags\",\n label: \"Current Organization User Roles\",\n isActionDisabledForRecord: (data) => {\n return !data?.organizationMemberId;\n },\n actionFn: async (data) => {\n setSelectedRecord({\n organizationId: UserInfo?.currentOrganization?.id,\n id: data?.organizationMemberId,\n });\n setOrganizationMemberRolesWindowState(true);\n },\n },\n {\n icon: \"globe\",\n label: \"User Organizations\",\n actionFn: async (data) => {\n setSelectedPerson(data);\n setOrganizationMemberWindowState(true);\n },\n },\n ]}\n girdIcon=\"users\"\n editAction={{\n isEnabled: true,\n authority: \"PERSON_EDIT\",\n preActionValidation: (data) => {\n if (\n data.refSource != undefined &&\n data.refSource != null &&\n data.refSource != \"\"\n ) {\n toast.error(\n \"This Person Was synced from other system therefore you can't modify this record\"\n );\n return false;\n }\n return true;\n },\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"PERSON_DELETE\",\n preActionValidation: (data) => {\n if (\n data.refSource != undefined &&\n data.refSource != null &&\n data.refSource != \"\"\n ) {\n toast.error(\n \"This Person Was synced from other system therefore you can't modify this record\"\n );\n return false;\n }\n return true;\n },\n }}\n />\n </>\n );\n};\n\nexport default PersonGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useWindow } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\n\nconst SystemApplicationGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/org/admin/systemapplication/all\",\n deleteById: \"api/v1/org/admin/systemapplication\",\n save: \"api/v1/org/admin/systemapplication\",\n findById: \"api/v1/org/admin/systemapplication\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_APPLICATION_CODE\",\n fieldName: \"applicationCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_APPLICATION_NAME\",\n fieldName: \"applicationName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_APPLICATION_DESCRIPTION\",\n fieldName: \"applicationDescription\",\n required: false,\n fieldType: \"text\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <>\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"SYSTEM_APPLICATION_PLURAL\"\n girdIcon=\"window-restore\"\n editAction={{ isEnabled: true, authority: \"SYSTEM_APPLICATION_EDIT\" }}\n deleteAction={{\n isEnabled: true,\n authority: \"SYSTEM_APPLICATION_DELETE\",\n }}\n />\n </>\n );\n};\n\nexport default SystemApplicationGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\n\nconst SystemApplicationRoleAuthorityGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/admin/systemapplicationroleauthority/all\",\n deleteById: \"api/v1/admin/systemapplicationroleauthority\",\n save: \"api/v1/admin/systemapplicationroleauthority\",\n findById: \"api/v1/admin/systemapplicationroleauthority\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"SYSTEM_APPLICATION_ROLE_AUTHORITY_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"SYSTEM_APPLICATION_ROLE_AUTHORITY_SYSTEM_APPLICATION_AUTHORITY_ID\",\n fieldName: \"systemApplicationAuthorityId\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"SYSTEM_APPLICATION_ROLE_AUTHORITY_SYSTEM_APPLICATION_ROLE_ID\",\n fieldName: \"systemApplicationRoleId\",\n required: true,\n fieldType: \"text\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"SYSTEM_APPLICATION_ROLE_AUTHORITY_PLURAL\"\n girdIcon=\"table-cells\"\n editAction={{\n isEnabled: true,\n authority: \"SYSTEM_APPLICATION_ROLE_AUTHORITY_EDIT\",\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"SYSTEM_APPLICATION_ROLE_AUTHORITY_DELETE\",\n }}\n />\n );\n};\n\nexport default SystemApplicationRoleAuthorityGrid;\n","import { useEffect, useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useAxios } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useSelector } from \"react-redux\";\n\nconst OrganizationApplicationModuleGrid: React.FC = () => {\n const { t } = useTranslation();\n const { handleGetRequest } = useAxios();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/org/admin/organizationapplicationmodule/all\",\n deleteById: \"api/org/v1/admin/organizationapplicationmodule\",\n save: \"api/v1/org/admin/organizationapplicationmodule\",\n findById: \"api/org/v1/admin/organizationapplicationmodule\",\n setData: setData,\n });\n const SystemApplicationModules = useSelector(\n (state: any) => state.commonStores.stores.SystemApplicationModules.data\n );\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"ORGANIZATION_APPLICATION_MODULE_SYSTEM_APPLICATION_MODULE_ID\",\n fieldName: \"systemApplicationModuleId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemApplicationModules,\n optionDisplayField: \"moduleName\",\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n hidden: true,\n gridProps: {\n hidden: true,\n },\n fieldLabel: \"ORGANIZATION_APPLICATION_MODULE_ORGANIZATION_ID\",\n fieldName: \"organizationId\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_APPLICATION_MODULE_SUBSCRIPTION_DATE\",\n fieldName: \"subscriptionDate\",\n required: true,\n fieldType: \"date\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_APPLICATION_MODULE_EXPIRATION_DATE\",\n fieldName: \"expirationDate\",\n required: false,\n fieldType: \"date\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ORGANIZATION_APPLICATION_MODULE_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n hideInfoBar={true}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle=\"ORGANIZATION_APPLICATION_MODULE_PLURAL\"\n girdIcon=\"layer-group\"\n editAction={{\n isEnabled: true,\n authority: \"ORGANIZATION_APPLICATION_MODULE_EDIT\",\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"ORGANIZATION_APPLICATION_MODULE_DELETE\",\n }}\n />\n );\n};\n\nexport default OrganizationApplicationModuleGrid;\n","import { SystemRoute } from \"../types\";\nimport BluePrintGrid from \"../../components/administration/dev/BluePrintGrid\";\nimport DataQueryGrid from \"../../components/administration/dev/DataQueryGrid\";\nimport DatasourceConnectionGrid from \"../../components/administration/dev/DatasourceConnectionGrid\";\nimport EntityParameterGrid from \"../../components/administration/dev/EntityParameterGrid\";\n\nimport LookupGrid from \"../../components/administration/dev/LookupGrid\";\n\nimport ReportGrid from \"../../components/administration/dev/ReportGrid\";\nimport MailTemplateGrid from \"../../components/administration/dev/MailTemplateGrid\";\nimport MailSenderConfigGrid from \"../../components/administration/dev/MailSenderConfigGrid\";\nimport WorkflowDocumentGrid from \"../../components/administration/dev/WorkflowDocumentGrid\";\nimport WidgetGrid from \"../../components/administration/dev/WidgetGrid\";\nimport DashboardGrid from \"../../components/administration/dev/DashboardGrid\";\nimport DashboardRouteView from \"../../components/templates/visuals/DashboardRouteView\";\nimport WorkflowDocumentMailLogGrid from \"../../components/administration/dev/WorkflowDocumentMailLogGrid\";\nimport MailNotificationQueueGrid from \"../../components/administration/dev/MailNotificationQueueGrid\";\nimport SystemApplicationAuthorityGrid from \"../../components/administration/admin/SystemApplicationAuthorityGrid\";\nimport SystemApplicationRoleGrid from \"../../components/administration/admin/SystemApplicationRoleGrid\";\nimport SystemApplicationModuleGrid from \"../../components/administration/admin/SystemApplicationModuleGrid\";\nimport AttachmentConfigGrid from \"../../components/administration/dev/AttachmentConfigGrid\";\nimport NotificationGrid from \"../../components/administration/dev/NotificationGrid\";\nimport MyNotificationsPanel from \"../../components/common/MyNotificationsPanel\";\nimport WorkflowRouteComponent from \"../../components/templates/workflow/WorkflowRouteComponent\";\n\nexport const devRoutes: Array<SystemRoute> = [\n {\n path: \"dev/blueprints\",\n component: BluePrintGrid,\n authority: \"BLUE_PRINT_VIEW\",\n },\n {\n path: \"dev/dataqueries\",\n component: DataQueryGrid,\n authority: \"DATA_QUERY_VIEW\",\n },\n {\n path: \"dev/datasourceconnections\",\n component: DatasourceConnectionGrid,\n authority: \"DATASOURCE_CONNECTION_VIEW\",\n },\n {\n path: \"dev/entityparameters\",\n component: EntityParameterGrid,\n authority: \"ENTITY_PARAMETER_VIEW\",\n },\n {\n path: \"dev/lookups\",\n component: LookupGrid,\n authority: \"LOOKUP_VIEW\",\n },\n {\n path: \"dev/reports\",\n component: ReportGrid,\n authority: \"REPORT_VIEW\",\n },\n {\n path: \"dev/mailtemplates\",\n component: MailTemplateGrid,\n authority: \"MAILTEMPLATE_VIEW\",\n },\n {\n path: \"dev/mailsender/config\",\n component: MailSenderConfigGrid,\n authority: \"MAILTEMPLATE_VIEW\",\n },\n {\n path: \"dev/workflowdocuments\",\n component: WorkflowDocumentGrid,\n authority: \"WORKFLOW_DOCUMENT_VIEW\",\n },\n {\n path: \"dev/widgets\",\n component: WidgetGrid,\n authority: \"WIDGET_VIEW\",\n },\n {\n path: \"dev/dashboards\",\n component: DashboardGrid,\n authority: \"DASHBOARD_VIEW\",\n },\n {\n path: \"dashboard/:dashboardCode\",\n component: DashboardRouteView,\n },\n {\n path: \"dev/workflowdocumentmaillogs\",\n component: WorkflowDocumentMailLogGrid,\n },\n {\n path: \"dev/mailnotificationqueues\",\n component: MailNotificationQueueGrid,\n },\n {\n path: \"dev/system/authorities\",\n component: SystemApplicationAuthorityGrid,\n },\n {\n path: \"dev/system/roles\",\n component: SystemApplicationRoleGrid,\n },\n {\n path: \"dev/system/lookups\",\n component: LookupGrid,\n },\n {\n path: \"dev/system/modules\",\n component: SystemApplicationModuleGrid,\n },\n {\n path: \"dev/attachmentconfigs\",\n component: AttachmentConfigGrid,\n },\n {\n path: \"dev/notifications\",\n component: NotificationGrid,\n },\n {\n path: \"myNotifications\",\n component: MyNotificationsPanel,\n },\n {\n path: \"workflow/:workflowDocumentCode/:refDocumentId\",\n component: WorkflowRouteComponent,\n },\n];\n\n// import { devRoutes } from \"./devRoutes\";\n// [...devRoutes]\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useSelector } from \"react-redux\";\n\nconst BluePrintGrid: React.FC = () => {\n const { t } = useTranslation();\n const SystemDataQueries = useSelector(\n (state: any) => state.commonStores.stores.SystemDataQueries.data\n );\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"SystemBluePrints\",\n deleteById: \"api/v1/dev/blueprint\",\n save: \"api/v1/dev/blueprint\",\n findById: \"api/v1/dev/blueprint\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"BLUE_PRINT_BLUE_PRINT_CODE\",\n fieldName: \"bluePrintCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"BLUE_PRINT_QUERY_ID\",\n fieldName: \"queryId\",\n required: true,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionDisplayField: \"queryName\",\n optionValueField: \"id\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\", reloadAfterSave: true }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"BLUE_PRINT_PLURAL\")}\n girdIcon=\"table-cells\"\n editAction={{ isEnabled: true, authority: \"BLUE_PRINT_EDIT\" }}\n deleteAction={{ isEnabled: true, authority: \"BLUE_PRINT_DELETE\" }}\n />\n );\n};\n\nexport default BluePrintGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useWindow } from \"../../../hooks\";\nimport {\n FormElementProps,\n FormValueChangeCallBk,\n} from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useSelector } from \"react-redux\";\nimport DataQueryParametersForm from \"./DataQueryParametersForm\";\nimport DataQueryParameterGrid from \"./DataQueryParameterGrid\";\n\nconst DataQueryGrid: React.FC = () => {\n const [selectedRecord, setSelectedRecord] = useState<any>(null);\n const {\n Window: DataQueryParameterWindow,\n setWindowState: setDataQueryParameterWindow,\n } = useWindow({\n width: \"50%\",\n windowTitle: \"Data query parameters\",\n windowIcon: \"p\",\n });\n const SystemDataSources = useSelector(\n (state: any) => state.commonStores.stores.SystemDataSources.data\n );\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"SystemDataQueries\",\n deleteById: \"api/v1/dev/dataquery\",\n save: \"api/v1/dev/dataquery\",\n findById: \"api/v1/dev/dataquery\",\n setData: setData,\n });\n\n const adjustFormAfterValueChange: FormValueChangeCallBk = (\n formValues,\n formActions,\n formManager,\n fieldName,\n newValue\n ) => {\n if (fieldName) {\n if (fieldName === \"useSysCon\" && newValue == true) {\n formActions.hideField(\"datasourceConId\");\n formManager.setValue(\"datasourceConId\", null);\n } else {\n formActions.showField(\"datasourceConId\");\n }\n } else {\n if (formValues?.useSysCon) {\n formActions.hideField(\"datasourceConId\");\n }\n }\n };\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_QUERY_NAME\",\n fieldName: \"queryName\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_USE_SYS_CON\",\n fieldName: \"useSysCon\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_DATASOURCE_CON_ID\",\n fieldName: \"datasourceConId\",\n required: false,\n options: SystemDataSources,\n optionDisplayField: \"connectionName\",\n optionValueField: \"id\",\n fieldType: \"combobox\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATA_QUERY_QUERY_STR\",\n fieldName: \"queryStr\",\n formProps: { fieldHeight: 400 },\n gridProps: {\n hidden: true,\n },\n muiTextFieldProps: {\n multiline: true,\n rows: 4,\n },\n required: false,\n fieldType: \"text\",\n },\n },\n ];\n\n return (\n <>\n <DataQueryParameterWindow>\n <DataQueryParameterGrid selectedRecord={selectedRecord} />\n </DataQueryParameterWindow>\n <TemplateGrid\n apiActions={apiActions}\n rowActions={[\n {\n label: \"Query Parameters\",\n actionFn: async (data) => {\n setSelectedRecord(data);\n setDataQueryParameterWindow(true);\n },\n icon: \"p\",\n },\n ]}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalTitle: \"System Query\",\n modalWidth: 600,\n modalIcon: \"file-code\",\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"DATA_QUERY_PLURAL\")}\n girdIcon=\"table-cells\"\n editAction={{ isEnabled: true, authority: \"DATA_QUERY_EDIT\" }}\n deleteAction={{ isEnabled: true, authority: \"DATA_QUERY_DELETE\" }}\n formProps={{ formValuesChangeCallBk: adjustFormAfterValueChange }}\n />\n </>\n );\n};\n\nexport default DataQueryGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions, useAxios } from \"../../../hooks\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useSelector } from \"react-redux\";\nimport { toast } from \"react-toastify\";\n\nconst DatasourceConnectionGrid: React.FC = () => {\n const { handleGetRequest } = useAxios();\n const SystemDataSourceType = useSelector(\n (state: any) => state.commonStores.stores.SystemDataSourceType.data\n );\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n deleteById: \"api/v1/dev/datasourceconnection\",\n save: \"api/v1/dev/datasourceconnection\",\n findById: \"api/v1/dev/datasourceconnection\",\n setData: setData,\n commonStoreKey: \"SystemDataSources\",\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ID\",\n fieldName: \"id\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATASOURCE_CONNECTION_CONNECTION_NAME\",\n fieldName: \"connectionName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATASOURCE_CONNECTION_DATASOURCE_TYPE\",\n fieldName: \"datasourceType\",\n required: true,\n fieldType: \"combobox\",\n options: SystemDataSourceType,\n comboboxValueDataType: \"string\",\n optionValueField: \"value\",\n optionDisplayField: \"value\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATASOURCE_CONNECTION_DATASOURCE_URL\",\n fieldName: \"datasourceUrl\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATASOURCE_CONNECTION_DATASOURCE_USERNAME\",\n fieldName: \"datasourceUsername\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATASOURCE_CONNECTION_DATASOURCE_PASSWORD\",\n fieldName: \"datasourcePassword\",\n required: true,\n fieldType: \"text\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DATASOURCE_CONNECTION_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalTitle: \"Datasource Connection\",\n modalIcon: \"plug\",\n modalWidth: 300,\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"DATASOURCE_CONNECTION_PLURAL\")}\n girdIcon=\"plug\"\n rowActions={[\n {\n icon: \"plug\",\n label: \"test connection\",\n actionFn: async (data) => {\n await handleGetRequest({\n endPointURI: \"api/v1/dev/datasourceConnection/test\",\n showMask: true,\n parameters: {\n id: data.id,\n },\n // loadingMessage: \"checking datasource connectivity\",\n successCallBkFn: (response: any) => {\n toast.success(response.data);\n },\n });\n },\n },\n ]}\n editAction={{ isEnabled: true, authority: \"DATASOURCE_CONNECTION_EDIT\" }}\n deleteAction={{\n isEnabled: true,\n authority: \"DATASOURCE_CONNECTION_DELETE\",\n }}\n />\n );\n};\n\nexport default DatasourceConnectionGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { useApiActions } from \"../../../hooks\";\nimport {\n FormElementProps,\n FormValueChangeCallBk,\n} from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useSelector } from \"react-redux\";\nimport { DATE_FORMAT, DATE_TIME_FORMAT } from \"../../../util\";\n\nconst EntityParameterGrid: React.FC = () => {\n const { t } = useTranslation();\n const SystemParameterTypes = useSelector(\n (state: any) => state.commonStores.stores.SystemParameterTypes.data\n );\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"SystemEntityParameters\",\n deleteById: \"api/v1/dev/entityparameter\",\n save: \"api/v1/dev/entityparameter\",\n findById: \"api/v1/dev/entityparameter\",\n setData: setData,\n });\n\n const SystemDataQueries = useSelector(\n (state: any) => state.commonStores.stores.SystemDataQueries.data\n );\n const adjustFormAccordingFormValues: FormValueChangeCallBk = (\n formValues: any,\n formActions,\n formManager,\n fieldName,\n newValue,\n selectedRecord\n ) => {\n if (fieldName) {\n if (fieldName === \"parameterType\") {\n if (newValue === \"combobox\") {\n formManager.setValue(\"parameterValueFormat\", null);\n formActions.showField(\"parameterDataQueryId\");\n formActions.showField(\"parameterDataset\");\n formActions.showField(\"parameterDisplayField\");\n formActions.showField(\"parameterValueField\");\n formActions.hideField(\"parameterValueFormat\");\n } else {\n formActions.hideField(\"parameterDataQueryId\");\n formActions.hideField(\"parameterDataset\");\n formActions.hideField(\"parameterDisplayField\");\n formActions.hideField(\"parameterValueField\");\n }\n if (newValue === \"date\" || newValue === \"datetime\") {\n formActions.showField(\"parameterValueFormat\");\n if (newValue === \"date\") {\n formManager.setValue(\"parameterValueFormat\", DATE_FORMAT);\n } else {\n formManager.setValue(\"parameterValueFormat\", DATE_TIME_FORMAT);\n }\n } else {\n formActions.hideField(\"parameterValueFormat\");\n formManager.setValue(\"parameterValueFormat\", null);\n }\n } else if (fieldName == \"parameterDataQueryId\") {\n if (newValue != null && newValue != \"\") {\n formManager.setValue(\"parameterDataset\", null);\n formActions.hideField(\"parameterDataset\");\n } else {\n formActions.showField(\"parameterDataset\");\n }\n } else if (fieldName == \"parameterDataset\") {\n if (newValue != null && newValue != \"\") {\n formManager.setValue(\"parameterDataQueryId\", null);\n formActions.hideField(\"parameterDataQueryId\");\n } else {\n formActions.showField(\"parameterDataQueryId\");\n }\n }\n } else { \n if (formValues?.parameterType === \"combobox\") {\n formManager.setValue(\"parameterValueFormat\", null);\n formActions.showField(\"parameterDataQueryId\");\n formActions.showField(\"parameterDataset\");\n formActions.showField(\"parameterDisplayField\");\n formActions.showField(\"parameterValueField\");\n formActions.hideField(\"parameterValueFormat\"); \n } else if (formValues?.parameterType === \"date\") {\n formActions.hideField(\"parameterDataQueryId\");\n formActions.hideField(\"parameterDataset\");\n formActions.hideField(\"parameterDisplayField\");\n formActions.hideField(\"parameterValueField\");\n formActions.showField(\"parameterValueFormat\");\n formManager.setValue(\"parameterValueFormat\", DATE_FORMAT);\n } else if (formValues?.parameterType === \"datetime\") {\n formActions.hideField(\"parameterDataQueryId\");\n formActions.hideField(\"parameterDataset\");\n formActions.hideField(\"parameterDisplayField\");\n formActions.hideField(\"parameterValueField\");\n formActions.showField(\"parameterValueFormat\");\n formManager.setValue(\"parameterValueFormat\", DATE_TIME_FORMAT);\n } else {\n formManager.setValue(\"parameterValueFormat\", null);\n formActions.hideField(\"parameterDataQueryId\");\n formActions.hideField(\"parameterDataset\");\n formActions.hideField(\"parameterDisplayField\");\n formActions.hideField(\"parameterValueField\");\n formActions.hideField(\"parameterValueFormat\");\n }\n }\n };\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ENTITY_PARAMETER_PARAMETER_CODE\",\n fieldName: \"parameterCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ENTITY_PARAMETER_PARAMETER_LABEL\",\n fieldName: \"parameterLabel\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ENTITY_PARAMETER_PARAMETER_TYPE\",\n fieldName: \"parameterType\",\n required: true,\n fieldType: \"combobox\",\n options: SystemParameterTypes,\n comboboxValueDataType: \"string\",\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ENTITY_PARAMETER_PARAMETER_DATA_QUERY_ID\",\n fieldName: \"parameterDataQueryId\",\n hidden: true,\n required: false,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionDisplayField: \"queryName\",\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ENTITY_PARAMETER_PARAMETER_DATASET\",\n fieldName: \"parameterDataset\",\n hidden: true,\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ENTITY_PARAMETER_PARAMETER_DISPLAY_FIELD\",\n fieldName: \"parameterDisplayField\",\n hidden: true,\n required: false,\n fieldType: \"text\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ENTITY_PARAMETER_PARAMETER_VALUE_FIELD\",\n fieldName: \"parameterValueField\",\n hidden: true,\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ENTITY_PARAMETER_PARAMETER_VALUE_FORMAT\",\n fieldName: \"parameterValueFormat\",\n required: false,\n hidden: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"ENTITY_PARAMETER_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalTitle: \"Entity Parameter\",\n modalIcon: \"p\",\n modalWidth: 300,\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"ENTITY_PARAMETER_PLURAL\")}\n girdIcon=\"p\"\n formProps={{ formValuesChangeCallBk: adjustFormAccordingFormValues }}\n editAction={{ isEnabled: true, authority: \"ENTITY_PARAMETER_EDIT\" }}\n deleteAction={{ isEnabled: true, authority: \"ENTITY_PARAMETER_DELETE\" }}\n />\n );\n};\n\nexport default EntityParameterGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\n\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions, useWindow } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\nimport { toast } from \"react-toastify\";\nimport MailRecipientGrid from \"./MailRecipientGrid\";\nimport MailBodyGrid from \"./MailBodyGrid\";\nimport MailAttachmentGrid from \"./MailAttachmentGrid\";\n\nconst MailTemplateGrid: React.FC = () => {\n const SystemDataQueries = useSelector(\n (state: any) => state.commonStores.stores.SystemDataQueries.data\n );\n const SystemTimeIntervals = useSelector(\n (state: any) => state.commonStores.stores.SystemTimeIntervals.data\n );\n const [selectedRecord, setSelectedRecord] = useState<any>(null);\n const {\n Window: MailRecipentsWindow,\n setWindowState: setMailRecipientsWindowState,\n } = useWindow({ windowTitle: \"Mail Receipents\", windowIcon: \"users\" });\n const { Window: MailBodiesWindow, setWindowState: setMailBodiesWindowState } =\n useWindow({\n windowTitle: \"Mail Bodies\",\n windowIcon: { prefix: \"fas\", iconName: \"envelope-open-text\" },\n });\n const {\n Window: MailAttachmentWindow,\n setWindowState: setMailAttachmentWindowState,\n } = useWindow({\n windowTitle: \"Mail Attachment\",\n windowIcon: \"paperclip\",\n width: 500,\n });\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"SystemMailTemplates\",\n deleteById: \"api/v1/dev/mailtemplate\",\n save: \"api/v1/dev/mailtemplate\",\n findById: \"api/v1/dev/mailtemplate\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_TEMPLATE_MAIL_TEMPLATE_CODE\",\n fieldName: \"mailTemplateCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_TEMPLATE_MAIL_TEMPLATE_NAME\",\n fieldName: \"mailTemplateName\",\n required: true,\n fieldType: \"text\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_TEMPLATE_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"group\",\n props: {\n label: \"subject\",\n icon: \"users\",\n style: { padding: 1, border: \"0.5px dashed black\", margin: 1 },\n elements: [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_TEMPLATE_MAIL_SUBJECT\",\n fieldName: \"mailSubject\",\n required: true,\n fieldType: \"text\",\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_TEMPLATE_SUBJECT_DATA_QUERY_ID\",\n fieldName: \"subjectDataQueryId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionDisplayField: \"queryName\",\n optionValueField: \"id\",\n gridProps: {\n hidden: true,\n },\n },\n },\n ],\n },\n },\n\n {\n type: \"group\",\n props: {\n label: \"Recipients\",\n icon: \"users\",\n style: { padding: 1, border: \"0.5px dashed black\", margin: 1 },\n elements: [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"To Recipient Query (must return list of objects with property email)\",\n fieldName: \"mailToDataQueryId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionDisplayField: \"queryName\",\n optionValueField: \"id\",\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"CC Recipient Query (must return list of objects with property email)\",\n fieldName: \"mailCcDataQueryId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionDisplayField: \"queryName\",\n optionValueField: \"id\",\n gridProps: {\n hidden: true,\n },\n },\n },\n ],\n },\n },\n {\n type: \"group\",\n props: {\n label: \"Periodical Configuration\",\n icon: \"history\",\n style: { padding: 1, border: \"0.5px dashed black\", margin: 1 },\n elements: [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_TEMPLATE_PERIODICAL\",\n fieldName: \"periodical\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_TEMPLATE_PERIOD_TYPE\",\n fieldName: \"periodType\",\n options: SystemTimeIntervals,\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n required: false,\n fieldType: \"combobox\",\n comboboxValueDataType: \"string\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_TEMPLATE_PERIOD_VALUE\",\n fieldName: \"periodValue\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_TEMPLATE_START_SENDING_AT\",\n fieldName: \"startSendingAt\",\n required: false,\n fieldType: \"datetime\",\n },\n },\n ],\n },\n },\n ];\n\n return (\n <>\n <MailRecipentsWindow>\n <MailRecipientGrid\n selectedRecord={selectedRecord}\n callBkFn={() => {\n setMailRecipientsWindowState(false);\n }}\n />\n </MailRecipentsWindow>\n <MailBodiesWindow>\n <MailBodyGrid\n selectedRecord={selectedRecord}\n callBkFn={() => {\n setMailRecipientsWindowState(false);\n }}\n />\n </MailBodiesWindow>\n <MailAttachmentWindow>\n <MailAttachmentGrid\n selectedRecord={selectedRecord}\n callBkFn={() => {\n setMailAttachmentWindowState(false);\n }}\n />\n </MailAttachmentWindow>\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalWidth: 300,\n modalTitle: \"Mail Template\",\n modalIcon: \"envelope\",\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"MAIL_TEMPLATE_PLURAL\")}\n girdIcon=\"envelope\"\n rowActions={[\n {\n icon: \"users\",\n label: \"Recipients\",\n actionFn: async (data) => {\n setSelectedRecord(data);\n setMailRecipientsWindowState(true);\n },\n },\n {\n icon: { prefix: \"fas\", iconName: \"envelope-open-text\" },\n label: \"Mail Body\",\n actionFn: async (data) => {\n setSelectedRecord(data);\n setMailBodiesWindowState(true);\n },\n },\n {\n icon: \"paperclip\",\n label: \"Mail Attachments\",\n actionFn: async (data) => {\n setSelectedRecord(data);\n setMailAttachmentWindowState(true);\n },\n },\n ]}\n editAction={{\n isEnabled: true,\n authority: \"MAIL_TEMPLATE_EDIT\",\n preActionValidation: (record) => {\n if (record?.periodical === true && !record?.periodType) {\n toast.error(\n \"You must specifiy the period type since this email is periodical\"\n );\n return false;\n }\n if (record?.periodical === true && !record?.periodValue) {\n toast.error(\n \"You must specifiy the period value since this email is periodical\"\n );\n return false;\n }\n if (record?.periodical === true && !record?.startSendingAt) {\n toast.error(\n \"You must specifiy the start sending time since this email is periodical\"\n );\n return false;\n }\n\n return true;\n },\n }}\n deleteAction={{ isEnabled: true, authority: \"MAIL_TEMPLATE_DELETE\" }}\n />\n </>\n );\n};\n\nexport default MailTemplateGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions, useWindow } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\nimport WorkflowDocumentStatusGrid from \"./WorkflowDocumentStatusGrid\";\nimport WorkflowDocumentActionGrid from \"./WorkflowDocumentActionGrid\";\n\nconst WorkflowDocumentGrid: React.FC = () => {\n const [selectedRecord, setSelectedRecord] = useState<any>(null);\n const {\n Window: WorkflowStatusWindow,\n setWindowState: setWorkflowStatusWindowState,\n } = useWindow({\n windowTitle: \"Document Status\",\n windowIcon: \"tag\",\n });\n const {\n Window: WorkflowActionWindow,\n setWindowState: setWorkflowActionWindowState,\n } = useWindow({\n windowTitle: \"Document Action\",\n windowIcon: \"stamp\",\n });\n const SystemOrganizations = useSelector(\n (state: any) => state.commonStores.stores.SystemOrganizations.data\n );\n const SystemReports = useSelector(\n (state: any) => state.commonStores.stores.SystemReports.data\n );\n const SystemDataSources = useSelector(\n (state: any) => state.commonStores.stores.SystemDataSources.data\n );\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/workflowdocument/all\",\n deleteById: \"api/v1/dev/workflowdocument\",\n save: \"api/v1/dev/workflowdocument\",\n findById: \"api/v1/dev/workflowdocument\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_ORG_CODE\",\n fieldName: \"orgCode\",\n required: false,\n fieldType: \"combobox\",\n options: SystemOrganizations,\n optionDisplayField: \"organizationCode\",\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_DOCUMENT_CODE\",\n fieldName: \"documentCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Workflow Document En Display Name\",\n fieldName: \"documentEnName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Workflow Document Ar Display Name\",\n fieldName: \"documentArName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"Report To be Attached For The Document ( will be passed a parameter called doc_id)\",\n fieldName: \"documentReportId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemReports,\n optionDisplayField: \"reportName\",\n optionValueField: \"id\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_APPROVAL_ALLOWED\",\n fieldName: \"mailApprovalAllowed\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"group\",\n props: {\n icon: \"bell\",\n style: { border: \"1px dashed black\", padding: 1, marginBottom: 1 },\n label: \"App Visual Notifications\",\n elements: [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_APP_NOTIFICATION_ICON\",\n fieldName: \"appNotificationIcon\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_APP_NOTIFICATION_STYLE\",\n fieldName: \"appNotificationStyle\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_APP_VIEW_ROUTE\",\n fieldName: \"appViewRoute\",\n required: false,\n fieldType: \"text\",\n },\n },\n ],\n },\n },\n\n {\n type: \"group\",\n props: {\n icon: \"database\",\n style: { border: \"1px dashed black\", padding: 1, marginBottom: 1 },\n label: \"Related Document Database\",\n elements: [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_USE_SYSTEM_CON\",\n fieldName: \"useSystemCon\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_DOCUMENT_CON_ID\",\n fieldName: \"documentConId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemDataSources,\n optionDisplayField: \"connectionName\",\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_DOCUMENT_DATABASE_NAME\",\n fieldName: \"documentDatabaseName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_DOCUMENT_DATABASE_TABLE\",\n fieldName: \"documentDatabaseTable\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_DOCUMENT_ID_FIELD\",\n fieldName: \"documentIdField\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_DOCUMENT_STATUS_FIELD\",\n fieldName: \"documentStatusField\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_DOCUMENT_NUMBER_FIELD\",\n fieldName: \"documentNumberField\",\n required: true,\n fieldType: \"text\",\n },\n },\n ],\n },\n },\n ];\n\n return (\n <>\n <WorkflowStatusWindow>\n <WorkflowDocumentStatusGrid selectedRecord={selectedRecord} />\n </WorkflowStatusWindow>\n <WorkflowActionWindow>\n <WorkflowDocumentActionGrid selectedRecord={selectedRecord} />\n </WorkflowActionWindow>\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n rowActions={[\n {\n icon: \"tag\",\n label: \"Document States\",\n actionFn: async (data) => {\n setSelectedRecord(data);\n setWorkflowStatusWindowState(true);\n },\n },\n {\n icon: \"stamp\",\n label: \"Document Actions\",\n actionFn: async (data) => {\n setSelectedRecord(data);\n setWorkflowActionWindowState(true);\n },\n },\n ]}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalIcon: \"chart-diagram\",\n modalTitle: t(\"WORKFLOW_DOCUMENT_SINGULAR\"),\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"WORKFLOW_DOCUMENT_PLURAL\")}\n girdIcon=\"chart-diagram\"\n editAction={{ isEnabled: true, authority: \"WORKFLOW_DOCUMENT_EDIT\" }}\n deleteAction={{\n isEnabled: true,\n authority: \"WORKFLOW_DOCUMENT_DELETE\",\n }}\n />\n </>\n );\n};\n\nexport default WorkflowDocumentGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport {\n FormActionProps,\n FormElementProps,\n FormValueChangeCallBk,\n} from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\nimport { UseFormReturn } from \"react-hook-form\";\n\nexport type WidgetType =\n | \"LineChart\"\n | \"ColumnChart\"\n | \"PieChart\"\n | \"Card\"\n | \"CircularProgress\"\n | \"LinearProgress\";\n\nconst adjustFormAfterValueChange: FormValueChangeCallBk = (\n formValues,\n formActions,\n formManager,\n fieldName,\n newValue\n) => {\n if (fieldName) {\n if (fieldName === \"widgetType\") {\n if (newValue === \"LineChart\") {\n formActions.showField(\"height\");\n formActions.showField(\"width\");\n formActions.showField(\"horizontalAxisField\");\n formActions.showField(\"horizontalAxisLabel\");\n formActions.showField(\"seriesKeys\");\n formActions.showField(\"verticalAxisField\");\n formActions.showField(\"verticalAxisLabel\");\n } else if (newValue === \"ColumnChart\") {\n formActions.showField(\"height\");\n formActions.showField(\"width\");\n formActions.showField(\"horizontalAxisField\");\n formActions.showField(\"horizontalAxisLabel\");\n formActions.hideField(\"seriesKeys\");\n formActions.showField(\"verticalAxisField\");\n formActions.showField(\"verticalAxisLabel\");\n } else if (newValue === \"PieChart\") {\n formActions.showField(\"height\");\n formActions.showField(\"width\");\n formActions.showField(\"horizontalAxisField\");\n formActions.hideField(\"horizontalAxisLabel\");\n formActions.hideField(\"seriesKeys\");\n formActions.showField(\"verticalAxisField\");\n formActions.hideField(\"verticalAxisLabel\");\n } else if (newValue === \"Card\") {\n formActions.showField(\"height\");\n formActions.showField(\"width\");\n formActions.showField(\"horizontalAxisField\");\n formActions.hideField(\"horizontalAxisLabel\");\n formActions.hideField(\"seriesKeys\");\n formActions.showField(\"verticalAxisField\");\n formActions.hideField(\"verticalAxisLabel\");\n } else if (newValue === \"CircularProgress\") {\n formActions.hideField(\"height\");\n formActions.hideField(\"width\");\n formActions.hideField(\"horizontalAxisField\");\n formActions.hideField(\"horizontalAxisLabel\");\n formActions.hideField(\"seriesKeys\");\n formActions.hideField(\"verticalAxisField\");\n formActions.hideField(\"verticalAxisLabel\");\n } else if (newValue === \"LinearProgress\") {\n formActions.hideField(\"height\");\n formActions.hideField(\"width\");\n formActions.hideField(\"horizontalAxisField\");\n formActions.hideField(\"horizontalAxisLabel\");\n formActions.hideField(\"seriesKeys\");\n formActions.hideField(\"verticalAxisField\");\n formActions.hideField(\"verticalAxisLabel\");\n } else {\n formActions.hideField(\"height\");\n formManager.setValue(\"height\", null);\n formActions.hideField(\"width\");\n formManager.setValue(\"width\", null);\n formActions.hideField(\"horizontalAxisField\");\n formManager.setValue(\"horizontalAxisField\", null);\n formActions.hideField(\"horizontalAxisLabel\");\n formManager.setValue(\"horizontalAxisLabel\", null);\n formActions.hideField(\"seriesKeys\");\n formManager.setValue(\"seriesKeys\", null);\n formActions.hideField(\"verticalAxisField\");\n formManager.setValue(\"verticalAxisField\", null);\n formActions.hideField(\"verticalAxisLabel\");\n formManager.setValue(\"verticalAxisLabel\", null);\n }\n }\n } else {\n }\n};\n\nconst WidgetGrid: React.FC = () => {\n const { t } = useTranslation();\n const SystemDataQueries = useSelector(\n (state: any) => state.commonStores.stores.SystemDataQueries.data\n );\n const SystemWidgetTypes = useSelector(\n (state: any) => state.commonStores.stores.SystemWidgetTypes.data\n );\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n commonStoreKey: \"SystemWidgets\",\n deleteById: \"api/v1/dev/widget\",\n save: \"api/v1/dev/widget\",\n findById: \"api/v1/dev/widget\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_WIDGET_TYPE\",\n fieldName: \"widgetType\",\n required: true,\n fieldType: \"combobox\",\n comboboxValueDataType: \"string\",\n options: SystemWidgetTypes,\n optionDisplayField: \"name\",\n optionValueField: \"name\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Query\",\n fieldName: \"dataQueryId\",\n required: true,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionDisplayField: \"queryName\",\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_WIDGET_NAME\",\n fieldName: \"widgetName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_ICON\",\n fieldName: \"icon\",\n required: false,\n fieldType: \"text\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_TITLE\",\n fieldName: \"title\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_WIDGET_DESCRIPTION\",\n fieldName: \"widgetDescription\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_HEIGHT\",\n fieldName: \"height\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_WIDTH\",\n fieldName: \"width\",\n required: false,\n fieldType: \"combobox\",\n options: [\n { value: 1 },\n { value: 2 },\n { value: 3 },\n { value: 4 },\n { value: 5 },\n { value: 6 },\n { value: 7 },\n { value: 8 },\n { value: 9 },\n { value: 10 },\n { value: 11 },\n { value: 12 },\n ],\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"group\",\n props: {\n style: { padding: 1, border: \"1px solid black\", width: \"100%\" },\n label: \"Data Specs\",\n elements: [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_HORIZONTAL_AXIS_FIELD\",\n fieldName: \"horizontalAxisField\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_HORIZONTAL_AXIS_LABEL\",\n fieldName: \"horizontalAxisLabel\",\n required: true,\n fieldType: \"text\",\n },\n },\n\n // {\n // type: \"field\",\n // mode: \"props\",\n // props: {\n // fieldLabel: \"WIDGET_SERIES_KEYS\",\n // fieldName: \"seriesKeys\",\n // required: false,\n // fieldType: \"text\",\n // },\n // },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WIDGET_VERTICAL_AXIS_FIELD\",\n fieldName: \"verticalAxisField\",\n required: true,\n fieldType: \"text\",\n },\n },\n // {\n // type: \"field\",\n // mode: \"props\",\n // props: {\n // fieldLabel: \"WIDGET_VERTICAL_AXIS_LABEL\",\n // fieldName: \"verticalAxisLabel\",\n // required: false,\n // fieldType: \"text\",\n // },\n // },\n ],\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: { modalIcon: \"chart-pie\", modalTitle: \"Widget\" },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"WIDGET_PLURAL\")}\n girdIcon=\"chart-pie\"\n editAction={{ isEnabled: true, authority: \"WIDGET_EDIT\" }}\n deleteAction={{ isEnabled: true, authority: \"WIDGET_DELETE\" }}\n // formProps={{ formValuesChangeCallBk: adjustFormAfterValueChange }}\n />\n );\n};\n\nexport default WidgetGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions, useWindow } from \"../../../hooks\";\nimport DashboardWidgetGrid from \"./DashboardWidgetGrid\";\nimport { useNavigate } from \"react-router-dom\";\n\nconst DashboardGrid: React.FC = () => {\n const { t } = useTranslation();\n const [selectedRecord, setSelectedRecord] = useState<any>(null);\n const { Window: WidgetsWindows, setWindowState: setWidgetsWindowState } =\n useWindow({\n windowTitle: \"Dashboard Widgets\",\n windowIcon: \"chart-pie\",\n });\n const [data, setData] = useState([]);\n const navigate = useNavigate();\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/dashboard/all\",\n deleteById: \"api/v1/dev/dashboard\",\n save: \"api/v1/dev/dashboard\",\n findById: \"api/v1/dev/dashboard\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DASHBOARD_DASHBOARD_CODE\",\n fieldName: \"dashboardCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DASHBOARD_DASHBOARD_NAME\",\n fieldName: \"dashboardName\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DASHBOARD_DASHBOARD_TITLE\",\n fieldName: \"dashboardTitle\",\n required: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"DASHBOARD_ENABLED\",\n fieldName: \"enabled\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <>\n <WidgetsWindows>\n <DashboardWidgetGrid selectedRecord={selectedRecord} />\n </WidgetsWindows>\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n rowActions={[\n {\n label: \"Widgets\",\n icon: \"chart-pie\",\n actionFn: async (data) => {\n setSelectedRecord(data);\n setWidgetsWindowState(true);\n },\n },\n {\n label: \"View\",\n icon: \"eye\",\n actionFn: async (data) => {\n navigate(\"/dashboard/\" + data.dashboardCode);\n },\n },\n ]}\n gridTitle={t(\"DASHBOARD_PLURAL\")}\n girdIcon=\"square-poll-vertical\"\n editAction={{ isEnabled: true, authority: \"DASHBOARD_EDIT\" }}\n deleteAction={{ isEnabled: true, authority: \"DASHBOARD_DELETE\" }}\n />\n </>\n );\n};\n\nexport default DashboardGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\n\nconst WorkflowDocumentMailLogGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/workflowdocumentmaillog/all\",\n deleteById: \"api/v1/dev/workflowdocumentmaillog\",\n save: \"api/v1/dev/workflowdocumentmaillog\",\n findById: \"api/v1/dev/workflowdocumentmaillog\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_GRAPH_API_MSG_ID\",\n fieldName: \"graphApiMsgId\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_IS_PROCESSED\",\n fieldName: \"isProcessed\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_MAIL_ACTION_CODE\",\n fieldName: \"mailActionCode\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_MAIL_BODY_CONTENT\",\n fieldName: \"mailBodyContent\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_MAIL_FROM\",\n fieldName: \"mailFrom\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_MAIL_SUBJECT\",\n fieldName: \"mailSubject\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_PROCESS_MESSAGE\",\n fieldName: \"processMessage\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_PROCESS_TIME\",\n fieldName: \"processTime\",\n required: false,\n fieldType: \"datetime\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_REF_DOC_ID\",\n fieldName: \"refDocId\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_WORKFLOW_DOCUMENT_ID\",\n fieldName: \"workflowDocumentId\",\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"WORKFLOW_DOCUMENT_MAIL_LOG_MAIL_RECEIVE_TIME\",\n fieldName: \"mailReceiveTime\",\n required: false,\n fieldType: \"datetime\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{ editMode: \"row\" }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"WORKFLOW_DOCUMENT_MAIL_LOG_PLURAL\")}\n girdIcon=\"table-cells\"\n editAction={{\n isEnabled: true,\n authority: \"WORKFLOW_DOCUMENT_MAIL_LOG_EDIT\",\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"WORKFLOW_DOCUMENT_MAIL_LOG_DELETE\",\n }}\n />\n );\n};\n\nexport default WorkflowDocumentMailLogGrid;\n","import { useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions, useAxios, useConfirmationWindow } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\n\nconst MailNotificationQueueGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const { handlePostRequest } = useAxios();\n\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/mailnotificationqueue/all\",\n deleteById: \"api/v1/dev/mailnotificationqueue\",\n save: \"api/v1/dev/mailnotificationqueue\",\n findById: \"api/v1/dev/mailnotificationqueue\",\n setData: setData,\n });\n const SystemMailTemplates = useSelector(\n (state: any) => state.commonStores.stores.SystemMailTemplates.data\n );\n\n const resendMail = async (id: any) => {\n await handlePostRequest({\n endPointURI: \"api/v1/public/mailNotification/resend\",\n showMask: true,\n parameters: {\n mailNotificationQueueId: id,\n },\n successCallBkFn: (response: any) => {\n apiActions.reloadData();\n },\n });\n };\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_NOTIFICATION_QUEUE_MAIL_TEMPLATE_ID\",\n fieldName: \"mailTemplateId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemMailTemplates,\n optionDisplayField: \"mailTemplateName\",\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_NOTIFICATION_QUEUE_CUSTOM_MAIL_ATTACHED_REPORT_ID\",\n fieldName: \"customMailAttachedReportId\",\n required: false,\n hidden: true,\n gridProps: {\n hidden: true,\n },\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_NOTIFICATION_QUEUE_CUSTOM_MAIL_BODY\",\n fieldName: \"customMailBody\",\n required: false,\n hidden: true,\n gridProps: {\n hidden: true,\n },\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_NOTIFICATION_QUEUE_CUSTOM_MAIL_SUBJECT\",\n fieldName: \"customMailSubject\",\n required: false,\n hidden: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_NOTIFICATION_QUEUE_CUSTOM_RECIPIENTS\",\n fieldName: \"customRecipients\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_NOTIFICATION_QUEUE_IS_NOTIFIED\",\n fieldName: \"isNotified\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_NOTIFICATION_QUEUE_NOTIFICATION_TIME\",\n fieldName: \"notificationTime\",\n required: false,\n fieldType: \"datetime\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_NOTIFICATION_QUEUE_NOTIFICATION_MESSAGE\",\n fieldName: \"notificationMessage\",\n required: false,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"MAIL_NOTIFICATION_QUEUE_MAIL_PARAMETERS\",\n fieldName: \"mailParameters\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n required: false,\n fieldType: \"text\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n disableDefaultAction={true}\n data={data}\n setData={setData}\n editMode={{ editMode: \"none\" }}\n formElements={formElements}\n rowActions={[\n {\n actionFn: async (data) => {\n resendMail(data.id);\n },\n label: \"Resend\",\n icon: \"repeat\",\n confirmationMessage: \"Are you sure you want to resend this email ?\",\n isConfirmationRequired: true,\n },\n ]}\n keyColumnName={\"id\"}\n gridTitle={t(\"MAIL_NOTIFICATION_QUEUE_PLURAL\")}\n girdIcon=\"table-cells\"\n editAction={{\n isEnabled: true,\n authority: \"MAIL_NOTIFICATION_QUEUE_EDIT\",\n }}\n deleteAction={{\n isEnabled: true,\n authority: \"MAIL_NOTIFICATION_QUEUE_DELETE\",\n }}\n />\n );\n};\n\nexport default MailNotificationQueueGrid;\n","import { useEffect, useState } from \"react\";\nimport TemplateGrid from \"../../templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid\";\nimport { FormElementProps } from \"../../templates/DataEntryTemplates/DataEntryTypes\";\nimport { useTranslation } from \"react-i18next\";\nimport { useApiActions } from \"../../../hooks\";\nimport { useSelector } from \"react-redux\";\nimport { Box } from \"@mui/material\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport useInterval from \"../../../hooks/useInterval\";\n\nconst NotificationGrid: React.FC = () => {\n const { t } = useTranslation();\n const [data, setData] = useState([]);\n const SystemTimeIntervals = useSelector(\n (state: any) => state.commonStores.stores.SystemTimeIntervals.data\n );\n const SystemDataQueries = useSelector(\n (state: any) => state.commonStores.stores.SystemDataQueries.data\n );\n const apiActions = useApiActions({\n findAll: \"api/v1/dev/notification/all\",\n deleteById: \"api/v1/dev/notification\",\n save: \"api/v1/dev/notification\",\n findById: \"api/v1/dev/notification\",\n setData: setData,\n });\n\n const formElements: Array<FormElementProps> = [\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"id\",\n fieldName: \"id\",\n fieldType: \"number\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createTime\",\n fieldName: \"createTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"createdBy\",\n fieldName: \"createdBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateBy\",\n fieldName: \"lastUpdateBy\",\n fieldType: \"text\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"lastUpdateTime\",\n fieldName: \"lastUpdateTime\",\n fieldType: \"datetime\",\n hidden: true,\n gridProps: {\n hidden: true,\n },\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_NOTIFICATION_CODE\",\n fieldName: \"notificationCode\",\n required: true,\n fieldType: \"text\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"Notification Data Query ( will be passed a parameter call last_run_time represents last check time)\",\n fieldName: \"notificationQueryId\",\n required: true,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionDisplayField: \"queryName\",\n gridProps: {\n hidden: true,\n },\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"Users to notify Query (must have username property in the result set)\",\n fieldName: \"usersToNotifyQueryId\",\n required: false,\n fieldType: \"combobox\",\n options: SystemDataQueries,\n optionDisplayField: \"queryName\",\n gridProps: {\n hidden: true,\n },\n optionValueField: \"id\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_AUTHORITY_TO_NOTIFY\",\n fieldName: \"authorityToNotify\",\n required: false,\n gridProps: {\n hidden: true,\n },\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Interval Type\",\n fieldName: \"intervalType\",\n fieldType: \"combobox\",\n comboboxValueDataType: \"string\",\n options: SystemTimeIntervals,\n gridProps: {\n hidden: true,\n },\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Interval Value (minmum value 20 seconds)\",\n fieldName: \"intervalValue\",\n gridProps: {\n hidden: true,\n },\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Start Notifing Date\",\n fieldName: \"startNotificationFrom\",\n gridProps: {\n hidden: true,\n },\n fieldType: \"datetime\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_SYSTEM_APPLICATION_ID\",\n fieldName: \"systemApplicationId\",\n hidden: true,\n gridProps: { hidden: true },\n required: false,\n fieldType: \"number\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_NOTIFICATION_ICON\",\n fieldName: \"notificationIcon\",\n required: true,\n fieldType: \"text\",\n gridProps: {\n muiProps: {\n renderCell: (params: any) => {\n return (\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n color: params?.row?.notificationIconColor,\n justifyContent: \"center\",\n height: \"100%\",\n }}\n >\n {params?.row?.notificationIcon ? (\n <FontAwesomeIcon icon={params.row.notificationIcon} />\n ) : (\n <></>\n )}\n </Box>\n );\n },\n },\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_NOTIFICATION_AR_TEXT\",\n fieldName: \"notificationArText\",\n required: true,\n fieldType: \"text\",\n gridProps: {\n muiProps: {\n renderCell: (params: any) => {\n return (\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n color: params?.row?.notificationTextColor,\n justifyContent: \"center\",\n height: \"100%\",\n }}\n >\n {params?.row?.notificationArText}\n </Box>\n );\n },\n },\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_NOTIFICATION_EN_TEXT\",\n fieldName: \"notificationEnText\",\n required: true,\n fieldType: \"text\",\n gridProps: {\n muiProps: {\n renderCell: (params: any) => {\n return (\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n color: params?.row?.notificationTextColor,\n justifyContent: \"center\",\n height: \"100%\",\n }}\n >\n {params?.row?.notificationEnText}\n </Box>\n );\n },\n },\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Last Runtime\",\n disabled: true,\n fieldName: \"lastIntervalRun\",\n fieldType: \"datetime\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Last Successful Runtime\",\n fieldName: \"lastSuccessfulRun\",\n disabled: true,\n fieldType: \"datetime\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"Last Run Message\",\n fieldName: \"lastRunMessage\",\n disabled: true,\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_NOTIFICATION_TEXT_COLOR\",\n fieldName: \"notificationTextColor\",\n required: false,\n gridProps: {\n hidden: true,\n },\n fieldType: \"text\",\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_NOTIFICATION_ICON_COLOR\",\n fieldName: \"notificationIconColor\",\n required: false,\n gridProps: {\n hidden: true,\n },\n fieldType: \"text\",\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_NOTIFICATION_ACTION\",\n fieldName: \"notificationAction\",\n required: false,\n fieldType: \"combobox\",\n comboboxValueDataType: \"string\",\n options: [{ value: \"NAVIGATION\" }],\n optionDisplayField: \"value\",\n optionValueField: \"value\",\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"Action Payload (must be a rout in case of NAVIGATION with parameter values betweem @@)\",\n fieldName: \"notificationActionPayload\",\n required: false,\n fieldType: \"text\",\n gridProps: {\n hidden: true,\n },\n },\n },\n\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel:\n \"Organization Id Field on the Notification Query result set if it supports it\",\n fieldName: \"organizationIdField\",\n required: false,\n fieldType: \"text\",\n gridProps: {\n hidden: true,\n },\n },\n },\n {\n type: \"field\",\n mode: \"props\",\n props: {\n fieldLabel: \"NOTIFICATION_IS_ACTIVE\",\n fieldName: \"isActive\",\n required: false,\n fieldType: \"checkbox\",\n },\n },\n ];\n\n return (\n <TemplateGrid\n apiActions={apiActions}\n data={data}\n setData={setData}\n editMode={{\n editMode: \"modal\",\n specs: {\n modalIcon: \"bell\",\n modalTitle: \"System Notification\",\n modalWidth: \"300\",\n },\n }}\n formElements={formElements}\n keyColumnName={\"id\"}\n gridTitle={t(\"NOTIFICATION_PLURAL\")}\n girdIcon=\"bell\"\n editAction={{ isEnabled: true, authority: \"NOTIFICATION_EDIT\" }}\n deleteAction={{ isEnabled: true, authority: \"NOTIFICATION_DELETE\" }}\n />\n );\n};\n\nexport default NotificationGrid;\n","import { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\nimport { Box, Button } from \"@mui/material\";\nimport { useSelector } from \"react-redux\";\nimport { useAxios, useSession } from \"../../hooks\";\nimport { useState } from \"react\";\nimport useInterval from \"../../hooks/useInterval\";\nimport { notificationsCheckIntervalSeconds } from \"../../layout/NotificationButton\";\nimport NotificationItem from \"./NotificationItem\";\n\nconst MyNotificationsPanel: React.FC = () => {\n const { UserInfo } = useSession();\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const { handleGetRequest, handlePostRequest } = useAxios();\n const [notifications, setNotifications] = useState<Array<Notification>>([]);\n const AppInfo = useSelector((state: any) => state.AppInfo.value);\n const acknowledgeAllCurrentNotifications = async () => {\n await handlePostRequest({\n endPointURI: \"api/v1/public/notification/all/notified\",\n showMask: true,\n });\n };\n\n const archiveAllCurrentNotifications = async () => {\n await handlePostRequest({\n endPointURI: \"api/v1/public/notification/all/archive\",\n showMask: true,\n });\n };\n\n const loadUserNotifications = () => {\n if (UserInfo.isAuthenticated === true) {\n handleGetRequest({\n endPointURI: \"api/v1/public/notifications\",\n showMask: false,\n successCallBkFn: (response: any) => {\n setNotifications(response.data);\n },\n });\n }\n };\n if (AppInfo?.enableUINotifications === true) {\n useInterval(\n loadUserNotifications,\n notificationsCheckIntervalSeconds * 1000\n );\n }\n\n return (\n <>\n <Box\n sx={{ display: \"flex\", alignItems: \"center\", justifyContent: \"center\" }}\n >\n <Box sx={{ flex: 1 }}></Box>\n <h3>\n <FontAwesomeIcon\n icon=\"bell\"\n style={{ marginRight: 10, marginLeft: 10 }}\n />\n {AppLayout.appDirection === \"ltr\" ? \"Notifications\" : \"الاشعارات\"}\n </h3>\n <Box sx={{ flex: 1 }}></Box>\n <Button\n sx={{ textTransform: \"none\" }}\n onClick={acknowledgeAllCurrentNotifications}\n >\n Mark All Read\n </Button>\n <Button\n color=\"error\"\n sx={{ textTransform: \"none\" }}\n onClick={archiveAllCurrentNotifications}\n >\n Delete All\n </Button>\n </Box>\n <Box\n sx={{\n flex: 1,\n width: \"100%\",\n display: \"flex\",\n overflowY: \"auto\",\n }}\n >\n <Box\n sx={{\n flexGrow: 1,\n width: \"fit-content\",\n display: \"flex\",\n flexDirection: \"column\",\n overflowY: \"auto\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n }}\n >\n {notifications.map((notification: Notification, index) => {\n return (\n <NotificationItem\n {...notification}\n showDivider={index < notifications.length - 1}\n />\n );\n })}\n </Box>\n </Box>\n </>\n );\n};\n\nexport default MyNotificationsPanel;\n","import { Box } from \"@mui/material\";\nimport { useSession } from \"../hooks\";\nimport { FontAwesomeIcon } from \"@fortawesome/react-fontawesome\";\n\ntype RouteWrapperProps = {\n authority?: string;\n applicationModule?: string;\n children?: React.ReactNode;\n};\nconst RouteWrapper: React.FC<RouteWrapperProps> = (props) => {\n const { isUserAuthorized, isCurrentOrganizationAuthorizedToModule } =\n useSession();\n if (\n props?.applicationModule &&\n !isCurrentOrganizationAuthorizedToModule(props?.applicationModule)\n ) {\n return (\n <Box\n sx={{\n flex: 1,\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"center\",\n color: \"red\",\n }}\n >\n <h2>\n <FontAwesomeIcon\n style={{ marginRight: 10, marginLeft: 10 }}\n icon=\"cancel\"\n />\n Your organization didn't subscribe for this system module\n </h2>\n </Box>\n );\n }\n if (props?.authority && !isUserAuthorized(props.authority)) {\n return (\n <Box\n sx={{\n flex: 1,\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"center\",\n color: \"red\",\n }}\n >\n <h2>\n <FontAwesomeIcon\n style={{ marginRight: 10, marginLeft: 10 }}\n icon=\"cancel\"\n />\n You aren't authorized to access this page\n </h2>\n </Box>\n );\n }\n return <>{props.children}</>;\n};\n\nexport default RouteWrapper;\n","import { Box } from \"@mui/material\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { CacheProvider } from \"@emotion/react\";\nimport { Route, Routes } from \"react-router-dom\";\nimport { cacheLtr, cacheRtl } from \"../components/common/LayoutHandlers\";\nimport { SYSTEM_ROUTES } from \"../routes\";\nimport { SystemRoute } from \"../routes/types\";\nimport RouteWrapper from \"./RouteWrapper\";\nimport { useAxios, useLoadingMask, useSession } from \"../hooks\";\nimport { useEffect, useState } from \"react\";\nimport { setStoreData } from \"../redux/features/common/CommonStoreSlice\";\n\nconst MainContent: React.FC = () => {\n const AppLayoutState = useSelector((state: any) => state.AppLayout);\n const AppInfo = useSelector((state: any) => state.AppInfo.value);\n const businessRoutes = useSelector(\n (state: any) => state.AppInfo.value.businessRoutes\n );\n const { UserInfo } = useSession();\n const dispatch = useDispatch();\n const { show, hide } = useLoadingMask();\n const commonStores = useSelector((state: any) => state.commonStores);\n const [isAutoLoadLoaded, setAutoLoadLoaded] = useState<boolean>(false);\n const { isUserAuthorized } = useSession();\n const { handleGetRequest } = useAxios();\n const loadCommonStores = async () => {\n show(\"Loading ... please wait\");\n setAutoLoadLoaded(false);\n const stores = commonStores.stores;\n const storeKeys = commonStores.storeKeys;\n for (let storeKey of storeKeys) {\n if (\n (stores[storeKey]?.authority === undefined ||\n stores[storeKey]?.authority === null ||\n isUserAuthorized(stores[storeKey]?.authority)) &&\n stores[storeKey]?.url != \"\" &&\n stores[storeKey].autoLoad === true\n ) {\n handleGetRequest({\n endPointURI: stores[storeKey].url,\n showMask: false,\n successCallBkFn: (response) => {\n dispatch(setStoreData({ storeKey, data: response.data }));\n },\n failureCallBkFn: () => {\n dispatch(setStoreData({ storeKey, data: [] }));\n },\n });\n }\n }\n setAutoLoadLoaded(true);\n hide();\n };\n\n useEffect(() => {\n if (commonStores?.storeKeys) {\n loadCommonStores();\n }\n }, [commonStores.storeKeys, UserInfo?.currentOrganization]);\n return (\n <CacheProvider\n value={AppLayoutState.appDirection === \"ltr\" ? cacheLtr : cacheRtl}\n >\n {/* {isAutoLoadLoaded ? ( */}\n <Box\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n // alignItems: \"center\",\n justifyContent: \"flex-start\",\n flex: 1,\n overflow: \"hidden\",\n padding: 3,\n }}\n >\n <Routes>\n {AppInfo.enableAdministrationModule\n ? SYSTEM_ROUTES.map((route: SystemRoute, index) => {\n return (\n <Route\n key={\"adm\" + index}\n path={route.path}\n element={\n <RouteWrapper\n authority={route.authority}\n applicationModule={route.applicationModule}\n >\n <route.component />\n </RouteWrapper>\n }\n />\n );\n })\n : null}\n {businessRoutes.map((route: SystemRoute, index) => {\n return (\n <Route\n key={\"bs\" + index}\n path={route.path}\n element={\n <RouteWrapper authority={route.authority}>\n <route.component />\n </RouteWrapper>\n }\n />\n );\n })}\n </Routes>\n </Box>\n </CacheProvider>\n );\n};\n\nexport default MainContent;\n","import { styled } from \"@mui/material/styles\";\nimport { grey } from \"@mui/material/colors\";\nimport SwipeableDrawer from \"@mui/material/SwipeableDrawer\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { Box, Typography } from \"@mui/material\";\nimport { AppLayoutActions } from \"../redux/features/common/AppLayoutSlice\";\nimport NavigationTree from \"./NavigationTree\";\nimport { setSideBarState } from \"../redux/features/common/SideBarSlice\";\n\nconst drawerBleeding = 56;\n\ninterface Props {\n /**\n * Injected by the documentation to work in an iframe.\n * You won't need it on your project.\n */\n window?: () => Window;\n}\n\nconst Puller = styled(\"div\")(({ theme }) => ({\n width: 30,\n height: 6,\n margin: 10,\n backgroundColor: grey[300],\n borderRadius: 3,\n // position: \"absolute\",\n top: 8,\n // left: \"calc(50% - 15px)\",\n ...theme.applyStyles(\"dark\", {\n backgroundColor: grey[900],\n }),\n}));\n\nexport default function MobileDrawer(props: Props) {\n const { window } = props;\n const SideBarState = useSelector((state: any) => state.SideBar);\n const AppInfo = useSelector((state: any) => state.AppInfo.value);\n const dispatch = useDispatch();\n const toggleDrawer = (newState: boolean) => {\n dispatch(setSideBarState(newState));\n };\n // This is used only for the example\n const container =\n window !== undefined ? () => window().document.body : undefined;\n\n return (\n <SwipeableDrawer\n container={container}\n anchor=\"bottom\"\n open={SideBarState.isOpened}\n onClose={() => {\n toggleDrawer(false);\n }}\n onOpen={() => {\n toggleDrawer(true);\n }}\n swipeAreaWidth={drawerBleeding}\n disableSwipeToOpen={false}\n ModalProps={{\n keepMounted: true,\n }}\n >\n <Box\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n height: \"100%\",\n overflow: \"hidden\",\n }}\n >\n <Puller />\n <Box\n sx={{\n flexGrow: 1,\n display: \"flex\",\n justifyContent: \"center\",\n width: \"99%\",\n overflowY: \"auto\",\n }}\n >\n <NavigationTree />\n </Box>\n <Box\n sx={{\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"space-around\",\n marginTop: 1,\n width: \"100%\",\n }}\n >\n <Typography sx={{ fontSize: 12 }} color=\"textDisabled\">\n {AppInfo.appName}\n </Typography>\n <Typography sx={{ fontSize: 12 }} color=\"textDisabled\">\n V.{AppInfo.appVersion}\n </Typography>\n </Box>\n </Box>\n </SwipeableDrawer>\n );\n}\n","import { useSelector } from \"react-redux\";\nimport { Backdrop, CircularProgress } from \"@mui/material\";\nimport { useTranslation } from \"react-i18next\";\n\nconst LoadingMask: React.FC = () => {\n const { t } = useTranslation();\n const loadingMask = useSelector((state: any) => state.loadingMask.value);\n const AppLayoutState = useSelector((state: any) => state.AppLayout);\n\n return (\n <Backdrop\n dir={AppLayoutState.appDirection}\n sx={{ color: \"#fff\", zIndex: (theme) => theme.zIndex.drawer + 1 }}\n open={loadingMask.isOpened}\n >\n <CircularProgress color=\"inherit\" />\n <div style={{ marginRight: 10, marginLeft: 10 }}>\n {loadingMask?.message || t(\"DEFAULT_LOADING_MESSAGE\")}\n </div>\n </Backdrop>\n );\n};\n\nexport default LoadingMask;\n","import {\n Box,\n Button,\n CircularProgress,\n createTheme,\n Paper,\n TextField,\n Typography,\n} from \"@mui/material\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { ThemeProvider } from \"@emotion/react\";\nimport { useEffect, useState } from \"react\";\nimport axios from \"axios\";\nimport { toast } from \"react-toastify\";\nimport { UserSessionActions } from \"../../redux/features/common/UserSessionSlice\";\nimport {\n DARK_THEME_INITIAL_MAIN_COLOR,\n DARK_THEME_INITIAL_SECANDARY_COLOR,\n} from \"../../util\";\n\nconst Login: React.FC = () => {\n const appInfo = useSelector((state: any) => state.AppInfo.value);\n const [username, setUsername] = useState(\"\");\n const [password, setPassword] = useState(\"\");\n const [isLoginInProcess, setIsLoginInProcess] = useState(false);\n const UserSessionState = useSelector((state: any) => state.UserSession.value);\n const dispatch = useDispatch();\n const handleLogin = async () => {\n if (username == null || username == \"\") {\n toast.error(\"username is required to proceed\");\n return;\n }\n if (password == null || password == \"\") {\n toast.error(\"password is required to proceed\");\n return;\n }\n setIsLoginInProcess(true);\n let response: any = null;\n try {\n response = await axios.post(\n `${appInfo.apiBaseUrl}/api/auth/login`,\n {\n username,\n password,\n },\n {\n withCredentials: true,\n }\n );\n if (response.data != null && response.data !== \"\") {\n setIsLoginInProcess(false);\n const UserSession = {\n ...response.data,\n isAuthenticated: true,\n };\n if (response?.data?.token) {\n localStorage.setItem(\"TOKEN\", response.data.token);\n }\n dispatch(UserSessionActions.setAuthenticated(UserSession));\n }\n } catch (e: any) {\n setIsLoginInProcess(false);\n toast.error(\n e?.response?.data ||\n \"failed to authenticate, contact your administrator\"\n );\n }\n };\n const userSession = useSelector((state: any) => state.UserSession.value);\n const loginTheme = createTheme({\n components: {\n MuiCssBaseline: {\n styleOverrides: `\n /* Custom Scrollbar */\n * {\n scrollbar-width: thin;\n scrollbar-color: ${\n appInfo.appTheme?.dark?.primaryColor ||\n DARK_THEME_INITIAL_MAIN_COLOR\n } #121212;\n }\n \n /* Webkit Browsers */\n *::-webkit-scrollbar {\n width: 12px;\n height: 10px;\n } \n `,\n },\n },\n palette: {\n mode: \"dark\",\n primary: {\n main:\n appInfo.appTheme?.dark?.primaryColor || DARK_THEME_INITIAL_MAIN_COLOR,\n },\n secondary: {\n main:\n appInfo.appTheme?.dark?.secondaryColor ||\n DARK_THEME_INITIAL_SECANDARY_COLOR,\n },\n },\n });\n const checkUserSession = async () => {\n if (appInfo?.apiBaseUrl) {\n if (userSession.isAuthenticated == null) {\n const token = localStorage.getItem(\"TOKEN\");\n try {\n let response = await axios.get(\n `${appInfo.apiBaseUrl}/api/auth/userInfo`,\n {\n withCredentials: true,\n headers: { Authorization: `Bearer ${token}` },\n }\n );\n if (response != null && response.data != null) {\n const UserSession = {\n ...response.data,\n isAuthenticated: true,\n };\n dispatch(UserSessionActions.setAuthenticated(UserSession));\n } else {\n dispatch(UserSessionActions.setUnAuthenticated());\n }\n } catch (error) {\n dispatch(UserSessionActions.setUnAuthenticated());\n }\n }\n }\n };\n useEffect(() => {\n console.log(\"checking usersession on reload\", userSession);\n console.log(\"checking usersession app info\", appInfo);\n checkUserSession();\n }, [appInfo, userSession.isAuthenticated]);\n\n return (\n <ThemeProvider theme={loginTheme}>\n <Paper\n sx={{\n display: \"flex\",\n height: \"100vh\",\n width: \"100%\",\n borderRadius: 0,\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n {UserSessionState.isAuthenticated == false ? (\n <Box\n sx={{\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <img src={appInfo?.appLogo} width={150} height={150} />\n <Typography sx={{ m: 1 }} variant=\"h4\" color=\"textSecondary\">\n {appInfo?.appName}\n </Typography>\n <Typography\n sx={{\n paddingRight: 1,\n width: \"100%\",\n textAlign: \"right\",\n fontSize: 10,\n }}\n variant=\"caption\"\n color=\"textSecondary\"\n >\n V.{appInfo.appVersion}\n </Typography>\n <TextField\n label=\"username\"\n sx={{ width: 300, m: 1 }}\n value={username}\n onChange={(event) => {\n setUsername(event.target.value);\n }}\n onKeyDown={(event) => {\n if (event.key === \"Enter\") {\n handleLogin();\n }\n }}\n />\n <TextField\n label=\"password\"\n sx={{ width: 300, m: 1 }}\n value={password}\n type=\"password\"\n onChange={(event) => {\n setPassword(event.target.value);\n }}\n onKeyDown={(event) => {\n if (event.key === \"Enter\") {\n handleLogin();\n }\n }}\n />\n <Button\n loading={isLoginInProcess}\n onClick={handleLogin}\n variant=\"contained\"\n color=\"primary\"\n sx={{ m: 1 }}\n >\n login\n </Button>\n </Box>\n ) : (\n <>\n <CircularProgress sx={{ marginRight: 1 }} />\n <div>You will be redirected shortly ... please wait</div>\n </>\n )}\n </Paper>\n </ThemeProvider>\n );\n};\n\nexport default Login;\n","import { Box, Typography } from \"@mui/material\";\nimport {\n AppInfo,\n LicenseCheckObject,\n} from \"../../redux/features/common/AppInfoSlice\";\nimport { useSelector } from \"react-redux\";\nimport { useEffect, useState } from \"react\";\nimport { useAxios } from \"../../hooks\";\n\nconst NoLicenseComponent: React.FC = () => {\n const [licenseCheckObj, setLicenseCheckObject] = useState<LicenseCheckObject>(\n { isLicensed: true, lastLicenseCheckMessage: \"\", lastLicenseCheckTime: \"\" }\n );\n const { handleGetRequest } = useAxios();\n const appInfo: AppInfo = useSelector((state: any) => state.AppInfo.value);\n const checkSystemLicense = async () => {\n if (appInfo?.checkLicense?.endpoint) {\n await handleGetRequest({\n endPointURI: appInfo.checkLicense?.endpoint,\n successCallBkFn: (response) => {\n setLicenseCheckObject(response.data);\n },\n });\n }\n };\n\n useEffect(() => {\n if (appInfo?.checkLicense?.endpoint) {\n const interval = appInfo?.checkLicense?.interval || 60000;\n const intervalId = setInterval(() => {\n checkSystemLicense();\n }, interval);\n return () => {\n clearInterval(intervalId);\n console.log(\"Interval cleared\");\n };\n }\n }, [appInfo]);\n return !licenseCheckObj.isLicensed ? (\n <Box\n sx={{\n flex: 1,\n width: \"100%\",\n height: \"100%\",\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"center\",\n position: \"fixed\",\n top: 0,\n background: \"rgba(235, 235, 235, 0.8)\",\n left: 0,\n zIndex: 9999,\n }}\n >\n <img src={appInfo.appLogo} style={{ height: 200, width: 200 }} />\n <Typography variant=\"h5\">\n {appInfo.appName} - {appInfo.appVersion}\n </Typography>\n <Typography variant=\"h6\" color=\"error\">\n Your license is missing or has expired.\n </Typography>\n <Typography variant=\"h6\" color=\"error\">\n Please reach out to your vendor for assistance.\n </Typography>\n <Typography>\n License Check @{licenseCheckObj?.lastLicenseCheckTime || \"--------\"}\n </Typography>\n <Typography>\n License Check Result :{\" \"}\n {licenseCheckObj?.lastLicenseCheckMessage || \"--------\"}\n </Typography>\n </Box>\n ) : (\n <></>\n );\n};\n\nexport default NoLicenseComponent;\n","import { styled, useTheme } from \"@mui/material/styles\";\nimport CssBaseline from \"@mui/material/CssBaseline\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport TopBar from \"./TopBar\";\nimport { DrawerHeader } from \"./DrawerHeader\";\nimport SideBar from \"./SideBar\";\nimport MainContent from \"./MainContent\";\nimport { BrowserRouter } from \"react-router-dom\";\nimport MobileDrawer from \"./MobileDrawer\";\nimport { ToastContainer } from \"react-toastify\";\nimport { useIsMobile } from \"../hooks/UseMobile\";\nimport { DRAWER_WIDTH } from \"../redux/features/common/AppLayoutSlice\";\nimport { UserSessionProps } from \"../redux/features/common/UserSessionSlice\";\nimport LoadingMask from \"../components/common/LoadingMask\";\nimport Login from \"../components/common/Login\";\nimport NoLicenseComponent from \"../components/common/NoLicenseComponent\";\n\nconst Main = styled(\"main\", {\n shouldForwardProp: (prop) => prop !== \"open\",\n})<{\n open?: boolean;\n}>(({ theme: any, open }) => {\n const AppLayout = useSelector((state: any) => state.AppLayout);\n const theme = useTheme();\n const isMobile = useIsMobile();\n\n return {\n display: \"flex\",\n flexDirection: \"column\",\n overflow: \"hidden\",\n flexGrow: 1,\n width: !isMobile && open ? `calc(100% - ${DRAWER_WIDTH}px)` : \"100%\",\n direction: AppLayout.appDirection,\n justifyContent: \"flex-start\",\n transition:\n open === true\n ? theme.transitions.create([\"margin\", \"width\"], {\n easing: theme.transitions.easing.easeOut,\n duration: theme.transitions.duration.enteringScreen,\n })\n : theme.transitions.create([\"margin\", \"width\"], {\n easing: theme.transitions.easing.sharp,\n duration: theme.transitions.duration.leavingScreen,\n }),\n marginLeft:\n !isMobile && AppLayout.appDirection === \"ltr\" && open === true\n ? DRAWER_WIDTH + \"px\"\n : 0,\n marginRight:\n !isMobile && AppLayout.appDirection === \"rtl\" && open === true\n ? DRAWER_WIDTH + \"px\"\n : 0,\n };\n});\n\nexport default function Layout() {\n const SideBarState = useSelector((state: any) => state.SideBar);\n\n const isMobile = useIsMobile();\n const UserSession: UserSessionProps = useSelector(\n (state: any) => state.UserSession\n );\n const AppLayout = useSelector((state: any) => state.AppLayout);\n return (\n <BrowserRouter>\n <ToastContainer\n rtl={AppLayout.appDirection === \"rtl\"}\n draggable={true}\n position=\"bottom-center\"\n />\n <LoadingMask />\n {UserSession.value.isAuthenticated === true ? (\n // licenseCheckObj?.isLicensed ? (\n <Main open={SideBarState.isOpened}>\n <CssBaseline />\n <TopBar />\n {!isMobile ? <SideBar /> : null}\n {isMobile ? <MobileDrawer /> : null}\n <DrawerHeader />\n <MainContent />\n <NoLicenseComponent />\n </Main>\n ) : (\n <Login />\n )}\n </BrowserRouter>\n );\n}\n","import { createSlice, Reducer } from \"@reduxjs/toolkit\";\nimport { SystemRoute } from \"../../../routes/types\";\nimport { ExtendedTreeItemProps } from \"../../../navigationItems\";\nimport { StoreMetaData } from \"./CommonStoreSlice\";\n\nexport type LicenseCheckObject = {\n isLicensed: boolean;\n lastLicenseCheckMessage: string;\n lastLicenseCheckTime: string;\n};\n\nexport type AppInfo = {\n documentTitle: string | null;\n apiBaseUrl: string | null;\n appName: string | null;\n appVersion: string | null;\n appLogo: any | null;\n businessLocals?: {\n ar: { [key: string]: string };\n en: { [key: string]: string };\n };\n businessRoutes?: Array<SystemRoute>;\n businessNavigationItems?: Array<ExtendedTreeItemProps>;\n businessReduxReducers?: { [key: string]: Reducer<any> };\n businessCommonStoresMetaData?: { [key: string]: StoreMetaData };\n muiPremiumKey: string;\n enableAdministrationModule: boolean;\n enableUINotifications: Boolean;\n appTheme?: {\n light: { primaryColor: string; secondaryColor: string };\n dark: { primaryColor: string; secondaryColor: string };\n };\n checkLicense?: { endpoint: string; interval: number };\n};\n\nexport type AppInfoProp = {\n value: AppInfo;\n};\n\nconst initialState: AppInfoProp = {\n value: {\n documentTitle: null,\n apiBaseUrl: null,\n appName: null,\n appVersion: null,\n appLogo: null,\n muiPremiumKey: null,\n enableAdministrationModule: false,\n enableUINotifications: false,\n businessRoutes: [],\n businessNavigationItems: [],\n businessReduxReducers: {},\n businessCommonStoresMetaData: {},\n appTheme: {\n light: { primaryColor: \"#37505C\", secondaryColor: \"#ff6d00\" },\n dark: { primaryColor: \"#ea690e\", secondaryColor: \"#74776B\" },\n },\n },\n};\n\nconst AppInfoSlice = createSlice({\n name: \"AppInfo\",\n initialState: initialState,\n reducers: {\n setAppInfo: (state, action) => {\n state.value = action.payload;\n },\n },\n});\n\nexport const AppInfoActions = AppInfoSlice.actions;\nexport default AppInfoSlice.reducer;\n","import { CommonStores } from \"../common/CommonStoreSlice\";\n\nexport const ADMINISTRATION_STORES: CommonStores = {\n SystemDataSourceType: {\n autoLoad: false,\n data: [{ value: \"Mysql\" }, { value: \"Oracle\" }, { value: \"DB2\" }],\n url: \"\",\n },\n SystemParameterTypes: {\n autoLoad: false,\n url: \"\",\n data: [\n { value: \"text\" },\n { value: \"number\" },\n { value: \"date\" },\n { value: \"datetime\" },\n { value: \"combobox\" },\n { value: \"checkbox\" },\n { value: \"html\" },\n { value: \"lookup\" },\n ],\n },\n SystemReportTypes: {\n autoLoad: false,\n url: \"\",\n data: [{ value: \"Excel\" }, { value: \"Jasper\" }, { value: \"Blueprint\" }],\n },\n SystemWidgetTypes: {\n autoLoad: false,\n url: \"\",\n data: [\n { name: \"LineChart\" },\n { name: \"ColumnChart\" },\n { name: \"PieChart\" },\n { name: \"Card\" },\n { name: \"CircularProgress\" },\n { name: \"LinearProgress\" },\n ],\n },\n SystemTimeIntervals: {\n autoLoad: false,\n url: \"\",\n data: [\n { value: \"second\" },\n { value: \"minute\" },\n { value: \"hour\" },\n { value: \"day\" },\n { value: \"week\" },\n { value: \"month\" },\n { value: \"year\" },\n ],\n },\n SystemMailRecipientTypes: {\n autoLoad: false,\n url: \"\",\n data: [{ name: \"To\" }, { name: \"CC\" }],\n },\n SystemOrganizations: {\n autoLoad: true,\n url: \"api/v1/public/organization/all\",\n data: [],\n },\n SystemOrganizationRanks: {\n autoLoad: true,\n url: \"api/v1/public/organization/ranks/all\",\n data: [],\n },\n CurrentOrganizationRanks: {\n autoLoad: true,\n url: \"api/v1/public/organizationrank/all\",\n data: [],\n },\n SystemOrganizationUnits: {\n autoLoad: true,\n url: \"api/v1/public/organization/units/all\",\n data: [],\n },\n CurrentOrganizationUnits: {\n autoLoad: true,\n url: \"api/v1/public/organizationunit/all\",\n data: [],\n },\n SystemOrganizationUnitType: {\n autoLoad: true,\n url: \"api/v1/public/organizationunittype/all\",\n data: [],\n },\n SystemDataSources: {\n autoLoad: true,\n data: [],\n authority: \"DEVELOPMENT_ADMIN\",\n url: \"api/v1/dev/datasourceconnection/all\",\n },\n SystemDataQueries: {\n autoLoad: true,\n data: [],\n authority: \"DEVELOPMENT_ADMIN\",\n url: \"api/v1/dev/dataquery/all\",\n },\n SystemBluePrints: {\n autoLoad: true,\n data: [],\n authority: \"DEVELOPMENT_ADMIN\",\n url: \"api/v1/dev/blueprint/all\",\n },\n SystemReports: {\n autoLoad: true,\n data: [],\n authority: \"DEVELOPMENT_ADMIN\",\n url: \"api/v1/dev/report/all\",\n },\n SystemEntityParameters: {\n autoLoad: true,\n data: [],\n authority: \"DEVELOPMENT_ADMIN\",\n url: \"api/v1/dev/entityparameter/all\",\n },\n SystemMailTemplates: {\n autoLoad: true,\n data: [],\n authority: \"DEVELOPMENT_ADMIN\",\n url: \"api/v1/dev/mailtemplate/all\",\n },\n SystemWidgets: {\n autoLoad: true,\n data: [],\n authority: \"DEVELOPMENT_ADMIN\",\n url: \"api/v1/dev/widget/all\",\n },\n SystemApplicationModules: {\n autoLoad: true,\n data: [],\n authority: \"SYSTEM_ADMIN\",\n url: \"api/v1/admin/systemapplicationmodule/application/all\",\n },\n SystemApplicationAuthorities: {\n autoLoad: true,\n data: [],\n authority: \"SYSTEM_ADMIN\",\n url: \"api/v1/admin/systemapplicationauthority/all\",\n },\n SystemApplicationRoles: {\n autoLoad: true,\n data: [],\n authority: \"SYSTEM_ADMIN\",\n url: \"api/v1/admin/systemapplicationrole/all\",\n },\n};\n","import { useDispatch, useSelector } from \"react-redux\";\nimport { createTheme, ThemeOptions } from \"@mui/material\";\nimport { ThemeProvider } from \"@emotion/react\";\nimport React, { useEffect } from \"react\";\nimport Layout from \"../layout/Layout\";\nimport { AppInfo, AppInfoActions } from \"../redux/features/common/AppInfoSlice\";\nimport { LicenseInfo } from \"@mui/x-license\";\nimport {\n DARK_THEME_INITIAL_MAIN_COLOR,\n DARK_THEME_INITIAL_SECANDARY_COLOR,\n LIGHT_THEME_INITIAL_MAIN_COLOR,\n LIGHT_THEME_INITIAL_SECANDARY_COLOR,\n} from \"../util\";\nimport { setStoresMetaData } from \"../redux/features/common/CommonStoreSlice\";\nimport { ADMINISTRATION_STORES } from \"../redux/features/administration/AdministrationStoresMetaData\";\n\nconst App: React.FC<AppInfo> = (props: AppInfo) => {\n const dispatch = useDispatch();\n LicenseInfo.setLicenseKey(props.muiPremiumKey);\n const LightThemeOptions: ThemeOptions = {\n components: {\n MuiCssBaseline: {\n styleOverrides: `\n /* Custom Scrollbar */\n * {\n scrollbar-width: thin;\n scrollbar-color: ${\n props.appTheme?.light?.primaryColor ||\n LIGHT_THEME_INITIAL_MAIN_COLOR\n } #ffffff;\n }\n \n /* Webkit Browsers */\n *::-webkit-scrollbar {\n width: 12px;\n height: 10px;\n } \n `,\n },\n },\n palette: {\n mode: \"light\",\n primary: {\n main:\n props.appTheme?.light?.primaryColor || LIGHT_THEME_INITIAL_MAIN_COLOR,\n },\n secondary: {\n main:\n props.appTheme?.light?.secondaryColor ||\n LIGHT_THEME_INITIAL_SECANDARY_COLOR,\n },\n background: {\n default: \"#f5f5f5\",\n paper: \"#f5f5f5\",\n },\n },\n };\n const DarkThemeOptions: ThemeOptions = {\n components: {\n MuiCssBaseline: {\n styleOverrides: `\n /* Custom Scrollbar */\n * {\n scrollbar-width: thin;\n scrollbar-color: ${\n props.appTheme?.dark?.primaryColor || DARK_THEME_INITIAL_MAIN_COLOR\n } #121212;\n }\n \n /* Webkit Browsers */\n *::-webkit-scrollbar {\n width: 12px;\n height: 10px;\n } \n `,\n },\n },\n palette: {\n mode: \"dark\",\n primary: {\n main:\n props.appTheme?.dark?.primaryColor || DARK_THEME_INITIAL_MAIN_COLOR,\n },\n secondary: {\n main:\n props.appTheme?.dark?.secondaryColor ||\n DARK_THEME_INITIAL_SECANDARY_COLOR,\n },\n },\n };\n\n const AppLayoutState = useSelector((state: any) => state.AppLayout);\n let themeOptions = { ...LightThemeOptions };\n if (AppLayoutState.themeMode === \"dark\") {\n themeOptions = { ...DarkThemeOptions };\n }\n const theme = createTheme({\n direction: AppLayoutState.appDirection,\n ...themeOptions,\n });\n useEffect(() => {\n document.title = props.documentTitle;\n dispatch(AppInfoActions.setAppInfo(props));\n let commonStores = {};\n if (props.enableAdministrationModule) {\n commonStores = { ...ADMINISTRATION_STORES };\n }\n if (props.businessCommonStoresMetaData) {\n commonStores = {\n ...commonStores,\n ...props.businessCommonStoresMetaData,\n };\n }\n dispatch(setStoresMetaData(commonStores));\n }, [props]);\n return (\n <ThemeProvider theme={theme}>\n <Layout />\n </ThemeProvider>\n );\n};\n\nexport default App;\n","import common from \"./common.json\";\nimport AdminLocalsEn from \"./adminLocalsEn.json\";\nimport devLocalsEn from \"./devLocalsEn.json\";\n\nexport const ENGLISH_TRANS = {\n ...common,\n ...AdminLocalsEn,\n ...devLocalsEn,\n};\n","import common from \"./common.json\";\nimport adminLocalsAr from \"./adminLocalsAr.json\";\nimport devLocalAr from \"./devLocalsAr.json\";\n\nexport const ARABIC_TRANS = {\n ...common,\n ...adminLocalsAr,\n ...devLocalAr,\n};\n","import { Provider } from \"react-redux\";\nimport { library } from \"@fortawesome/fontawesome-svg-core\";\nimport { fab } from \"@fortawesome/free-brands-svg-icons\";\nimport { far } from \"@fortawesome/free-regular-svg-icons\";\nimport { fas } from \"@fortawesome/free-solid-svg-icons\";\nimport \"../styles/index.css\";\nimport \"react-toastify/dist/ReactToastify.css\";\nimport App from \"./App\";\nimport { AppInfo } from \"../redux/features/common/AppInfoSlice\";\nimport AppLayoutReducer from \"../redux/features/common/AppLayoutSlice\";\nimport UserSessionReducer from \"../redux/features/common/UserSessionSlice\";\nimport LoadingMaskReducer from \"../redux/features/common/LoadingMaskSlice\";\nimport CommonStoreReducer from \"../redux/features/common/CommonStoreSlice\";\nimport AppInfoReducer from \"../redux/features/common/AppInfoSlice\";\nimport SideBarReducer from \"../redux/features/common/SideBarSlice\";\nimport { configureStore } from \"@reduxjs/toolkit\";\nimport i18n from \"../locales/i18n\";\nimport { initReactI18next } from \"react-i18next\";\nimport { ENGLISH_TRANS } from \"../locales/english\";\nimport { ARABIC_TRANS } from \"../locales/arabic\";\nimport { useEffect, useState } from \"react\";\n\nlibrary.add(fab);\nlibrary.add(far);\nlibrary.add(fas);\n\nexport const BaseApp: React.FC<AppInfo> = (props) => {\n // let store = null;\n const [systemReducers, setSystemReducers] = useState<any>({\n AppLayout: AppLayoutReducer,\n UserSession: UserSessionReducer,\n loadingMask: LoadingMaskReducer,\n commonStores: CommonStoreReducer,\n SideBar: SideBarReducer,\n AppInfo: AppInfoReducer,\n });\n const store = configureStore({\n reducer: systemReducers,\n });\n const [isAppInitialized, setIsAppInitialized] = useState<boolean>(false);\n const initializeApp = () => {\n const reducers = {\n AppLayout: AppLayoutReducer,\n UserSession: UserSessionReducer,\n loadingMask: LoadingMaskReducer,\n commonStores: CommonStoreReducer,\n SideBar: SideBarReducer,\n AppInfo: AppInfoReducer,\n ...props?.businessReduxReducers,\n };\n setSystemReducers((state) => {\n return { ...reducers };\n });\n const resources = {\n en: { translation: { ...ENGLISH_TRANS, ...props?.businessLocals?.en } },\n ar: { translation: { ...ARABIC_TRANS, ...props?.businessLocals?.ar } },\n };\n i18n.use(initReactI18next).init({\n resources: resources, // Where we're gonna put translations' files\n lng: localStorage.getItem(\"language\") || \"en\", // Set the initial language of the App\n fallbackLng: \"en\",\n });\n setIsAppInitialized(true);\n };\n useEffect(() => {\n initializeApp();\n }, [props]);\n return isAppInitialized ? (\n <Provider store={store}>\n <App {...props} />\n </Provider>\n ) : (\n <></>\n );\n};\n"],"names":["css","ref","insertAt","document","head","getElementsByTagName","style","createElement","type","firstChild","insertBefore","appendChild","styleSheet","cssText","createTextNode","useIsMobile","breakpoint","isMobile","setIsMobile","useState","window","innerWidth","useEffect","handleResize","addEventListener","removeEventListener","DRAWER_WIDTH","AppLayoutSlice","createSlice","name","themeMode","localStorage","getItem","appDirection","reducers","setThemeMode","state","action","payload","setAppDirection","AppLayoutActions","actions","AppLayoutReducer","reducer","loadingMaskSlice","value","isOpened","message","showLoadingMask","hideLoadingMask","LoadingMaskReducer","useLoadingMask","dispatch","useDispatch","show","hide","UserSessionSlice","isAuthenticated","authorities","setAuthenticated","setUnAuthenticated","UserSessionActions","UserSessionReducer","useAxios","mask","apiBaseUrl","useSelector","AppInfo","axiosInstance","axios","create","baseURL","timeout","withCredentials","defaults","interceptors","request","use","config","token","headers","Authorization","error","Promise","reject","response","status","toast","autoClose","data","Blob","text","then","handleGetRequest","async","props","undefined","showMask","loadingMessage","get","endPointURI","params","parameters","responseType","successCallBkFn","failureCallBkFn","handlePostRequest","post","handleDeleteRequest","delete","HandleDownloadHTTPPostPDF","handleUploadRequest","files","length","formData","FormData","file","append","useConfirmationWindow","open","setOpen","t","useTranslation","ConfirmationWindow","_jsxs","Dialog","children","_jsx","DialogTitle","title","DialogContent","DialogContentText","body","DialogActions","Button","variant","sx","marginRight","marginLeft","color","onClick","onConfirmationCallBk","autoFocus","useSession","UserSession","UserInfo","isUserAuthorized","authorityCode","grantedAuthority","authority","isCurrentOrganizationAuthorizedToModule","moduleCode","currentOrganization","systemApplicationModules","subscripedModule","toLowerCase","useWindow","windowState","setWindowState","AppLayout","Window","windowProps","Modal","zIndex","theme","drawer","onClose","onCloseCallBack","Box","dir","position","top","left","maxHeight","transform","height","width","minWidth","minHeight","overflow","bgcolor","display","flexDirection","alignItems","justifyContent","AppBar","Toolbar","FontAwesomeIcon","icon","windowIcon","Typography","component","windowTitle","flexGrow","IconButton","Paper","padding","commonStoreSlice","initialState","stores","storeKeys","setStoresMetaData","Object","keys","setStoreData","storeKey","CommonStoreReducer","useApiActions","apiActionsProps","CommonStores","commonStores","session","reloadData","commonStoreKey","url","setData","findAll","loadRecordById","recordId","record","findById","findByIdParamName","saveRecord","savedRecord","save","deleteRecordById","result","deleteById","deleteByIdParamName","TemplateTextField","TextField","slotProps","inputLabel","shrink","fontWeight","label","_Fragment","helperText","not","a","b","filter","indexOf","intersection","TransferList","valueField","displayField","options","selectedOptions","setSelection","checked","setChecked","React","setLeft","right","setRight","leftFilterValue","setLeftFilterValue","rightFilterValue","setRightFilterValue","leftChecked","rightChecked","handleToggle","currentIndex","newChecked","push","splice","numberOfChecked","items","handleToggleAll","customList","unfilteredItems","side","option","toLocaleLowerCase","includes","Card","CardHeader","px","py","avatar","Checkbox","indeterminate","disabled","inputProps","subheader","fullWidth","onChange","event","target","Divider","List","dense","role","map","ListItemButton","cursor","ListItemIcon","tabIndex","disableRipple","ListItemText","id","primary","Grid2","container","spacing","margin","flex","direction","my","size","oldState","newState","concat","CheckBox","FormControlLabel","hidden","required","control","checkedValue","e","onChangeCallBack","unCheckedValue","ComboBox","AppLayoutState","Autocomplete","v","getValue","newValue","clearOnBlur","handleHomeEndKeys","getOptionLabel","renderOption","props1","slots","popper","Popper","renderInput","errorMessage","DATE_FORMAT","DATE_TIME_FORMAT","LIGHT_THEME_INITIAL_MAIN_COLOR","LIGHT_THEME_INITIAL_SECANDARY_COLOR","DARK_THEME_INITIAL_MAIN_COLOR","DARK_THEME_INITIAL_SECANDARY_COLOR","Datefield","LocalizationProvider","dateAdapter","AdapterMoment","DatePicker","moment","format","momentValue","isValid","textField","InputLabelProps","DatetimeField","DateTimePicker","SystemLookupCombobox","setOptions","lookupType","loadLookupOptions","generateDateColumn","colDef","renderEditCell","api","setEditCellValue","field","valueParser","row","column","valueFormatter","generateDateTimeColumn","generateComboColumn","valueGetter","renderCell","find","item","selectedRecord","generateCheckBoxColumn","getElementFields","element","fields","mode","elements","childElement","getAllFields","constructGridColumnsFromFields","isDefaultEditable","columns","tableField","fieldType","gridProps","muiProps","editable","fieldName","headerName","fieldLabel","headerAlign","align","searchable","optionValueField","optionDisplayField","constructValidationSchema","validationSchemaObj","z","number","required_error","invalid_type_error","optional","nullable","boolean","comboboxValueDataType","string","min","getGridSelection","rowSelectionModel","keyColumnName","sRecords","sRecordIds","ids","selectedId","x","selectedRecords","selectedRecordIds","formatMuiErrorMessage","code","args","URL","forEach","arg","searchParams","process","env","NODE_ENV","reactIsModule","exports","Symbol","for","c","d","f","g","h","k","l","m","n","p","q","r","w","y","u","$$typeof","A","reactIs_production_min","AsyncMode","ConcurrentMode","ContextConsumer","Element","ForwardRef","Fragment","Lazy","Portal","Profiler","StrictMode","Suspense","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isProfiler","isStrictMode","isSuspense","isValidElementType","typeOf","require$$0","hasSymbol","REACT_ELEMENT_TYPE","REACT_PORTAL_TYPE","REACT_FRAGMENT_TYPE","REACT_STRICT_MODE_TYPE","REACT_PROFILER_TYPE","REACT_PROVIDER_TYPE","REACT_CONTEXT_TYPE","REACT_ASYNC_MODE_TYPE","REACT_CONCURRENT_MODE_TYPE","REACT_FORWARD_REF_TYPE","REACT_SUSPENSE_TYPE","REACT_SUSPENSE_LIST_TYPE","REACT_MEMO_TYPE","REACT_LAZY_TYPE","REACT_BLOCK_TYPE","REACT_FUNDAMENTAL_TYPE","REACT_RESPONDER_TYPE","REACT_SCOPE_TYPE","object","$$typeofType","ContextProvider","Memo","hasWarnedAboutDeprecatedIsAsyncMode","reactIs_development","console","isPortal","getOwnPropertySymbols","hasOwnProperty","prototype","propIsEnumerable","propertyIsEnumerable","objectAssign","assign","test1","String","getOwnPropertyNames","test2","i","fromCharCode","join","test3","split","letter","err","shouldUseNative","source","from","symbols","to","val","TypeError","toObject","s","arguments","key","call","ReactPropTypesSecret_1","has","Function","bind","printWarning","ReactPropTypesSecret","loggedTypeFailures","require$$1","Error","checkPropTypes","typeSpecs","values","location","componentName","getStack","typeSpecName","ex","stack","resetWarningCache","checkPropTypes_1","ReactIs","require$$2","require$$3","require$$4","emptyFunctionThatReturnsNull","factoryWithTypeCheckers","isValidElement","throwOnDirectAccess","ITERATOR_SYMBOL","iterator","ANONYMOUS","ReactPropTypes","array","createPrimitiveTypeChecker","bigint","bool","func","symbol","any","createChainableTypeChecker","arrayOf","typeChecker","propName","propFullName","PropTypeError","propValue","Array","isArray","getPropType","elementType","instanceOf","expectedClass","expectedClassName","constructor","node","isNode","objectOf","propType","oneOf","expectedValues","is","valuesString","JSON","stringify","getPreciseType","oneOfType","arrayOfTypeCheckers","checker","getPostfixForTypeWarning","expectedTypes","checkerResult","expectedType","shape","shapeTypes","invalidValidatorError","exact","allKeys","this","validate","manualPropTypeCallCache","manualPropTypeWarningCount","checkType","isRequired","secret","cacheKey","chainedCheckType","every","iteratorFn","maybeIterable","getIteratorFn","step","entries","next","done","entry","RegExp","isSymbol","Date","PropTypes","emptyFunction","emptyFunctionWithReset","factoryWithThrowingShims","shim","getShim","propTypesModule","REACT_CONSUMER_TYPE","REACT_VIEW_TRANSITION_TYPE","REACT_CLIENT_REFERENCE","reactIs_production","SuspenseList","isSuspenseList","getModuleId","isPlainObject","getPrototypeOf","toStringTag","deepClone","output","deepmerge","clone","createBreakpoints","breakpoints","xs","sm","md","lg","xl","unit","other","sortedValues","breakpointsAsArray","sort","breakpoint1","breakpoint2","reduce","acc","obj","sortBreakpointsValues","up","down","between","start","end","endIndex","only","keyIndex","replace","sortContainerQueries","containerQueries","sorted","startsWith","regex","match","borderRadius","responsivePropType","merge","defaultBreakpoints","defaultContainerQueries","containerName","handleBreakpoints","styleFromPropValue","themeBreakpoints","index","breakpointKeys","some","containerKey","shorthand","matches","_formatErrorMessage","containerQuery","Number","isNaN","getContainerQuery","cssKey","removeUnusedBreakpoints","breakpointOutput","capitalize","charAt","toUpperCase","slice","getPath","path","checkVars","vars","getStyleValue","themeMapping","propValueFinal","userValue","prop","cssProperty","themeKey","fn","propTypes","filterProps","properties","directions","aliases","marginX","marginY","paddingX","paddingY","getCssProperties","cache","memoize","property","marginKeys","paddingKeys","spacingKeys","createUnaryUnit","defaultValue","themeSpacing","abs","Math","isInteger","transformed","createUnarySpacing","transformer","resolveCssProperty","cssProperties","getStyleFromPropValue","compose","styles","handlers","borderTransform","createBorderStyle","border","borderTop","borderRight","borderBottom","borderLeft","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outline","outlineColor","gap","columnGap","rowGap","paletteTransform","sizingTransform","maxWidth","breakpointsValues","defaultSxConfig","backgroundColor","pt","pr","pb","pl","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd","mt","mr","mb","ml","mx","marginTop","marginBottom","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd","displayPrint","textOverflow","visibility","whiteSpace","flexBasis","flexWrap","alignContent","order","flexShrink","alignSelf","justifyItems","justifySelf","gridColumn","gridRow","gridAutoFlow","gridAutoColumns","gridAutoRows","gridTemplateColumns","gridTemplateRows","gridTemplateAreas","gridArea","bottom","boxShadow","boxSizing","font","fontFamily","fontSize","fontStyle","letterSpacing","textTransform","lineHeight","textAlign","typography","styleFunctionSx","getThemeValue","nested","unstable_sxConfig","traverse","sxInput","sxObject","emptyBreakpoints","breakpointsInput","breakpointsInOrder","createEmptyBreakpointObject","breakpointsKeys","styleKey","maybeFn","objects","union","Set","objectsHaveSameKeys","modularCssLayers","unstable_createStyleFunctionSx","applyStyles","colorSchemes","getColorSchemeSelector","selector","palette","useTheme","defaultTheme","contextTheme","useContext","ThemeContext","systemDefaultTheme","paletteInput","spacingInput","shapeInput","mui","argsInput","argument","createSpacing","muiTheme","components","themeInput","toContainerQuery","mediaQuery","attachCq","cssContainerQueries","unstable_sx","createTheme","extendSxProp","inSx","systemProps","otherProps","splitProps","finalSx","defaultGenerator","ClassNameGenerator","generate","configure","generator","reset","createClassNameGenerator","o","clsx","globalStateClasses","active","completed","expanded","focused","focusVisible","readOnly","selected","themeId","defaultClassName","generateClassName","BoxRoot","tag","stylesFactory","emStyled","styled","shouldForwardProp","forwardRef","inProps","useThemeWithoutDefault","className","as","createBox","globalStatePrefix","slot","globalStateClass","generateUtilityClass","generateUtilityClasses","root","hasDigitsOnly","str","test","isNumber","isNumeric","trim","capitalizeFirstLetter","isValidEmail","email","timeAgo","dateInput","date","now","diffInSeconds","floor","locale","rtf","Intl","RelativeTimeFormat","numeric","units","seconds","delta","formatDate","parseStringToDate","dateString","toDate","FormElementField","fieldInfo","formManager","formActions","formValues","getFieldLabel","formProps","fieldLabelFn","hiddenFields","fieldSize","muiTextFieldProps","disabledFields","setValue","formValuesChangeCallBk","fieldHeight","formState","errors","toString","dateFormat","FormAction","setConfirmationWindowState","confirmationMessage","actionFn","formActionProps","actionButtonVariant","actionButtonColor","preActionValidation","isConfirmationRequired","FormElementGroup","AttachmentImageViewer","imgSrc","setImgSrc","imagePath","attachmentId","attachmentCode","refKey","category","handleImageSrc","showAsAvatar","Avatar","onError","onErrorImage","src","loading","alt","objectFit","AttachmentCard","allowDownload","downloadAuthorityKey","setAttachmentConfig","handleDelete","CardMedia","docType","CardContent","gutterBottom","fileName","attachmentSize","remark","CardActions","allowDelete","Tooltip","createObjectURL","link","href","setAttribute","click","remove","AttachmentPanel","setFiles","attachmentCategories","setAttachmentCategories","setRemark","selectedCategory","setSelectedCategory","allowedTypes","setAllowedTypes","attachmentConfig","getFileExtension","pop","loadAttachmentConfig","allowedFileTypes","cats","showAttachments","allowUpload","enableAttachment","uploadAuthorityKey","maxAllowedNumberOfFiles","refKeyAttachments","accept","multiple","fileExt","multiline","rows","existingAttachments","isCategoryRequired","MAX_SIZE_KB","maxSizeBytes","success","refKeyAttachment","WorkflowDocumentTimeLine","overflowY","actionHistory","actionHistoryRecord","actionTime","actionMethod","personId","documentActionEnName","documentActionArName","actionComment","employeeEnName","employeeArName","TemplateGridMultiRecordAction","rowAction","recordsToProcessActionOn","recordIdsToProcessActionOn","isActionAllowed","StyledQuickFilter","QuickFilter","StyledToolbarButton","ToolbarButton","ownerState","opacity","pointerEvents","transition","transitions","StyledTextField","overflowX","TemplateGridTopBar","isCreationAuthorized","templateProps","editAction","gridSelection","editMode","handleCreateNewRecord","rowActions","gridActionProps","multiRecord","_createElement","apiActions","gridLoadParametersValues","tBar","ColumnsPanelTrigger","render","GridViewColumnIcon","FilterPanelTrigger","Badge","badgeContent","filterCount","GridFilterListIcon","gridStateKey","clearGridState","orientation","flexItem","ExportExcel","MenuItem","QuickFilterTrigger","triggerProps","enterDelay","QuickFilterControl","controlProps","inputRef","placeholder","input","startAdornment","InputAdornment","endAdornment","QuickFilterClear","edge","TemplateGridRecordAction","iconStyle","getActionIconStyleForRecord","isActionVisibleForRecord","isActionDisabledForRecord","GridActionsCellItem","showInMenu","reloadGridAfterAction","currentNewRecordIndex","loadGridState","saved","parse","saveGridState","statePart","current","setItem","PIN_FIXED_COLUMNS","TemplateGrid","setSelectedRecord","attachmentPanelEnabledForRecord","setAttachmentPanelEnabledForRecord","getLookupOptions","generateLookupGridColumn","useLookupGridColumn","AttachmentWindow","setAttachmentWindowState","gridTitle","WorkFlowWindow","setWorkFlowWindowState","generatedColumns","setGeneratedColumns","formElements","savedState","useMemo","initialVisibilityState","columnVisibilityModel","existingFields","themeDirection","setColumnVisibilityModel","columnOrder","setColumnOrder","columnWidths","setColumnWidths","gridRowGroupingModel","setGridRowGroupingModel","columnGroupingModel","newLeft","pinnedColumns","newRight","setPinnedColumns","navigate","useNavigate","recordToDelete","setRecordToDelete","recordToEdit","setRecordToEdit","rowModesModel","setRowModesModel","adjustGridColumns","gridColumns","setRowSelectionModel","validationSchema","isEditAllowed","isDeleteAllowed","deleteAction","setConfirmationWindowOpened","isNew","postActionCallBack","oldData","formModalHeight","formModalWidth","formModalMinHeight","formModalMinWidth","formModalIcon","formModalTitle","specs","modalHeight","modalWidth","modalMinHeight","modalMinWidth","modalIcon","modalTitle","FormWindow","setFormWindowState","actionColumn","isEnabled","attachment","workFlowDocumentCode","getActions","disableDefaultAction","isInEditMode","GridRowModes","Edit","View","handleSaveRowClick","ignoreModifications","newData","handleCancelRowEditClick","isEditActionVisibleForRecord","isActionEditDisabledForRecord","formRoute","handleEditRecord","isDeleteActionVisibleForRecord","isDeleteActionDisabledForRecord","enableAttachFn","structuredColumns","autoLoad","adjustedColumns","baseCols","col","fieldToCol","Map","Boolean","formComponent","recordIdToEdit","formCloseCallBk","TemplateForm","editAuthorityKey","formSavedSuccessfullyCallBk","preSaveValidation","hideInfoBar","hideBackButton","girdIcon","gridLoadParameters","setGridLoadParametersValues","Accordion","defaultExpanded","AccordionSummary","expandIcon","GridExpandMoreIcon","AccordionDetails","saveButtonSpecs","cancelButtonSpecs","WorkflowDocumentPanel","refDocumentId","postActionCallBk","cancelActionCallBk","DataGridPremium","toolbar","newRecord","oldRows","oldModel","removeItem","getRowId","showToolbar","checkboxSelection","onRowEditStop","reason","defaultMuiPrevented","onRowModesModelChange","newModel","rowGroupingColumnMode","processRowUpdate","log","ZodError","validateRecord","requestObject","reloadAfterSave","onRowSelectionModelChange","gridSelectionModel","onColumnVisibilityModelChange","model","onColumnOrderChange","targetIndex","prevOrder","currentOrder","fromIndex","rowGroupingModel","onRowGroupingModelChange","handleRowGroupChange","getGridColumnsFromRecord","formElement","ExcelReportViewer","reportData","report_record_data_key","setReportData","reloadReport","useParameterPanel","parametersValues","setParametersValues","initialParameterValues","panelElements","parameterValues","parameter","parameterLabel","parameterCode","parameterType","mandatory","getFormElementsFromParameters","ParameterPanel","searchBtnClickCallBk","prefix","iconName","isIdRequired","enabled","ReportViewer","blobUrl","setBlobUrl","setErrorMessage","excelReportData","setExcelReportData","reportViewerState","setReportViewerState","reportInfo","setReportInfo","reportParameters","reportParametersValues","runReport","reportType","reportCode","resultMode","jasperOutPutFileType","contentDisposition","filename","blob","download","removeChild","revokeObjectURL","byPassParameterEntry","loadReportData","reportName","setAction","authorizedActions","setAuthorizedActions","setActionComment","workflowDocumentInfo","setWorkflowDocumentInfo","referencedDocument","workflowDocumentReport","workflowDocument","workflowDocumentStatus","actionsHistory","nextActionTakers","nextActions","ReporTViewWindow","setReportViewWindowState","documentEnName","documentNumberField","documentArName","loadWorkFlowDocumentInfo","workflowDocumentCode","processWorkflowDocumentAction","workflowDocumentId","actionId","refDocumentStatus","documentStatusCode","post_action_endpoint","nextActionTakersAuthority","actionTaker","username","USERNAME","doc_id","documentStatusEnName","documentStatusArName","startIcon","require_comment","pre_action_endpoint","nextActionTaker","employee_en_name","employee_ar_name","mobile_number","WorkflowWindow","setWorkflowWindowState","initiallyHiddenFields","setHiddenFields","initialValues","setDisabledFields","formSchema","useForm","resolver","zodResolver","defaultValues","watch","pathParameters","useParams","formRouteRecordIdParamName","loadRecord","idToLoad","retrievedRecord","setFieldValue","fieldValue","hideField","oldValues","showField","disableField","enableField","handleSubmit","WorkflowRouteComponent","TemplateBarChart","BarChart","dataset","xAxis","dataKey","scaleType","valueLabel","series","labelField","TemplateDataCard","TemplateGauge","Gauge","valueMax","total","TemplateLineChart","LineChart","LinearProgressWithLabel","LinearProgress","round","TemplateLineProgress","TemplatePieChart","chartData","PieChart","WidgetViewer","isWidgetLoading","setWidgetLoading","loadWidget","queryId","dataQueryId","getWidgetData","loadCounter","widgetType","verticalAxisField","spin","widgetTitle","horizontalAxisField","horizontalAxisLabel","DashboardViewer","dashboardInfo","setDashboardInfo","dashboardCode","dashboardName","dashboardTitle","dashboardParameters","widgets","setLoadCounter","loadDashboard","setLoadDashboard","shouldLoadWidgets","loadDashboardInfo","widget","DashboardRouteView","ChangeOrgForm","newOrgId","setNewOrgId","userOrganizations","orgId","successChangeCallBackFn","SideBarSlice","toggleSideBarState","setSideBarState","SideBarReducer","useInterval","callback","delay","savedCallback","useRef","setInterval","clearInterval","beatFade","keyframes","NotificationItem","notification","notificationId","notificationAction","notificationActionPayload","isNotified","notificationQueueId","notificationTextColor","notificationIcon","notificationIconColor","notificationEnText","notificationArText","animation","createTime","showDivider","NotificationButton","anchorEl","setAnchorEl","notifications","setNotifications","info","closeOnClick","notificationsCheckIntervalSeconds","ClickAwayListener","onClickAway","currentTarget","anchorOrigin","vertical","horizontal","notificaiton","placement","TransitionProps","Fade","ChangePasswordPanel","currentPassword","setCurrentPassword","password1","setPassword1","password2","setPassword2","selectedPerson","isSelfService","newPassword","onSuccessCallBk","handleChangePasswordRequest","MuiAppBar","easing","sharp","duration","leavingScreen","variants","easeOut","enteringScreen","TopBar","ChangeOrgWindow","setChangeOrgWindowState","anchorElUser","setAnchorElUser","handleCloseUserMenu","handleOpenUserMenu","SideBarState","SideBar","ChangePasswordWindow","setChangePasswordWindow","Menu","keepMounted","transformOrigin","noWrap","appName","organizationEnName","organizationArName","i18n","language","nextLanguage","lng","changeLanguage","enableUINotifications","rotation","DrawerHeader","mixins","findNavigationItemById","nodes","found","NavigationItems","actionPayload","DotIcon","verticalAlign","StyledTreeItemRoot","TreeItem2Root","grey","treeItemClasses","groupTransition","CustomTreeItemContent","TreeItem2Content","dark","main","content","alpha","contrastText","AnimatedCollapse","animated","Collapse","TransitionComponent","useSpring","in","StyledTreeItemLabelText","CustomLabel","expandable","appLayoutState","TreeItem2Label","isExpandable","reactChildren","CustomTreeItem","itemId","getRootProps","getContentProps","getIconContainerProps","getCheckboxProps","getLabelProps","getGroupTransitionProps","getDragAndDropOverlayProps","publicAPI","useTreeItem2","rootRef","TreeItem2Provider","TreeItem2IconContainer","TreeItem2Icon","TreeItem2Checkbox","TreeItem2DragAndDropOverlay","NavigationTree","filterData","parentItems","parentItem","applicationModule","newParentItem","structuredClone","mergedNavigationItems","enableAdministrationModule","businessNavigationItems","authoriedNavigationItems","RichTreeView","onItemClick","navigationItem","Drawer","anchor","appVersion","cacheRtl","createCache","stylisPlugins","prefixer","rtlPlugin","cacheLtr","OrgMemberRoleForm","setSelectedOptions","availableOptions","setAvailableOptions","orgMemberId","organizationId","currentRoles","availableRoles","getOrgMemberRoles","closeModalFn","OrganizationMemberGrid","OrganizationMemberRolesWindow","setOrganizationMemberRolesWindowState","SystemOrganizations","SystemOrganizationRanks","SystemOrganizationUnits","OrganizationRankGrid","loadOrganizationRanks","OrganizationUnitGrid","organizationUnitTypes","SystemOrganizationUnitType","loadOrganizationUnits","OrganizationUnitTypeGrid","SystemApplicationAuthorityGrid","SystemApplicationModules","SystemApplicationModuleGrid","RoleAuthoritiesForm","availableAuthorities","setAvailableAuthorities","roleId","selectedAuthorities","getRoleAuthorities","SystemApplicationRoleGrid","selectedRole","setSelectedRole","RoleaAuthoritiesWindow","setRoleAuthoritiesWindowState","DataQueryParameterGrid","SystemEntityParameters","LookupGrid","ReportParameterGrid","reportId","storageTypes","adjustFormAfterValueChange","useSysCon","MailRecipientGrid","mailTemplateId","recipientMail","MailBodyGrid","SystemDataQueries","MailAttachmentGrid","SystemReports","validationObject","Gmail","mailHost","isMandatory","isVisible","mailPort","mailUsername","mailPassword","mailProtocol","isMailSmtpAuthEnabled","isMailStarttlsEnabled","isSmtpSSlEnabled","azureGraphApiClientId","azureGraphApiClientSecret","azureGraphApiTenantId","azureGraphApiScope","azureGraphApiEmailId","Azure","adjustFormAccordingToEngineType","validationObjects","WorkflowDocumentStatusGrid","WorkflowDocumentActionMailGrid","SystemMailTemplates","documentActionId","WorkflowDocumentActionGrid","ActionMailsWindow","setActionMailWindowState","workflowStates","setWorkflowStates","loadWorkFlowDocumentStates","DashboardWidgetGrid","SystemWidgets","dashboardId","SYSTEM_ROUTES","setSelectedPerson","CurrentOrganizationRanks","CurrentOrganizationUnits","OrganizationMembersWindow","setOrganizationMemberWindowState","organizationMemberId","refSource","DataQueryParameterWindow","setDataQueryParameterWindow","SystemDataSources","SystemDataSourceType","SystemParameterTypes","ReporTrialWindow","setReportTrialWindowState","ReportParameterWindow","setReportParameterWindowState","SystemBluePrints","useSysDatasource","datasourceConId","reportJasperName","reportBluePrintId","reportExcelDataQueryId","SystemTimeIntervals","MailRecipentsWindow","setMailRecipientsWindowState","MailBodiesWindow","setMailBodiesWindowState","MailAttachmentWindow","setMailAttachmentWindowState","callBkFn","periodical","periodType","periodValue","startSendingAt","onValueChangeCallBack","formLoadCallBk","mailEngine","WorkflowStatusWindow","setWorkflowStatusWindowState","WorkflowActionWindow","setWorkflowActionWindowState","SystemWidgetTypes","WidgetsWindows","setWidgetsWindowState","mailNotificationQueueId","resendMail","loadUserNotifications","RouteWrapper","MainContent","businessRoutes","isAutoLoadLoaded","setAutoLoadLoaded","loadCommonStores","CacheProvider","Routes","route","Route","Puller","MobileDrawer","toggleDrawer","SwipeableDrawer","onOpen","swipeAreaWidth","disableSwipeToOpen","ModalProps","LoadingMask","loadingMask","Backdrop","CircularProgress","Login","appInfo","setUsername","password","setPassword","isLoginInProcess","setIsLoginInProcess","UserSessionState","handleLogin","userSession","loginTheme","MuiCssBaseline","styleOverrides","appTheme","primaryColor","secondary","secondaryColor","checkUserSession","ThemeProvider","appLogo","onKeyDown","NoLicenseComponent","licenseCheckObj","setLicenseCheckObject","isLicensed","lastLicenseCheckMessage","lastLicenseCheckTime","checkLicense","endpoint","intervalId","checkSystemLicense","interval","background","Main","Layout","BrowserRouter","ToastContainer","rtl","draggable","CssBaseline","AppInfoSlice","documentTitle","muiPremiumKey","businessReduxReducers","businessCommonStoresMetaData","light","setAppInfo","AppInfoActions","AppInfoReducer","ADMINISTRATION_STORES","SystemReportTypes","SystemMailRecipientTypes","SystemApplicationAuthorities","SystemApplicationRoles","App","LicenseInfo","setLicenseKey","LightThemeOptions","default","paper","DarkThemeOptions","themeOptions","ENGLISH_TRANS","common","AdminLocalsEn","ARABIC_TRANS","adminLocalsAr","library","add","fab","far","fas","BaseApp","systemReducers","setSystemReducers","store","configureStore","isAppInitialized","setIsAppInitialized","resources","en","translation","businessLocals","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B,MAAkBpuD,GAAOwvD,gBAAgBF,KACjEG,GAAI,CAAEF,YAAa,IAAKhB,MAAiBvuD,GAAOwvD,gBAAgBC,MAElE/T,GAAK58C,IAAI4wD,IAAkBC,KAAK,CAC9BN,UAAWA,EACXxT,IAAK7/C,aAAaC,QAAQ,aAAe,KACzC2zD,YAAa,OAEfR,GAAoB,IAGpBS,IACC,CAAC7vD,IACGmvD,EACLntD,EAAC8tD,EAAQ,CAACb,MAAOA,EAAKltD,SACpBC,EAAC4rD,GAAG,IAAK5tD,MAGXgC,EAAA6G,EAAA,CAAA","x_google_ignoreList":[0,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67]}
|