人效管理-绩效管理-绩效填报-任务行-审批-问题修复

dev-scheduling
ysn 1 month ago
parent 76fd83bd2c
commit fdaf6cf915
  1. 96
      src/views/personnelEfficiencyManagement/performanceManagement/dataReporting.vue

@ -19,7 +19,13 @@
@on-load="onLoad" @on-load="onLoad"
> >
<template #menu-left> <template #menu-left>
<el-button type="primary" @click="maintenanceContents" v-if="permission.maintenance_perf_maintenance"> 绩效内容维护 </el-button> <el-button
type="primary"
@click="maintenanceContents"
v-if="permission.maintenance_perf_maintenance"
>
绩效内容维护
</el-button>
</template> </template>
<template #status="scope"> <template #status="scope">
<el-tag <el-tag
@ -42,9 +48,10 @@
<template #menu="scope"> <template #menu="scope">
<el-button <el-button
v-if=" v-if="
(scope.row.status == 1 && (scope.row.parentId === 0 || scope.row.parentId === null) && permission.main_task_download) (scope.row.status == 1 &&
|| (scope.row.parentId === 0 || scope.row.parentId === null) &&
(scope.row.status == 2 && permission.subtask_download) permission.main_task_download) ||
(scope.row.status == 2 && permission.subtask_download)
" "
type="text" type="text"
@click="downloadTask(scope.row)" @click="downloadTask(scope.row)"
@ -53,24 +60,34 @@
</el-button> </el-button>
<el-button <el-button
v-if=" v-if="
((scope.row.parentId === 0 || scope.row.parentId === null) && scope.row.status == 1 && permission.main_task_reporting) ((scope.row.parentId === 0 || scope.row.parentId === null) &&
|| scope.row.status == 1 &&
(scope.row.parentId && scope.row.status == 1 && permission.subtask_reporting) permission.main_task_reporting) ||
|| (scope.row.parentId && scope.row.status == 1 && permission.subtask_reporting) ||
((scope.row.parentId === 0 || scope.row.parentId === null) && scope.row.status == 5 && permission.main_task_reporting)" ((scope.row.parentId === 0 || scope.row.parentId === null) &&
scope.row.status == 5 &&
permission.main_task_reporting)
"
type="text" type="text"
@click="fillRow(scope.row)" @click="fillRow(scope.row)"
> >
填报 填报
</el-button> </el-button>
<el-button <el-button
v-if="(scope.row.status == 3 || scope.row.status == 4 || scope.row.status == 5) && permission.main_task_detail" v-if="
(scope.row.status == 3 || scope.row.status == 4 || scope.row.status == 5) &&
permission.main_task_detail
"
type="text" type="text"
@click="detailRow(scope.row)" @click="detailRow(scope.row)"
> >
详情 详情
</el-button> </el-button>
<el-button v-if="scope.row.status == 3 && permission.main_task_examine" type="text" @click="examineRow(scope.row)"> <el-button
v-if="scope.row.status == 3 && permission.main_task_examine"
type="text"
@click="examineRow(scope.row)"
>
审批 审批
</el-button> </el-button>
<el-button <el-button
@ -81,7 +98,12 @@
删除 删除
</el-button> </el-button>
<el-button <el-button
v-if="scope.row.parentId && scope.row.status == 2 && scope.row.parentStatus == 1 && permission.subtask_reset" v-if="
scope.row.parentId &&
scope.row.status == 2 &&
scope.row.parentStatus == 1 &&
permission.subtask_reset
"
type="text" type="text"
@click="resetTaskDetail(scope.row)" @click="resetTaskDetail(scope.row)"
> >
@ -105,7 +127,23 @@
:type="'1'" :type="'1'"
/> />
<el-dialog append-to-body title="审批" v-model="showExamine" width="85%"> <el-dialog append-to-body title="审批" v-model="showExamine" width="85%">
<avue-form :option="examineOption" v-model="examineForm" ref="examineForm" /> <!-- 👇 这里全部换成原生 Element UI -->
<el-form :model="examineForm" :rules="rules" ref="examineFormRef" label-width="100px">
<el-form-item label="审批结果" prop="result">
<el-radio-group v-model="examineForm.result">
<el-radio label="1">通过</el-radio>
<el-radio label="2">不通过</el-radio>
</el-radio-group>
</el-form-item>
<el-form-item label="审批意见" prop="remark">
<el-input
v-model="examineForm.remark"
type="textarea"
:rows="3"
placeholder="请输入审批意见"
></el-input>
</el-form-item>
</el-form>
<template #footer> <template #footer>
<span class="dialog-footer"> <span class="dialog-footer">
<el-button @click="closeExamine"> </el-button> <el-button @click="closeExamine"> </el-button>
@ -153,31 +191,11 @@ export default {
showDetail: false, showDetail: false,
showExamine: false, showExamine: false,
examineForm: { examineForm: {
result: '', result: '1',
remark: '', remark: '',
}, },
examineOption: { rules: {
submitBtn: false, result: [{ required: true, message: '请选择审批结果', trigger: 'change' }],
emptyBtn: false,
column: [
{
label: '审批结果',
prop: 'result',
type: 'radio',
dicData: [
{ label: '通过', value: '1' },
{ label: '不通过', value: '2' },
],
span: 24,
rules: [{ required: true, message: '请选择审批结果', trigger: 'blur' }],
},
{
label: '审批意见',
prop: 'remark',
type: 'textarea',
span: 24,
},
],
}, },
loading: false, loading: false,
data: [], data: [],
@ -343,6 +361,10 @@ export default {
}, },
// //
examineRow(row) { examineRow(row) {
this.examineForm = {
result: '1',
remark: '',
};
this.currentRow = row; this.currentRow = row;
this.showExamine = true; this.showExamine = true;
}, },
@ -443,7 +465,7 @@ export default {
handleApproval() { handleApproval() {
if (!this.currentRow) return; if (!this.currentRow) return;
// //
this.$refs.examineForm.validate(valid => { this.$refs.examineFormRef.validate(valid => {
if (valid) { if (valid) {
if (this.examineForm.result === '1') { if (this.examineForm.result === '1') {
this.approvalRow(this.currentRow); this.approvalRow(this.currentRow);

Loading…
Cancel
Save