增加监理人员提交审核页面

This commit is contained in:
BianLzhaoMin 2025-05-29 08:54:16 +08:00
parent faac6dd3c3
commit 26a3bd00a6
4 changed files with 120 additions and 42 deletions

View File

@ -1,19 +1,19 @@
import request from '@/utils/request' import request from '@/utils/request'
// 人员入场查询列表 // 获取监理人员列表接口
export function listAdmissionRequest(query) { export function getPtSupPersonApi(data) {
return request({ return request({
url: '/project/admissionRequest/list', url: '/project/SupervisionUnit/getPtSupPerson',
method: 'get', method: 'get',
params: query, params: data,
}) })
} }
// 人员信息列表查询 // 提交审核接口
export function listPersonnelInformation(query) { export function submitApprovalApi(data) {
return request({ return request({
url: '/project/admissionRequest/listPersonnelInformation', url: '/flowable/business/submitApproval',
method: 'get', method: 'post',
params: query, data,
}) })
} }

View File

@ -6,12 +6,12 @@ const cbc_iv = CryptoJS.enc.Utf8.parse('1234567812345678')
* 默认参数需要加密 * 默认参数需要加密
* @type {boolean} * @type {boolean}
*/ */
const jia_mi = true const jia_mi = process.env.NODE_ENV === 'development' ? false : true
/** /**
* 默认后台会自动加密 * 默认后台会自动加密
* @type {boolean} * @type {boolean}
*/ */
const jie_mi = true const jie_mi = process.env.NODE_ENV === 'development' ? false : true
/** /**
* 加密 * 加密
* @param word * @param word

View File

@ -184,6 +184,8 @@ import { decryptCBC } from '@/utils/aescbc'
import { addSupervisoryPersonApply } from '@/api/pro/supervisory' import { addSupervisoryPersonApply } from '@/api/pro/supervisory'
import { listSupervisorPersonById } from '@/api/pro/outsourcingPro'
export default { export default {
components: { BnsTimelineTabs, bnsKkFilePreview, Treeselect, uploadFile }, components: { BnsTimelineTabs, bnsKkFilePreview, Treeselect, uploadFile },
data() { data() {
@ -256,7 +258,6 @@ export default {
const params = this.$route.params && this.$route.params.data const params = this.$route.params && this.$route.params.data
this.paramsData = JSON.parse(decryptCBC(params)) this.paramsData = JSON.parse(decryptCBC(params))
if (this.paramsData.type !== 'view') { if (this.paramsData.type !== 'view') {
this.showOrNot = true
if (this.paramsData.type === 'edit') { if (this.paramsData.type === 'edit') {
this.getData() this.getData()
} }
@ -270,6 +271,24 @@ export default {
this.getStatus() this.getStatus()
}, },
methods: { methods: {
//
// getDetails(row) {
// this.loading = true
// const params = {
// id: row.id,
// proId: row.proId,
// uuid: row.uuid,
// supUuid: row.supUuid,
// }
// listSupervisorPersonById(params).then(response => {
// console.log(response)
// this.form = { ...response.data }
// this.fileUuid = response.data.id
// this.personId = response.data.uuid
// this.loading = false
// })
// },
getStatus() { getStatus() {
const params = { const params = {
dictType: 'sys_sup_post', dictType: 'sys_sup_post',
@ -309,23 +328,36 @@ export default {
} }
}, },
getData() { getData() {
// const params = {
// consUserId: this.paramsData.consUserId,
// uuid: this.paramsData.uuid,
// proId: '2',
// supId: '1',
// consId: '1',
// }
// getData(params).then(response => {
// console.log(response)
// this.form = response.data
// if (this.form.post === '1') {
// this.showSpecialWorkType = true
// }
// if (this.paramsData.type === 'view') {
// this.form.phone = hideSensitiveInfo(response.data.phone)
// this.form.idCard = hideSensitiveInfo(response.data.idCard)
// }
// })
const params = { const params = {
consUserId: this.paramsData.consUserId, id: this.paramsData.id,
proId: this.paramsData.proId,
uuid: this.paramsData.uuid, uuid: this.paramsData.uuid,
proId: '2', supUuid: this.paramsData.supUuid,
supId: '1',
consId: '1',
} }
getData(params).then(response => { listSupervisorPersonById(params).then(response => {
console.log(response) console.log(response)
this.form = response.data this.form = { ...response.data }
if (this.form.post === '1') { this.fileUuid = response.data.id
this.showSpecialWorkType = true this.personId = response.data.uuid
} // this.loading = false
if (this.paramsData.type === 'view') {
this.form.phone = hideSensitiveInfo(response.data.phone)
this.form.idCard = hideSensitiveInfo(response.data.idCard)
}
}) })
}, },
//- //-
@ -398,7 +430,7 @@ export default {
} }
addSupervisoryPersonApply(reqData) addSupervisoryPersonApply(reqData)
.then(response => { .then(response => {
this.$modal.msgSuccess('新增成功') this.$modal.msgSuccess(this.paramsData.type === 'edit' ? '修改成功' : '新增成功')
// this.supervisorOpen = false // this.supervisorOpen = false
this.delFileIds = [] this.delFileIds = []
// this.getSupervisorPersonList() // this.getSupervisorPersonList()

View File

@ -96,9 +96,18 @@
</el-popover> </el-popover>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="审核状态" align="center">
<template slot-scope="scope">
<el-tag size="mini" v-if="scope.row.status == 0" type="primary">待审核</el-tag>
<el-tag size="mini" v-if="scope.row.status == 1" type="success">已审核</el-tag>
<el-tag size="mini" v-if="scope.row.status == 2" type="danger">驳回</el-tag>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width"> <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button size="mini" type="text" @click="onHandleAudit(scope.row)">提交审核</el-button> <el-button size="mini" type="text" @click="onHandleAudit(scope.row)" v-if="scope.row.status == 0">
提交审核
</el-button>
<el-button size="mini" type="text" @click="handleEdit(scope.row)">编辑</el-button> <el-button size="mini" type="text" @click="handleEdit(scope.row)">编辑</el-button>
<el-button size="mini" type="text" @click="handleDel(scope.row)">删除</el-button> <el-button size="mini" type="text" @click="handleDel(scope.row)">删除</el-button>
</template> </template>
@ -384,6 +393,8 @@ import debounce from 'lodash/debounce'
import { listSupervisor, listSupervisorPerson } from '@/api/pro/outsourcingPro' import { listSupervisor, listSupervisorPerson } from '@/api/pro/outsourcingPro'
import { getPtSupPersonApi, submitApprovalApi } from '@/api/pro/supervisor-person-manage'
export default { export default {
name: 'Post', name: 'Post',
components: { bnsKkFilePreview, BnsFileListTabs }, components: { bnsKkFilePreview, BnsFileListTabs },
@ -432,17 +443,14 @@ export default {
queryParams: { queryParams: {
pageNum: 1, pageNum: 1,
pageSize: 10, pageSize: 10,
deviceName: undefined,
createUser: undefined,
deviceUser: undefined,
deviceType: undefined,
proId: this.$store.state.user.thisIds.proId, proId: this.$store.state.user.thisIds.proId,
supUuid: this.$store.state.user.thisIds.supUuid, supUuid: this.$store.state.user.thisIds.supUuid,
contUuid: this.$store.state.user.thisIds.contUuid, // contUuid: this.$store.state.user.thisIds.contUuid,
subUuid: this.$store.state.user.thisIds.subUuid, // subUuid: this.$store.state.user.thisIds.subUuid,
userType: this.$store.state.user.thisIds.userType, userType: '',
consName: undefined, // consName: undefined,
status: undefined, // status: undefined,
}, },
// //
form: {}, form: {},
@ -510,7 +518,7 @@ export default {
3: '特殊工种文件', 3: '特殊工种文件',
4: '其他文件', 4: '其他文件',
} }
selectFile({ classification: 9, uuid: row.uuid, informationType: informationType, fromType: 2 }).then( selectFile({ classification: 9, uuid: row.uuid, informationType: informationType, fromType: 3 }).then(
response => { response => {
console.log(response) console.log(response)
if (response.data.length === 0) { if (response.data.length === 0) {
@ -546,11 +554,11 @@ export default {
/** 查询设备列表 */ /** 查询设备列表 */
getList() { getList() {
this.loading = true this.loading = true
this.queryParams.proId = this.$store.state.user.thisIds.proId // this.queryParams.proId = this.$store.state.user.thisIds.proId
this.queryParams.contUuid = this.$store.state.user.thisIds.consUuid // this.queryParams.contUuid = this.$store.state.user.thisIds.consUuid
this.queryParams.subUuid = this.$store.state.user.thisIds.subUuid // this.queryParams.subUuid = this.$store.state.user.thisIds.subUuid
// this.queryParams.userType = this.$store.state.user.userType this.queryParams.userType = this.$store.state.user.userType
listSupervisorPerson(this.queryParams).then(response => { getPtSupPersonApi(this.queryParams).then(response => {
console.log(response, 'response') console.log(response, 'response')
this.supervisorList = response.rows this.supervisorList = response.rows
this.total = response.total this.total = response.total
@ -1012,6 +1020,44 @@ export default {
// //
onHandleAudit(row) { onHandleAudit(row) {
console.log(row, '行信息') console.log(row, '行信息')
this.$confirm('确定提交审核吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
}).then(async () => {
const res = await submitApprovalApi({
parentUuid: row.supUuid,
proId: row.proId,
supUuid: row.supUuid,
uuid: row.uuid,
taskType: '1',
userType: this.$store.state.user.userType,
})
console.log('确定', res)
})
},
//
handleEdit(row) {
// console.log(row, '')
// this.$router.push({
// path: '/project/supervisor-person-manage/addPersonnel/',
// query: {
// id: row.id,
// proId: row.proId,
// uuid: row.uuid,
// supUuid: row.supUuid,
// },
// })
const params = {
id: row.id,
proId: row.proId,
uuid: row.uuid,
supUuid: row.supUuid,
type: 'edit',
}
this.$router.push('/project/supervisor-person-manage/addPersonnel/' + encryptCBC(JSON.stringify(params)))
}, },
}, },
} }