master
xy 2 years ago
parent ee0858fde3
commit 4337d535a3

@ -82,9 +82,14 @@ export default {
<el-form
ref={`expand-form${$index}`}
props={{ model: row._form }}
rules={{
socre: [{ required: true, message: "请输入自评值", trigger: "blur" }],
evaluation_main: [{ required: true, message: "请输入评价要点及评分规则", trigger: "blur" }],
result: [{ required: true, message: "请输入实际完成值", trigger: "blur" }],
}}
label-width="120px"
>
<el-form-item label="评价要点及评分规则">
<el-form-item label="评价要点及评分规则" prop="evaluation_main" required={true}>
<el-input
type="textarea"
autosize={{
@ -96,7 +101,7 @@ export default {
></el-input>
</el-form-item>
<el-form-item label="实际完成值" required={true}>
<el-form-item label="实际完成值" prop="result" required={true}>
<el-input
type="textarea"
autosize={{
@ -108,7 +113,7 @@ export default {
></el-input>
</el-form-item>
<el-form-item label="得分" required={true}>
<el-form-item label="得分" prop="socre" required={true}>
<el-input-number
precision={2}
controls={false}
@ -132,7 +137,7 @@ export default {
></el-input>
</el-form-item>
<el-form-item label="文件">
<el-form-item label="文件" required={true}>
<el-upload
style="width: 300px"
ref={`expand-form-upload${$index}`}
@ -159,7 +164,7 @@ export default {
<div slot="tip" className="el-upload__tip">
支持文件格式.rar .zip .doc .docx .xlsx .pdf .png .jpg
<br />
单个文件不能超过2Mb
单个文件不能超过50Mb
</div>
</el-upload>
</el-form-item>
@ -169,14 +174,25 @@ export default {
type="primary"
on={{
["click"]: (e) => {
row._form.file_ids = row._fileList?.map(i => i.response.id)
save(row._form).then(res => {
this.$message({
type: "success",
message: "操作成功"
})
this.$refs[`expand-form${$index}`].validate((valid) => {
if (valid) {
if (!row._fileList || row._fileList.length === 0) {
this.$message({
type: "warning",
message: "请上传文件",
});
return
}
row._form.file_ids = row._fileList?.map(i => i.response.id)
save(row._form).then(res => {
this.$message({
type: "success",
message: "操作成功"
})
this.getList()
this.getList()
})
}
})
},
}}
@ -264,10 +280,10 @@ export default {
row._fileList = fileList;
},
uploadBefore(file) {
if (file.size / 1024 > 500) {
if ((file.size / 1024 / 1024) > 50) {
this.$message({
type: "warning",
message: "上传文件大小超过500kb",
message: "上传文件大小超过50Mb",
});
return false;
}

@ -12,6 +12,8 @@
</el-form-item>
<el-form-item :label="(type === 1 ? '年中' : '年末') + '绩效目标'">
<el-input :value="type === 1 ? form.year_midst : form.year_end"
type="textarea"
:autosize="{ minRows: 2 }"
placeholder="绩效目标"
@input="e => {
type === 1 ? form.year_midst = e : form.year_end = e
@ -19,6 +21,8 @@
</el-form-item>
<el-form-item :label="(type === 1 ? '年中' : '年末') + '绩效目标完成情况'">
<el-input :value="type === 1 ? form.middle_result : form.end_result"
type="textarea"
:autosize="{ minRows: 2 }"
placeholder="绩效目标完成情况"
@input="e => {
type === 1 ? form.middle_result = e : form.end_result = e
@ -27,8 +31,8 @@
<el-form-item :label="(type === 1 ? '年中' : '年末') + '成效(通过绩效评价总结的成效)'">
<el-input :value="type === 1 ? form.middle_effect : form.end_effect"
type="textarea"
placeholder="(请结合项目年度绩效目标进行阐述,需有真实的数据和事实等材料支撑)"
:autosize="{ minRows: 2 }"
placeholder="(请结合项目年度绩效目标进行阐述,需有真实的数据和事实等材料支撑)"
@input="e => {
type === 1 ? form.middle_effect = e : form.end_effect = e
}"></el-input>
@ -119,9 +123,9 @@ export default {
submit() {
this.form.id = this.id
if (this.type === 1) {
this.form.year_middle_audit = (this.form.year_middle_audit && this.form.year_middle_audit < 0) ? Math.abs(this.form.year_middle_audit) : 1
this.form.year_middle_audit = (this.form.year_middle_audit && this.form.year_middle_audit < 0) ? Math.abs(this.form.year_middle_audit) : 0
} else {
this.form.year_end_audit = (this.form.year_end_audit && this.form.year_end_audit < 0) ? Math.abs(this.form.year_end_audit) : 1
this.form.year_end_audit = (this.form.year_end_audit && this.form.year_end_audit < 0) ? Math.abs(this.form.year_end_audit) : 0
}
editorBudget({
...this.form,

@ -45,17 +45,17 @@
<!-- 实际支出数-->
<!-- </th>-->
<!-- </tr>-->
<tr v-for="(item, index) in contractList">
<td colspan="2">
{{ item.name }}
</td>
<td colspan="3">
{{ item.plan_price }}
</td>
<td colspan="2">
{{ item.money}}
</td>
</tr>
<!-- <tr v-for="(item, index) in contractList">-->
<!-- <td colspan="2">-->
<!-- {{ item.name }}-->
<!-- </td>-->
<!-- <td colspan="3">-->
<!-- {{ item.plan_price }}-->
<!-- </td>-->
<!-- <td colspan="2">-->
<!-- {{ item.money}}-->
<!-- </td>-->
<!-- </tr>-->
<tr>
<th>一级指标</th>
<th>二级指标</th>
@ -175,7 +175,7 @@ export default {
},
async getPlanTarget() {
const list = (await index({ plan_id: this.planId },true)).data
const list = (await index({ plan_id: this.planId },true))?.data?.sort((a,b) => a.target.target_type_id - b.target.target_type_id)
this.pos = this.pos1 = 0;
this.spanArr = [];
this.spanArr1 = [];

@ -57,7 +57,9 @@
width="260"
>
<template v-slot:default="scope">
<el-dropdown @command="command => {
<template v-if="!(scope.row.year_middle_audit > 0) || !(scope.row.year_end_audit > 0)">
<el-dropdown
@command="command => {
if (command === 'yearMiddle') {
$refs['addPlanEvaluate'].type = 1;
$refs['addPlanEvaluate'].setPlanId(scope.row.id);
@ -68,16 +70,19 @@
$refs['addPlanEvaluate'].show();
}
}">
<Button style="margin-left: 4px;" size="small" type="primary">
填报绩效指标<i class="el-icon-arrow-down el-icon--right"></i>
</Button>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item command="yearMiddle">填报年中绩效指标</el-dropdown-item>
<el-dropdown-item command="yearEnd">填报年末绩效指标</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
<Button style="margin-left: 4px;" size="small" type="primary">
填报绩效指标<i class="el-icon-arrow-down el-icon--right"></i>
</Button>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item command="yearMiddle" v-if="!(scope.row.year_middle_audit > 0)"></el-dropdown-item>
<el-dropdown-item command="yearEnd" v-if="!(scope.row.year_end_audit > 0)"></el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</template>
<el-dropdown @command="command => {
<template v-if="!(scope.row.year_middle_audit > 0) || !(scope.row.year_end_audit > 0)">
<el-dropdown
@command="command => {
if (command === 'yearMiddle') {
$refs['addSelfEvaluationForm'].setId(scope.row.id);
$refs['addSelfEvaluationForm'].setType(1);
@ -88,18 +93,19 @@
$refs['addSelfEvaluationForm'].show();
}
}">
<Button style="margin-left: 4px;" size="small" type="primary">
填报自评表<i class="el-icon-arrow-down el-icon--right"></i>
</Button>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item command="yearMiddle">
<span :style="{'color': scope.row.year_middle_audit < 0 ? 'red' : '' }">填报年中自评表</span>
</el-dropdown-item>
<el-dropdown-item command="yearEnd">
<span :style="{'color': scope.row.year_end_audit < 0 ? 'red' : '' }">填报年末自评表</span>
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
<Button style="margin-left: 4px;" size="small" type="primary">
填报自评表<i class="el-icon-arrow-down el-icon--right"></i>
</Button>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item command="yearMiddle" v-if="!(scope.row.year_middle_audit > 0)">
<span :style="{'color': scope.row.year_middle_audit < 0 ? 'red' : '' }">填报年中自评表</span>
</el-dropdown-item>
<el-dropdown-item command="yearEnd" v-if="!(scope.row.year_end_audit > 0)">
<span :style="{'color': scope.row.year_end_audit < 0 ? 'red' : '' }">填报年末自评表</span>
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</template>
<el-dropdown @command="command => {
if (command === 'yearMiddle') {
@ -124,6 +130,22 @@
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
<template v-if="scope.row.year_middle_audit === 0 || scope.row.year_end_audit === 0">
<el-dropdown @command="command => sendExamine(command,scope.row)">
<Button style="margin-left: 4px;" size="small" type="primary">
送审<i class="el-icon-arrow-down el-icon--right"></i>
</Button>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item command="yearMiddle" v-if="scope.row.year_middle_audit === 0">
<span>送审年中绩效</span>
</el-dropdown-item>
<el-dropdown-item command="yearEnd" v-if="scope.row.year_end_audit === 0">
<span>送审年末绩效</span>
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</template>
</template>
</el-table-column>
</template>
@ -151,7 +173,7 @@
</template>
<script>
import { getBudget } from "@/api/budget/budget";
import { getBudget, editorBudget } from "@/api/budget/budget";
import { index, destroy } from "@/api/achievements/evaluate";
import { moneyFormatter, parseTime } from "@/utils";
import { getparameter } from "@/api/system/dictionary";
@ -249,6 +271,112 @@ export default {
align: "left",
sortable: false,
},
{
label: "年中绩效审核状态",
multiHd: [
{
label: "部门负责人",
prop: "year_middle_audit",
customFn: row => {
const val = row.year_middle_audit
if (val === -1) {
return (<span style="color: red;">驳回</span>)
}
else if (val > 1 || val < -1) {
return (<span style="color: green;">通过</span>)
} else {
return '待审核'
}
},
width: 120
},
{
label: "分管领导",
prop: "year_middle_audit",
customFn: row => {
const val = row.year_middle_audit
if (val === -2) {
return (<span style="color: red;">驳回</span>)
}
else if (val > 2 || val < -2) {
return (<span style="color: green;">通过</span>)
} else {
return '待审核'
}
},
width: 120
},
{
label: "财务",
prop: "year_middle_audit",
customFn: row => {
const val = row.year_middle_audit
if (val === -3) {
return (<span style="color: red;">驳回</span>)
}
else if (val > 3) {
return (<span style="color: green;">通过</span>)
} else {
return '待审核'
}
},
width: 120
}
]
},
{
label: "年末绩效审核状态",
multiHd: [
{
label: "部门负责人",
prop: "year_end_audit",
customFn: row => {
const val = row.year_end_audit
if (val === -1) {
return (<span style="color: red;">驳回</span>)
}
else if (val > 1 || val < -1) {
return (<span style="color: green;">通过</span>)
} else {
return '待审核'
}
},
width: 120
},
{
label: "分管领导",
prop: "year_end_audit",
customFn: row => {
const val = row.year_end_audit
if (val === -2) {
return (<span style="color: red;">驳回</span>)
}
else if (val > 2 || val < -2) {
return (<span style="color: green;">通过</span>)
} else {
return '待审核'
}
},
width: 120
},
{
label: "财务",
prop: "year_end_audit",
customFn: row => {
const val = row.year_end_audit
if (val === -3) {
return (<span style="color: red;">驳回</span>)
}
else if (val > 3) {
return (<span style="color: green;">通过</span>)
} else {
return '待审核'
}
},
width: 120
}
]
},
{
label: "自评意见",
width: 100,
@ -271,6 +399,35 @@ export default {
};
},
methods: {
sendExamine (command, row) {
this.$confirm("确认要送审?","提示",{
}).then(_ => {
if (command === 'yearMiddle') {
editorBudget({
id: row.id,
year_middle_audit: 1
}).then((res) => {
this.$message({
type: "success",
message: "送审成功",
});
this.getList();
})
} else {
editorBudget({
id: row.id,
year_end_audit: 1
}).then((res) => {
this.$message({
type: "success",
message: "送审成功",
});
this.getList();
})
}
})
},
async getBudgetTypes() {
const res = await getparameter({
number: "money_way",

@ -170,11 +170,25 @@ export default {
label: "半年(程)指标值",
prop: "target.half_target",
width: 180,
customFn: row => {
if (row.target?.unit_detail?.value !== '无') {
return `${row.target?.symbol_detail?.value}${row.target?.half_target}${row.target?.unit_detail?.value}`
} else {
return row.target?.half_target
}
}
},
{
label: "全年(程)指标值",
prop: "target.year_target",
width: 180,
customFn: row => {
if (row.target?.unit_detail?.value !== '无') {
return `${row.target?.symbol_detail?.value}${row.target?.year_target}${row.target?.unit_detail?.value}`
} else {
return row.target?.year_target
}
}
},
{
label: "创建时间",

@ -99,7 +99,7 @@
>
<div slot="tip" class="el-upload__tip">
支持文件格式.rar .zip .doc .docx .pdf
<br />单个文件不能超过500kb
<br />单个文件不能超过2Mb
</div>
</el-upload>
</div>
@ -188,10 +188,10 @@ export default {
},
uploadBefore(file) {
console.log(file);
if (file.size / 1000 > 500) {
if ((file.size / 1024 / 1024) > 2) {
this.$message({
type: "warning",
message: "上传文件大小超过500kb",
message: "上传文件大小超过2Mb",
});
return false;
}

Loading…
Cancel
Save