chore: 调整为部署json类型

This commit is contained in:
dap 2025-01-16 14:12:27 +08:00
parent 8816086b37
commit b1bc6f632d
2 changed files with 10 additions and 4 deletions

View File

@ -217,7 +217,7 @@ async function handleExportXml(row: any) {
const hideLoading = message.loading($t('pages.common.downloadLoading'), 0);
try {
const blob = await workflowDefinitionExport(row.id);
downloadByData(blob, `${row.flowName}-${Date.now()}.xml`);
downloadByData(blob, `${row.flowName}-${Date.now()}.json`);
} catch (error) {
console.error(error);
} finally {
@ -245,6 +245,12 @@ function handleDeploy() {
deployModalApi.setData({ category: selectedCategory });
deployModalApi.open();
}
async function handleDeploySuccess() {
//
currentStatus.value = 0;
await tableApi.reload();
}
</script>
<template>
@ -353,6 +359,6 @@ function handleDeploy() {
</BasicTable>
</div>
<ProcessDefinitionModal @reload="() => tableApi.reload()" />
<ProcessDefinitionDeployModal @reload="() => tableApi.reload()" />
<ProcessDefinitionDeployModal @reload="handleDeploySuccess" />
</Page>
</template>

View File

@ -62,12 +62,12 @@ function handleCancel() {
:before-upload="() => false"
:max-count="1"
:show-upload-list="true"
accept="text/xml"
accept="text/json"
>
<p class="ant-upload-drag-icon flex items-center justify-center">
<InBoxIcon class="text-primary size-[48px]" />
</p>
<p class="ant-upload-text">点击或者拖拽到此处上传文件</p>
<p class="ant-upload-text">点击或者拖拽到此处上传[json]文件</p>
</UploadDragger>
</BasicModal>
</template>