Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
Z
zrch-risk-39
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
Administrator
zrch-risk-39
Commits
8b5818ac
提交
8b5818ac
authored
3月 31, 2026
作者:
kxjia
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
问题管理
上级
354e0b80
全部展开
隐藏空白字符变更
内嵌
并排
正在显示
23 个修改的文件
包含
1071 行增加
和
126 行删除
+1071
-126
ApprovalPanel.vue
zrch-risk-client-39/src/views/common/ApprovalPanel.vue
+4
-2
CurrentFormPanel.vue
zrch-risk-client-39/src/views/common/CurrentFormPanel.vue
+11
-4
HistoryPanel.vue
zrch-risk-client-39/src/views/common/HistoryPanel.vue
+0
-0
TaskAssigneeDrawer.vue
zrch-risk-client-39/src/views/common/TaskAssigneeDrawer.vue
+0
-0
TaskAssigneeSelector.vue
...-risk-client-39/src/views/common/TaskAssigneeSelector.vue
+0
-0
WorkFlowFormApprovalDrawer.vue
...client-39/src/views/common/WorkFlowFormApprovalDrawer.vue
+0
-0
WorkFlowFormDrawer.vue
zrch-risk-client-39/src/views/common/WorkFlowFormDrawer.vue
+15
-1
StProblemCheckArchive.api.ts
...views/project/problemArchive/StProblemCheckArchive.api.ts
+64
-0
StProblemCheckArchive.data.ts
...iews/project/problemArchive/StProblemCheckArchive.data.ts
+353
-0
StProblemCheckArchiveList.vue
...iews/project/problemArchive/StProblemCheckArchiveList.vue
+245
-0
StProblemCheckArchiveForm.vue
...t/problemArchive/components/StProblemCheckArchiveForm.vue
+71
-0
StProblemCheckArchiveModal.vue
.../problemArchive/components/StProblemCheckArchiveModal.vue
+101
-0
StProblemArchiveList.vue
...9/src/views/project/problemCheck/StProblemArchiveList.vue
+2
-10
StProblemCheck.api.ts
...t-39/src/views/project/problemCheck/StProblemCheck.api.ts
+11
-0
StProblemCheckList.vue
...-39/src/views/project/problemCheck/StProblemCheckList.vue
+7
-7
StProblemExecApprovalList.vue
.../views/project/problemCheck/StProblemExecApprovalList.vue
+26
-12
StProblemExecList.vue
...t-39/src/views/project/problemCheck/StProblemExecList.vue
+26
-11
StProblemIndex.vue
...ient-39/src/views/project/problemCheck/StProblemIndex.vue
+73
-37
StProblemPlanApprovalList.vue
.../views/project/problemCheck/StProblemPlanApprovalList.vue
+23
-10
StProblemPlanList.vue
...t-39/src/views/project/problemCheck/StProblemPlanList.vue
+14
-9
StProblemCheckExecuteForm.vue
...ect/problemCheck/components/StProblemCheckExecuteForm.vue
+10
-12
StProblemCheckForm.vue
...ws/project/problemCheck/components/StProblemCheckForm.vue
+7
-8
StProblemCheckPlanForm.vue
...roject/problemCheck/components/StProblemCheckPlanForm.vue
+8
-3
没有找到文件。
zrch-risk-client-39/src/views/common/ApprovalPanel.vue
浏览文件 @
8b5818ac
...
...
@@ -70,8 +70,6 @@
</div>
<a-divider
v-if=
"showSummary"
/>
<!-- 信息摘要区域 -->
<div
class=
"approval-summary"
v-if=
"showSummary"
>
<div
v-for=
"item in summaryItems"
...
...
@@ -83,6 +81,10 @@
</div>
</div>
</a-form>
<a-space
direction=
""
style=
"width:100%"
>
<a-button
type=
"primary"
ghost
block
@
click=
"handleSubmit"
>
保存
</a-button>
<a-button
type=
"primary"
ghost
block
@
click=
"handleSubmit"
>
保存并发送
</a-button>
</a-space>
</div>
</div>
</template>
...
...
zrch-risk-client-39/src/views/common/CurrentFormPanel.vue
浏览文件 @
8b5818ac
<!-- CurrentFormPanel.vue -->
<
template
>
<div
class=
"form-panel"
>
<div
class=
"form-header"
>
...
...
@@ -11,11 +10,11 @@
<a-tag
color=
"processing"
>
待处理
</a-tag>
</
template
>
<component
:is=
"getComponent(editableNode.formUrl
|| editableNode.formListUrl
)"
:is=
"getComponent(editableNode.formUrl)"
:ref=
"(el) => setFormRef(el, editableNode.id)"
:disabled=
"
false
"
:disabled=
"
props.disabled
"
:readonly=
"false"
:form-data=
"formData"
:form-data=
"
props.
formData"
:current-flow-node=
"editableNode"
@
update:form-data=
"handleFormDataUpdate"
/>
...
...
@@ -59,6 +58,14 @@ const props = defineProps({
externalFormData
:
{
type
:
Object
as
()
=>
Record
<
string
,
any
>
,
default
:
()
=>
({})
},
formData
:
{
type
:
Object
as
()
=>
Record
<
string
,
any
>
,
default
:
()
=>
({})
},
disabled
:
{
type
:
Boolean
,
default
:
false
}
})
...
...
zrch-risk-client-39/src/views/common/HistoryPanel.vue
浏览文件 @
8b5818ac
差异被折叠。
点击展开。
zrch-risk-client-39/src/views/common/TaskAssigneeDrawer.vue
浏览文件 @
8b5818ac
差异被折叠。
点击展开。
zrch-risk-client-39/src/views/common/TaskAssigneeSelector.vue
浏览文件 @
8b5818ac
差异被折叠。
点击展开。
zrch-risk-client-39/src/views/common/WorkFlowFormApprovalDrawer.vue
deleted
100644 → 0
浏览文件 @
354e0b80
差异被折叠。
点击展开。
zrch-risk-client-39/src/views/common/WorkFlowFormDrawer.vue
浏览文件 @
8b5818ac
...
...
@@ -14,7 +14,7 @@
<HistoryPanel
:readonly-nodes=
"readonlyNodes"
:data-id=
"dataId"
:show-history-form-data=
"showHistoryFormData"
:show-history-form-data=
"
props.
showHistoryFormData"
/>
<div
class=
"form-wrapper"
>
<CurrentFormPanel
...
...
@@ -22,6 +22,9 @@
:editable-node=
"editableNode"
:data-id=
"dataId"
:external-form-data=
"externalFormData"
:form-data=
"props.formData"
:form-bpm=
"formBpm"
:disabled=
"showApprovalPanel||false"
@
update:form-data=
"handleFormDataUpdate"
@
form-mounted=
"handleFormMounted"
/>
...
...
@@ -64,6 +67,12 @@ import HistoryPanel from './HistoryPanel.vue'
import
CurrentFormPanel
from
'./CurrentFormPanel.vue'
import
ApprovalPanel
from
'./ApprovalPanel.vue'
const
formBpm
=
ref
(
true
)
const
formDisabled
=
ref
(
false
)
interface
WorkflowNode
{
id
:
string
name
:
string
...
...
@@ -113,6 +122,10 @@ const props = defineProps({
type
:
Object
as
()
=>
Record
<
string
,
any
>
,
default
:
()
=>
({})
},
formData
:
{
type
:
Object
as
()
=>
Record
<
string
,
any
>
,
default
:
()
=>
({})
},
procDefId
:
{
type
:
String
,
default
:
''
...
...
@@ -219,6 +232,7 @@ const approvalPanelRef = ref<InstanceType<typeof ApprovalPanel> | null>(null)
const
drawerTitle
=
computed
(()
=>
props
.
title
)
const
drawerWidth
=
computed
(()
=>
props
.
width
)
// 只读节点:索引小于 currentNodeIndex 的节点
const
readonlyNodes
=
computed
(()
=>
{
if
(
!
props
.
workflowNodes
||
props
.
workflowNodes
.
length
===
0
)
{
...
...
zrch-risk-client-39/src/views/project/problemArchive/StProblemCheckArchive.api.ts
0 → 100644
浏览文件 @
8b5818ac
import
{
defHttp
}
from
'/@/utils/http/axios'
;
import
{
useMessage
}
from
"/@/hooks/web/useMessage"
;
const
{
createConfirm
}
=
useMessage
();
enum
Api
{
list
=
'/problem/stProblemCheckArchive/list'
,
save
=
'/problem/stProblemCheckArchive/add'
,
edit
=
'/problem/stProblemCheckArchive/edit'
,
deleteOne
=
'/problem/stProblemCheckArchive/delete'
,
deleteBatch
=
'/problem/stProblemCheckArchive/deleteBatch'
,
importExcel
=
'/problem/stProblemCheckArchive/importExcel'
,
exportXls
=
'/problem/stProblemCheckArchive/exportXls'
,
}
/**
* 导出api
* @param params
*/
export
const
getExportUrl
=
Api
.
exportXls
;
/**
* 导入api
*/
export
const
getImportUrl
=
Api
.
importExcel
;
/**
* 列表接口
* @param params
*/
export
const
list
=
(
params
)
=>
defHttp
.
get
({
url
:
Api
.
list
,
params
});
/**
* 删除单个
*/
export
const
deleteOne
=
(
params
,
handleSuccess
)
=>
{
return
defHttp
.
delete
({
url
:
Api
.
deleteOne
,
params
},
{
joinParamsToUrl
:
true
}).
then
(()
=>
{
handleSuccess
();
});
}
/**
* 批量删除
* @param params
*/
export
const
batchDelete
=
(
params
,
handleSuccess
)
=>
{
createConfirm
({
iconType
:
'warning'
,
title
:
'确认删除'
,
content
:
'是否删除选中数据'
,
okText
:
'确认'
,
cancelText
:
'取消'
,
onOk
:
()
=>
{
return
defHttp
.
delete
({
url
:
Api
.
deleteBatch
,
data
:
params
},
{
joinParamsToUrl
:
true
}).
then
(()
=>
{
handleSuccess
();
});
}
});
}
/**
* 保存或者更新
* @param params
*/
export
const
saveOrUpdate
=
(
params
,
isUpdate
)
=>
{
let
url
=
isUpdate
?
Api
.
edit
:
Api
.
save
;
return
defHttp
.
post
({
url
:
url
,
params
});
}
zrch-risk-client-39/src/views/project/problemArchive/StProblemCheckArchive.data.ts
0 → 100644
浏览文件 @
8b5818ac
import
{
BasicColumn
}
from
'/@/components/Table'
;
import
{
FormSchema
}
from
'/@/components/Table'
;
import
{
render
}
from
'/@/utils/common/renderUtils'
;
//列表数据
export
const
columns
:
BasicColumn
[]
=
[
{
title
:
'问题编号'
,
align
:
'center'
,
dataIndex
:
'problemNo'
,
resizable
:
true
,
ifShow
:
true
,
width
:
100
,
sorter
:
true
,
},
{
title
:
'项目分类'
,
align
:
'center'
,
dataIndex
:
'projectCategory'
,
resizable
:
true
,
width
:
100
,
sorter
:
true
,
customRender
:
({
text
})
=>
{
return
render
.
renderDict
(
text
,
'project_category'
);
},
},
{
title
:
'问题来源'
,
align
:
'center'
,
dataIndex
:
'problemSource'
,
resizable
:
true
,
width
:
150
,
},
{
title
:
'所属领域'
,
align
:
'center'
,
dataIndex
:
'domain'
,
width
:
150
,
resizable
:
true
,
customRender
:
({
text
})
=>
{
return
render
.
renderDict
(
text
,
'rate_domain'
);
},
sorter
:
true
,
},
{
title
:
'问题描述'
,
align
:
'center'
,
dataIndex
:
'problemDes'
,
resizable
:
true
,
ifShow
:
false
,
},
{
title
:
'风险等级'
,
align
:
'center'
,
dataIndex
:
'riskLevel'
,
width
:
100
,
resizable
:
true
,
customRender
:
({
text
})
=>
{
return
render
.
renderDict
(
text
,
'risk_level'
);
},
},
{
title
:
'整改状态'
,
align
:
'center'
,
dataIndex
:
'bpmStatus'
,
width
:
100
,
resizable
:
true
,
customRender
:
({
text
})
=>
{
return
render
.
renderDict
(
text
,
'bpm_status'
);
},
sorter
:
true
,
},
];
//查询数据
export
const
searchFormSchema
:
FormSchema
[]
=
[
];
//表单数据
export
const
formSchema
:
FormSchema
[]
=
[
{
label
:
'编号'
,
field
:
'problemNo'
,
component
:
'Input'
,
},
{
label
:
'projectCategory'
,
field
:
'projectCategory'
,
component
:
'Input'
,
},
{
label
:
'类别'
,
field
:
'problemItem'
,
component
:
'Input'
,
},
{
label
:
'问题描述'
,
field
:
'problemDes'
,
component
:
'InputTextArea'
,
},
{
label
:
'发现人'
,
field
:
'findUser'
,
component
:
'Input'
,
},
{
label
:
'发现时间'
,
field
:
'findingTime'
,
component
:
'DatePicker'
,
componentProps
:
{
showTime
:
true
,
valueFormat
:
'YYYY-MM-DD HH:mm:ss'
},
},
{
label
:
'问题来源'
,
field
:
'problemSource'
,
component
:
'Input'
,
},
{
label
:
'严重程度;0001 不严重 0002 一般 0003 严重 0004 非常严重'
,
field
:
'severity'
,
component
:
'Input'
,
},
{
label
:
'领域'
,
field
:
'domain'
,
component
:
'Input'
,
},
{
label
:
'负责部门'
,
field
:
'headDepCode'
,
component
:
'Input'
,
},
{
label
:
'负责人'
,
field
:
'headUserId'
,
component
:
'Input'
,
},
{
label
:
'是否整改: 0-否 1-是'
,
field
:
'isRectified'
,
component
:
'Input'
,
},
{
label
:
'整改状态'
,
field
:
'rectifyStatus'
,
component
:
'Input'
,
},
{
label
:
'风险等级'
,
field
:
'riskLevel'
,
component
:
'InputNumber'
,
},
{
label
:
'整改周期'
,
field
:
'rectifyCycle'
,
component
:
'InputNumber'
,
},
{
label
:
'整改方案'
,
field
:
'rectifyPlan'
,
component
:
'InputTextArea'
,
},
{
label
:
'计划开始时间'
,
field
:
'planStartDate'
,
component
:
'DatePicker'
,
componentProps
:
{
valueFormat
:
'YYYY-MM-DD'
},
},
{
label
:
'成因分析'
,
field
:
'causeAnalysis'
,
component
:
'Input'
,
},
{
label
:
'计划结束时间'
,
field
:
'planEndDate'
,
component
:
'DatePicker'
,
componentProps
:
{
valueFormat
:
'YYYY-MM-DD'
},
},
{
label
:
'执行部门'
,
field
:
'execDepCode'
,
component
:
'Input'
,
},
{
label
:
'执行人'
,
field
:
'execUserId'
,
component
:
'Input'
,
},
{
label
:
'整改开始时间'
,
field
:
'execStartDate'
,
component
:
'DatePicker'
,
componentProps
:
{
valueFormat
:
'YYYY-MM-DD'
},
},
{
label
:
'整改结束时间'
,
field
:
'execEndDate'
,
component
:
'DatePicker'
,
componentProps
:
{
valueFormat
:
'YYYY-MM-DD'
},
},
{
label
:
'整改落实情况'
,
field
:
'execRemark'
,
component
:
'InputTextArea'
,
},
{
label
:
'审核意见'
,
field
:
'reviewComment'
,
component
:
'InputTextArea'
,
},
{
label
:
'流程节点顺序号'
,
field
:
'bmpNodeId'
,
component
:
'Input'
,
},
{
label
:
'流程状态'
,
field
:
'bpmStatus'
,
component
:
'Input'
,
},
{
label
:
'部署ID'
,
field
:
'deployId'
,
component
:
'Input'
,
},
{
label
:
'创建人'
,
field
:
'createdUser'
,
component
:
'Input'
,
},
{
label
:
'创建时间'
,
field
:
'createdTime'
,
component
:
'DatePicker'
,
componentProps
:
{
showTime
:
true
,
valueFormat
:
'YYYY-MM-DD HH:mm:ss'
},
},
{
label
:
'更新人'
,
field
:
'updatedUser'
,
component
:
'Input'
,
},
{
label
:
'更新时间'
,
field
:
'updatedTime'
,
component
:
'DatePicker'
,
componentProps
:
{
showTime
:
true
,
valueFormat
:
'YYYY-MM-DD HH:mm:ss'
},
},
{
label
:
'0=未 1=接收'
,
field
:
'isReceive'
,
component
:
'InputNumber'
,
},
{
label
:
'programme'
,
field
:
'programme'
,
component
:
'Input'
,
},
{
label
:
'strategy'
,
field
:
'strategy'
,
component
:
'Input'
,
},
{
label
:
'caNo'
,
field
:
'caNo'
,
component
:
'InputNumber'
,
},
{
label
:
'headUserCode'
,
field
:
'headUserCode'
,
component
:
'Input'
,
},
{
label
:
'receivestatus'
,
field
:
'receivestatus'
,
component
:
'Input'
,
},
// TODO 主键隐藏字段,目前写死为ID
{
label
:
''
,
field
:
'id'
,
component
:
'Input'
,
show
:
false
},
];
// 高级查询数据
export
const
superQuerySchema
=
{
problemNo
:
{
title
:
'编号'
,
order
:
0
,
view
:
'text'
,
type
:
'string'
,},
projectCategory
:
{
title
:
'projectCategory'
,
order
:
1
,
view
:
'text'
,
type
:
'string'
,},
problemItem
:
{
title
:
'类别'
,
order
:
2
,
view
:
'text'
,
type
:
'string'
,},
problemDes
:
{
title
:
'问题描述'
,
order
:
3
,
view
:
'textarea'
,
type
:
'string'
,},
findUser
:
{
title
:
'发现人'
,
order
:
4
,
view
:
'text'
,
type
:
'string'
,},
findingTime
:
{
title
:
'发现时间'
,
order
:
5
,
view
:
'datetime'
,
type
:
'string'
,},
problemSource
:
{
title
:
'问题来源'
,
order
:
6
,
view
:
'text'
,
type
:
'string'
,},
severity
:
{
title
:
'严重程度;0001 不严重 0002 一般 0003 严重 0004 非常严重'
,
order
:
7
,
view
:
'text'
,
type
:
'string'
,},
domain
:
{
title
:
'领域'
,
order
:
8
,
view
:
'text'
,
type
:
'string'
,},
headDepCode
:
{
title
:
'负责部门'
,
order
:
9
,
view
:
'text'
,
type
:
'string'
,},
headUserId
:
{
title
:
'负责人'
,
order
:
10
,
view
:
'text'
,
type
:
'string'
,},
isRectified
:
{
title
:
'是否整改: 0-否 1-是'
,
order
:
11
,
view
:
'text'
,
type
:
'string'
,},
rectifyStatus
:
{
title
:
'整改状态'
,
order
:
12
,
view
:
'text'
,
type
:
'string'
,},
riskLevel
:
{
title
:
'风险等级'
,
order
:
13
,
view
:
'number'
,
type
:
'number'
,},
rectifyCycle
:
{
title
:
'整改周期'
,
order
:
14
,
view
:
'number'
,
type
:
'number'
,},
rectifyPlan
:
{
title
:
'整改方案'
,
order
:
15
,
view
:
'textarea'
,
type
:
'string'
,},
planStartDate
:
{
title
:
'计划开始时间'
,
order
:
16
,
view
:
'date'
,
type
:
'string'
,},
causeAnalysis
:
{
title
:
'成因分析'
,
order
:
17
,
view
:
'text'
,
type
:
'string'
,},
planEndDate
:
{
title
:
'计划结束时间'
,
order
:
18
,
view
:
'date'
,
type
:
'string'
,},
execDepCode
:
{
title
:
'执行部门'
,
order
:
19
,
view
:
'text'
,
type
:
'string'
,},
execUserId
:
{
title
:
'执行人'
,
order
:
20
,
view
:
'text'
,
type
:
'string'
,},
execStartDate
:
{
title
:
'整改开始时间'
,
order
:
21
,
view
:
'date'
,
type
:
'string'
,},
execEndDate
:
{
title
:
'整改结束时间'
,
order
:
22
,
view
:
'date'
,
type
:
'string'
,},
execRemark
:
{
title
:
'整改落实情况'
,
order
:
23
,
view
:
'textarea'
,
type
:
'string'
,},
reviewComment
:
{
title
:
'审核意见'
,
order
:
24
,
view
:
'textarea'
,
type
:
'string'
,},
bmpNodeId
:
{
title
:
'流程节点顺序号'
,
order
:
25
,
view
:
'text'
,
type
:
'string'
,},
bpmStatus
:
{
title
:
'流程状态'
,
order
:
26
,
view
:
'text'
,
type
:
'string'
,},
deployId
:
{
title
:
'部署ID'
,
order
:
27
,
view
:
'text'
,
type
:
'string'
,},
createdUser
:
{
title
:
'创建人'
,
order
:
28
,
view
:
'text'
,
type
:
'string'
,},
createdTime
:
{
title
:
'创建时间'
,
order
:
29
,
view
:
'datetime'
,
type
:
'string'
,},
updatedUser
:
{
title
:
'更新人'
,
order
:
30
,
view
:
'text'
,
type
:
'string'
,},
updatedTime
:
{
title
:
'更新时间'
,
order
:
31
,
view
:
'datetime'
,
type
:
'string'
,},
isReceive
:
{
title
:
'0=未 1=接收'
,
order
:
32
,
view
:
'number'
,
type
:
'number'
,},
programme
:
{
title
:
'programme'
,
order
:
33
,
view
:
'text'
,
type
:
'string'
,},
strategy
:
{
title
:
'strategy'
,
order
:
34
,
view
:
'text'
,
type
:
'string'
,},
caNo
:
{
title
:
'caNo'
,
order
:
35
,
view
:
'number'
,
type
:
'number'
,},
headUserCode
:
{
title
:
'headUserCode'
,
order
:
36
,
view
:
'text'
,
type
:
'string'
,},
receivestatus
:
{
title
:
'receivestatus'
,
order
:
37
,
view
:
'text'
,
type
:
'string'
,},
};
/**
* 流程表单调用这个方法获取formSchema
* @param param
*/
export
function
getBpmFormSchema
(
_formData
):
FormSchema
[]{
// 默认和原始表单保持一致 如果流程中配置了权限数据,这里需要单独处理formSchema
return
formSchema
;
}
\ No newline at end of file
zrch-risk-client-39/src/views/project/problemArchive/StProblemCheckArchiveList.vue
0 → 100644
浏览文件 @
8b5818ac
<
template
>
<div>
<!--引用表格-->
<BasicTable
@
register=
"registerTable"
:rowSelection=
"rowSelection"
>
<!--插槽:table标题-->
<template
#
tableTitle
>
<a-button
type=
"primary"
v-auth=
"'problem:st_problem_check_archive:add'"
@
click=
"handleAdd"
preIcon=
"ant-design:plus-outlined"
>
新增
</a-button>
<a-button
type=
"primary"
v-auth=
"'problem:st_problem_check_archive:exportXls'"
preIcon=
"ant-design:export-outlined"
@
click=
"onExportXls"
>
导出
</a-button>
<j-upload-button
type=
"primary"
v-auth=
"'problem:st_problem_check_archive:importExcel'"
preIcon=
"ant-design:import-outlined"
@
click=
"onImportXls"
>
导入
</j-upload-button>
<a-dropdown
v-if=
"selectedRowKeys.length > 0"
>
<template
#
overlay
>
<a-menu>
<a-menu-item
key=
"1"
@
click=
"batchHandleDelete"
>
<Icon
icon=
"ant-design:delete-outlined"
></Icon>
删除
</a-menu-item>
</a-menu>
</
template
>
<a-button
v-auth=
"'problem:st_problem_check_archive:deleteBatch'"
>
批量操作
<Icon
icon=
"mdi:chevron-down"
></Icon>
</a-button>
</a-dropdown>
<!-- 高级查询 -->
<super-query
:config=
"superQueryConfig"
@
search=
"handleSuperQuery"
/>
</template>
<!--操作栏-->
<
template
#
action=
"{ record }"
>
<TableAction
:actions=
"getTableAction(record)"
:dropDownActions=
"getDropDownAction(record)"
/>
</
template
>
<!--字段回显插槽-->
<
template
v-slot:bodyCell=
"{ column, record, index, text }"
>
</
template
>
</BasicTable>
<!-- 表单区域 -->
<StProblemCheckArchiveModal
@
register=
"registerModal"
@
success=
"handleSuccess"
></StProblemCheckArchiveModal>
<!-- 审批记录 -->
<BpmPictureModal
@
register=
"registerBpmModal"
/>
</div>
</template>
<
script
lang=
"ts"
name=
"problem-stProblemCheckArchive"
setup
>
import
{
ref
,
reactive
,
computed
,
unref
}
from
'vue'
;
import
{
BasicTable
,
useTable
,
TableAction
}
from
'/@/components/Table'
;
import
{
useModal
}
from
'/@/components/Modal'
;
import
{
useListPage
}
from
'/@/hooks/system/useListPage'
import
StProblemCheckArchiveModal
from
'./components/StProblemCheckArchiveModal.vue'
import
{
columns
,
searchFormSchema
,
superQuerySchema
}
from
'./StProblemCheckArchive.data'
;
import
{
list
,
deleteOne
,
batchDelete
,
getImportUrl
,
getExportUrl
}
from
'./StProblemCheckArchive.api'
;
import
{
getDateByPicker
}
from
'/@/utils'
;
//日期个性化选择
const
fieldPickers
=
reactive
({
});
const
[
registerBpmModal
,
{
openModal
:
bpmPicModal
}]
=
useModal
();
const
queryParam
=
reactive
<
any
>
({});
//注册model
const
[
registerModal
,
{
openModal
}]
=
useModal
();
//注册table数据
const
{
prefixCls
,
tableContext
,
onExportXls
,
onImportXls
}
=
useListPage
({
tableProps
:{
title
:
'问题归档'
,
api
:
list
,
columns
,
canResize
:
true
,
formConfig
:
{
//labelWidth: 120,
schemas
:
searchFormSchema
,
autoSubmitOnEnter
:
true
,
showAdvancedButton
:
true
,
fieldMapToNumber
:
[
],
fieldMapToTime
:
[
],
},
actionColumn
:
{
width
:
120
,
fixed
:
'right'
},
beforeFetch
:
(
params
)
=>
{
if
(
params
&&
fieldPickers
)
{
for
(
let
key
in
fieldPickers
)
{
if
(
params
[
key
])
{
params
[
key
]
=
getDateByPicker
(
params
[
key
],
fieldPickers
[
key
]);
}
}
}
return
Object
.
assign
(
params
,
queryParam
);
},
},
exportConfig
:
{
name
:
"问题归档"
,
url
:
getExportUrl
,
params
:
queryParam
,
},
importConfig
:
{
url
:
getImportUrl
,
success
:
handleSuccess
},
})
const
[
registerTable
,
{
reload
},{
rowSelection
,
selectedRowKeys
}]
=
tableContext
// 高级查询配置
const
superQueryConfig
=
reactive
(
superQuerySchema
);
/**
* 高级查询事件
*/
function
handleSuperQuery
(
params
)
{
Object
.
keys
(
params
).
map
((
k
)
=>
{
queryParam
[
k
]
=
params
[
k
];
});
reload
();
}
/**
* 新增事件
*/
function
handleAdd
()
{
openModal
(
true
,
{
isUpdate
:
false
,
showFooter
:
true
,
});
}
/**
* 编辑事件
*/
function
handleEdit
(
record
:
Recordable
)
{
openModal
(
true
,
{
record
,
isUpdate
:
true
,
showFooter
:
true
,
});
}
/**
* 详情
*/
function
handleDetail
(
record
:
Recordable
)
{
openModal
(
true
,
{
record
,
isUpdate
:
true
,
showFooter
:
false
,
});
}
/**
* 删除事件
*/
async
function
handleDelete
(
record
)
{
await
deleteOne
({
id
:
record
.
id
},
handleSuccess
);
}
/**
* 批量删除事件
*/
async
function
batchHandleDelete
()
{
await
batchDelete
({
ids
:
selectedRowKeys
.
value
},
handleSuccess
);
}
/**
* 成功回调
*/
function
handleSuccess
()
{
(
selectedRowKeys
.
value
=
[])
&&
reload
();
}
/**
* 操作栏
*/
function
getTableAction
(
record
){
return
[
{
label
:
'编辑'
,
onClick
:
handleEdit
.
bind
(
null
,
record
),
auth
:
'problem:st_problem_check_archive:edit'
}
]
}
/**
* 下拉操作栏
*/
function
getDropDownAction
(
record
){
let
dropDownAction
=
[
{
label
:
'详情'
,
onClick
:
handleDetail
.
bind
(
null
,
record
),
},
{
label
:
'删除'
,
popConfirm
:
{
title
:
'是否确认删除'
,
confirm
:
handleDelete
.
bind
(
null
,
record
),
placement
:
'topLeft'
,
},
auth
:
'problem:st_problem_check_archive:delete'
},
{
label
:
'审批进度'
,
onClick
:
handlePreviewPic
.
bind
(
null
,
record
),
ifShow
:
!!
record
.
bpmStatus
&&
record
.
bpmStatus
!==
'1'
,
}
];
if
(
record
.
bpmStatus
==
'1'
){
dropDownAction
.
push
({
label
:
'发起流程'
,
popConfirm
:
{
title
:
'确认提交流程吗?'
,
confirm
:
handleProcess
.
bind
(
null
,
record
),
placement
:
'topLeft'
,
}
})
}
return
dropDownAction
;
}
/**
* 提交流程
*/
async
function
handleProcess
(
record
)
{
let
params
=
{
flowCode
:
'dev_st_problem_check_archive_001'
,
id
:
record
.
id
,
formUrl
:
'problem/components/StProblemCheckArchiveForm'
,
formUrlMobile
:
''
}
await
startProcess
(
params
);
handleSuccess
();
}
/**
* 审批进度
*/
async
function
handlePreviewPic
(
record
)
{
bpmPicModal
(
true
,
{
flowCode
:
'dev_st_problem_check_archive_001'
,
dataId
:
record
.
id
,
});
}
</
script
>
<
style
lang=
"less"
scoped
>
:deep(.ant-picker),:deep(.ant-input-number){
width: 100%;
}
</
style
>
\ No newline at end of file
zrch-risk-client-39/src/views/project/problemArchive/components/StProblemCheckArchiveForm.vue
0 → 100644
浏览文件 @
8b5818ac
<
template
>
<div
style=
"min-height: 400px"
>
<BasicForm
@
register=
"registerForm"
></BasicForm>
<div
style=
"width: 100%;text-align: center"
v-if=
"!formDisabled"
>
<a-button
@
click=
"submitForm"
pre-icon=
"ant-design:check"
type=
"primary"
>
提 交
</a-button>
</div>
</div>
</
template
>
<
script
lang=
"ts"
>
import
{
BasicForm
,
useForm
}
from
'/@/components/Form/index'
;
import
{
computed
,
defineComponent
}
from
'vue'
;
import
{
defHttp
}
from
'/@/utils/http/axios'
;
import
{
propTypes
}
from
'/@/utils/propTypes'
;
import
{
getBpmFormSchema
}
from
'../StProblemCheckArchive.data'
;
import
{
saveOrUpdate
}
from
'../StProblemCheckArchive.api'
;
export
default
defineComponent
({
name
:
"StProblemCheckArchiveForm"
,
components
:{
BasicForm
},
props
:{
formData
:
propTypes
.
object
.
def
({}),
formBpm
:
propTypes
.
bool
.
def
(
true
),
},
setup
(
props
){
const
[
registerForm
,
{
setFieldsValue
,
setProps
,
getFieldsValue
}]
=
useForm
({
labelWidth
:
150
,
schemas
:
getBpmFormSchema
(
props
.
formData
),
showActionButtonGroup
:
false
,
baseColProps
:
{
span
:
24
}
});
const
formDisabled
=
computed
(()
=>
{
if
(
props
.
formData
.
disabled
===
false
){
return
false
;
}
return
true
;
});
let
formData
=
{};
const
queryByIdUrl
=
'/problem/stProblemCheckArchive/queryById'
;
async
function
initFormData
(){
let
params
=
{
id
:
props
.
formData
.
dataId
};
const
data
=
await
defHttp
.
get
({
url
:
queryByIdUrl
,
params
});
formData
=
{...
data
}
//设置表单的值
await
setFieldsValue
(
formData
);
//默认是禁用
await
setProps
({
disabled
:
formDisabled
.
value
})
}
async
function
submitForm
()
{
let
data
=
getFieldsValue
();
let
params
=
Object
.
assign
({},
formData
,
data
);
console
.
log
(
'表单数据'
,
params
)
await
saveOrUpdate
(
params
,
true
)
}
initFormData
();
return
{
registerForm
,
formDisabled
,
submitForm
,
}
}
});
</
script
>
\ No newline at end of file
zrch-risk-client-39/src/views/project/problemArchive/components/StProblemCheckArchiveModal.vue
0 → 100644
浏览文件 @
8b5818ac
<
template
>
<BasicModal
v-bind=
"$attrs"
@
register=
"registerModal"
destroyOnClose
:title=
"title"
:maxHeight=
"500"
:width=
"800"
@
ok=
"handleSubmit"
>
<BasicForm
@
register=
"registerForm"
name=
"StProblemCheckArchiveForm"
/>
</BasicModal>
</
template
>
<
script
lang=
"ts"
setup
>
import
{
ref
,
computed
,
unref
,
reactive
}
from
'vue'
;
import
{
BasicModal
,
useModalInner
}
from
'/@/components/Modal'
;
import
{
BasicForm
,
useForm
}
from
'/@/components/Form/index'
;
import
{
formSchema
}
from
'../StProblemCheckArchive.data'
;
import
{
saveOrUpdate
}
from
'../StProblemCheckArchive.api'
;
import
{
useMessage
}
from
'/@/hooks/web/useMessage'
;
import
{
getDateByPicker
}
from
'/@/utils'
;
const
{
createMessage
}
=
useMessage
();
// Emits声明
const
emit
=
defineEmits
([
'register'
,
'success'
]);
const
isUpdate
=
ref
(
true
);
const
isDetail
=
ref
(
false
);
//表单配置
const
[
registerForm
,
{
setProps
,
resetFields
,
setFieldsValue
,
validate
,
scrollToField
}]
=
useForm
({
labelWidth
:
150
,
schemas
:
formSchema
,
showActionButtonGroup
:
false
,
baseColProps
:
{
span
:
24
},
baseRowStyle
:
{
padding
:
"0 20px"
}
});
//表单赋值
const
[
registerModal
,
{
setModalProps
,
closeModal
}]
=
useModalInner
(
async
(
data
)
=>
{
//重置表单
await
resetFields
();
setModalProps
({
confirmLoading
:
false
,
showCancelBtn
:
!!
data
?.
showFooter
,
showOkBtn
:
!!
data
?.
showFooter
});
isUpdate
.
value
=
!!
data
?.
isUpdate
;
isDetail
.
value
=
!!
data
?.
showFooter
;
if
(
unref
(
isUpdate
))
{
//表单赋值
await
setFieldsValue
({
...
data
.
record
,
});
}
// 隐藏底部时禁用整个表单
setProps
({
disabled
:
!
data
?.
showFooter
})
});
//日期个性化选择
const
fieldPickers
=
reactive
({
});
//设置标题
const
title
=
computed
(()
=>
(
!
unref
(
isUpdate
)
?
'新增'
:
!
unref
(
isDetail
)
?
'详情'
:
'编辑'
));
//表单提交事件
async
function
handleSubmit
(
v
)
{
try
{
let
values
=
await
validate
();
// 预处理日期数据
changeDateValue
(
values
);
setModalProps
({
confirmLoading
:
true
});
//提交表单
await
saveOrUpdate
(
values
,
isUpdate
.
value
);
//关闭弹窗
closeModal
();
//刷新列表
emit
(
'success'
);
}
catch
({
errorFields
})
{
if
(
errorFields
)
{
const
firstField
=
errorFields
[
0
];
if
(
firstField
)
{
scrollToField
(
firstField
.
name
,
{
behavior
:
'smooth'
,
block
:
'center'
});
}
}
return
Promise
.
reject
(
errorFields
);
}
finally
{
setModalProps
({
confirmLoading
:
false
});
}
}
/**
* 处理日期值
* @param formData 表单数据
*/
const
changeDateValue
=
(
formData
)
=>
{
if
(
formData
&&
fieldPickers
)
{
for
(
let
key
in
fieldPickers
)
{
if
(
formData
[
key
])
{
formData
[
key
]
=
getDateByPicker
(
formData
[
key
],
fieldPickers
[
key
]);
}
}
}
};
</
script
>
<
style
lang=
"less"
scoped
>
/** 时间和数字输入框样式 */
:deep(.ant-input-number) {
width: 100%;
}
:deep(.ant-calendar-picker) {
width: 100%;
}
</
style
>
\ No newline at end of file
zrch-risk-client-39/src/views/project/problemCheck/StProblemArchiveList.vue
浏览文件 @
8b5818ac
...
...
@@ -22,7 +22,7 @@
import
{
useModal
}
from
'/@/components/Modal'
;
import
{
useListPage
}
from
'/@/hooks/system/useListPage'
;
import
{
columns
,
searchFormSchema
}
from
'./StProblemCheck.data'
;
import
{
list
}
from
'./StProblemCheck.api'
;
import
{
list
,
problemArchive
}
from
'./StProblemCheck.api'
;
import
StProblemCheckExecuteModal
from
'./components/StProblemCheckExecuteModal.vue'
;
const
emit
=
defineEmits
([
'callback'
])
...
...
@@ -52,14 +52,6 @@
api
:
list
,
columns
,
canResize
:
false
,
formConfig
:
{
//labelWidth: 120,
schemas
:
searchFormSchema
,
autoSubmitOnEnter
:
true
,
showAdvancedButton
:
true
,
fieldMapToNumber
:
[],
fieldMapToTime
:
[],
},
beforeFetch
(
params
)
{
params
[
'bmpNodeId'
]
=
props
.
currentFlowNode
.
id
},
...
...
@@ -73,7 +65,7 @@
const
[
registerTable
,
{
reload
},
{
rowSelection
,
selectedRowKeys
}]
=
tableContext
;
function
handleArchive
(
record
:
Recordable
)
{
emit
(
"callback"
,
record
)
problemArchive
({
id
:
record
.
id
,
}).
then
(
handleSuccess
);
}
function
handleSuccess
()
{
...
...
zrch-risk-client-39/src/views/project/problemCheck/StProblemCheck.api.ts
浏览文件 @
8b5818ac
...
...
@@ -11,6 +11,7 @@ enum Api {
deleteBatch
=
'/problem/stProblemCheck/deleteBatch'
,
importExcel
=
'/problem/stProblemCheck/importExcel'
,
exportXls
=
'/problem/stProblemCheck/exportXls'
,
problemArchive
=
'/problem/stProblemCheck/problemArchive'
,
}
/**
* 导出api
...
...
@@ -62,3 +63,13 @@ export const saveOrUpdate = (params, isUpdate) => {
let
url
=
isUpdate
?
Api
.
edit
:
Api
.
save
;
return
defHttp
.
post
({
url
:
url
,
params
});
}
/**
* 保存或者更新
* @param params
*/
export
const
problemArchive
=
(
params
)
=>
{
let
url
=
Api
.
problemArchive
;
return
defHttp
.
post
({
url
:
url
,
params
});
}
zrch-risk-client-39/src/views/project/problemCheck/StProblemCheckList.vue
浏览文件 @
8b5818ac
...
...
@@ -65,13 +65,13 @@
api
:
list
,
columns
,
canResize
:
false
,
formConfig
:
{
schemas
:
searchFormSchema
,
autoSubmitOnEnter
:
true
,
showAdvancedButton
:
true
,
fieldMapToNumber
:
[],
fieldMapToTime
:
[],
},
//
formConfig: {
//
schemas: searchFormSchema,
//
autoSubmitOnEnter: true,
//
showAdvancedButton: true,
//
fieldMapToNumber: [],
//
fieldMapToTime: [],
//
},
beforeFetch
(
params
)
{
params
[
'bmpNodeId'
]
=
props
.
currentFlowNode
.
id
},
...
...
zrch-risk-client-39/src/views/project/problemCheck/StProblemExecApprovalList.vue
浏览文件 @
8b5818ac
...
...
@@ -17,15 +17,15 @@
</template>
<
script
lang=
"ts"
name=
"problem-stProblemCheck"
setup
>
import
{
ref
}
from
'vue'
;
import
{
BasicTable
,
TableAction
}
from
'/@/components/Table'
;
import
{
useModal
}
from
'/@/components/Modal'
;
import
{
useListPage
}
from
'/@/hooks/system/useListPage'
;
import
{
columns
,
searchFormSchema
}
from
'./StProblemCheck.data'
;
import
{
list
}
from
'./StProblemCheck.api'
;
import
{
list
,
saveOrUpdate
}
from
'./StProblemCheck.api'
;
import
StProblemCheckExecuteModal
from
'./components/StProblemCheckExecuteModal.vue'
;
const
emit
=
defineEmits
([
'callback'
])
const
emit
=
defineEmits
([
'callback'
,
'sendWorkFlow'
])
const
props
=
defineProps
({
beforeFlowNode
:
{
...
...
@@ -50,15 +50,7 @@
title
:
'计划执行审批'
,
api
:
list
,
columns
,
canResize
:
false
,
formConfig
:
{
//labelWidth: 120,
schemas
:
searchFormSchema
,
autoSubmitOnEnter
:
true
,
showAdvancedButton
:
true
,
fieldMapToNumber
:
[],
fieldMapToTime
:
[],
},
canResize
:
true
,
beforeFetch
(
params
)
{
params
[
'bmpNodeId'
]
=
props
.
currentFlowNode
.
id
},
...
...
@@ -78,6 +70,10 @@
function
handleSuccess
()
{
(
selectedRowKeys
.
value
=
[])
&&
reload
();
}
function
handleSendNext
(
record
:
Recordable
)
{
emit
(
"sendWorkFlow"
,
record
)
}
function
getTableAction
(
record
)
{
return
[
...
...
@@ -85,9 +81,27 @@
label
:
'整改审核'
,
onClick
:
handleExecuteApproval
.
bind
(
null
,
record
),
},
{
label
:
'提交'
,
onClick
:
handleSendNext
.
bind
(
null
,
record
),
},
];
}
async
function
handleUpdate
(
dataId
)
{
await
saveOrUpdate
({
bmpNodeId
:
props
.
nextFlowNode
.
id
,
id
:
dataId
,
},
true
).
then
(
res
=>
{
handleSuccess
();
})
}
defineExpose
({
handleUpdate
,
})
</
script
>
<
style
scoped
></
style
>
zrch-risk-client-39/src/views/project/problemCheck/StProblemExecList.vue
浏览文件 @
8b5818ac
...
...
@@ -22,10 +22,10 @@
import
{
useModal
}
from
'/@/components/Modal'
;
import
{
useListPage
}
from
'/@/hooks/system/useListPage'
;
import
{
columns
,
searchFormSchema
}
from
'./StProblemCheck.data'
;
import
{
list
}
from
'./StProblemCheck.api'
;
import
{
list
,
saveOrUpdate
}
from
'./StProblemCheck.api'
;
import
StProblemCheckExecuteModal
from
'./components/StProblemCheckExecuteModal.vue'
;
const
emit
=
defineEmits
([
'callback'
])
const
emit
=
defineEmits
([
'callback'
,
'sendWorkFlow'
])
const
props
=
defineProps
({
beforeFlowNode
:
{
...
...
@@ -50,15 +50,7 @@
title
:
'问题整改'
,
api
:
list
,
columns
,
canResize
:
false
,
formConfig
:
{
//labelWidth: 120,
schemas
:
searchFormSchema
,
autoSubmitOnEnter
:
true
,
showAdvancedButton
:
true
,
fieldMapToNumber
:
[],
fieldMapToTime
:
[],
},
canResize
:
true
,
beforeFetch
(
params
)
{
params
[
'bmpNodeId'
]
=
props
.
currentFlowNode
.
id
},
...
...
@@ -78,6 +70,10 @@
function
handleSuccess
()
{
(
selectedRowKeys
.
value
=
[])
&&
reload
();
}
function
handleSendNext
(
record
:
Recordable
)
{
emit
(
"sendWorkFlow"
,
record
)
}
function
getTableAction
(
record
)
{
return
[
...
...
@@ -85,9 +81,28 @@
label
:
'整改执行'
,
onClick
:
handleExecute
.
bind
(
null
,
record
),
},
{
label
:
'提交'
,
onClick
:
handleSendNext
.
bind
(
null
,
record
),
},
];
}
async
function
handleUpdate
(
dataId
)
{
await
saveOrUpdate
({
bmpNodeId
:
props
.
nextFlowNode
.
id
,
id
:
dataId
,
},
true
).
then
(
res
=>
{
handleSuccess
();
})
}
defineExpose
({
handleUpdate
,
})
</
script
>
<
style
scoped
></
style
>
zrch-risk-client-39/src/views/project/problemCheck/StProblemIndex.vue
浏览文件 @
8b5818ac
...
...
@@ -4,6 +4,7 @@
<a-tab-pane
v-for=
"(node, index) in workflowNodes"
:key=
"index + 1"
:tab=
"node.name"
>
<div
v-if=
"node.formListUrl"
class=
"tab-content"
>
<component
:is=
"loadComponent(node.formListUrl)"
:ref=
"(el) => setFormComponentRef(el, index)"
@
startWorkFlow=
"handleDefinitionStart"
@
sendWorkFlow=
"handleDefinitionSend"
:beforeFlowNode=
"workflowNodes[index-1]"
...
...
@@ -25,6 +26,7 @@
:workflow-nodes=
"workflowNodes"
:external-form-data=
"externalFormData"
:proc-def-id=
"currentProcDefId"
:show-history-form-data=
"true"
:data-id=
"dataId"
:show-approval-panel=
"isShowApprovalPanel"
@
submit=
"handleMultiFormSubmit"
...
...
@@ -39,10 +41,16 @@
:task-name=
"taskName"
:proc-def-id=
"procDefId"
:proc-def-name=
"procDefName"
:form-data=
"formData"
:show-task-info=
"true"
:show-form-data=
"true"
@
success=
"handleSuccess"
:assignee-title=
"assigneeTitle"
:user-type=
"userType"
:assignee=
"assignee"
:deploy-id=
"deployId"
:user-type-options=
"userTypeOptions"
:custom-next-api=
"customNextApi"
:form-data=
"formData"
@
success=
"handlSendSuccess"
@
error=
"handleError"
/>
...
...
@@ -61,22 +69,25 @@
const
dataId
=
ref
(
''
);
const
currentNode
=
ref
<
any
>
({});
const
isShowApprovalPanel
=
ref
(
true
);
const
deployId
=
ref
(
''
);
// 改为动态 ref 对象,存储每个节点的组件实例
const
formComponentRefs
=
ref
<
Map
<
number
,
any
>>
(
new
Map
());
// 任务指派抽屉相关状态
const
drawerTaskVisible
=
ref
(
false
);
const
taskId
=
ref
(
'
task_123456
'
)
const
taskName
=
ref
(
'
部门经理审批
'
)
const
procDefId
=
ref
(
'
process_001
'
)
const
procDefName
=
ref
(
'
请假流程
'
)
const
formData
=
ref
({
申请人
:
'张三'
,
请假类型
:
'年假'
,
开始时间
:
'2024-01-15'
,
结束时间
:
'2024-01-20'
,
请假天数
:
5
,
请假事由
:
'家庭旅游'
})
const
taskId
=
ref
(
''
)
const
taskName
=
ref
(
''
)
const
procDefId
=
ref
(
''
)
const
procDefName
=
ref
(
''
)
const
assignee
=
ref
<
any
>
(
""
);
const
assigneeTitle
=
ref
<
any
>
(
""
);
const
userType
=
ref
<
any
>
(
""
);
const
formData
=
ref
<
any
>
({});
const
userTypeOptions
=
ref
<
any
>
([
{
value
:
'user'
,
label
:
'用户'
}
,
{
value
:
'role'
,
label
:
'角色'
}
]);
const
customNextApi
=
ref
<
any
>
(
null
);
// 抽屉相关状态
...
...
@@ -89,6 +100,21 @@
const
componentCache
=
new
Map
();
const
modules
=
import
.
meta
.
glob
(
'@/views/**/*.vue'
);
// 动态设置 ref 的函数
function
setFormComponentRef
(
el
:
any
,
index
:
number
)
{
if
(
el
)
{
formComponentRefs
.
value
.
set
(
index
,
el
);
}
else
{
formComponentRefs
.
value
.
delete
(
index
);
}
}
// 获取当前活动标签页对应的组件实例
function
getCurrentFormComponent
()
{
const
currentIndex
=
activeTab
.
value
-
1
;
return
formComponentRefs
.
value
.
get
(
currentIndex
);
}
function
handleTabChange
(
key
)
{
activeTab
.
value
=
key
;
currentMultiFormIndex
.
value
=
key
-
1
;
...
...
@@ -147,22 +173,33 @@
const
formData
=
{
dataId
:
data
.
id
,
dataName
:
'id'
};
const
startResRaw
=
await
definitionStartByDeployId
(
currentNode
.
value
?.
deployId
||
''
,
formData
);
if
(
startResRaw
?.
data
?.
id
)
{
dataId
.
value
=
startResRaw
.
data
.
id
;
}
}
const
handleDefinitionSend
=
async
(
data
)
=>
{
drawerTaskVisible
.
value
=
true
;
taskId
.
value
=
data
.
taskId
;
taskName
.
value
=
data
.
taskName
;
procDefId
.
value
=
data
.
procDefId
;
procDefName
.
value
=
data
.
procDefName
;
const
handleDefinitionSend
=
async
(
data
)
=>
{
drawerTaskVisible
.
value
=
true
;
const
nextNode
=
workflowNodes
.
value
[
activeTab
.
value
];
if
(
nextNode
?.
assignee
)
{
assignee
.
value
=
nextNode
.
assignee
;
}
else
{
assignee
.
value
=
''
;
}
deployId
.
value
=
nextNode
?.
deployId
||
''
;
const
attributes
=
nextNode
.
value
?.
attributes
||
{};
const
userTypes
=
attributes
.
userType
||
[];
if
(
userTypes
.
length
>
0
)
{
userType
.
value
=
userTypes
[
0
].
value
||
''
;
}
formData
.
value
=
data
;
}
}
const
handleOpenMultiForm
=
(
params
:
{
nodeIndex
?:
number
;
...
...
@@ -234,10 +271,18 @@ const handleDefinitionSend = async (data) => {
});
};
function handleSuccess(response: any) {
console.log('任务处理成功:', response)
// 刷新列表等操作
}
function handlSendSuccess(dataId: any) {
const currentFormComponent = getCurrentFormComponent();
if (currentFormComponent && typeof currentFormComponent.handleUpdate === 'function') {
currentFormComponent.handleUpdate(dataId);
} else {
console.warn('当前组件实例不存在或没有 handleUpdate 方法');
}
}
function handleError(error: any) {
...
...
@@ -276,27 +321,18 @@ const handleDefinitionSend = async (data) => {
function handleCallback(data: any) {
drawerVisible.value = true;
dataId.value = data.id || '';
currentNode.value = workflowNodes.value[currentMultiFormIndex.value];
currentProcDefId.value = currentNode.value.procDefId || '';
const isApprovalNode = JSON.parse(currentNode.value["isApprove"] || 'false');
if(
currentNode.value.name.indexOf('审') > -1
) {
if(
isApprovalNode
) {
isShowApprovalPanel.value = true;
} else {
isShowApprovalPanel.value = false;
}
const userid = currentNode.value?.assignee || '';
const nodeId = currentNode.value?.id
const procDefId = currentNode.value?.procDefId || '';
const attributes = currentNode.value?.attributes || {};
const userType = attributes.userType || [];
if (userType.length > 0) {
data['userType'] = userType[0].value || '';
}
}
</
script
>
...
...
zrch-risk-client-39/src/views/project/problemCheck/StProblemPlanApprovalList.vue
浏览文件 @
8b5818ac
...
...
@@ -22,7 +22,7 @@
import
{
useModal
}
from
'/@/components/Modal'
;
import
{
useListPage
}
from
'/@/hooks/system/useListPage'
;
import
{
columns
,
searchFormSchema
}
from
'./StProblemCheck.data'
;
import
{
list
}
from
'./StProblemCheck.api'
;
import
{
list
,
saveOrUpdate
}
from
'./StProblemCheck.api'
;
import
StProblemCheckExecuteModal
from
'./components/StProblemCheckExecuteModal.vue'
;
const
props
=
defineProps
({
...
...
@@ -40,7 +40,7 @@
}
})
const
emit
=
defineEmits
([
'callback'
])
const
emit
=
defineEmits
([
'callback'
,
'sendWorkFlow'
])
//注册model
const
[
registerExecuteModal
,
{
openModal
:
openExecuteModal
}]
=
useModal
();
...
...
@@ -51,14 +51,6 @@
api
:
list
,
columns
,
canResize
:
false
,
formConfig
:
{
//labelWidth: 120,
schemas
:
searchFormSchema
,
autoSubmitOnEnter
:
true
,
showAdvancedButton
:
true
,
fieldMapToNumber
:
[],
fieldMapToTime
:
[],
},
beforeFetch
(
params
)
{
params
[
'bmpNodeId'
]
=
props
.
currentFlowNode
.
id
},
...
...
@@ -78,6 +70,10 @@
function
handleSuccess
()
{
(
selectedRowKeys
.
value
=
[])
&&
reload
();
}
function
handleSendNext
(
record
:
Recordable
)
{
emit
(
"sendWorkFlow"
,
record
)
}
function
getTableAction
(
record
)
{
return
[
...
...
@@ -85,9 +81,26 @@
label
:
'计划审核'
,
onClick
:
handlePlanApproval
.
bind
(
null
,
record
),
},
{
label
:
'提交'
,
onClick
:
handleSendNext
.
bind
(
null
,
record
),
},
];
}
async
function
handleUpdate
(
dataId
)
{
await
saveOrUpdate
({
bmpNodeId
:
props
.
nextFlowNode
.
id
,
id
:
dataId
,
},
true
).
then
(
res
=>
{
handleSuccess
();
})
}
defineExpose
({
handleUpdate
,
})
</
script
>
<
style
scoped
></
style
>
zrch-risk-client-39/src/views/project/problemCheck/StProblemPlanList.vue
浏览文件 @
8b5818ac
...
...
@@ -22,7 +22,7 @@
import
{
useModal
}
from
'/@/components/Modal'
;
import
{
useListPage
}
from
'/@/hooks/system/useListPage'
;
import
{
columns
,
searchFormSchema
}
from
'./StProblemCheck.data'
;
import
{
list
}
from
'./StProblemCheck.api'
;
import
{
list
,
saveOrUpdate
}
from
'./StProblemCheck.api'
;
import
StProblemCheckExecuteModal
from
'./components/StProblemCheckExecuteModal.vue'
;
const
emit
=
defineEmits
([
'callback'
,
'sendWorkFlow'
])
...
...
@@ -49,14 +49,6 @@
api
:
list
,
columns
,
canResize
:
false
,
formConfig
:
{
//labelWidth: 120,
schemas
:
searchFormSchema
,
autoSubmitOnEnter
:
true
,
showAdvancedButton
:
true
,
fieldMapToNumber
:
[],
fieldMapToTime
:
[],
},
beforeFetch
(
params
)
{
params
[
'bmpNodeId'
]
=
props
.
currentFlowNode
.
id
},
...
...
@@ -94,6 +86,19 @@
];
}
async
function
handleUpdate
(
dataId
)
{
await
saveOrUpdate
({
bmpNodeId
:
props
.
nextFlowNode
.
id
,
id
:
dataId
,
},
true
).
then
(
res
=>
{
handleSuccess
();
})
}
defineExpose
({
handleUpdate
,
})
</
script
>
...
...
zrch-risk-client-39/src/views/project/problemCheck/components/StProblemCheckExecuteForm.vue
浏览文件 @
8b5818ac
...
...
@@ -13,7 +13,7 @@
import
{
defHttp
}
from
'/@/utils/http/axios'
;
import
{
propTypes
}
from
'/@/utils/propTypes'
;
import
{
getExecuteFormSchema
}
from
'../StProblemCheck.data'
;
import
{
saveOrUpdate
}
from
'../StProblemCheck.api'
;
import
{
saveOrUpdate
,
}
from
'../StProblemCheck.api'
;
export
default
defineComponent
({
name
:
'StProblemCheckForm'
,
...
...
@@ -23,6 +23,8 @@
props
:
{
formData
:
propTypes
.
object
.
def
({}),
formBpm
:
propTypes
.
bool
.
def
(
true
),
dataId
:
propTypes
.
string
.
def
(
''
),
disabled
:
propTypes
.
bool
.
def
(
false
),
},
setup
(
props
)
{
const
[
registerForm
,
{
setFieldsValue
,
setProps
,
getFieldsValue
}]
=
useForm
({
...
...
@@ -33,37 +35,33 @@
});
const
formDisabled
=
computed
(()
=>
{
if
(
props
.
formData
.
disabled
===
false
)
{
if
(
props
.
disabled
===
false
)
{
return
false
;
}
return
true
;
});
let
formData
=
{};
const
queryById
Url
=
'/problem/stProblemCheck/queryById'
;
async
function
initFormData
()
{
let
params
=
{
id
:
props
.
formData
.
dataI
d
};
const
data
=
await
defHttp
.
get
({
url
:
queryById
Url
,
params
});
const
queryById
=
'/problem/stProblemCheck/queryById'
;
async
function
initFormData
(
did
)
{
let
params
=
{
id
:
props
.
dataId
||
di
d
};
const
data
=
await
defHttp
.
get
({
url
:
queryById
,
params
});
formData
=
{
...
data
};
//设置表单的值
await
setFieldsValue
(
formData
);
//默认是禁用
await
setProps
({
disabled
:
formDisabled
.
value
});
}
async
function
submitForm
()
{
let
data
=
getFieldsValue
();
let
params
=
Object
.
assign
({},
formData
,
data
);
console
.
log
(
'表单数据'
,
params
);
await
saveOrUpdate
(
params
,
true
);
}
initFormData
();
initFormData
(
props
.
dataId
);
return
{
registerForm
,
formDisabled
,
submitForm
,
initFormData
};
},
});
...
...
zrch-risk-client-39/src/views/project/problemCheck/components/StProblemCheckForm.vue
浏览文件 @
8b5818ac
...
...
@@ -13,7 +13,7 @@
import
{
defHttp
}
from
'/@/utils/http/axios'
;
import
{
propTypes
}
from
'/@/utils/propTypes'
;
import
{
getBpmFormSchema
}
from
'../StProblemCheck.data'
;
import
{
saveOrUpdate
}
from
'../StProblemCheck.api'
;
import
{
saveOrUpdate
,
}
from
'../StProblemCheck.api'
;
export
default
defineComponent
({
name
:
'StProblemCheckForm'
,
...
...
@@ -24,6 +24,7 @@
formData
:
propTypes
.
object
.
def
({}),
formBpm
:
propTypes
.
bool
.
def
(
true
),
dataId
:
propTypes
.
string
.
def
(
''
),
disabled
:
propTypes
.
bool
.
def
(
false
),
},
setup
(
props
)
{
const
[
registerForm
,
{
setFieldsValue
,
setProps
,
getFieldsValue
}]
=
useForm
({
...
...
@@ -34,31 +35,29 @@
});
const
formDisabled
=
computed
(()
=>
{
if
(
props
.
formData
.
disabled
===
false
)
{
if
(
props
.
disabled
===
false
)
{
return
false
;
}
return
true
;
});
let
formData
=
{};
const
queryById
Url
=
'/problem/stProblemCheck/queryById/
'
;
const
queryById
=
'/problem/stProblemCheck/queryById
'
;
async
function
initFormData
(
did
)
{
let
params
=
{
id
:
props
.
dataId
||
did
};
const
data
=
await
defHttp
.
get
({
url
:
queryById
Url
,
params
});
const
data
=
await
defHttp
.
get
({
url
:
queryById
,
params
});
formData
=
{
...
data
};
//设置表单的值
await
setFieldsValue
(
formData
);
//默认是禁用
await
setProps
({
disabled
:
formDisabled
.
value
});
}
async
function
submitForm
()
{
let
data
=
getFieldsValue
();
let
params
=
Object
.
assign
({},
formData
,
data
);
console
.
log
(
'表单数据'
,
params
);
await
saveOrUpdate
(
params
,
true
);
}
initFormData
(
props
.
dataId
);
return
{
registerForm
,
formDisabled
,
...
...
zrch-risk-client-39/src/views/project/problemCheck/components/StProblemCheckPlanForm.vue
浏览文件 @
8b5818ac
...
...
@@ -12,7 +12,7 @@
import
{
computed
,
defineComponent
}
from
'vue'
;
import
{
defHttp
}
from
'/@/utils/http/axios'
;
import
{
propTypes
}
from
'/@/utils/propTypes'
;
import
{
getPlanFormSchema
,
formSchema
}
from
'../StProblemCheck.data'
;
import
{
getPlanFormSchema
}
from
'../StProblemCheck.data'
;
import
{
saveOrUpdate
,
}
from
'../StProblemCheck.api'
;
export
default
defineComponent
({
...
...
@@ -24,17 +24,18 @@
formData
:
propTypes
.
object
.
def
({}),
formBpm
:
propTypes
.
bool
.
def
(
true
),
dataId
:
propTypes
.
string
.
def
(
''
),
disabled
:
propTypes
.
bool
.
def
(
false
),
},
setup
(
props
)
{
const
[
registerForm
,
{
setFieldsValue
,
setProps
,
getFieldsValue
}]
=
useForm
({
labelWidth
:
150
,
schemas
:
formSchema
,
schemas
:
getPlanFormSchema
(
props
.
formData
)
,
showActionButtonGroup
:
false
,
baseColProps
:
{
span
:
24
},
});
const
formDisabled
=
computed
(()
=>
{
if
(
props
.
formData
.
disabled
===
false
)
{
if
(
props
.
disabled
===
false
)
{
return
false
;
}
return
true
;
...
...
@@ -55,6 +56,10 @@
await
saveOrUpdate
(
params
,
true
);
}
initFormData
(
props
.
dataId
);
return
{
registerForm
,
formDisabled
,
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论