mirror of
https://github.com/m-xlsea/ruoyi-plus-soybean.git
synced 2025-09-24 07:49:47 +08:00
optimize(projects): 优化代码
This commit is contained in:
@ -25,6 +25,6 @@ const iframeUrl = `${baseURL}/warm-flow-ui/index.html?${stringify(urlParams)}`;
|
|||||||
|
|
||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<iframe :src="iframeUrl" class="h-[600px] w-full" />
|
<iframe :src="iframeUrl" class="h-[450px] w-full" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
@ -281,7 +281,7 @@ watch(visible, initializeData, { immediate: true });
|
|||||||
</NForm>
|
</NForm>
|
||||||
</div>
|
</div>
|
||||||
<div v-else>
|
<div v-else>
|
||||||
<NDescriptions bordered :column="2" label-placement="left">
|
<NDescriptions size="small" bordered :column="2" label-placement="left">
|
||||||
<NDescriptionsItem label="流程类型">
|
<NDescriptionsItem label="流程类型">
|
||||||
{{ flowCodeTypeRecord[modelDetail.flowCode] }}
|
{{ flowCodeTypeRecord[modelDetail.flowCode] }}
|
||||||
</NDescriptionsItem>
|
</NDescriptionsItem>
|
||||||
|
@ -323,10 +323,9 @@ const businessId = ref<CommonType.IdType>();
|
|||||||
async function handlePreview(row: Api.Workflow.Instance) {
|
async function handlePreview(row: Api.Workflow.Instance) {
|
||||||
businessId.value = row.businessId;
|
businessId.value = row.businessId;
|
||||||
const formPath = row.formPath;
|
const formPath = row.formPath;
|
||||||
if (formPath) {
|
if (!formPath) return;
|
||||||
dynamicComponent.value = await loadDynamicComponent(modules, formPath);
|
dynamicComponent.value = await loadDynamicComponent(modules, formPath);
|
||||||
showPreviewDrawer();
|
showPreviewDrawer();
|
||||||
}
|
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
@ -169,7 +169,7 @@ const {
|
|||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div class="flex-center gap-8px">
|
<div class="flex-center gap-1px">
|
||||||
{buttons.map((btn, index) => (index > 0 ? [<NDivider vertical />, btn] : btn))}
|
{buttons.map((btn, index) => (index > 0 ? [<NDivider vertical />, btn] : btn))}
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
@ -222,10 +222,9 @@ async function handleOpen(row: Api.Workflow.Instance, type: 'edit' | 'detail') {
|
|||||||
operateType.value = type;
|
operateType.value = type;
|
||||||
businessId.value = row.businessId;
|
businessId.value = row.businessId;
|
||||||
const formPath = row.formPath;
|
const formPath = row.formPath;
|
||||||
if (formPath) {
|
if (!formPath) return;
|
||||||
dynamicComponent.value = await loadDynamicComponent(modules, formPath);
|
dynamicComponent.value = await loadDynamicComponent(modules, formPath);
|
||||||
showViewDrawer();
|
showViewDrawer();
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
async function handleDelete(row: Api.Workflow.Instance) {
|
async function handleDelete(row: Api.Workflow.Instance) {
|
||||||
|
@ -171,10 +171,9 @@ async function handleView(row: Api.Workflow.Task) {
|
|||||||
businessId.value = row.businessId;
|
businessId.value = row.businessId;
|
||||||
taskId.value = row.id;
|
taskId.value = row.id;
|
||||||
const formPath = row.formPath;
|
const formPath = row.formPath;
|
||||||
if (formPath) {
|
if (!formPath) return;
|
||||||
dynamicComponent.value = await loadDynamicComponent(modules, formPath);
|
dynamicComponent.value = await loadDynamicComponent(modules, formPath);
|
||||||
showViewDrawer();
|
showViewDrawer();
|
||||||
}
|
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
@ -240,6 +239,7 @@ async function handleView(row: Api.Workflow.Task) {
|
|||||||
/>
|
/>
|
||||||
<component
|
<component
|
||||||
:is="dynamicComponent"
|
:is="dynamicComponent"
|
||||||
|
v-if="dynamicComponent"
|
||||||
:visible="viewVisible"
|
:visible="viewVisible"
|
||||||
operate-type="detail"
|
operate-type="detail"
|
||||||
:business-id="businessId"
|
:business-id="businessId"
|
||||||
|
@ -184,10 +184,9 @@ async function handleView(row: Api.Workflow.HisTask) {
|
|||||||
businessId.value = row.businessId;
|
businessId.value = row.businessId;
|
||||||
taskId.value = row.id;
|
taskId.value = row.id;
|
||||||
const formPath = row.formPath;
|
const formPath = row.formPath;
|
||||||
if (formPath) {
|
if (!formPath) return;
|
||||||
dynamicComponent.value = await loadDynamicComponent(modules, formPath);
|
dynamicComponent.value = await loadDynamicComponent(modules, formPath);
|
||||||
showViewDrawer();
|
showViewDrawer();
|
||||||
}
|
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
@ -165,10 +165,9 @@ async function handleApproval(row: Api.Workflow.Task) {
|
|||||||
businessId.value = row.businessId;
|
businessId.value = row.businessId;
|
||||||
taskId.value = row.id;
|
taskId.value = row.id;
|
||||||
const formPath = row.formPath;
|
const formPath = row.formPath;
|
||||||
if (formPath) {
|
if (!formPath) return;
|
||||||
dynamicComponent.value = await loadDynamicComponent(modules, formPath);
|
dynamicComponent.value = await loadDynamicComponent(modules, formPath);
|
||||||
showViewDrawer();
|
showViewDrawer();
|
||||||
}
|
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user