Compare commits

...

2 Commits

Author SHA1 Message Date
BianLzhaoMin 2a284b8d52 合并冲突 2024-05-14 15:54:22 +08:00
BianLzhaoMin 5316d97e2b 优化权限数据流程 2024-05-14 15:53:42 +08:00
9 changed files with 1230 additions and 632 deletions

View File

@ -93,6 +93,7 @@
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['picking:auditing']"
>新建</el-button
>
</el-col>
@ -195,6 +196,7 @@
align="center"
prop="taskName"
:show-overflow-tooltip="true"
width="120px"
/>
<el-table-column
label="审批意见 "

View File

@ -61,7 +61,12 @@
@selection-change="handleSelectionChange"
>
<!-- <el-table-column type="selection" width="55" align="center" />-->
<el-table-column label="序号" align="center" width="80" type="index" />
<el-table-column
label="序号"
align="center"
width="80"
type="index"
/>
<el-table-column
label="类型名称"
align="center"
@ -300,438 +305,465 @@
</template>
<script>
import {
listType,
getType,
delType,
addType,
updateType,
refreshCache,
} from '@/api/system/dict/type'
import {
auditLeaseByCompany,
getLeaseListAll,
rejectLeaseByCompany,
} from '@/api/claimAndRefund/receive'
import { mapState } from 'vuex'
export default {
name: 'receiveExamine',
data() {
return {
flowPath: [
{
id: 30,
name: '待分公司审核',
remarkKey: 'companyAuditRemark',
authorKey: 'companyAuditBy',
timeKey: 'companyAuditTime',
},
{
id: 31,
name: '待分管部门审核',
remarkKey: 'deptAuditRemark',
authorKey: 'deptAuditBy',
timeKey: 'deptAuditTime',
},
{
id: 32,
name: '待内部审核',
remarkKey: 'directAuditRemark',
authorKey: 'directAuditBy',
timeKey: 'directAuditTime',
},
],
isView: false,
examineVisible: false,
refuseVisible: false,
//
loading: false,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
typeList: [],
//
title: '',
//
open: false,
//
dateRange: [],
//
queryParams: {
leaseApplyInfo: {},
leaseApplyDetails: [],
companyAuditRemarks: '',
import {
listType,
getType,
delType,
addType,
updateType,
refreshCache,
} from '@/api/system/dict/type'
import {
auditLeaseByCompany,
getLeaseListAll,
rejectLeaseByCompany,
} from '@/api/claimAndRefund/receive'
import { mapState } from 'vuex'
export default {
name: 'receiveExamine',
data() {
return {
flowPath: [
{
id: 30,
name: '待分公司审核',
remarkKey: 'companyAuditRemark',
authorKey: 'companyAuditBy',
timeKey: 'companyAuditTime',
},
//
form: {},
//
rules: {
dictName: [
{
required: true,
message: '字典名称不能为空',
trigger: 'blur',
},
],
dictType: [
{
required: true,
message: '字典类型不能为空',
trigger: 'blur',
},
],
},
peopleOpen: false,
noticeOpen: false,
nform: {
notice: '',
},
nrules: {
notice: [
{
required: true,
message: '通知内容不能为空',
trigger: 'blur',
},
],
},
deptName: undefined,
activities: [
{
content: '小洁发起申请',
timestamp: '2018-04-15',
},
{
content: '分公司审批',
timestamp: '2018-04-13',
},
{
content: '部门审批',
timestamp: '2018-04-11',
},
],
}
},
computed: {
...mapState(['user']),
},
mounted() {
let taskId = this.$route.query.taskId
let isView = this.$route.query.isView
this.isView = false
if (isView) {
this.isView = true
}
console.log(isView)
if (taskId) {
this.getData(taskId)
}
},
methods: {
agree() {
this.examineVisible = true
this.queryParams.companyAuditRemarks = '同意'
// {
// id: 31,
// name: '',
// remarkKey: 'deptAuditRemark',
// authorKey: 'deptAuditBy',
// timeKey: 'deptAuditTime',
// },
// {
// id: 32,
// name: '',
// remarkKey: 'directAuditRemark',
// authorKey: 'directAuditBy',
// timeKey: 'directAuditTime',
// },
],
isView: false,
examineVisible: false,
refuseVisible: false,
//
loading: false,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
typeList: [],
//
title: '',
//
open: false,
//
dateRange: [],
//
queryParams: {
leaseApplyInfo: {},
leaseApplyDetails: [],
companyAuditRemarks: '',
},
// handelExamine(type){
// if(type){
// this.subAuditLeaseByCompany()
// }else {
// this.queryParams.companyAuditRemarks = ''
// }
// this.examineVisible = type
// },
//
async subAuditLeaseByCompany(type) {
console.log(type)
const params = JSON.parse(JSON.stringify(this.queryParams))
params.taskStatus = params.taskStatus + 1
//
form: {},
//
rules: {
dictName: [
{
required: true,
message: '字典名称不能为空',
trigger: 'blur',
},
],
dictType: [
{
required: true,
message: '字典类型不能为空',
trigger: 'blur',
},
],
},
peopleOpen: false,
noticeOpen: false,
nform: {
notice: '',
},
nrules: {
notice: [
{
required: true,
message: '通知内容不能为空',
trigger: 'blur',
},
],
},
deptName: undefined,
activities: [
{
content: '小洁发起申请',
timestamp: '2018-04-15',
},
{
content: '分公司审批',
timestamp: '2018-04-13',
},
{
content: '部门审批',
timestamp: '2018-04-11',
},
],
params.leaseApplyInfoList.forEach((v) => {
console.log(v)
/* 判断当前设备属于是否属于机具分公司 */
isMachinery: true,
}
},
computed: {
...mapState(['user']),
},
mounted() {
let taskId = this.$route.query.taskId
let isView = this.$route.query.isView
this.isView = false
if (isView) {
this.isView = true
}
console.log(isView)
if (taskId) {
this.getData(taskId)
}
},
methods: {
agree() {
this.examineVisible = true
this.queryParams.companyAuditRemarks = '同意'
},
// handelExamine(type){
// if(type){
// this.subAuditLeaseByCompany()
// }else {
// this.queryParams.companyAuditRemarks = ''
// }
// this.examineVisible = type
// },
//
async subAuditLeaseByCompany(type) {
const params = JSON.parse(JSON.stringify(this.queryParams))
params.taskStatus = params.taskStatus + 1
params.leaseApplyInfoList.forEach((v) => {
console.log(v)
this.$set(v, 'companyAuditRemark', params.companyAuditRemarks)
this.$set(v, 'companyAuditBy', this.user.id)
if (!this.isMachinery && type == 9) {
this.$set(
v,
'companyAuditRemark',
params.companyAuditRemarks,
'examineStatusId',
Number(params.examineStatusId) + 1,
)
this.$set(v, 'companyAuditBy', this.user.id)
} else {
this.$set(
v,
'examineStatusId',
Number(params.examineStatusId),
)
this.$set(v, 'status', type)
})
params.updateTime = params.updateTimes
params.createTime = params.createTimes
console.log(params)
const res = await auditLeaseByCompany(params)
if (res.code == 200) {
this.examineVisible = false
this.$tab.closeOpenPage({
path: '/claimAndRefund/receive/receiveManage',
})
}
console.log('subAuditLeaseByCompany ==================', res)
},
//
refuse() {
this.refuseVisible = true
this.queryParams.companyAuditRemarks = '驳回'
},
// handelRefuse(type){
// if (this.queryParams.companyAuditRemarks=='') {
// this.$message.error('');
// return;
// }
// if(type){
// this.refuseAuditLeaseByCompany()
// }else {
// this.queryParams.companyAuditRemarks = ''
// }
// this.refuseVisible = type
// },
//
async refuseAuditLeaseByCompany(type) {
const params = JSON.parse(JSON.stringify(this.queryParams))
if (params.taskStatus == 30) {
params.taskStatus = 98
params.examineStatusId = 98
}
if (params.taskStatus == 31) {
params.taskStatus = 99
params.examineStatusId = 99
}
if (params.taskStatus == 32) {
params.taskStatus = 100
params.examineStatusId = 100
}
params.updateTime = params.updateTimes
params.createTime = params.createTimes
params.leaseApplyInfoList.forEach((v) => {
this.$set(
v,
'companyAuditRemark',
params.companyAuditRemarks,
)
this.$set(v, 'companyAuditBy', this.user.id)
this.$set(
v,
'examineStatusId',
Number(params.examineStatusId),
)
this.$set(v, 'status', type)
})
console.log(params)
const res = await rejectLeaseByCompany(params)
if (res.code == 200) {
this.examineVisible = false
this.$tab.closeOpenPage({
path: '/claimAndRefund/receive/receiveManage',
})
}
console.log('subAuditLeaseByCompany ==================', res)
},
/** 修改按钮操作 */
handleBack(row) {
this.$set(v, 'status', type)
})
params.updateTime = params.updateTimes
params.createTime = params.createTimes
/* 如果为调试分公司机具 参数修改 直接跳过分管部门审核 */
if (!this.isMachinery && type == 9) {
params.taskStatus = 32
}
console.log(params,'审核参数',type)
const res = await auditLeaseByCompany(params)
if (res.code == 200) {
this.examineVisible = false
this.$tab.closeOpenPage({
path: '/claimAndRefund/receive/receiveManage',
})
},
/** 查询 */
async getData(taskId) {
const res = await getLeaseListAll({
taskId,
})
this.queryParams = { ...this.queryParams, ...res.rows[0] }
this.$set(
this.queryParams,
'leaseApplyInfo',
this.queryParams.leaseApplyInfoList[0],
)
this.queryParams.leaseApplyDetails.forEach((v) => {
this.$set(v, 'applyFor', this.queryParams.applyFor)
this.$set(v, 'updateTimes', this.queryParams.updateTimes)
this.$set(v, 'taskName', this.queryParams.taskName)
this.$set(v, 'createTime', this.queryParams.createTimes)
this.$set(v, 'updateTime', this.queryParams.updateTimes)
})
console.log(this.queryParams.examineStatusId)
for (let i = 0; i < this.flowPath.length; i++) {
if (
this.flowPath[i].id < this.queryParams.examineStatusId
) {
this.flowPath[i].color = '#0bbd87'
this.flowPath[i].icon = 'el-icon-check'
} else {
this.flowPath[i].remarkKey = ''
}
if (
this.flowPath[i].id == this.queryParams.examineStatusId
) {
this.flowPath[i].type = 'primary'
this.flowPath[i].color = '#1890ff'
this.flowPath[i].icon = 'el-icon-more'
break
}
}
console.log(this.flowPath)
if (this.queryParams.examineStatusId == 98) {
this.flowPath[0].color = 'red'
this.flowPath[0].icon = 'el-icon-close'
this.flowPath[1].color = ''
this.flowPath[1].icon = ''
this.flowPath[2].color = ''
this.flowPath[2].icon = ''
}
if (this.queryParams.examineStatusId == 99) {
this.flowPath[1].color = 'red'
this.flowPath[1].icon = 'el-icon-close'
this.flowPath[2].color = ''
this.flowPath[2].icon = ''
}
if (this.queryParams.examineStatusId == 100) {
this.flowPath[2].color = 'red'
this.flowPath[2].icon = 'el-icon-close'
}
},
//
cancel() {
this.open = false
this.reset()
},
//
reset() {
this.form = {
dictId: undefined,
dictName: undefined,
dictType: undefined,
status: '0',
remark: undefined,
}
this.resetForm('form')
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1
this.getList()
},
/** 重置按钮操作 */
resetQuery() {
this.dateRange = []
this.resetForm('queryForm')
this.handleQuery()
},
handleNotice() {
this.noticeOpen = true
},
/** 新增按钮操作 */
handleAdd() {
this.reset()
this.open = true
this.title = '添加字典类型'
},
//
handleSelectionChange(selection) {
this.ids = selection.map((item) => item.dictId)
this.single = selection.length != 1
this.multiple = !selection.length
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset()
const dictId = row.dictId || this.ids
getType(dictId).then((response) => {
this.form = response.data
this.open = true
this.title = '验收'
})
},
/** 提交按钮 */
submitForm: function () {
this.$refs['form'].validate((valid) => {
if (valid) {
if (this.form.dictId != undefined) {
updateType(this.form).then((response) => {
this.$modal.msgSuccess('修改成功')
this.open = false
this.getList()
})
} else {
addType(this.form).then((response) => {
this.$modal.msgSuccess('新增成功')
this.open = false
this.getList()
})
}
}
})
},
/** 删除按钮操作 */
handleDelete(row) {
const dictIds = row.dictId || this.ids
this.$modal
.confirm('是否确认删除所选择的数据项?')
.then(function () {
return delType(dictIds)
})
.then(() => {
this.getList()
this.$modal.msgSuccess('删除成功')
})
.catch(() => {})
},
/** 导出按钮操作 */
handleExport() {
this.download(
'system/dict/type/export',
{
...this.queryParams,
},
`type_${new Date().getTime()}.xlsx`,
)
},
/** 刷新缓存按钮操作 */
handleRefreshCache() {
refreshCache().then(() => {
this.$modal.msgSuccess('刷新成功')
this.$store.dispatch('dict/cleanDict')
})
},
}
// console.log('subAuditLeaseByCompany ==================', res)
},
}
//
refuse() {
this.refuseVisible = true
this.queryParams.companyAuditRemarks = '驳回'
},
// handelRefuse(type){
// if (this.queryParams.companyAuditRemarks=='') {
// this.$message.error('');
// return;
// }
// if(type){
// this.refuseAuditLeaseByCompany()
// }else {
// this.queryParams.companyAuditRemarks = ''
// }
// this.refuseVisible = type
// },
//
async refuseAuditLeaseByCompany(type) {
const params = JSON.parse(JSON.stringify(this.queryParams))
if (params.taskStatus == 30) {
params.taskStatus = 98
params.examineStatusId = 98
}
if (params.taskStatus == 31) {
params.taskStatus = 99
params.examineStatusId = 99
}
if (params.taskStatus == 32) {
params.taskStatus = 100
params.examineStatusId = 100
}
params.updateTime = params.updateTimes
params.createTime = params.createTimes
params.leaseApplyInfoList.forEach((v) => {
this.$set(v, 'companyAuditRemark', params.companyAuditRemarks)
this.$set(v, 'companyAuditBy', this.user.id)
this.$set(v, 'examineStatusId', Number(params.examineStatusId))
this.$set(v, 'status', type)
})
console.log(params)
const res = await rejectLeaseByCompany(params)
if (res.code == 200) {
this.examineVisible = false
this.$tab.closeOpenPage({
path: '/claimAndRefund/receive/receiveManage',
})
}
console.log('subAuditLeaseByCompany ==================', res)
},
/** 修改按钮操作 */
handleBack(row) {
this.$tab.closeOpenPage({
path: '/claimAndRefund/receive/receiveManage',
})
},
/** 查询 */
async getData(taskId) {
const res = await getLeaseListAll({
taskId,
})
/* 判断当前领料的机具类型 101 102 */
const stepList = [
{
id: 31,
name: '待分管部门审核',
remarkKey: 'deptAuditRemark',
authorKey: 'deptAuditBy',
timeKey: 'deptAuditTime',
},
{
id: 32,
name: '待内部审核',
remarkKey: 'directAuditRemark',
authorKey: 'directAuditBy',
timeKey: 'directAuditTime',
},
]
if (res.rows[0].leaseApplyInfoList[0].companyId == 101) {
this.flowPath = this.flowPath.concat(stepList)
} else {
/* companyId为102时 属于调试分公司 则审核步骤无需分管部门参与 */
this.isMachinery = false
this.flowPath.push(stepList[1])
}
this.queryParams = { ...this.queryParams, ...res.rows[0] }
this.$set(
this.queryParams,
'leaseApplyInfo',
this.queryParams.leaseApplyInfoList[0],
)
this.queryParams.leaseApplyDetails.forEach((v) => {
this.$set(v, 'applyFor', this.queryParams.applyFor)
this.$set(v, 'updateTimes', this.queryParams.updateTimes)
this.$set(v, 'taskName', this.queryParams.taskName)
this.$set(v, 'createTime', this.queryParams.createTimes)
this.$set(v, 'updateTime', this.queryParams.updateTimes)
})
console.log(this.queryParams.examineStatusId)
for (let i = 0; i < this.flowPath.length; i++) {
if (this.flowPath[i].id < this.queryParams.examineStatusId) {
this.flowPath[i].color = '#0bbd87'
this.flowPath[i].icon = 'el-icon-check'
} else {
this.flowPath[i].remarkKey = ''
}
if (this.flowPath[i].id == this.queryParams.examineStatusId) {
this.flowPath[i].type = 'primary'
this.flowPath[i].color = '#1890ff'
this.flowPath[i].icon = 'el-icon-more'
break
}
}
console.log(this.flowPath)
if (this.queryParams.examineStatusId == 98) {
this.flowPath[0].color = 'red'
this.flowPath[0].icon = 'el-icon-close'
this.flowPath[1].color = ''
this.flowPath[1].icon = ''
this.flowPath[2].color = ''
this.flowPath[2].icon = ''
}
if (this.queryParams.examineStatusId == 99) {
this.flowPath[1].color = 'red'
this.flowPath[1].icon = 'el-icon-close'
this.flowPath[2].color = ''
this.flowPath[2].icon = ''
}
if (this.queryParams.examineStatusId == 100) {
this.flowPath[2].color = 'red'
this.flowPath[2].icon = 'el-icon-close'
}
},
//
cancel() {
this.open = false
this.reset()
},
//
reset() {
this.form = {
dictId: undefined,
dictName: undefined,
dictType: undefined,
status: '0',
remark: undefined,
}
this.resetForm('form')
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1
this.getList()
},
/** 重置按钮操作 */
resetQuery() {
this.dateRange = []
this.resetForm('queryForm')
this.handleQuery()
},
handleNotice() {
this.noticeOpen = true
},
/** 新增按钮操作 */
handleAdd() {
this.reset()
this.open = true
this.title = '添加字典类型'
},
//
handleSelectionChange(selection) {
this.ids = selection.map((item) => item.dictId)
this.single = selection.length != 1
this.multiple = !selection.length
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset()
const dictId = row.dictId || this.ids
getType(dictId).then((response) => {
this.form = response.data
this.open = true
this.title = '验收'
})
},
/** 提交按钮 */
submitForm: function () {
this.$refs['form'].validate((valid) => {
if (valid) {
if (this.form.dictId != undefined) {
updateType(this.form).then((response) => {
this.$modal.msgSuccess('修改成功')
this.open = false
this.getList()
})
} else {
addType(this.form).then((response) => {
this.$modal.msgSuccess('新增成功')
this.open = false
this.getList()
})
}
}
})
},
/** 删除按钮操作 */
handleDelete(row) {
const dictIds = row.dictId || this.ids
this.$modal
.confirm('是否确认删除所选择的数据项?')
.then(function () {
return delType(dictIds)
})
.then(() => {
this.getList()
this.$modal.msgSuccess('删除成功')
})
.catch(() => {})
},
/** 导出按钮操作 */
handleExport() {
this.download(
'system/dict/type/export',
{
...this.queryParams,
},
`type_${new Date().getTime()}.xlsx`,
)
},
/** 刷新缓存按钮操作 */
handleRefreshCache() {
refreshCache().then(() => {
this.$modal.msgSuccess('刷新成功')
this.$store.dispatch('dict/cleanDict')
})
},
},
}
</script>
<style lang="scss" scoped>
::v-deep .el-card__body {
padding: 10px !important;
p {
margin: 0 !important;
}
.title {
color: #848484;
font-weight: 700;
}
.author {
font-size: 13px;
margin-top: 5px;
}
.time {
font-size: 12px;
}
.remark {
margin-top: 10px;
word-break: break-all;
font-size: 13px;
}
::v-deep .el-card__body {
padding: 10px !important;
p {
margin: 0 !important;
}
.title {
color: #848484;
font-weight: 700;
}
.author {
font-size: 13px;
margin-top: 5px;
}
.time {
font-size: 12px;
}
.remark {
margin-top: 10px;
word-break: break-all;
font-size: 13px;
}
}
</style>

View File

@ -253,7 +253,7 @@
(scope.row.leaseApplyInfoList[0].status == '5' ||
scope.row.leaseApplyInfoList[0].status == '7' ||
scope.row.leaseApplyInfoList[0].status == '4' ||
scope.row.leaseApplyInfoList[0].status == '2')
scope.row.leaseApplyInfoList[0].status == '2' )
"
>审批</el-button
>
@ -267,7 +267,8 @@
(scope.row.leaseApplyInfoList[0].status == '5' ||
scope.row.leaseApplyInfoList[0].status == '7' ||
scope.row.leaseApplyInfoList[0].status == '4' ||
scope.row.leaseApplyInfoList[0].status == '2')
scope.row.leaseApplyInfoList[0].status == '2' ||
scope.row.leaseApplyInfoList[0].status == '9')
"
>审批</el-button
>

View File

@ -118,7 +118,7 @@
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button type="primary" plain size="mini" @click="handleAdd"
<el-button type="primary" plain size="mini" @click="handleAdd" v-hasPermi="['return:review']"
>退料申请</el-button
>
</el-col>

View File

@ -273,21 +273,21 @@
prop="remark"
:show-overflow-tooltip="true"
/>
<el-table-column label="操作" align="center" width="180">
<el-table-column label="操作" align="center" width="200">
<template slot-scope="scope">
<el-button
size="mini"
size="medium"
type="text"
icon="el-icon-zoom-in"
@click="handleSee(scope.row, 'see')"
>查看</el-button
>
<el-button
size="mini"
size="medium"
type="text"
icon="el-icon-edit"
v-if="scope.row.applyStatus == '0'"
v-hasPermi="['auditing']"
v-hasPermi="['return:auditing']"
@click="handleUpdate(scope.row, 'update')"
>
审批
@ -303,8 +303,9 @@
审批
</el-button> -->
<el-button
size="mini"
size="medium"
type="text"
icon="el-icon-tickets"
@click="handlePrint(scope.row)"
>退料单</el-button
>

View File

@ -210,27 +210,29 @@
show-overflow-tooltip
></el-table-column>
<el-table-column label="操作" align="center" width="160">
<el-table-column label="操作" align="center" width="200">
<template slot-scope="scope">
<el-button
size="mini"
size="medium"
type="text"
icon="el-icon-zoom-in"
@click="handleSee(scope.row, 'see')"
>查看</el-button
>
<el-button
size="mini"
size="medium"
type="text"
@click="handleReturn(scope.row, 'see')"
icon="el-icon-d-arrow-right"
v-hasPermi="['return:btn']"
v-if="scope.row.taskStatus != '40'"
>
退料
</el-button>
<el-button
size="mini"
size="medium"
type="text"
icon="el-icon-tickets"
@click="handlePrint(scope.row)"
>退料单</el-button
>

View File

@ -255,10 +255,13 @@
<!-- 维修对话框 -->
<el-dialog
:title="repairTitle"
:visible.sync="open"
width="1650px"
v-if="open"
width="85%"
append-to-body
:before-close="onClose"
destroy-on-close
>
<el-form
:model="dialogQueryParams"
@ -352,38 +355,26 @@
:data="repairList"
@selection-change="selectionChange"
>
<el-table-column type="selection" width="55" align="center" />
<el-table-column
label="序号"
type="selection"
width="55"
align="center"
width="80"
type="index"
>
<template scope="scope">
<span>{{
(dialogQueryParams.pageNum - 1) * 10 +
scope.$index +
1
}}</span>
</template>
</el-table-column>
v-if="repairTitle === '维修'"
/>
<el-table-column
label="类型名称"
align="center"
prop="typeName"
sortable
:show-overflow-tooltip="true"
/>
<el-table-column
label="规格型号"
align="center"
prop="type"
sortable
:show-overflow-tooltip="true"
/>
<el-table-column
label="编码"
sortable
align="center"
prop="code"
width="200"
@ -392,7 +383,6 @@
<el-table-column
label="维修总量"
align="center"
sortable
prop="repairNum"
:show-overflow-tooltip="true"
/>
@ -400,14 +390,12 @@
<el-table-column
label="维修合格数量"
align="center"
sortable
prop="repairedNum"
:show-overflow-tooltip="true"
/>
<el-table-column
label="报废数量"
align="center"
sortable
prop="scrapNum"
:show-overflow-tooltip="true"
/>
@ -437,7 +425,7 @@
label="操作"
align="center"
class-name="small-padding fixed-width"
width="300px"
width="280px"
v-if="type == 'update'"
>
<template slot-scope="scope">
@ -646,6 +634,14 @@ export default {
//
rules: {},
defaultData: {},
/**
* *********************
* *********************
*/
/* 维修查看弹框标题 */
repairTitle: '查看',
}
},
created() {
@ -681,19 +677,14 @@ export default {
this.dialogQueryParams.type = value
},
/** 查询字典类型列表 */
getList() {
async getList() {
this.loading = true
this.queryParams.startTime = this.dateRange[0]
this.queryParams.endTime = this.dateRange[1]
getRepairTaskListApi(this.queryParams)
.then((response) => {
this.typeList = response.rows
this.total = response.total
this.loading = false
})
.catch(() => {
this.loading = false
})
const { data: res } = await getRepairTaskListApi(this.queryParams)
this.typeList = res?.rows
this.total = res?.total
this.loading = false
},
getTree() {
listPartTypeApi().then((response) => {
@ -785,23 +776,26 @@ export default {
(item) => item.repairNum === item.repairedNum + item.scrapNum,
)
},
/** 修改按钮操作 */
handleUpdate(row, type) {
/** 维修按钮 */
async handleUpdate(row, type) {
this.repairTitle = '维修'
this.taskId = row.taskId
this.getDialogList()
await this.getDialogList()
this.$eventBus.$emit('taskId', row.taskId)
this.open = true
this.type = type
this.selectionList = []
this.dialogQueryParams = {
pageNum: 1,
pageSize: 10,
}
},
handleSee(row, type) {
this.taskId = row.taskId
this.getDialogList()
this.open = true
},
/* 查看按钮 */
async handleSee(row, type) {
this.repairTitle = '查看'
this.taskId = row.taskId
await this.getDialogList()
this.type = type
this.selectionList = []
this.dialogQueryParams = {
@ -809,6 +803,7 @@ export default {
pageSize: 10,
}
this.resetForm('dialogQueryParams')
this.open = true
},
getDialogList() {
let params = {
@ -921,27 +916,105 @@ export default {
this.isShowThreeFlag = true
},
complete(type) {
// if (type == 1) {
// this.typeText = type
// this.title = ''
// this.openOne = true
// this.openTextOne = '?'
// // this.openTextTwo = '?'
// }
// if (type == 2) {
// this.typeText = type
// this.title = ''
// this.openOne = true
// this.openTextOne = '?'
// // this.openTextTwo = '?'
// }
// if (type == 3) {
// this.typeText = type
// this.title = ''
// this.openOne = true
// this.openTextOne = '?'
// this.openTextTwo = ''
// }
let tipText = ''
let apiFunc = null
let ids = []
if (type == 1) {
this.typeText = type
this.title = '确认操作'
this.openOne = true
this.openTextOne = '确定提交审核么?'
// this.openTextTwo = '?'
tipText = '是否确定提交审核?'
apiFunc = addEndRepairTaskApi
}
if (type == 2) {
this.typeText = type
this.title = '确认操作'
this.openOne = true
this.openTextOne = '确定维修合格了么?'
// this.openTextTwo = '?'
tipText = '是否确定维修合格?'
apiFunc = addFastRepairApplyApi
}
if (type == 3) {
this.typeText = type
this.title = '确认操作'
this.openOne = true
this.openTextOne = '确定完成维修了么?'
this.openTextTwo = '完成维修后不可修改该条数据'
tipText = '是否确定完成维修?提交后将不能再修改此项记录!'
apiFunc = addCompleteRepairApi
let arr = this.selectionList
arr.map((item) => {
ids.push(item.id)
})
}
console.log(ids, '完成维修参数')
this.$confirm(tipText, '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
}).then(async () => {
const res = await apiFunc(
type == 2 || type == 1 ? this.selectionList : ids,
)
if (res.code == 200) {
this.$modal.msgSuccess('已提交')
} else {
this.$modal.msgError(res.msg)
}
this.getDialogList()
})
// if (this.typeText == 1) {
// addEndRepairTaskApi(this.selectionList)
// .then((res) => {
// if (res.code == 200) {
// this.openTwo = true
// this.openTextThree = ''
// // this.getDialogList()
// }
// })
// .catch(() => {})
// }
// if (this.typeText == 2) {
// addFastRepairApplyApi(this.selectionList)
// .then((res) => {
// if (res.code == 200) {
// this.openTwo = true
// this.openTextThree = ''
// // this.getDialogList()
// }
// })
// .catch(() => {})
// }
// if (this.typeText == 3) {
// let ids = []
// let arr = this.selectionList
// arr.map((item) => {
// ids.push(item.id)
// })
// addCompleteRepairApi(ids)
// .then((res) => {
// if (res.code == 200) {
// this.openTwo = true
// this.openTextThree = ''
// // this.getDialogList()
// }
// })
// .catch(() => {})
// }
},
//
getStatusText(status) {

View File

@ -1,23 +1,53 @@
<template>
<div class="app-container" id="testExamine">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch"
label-width="120px">
<el-form
:model="queryParams"
ref="queryForm"
size="small"
:inline="true"
v-show="showSearch"
label-width="100px"
>
<el-form-item label="关键字" prop="keyword">
<el-input v-model="queryParams.keyword" placeholder="请输入关键字" clearable maxlength="50"
style="width: 240px" @keyup.enter.native="handleQuery" />
<el-input
v-model="queryParams.keyword"
placeholder="请输入关键字"
clearable
maxlength="50"
style="width: 240px"
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="单位名称" prop="backUnit">
<el-select v-model="queryParams.backUnit" placeholder="请选择单位名称" clearable filterable
style="width: 240px">
<el-option v-for="dict in unitInfoSelectList" :key="dict.unitId" :label="dict.unitName"
:value="dict.unitId" />
<el-select
v-model="queryParams.backUnit"
placeholder="请选择单位名称"
clearable
filterable
style="width: 240px"
>
<el-option
v-for="dict in unitInfoSelectList"
:key="dict.unitId"
:label="dict.unitName"
:value="dict.unitId"
/>
</el-select>
</el-form-item>
<el-form-item label="工程名称" prop="backPro">
<el-select v-model="queryParams.backPro" placeholder="请选择工程名称" clearable filterable
style="width: 240px">
<el-option v-for="dict in projectSelectList" :key="dict.projectId" :label="dict.projectName"
:value="dict.projectId" />
<el-select
v-model="queryParams.backPro"
placeholder="请选择工程名称"
clearable
filterable
style="width: 240px"
>
<el-option
v-for="dict in projectSelectList"
:key="dict.projectId"
:label="dict.projectName"
:value="dict.projectId"
/>
</el-select>
</el-form-item>
<el-form-item label="工机具类型" prop="type">
@ -36,79 +66,223 @@
<!-- :placeholder="'请选择'"-->
<!-- @handleNodeClick="selectDrop"-->
<!-- ></selectTree>-->
<Tree ref="mychildSon" :width="240" :dataList="deptList" @changeId="selectDrop"></Tree>
<Tree
ref="mychildSon"
:width="240"
:dataList="deptList"
@changeId="selectDrop"
></Tree>
</el-form-item>
<el-form-item label="修试审核单号" prop="backCode">
<el-input v-model="queryParams.backCode" placeholder="请选择修试审核单号" clearable maxlength="50"
style="width: 240px" @keyup.enter.native="handleQuery" />
<el-input
v-model="queryParams.backCode"
placeholder="请选择修试审核单号"
clearable
maxlength="50"
style="width: 240px"
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="修试审核状态" prop="taskStatus">
<el-select v-model="queryParams.taskStatus" placeholder="请选择修试审核状态" clearable filterable
style="width: 240px">
<el-option v-for="dict in dicSelectList" :key="dict.id" :label="dict.name" :value="dict.id" />
<el-select
v-model="queryParams.taskStatus"
placeholder="请选择修试审核状态"
clearable
filterable
style="width: 240px"
>
<el-option
v-for="dict in dicSelectList"
:key="dict.id"
:label="dict.name"
:value="dict.id"
/>
</el-select>
</el-form-item>
<el-form-item label="任务创建时间">
<el-date-picker v-model="dateRange" style="width: 240px" value-format="yyyy-MM-dd" type="daterange"
range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
<el-date-picker
v-model="dateRange"
style="width: 240px"
value-format="yyyy-MM-dd"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
></el-date-picker>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">查询</el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
<el-button
type="primary"
icon="el-icon-search"
size="mini"
@click="handleQuery"
>查询</el-button
>
<el-button
icon="el-icon-refresh"
size="mini"
@click="resetQuery"
>重置</el-button
>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8" style="margin-left: 3%">
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button type="primary" plain icon="el-icon-plus" size="mini" :disabled="multiple"
@click="checkClick">批量审核</el-button>
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
:disabled="multiple"
@click="checkClick"
>批量审核</el-button
>
</el-col>
<el-col :span="1.5">
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport">导出</el-button>
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
>导出</el-button
>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
<right-toolbar
:showSearch.sync="showSearch"
@queryTable="getList"
></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="typeList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" :selectable="selectable" />
<el-table-column label="序号" align="center" width="80" type="index">
<template scope="scope">
<span>{{ (queryParams.pageNum - 1) * 10 + scope.$index + 1 }}</span>
</template>
</el-table-column>
<el-table-column label="修试审核单号" align="center" sortable prop="scrapNum" :show-overflow-tooltip="true" />
<el-table-column label="单位名称" align="center" prop="unitName" sortable :show-overflow-tooltip="true" />
<el-table-column label="工程名称" sortable align="center" prop="projectName" :show-overflow-tooltip="true" />
<el-table-column label="机具类型" align="center" prop="itemType" sortable :show-overflow-tooltip="true" />
<el-table-column label="任务创建人" sortable align="center" prop="createBy" :show-overflow-tooltip="true" />
<el-table-column label="任务创建时间" sortable align="center" prop="createTime" :show-overflow-tooltip="true" />
<el-table-column label="维修单号" align="center" sortable prop="repairNum" :show-overflow-tooltip="true" />
<el-table
v-loading="loading"
:data="typeList"
@selection-change="handleSelectionChange"
border
>
<el-table-column
type="selection"
width="55"
align="center"
:selectable="selectable"
/>
<el-table-column
align="center"
type="index"
width="50"
label="序号"
/>
<el-table-column
label="修试审核单号"
align="center"
prop="scrapNum"
:show-overflow-tooltip="true"
/>
<el-table-column
label="单位名称"
align="center"
prop="unitName"
:show-overflow-tooltip="true"
/>
<el-table-column
label="工程名称"
align="center"
prop="projectName"
:show-overflow-tooltip="true"
/>
<el-table-column
label="机具类型"
align="center"
prop="itemType"
:show-overflow-tooltip="true"
/>
<el-table-column
label="任务创建人"
align="center"
prop="createBy"
:show-overflow-tooltip="true"
/>
<el-table-column
label="任务创建时间"
align="center"
prop="createTime"
:show-overflow-tooltip="true"
/>
<el-table-column
label="维修单号"
align="center"
prop="repairNum"
:show-overflow-tooltip="true"
/>
<el-table-column label="审核状态" align="center" sortable prop="taskStatusName" :show-overflow-tooltip="true" />
<el-table-column label="不通过原因" align="center" sortable prop="remark" :show-overflow-tooltip="true" />
<el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="200px">
<el-table-column
label="审核状态"
align="center"
prop="taskStatusName"
:show-overflow-tooltip="true"
/>
<el-table-column
label="不通过原因"
align="center"
prop="remark"
:show-overflow-tooltip="true"
/>
<el-table-column label="操作" align="center">
<template slot-scope="scope">
<el-button size="mini" type="primary" icon="el-icon-zoom-in"
@click="handleSee(scope.row, 'see')">查看</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-zoom-in"
@click="handleSee(scope.row, 'see')"
>查看</el-button
>
<!-- -->
<el-button size="mini" type="warning" icon="el-icon-circle-check"
:disabled="scope.row.taskStatus !== 46"
@click="handleUpdate(scope.row, 'update')">审核</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-circle-check"
v-if="scope.row.taskStatus == 46"
@click="handleUpdate(scope.row, 'update')"
>审核</el-button
>
</template>
</el-table-column>
</el-table>
<pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize" @pagination="getList" />
<pagination
v-show="total > 0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 添加或修改参数配置对话框 -->
<el-dialog :title="dialogTitle" :visible.sync="open" width="1300px" append-to-body :before-close="onClose">
<el-form :model="dialogQueryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch"
label-width="100px">
<el-dialog
:title="dialogTitle"
:visible.sync="open"
width="1300px"
append-to-body
:before-close="onClose"
>
<el-form
:model="dialogQueryParams"
ref="queryForm"
size="small"
:inline="true"
v-show="showSearch"
label-width="100px"
>
<el-row>
<el-form-item label="关键字" prop="keyword">
<el-input v-model="dialogQueryParams.keyword" placeholder="请输入关键字" :clearable="false"
maxlength="50" style="width: 240px" />
<el-input
v-model="dialogQueryParams.keyword"
placeholder="请输入关键字"
:clearable="false"
maxlength="50"
style="width: 240px"
/>
</el-form-item>
<el-form-item label="类型名称" prop="typeName">
<!-- <treeselect
@ -118,139 +292,385 @@
:normalizer="normalizer"
placeholder="请选择类型名称"
/> -->
<selectTree ref="mychildDialog" style="width: 240px" :treeList="deptList" :treeProps="{
children: 'children',
label: 'label',
}" nodeKey="id" :defaultSelect="true" :defaultData="defaultData" :clearable="false"
:placeholder="'请选择'" @handleNodeClick="selectDropDialog"></selectTree>
<selectTree
ref="mychildDialog"
style="width: 240px"
:treeList="deptList"
:treeProps="{
children: 'children',
label: 'label',
}"
nodeKey="id"
:defaultSelect="true"
:defaultData="defaultData"
:clearable="false"
:placeholder="'请选择'"
@handleNodeClick="selectDropDialog"
></selectTree>
</el-form-item>
<el-form-item label="规格型号" prop="type">
<selectTree ref="mychildDialogTwo" style="width: 240px" :treeList="deptTypeList" :treeProps="{
children: 'children',
label: 'label',
}" nodeKey="id" :defaultSelect="true" :defaultData="defaultData" :clearable="false"
:placeholder="'请选择'" @handleNodeClick="selectDropDialogTwo"></selectTree>
<selectTree
ref="mychildDialogTwo"
style="width: 240px"
:treeList="deptTypeList"
:treeProps="{
children: 'children',
label: 'label',
}"
nodeKey="id"
:defaultSelect="true"
:defaultData="defaultData"
:clearable="false"
:placeholder="'请选择'"
@handleNodeClick="selectDropDialogTwo"
></selectTree>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini"
@click="getdialogList">查询</el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQueryDialog">重置</el-button>
<el-button
type="primary"
icon="el-icon-search"
size="mini"
@click="getdialogList"
>查询</el-button
>
<el-button
icon="el-icon-refresh"
size="mini"
@click="resetQueryDialog"
>重置</el-button
>
</el-form-item>
</el-row>
</el-form>
<el-table v-loading="loading" :data="dialogList" height="500px"
@selection-change="handleDialogSelectionChange">
<el-table-column type="selection" width="55" align="center" :selectable="selectableDialog" />
<el-table-column label="序号" align="center" width="80" type="index">
<el-table
v-loading="loading"
:data="dialogList"
height="500px"
@selection-change="handleDialogSelectionChange"
>
<el-table-column
type="selection"
width="55"
align="center"
:selectable="selectableDialog"
/>
<el-table-column
label="序号"
align="center"
width="80"
type="index"
>
<template scope="scope">
<span>{{ (dialogQueryParams.pageNum - 1) * 10 + scope.$index + 1 }}</span>
<span>{{
(dialogQueryParams.pageNum - 1) * 10 +
scope.$index +
1
}}</span>
</template>
</el-table-column>
<el-table-column label="类型名称" align="center" prop="machineTypeName" :show-overflow-tooltip="true" />
<el-table-column label="规格型号" align="center" prop="specificationType" :show-overflow-tooltip="true" />
<el-table-column label="编码" align="center" prop="maCode" width="200" :show-overflow-tooltip="true" />
<el-table-column label="维修总量" align="center" prop="repairNum" :show-overflow-tooltip="true" />
<el-table-column label="维修数量" align="center" prop="repairedNum" :show-overflow-tooltip="true" />
<el-table-column label="报废数量" align="center" prop="scrapNum" :show-overflow-tooltip="true" />
<el-table-column label="状态" align="center" prop="status" :show-overflow-tooltip="true">
<el-table-column
label="类型名称"
align="center"
prop="machineTypeName"
:show-overflow-tooltip="true"
/>
<el-table-column
label="规格型号"
align="center"
prop="specificationType"
:show-overflow-tooltip="true"
/>
<el-table-column
label="编码"
align="center"
prop="maCode"
width="200"
:show-overflow-tooltip="true"
/>
<el-table-column
label="维修总量"
align="center"
prop="repairNum"
:show-overflow-tooltip="true"
/>
<el-table-column
label="维修数量"
align="center"
prop="repairedNum"
:show-overflow-tooltip="true"
/>
<el-table-column
label="报废数量"
align="center"
prop="scrapNum"
:show-overflow-tooltip="true"
/>
<el-table-column
label="状态"
align="center"
prop="status"
:show-overflow-tooltip="true"
>
<template slot-scope="scope">
<span v-if="scope.row.status == '0'">未审核</span>
<span v-if="scope.row.status == '1'">通过</span>
<span v-if="scope.row.status == '2'">驳回</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="200px">
<el-table-column
label="操作"
align="center"
class-name="small-padding fixed-width"
width="200px"
>
<template slot-scope="scope">
<el-button size="mini" type="primary" icon="el-icon-zoom-in"
@click="repairRecord(scope.row)">维修记录</el-button>
<el-button size="mini" type="warning" icon="el-icon-circle-check"
@click="partRecord(scope.row)">配件详情</el-button>
<el-button
size="mini"
type="primary"
icon="el-icon-zoom-in"
@click="repairRecord(scope.row)"
>维修记录</el-button
>
<el-button
size="mini"
type="warning"
icon="el-icon-circle-check"
@click="partRecord(scope.row)"
>配件详情</el-button
>
</template>
</el-table-column>
</el-table>
<pagination v-show="dialogTotal > 0" :total="dialogTotal" :page.sync="dialogQueryParams.pageNum"
:limit.sync="dialogQueryParams.pageSize" @pagination="getdialogList" />
<pagination
v-show="dialogTotal > 0"
:total="dialogTotal"
:page.sync="dialogQueryParams.pageNum"
:limit.sync="dialogQueryParams.pageSize"
@pagination="getdialogList"
/>
<div slot="footer" class="dialog-footer-btn" style="text-align: center"
v-if="type == 'update' && dialogList.length !== 0">
<el-button type="primary" @click="submitForm(1)" :disabled="dialogMultiple">通过</el-button>
<el-button @click="returnSubmit(1)" :disabled="dialogMultiple">不通过</el-button>
<div
slot="footer"
class="dialog-footer-btn"
style="text-align: center"
v-if="type == 'update' && dialogList.length !== 0"
>
<el-button
type="primary"
@click="submitForm(1)"
:disabled="dialogMultiple"
>通过</el-button
>
<el-button @click="returnSubmit(1)" :disabled="dialogMultiple"
>不通过</el-button
>
</div>
</el-dialog>
<!-- 维修记录 -->
<el-dialog v-loading.fullscreen.lock="fullscreenLoading" :title="title" :visible.sync="openRepairRecord"
append-to-body width="1200px">
<el-dialog
v-loading.fullscreen.lock="fullscreenLoading"
:title="title"
:visible.sync="openRepairRecord"
append-to-body
width="1200px"
>
<el-table :data="repairRecordList" height="450px">
<el-table-column label="序号" align="center" width="80" type="index">
<el-table-column
label="序号"
align="center"
width="80"
type="index"
>
<template scope="scope">
<span>{{ (repairRecordParams.pageNum - 1) * 10 + scope.$index + 1 }}</span>
<span>{{
(repairRecordParams.pageNum - 1) * 10 +
scope.$index +
1
}}</span>
</template>
</el-table-column>
<el-table-column label="维修内容" align="center" prop="repairContent" :show-overflow-tooltip="true" />
<el-table-column label="维修数量" align="center" prop="repairNum" :show-overflow-tooltip="true" />
<el-table-column label="维修人" align="center" prop="repairer" :show-overflow-tooltip="true" />
<el-table-column label="维修方式" align="center" prop="repairType" :show-overflow-tooltip="true">
<el-table-column
label="维修内容"
align="center"
prop="repairContent"
:show-overflow-tooltip="true"
/>
<el-table-column
label="维修数量"
align="center"
prop="repairNum"
:show-overflow-tooltip="true"
/>
<el-table-column
label="维修人"
align="center"
prop="repairer"
:show-overflow-tooltip="true"
/>
<el-table-column
label="维修方式"
align="center"
prop="repairType"
:show-overflow-tooltip="true"
>
<template slot-scope="scope">
<span v-if="scope.row.repairType == '1'">内部</span>
<span v-if="scope.row.repairType == '2'">返厂</span>
<span v-if="scope.row.repairType == '3'">报废</span>
</template>
</el-table-column>
<el-table-column label="返厂名称" align="center" prop="supplier" :show-overflow-tooltip="true" />
<el-table-column label="报废原因" align="center" prop="scrapReason" :show-overflow-tooltip="true" />
<el-table-column label="报废数量" align="center" prop="scrapNum" :show-overflow-tooltip="true" />
<el-table-column label="报废类型" align="center" prop="scrapType" :show-overflow-tooltip="true">
<el-table-column
label="返厂名称"
align="center"
prop="supplier"
:show-overflow-tooltip="true"
/>
<el-table-column
label="报废原因"
align="center"
prop="scrapReason"
:show-overflow-tooltip="true"
/>
<el-table-column
label="报废数量"
align="center"
prop="scrapNum"
:show-overflow-tooltip="true"
/>
<el-table-column
label="报废类型"
align="center"
prop="scrapType"
:show-overflow-tooltip="true"
>
<template slot-scope="scope">
<span v-if="scope.row.scrapType == '0'">自然报废</span>
<span v-if="scope.row.scrapType == '1'">人为报废</span>
</template>
</el-table-column>
<el-table-column label="配件名称" align="center" prop="partName" :show-overflow-tooltip="true" />
<el-table-column label="配件数量" align="center" prop="partNum" :show-overflow-tooltip="true" />
<el-table-column label="配件单价" align="center" prop="partPrice" :show-overflow-tooltip="true" />
<el-table-column label="类型" align="center" prop="partType" :show-overflow-tooltip="true">
<el-table-column
label="配件名称"
align="center"
prop="partName"
:show-overflow-tooltip="true"
/>
<el-table-column
label="配件数量"
align="center"
prop="partNum"
:show-overflow-tooltip="true"
/>
<el-table-column
label="配件单价"
align="center"
prop="partPrice"
:show-overflow-tooltip="true"
/>
<el-table-column
label="类型"
align="center"
prop="partType"
:show-overflow-tooltip="true"
>
<template slot-scope="scope">
<span v-if="scope.row.partType == '0'">不收费</span>
<span v-if="scope.row.partType == '1'">收费</span>
</template>
</el-table-column>
</el-table>
<pagination v-show="repairRecordTotal > 0" :total="repairRecordTotal"
:page.sync="repairRecordParams.pageNum" :limit.sync="repairRecordParams.pageSize"
@pagination="getRepairRecordList" />
<pagination
v-show="repairRecordTotal > 0"
:total="repairRecordTotal"
:page.sync="repairRecordParams.pageNum"
:limit.sync="repairRecordParams.pageSize"
@pagination="getRepairRecordList"
/>
</el-dialog>
<!-- 维修记录 -->
<el-dialog v-loading.fullscreen.lock="fullscreenLoading" :title="title" :visible.sync="openPartRecord"
append-to-body width="1200px">
<el-dialog
v-loading.fullscreen.lock="fullscreenLoading"
:title="title"
:visible.sync="openPartRecord"
append-to-body
width="1200px"
>
<el-table :data="partRecordList" height="450px">
<el-table-column label="序号" align="center" width="80" type="index">
<el-table-column
label="序号"
align="center"
width="80"
type="index"
>
<template scope="scope">
<span>{{ (partRecordParams.pageNum - 1) * 10 + scope.$index + 1 }}</span>
<span>{{
(partRecordParams.pageNum - 1) * 10 +
scope.$index +
1
}}</span>
</template>
</el-table-column>
<el-table-column label="配件名称" align="center" prop="partName" :show-overflow-tooltip="true" />
<el-table-column label="配件数量" align="center" prop="partNum" :show-overflow-tooltip="true" />
<el-table-column label="配件费用" align="center" prop="partCost" :show-overflow-tooltip="true" />
<el-table-column label="类型" align="center" prop="partType" :show-overflow-tooltip="true">
<el-table-column
label="配件名称"
align="center"
prop="partName"
:show-overflow-tooltip="true"
/>
<el-table-column
label="配件数量"
align="center"
prop="partNum"
:show-overflow-tooltip="true"
/>
<el-table-column
label="配件费用"
align="center"
prop="partCost"
:show-overflow-tooltip="true"
/>
<el-table-column
label="类型"
align="center"
prop="partType"
:show-overflow-tooltip="true"
>
<template slot-scope="scope">
<span v-if="scope.row.partType == '0'">不收费</span>
<span v-if="scope.row.partType == '1'">收费</span>
</template>
</el-table-column>
<el-table-column label="备注" align="center" prop="remark" :show-overflow-tooltip="true" />
<el-table-column
label="备注"
align="center"
prop="remark"
:show-overflow-tooltip="true"
/>
</el-table>
<pagination v-show="partRecordTotal > 0" :total="partRecordTotal" :page.sync="partRecordParams.pageNum"
:limit.sync="partRecordParams.pageSize" @pagination="getPartRecordList" />
<pagination
v-show="partRecordTotal > 0"
:total="partRecordTotal"
:page.sync="partRecordParams.pageNum"
:limit.sync="partRecordParams.pageSize"
@pagination="getPartRecordList"
/>
</el-dialog>
<el-dialog v-loading.fullscreen.lock="fullscreenLoading" :title="title" :visible.sync="openOne" append-to-body
width="400px">
<el-dialog
v-loading.fullscreen.lock="fullscreenLoading"
:title="title"
:visible.sync="openOne"
v-if="openOne"
append-to-body
width="400px"
>
<div class="submit_box">
<div>
<i class="el-icon-circle-check" style="color: #ff9900; font-size: 30px"></i>
<i
class="el-icon-circle-check"
style="color: #ff9900; font-size: 30px"
></i>
</div>
<div class="submit_box_title">
<div>{{ openTextOne }}</div>
@ -259,26 +679,52 @@
</div>
<div slot="footer" class="dialog-footer">
<el-button @click="submitOpenOneFeturn">返回</el-button>
<el-button type="primary" @click="submitOpenOneForm()">确定</el-button>
<el-button type="primary" @click="submitOpenOneForm()"
>确定</el-button
>
</div>
</el-dialog>
<el-dialog v-loading.fullscreen.lock="fullscreenLoading" :title="title" :visible.sync="openTwo" append-to-body
width="400px" :before-close="openTextThreeClose">
<el-dialog
v-loading.fullscreen.lock="fullscreenLoading"
:title="title"
:visible.sync="openTwo"
append-to-body
width="400px"
:before-close="openTextThreeClose"
>
<div class="submit_box_two">
<div>
<i class="el-icon-circle-check" style="color: #00c196; font-size: 30px"></i>
<i
class="el-icon-circle-check"
style="color: #00c196; font-size: 30px"
></i>
</div>
<div class="submit_box_title">{{ openTextThree }}</div>
</div>
<div slot="footer" class="dialog-footer"></div>
</el-dialog>
<el-dialog v-loading.fullscreen.lock="fullscreenLoading" :title="title" :visible.sync="openThree" append-to-body
width="800px">
<el-dialog
v-loading.fullscreen.lock="fullscreenLoading"
:title="title"
:visible.sync="openThree"
append-to-body
width="800px"
>
<div class="submit_box">
<el-form ref="form" :model="form" :rules="rules" label-width="140px">
<el-form
ref="form"
:model="form"
:rules="rules"
label-width="140px"
>
<el-form-item label="请输入驳回原因:" prop="remark">
<el-input style="width: 600px" type="textarea" v-model="form.remark" maxlength="100"
show-word-limit></el-input>
<el-input
style="width: 600px"
type="textarea"
v-model="form.remark"
maxlength="100"
show-word-limit
></el-input>
</el-form-item>
</el-form>
</div>
@ -287,13 +733,20 @@
<el-button type="primary" @click="formSubmit">保存</el-button>
</div>
</el-dialog>
<el-dialog v-loading.fullscreen.lock="fullscreenLoading" :title="title" :visible.sync="openFour" append-to-body
width="400px">
<el-dialog
v-loading.fullscreen.lock="fullscreenLoading"
:title="title"
:visible.sync="openFour"
append-to-body
width="400px"
>
<div class="submit_box_openFour">
你选择了{{ selectionList.length }}条数据,请进行审批
</div>
<div slot="footer" class="dialog-footer">
<el-button @click="submitForm(2)" type="primary">通过</el-button>
<el-button @click="submitForm(2)" type="primary"
>通过</el-button
>
<el-button @click="returnSubmit(2)">不通过</el-button>
</div>
</el-dialog>
@ -435,8 +888,8 @@ export default {
getQuestListApi(
this.addDateRange(this.queryParams, this.dateRange),
).then((response) => {
this.typeList = response.rows
this.total = response.total
this.typeList = response.data.rows
this.total = response.data.total
this.loading = false
})
},
@ -460,7 +913,7 @@ export default {
this.dialogTotal = response.total
}
})
.catch(() => { })
.catch(() => {})
},
checkClick() {
this.title = '审批'
@ -587,10 +1040,44 @@ export default {
submitForm(val) {
// val 1 2
this.checkResult = val
this.openOne = true
this.openFour = false
this.openTextOne = '确定审批通过么?'
this.openTextTwo = '确定审批通过么?'
if (this.checkResult == 1) {
let taskIdList = []
taskIdList.push(this.rowObj.taskId)
let params = {
checkResult: '通过',
taskIdList: taskIdList,
auditDetailList: this.dialogIds,
}
// console.log(params)
addDetailsAuditApi(params)
.then((res) => {
this.$modal.msgSuccess('审核通过')
this.open = false
this.getList()
})
.catch(() => {})
}
if (this.checkResult == 2) {
let taskIdList = []
this.selectionList.map((item) => {
taskIdList.push(item.taskId)
})
let params = {
checkResult: '通过',
taskIdList: taskIdList,
}
addDetailsAuditApi(params)
.then((res) => {
this.$modal.msgSuccess('审核通过')
this.open = false
this.getList()
})
.catch(() => {})
}
// this.openOne = true
// this.openFour = false
// this.openTextOne = '?'
// this.openTextTwo = '?'
},
submitOpenOneForm() {
this.openOne = false
@ -613,7 +1100,7 @@ export default {
// this.getdialogList()
this.getList()
})
.catch(() => { })
.catch(() => {})
}
if (this.checkResult == 2) {
let taskIdList = []
@ -630,7 +1117,7 @@ export default {
this.openTextThree = '审批通过!'
this.getList()
})
.catch(() => { })
.catch(() => {})
}
},
openTextThreeClose() {
@ -665,7 +1152,7 @@ export default {
this.openRepairRecord = true
this.title = '维修记录'
})
.catch(() => { })
.catch(() => {})
},
//
partRecord(row) {
@ -687,7 +1174,7 @@ export default {
this.openPartRecord = true
this.title = '配件详情'
})
.catch(() => { })
.catch(() => {})
},
returnSubmit(val) {
@ -720,7 +1207,7 @@ export default {
// this.getdialogList()
this.getList()
})
.catch(() => { })
.catch(() => {})
}
if (this.checkResult == 2) {
let taskIdList = []
@ -741,7 +1228,7 @@ export default {
this.getList()
// }
})
.catch(() => { })
.catch(() => {})
}
} else {
return false

View File

@ -42,10 +42,10 @@ module.exports = {
// target: `https://test-cc.zhgkxt.com`,//线上环境-南网
// target: `https://z.csgmall.com.cn`,
// target: `http://10.40.92.8:8080`, //超
target: `http://10.40.92.13:38080`, //超
// target: `http://10.40.92.81:8080`, //韩/
// target: `http://10.40.92.74:8080`,//旭/
target: `http://10.40.92.138:28080`, //帅
// target: `http://10.40.92.140:28080`, //帅
// target: `http://10.40.92.14:28080`, //福
//******** 注意事项 ********* */