Merge remote-tracking branch 'origin/master'

# Conflicts:
#	src/views/workflow/process/nodes/Node.vue
This commit is contained in:
2024-05-12 15:15:48 +08:00
2 changed files with 22 additions and 7 deletions

View File

@@ -68,7 +68,7 @@
<!-- </el-col>-->
<!-- </el-row>-->
</el-form>
<div class="oper-page-btn" v-if="processInstanceData.taskId">
<div class="oper-page-btn" v-if="processInstanceData.state === '1' && processInstanceData.taskId">
<el-button @click="handleReject">驳回</el-button>
<el-button color="#DED0B2" @click="handleSubmit">同意</el-button>
</div>

View File

@@ -73,7 +73,7 @@ const tableConfig = reactive({
prop: 'state',
label: '状态',
align: 'center',
width:200,
width: 200,
showOverflowTooltip: false,
currentRender: ({row, index}) => (<Tag dictType={'process_state'} value={row.state}/>)
},
@@ -83,12 +83,27 @@ const tableConfig = reactive({
align: 'center',
showOverflowTooltip: false,
currentRender: ({row, index}) => {
let btn = [{label: '详情', func: () => handleDetail(row), type: 'primary'}]
if (row.state === '3' || row.state === '2') {
btn.push({label: '编辑', func: () => handleEdit(row), type: 'primary'})
btn.push({label: '删除', func: () => handleDel(row), type: 'danger'})
}else if (row.state === '4'){
btn.push({label: '上报', func: () => handleReport(row), type: 'primary'})
}
return (
<div>
<el-button type="primary" link onClick={() => handleDetail(row)}>详情
</el-button>
<el-button type="primary" link onClick={() => handleEdit(row)}>编辑</el-button>
<el-button type="primary" link onClick={() => handleReport(row)}>上报</el-button>
<div style={{width: '100%'}}>
{
btn.map(item => (
<el-button
type={item.type}
// v-perm={item.auth}
onClick={() => item.func()}
link
>
{item.label}
</el-button>
))
}
</div>
)
}