Commit 81ed822d by zhaochengxiang

word导入

parent dc2c19c6
......@@ -40,6 +40,10 @@ const EditModel = (props) => {
const newModelerData = {...modelerData, ...row};
if (newModelerData.easyDataModelerModelingTemplate==='' || newModelerData.easyDataModelerModelingTemplate==={}) {
newModelerData.easyDataModelerModelingTemplate = null;
}
setConfirmLoading(true);
dispatchLatest({
type: 'datamodel.saveDataModel',
......
......@@ -25,7 +25,7 @@ const ImportModal = (props) => {
payload: { fileList: excelFiles },
callback: data => {
setConfirmLoading(false);
onCancel && onCancel({ hints: data||[] });
onCancel && onCancel(data||[]);
},
error: () => {
setConfirmLoading(false);
......
......@@ -48,6 +48,13 @@ const ImportWordModal = (props) => {
callback: data => {
setConfirmLoading(false);
reset();
if (onCancel) {
if (reference==='stock') {
onCancel(true);
} else {
onCancel(true, data?.firstId, data?.result);
}
}
onCancel && onCancel(true);
},
error: () => {
......
......@@ -344,9 +344,20 @@ class Model extends React.Component {
});
}
onImportWordModalCancel = (refresh = false) => {
onImportWordModalCancel = (refresh = false, result = '', id = '') => {
const { catalogId } = this.state;
this.setState({ importWordModalVisible: false });
refresh && this.onTableChange();
if ((result||'')!=='') {
showMessage('info', result);
}
if ((id||'')!=='') {
setTimeout(() => {
window.open(`/data-govern/data-model-action?${Action}=add&${CatalogId}=${catalogId}&${ModelerId}=${id}`);
}, 1000);
}
}
onExportDDLModalCancel = () => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment