Skip to content

Commit 99790ba

Browse files
committed
【功能评审】Bpm:复制流程
1 parent 6b1c0e7 commit 99790ba

File tree

5 files changed

+12
-15
lines changed

5 files changed

+12
-15
lines changed

src/components/SimpleProcessDesignerV2/src/SimpleProcessModel.vue

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ import { SimpleFlowNode, NodeType, NODE_DEFAULT_TEXT } from './consts'
5151
import { useWatchNode } from './node'
5252
import { ZoomOut, ZoomIn, ScaleToOriginal } from '@element-plus/icons-vue'
5353
import { isString } from '@/utils/is'
54-
import download from "@/utils/download";
54+
import download from '@/utils/download'
5555
5656
defineOptions({
5757
name: 'SimpleProcessModel'
@@ -173,7 +173,6 @@ defineExpose({
173173
})
174174
175175
/** 导出 JSON */
176-
// TODO @zws:增加一个 download 里面搞个 json 更好
177176
const exportJson = () => {
178177
download.json(new Blob([JSON.stringify(processNodeTree.value)]), 'model.json')
179178
}

src/layout/components/TagsView/src/TagsView.vue

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ import { useScrollTo } from '@/hooks/event/useScrollTo'
1515
import { useTagsView } from '@/hooks/web/useTagsView'
1616
import { cloneDeep } from 'lodash-es'
1717
18-
1918
defineOptions({ name: 'TagsView' })
2019
2120
const { getPrefixCls } = useDesign()

src/store/modules/tagsView.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ export const useTagsViewStore = defineStore('tagsView', {
156156
}
157157
}
158158
},
159-
// 设置当前选中的tag
159+
// 设置当前选中的 tag
160160
setSelectedTag(tag: RouteLocationNormalizedLoaded) {
161161
this.selectedTag = tag
162162
},

src/views/bpm/model/CategoryDraggableModel.vue

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ import { checkPermi } from '@/utils/permission'
262262
import { useUserStoreWithOut } from '@/store/modules/user'
263263
import { useAppStore } from '@/store/modules/app'
264264
import { cloneDeep } from 'lodash-es'
265-
import {useTagsView} from "@/hooks/web/useTagsView";
265+
import { useTagsView } from '@/hooks/web/useTagsView'
266266
267267
defineOptions({ name: 'BpmModel' })
268268
@@ -499,21 +499,21 @@ const handleDeleteCategory = async () => {
499499
} catch {}
500500
}
501501
502-
const tagsView = useTagsView();
503502
/** 添加流程模型弹窗 */
503+
const tagsView = useTagsView()
504504
const modelFormRef = ref()
505-
const openModelForm = (type: string, id?: number) => {
505+
const openModelForm = async (type: string, id?: number) => {
506506
if (type === 'create') {
507-
push({ name: 'BpmModelCreate' })
507+
await push({ name: 'BpmModelCreate' })
508508
} else {
509-
push({
509+
await push({
510510
name: 'BpmModelUpdate',
511511
params: { id, type }
512-
}).then((_) => {
513-
if (type === 'copy') {
514-
tagsView.setTitle('复制流程')
515-
}
516512
})
513+
// 设置标题
514+
if (type === 'copy') {
515+
tagsView.setTitle('复制流程')
516+
}
517517
}
518518
}
519519

src/views/bpm/model/editor/index.vue

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,7 @@ const controlForm = ref({
7171
const model = ref<ModelApi.ModelVO>() // 流程模型的信息
7272
7373
/** 初始化 modeler */
74-
// TODO @zws:需要初始化,不然首次创建后,无法发布!相当于说,key、name 要去赋值下
75-
const initModeler = async (item) => {
74+
const initModeler = async (item: any) => {
7675
//先初始化模型数据
7776
model.value = modelData.value
7877
modeler.value = item

0 commit comments

Comments
 (0)