优化新建模型等待
This commit is contained in:
parent
a49aef600d
commit
55b9e7d72c
@ -269,7 +269,7 @@
|
|||||||
</awsui-form>
|
</awsui-form>
|
||||||
</div>
|
</div>
|
||||||
<span slot="footer" class="dialog-footer">
|
<span slot="footer" class="dialog-footer">
|
||||||
<awsui-button class="button-general-color" type="primary" @click="createSystemSave('systemForm')" :disabled="isDisabled">确定</awsui-button>
|
<awsui-button class="button-general-color" type="primary" @click="createSystemSave('systemForm')" :loading="isLoading">确定</awsui-button>
|
||||||
<awsui-button @click="clearSystemDlg">取消</awsui-button>
|
<awsui-button @click="clearSystemDlg">取消</awsui-button>
|
||||||
</span>
|
</span>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
@ -321,7 +321,7 @@
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
return {
|
return {
|
||||||
isDisabled:false,
|
isLoading:false,
|
||||||
multiple: true,
|
multiple: true,
|
||||||
// 创建人
|
// 创建人
|
||||||
currentUserCheck: true,
|
currentUserCheck: true,
|
||||||
@ -1081,10 +1081,9 @@
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
//
|
//新建模型
|
||||||
createSystemSave(formName) {// 保存新建的文件夹
|
createSystemSave(formName) {// 保存新建的文件夹
|
||||||
const that = this;
|
const that = this;
|
||||||
|
|
||||||
that.$refs[formName].validate((valid) => {
|
that.$refs[formName].validate((valid) => {
|
||||||
if (valid) {
|
if (valid) {
|
||||||
const checkdata = {
|
const checkdata = {
|
||||||
@ -1097,9 +1096,8 @@
|
|||||||
};
|
};
|
||||||
// 查询数据
|
// 查询数据
|
||||||
awsuiAxios.post(checkdata).then(function (ro) {
|
awsuiAxios.post(checkdata).then(function (ro) {
|
||||||
|
|
||||||
if (ro.data.result == 'ok') {
|
if (ro.data.result == 'ok') {
|
||||||
that.isDisabled = true;
|
that.isLoading = true;
|
||||||
const nodeData = that.$refs.tree.getCurrentNode();
|
const nodeData = that.$refs.tree.getCurrentNode();
|
||||||
const parentId = nodeData.id;
|
const parentId = nodeData.id;
|
||||||
const wsId = that.$store.getters.getWsIdFn;
|
const wsId = that.$store.getters.getWsIdFn;
|
||||||
@ -1122,34 +1120,44 @@
|
|||||||
if (ro.result == 'ok') {
|
if (ro.result == 'ok') {
|
||||||
that.ModelsetUpDialog.systemForm.uuid=ro.data.id;
|
that.ModelsetUpDialog.systemForm.uuid=ro.data.id;
|
||||||
that.ModelsetUpDialog.systemForm.parentId=parentId;
|
that.ModelsetUpDialog.systemForm.parentId=parentId;
|
||||||
const data = {
|
if(that.ModelsetUpDialog.systemForm.method == "control.policy"){
|
||||||
url:'jd',
|
const data = {
|
||||||
data:{
|
url:'jd',
|
||||||
cmd: 'com.actionsoft.apps.coe.pal_pl_repository_designer_CreateSystemModelBySelectType',
|
data:{
|
||||||
title: that.ModelsetUpDialog.systemForm.name,
|
cmd: 'com.actionsoft.apps.coe.pal_pl_repository_designer_CreateSystemModelBySelectType',
|
||||||
type: that.ModelsetUpDialog.systemForm.systemType,
|
title: that.ModelsetUpDialog.systemForm.name,
|
||||||
method:that.ModelsetUpDialog.systemForm.method,
|
type: that.ModelsetUpDialog.systemForm.systemType,
|
||||||
uuid:that.ModelsetUpDialog.systemForm.uuid,
|
method:that.ModelsetUpDialog.systemForm.method,
|
||||||
parentId:that.ModelsetUpDialog.systemForm.parentId
|
uuid:that.ModelsetUpDialog.systemForm.uuid,
|
||||||
}
|
parentId:that.ModelsetUpDialog.systemForm.parentId
|
||||||
};
|
}
|
||||||
// 查询数据
|
};
|
||||||
awsuiAxios.post(data).then(function (ro) {
|
// 查询数据
|
||||||
if (ro.result == 'ok') {
|
awsuiAxios.post(data).then(function (ro) {
|
||||||
that.isDisabled = false;
|
if (ro.result == 'ok') {
|
||||||
that.ModelsetUpDialog.dialogVisible = false;
|
that.isLoading = false;
|
||||||
that.openRepositoryList(that.ModelsetUpDialog.systemForm.parentId);
|
that.ModelsetUpDialog.dialogVisible = false;
|
||||||
// 返回id
|
that.openRepositoryList(that.ModelsetUpDialog.systemForm.parentId);
|
||||||
openDesigner(that.$store.getters.getTeamIdFn, that.ModelsetUpDialog.systemForm.uuid, that.$store.state.sessionId);
|
// 返回id
|
||||||
|
openDesigner(that.$store.getters.getTeamIdFn, that.ModelsetUpDialog.systemForm.uuid, that.$store.state.sessionId);
|
||||||
|
//清空数据
|
||||||
|
that.$refs['systemForm'].resetFields();
|
||||||
|
} else {
|
||||||
|
that.$message.error(ro.msg);
|
||||||
|
}
|
||||||
|
}).catch(error=>{
|
||||||
|
console.log(error);
|
||||||
|
})
|
||||||
|
}else{
|
||||||
|
that.isLoading = false;
|
||||||
|
that.ModelsetUpDialog.dialogVisible = false;
|
||||||
|
that.openRepositoryList(that.ModelsetUpDialog.systemForm.parentId);
|
||||||
|
// 返回id
|
||||||
|
openDesigner(that.$store.getters.getTeamIdFn, that.ModelsetUpDialog.systemForm.uuid, that.$store.state.sessionId);
|
||||||
|
//清空数据
|
||||||
|
that.$refs['systemForm'].resetFields();
|
||||||
|
}
|
||||||
|
|
||||||
//清空数据
|
|
||||||
that.$refs['systemForm'].resetFields();
|
|
||||||
} else {
|
|
||||||
that.$message.error(ro.msg);
|
|
||||||
}
|
|
||||||
}).catch(error=>{
|
|
||||||
console.log(error);
|
|
||||||
})
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}).catch(error => {
|
}).catch(error => {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user