diff --git a/apps/web-antd/src/views/workflow/components/actions/flow-actions.vue b/apps/web-antd/src/views/workflow/components/actions/flow-actions.vue
new file mode 100644
index 00000000..d9ccf8de
--- /dev/null
+++ b/apps/web-antd/src/views/workflow/components/actions/flow-actions.vue
@@ -0,0 +1,420 @@
+
+
+
+
+
+
+
+ 撤销申请
+
+
+ 重新编辑
+
+
+ 删除
+
+
+
+
+ 通过
+
+
+ 终止
+
+
+ 驳回
+
+
+
+
+
+
+ 其他
+
+
+
+
+
+
+
+
+
+
+ 流程干预
+ updateAssigneeModalApi.open()">
+ 修改办理人
+
+
+
+
+
+
+
diff --git a/apps/web-antd/src/views/workflow/components/actions/index.ts b/apps/web-antd/src/views/workflow/components/actions/index.ts
new file mode 100644
index 00000000..3daaedf1
--- /dev/null
+++ b/apps/web-antd/src/views/workflow/components/actions/index.ts
@@ -0,0 +1 @@
+export { default as FlowActions } from './flow-actions.vue';
diff --git a/apps/web-antd/src/views/workflow/components/approval-details.vue b/apps/web-antd/src/views/workflow/components/approval-details.vue
index 1673e9c7..e6c6587f 100644
--- a/apps/web-antd/src/views/workflow/components/approval-details.vue
+++ b/apps/web-antd/src/views/workflow/components/approval-details.vue
@@ -20,8 +20,6 @@ defineOptions({
defineProps<{
currentFlowInfo: FlowInfoResponse;
- iframeHeight: number;
- iframeLoaded: boolean;
task: TaskInfo;
}>();
diff --git a/apps/web-antd/src/views/workflow/components/approval-panel.vue b/apps/web-antd/src/views/workflow/components/approval-panel.vue
index 4069c7bb..32b2d91c 100644
--- a/apps/web-antd/src/views/workflow/components/approval-panel.vue
+++ b/apps/web-antd/src/views/workflow/components/approval-panel.vue
@@ -1,87 +1,52 @@
-
+
diff --git a/apps/web-antd/src/views/workflow/components/hook.ts b/apps/web-antd/src/views/workflow/components/hook.ts
index d08e6dbd..7a6cf1d5 100644
--- a/apps/web-antd/src/views/workflow/components/hook.ts
+++ b/apps/web-antd/src/views/workflow/components/hook.ts
@@ -10,20 +10,26 @@ export function useWarmflowIframe() {
const iframeRef = useTemplateRef('iframeRef');
const { isDark } = usePreferences();
+ async function iframeLoadEvent() {
+ /**
+ * TODO: 这里可以优化 因为拿不到内部vue的mount状态
+ */
+ await new Promise((resolve) => setTimeout(resolve, 500));
+ const theme = isDark.value ? 'theme-dark' : 'theme-light';
+ iframeRef.value?.contentWindow?.postMessage({ type: theme });
+ }
+
onMounted(() => {
/**
* load只是iframe加载完 而非vue加载完
*/
- iframeRef.value?.addEventListener('load', async () => {
- /**
- * TODO: 这里可以优化 因为拿不到内部vue的mount状态
- */
- await new Promise((resolve) => setTimeout(resolve, 500));
- const theme = isDark.value ? 'theme-dark' : 'theme-light';
- iframeRef.value?.contentWindow?.postMessage({ type: theme });
- });
+ iframeRef.value?.addEventListener('load', iframeLoadEvent);
});
+ // onBeforeUnmount(() => {
+ // iframeRef.value?.removeEventListener('load', iframeLoadEvent);
+ // });
+
// 监听主题切换 通知iframe切换
watch(isDark, (dark) => {
if (!iframeRef.value) {
diff --git a/apps/web-antd/src/views/workflow/components/type.d.ts b/apps/web-antd/src/views/workflow/components/type.d.ts
new file mode 100644
index 00000000..b7cbaa4a
--- /dev/null
+++ b/apps/web-antd/src/views/workflow/components/type.d.ts
@@ -0,0 +1,8 @@
+export {};
+/**
+ * myself 我发起的
+ * readonly 只读 只用于查看
+ * approve 审批(我的待办)
+ * admin 流程监控 - 待办任务使用
+ */
+export type ApprovalType = 'admin' | 'approve' | 'myself' | 'readonly';