fix: Grid excel download rename

mpower
minuk926 2 years ago
parent d760c5ebff
commit a18cd21cae

@ -17,7 +17,7 @@ import xitCmm, { ErrorToast, saveAlert } from 'commons/XitCmm';
import CmmModal from 'views/cmm/CmmModal';
import JudgeTargetSaveForm from 'views/biz/admin/judge/JudgeTargetSaveForm';
import NumberFormat from 'react-number-format';
import ExcelDownload from 'views/cmm/file-ctl/ExcelDownload';
import ExcelDownloadGrid from 'views/cmm/file-ctl/ExcelDownloadGrid';
import { findJudgeTargets, saveJudgeTargets } from 'apis/judge';
import PropTypes from 'prop-types';
import getYear from 'date-fns/getYear';
@ -204,7 +204,7 @@ const JudgeRegistReview = ({ scDatagb, menuName }) => {
</Button>
</Grid>
<Grid item>
<ExcelDownload
<ExcelDownloadGrid
fileName={`${menuName} 의견진술 심의목록`}
gridColumns={columns}
excelDatas={rowsState.rows}

@ -17,7 +17,7 @@ import xitCmm, { ErrorToast, saveAlert } from 'commons/XitCmm';
import CmmModal from 'views/cmm/CmmModal';
import SaveParkingTargetForm from './SaveParkingTargetForm';
import NumberFormat from 'react-number-format';
import ExcelDownload from 'views/cmm/file-ctl/ExcelDownload';
import ExcelDownloadGrid from 'views/cmm/file-ctl/ExcelDownloadGrid';
import { findParkingJudgeTargets, saveParkingJudgeTargets } from 'apis/parking';
import getYear from 'date-fns/getYear';
import { useAlert } from 'react-alert';
@ -205,7 +205,7 @@ const ParkingRegister = () => {
</Button>
</Grid>
<Grid item>
<ExcelDownload fileName="심사등록대상" gridColumns={columns} excelDatas={rowsState.rows} isDisabled={totalCount === 0} />
<ExcelDownloadGrid fileName="심사등록대상" gridColumns={columns} excelDatas={rowsState.rows} isDisabled={totalCount === 0} />
</Grid>
</Grid>
</Grid>

@ -5,7 +5,7 @@ import * as Excel from 'exceljs';
import saveAs from 'file-saver';
import { useAlert } from 'react-alert';
const ExcelDownload = ({ fileName, gridColumns, excelDatas, isDisabled = true }) => {
const ExcelDownloadGrid = ({ fileName, gridColumns, excelDatas, isDisabled = true }) => {
const alert = useAlert();
const handleExcelDownload = () => {
@ -101,11 +101,11 @@ const ExcelDownload = ({ fileName, gridColumns, excelDatas, isDisabled = true })
);
};
ExcelDownload.propTypes = {
ExcelDownloadGrid.propTypes = {
fileName: PropTypes.string.isRequired,
gridColumns: PropTypes.array.isRequired,
excelDatas: PropTypes.array.isRequired,
isDisabled: PropTypes.bool.isRequired
};
export default ExcelDownload;
export default ExcelDownloadGrid;

Loading…
Cancel
Save