refactor: 디자인 작업 반영

main
minuk926 3 years ago
parent 2fbc85bfa2
commit 012dd9c69c

@ -152,7 +152,6 @@
position: fixed;
right: 0;
bottom: 0;
top: 0;
left: 0;
width: 100%;
height: 100%;
@ -225,11 +224,6 @@
padding-right: 20px;
color: #35a6ff !important;
}
// ,
.MuiGrid-root:nth-child(4){
border:0px solid red;
margin-left: auto;
}
//
.css-lzdpoz-MuiPaper-root{
@ -314,4 +308,9 @@
.fix_address{
border: 1px solid pink;
margin: 0px !important;
}
.marginNone>*{
margin-right:0px !important;
border:0px solid red;
}

@ -122,7 +122,7 @@ const ModalJudgeResult = ({ totJudgeUsers, totJudgeUserData, judgeCars, judgeUse
</Grid>
<Paper sx={{ width: '100%', overflow: 'hidden' }}>
<TableContainer sx={{ maxwidth: 950, maxHeight: 700 }}>
<Table stickyHeader aria-label="sticky table">
<Table stickyHeader aria-label="sticky table" sx={{ top: '-1' }}>
<TableHead>
<TableRow>
{/* <StyledTableCell align="center" style={{ minWidth: 80 }} hidden> */}

@ -165,7 +165,7 @@ const ParkingRegister = () => {
검색
</Button>
</Grid>
<Grid item>
<Grid item sx={{ marginLeft: 'auto' }}>
<Button
disabled={selectionModel.length === 0}
variant="contained"

@ -195,7 +195,15 @@ const ModifyPublicBoardForm = (props) => {
저장
</Button>
</Grid>
<Grid item>
<Grid
item
sx={{
border: '0px solid red',
'& .MuiButton-root': {
backgroundColor: '#f44336'
}
}}
>
<Button disabled={!owner} variant="contained" size="small" startIcon={<Delete />} onClick={onRemove}>
삭제
</Button>

@ -12,6 +12,7 @@ import MainCard from 'ui-component/cards/MainCard';
// project imports
import MuiDataGrid from 'views/cmm/mui-grid/MuiDataGrid';
import CmmModal from '../../cmm/CmmModal';
import CmmModalB from '../../cmm/CmmModalB';
import UserManagerForm from './UserManagerForm';
import { findUsers, removeUser, saveUser } from 'apis/user';
import { getComboCodeList } from 'apis/common';
@ -267,7 +268,7 @@ const UserManager = () => {
setRowsState={setRowsState}
handleCellClick={handleOnCellClick}
/>
<CmmModal isBackdrop title={title} open={open} setOpen={setOpen}>
<CmmModalB isBackdrop title={title} open={open} setOpen={setOpen}>
<UserManagerForm
create={create}
setOpen={setOpen}
@ -276,7 +277,7 @@ const UserManager = () => {
teams={teams ?? []}
rowData={selectedRow}
/>
</CmmModal>
</CmmModalB>
</MainCard>
);
};

@ -56,9 +56,9 @@ const UserManagementForm = (props) => {
return (
<>
<Grid mt={1}>
<Grid container spacing={1} item xs={12}>
<Grid item sm={6}>
<Grid mt={2} mb={1} sx={{ border: '0px solid red' }}>
<Grid container spacing={1} item xs={12} justifyContent="space-around" className="marginNone">
<Grid item sm={5.9}>
<TextField
size="small"
disabled={!create}
@ -69,7 +69,7 @@ const UserManagementForm = (props) => {
fullWidth
/>
</Grid>
<Grid item sm={6}>
<Grid item sm={5.9}>
<TextField
size="small"
required
@ -81,8 +81,8 @@ const UserManagementForm = (props) => {
/>
</Grid>
</Grid>
<Grid container spacing={1} item xs={12} mt={2}>
<Grid item sm={6}>
<Grid container spacing={1} item xs={12} mt={2} justifyContent="space-around" className="marginNone">
<Grid item sm={5.9}>
<FormControl fullWidth>
<InputLabel required>사용자유형</InputLabel>
<Select size="small" defaultValue={accesstype} value={accesstype} onChange={(e) => setAccesstype(e.target.value)}>
@ -95,7 +95,7 @@ const UserManagementForm = (props) => {
</Select>
</FormControl>
</Grid>
<Grid item sm={6}>
<Grid item sm={5.9}>
<FormControl fullWidth>
<InputLabel required>소속팀</InputLabel>
<Select size="small" defaultValue={team} value={team} onChange={(e) => setTeam(e.target.value)}>
@ -109,24 +109,24 @@ const UserManagementForm = (props) => {
</FormControl>
</Grid>
</Grid>
<Grid container spacing={1} item xs={12} mt={2}>
<Grid item sm={6}>
<Grid container spacing={1} item xs={12} mt={2} justifyContent="space-around" className="marginNone">
<Grid item sm={5.9}>
<TextField size="small" label="이름" value={name} onChange={(e) => setName(e.target.value)} fullWidth />
</Grid>
<Grid item sm={6}>
<Grid item sm={5.9}>
<TextField size="small" label="연락처" value={mphone} onChange={(e) => setMphone(e.target.value)} fullWidth />
</Grid>
</Grid>
<Grid container spacing={1} item xs={12} mt={2}>
<Grid item sm={6}>
<Grid container spacing={1} item xs={12} mt={2} justifyContent="space-around" marginLeft="-8px !important" className="marginNone">
<Grid item sm={5.9}>
<TextField size="small" label="이메일" type="email" value={email} onChange={(e) => setEmail(e.target.value)} fullWidth />
</Grid>
<Grid item sm={6}>
<Grid item sm={5.9}>
<TextField size="small" disabled label="사용여부" value={rowData.isenable === '0' ? '비활성' : '활성'} fullWidth />
</Grid>
</Grid>
</Grid>
<Grid container spacing={1} item xs={12} mt={1}>
<Grid container spacing={1} item xs={12} mt={3}>
<Grid item xs={12}>
<Divider />
</Grid>
@ -143,7 +143,14 @@ const UserManagementForm = (props) => {
</Button>
</Grid>
{!create && (
<Grid item>
<Grid
item
sx={{
'& .MuiButton-root': {
backgroundColor: '#f44336'
}
}}
>
<Button variant="contained" size="small" startIcon={<Delete />} onClick={onRemove}>
삭제
</Button>

@ -0,0 +1,59 @@
import PropTypes from 'prop-types';
import Modal from '@mui/material/Modal';
import { IconButton } from '@mui/material';
import CloseOutlined from '@mui/icons-material/CloseOutlined';
import MainCard from 'ui-component/cards/MainCard';
const style = {
position: 'relative',
top: '50%',
left: '50%',
transform: 'translate(-50%, -50%)',
width: 650,
minHeight: 530,
bgcolor: 'background.paper',
border: '2px solid #000',
boxShadow: 24,
p: 3
};
// eslint-disable-next-line camelcase
const CmmModalB = ({ isBackdrop = false, open, setOpen, title, children, callback = () => {} }) => {
const handleClose = () => {
if (callback) callback();
setOpen(false);
};
return (
<div className="modalGroup">
{/* <Button onClick={handleOpen}>Grid Modal(List)</Button> */}
<Modal hideBackdrop={isBackdrop} open={open} aria-labelledby="modal-modal-title" aria-describedby="modal-modal-description">
<MainCard
sx={style}
title={title}
content
secondary={
<IconButton size="small" variant="rounded" onClick={handleClose}>
<CloseOutlined fontSize="small" />
</IconButton>
}
>
{children}
</MainCard>
</Modal>
</div>
);
};
CmmModalB.propTypes = {
isBackdrop: PropTypes.bool,
open: PropTypes.bool,
title: PropTypes.string,
children: PropTypes.node,
setOpen: PropTypes.func,
callback: PropTypes.func
};
// eslint-disable-next-line camelcase
export default CmmModalB;
Loading…
Cancel
Save