|
|
@ -8,12 +8,14 @@ import { Grid, TextField, MenuItem, Select, FormControl, InputLabel, InputAdornm
|
|
|
|
import Button from '@mui/material/Button';
|
|
|
|
import Button from '@mui/material/Button';
|
|
|
|
import { IconSearch } from '@tabler/icons';
|
|
|
|
import { IconSearch } from '@tabler/icons';
|
|
|
|
|
|
|
|
|
|
|
|
import FileInputForms from 'views/cmm/FileInputForms';
|
|
|
|
import FileInputForms from 'views/cmm/file-ctl/FileInputForms';
|
|
|
|
|
|
|
|
import DaumPost from '../../cmm/DaumPost';
|
|
|
|
|
|
|
|
|
|
|
|
// const toDate = new Date();
|
|
|
|
// const toDate = new Date();
|
|
|
|
|
|
|
|
|
|
|
|
const JudgeDataModifyForm = ({ rowData, contDocs, ingbs, setOpen, handleModalSave }) => {
|
|
|
|
const JudgeDataModifyForm = ({ rowData, contDocs, ingbs, setOpen, handleModalSave }) => {
|
|
|
|
const alert = useAlert();
|
|
|
|
const alert = useAlert();
|
|
|
|
|
|
|
|
const [isPostOpen, setIsPostOpen] = useState(false);
|
|
|
|
|
|
|
|
|
|
|
|
const [scCarnum, setScCarnum] = useState(rowData.scCarnum);
|
|
|
|
const [scCarnum, setScCarnum] = useState(rowData.scCarnum);
|
|
|
|
const [scName, setScName] = useState(rowData.scName);
|
|
|
|
const [scName, setScName] = useState(rowData.scName);
|
|
|
@ -59,8 +61,8 @@ const JudgeDataModifyForm = ({ rowData, contDocs, ingbs, setOpen, handleModalSav
|
|
|
|
Object.values(contads).forEach((v) => {
|
|
|
|
Object.values(contads).forEach((v) => {
|
|
|
|
formData.append('contadFiles', v);
|
|
|
|
formData.append('contadFiles', v);
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
console.log(picads, frecads, contads);
|
|
|
|
handleModalSave(formData);
|
|
|
|
// handleModalSave(formData);
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
const handleChangeFile = (e) => {
|
|
|
|
const handleChangeFile = (e) => {
|
|
|
@ -88,10 +90,37 @@ const JudgeDataModifyForm = ({ rowData, contDocs, ingbs, setOpen, handleModalSav
|
|
|
|
}
|
|
|
|
}
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const onCancel = () => {
|
|
|
|
|
|
|
|
setOpen(false);
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const openPostCode = (e) => {
|
|
|
|
|
|
|
|
e.preventDefault();
|
|
|
|
|
|
|
|
setIsPostOpen(true);
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const handlePostAddr = (data) => {
|
|
|
|
|
|
|
|
if (data) {
|
|
|
|
|
|
|
|
setZipcode1(data.zipCode);
|
|
|
|
|
|
|
|
setScJuso(data.addr);
|
|
|
|
|
|
|
|
setScBunji(data.dtlAddr);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
setIsPostOpen(false);
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
return (
|
|
|
|
return (
|
|
|
|
<>
|
|
|
|
<>
|
|
|
|
<Grid mt={2}>
|
|
|
|
<Grid mt={2}>
|
|
|
|
<Grid container spacing={0.5} item xs={12} mb={1.5}>
|
|
|
|
<Grid container spacing={0.5} item xs={12} mb={1.5}>
|
|
|
|
|
|
|
|
<Grid item sm={3}>
|
|
|
|
|
|
|
|
<TextField disabled size="small" required label="접수번호" fullWidth value={rowData.scSeq} />
|
|
|
|
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
<Grid item sm={3}>
|
|
|
|
|
|
|
|
<TextField disabled size="small" required label="전송상태" fullWidth value={rowData.scTransferNm} />
|
|
|
|
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
<Grid item sm={3}>
|
|
|
|
|
|
|
|
<TextField disabled size="small" required label="자료상태" fullWidth value={rowData.scStateNm} />
|
|
|
|
|
|
|
|
</Grid>
|
|
|
|
<Grid item sm={3}>
|
|
|
|
<Grid item sm={3}>
|
|
|
|
<TextField
|
|
|
|
<TextField
|
|
|
|
required
|
|
|
|
required
|
|
|
@ -103,6 +132,8 @@ const JudgeDataModifyForm = ({ rowData, contDocs, ingbs, setOpen, handleModalSav
|
|
|
|
autoFocus
|
|
|
|
autoFocus
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
</Grid>
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
<Grid container spacing={0.5} item xs={12} mb={1.5}>
|
|
|
|
<Grid item sm={3}>
|
|
|
|
<Grid item sm={3}>
|
|
|
|
<TextField required label="성명" size="small" fullWidth value={scName} onChange={(e) => setScName(e?.target?.value)} />
|
|
|
|
<TextField required label="성명" size="small" fullWidth value={scName} onChange={(e) => setScName(e?.target?.value)} />
|
|
|
|
</Grid>
|
|
|
|
</Grid>
|
|
|
@ -127,20 +158,6 @@ const JudgeDataModifyForm = ({ rowData, contDocs, ingbs, setOpen, handleModalSav
|
|
|
|
</Select>
|
|
|
|
</Select>
|
|
|
|
</FormControl>
|
|
|
|
</FormControl>
|
|
|
|
</Grid>
|
|
|
|
</Grid>
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
<Grid container spacing={0.5} item xs={12} mb={1.5}>
|
|
|
|
|
|
|
|
<Grid item sm={3}>
|
|
|
|
|
|
|
|
<NumberFormat
|
|
|
|
|
|
|
|
size="small"
|
|
|
|
|
|
|
|
customInput={TextField}
|
|
|
|
|
|
|
|
required
|
|
|
|
|
|
|
|
label="접수일자"
|
|
|
|
|
|
|
|
format="####-##-##"
|
|
|
|
|
|
|
|
fullWidth
|
|
|
|
|
|
|
|
value={scCdate}
|
|
|
|
|
|
|
|
onChange={(e) => setScCdate(e?.target?.value)}
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
<Grid item sm={3}>
|
|
|
|
<Grid item sm={3}>
|
|
|
|
<FormControl fullWidth>
|
|
|
|
<FormControl fullWidth>
|
|
|
|
<InputLabel required>접수방법</InputLabel>
|
|
|
|
<InputLabel required>접수방법</InputLabel>
|
|
|
@ -154,7 +171,21 @@ const JudgeDataModifyForm = ({ rowData, contDocs, ingbs, setOpen, handleModalSav
|
|
|
|
</Select>
|
|
|
|
</Select>
|
|
|
|
</FormControl>
|
|
|
|
</FormControl>
|
|
|
|
</Grid>
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
<Grid container spacing={0.5} item xs={12} mb={2}>
|
|
|
|
<Grid item sm={3}>
|
|
|
|
<Grid item sm={3}>
|
|
|
|
|
|
|
|
<NumberFormat
|
|
|
|
|
|
|
|
size="small"
|
|
|
|
|
|
|
|
customInput={TextField}
|
|
|
|
|
|
|
|
required
|
|
|
|
|
|
|
|
label="접수일자"
|
|
|
|
|
|
|
|
format="####-##-##"
|
|
|
|
|
|
|
|
fullWidth
|
|
|
|
|
|
|
|
value={scCdate}
|
|
|
|
|
|
|
|
onChange={(e) => setScCdate(e?.target?.value)}
|
|
|
|
|
|
|
|
/>
|
|
|
|
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
<Grid item sm={2}>
|
|
|
|
<NumberFormat
|
|
|
|
<NumberFormat
|
|
|
|
size="small"
|
|
|
|
size="small"
|
|
|
|
customInput={TextField}
|
|
|
|
customInput={TextField}
|
|
|
@ -166,7 +197,7 @@ const JudgeDataModifyForm = ({ rowData, contDocs, ingbs, setOpen, handleModalSav
|
|
|
|
onChange={(e) => setScWdate(e?.target?.value)}
|
|
|
|
onChange={(e) => setScWdate(e?.target?.value)}
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
</Grid>
|
|
|
|
</Grid>
|
|
|
|
<Grid item sm={3}>
|
|
|
|
<Grid item sm={1}>
|
|
|
|
<NumberFormat
|
|
|
|
<NumberFormat
|
|
|
|
size="small"
|
|
|
|
size="small"
|
|
|
|
customInput={TextField}
|
|
|
|
customInput={TextField}
|
|
|
@ -178,8 +209,6 @@ const JudgeDataModifyForm = ({ rowData, contDocs, ingbs, setOpen, handleModalSav
|
|
|
|
onChange={(e) => setScJbtime(e?.target?.value)}
|
|
|
|
onChange={(e) => setScJbtime(e?.target?.value)}
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
</Grid>
|
|
|
|
</Grid>
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
<Grid container spacing={0.5} item xs={12} mb={2}>
|
|
|
|
|
|
|
|
<Grid item sm={6}>
|
|
|
|
<Grid item sm={6}>
|
|
|
|
<TextField
|
|
|
|
<TextField
|
|
|
|
size="small"
|
|
|
|
size="small"
|
|
|
@ -190,12 +219,6 @@ const JudgeDataModifyForm = ({ rowData, contDocs, ingbs, setOpen, handleModalSav
|
|
|
|
onChange={(e) => setScPos(e?.target?.value)}
|
|
|
|
onChange={(e) => setScPos(e?.target?.value)}
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
</Grid>
|
|
|
|
</Grid>
|
|
|
|
<Grid item sm={3}>
|
|
|
|
|
|
|
|
<TextField disabled size="small" required label="전송상태" fullWidth value={rowData.scTransferNm} />
|
|
|
|
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
<Grid item sm={3}>
|
|
|
|
|
|
|
|
<TextField disabled size="small" required label="자료상태" fullWidth value={rowData.scStateNm} />
|
|
|
|
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
</Grid>
|
|
|
|
</Grid>
|
|
|
|
<Grid container spacing={0.5} item xs={12} mb={2}>
|
|
|
|
<Grid container spacing={0.5} item xs={12} mb={2}>
|
|
|
|
<Grid item sm={1.7}>
|
|
|
|
<Grid item sm={1.7}>
|
|
|
@ -206,6 +229,7 @@ const JudgeDataModifyForm = ({ rowData, contDocs, ingbs, setOpen, handleModalSav
|
|
|
|
label="우편번호"
|
|
|
|
label="우편번호"
|
|
|
|
value={zipcode1 ?? ''}
|
|
|
|
value={zipcode1 ?? ''}
|
|
|
|
onChange={(e) => setZipcode1(e?.target?.value)}
|
|
|
|
onChange={(e) => setZipcode1(e?.target?.value)}
|
|
|
|
|
|
|
|
onClick={openPostCode}
|
|
|
|
InputProps={{
|
|
|
|
InputProps={{
|
|
|
|
display: 'none',
|
|
|
|
display: 'none',
|
|
|
|
readOnly: true,
|
|
|
|
readOnly: true,
|
|
|
@ -438,13 +462,18 @@ const JudgeDataModifyForm = ({ rowData, contDocs, ingbs, setOpen, handleModalSav
|
|
|
|
</Grid>
|
|
|
|
</Grid>
|
|
|
|
</Grid>
|
|
|
|
</Grid>
|
|
|
|
<Grid item container spacing={0.5} xs={12} mt={1}>
|
|
|
|
<Grid item container spacing={0.5} xs={12} mt={1}>
|
|
|
|
|
|
|
|
<Grid item>
|
|
|
|
|
|
|
|
<Button variant="contained" color="error" size="small" onClick={onCancel}>
|
|
|
|
|
|
|
|
취소
|
|
|
|
|
|
|
|
</Button>
|
|
|
|
|
|
|
|
</Grid>
|
|
|
|
<Grid item style={{ marginLeft: 'auto' }}>
|
|
|
|
<Grid item style={{ marginLeft: 'auto' }}>
|
|
|
|
{/* <Button variant="contained" color="primary" size="small" startIcon={<IconFileExport />} onClick={onSave}> */}
|
|
|
|
<Button variant="contained" color="primary" size="small" onClick={onSave}>
|
|
|
|
<Button disabled variant="contained" color="primary" size="small" onClick={onSave}>
|
|
|
|
|
|
|
|
저장
|
|
|
|
저장
|
|
|
|
</Button>
|
|
|
|
</Button>
|
|
|
|
</Grid>
|
|
|
|
</Grid>
|
|
|
|
</Grid>
|
|
|
|
</Grid>
|
|
|
|
|
|
|
|
<DaumPost isOpen={isPostOpen} handlePostAddress={handlePostAddr} />
|
|
|
|
</>
|
|
|
|
</>
|
|
|
|
);
|
|
|
|
);
|
|
|
|
};
|
|
|
|
};
|
|
|
|