| @@ -141,17 +141,20 @@ function Header(props) { | |||||
| <Link className="userProfileGld" to='/user/profile'><Typography style={{ opacity: 0.9 }} variant={"pnspsHeaderTitle"} sx={{ ml: 2, mt: 1, mb: 1 }}>My Profile</Typography></Link> | <Link className="userProfileGld" to='/user/profile'><Typography style={{ opacity: 0.9 }} variant={"pnspsHeaderTitle"} sx={{ ml: 2, mt: 1, mb: 1 }}>My Profile</Typography></Link> | ||||
| </li> | </li> | ||||
| <li> | <li> | ||||
| <Link className="emailTemplate" to='/emailTemplate'><Typography style={{ opacity: 0.9 }} variant={"pnspsHeaderTitle"} sx={{ ml: 2, mt: 1, mb: 1 }}>Email Template</Typography></Link> | |||||
| <Link className="emailTemplate" to='/setting/emailTemplate'><Typography style={{ opacity: 0.9 }} variant={"pnspsHeaderTitle"} sx={{ ml: 2, mt: 1, mb: 1 }}>Email Template</Typography></Link> | |||||
| </li> | </li> | ||||
| <li> | <li> | ||||
| <Link className="systemSetting" to='/setting/sys'><Typography style={{ opacity: 0.9 }} variant={"pnspsHeaderTitle"} sx={{ ml: 2, mt: 1, mb: 1 }}>System Setting</Typography></Link> | <Link className="systemSetting" to='/setting/sys'><Typography style={{ opacity: 0.9 }} variant={"pnspsHeaderTitle"} sx={{ ml: 2, mt: 1, mb: 1 }}>System Setting</Typography></Link> | ||||
| </li> | </li> | ||||
| <li> | <li> | ||||
| <Link className="holidaySetting" to='/holiday'><Typography style={{ opacity: 0.9 }} variant={"pnspsHeaderTitle"} sx={{ ml: 2, mt: 1, mb: 1 }}>Holiday Setting</Typography></Link> | |||||
| <Link className="holidaySetting" to='/setting/holiday'><Typography style={{ opacity: 0.9 }} variant={"pnspsHeaderTitle"} sx={{ ml: 2, mt: 1, mb: 1 }}>Holiday Setting</Typography></Link> | |||||
| </li> | </li> | ||||
| <li> | <li> | ||||
| <Link className="announcement" to='/setting/announcement'><Typography style={{ opacity: 0.9 }} variant={"pnspsHeaderTitle"} sx={{ ml: 2, mt: 1, mb: 1 }}>Announcement</Typography></Link> | <Link className="announcement" to='/setting/announcement'><Typography style={{ opacity: 0.9 }} variant={"pnspsHeaderTitle"} sx={{ ml: 2, mt: 1, mb: 1 }}>Announcement</Typography></Link> | ||||
| </li> | </li> | ||||
| <li> | |||||
| <Link className="gazetteissueSetting" to='/setting/gazetteissuepage'><Typography style={{ opacity: 0.9 }} variant={"pnspsHeaderTitle"} sx={{ ml: 2, mt: 1, mb: 1 }}>Gazette Issue</Typography></Link> | |||||
| </li> | |||||
| </ul> | </ul> | ||||
| </li> | </li> | ||||
| <Box sx={{display: {xs: 'none', sm: 'none', md: 'block'}}}> | <Box sx={{display: {xs: 'none', sm: 'none', md: 'block'}}}> | ||||
| @@ -56,7 +56,7 @@ const SearchPublicNoticeForm = ({ applySearch, issueComboData, _paymentCount, _p | |||||
| function getIssueLabel(data) { | function getIssueLabel(data) { | ||||
| if (data == {}) return ""; | if (data == {}) return ""; | ||||
| return data.year | |||||
| return data.issueYear | |||||
| + " Vol. " + FormatUtils.zeroPad(data.volume, 3) | + " Vol. " + FormatUtils.zeroPad(data.volume, 3) | ||||
| + ", No. " + FormatUtils.zeroPad(data.issueNo, 2) | + ", No. " + FormatUtils.zeroPad(data.issueNo, 2) | ||||
| + ", " + DateUtils.dateFormat(data.issueDate, "D MMM YYYY (ddd)"); | + ", " + DateUtils.dateFormat(data.issueDate, "D MMM YYYY (ddd)"); | ||||
| @@ -75,7 +75,7 @@ const SearchDemandNoteForm = ({ applySearch, orgComboData, searchCriteria, issue | |||||
| function getIssueLabel(data) { | function getIssueLabel(data) { | ||||
| if (data == {}) return ""; | if (data == {}) return ""; | ||||
| return data.year | |||||
| return data.issueYear | |||||
| + " Vol. " + FormatUtils.zeroPad(data.volume, 3) | + " Vol. " + FormatUtils.zeroPad(data.volume, 3) | ||||
| + ", No. " + FormatUtils.zeroPad(data.issueNo, 2) | + ", No. " + FormatUtils.zeroPad(data.issueNo, 2) | ||||
| + ", " + DateUtils.dateFormat(data.issueDate, "D MMM YYYY (ddd)"); | + ", " + DateUtils.dateFormat(data.issueDate, "D MMM YYYY (ddd)"); | ||||
| @@ -64,7 +64,7 @@ const SearchDemandNoteForm = ({ applySearch, searchCriteria, issueComboData | |||||
| function getIssueLabel(data) { | function getIssueLabel(data) { | ||||
| if (data == {}) return ""; | if (data == {}) return ""; | ||||
| return data.year | |||||
| return data.issueYear | |||||
| + " Vol. " + FormatUtils.zeroPad(data.volume, 3) | + " Vol. " + FormatUtils.zeroPad(data.volume, 3) | ||||
| + ", No. " + FormatUtils.zeroPad(data.issueNo, 2) | + ", No. " + FormatUtils.zeroPad(data.issueNo, 2) | ||||
| + ", " + DateUtils.dateFormat(data.issueDate, "D MMM YYYY (ddd)"); | + ", " + DateUtils.dateFormat(data.issueDate, "D MMM YYYY (ddd)"); | ||||
| @@ -0,0 +1,167 @@ | |||||
| // material-ui | |||||
| import { | |||||
| Grid, | |||||
| Typography, | |||||
| Stack, | |||||
| Button, | |||||
| Dialog, DialogTitle, DialogContent, DialogActions, | |||||
| } from '@mui/material'; | |||||
| import * as UrlUtils from "utils/ApiPathConst"; | |||||
| import * as React from "react"; | |||||
| import * as HttpUtils from "utils/HttpUtils"; | |||||
| import titleBackgroundImg from 'assets/images/dashboard/gazette-bar.png' | |||||
| const BackgroundHead = { | |||||
| backgroundImage: `url(${titleBackgroundImg})`, | |||||
| width: '100%', | |||||
| height: '100%', | |||||
| backgroundSize: 'contain', | |||||
| backgroundRepeat: 'no-repeat', | |||||
| backgroundColor: '#0C489E', | |||||
| backgroundPosition: 'right' | |||||
| } | |||||
| import {PNSPS_LONG_BUTTON_THEME} from "themes/buttonConst"; | |||||
| import {ThemeProvider} from "@emotion/react"; | |||||
| import { notifySaveSuccess } from 'utils/CommonFunction'; | |||||
| // ==============================|| DASHBOARD - DEFAULT ||============================== // | |||||
| const Index = () => { | |||||
| const [attachments, setAttachments] = React.useState([]); | |||||
| const [waitImport, setWaitImport] = React.useState(false); | |||||
| const [waitDownload, setWaitDownload] = React.useState(false); | |||||
| const [isWarningPopUp, setIsWarningPopUp] = React.useState(false); | |||||
| const [warningText, setWarningText] = React.useState(""); | |||||
| React.useEffect(() => { | |||||
| if (attachments.length > 0) { | |||||
| importHoliday(); | |||||
| } | |||||
| }, [attachments]); | |||||
| const readFile = (event) => { | |||||
| let file = event.target.files[0]; | |||||
| if (file) { | |||||
| if (!file.name.toLowerCase().substr(file.name.length - 5).includes(".xlsx")) { | |||||
| setWarningText("Please upload a valid file (File format: .xlsx)."); | |||||
| setIsWarningPopUp(true); | |||||
| document.getElementById("uploadFileBtn").value = ""; | |||||
| return; | |||||
| } | |||||
| file['id'] = attachments.length; | |||||
| setAttachments([ | |||||
| ...attachments, | |||||
| file | |||||
| ]); | |||||
| document.getElementById("uploadFileBtn").value = ""; | |||||
| } | |||||
| } | |||||
| const doExport=()=>{ | |||||
| setWaitDownload(true) | |||||
| HttpUtils.fileDownload({ | |||||
| url: UrlUtils.GET_ISSUE_LIST, | |||||
| onResponse: () => { | |||||
| setTimeout(()=> setWaitDownload(false), 500) | |||||
| } | |||||
| }); | |||||
| } | |||||
| const importHoliday = () => { | |||||
| setWaitImport(true); | |||||
| if (!attachments || attachments.length <= 0) { | |||||
| setWarningText("Please upload file."); | |||||
| setSaving(false); | |||||
| return; | |||||
| } | |||||
| HttpUtils.postWithFiles({ | |||||
| url: UrlUtils.POST_ISSUE_FILE, | |||||
| files: attachments, | |||||
| onSuccess: () => { | |||||
| notifySaveSuccess() | |||||
| setWaitImport(false); | |||||
| setAttachments([]); | |||||
| // loadForm(); | |||||
| } | |||||
| }); | |||||
| } | |||||
| return ( | |||||
| <Grid container sx={{minHeight: '87vh', backgroundColor: 'backgroundColor.default'}} direction="column" justifyContent="flex-start" alignItems="center" > | |||||
| <Grid item xs={12} width="100%"> | |||||
| <div style={BackgroundHead} width="100%"> | |||||
| <Stack direction="row" height='70px'> | |||||
| <Typography ml={15} color='#FFF' variant="h4" sx={{ pt: 2 }}>Gazette Issue</Typography> | |||||
| </Stack> | |||||
| </div> | |||||
| </Grid> | |||||
| <Grid item xs={12} md={12} lg={6} width="100%"> | |||||
| <Stack direction="row" justifyContent="flex-start" alignItems="center" spacing={2} sx={{ml:2,mt:1}} > | |||||
| <ThemeProvider theme={PNSPS_LONG_BUTTON_THEME}> | |||||
| <label htmlFor="downloadFileBtn"> | |||||
| <Button | |||||
| component="span" | |||||
| variant="contained" | |||||
| size="large" | |||||
| disabled={waitDownload} | |||||
| onClick={doExport} | |||||
| > | |||||
| <Typography variant="h5">Export</Typography> | |||||
| </Button> | |||||
| </label> | |||||
| </ThemeProvider> | |||||
| <ThemeProvider theme={PNSPS_LONG_BUTTON_THEME}> | |||||
| <input | |||||
| id="uploadFileBtn" | |||||
| name="file" | |||||
| type="file" | |||||
| accept=".xlsx" | |||||
| style={{ display: 'none' }} | |||||
| disabled={waitImport} | |||||
| onChange={(event) => { | |||||
| readFile(event) | |||||
| }} | |||||
| /> | |||||
| <label htmlFor="uploadFileBtn"> | |||||
| <Button | |||||
| component="span" | |||||
| variant="contained" | |||||
| size="large" | |||||
| disabled={waitImport} | |||||
| > | |||||
| <Typography variant="h5">Upload Files</Typography> | |||||
| </Button> | |||||
| </label> | |||||
| </ThemeProvider> | |||||
| </Stack> | |||||
| </Grid> | |||||
| <div> | |||||
| <Dialog | |||||
| open={isWarningPopUp} | |||||
| onClose={() => setIsWarningPopUp(false)} | |||||
| PaperProps={{ | |||||
| sx: { | |||||
| minWidth: '40vw', | |||||
| maxWidth: { xs: '90vw', s: '90vw', m: '70vw', lg: '70vw' }, | |||||
| maxHeight: { xs: '90vh', s: '70vh', m: '70vh', lg: '60vh' } | |||||
| } | |||||
| }} | |||||
| > | |||||
| <DialogTitle><Typography variant="h3">Warning</Typography></DialogTitle> | |||||
| <DialogContent style={{ display: 'flex', }}> | |||||
| <Typography variant="h4" style={{ padding: '16px' }}>{warningText}</Typography> | |||||
| </DialogContent> | |||||
| <DialogActions> | |||||
| <Button onClick={() => setIsWarningPopUp(false)}><Typography variant="h5">OK</Typography></Button> | |||||
| </DialogActions> | |||||
| </Dialog> | |||||
| </div> | |||||
| </Grid > | |||||
| ); | |||||
| }; | |||||
| export default Index; | |||||
| @@ -47,7 +47,7 @@ export default function EmailTemplateTable({ recordList }) { | |||||
| <FiDataGrid | <FiDataGrid | ||||
| rows={rows} | rows={rows} | ||||
| columns={columns} | columns={columns} | ||||
| customPageSize={10} | |||||
| customPageSize={20} | |||||
| // onRowDoubleClick={handleRowDoubleClick} | // onRowDoubleClick={handleRowDoubleClick} | ||||
| getRowHeight={() => 'auto'} | getRowHeight={() => 'auto'} | ||||
| /> | /> | ||||
| @@ -12,7 +12,7 @@ import * as HttpUtils from "utils/HttpUtils"; | |||||
| import Loadable from 'components/Loadable'; | import Loadable from 'components/Loadable'; | ||||
| const LoadingComponent = Loadable(React.lazy(() => import('pages/extra-pages/LoadingComponent'))); | const LoadingComponent = Loadable(React.lazy(() => import('pages/extra-pages/LoadingComponent'))); | ||||
| const HolidayTable = Loadable(React.lazy(() => import('pages/Holiday/Search_GLD/DataGrid'))) | |||||
| const HolidayTable = Loadable(React.lazy(() => import('pages/Holiday/DataGrid'))) | |||||
| import titleBackgroundImg from 'assets/images/dashboard/gazette-bar.png' | import titleBackgroundImg from 'assets/images/dashboard/gazette-bar.png' | ||||
| // import AddCircleOutlineIcon from '@mui/icons-material/AddCircleOutline'; | // import AddCircleOutlineIcon from '@mui/icons-material/AddCircleOutline'; | ||||
| import MainCard from 'components/MainCard'; | import MainCard from 'components/MainCard'; | ||||
| @@ -40,13 +40,15 @@ const Index = () => { | |||||
| const [record, setRecord] = React.useState([]); | const [record, setRecord] = React.useState([]); | ||||
| const [comboData, setComboData] = React.useState([]); | const [comboData, setComboData] = React.useState([]); | ||||
| const [onReady, setOnReady] = React.useState(false); | const [onReady, setOnReady] = React.useState(false); | ||||
| const [onSearchReady, setOnSearchReady] = React.useState(false); | |||||
| // const navigate = useNavigate() | // const navigate = useNavigate() | ||||
| const [searchCriteria, setSearchCriteria] = React.useState({ | const [searchCriteria, setSearchCriteria] = React.useState({ | ||||
| year: dateStr_Year(new Date()), | year: dateStr_Year(new Date()), | ||||
| // dateFrom: DateUtils.dateStr(new Date().setDate(new Date().getDate()-14)), | // dateFrom: DateUtils.dateStr(new Date().setDate(new Date().getDate()-14)), | ||||
| }); | }); | ||||
| const [attachments, setAttachments] = React.useState([]); | const [attachments, setAttachments] = React.useState([]); | ||||
| const [wait, setWait] = React.useState(false); | |||||
| const [waitImport, setWaitImport] = React.useState(false); | |||||
| const [waitDownload, setWaitDownload] = React.useState(false); | |||||
| const [isWarningPopUp, setIsWarningPopUp] = React.useState(false); | const [isWarningPopUp, setIsWarningPopUp] = React.useState(false); | ||||
| const [warningText, setWarningText] = React.useState(""); | const [warningText, setWarningText] = React.useState(""); | ||||
| @@ -54,26 +56,29 @@ const Index = () => { | |||||
| // loadForm(); | // loadForm(); | ||||
| // }, []); | // }, []); | ||||
| React.useLayoutEffect(() => { | |||||
| if (comboData && comboData.length > 0) { | |||||
| setOnReady(true); | |||||
| } | |||||
| }, [comboData]); | |||||
| // React.useLayoutEffect(() => { | |||||
| // if (comboData) { | |||||
| // setOnReady(true); | |||||
| // } | |||||
| // }, [comboData]); | |||||
| React.useEffect(() => { | React.useEffect(() => { | ||||
| // console.log(searchCriteria) | // console.log(searchCriteria) | ||||
| setOnSearchReady(false) | |||||
| loadForm(); | loadForm(); | ||||
| }, [searchCriteria]); | }, [searchCriteria]); | ||||
| function loadForm() { | function loadForm() { | ||||
| HttpUtils.get({ | HttpUtils.get({ | ||||
| url: UrlUtils.GET_HOLIDAY, | url: UrlUtils.GET_HOLIDAY, | ||||
| params: searchCriteria, | params: searchCriteria, | ||||
| onSuccess: (responseData) => { | onSuccess: (responseData) => { | ||||
| console.log(comboData) | |||||
| // console.log(comboData) | |||||
| setRecord(responseData); | setRecord(responseData); | ||||
| if (comboData.length == 0) { | if (comboData.length == 0) { | ||||
| loadCombo(); | loadCombo(); | ||||
| }else{ | |||||
| setOnSearchReady(true) | |||||
| } | } | ||||
| } | } | ||||
| }); | }); | ||||
| @@ -85,6 +90,8 @@ const Index = () => { | |||||
| onSuccess: (responseData) => { | onSuccess: (responseData) => { | ||||
| let combo = responseData; | let combo = responseData; | ||||
| setComboData(combo); | setComboData(combo); | ||||
| setOnReady(true); | |||||
| setOnSearchReady(true) | |||||
| } | } | ||||
| }); | }); | ||||
| } | } | ||||
| @@ -117,8 +124,19 @@ const Index = () => { | |||||
| } | } | ||||
| } | } | ||||
| const doExport=()=>{ | |||||
| setWaitDownload(true) | |||||
| HttpUtils.fileDownload({ | |||||
| url: UrlUtils.GET_HOLIDAY_TEMPLATE, | |||||
| onResponse: () => { | |||||
| setTimeout(()=> setWaitDownload(false), 500) | |||||
| } | |||||
| }); | |||||
| } | |||||
| const importHoliday = () => { | const importHoliday = () => { | ||||
| setWait(true); | |||||
| setWaitImport(true); | |||||
| setOnSearchReady(false); | |||||
| if (!attachments || attachments.length <= 0) { | if (!attachments || attachments.length <= 0) { | ||||
| setWarningText("Please upload file."); | setWarningText("Please upload file."); | ||||
| setSaving(false); | setSaving(false); | ||||
| @@ -129,7 +147,7 @@ const Index = () => { | |||||
| files: attachments, | files: attachments, | ||||
| onSuccess: () => { | onSuccess: () => { | ||||
| notifySaveSuccess() | notifySaveSuccess() | ||||
| setWait(false); | |||||
| setWaitImport(false); | |||||
| setAttachments([]); | setAttachments([]); | ||||
| loadForm(); | loadForm(); | ||||
| } | } | ||||
| @@ -153,8 +171,23 @@ const Index = () => { | |||||
| </Stack> | </Stack> | ||||
| </div> | </div> | ||||
| </Grid> | </Grid> | ||||
| <Grid item xs={12} md={12} lg={12} width="100%"> | |||||
| <Stack direction="row" justifyContent="flex-start" alignItems="center" sx={{ml:2,mt:1}} > | |||||
| <Grid item xs={12} md={12} lg={6} width="100%"> | |||||
| <Stack direction="row" justifyContent="flex-start" alignItems="center" spacing={2} sx={{ml:2,mt:1}} > | |||||
| <ThemeProvider theme={PNSPS_LONG_BUTTON_THEME}> | |||||
| <label htmlFor="downloadFileBtn"> | |||||
| <Button | |||||
| component="span" | |||||
| variant="contained" | |||||
| size="large" | |||||
| disabled={waitDownload} | |||||
| onClick={doExport} | |||||
| > | |||||
| <Typography variant="h5">Export</Typography> | |||||
| </Button> | |||||
| </label> | |||||
| </ThemeProvider> | |||||
| <ThemeProvider theme={PNSPS_LONG_BUTTON_THEME}> | <ThemeProvider theme={PNSPS_LONG_BUTTON_THEME}> | ||||
| <input | <input | ||||
| id="uploadFileBtn" | id="uploadFileBtn" | ||||
| @@ -162,7 +195,7 @@ const Index = () => { | |||||
| type="file" | type="file" | ||||
| accept=".xlsx" | accept=".xlsx" | ||||
| style={{ display: 'none' }} | style={{ display: 'none' }} | ||||
| disabled={wait} | |||||
| disabled={waitImport} | |||||
| onChange={(event) => { | onChange={(event) => { | ||||
| readFile(event) | readFile(event) | ||||
| }} | }} | ||||
| @@ -172,14 +205,16 @@ const Index = () => { | |||||
| component="span" | component="span" | ||||
| variant="contained" | variant="contained" | ||||
| size="large" | size="large" | ||||
| disabled={wait} | |||||
| disabled={waitImport} | |||||
| > | > | ||||
| <Typography variant="h5">Upload Files</Typography> | <Typography variant="h5">Upload Files</Typography> | ||||
| </Button> | </Button> | ||||
| </label> | </label> | ||||
| </ThemeProvider> | </ThemeProvider> | ||||
| </Stack> | </Stack> | ||||
| </Grid> | </Grid> | ||||
| {/*row 1*/} | {/*row 1*/} | ||||
| <Grid item xs={12} md={12} lg={12} width="100%"> | <Grid item xs={12} md={12} lg={12} width="100%"> | ||||
| <SearchForm | <SearchForm | ||||
| @@ -190,16 +225,19 @@ const Index = () => { | |||||
| /> | /> | ||||
| </Grid> | </Grid> | ||||
| {/*row 2*/} | {/*row 2*/} | ||||
| <Grid item xs={12} md={12} lg={12} width="100%"> | |||||
| <MainCard elevation={0} | |||||
| border={false} | |||||
| content={false} | |||||
| > | |||||
| <HolidayTable | |||||
| recordList={record} | |||||
| /> | |||||
| </MainCard> | |||||
| </Grid> | |||||
| {!onSearchReady? | |||||
| <LoadingComponent/>: | |||||
| <Grid item xs={12} md={12} lg={12} width="100%"> | |||||
| <MainCard elevation={0} | |||||
| border={false} | |||||
| content={false} | |||||
| > | |||||
| <HolidayTable | |||||
| recordList={record} | |||||
| /> | |||||
| </MainCard> | |||||
| </Grid> | |||||
| } | |||||
| <div> | <div> | ||||
| <Dialog | <Dialog | ||||
| open={isWarningPopUp} | open={isWarningPopUp} | ||||
| @@ -78,7 +78,7 @@ const SearchPublicNoticeForm = ({ applySearch, orgComboData, searchCriteria, iss | |||||
| function getIssueLabel(data) { | function getIssueLabel(data) { | ||||
| if (data == {}) return ""; | if (data == {}) return ""; | ||||
| return data.year | |||||
| return data.issueYear | |||||
| + " Vol. " + FormatUtils.zeroPad(data.volume, 3) | + " Vol. " + FormatUtils.zeroPad(data.volume, 3) | ||||
| + ", No. " + FormatUtils.zeroPad(data.issueNo, 2) | + ", No. " + FormatUtils.zeroPad(data.issueNo, 2) | ||||
| + ", " + DateUtils.dateFormat(data.issueDate, "D MMM YYYY (ddd)"); | + ", " + DateUtils.dateFormat(data.issueDate, "D MMM YYYY (ddd)"); | ||||
| @@ -85,7 +85,7 @@ const SearchPublicNoticeForm = ({ applySearch, searchCriteria, issueComboData | |||||
| function getIssueLabel(data) { | function getIssueLabel(data) { | ||||
| if (data == {}) return ""; | if (data == {}) return ""; | ||||
| return data.year | |||||
| return data.issueYear | |||||
| + " Vol. " + FormatUtils.zeroPad(data.volume, 3) | + " Vol. " + FormatUtils.zeroPad(data.volume, 3) | ||||
| + ", No. " + FormatUtils.zeroPad(data.issueNo, 2) | + ", No. " + FormatUtils.zeroPad(data.issueNo, 2) | ||||
| + ", " + DateUtils.dateFormat(data.issueDate, "D MMM YYYY (ddd)"); | + ", " + DateUtils.dateFormat(data.issueDate, "D MMM YYYY (ddd)"); | ||||
| @@ -53,7 +53,7 @@ const ApplyForm = () => { | |||||
| }; | }; | ||||
| function getIssueLabel(data) { | function getIssueLabel(data) { | ||||
| return data.year | |||||
| return data.issueYear | |||||
| + " Vol. " + FormatUtils.zeroPad(data.volume, 3) | + " Vol. " + FormatUtils.zeroPad(data.volume, 3) | ||||
| + ", No. " + FormatUtils.zeroPad(data.issueNo, 2) | + ", No. " + FormatUtils.zeroPad(data.issueNo, 2) | ||||
| + ", " + DateUtils.dateFormat(data.issueDate, "D MMM YYYY (ddd)"); | + ", " + DateUtils.dateFormat(data.issueDate, "D MMM YYYY (ddd)"); | ||||
| @@ -77,7 +77,7 @@ const SearchPublicNoticeForm = ({ applySearch, orgComboData, searchCriteria, iss | |||||
| function getIssueLabel(data) { | function getIssueLabel(data) { | ||||
| if (data == {}) return ""; | if (data == {}) return ""; | ||||
| return data.year | |||||
| return data.issueYear | |||||
| + " Vol. " + FormatUtils.zeroPad(data.volume, 3) | + " Vol. " + FormatUtils.zeroPad(data.volume, 3) | ||||
| + ", No. " + FormatUtils.zeroPad(data.issueNo, 2) | + ", No. " + FormatUtils.zeroPad(data.issueNo, 2) | ||||
| + ", " + DateUtils.dateFormat(data.issueDate, "D MMM YYYY (ddd)"); | + ", " + DateUtils.dateFormat(data.issueDate, "D MMM YYYY (ddd)"); | ||||
| @@ -22,6 +22,10 @@ const UserMaintainPage = Loadable(lazy(() => import('pages/User/GLDUserProfile') | |||||
| const SystemSetting = Loadable(lazy(() => import('pages/Setting/SystemSetting'))); | const SystemSetting = Loadable(lazy(() => import('pages/Setting/SystemSetting'))); | ||||
| const AnnouncementDetails = Loadable(lazy(() => import('pages/Announcement/Details'))); | const AnnouncementDetails = Loadable(lazy(() => import('pages/Announcement/Details'))); | ||||
| const AnnouncementSearch = Loadable(lazy(() => import('pages/Announcement/Search'))); | const AnnouncementSearch = Loadable(lazy(() => import('pages/Announcement/Search'))); | ||||
| const EmailTemplatePage = Loadable(lazy(() => import('pages/EmailTemplate/Search_GLD'))); | |||||
| const EmailTemplateDetailPage = Loadable(lazy(() => import('pages/EmailTemplate/Detail_GLD'))); | |||||
| const HolidayPage = Loadable(lazy(() => import('pages/Holiday'))); | |||||
| const GazetteIssuePage = Loadable(lazy(() => import('pages/GazetteIssue/index'))); | |||||
| // ==============================|| MAIN ROUTING ||============================== // | // ==============================|| MAIN ROUTING ||============================== // | ||||
| @@ -100,6 +104,22 @@ const GLDUserRoutes = { | |||||
| path: '/setting/announcement/details/:id', | path: '/setting/announcement/details/:id', | ||||
| element: <AnnouncementDetails /> | element: <AnnouncementDetails /> | ||||
| }, | }, | ||||
| { | |||||
| path: '/setting/emailTemplate', | |||||
| element: <EmailTemplatePage/> | |||||
| }, | |||||
| { | |||||
| path: '/setting/emailTemplate/:id', | |||||
| element: <EmailTemplateDetailPage/> | |||||
| }, | |||||
| { | |||||
| path: '/setting/holiday', | |||||
| element: <HolidayPage/> | |||||
| }, | |||||
| { | |||||
| path: '/setting/gazetteissuepage', | |||||
| element: <GazetteIssuePage/> | |||||
| }, | |||||
| ] | ] | ||||
| }, | }, | ||||
| ] | ] | ||||
| @@ -20,9 +20,6 @@ const UserGroupDetailPage = Loadable(lazy(() => import('pages/pnspsUserGroupDeta | |||||
| const OrganizationSearchPage = Loadable(lazy(() => import('pages/Organization/SearchPage'))); | const OrganizationSearchPage = Loadable(lazy(() => import('pages/Organization/SearchPage'))); | ||||
| const OrganizationDetailPage = Loadable(lazy(() => import('pages/Organization/DetailPage'))); | const OrganizationDetailPage = Loadable(lazy(() => import('pages/Organization/DetailPage'))); | ||||
| const OrganizationDetailPage_fromUser = Loadable(lazy(() => import('pages/Organization/DetailPage_FromUser'))); | const OrganizationDetailPage_fromUser = Loadable(lazy(() => import('pages/Organization/DetailPage_FromUser'))); | ||||
| const EmailTemplatePage = Loadable(lazy(() => import('pages/EmailTemplate/Search_GLD'))); | |||||
| const EmailTemplateDetailPage = Loadable(lazy(() => import('pages/EmailTemplate/Detail_GLD'))); | |||||
| const HolidayPage = Loadable(lazy(() => import('pages/Holiday/Search_GLD'))); | |||||
| // ==============================|| AUTH ROUTING ||============================== // | // ==============================|| AUTH ROUTING ||============================== // | ||||
| @@ -83,18 +80,7 @@ const SettingRoutes = { | |||||
| path: 'passwordpolicy', | path: 'passwordpolicy', | ||||
| element: <PasswordPolicyPage /> | element: <PasswordPolicyPage /> | ||||
| }, | }, | ||||
| { | |||||
| path: 'emailTemplate', | |||||
| element: <EmailTemplatePage/> | |||||
| }, | |||||
| { | |||||
| path: '/emailTemplate/:id', | |||||
| element: <EmailTemplateDetailPage/> | |||||
| }, | |||||
| { | |||||
| path: 'holiday', | |||||
| element: <HolidayPage/> | |||||
| }, | |||||
| ] | ] | ||||
| }; | }; | ||||
| @@ -111,7 +111,10 @@ export const SET_PUBLIC_NOTICE_STATUS_REVIEWED = apiPath+'/application/applicati | |||||
| export const SET_PUBLIC_NOTICE_STATUS_PUBLISH = apiPath+'/application/application-detail-status-publish'; | export const SET_PUBLIC_NOTICE_STATUS_PUBLISH = apiPath+'/application/application-detail-status-publish'; | ||||
| export const UPDATE_PUBLIC_NOTICE_APPLY_DETAIL = apiPath+'/application/save'; | export const UPDATE_PUBLIC_NOTICE_APPLY_DETAIL = apiPath+'/application/save'; | ||||
| //gazette | |||||
| export const GET_ISSUE_COMBO = apiPath+'/gazette-issue/combo'; | export const GET_ISSUE_COMBO = apiPath+'/gazette-issue/combo'; | ||||
| export const GET_ISSUE_LIST = apiPath+'/gazette-issue/export'; | |||||
| export const POST_ISSUE_FILE = apiPath+'/gazette-issue/import'; | |||||
| export const CHECK_CREATE_PROOF = apiPath+'/proof/check-create';//GET | export const CHECK_CREATE_PROOF = apiPath+'/proof/check-create';//GET | ||||
| export const LIST_PROOF = apiPath+'/proof/list';//GET | export const LIST_PROOF = apiPath+'/proof/list';//GET | ||||
| @@ -172,4 +175,5 @@ export const GEN_GFMIS_XML = apiPath+'/gfmis'; //GET | |||||
| //Holiday | //Holiday | ||||
| export const GET_HOLIDAY = apiPath+'/holiday/list'; //GET | export const GET_HOLIDAY = apiPath+'/holiday/list'; //GET | ||||
| export const POST_HOLIDAY = apiPath+'/holiday/import'; //POST | export const POST_HOLIDAY = apiPath+'/holiday/import'; //POST | ||||
| export const GET_HOLIDAY_COMBO = apiPath+'/holiday/combo'; //GET | |||||
| export const GET_HOLIDAY_COMBO = apiPath+'/holiday/combo'; //GET | |||||
| export const GET_HOLIDAY_TEMPLATE = apiPath+'/holiday/export'; //GET | |||||