This commit is contained in:
bb_pan 2025-12-02 16:35:39 +08:00
parent 1537811346
commit 03c9c8952e
7 changed files with 42 additions and 32 deletions

View File

@ -2,7 +2,7 @@
<!-- 基础页面 --> <!-- 基础页面 -->
<div class="app-container"> <div class="app-container">
<el-card v-show="showSearch" style="margin-bottom: 20px"> <el-card v-show="showSearch" style="margin-bottom: 20px">
<el-form :model="queryParams" ref="queryForm" size="small" inline label-width="100px"> <el-form :model="queryParams" ref="queryForm" size="small" inline label-width="110px">
<el-form-item label="需求单位" prop="useUnit"> <el-form-item label="需求单位" prop="useUnit">
<el-input v-model="queryParams.useUnit" style="width: 200px" placeholder="请输入需求单位" :disabled="queryParams.status=='0'" <el-input v-model="queryParams.useUnit" style="width: 200px" placeholder="请输入需求单位" :disabled="queryParams.status=='0'"

View File

@ -102,9 +102,10 @@
<el-table-column label="退库工具数" align="center" prop="toolNum" :show-overflow-tooltip="true"/> <el-table-column label="退库工具数" align="center" prop="toolNum" :show-overflow-tooltip="true"/>
<el-table-column label="任务状态" align="center" prop="taskStatus" :show-overflow-tooltip="true"> <el-table-column label="任务状态" align="center" prop="taskStatus" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag v-if="scope.row.taskStatus == '0'" type="warning">待审核</el-tag> <el-tag v-if="scope.row.taskStatus == '0'" type="info">待审批</el-tag>
<el-tag v-if="scope.row.taskStatus == '1'" type="success">已通过</el-tag> <el-tag v-if="scope.row.taskStatus == '1'" type="warning">审批中</el-tag>
<el-tag v-if="scope.row.taskStatus == '2'" type="danger">已驳回</el-tag> <el-tag v-if="scope.row.taskStatus == '2'" type="success">已审批</el-tag>
<el-tag v-if="scope.row.taskStatus == '3'" type="danger">审批驳回</el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="申请人" align="center" prop="createBy" :show-overflow-tooltip="true" width="140px"/> <el-table-column label="申请人" align="center" prop="createBy" :show-overflow-tooltip="true" width="140px"/>
@ -155,9 +156,10 @@ export default {
endTime: null endTime: null
}, },
statusList: [ statusList: [
{ label: '待审核', value: '0' }, { label: '待审批', value: '0' },
{ label: '已通过', value: '1' }, { label: '审批中', value: '1' },
{ label: '已驳回', value: '2' } { label: '已审批', value: '2' },
{ label: '审批驳回', value: '3' },
], ],
total: 0, // total: 0, //
// //

View File

@ -2,7 +2,7 @@
<!-- 基础页面 --> <!-- 基础页面 -->
<div class="app-container"> <div class="app-container">
<el-card v-show="showSearch" style="margin-bottom: 20px"> <el-card v-show="showSearch" style="margin-bottom: 20px">
<el-form :model="queryParams" ref="queryForm" :rules="outFormRules" inline label-width="100px"> <el-form :model="queryParams" ref="queryForm" :rules="outFormRules" inline label-width="110px">
<el-form-item label="需求单位" prop="useUnit"> <el-form-item label="需求单位" prop="useUnit">
<el-select <el-select
v-model="queryParams.useUnit" v-model="queryParams.useUnit"

View File

@ -107,9 +107,10 @@
<el-table-column label="退库工具数" align="center" prop="toolNum" :show-overflow-tooltip="true"/> <el-table-column label="退库工具数" align="center" prop="toolNum" :show-overflow-tooltip="true"/>
<el-table-column label="任务状态" align="center" prop="taskStatus" :show-overflow-tooltip="true"> <el-table-column label="任务状态" align="center" prop="taskStatus" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag v-if="scope.row.taskStatus == '0'" type="warning">待审核</el-tag> <el-tag v-if="scope.row.taskStatus == '0'" type="info">待审批</el-tag>
<el-tag v-if="scope.row.taskStatus == '1'" type="success">已通过</el-tag> <el-tag v-if="scope.row.taskStatus == '1'" type="warning">审批中</el-tag>
<el-tag v-if="scope.row.taskStatus == '2'" type="danger">已驳回</el-tag> <el-tag v-if="scope.row.taskStatus == '2'" type="success">已审批</el-tag>
<el-tag v-if="scope.row.taskStatus == '3'" type="danger">审批驳回</el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="申请人" align="center" prop="createBy" :show-overflow-tooltip="true" width="140px"/> <el-table-column label="申请人" align="center" prop="createBy" :show-overflow-tooltip="true" width="140px"/>
@ -167,9 +168,10 @@ export default {
useUnit: null useUnit: null
}, },
statusList: [ statusList: [
{ label: '待审核', value: '0' }, { label: '待审批', value: '0' },
{ label: '已通过', value: '1' }, { label: '审批中', value: '1' },
{ label: '已驳回', value: '2' } { label: '已审批', value: '2' },
{ label: '审批驳回', value: '3' },
], ],
total: 0, // total: 0, //
// //

View File

@ -80,9 +80,13 @@
<!-- 手动添加状态列 --> <!-- 手动添加状态列 -->
<el-table-column label="任务状态" align="center"> <el-table-column label="任务状态" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag :type="getStatusType(scope.row.status)"> <!-- <el-tag :type="getStatusType(scope.row.status)">
{{ getStatusLabel(scope.row.status) }} {{ getStatusLabel(scope.row.status) }}
</el-tag> </el-tag> -->
<el-tag v-if="scope.row.status == '0'" type="info">待审批</el-tag>
<el-tag v-if="scope.row.status == '1'" type="warning">审批中</el-tag>
<el-tag v-if="scope.row.status == '2'" type="success">已审批</el-tag>
<el-tag v-if="scope.row.status == '3'" type="danger">审批驳回</el-tag>
</template> </template>
</el-table-column> </el-table-column>
@ -129,11 +133,10 @@ export default {
endTime: null, endTime: null,
}, },
statusList: [ statusList: [
{ label: '待审核', value: '待审核' }, { label: '待审批', value: '0' },
{ label: '审核中', value: '审核中' }, { label: '审批中', value: '1' },
{ label: '驳回待处理', value: '驳回待处理' }, { label: '已审批', value: '2' },
{ label: '全部通过', value: '全部通过' }, { label: '审批驳回', value: '3' },
{ label: '全部驳回', value: '全部驳回' },
], ],
statusTextMap: { statusTextMap: {
'1': '待审核', '1': '待审核',
@ -169,7 +172,7 @@ export default {
return { return {
...item, // item ...item, // item
// status // status
status: this.statusTextMap[item.status] || '未知状态' // status: this.statusTextMap[item.status] || ''
}; };
}); });
} }

View File

@ -59,7 +59,7 @@
<span v-else></span> <span v-else></span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="状态" align="center" prop="status" width="90"> <!-- <el-table-column label="状态" align="center" prop="status" width="90">
<template #default="scope"> <template #default="scope">
<el-tag <el-tag
:type="scope.row.status === '通过' ? 'success' : scope.row.status === '驳回' ? 'danger' : 'warning'" :type="scope.row.status === '通过' ? 'success' : scope.row.status === '驳回' ? 'danger' : 'warning'"
@ -68,7 +68,7 @@
{{ scope.row.status }} {{ scope.row.status }}
</el-tag> </el-tag>
</template> </template>
</el-table-column> </el-table-column> -->
</el-table> </el-table>
</el-card> </el-card>

View File

@ -77,9 +77,13 @@
<!-- 手动添加状态列 --> <!-- 手动添加状态列 -->
<el-table-column label="任务状态" align="center"> <el-table-column label="任务状态" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag :type="getStatusType(scope.row.status)"> <!-- <el-tag :type="getStatusType(scope.row.status)">
{{ getStatusLabel(scope.row.status) }} {{ getStatusLabel(scope.row.status) }}
</el-tag> </el-tag> -->
<el-tag v-if="scope.row.status == '0'" type="info">待审批</el-tag>
<el-tag v-if="scope.row.status == '1'" type="warning">审批中</el-tag>
<el-tag v-if="scope.row.status == '2'" type="success">已审批</el-tag>
<el-tag v-if="scope.row.status == '3'" type="danger">审批驳回</el-tag>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" align="center"> <el-table-column label="操作" align="center">
@ -122,11 +126,10 @@ export default {
endTime: null, endTime: null,
}, },
statusList: [ statusList: [
{ label: '待审核', value: '待审核' }, { label: '待审批', value: '0' },
{ label: '审核中', value: '审核中' }, { label: '审批中', value: '1' },
{ label: '驳回待处理', value: '驳回待处理' }, { label: '已审批', value: '2' },
{ label: '全部通过', value: '全部通过' }, { label: '审批驳回', value: '3' },
{ label: '全部驳回', value: '全部驳回' },
], ],
statusTextMap: { statusTextMap: {
'1': '待审核', '1': '待审核',
@ -162,7 +165,7 @@ export default {
return { return {
...item, // item ...item, // item
// status // status
status: this.statusTextMap[item.status] || '未知状态' // status: this.statusTextMap[item.status] || ''
}; };
}); });
} }