Merge remote-tracking branch 'origin/main'

This commit is contained in:
danshihao
2023-11-22 13:52:15 +08:00
10 changed files with 462 additions and 53 deletions
+9 -6
View File
@@ -52,13 +52,15 @@ const getCheckReportById = (params) => getAction('/enterprise/inspect/inspectRep
// 企标稽查-根据id获取整改计划
const getRectificationPlanById = (params) => getAction('/enterprise/inspect/rectifyPlan', params)
// 企标复审计划-发起复审
const initReview = (params) => getAction('', params)
// 企标计划-根据id获取计划详情
const getEnterpriseStandardPlanInfoById = (params) => getAction('/enterprise/plan/detail', params)
// 企标计划-分页获取(选择企标计划组件中用)
const getEnterpriseStandardPlanPage = (params) => getAction('/process/es/initChange/getESPList', params)
// 企标复审计划-分页获取(选择企标复审计划组件中用)
const getEnterpriseRecheckPlanPage = (params) => getAction('/enterprise/recheckPlan/page', params)
// 企标复审计划-根据id获取数据
const getEnterpriseRecheckPlanById = (params) => getAction('', params)
export {
getEnterpriseStandardTableHeader,
@@ -89,8 +91,9 @@ export {
getCheckReportById,
getRectificationPlanById,
initReview,
getEnterpriseStandardPlanInfoById,
getEnterpriseStandardPlanPage
getEnterpriseStandardPlanPage,
getEnterpriseRecheckPlanPage,
getEnterpriseRecheckPlanById
}
+4
View File
@@ -531,6 +531,10 @@ module.exports = {
enterprisePlanSelect: {
title: '企标计划选择'
},
// 企标复审计划选择器
enterpriseRecheckPlanSelect: {
title: '企标复审计划选择'
},
// 用户/组织结构选择器
userOrOrganSelect: {
select: 'Select',
+5
View File
@@ -171,6 +171,7 @@ module.exports = {
pleaseSelectTime: '请选择时间',
oneTableAdded: '只能添加一个表格',
addATable: '请添加一个表格',
select: '选择',
// 树右键
treeRight: {
addFolder: '新增文件夹',
@@ -561,6 +562,10 @@ module.exports = {
enterprisePlanSelect: {
title: '企标计划选择'
},
// 企标复审计划选择器
enterpriseRecheckPlanSelect: {
title: '企标复审计划选择'
},
// 用户/组织结构选择器
userOrOrganSelect: {
select: '选择',
@@ -4,7 +4,7 @@
<a-input class="box-input" :value="standardNumber" :title="standardNumber" @click="standardClick"
disabled readonly :placeholder="placeholder"/>
<a-button v-if="!disabled" type="primary" class="button-box" @click="standardClick">
{{this.$t('enterprisePlanSelect.title')}}
{{ $t('enterprisePlanSelect.title')}}
</a-button>
</div>
<enterprise-plan-selection-modal ref="enterprisePlanSelectionModal" v-bind="$attrs" :value="value" @change="modalChange" @standardNumberChange="standardNumberChange" @listChange="modalListChange"></enterprise-plan-selection-modal>
@@ -0,0 +1,80 @@
<template>
<div class="selection-wrapper">
<div class="box-title-text">
<a-input class="box-input" :value="standardNumber" :title="standardNumber" @click="standardClick"
disabled readonly :placeholder="placeholder"/>
<a-button v-if="!disabled" type="primary" class="button-box" @click="standardClick">
{{ $t('select') }}
</a-button>
</div>
<enterprise-recheck-plan-selection-modal ref="enterpriseRecheckPlanSelectionModal" v-bind="$attrs" :value="value" @change="modalChange" @standardNumberChange="standardNumberChange" @listChange="modalListChange"></enterprise-recheck-plan-selection-modal>
</div>
</template>
<script>
import EnterpriseRecheckPlanSelectionModal from './EnterpriseRecheckPlanSelectionModal'
export default {
name: 'EnterpriseRecheckPlanSelection',
components: { EnterpriseRecheckPlanSelectionModal },
props: {
value: {
type: String,
default: ''
},
placeholder: {
type: String,
default: ''
},
disabled: {
type: Boolean,
default: false
},
standardNumber: {
type: String,
default: ''
}
},
methods: {
// 点击选择标准按钮
standardClick () {
this.$refs.enterpriseRecheckPlanSelectionModal.open()
},
modalChange (value) {
this.$emit('change', value)
},
standardNumberChange (value) {
this.$emit('standardNumberChange', value)
},
modalListChange (value) {
this.$emit('listChange', value)
}
},
model: {
prop: 'value',
event: 'change'
}
}
</script>
<style scoped lang="less">
.selection-wrapper {
height: 40px;
line-height: 40px;
}
.box-title-text {
height: 100%;
display: flex;
align-items: center;
.box-input {
width: 100%;
}
/deep/ .ant-input-disabled {
background: #fff;
color: rgba(0, 0, 0, 0.65);
cursor: default;
}
.button-box {
margin-left: 10px;
}
}
</style>
@@ -0,0 +1,282 @@
<template>
<a-drawer
:title="$t('enterpriseRecheckPlanSelect.title')"
:maskClosable="false"
:width="1000"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
class="custom-drawer-style">
<div class="custom-drawer-style-scroll">
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<!-- 企标编号 -->
<a-col :span="8">
<a-form-item :label="$t('enterpriseStandardLibrary.reviewPlan.enterpriseStandardNum')" :labelCol="labelCol" :wrapperCol="wrapperCol">
<a-input :placeholder="$t('pleaseEnter')+$t('enterpriseStandardLibrary.reviewPlan.enterpriseStandardNum')" v-model="queryParam.originEnStandardNo"></a-input>
</a-form-item>
</a-col>
<!-- 企标名称 -->
<a-col :span="8">
<a-form-item :label="$t('enterpriseStandardLibrary.reviewPlan.enterpriseStandardName')" :labelCol="labelCol" :wrapperCol="wrapperCol">
<a-input :placeholder="$t('pleaseEnter')+$t('enterpriseStandardLibrary.reviewPlan.enterpriseStandardName')" v-model="queryParam.originEnStandardName"></a-input>
</a-form-item>
</a-col>
<!-- 主起草人 -->
<a-col :span="8">
<a-form-item :label="$t('enterpriseStandardLibrary.reviewPlan.principalDrafter')" :labelCol="labelCol" :wrapperCol="wrapperCol">
<a-input :placeholder="$t('pleaseEnter')+$t('enterpriseStandardLibrary.reviewPlan.principalDrafter')" v-model="queryParam.mainDraftingUser"></a-input>
</a-form-item>
</a-col>
<!-- 主起草单位 -->
<a-col :span="8">
<a-form-item :label="$t('enterpriseStandardLibrary.reviewPlan.mainDraftingUnit')" :labelCol="labelCol" :wrapperCol="wrapperCol">
<a-tree-select
tree-node-filter-prop="title"
v-model="queryParam.mainDraftingUnit"
:maxTagCount="1"
:show-search="true"
:getPopupContainer="triggerNode=> triggerNode.parentNode"
class="box-input"
style="width: 100%"
:tree-data="categoryTreeList"
:placeholder="$t('pleaseSelect') + $t('enterpriseStandardLibrary.reviewPlan.mainDraftingUnit')"
/>
</a-form-item>
</a-col>
<div style="float: right;overflow: hidden;" class="table-page-search-submitButtons">
<a-button type="primary" @click="searchQuery" icon="search" style="margin-left: 8px">{{ $t('query') }}</a-button>
<a-button type="primary" ghost @click="searchReset" icon="reload" style="margin-left: 8px">{{ $t('reset') }}</a-button>
</div>
</a-row>
</a-form>
</div>
<a-table
:columns="columns"
rowKey="id"
:scroll="{x: 900}"
:data-source="dataList"
:pagination="ipagination"
:row-selection="{ type: type, selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
:loading="loading">
<template slot="text" slot-scope="text">
<a-tooltip overlay-class-name="tooltip-style">
<template slot="title">{{ text || text === 0 ? text : global.emptyLine }}</template>
<div class="table-text">{{ text || text === 0 ? text : global.emptyLine }}</div>
</a-tooltip>
</template>
<!-- 企标编号/企标名称 -->
<template v-slot:toDetail="text, record">
<a-tooltip overlay-class-name="tooltip-style">
<template slot="title">{{ text || text === 0 ? text : global.emptyLine }}</template>
<a v-if="text" class="link-a" @click="handleGoDetail(record)">{{ text }}</a>
<div v-else class="table-text">{{ global.emptyLine }}</div>
</a-tooltip>
</template>
</a-table>
</div>
<div class="custom-drawer-style-bottom-btn">
<a-button @click="handleCancel">{{ $t('cancel') }}</a-button>
<a-button @click="handleSubmit" type="primary" :loading="confirmLoading">{{ $t('submit') }}</a-button>
</div>
</a-drawer>
</template>
<script>
import { queryDepartTreeList } from '@/api/api'
import { getEnterpriseRecheckPlanPage } from '@/api/enterpriseStandardLibraryApi'
export default {
name: 'EnterpriseRecheckPlanSelectionModal',
props: {
value: {
type: String,
default: ''
},
type: {
type: String,
required: false,
default: 'checkbox'
},
searchParam: { // 根据不同模块传入固定的查询参数
type: Object,
required: false,
default () {
return {}
}
}
},
data () {
return {
visible: false,
confirmLoading: false,
labelCol: {
sm: 8
},
wrapperCol: {
sm: 14
},
selectedRowKeys: [],
selectedRowList: [],
loading: false,
queryParam: {},
/* 分页参数 */
ipagination: {
current: 1,
pageSize: 10,
pageSizeOptions: ['10', '20', '30'],
showTotal: (total, range) => {
return range[0] + '-' + range[1] + ' ' + this.$t('total') + ' ' + total + ' ' + this.$t('strip')
},
showQuickJumper: true,
showSizeChanger: true,
total: 0
},
columns: [
{ // 企标编号
title: this.$t('enterpriseStandardLibrary.reviewPlan.enterpriseStandardNum'),
align: 'center',
width: 180,
dataIndex: 'standardNo',
scopedSlots: { customRender: 'toDetail' }
},
{ // 企标名称
title: this.$t('enterpriseStandardLibrary.reviewPlan.enterpriseStandardName'),
align: 'center',
width: 180,
dataIndex: 'standardName',
scopedSlots: { customRender: 'toDetail' }
},
{ // 发布日期
title: this.$t('enterpriseStandardLibrary.reviewPlan.publishDate'),
align: 'center',
width: 180,
dataIndex: 'releaseDate',
scopedSlots: { customRender: 'text' }
},
{ // 复审日期
title: this.$t('enterpriseStandardLibrary.reviewPlan.reviewDate'),
align: 'center',
width: 180,
dataIndex: 'recheckDate',
scopedSlots: { customRender: 'reviewDate' }
},
{ // 复审结果
title: this.$t('enterpriseStandardLibrary.reviewPlan.reviewResult'),
align: 'center',
width: 180,
dataIndex: 'recheckResult_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 主起草人
title: this.$t('enterpriseStandardLibrary.reviewPlan.principalDrafter'),
align: 'center',
width: 180,
dataIndex: 'mainDraftingUser_dictText',
scopedSlots: { customRender: 'text' }
},
{ // 主起草单位
title: this.$t('enterpriseStandardLibrary.reviewPlan.mainDraftingUnit'),
align: 'center',
width: 180,
dataIndex: 'mainDraftingUnit_dictText',
scopedSlots: { customRender: 'text' }
}
],
dataList: [],
categoryTreeList: [] // 组织机构下拉框数据
}
},
mounted () {
this.getSysCategoryTree()
},
methods: {
open () {
this.visible = true
this.queryParam = {}
this.$nextTick(() => {
this.replacePage()
})
},
// 获取组织机构树
getSysCategoryTree () {
queryDepartTreeList().then((res) => {
if (res.success) {
this.categoryTreeList = res.result
} else {
this.categoryTreeList = []
}
})
},
// 点击跳转企标详情
handleGoDetail (record) {
this.$openPageNewSheet({
path: '/enterpriseStandardLibrary/enterpriseStandardDetail',
query: {
standardNumber: record.standardNo
}
})
},
// 获取表格数据
replacePage () {
const query = {
...this.queryParam,
...this.searchParam,
pageNo: this.ipagination.current,
pageSize: this.ipagination.pageSize
}
this.selectedRowKeys = []
this.loading = true
getEnterpriseRecheckPlanPage(query).then((res) => {
if (res.success) {
this.dataList = res.result.records
this.ipagination.total = res.result.total
this.selectedRowKeys = this.value.split(',')
} else {
this.dataList = []
}
}).finally(() => {
this.loading = false
})
},
searchQuery () {
this.replacePage()
},
searchReset () {
this.queryParam = {}
this.replacePage()
},
// 表格选择改变
onSelectChange (value, row) {
this.selectedRowKeys = value
this.selectedRowList = row
},
handleCancel () {
this.visible = false
},
handleSubmit () {
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
const standardNumberList = this.selectedRowList.map(item => item.originEnStandardNo)
this.$emit('change', this.selectedRowKeys.join(','))
this.$emit('standardNumberChange', standardNumberList.join(','))
this.$emit('listChange', this.selectedRowList)
this.visible = false
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
}
}
}
</script>
<style scoped lang="less">
@import '~@assets/less/common.less';
</style>
@@ -101,7 +101,6 @@
<script>
import JTable from '@/components/jero/JTable'
import { JeroListMixin } from '@/mixins/JeroListMixin'
import { initReview } from '@/api/enterpriseStandardLibraryApi'
export default {
name: 'ReviewPlanList',
@@ -213,14 +212,10 @@ export default {
this.$message.warning(this.$t('selectARecord'))
return
}
const params = {}
params.id = this.selectedRowKeys[0]
initReview(params).then(res => {
if (res.success) {
this.$message.success(res.message)
this.loadData()
} else {
this.$message.warning(res.message)
this.$router.push({
path: '/workCenter/enterpriseStandardRecheck/enterpriseStandardRecheckFlow',
query: {
recheckPlanId: this.selectedRowKeys[0]
}
})
}
@@ -54,14 +54,14 @@
<div class="process-part-title">{{ $t('basicServiceInformation') }}</div>
<!-- 节点1发起人发起 -->
<!-- 是联络人发起 -->
<contact-init-base-info v-if="currentNode === 1 && initRole === 'contact'" ref="baseInfoRef" @processNameChange="processNameChange"></contact-init-base-info>
<contact-init-base-info v-if="currentNode === 1" ref="baseInfoRef" @processNameChange="processNameChange"></contact-init-base-info>
<!-- 是标准化发起 -->
<standardization-init-base-info v-else-if="currentNode === 1 && initRole === 'standardization'" ref="baseInfoRef" @processNameChange="processNameChange"></standardization-init-base-info>
<standardization-init-base-info v-else-if="currentNode === 2" ref="baseInfoRef" @processNameChange="processNameChange"></standardization-init-base-info>
<!-- 节点2起草人填写意见 -->
<drafter-enter-option-base-info v-else-if="currentNode === 2" ref="baseInfoRef"></drafter-enter-option-base-info>
<drafter-enter-option-base-info v-else-if="currentNode === 3" ref="baseInfoRef"></drafter-enter-option-base-info>
<!-- 节点3起草人部长审批 -->
<!-- 节点4标准化审批 -->
<recheck-approve-base-info v-else-if="currentNode === 3 || currentNode === 4" ref="baseInfoRef"></recheck-approve-base-info>
<recheck-approve-base-info v-else-if="currentNode === 4 || currentNode === 5" ref="baseInfoRef"></recheck-approve-base-info>
<!-- 流程审批信息 -->
<div class="process-part-title" v-if="!onlyLook">{{ $t('processApprovalInformation') }}</div>
@@ -163,18 +163,21 @@ export default {
// 初始化节点
const taskName = this.$route.query.taskName
if (taskName) {
if (taskName === '发起人发起') {
if (taskName === '标准化发起') {
// 发起人发起
this.currentNode = 1
} else if (taskName === '联络人发起') {
// 联络人发起
this.currentNode = 2
} else if (taskName === '起草人填写意见') {
// 起草人填写意见
this.currentNode = 2
this.currentNode = 3
} else if (taskName === '起草人部长审批') {
// 起草人部长审批
this.currentNode = 3
this.currentNode = 4
} else if (taskName === '标准化审批') {
// 标准化审批
this.currentNode = 4
this.currentNode = 5
} else {
// 预留加签节点
this.currentNode = 999
@@ -184,10 +187,8 @@ export default {
this.getPersonInfoStructure(ProcessKey.ES_RECHECK.value, () => {
// 获取完人员信息结构,初始化人员信息是否可更改
if (this.$route.query.processInstanceId) {
if (this.currentNode === 1) {
if (this.currentNode === 1 || this.currentNode === 2) {
this.disabled = false
// 是节点1的话还需要设置是联络人发起还是标准化发起 ??
this.initRole = 'contact'
this.initPersonInfoData(true)
} else {
this.disabled = true
@@ -201,7 +202,14 @@ export default {
// 有流程id说明是从流程中心来的,需要初始化数据
this.getProcessData(this.$route.query.taskId)
} else {
this.currentNodeName = '发起人发起'
this.currentNodeName = '联络人发起'
}
if (this.$route.query.recheckPlanId) {
this.$nextTick(() => {
// 说明是从企标复审计划页面发起跳转过来的
this.$refs.baseInfoRef.formInline.recheckPlanId = this.$route.query.recheckPlanId
this.$refs.baseInfoRef.setFormById(this.$route.query.recheckPlanId)
})
}
// 如果是查看进入的,不可编辑,不可操作
if (this.$route.query.onlyLook) {
@@ -217,7 +225,6 @@ export default {
onlyLook: false, // 是否仅查看
currentNode: 1, // 当前节点
currentNodeName: '',
initRole: 'standardization', // 发起角色,发起的时候角色不一样表单不一样,contact联络人发起,standardization标准化发起
model: {},
processInfoForm: this.$form.createForm(this),
labelCol: {
@@ -11,12 +11,12 @@
{{ $t('workCenter.enterpriseInitChangePlan.enterpriseStandardNum') }}
</span>
</div>
<a-form-model-item class="item-model" prop="standardNumber">
<standard-selection :source="StandardSource.ENTERPRISE.value"
<a-form-model-item class="item-model" prop="recheckPlanId">
<enterprise-recheck-plan-selection
:disabled="disabled"
:disabledSourceSearch="true"
type="radio"
v-model="formInline.standardNumber"
v-model="formInline.recheckPlanId"
:standardNumber="formInline.standardNumber"
@listChange="listChange" />
</a-form-model-item>
</div>
@@ -122,12 +122,15 @@
<script>
import { StandardSource } from '@/enums/commonEnums'
import StandardSelection from '@/components/selection/StandardSelection'
import EnterpriseRecheckPlanSelection from '@/components/selection/EnterpriseRecheckPlanSelection'
import UserSelection from '@/components/selection/UserSelection'
import { getEnterpriseStandardInfoById } from '@/api/enterpriseStandardLibraryApi'
import {
getEnterpriseStandardInfoById,
getEnterpriseRecheckPlanById
} from '@/api/enterpriseStandardLibraryApi'
export default {
name: 'ContactInitBaseInfo',
components: { StandardSelection, UserSelection },
components: { EnterpriseRecheckPlanSelection, UserSelection },
props: {
disabled: {
type: Boolean,
@@ -142,7 +145,7 @@ export default {
formInline: {},
rules: {
// 企标编号
standardNumber: [
recheckPlanId: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.enterpriseStandardNum') + this.$t('cannotEmpty'),
@@ -177,26 +180,55 @@ export default {
})
return data
},
// 设置表单值,根据id
setFormById (recheckPlanId) {
this.loadind = true
getEnterpriseRecheckPlanById({ id: recheckPlanId }).then(res => {
if (res.success) {
const result = res.result
// 企标编号
this.formInline.standardNumber = result.standardNo
// 企标名称
this.formInline.standardName = result.standardName
// 发布日期
this.formInline.releaseDate = result.releaseDate
// 主起草人
this.formInline.mainDraftingUser = result.mainDraftingUser
this.formInline.mainDraftingUser_dictText = result.mainDraftingUser_dictText
// 主起草单位
this.formInline.mainDraftingUnit = result.mainDraftingUnit
// 复审日期
this.formInline.recheckDate = result.recheckDate
// 实施日期
this.formInline.implementationDate = result.implementationDate
}
}).finally(() => {
this.loading = false
})
this.$emit('processNameChange', (this.formInline.standardNumber || '') + '-' + (this.formInline.standardName || '') + '-' + '复审')
},
// 选完企标编号了,需要回显内容,返回流程名称
listChange (value) {
console.log(value)
this.loading = true
// 企标编号
this.formInline.standardNumber = value[0].standardNo
// 企标名称
this.formInline.standardName = value[0].standardName
getEnterpriseStandardInfoById({ id: value[0].id, type: '2' }).then(res => {
// 发布日期
this.formInline.releaseDate = value[0].releaseDate
// 主起草人
this.formInline.mainDraftingUser = value[0].mainDraftingUser
this.formInline.mainDraftingUser_dictText = value[0].mainDraftingUser_dictText
// 主起草单位
this.formInline.mainDraftingUnit = value[0].mainDraftingUnit
// 复审日期
this.formInline.recheckDate = value[0].recheckDate
getEnterpriseStandardInfoById({ standardNumber: value[0].standardNo, type: '2' }).then(res => {
if (res.success) {
const result = res.result
// 发布日期
this.formInline.releaseDate = result.release_date
// 实施日期
this.formInline.implementationDate = result.implementation_date
// 主起草人
this.formInline.mainDraftingUser = result.main_drafting_user
this.formInline.mainDraftingUser_dictText = result.main_drafting_user_dictText
// 主起草单位
this.formInline.mainDraftingUnit = result.main_drafting_unit
// 复审日期??
this.formInline = Object.assign({}, this.formInline)
}
}).finally(() => {
this.loading = false
@@ -11,11 +11,11 @@
</span>
</div>
<a-form-model-item class="item-model" prop="standardNumber">
<standard-selection :source="StandardSource.ENTERPRISE.value"
<enterprise-recheck-plan-selection
:disabled="disabled"
:disabledSourceSearch="true"
type="radio"
v-model="formInline.standardNumber"
:standardNumber="formInline.standardNumber"
@listChange="listChange" />
</a-form-model-item>
</div>
@@ -59,12 +59,12 @@
<script>
import { StandardSource } from '@/enums/commonEnums'
import StandardSelection from '@/components/selection/StandardSelection'
import UserSelection from '@/components/selection/UserSelection'
import EnterpriseRecheckPlanSelection from '@/components/selection/EnterpriseRecheckPlanSelection'
export default {
name: 'StandardizationInitBaseInfo',
components: { StandardSelection, UserSelection },
components: { EnterpriseRecheckPlanSelection, UserSelection },
props: {
disabled: {
type: Boolean,
@@ -78,7 +78,7 @@ export default {
formInline: {},
rules: {
// 企标编号
standardNumber: [
recheckPlanId: [
{
required: true,
message: this.$t('workCenter.enterpriseInitChangePlan.enterpriseStandardNum') + this.$t('cannotEmpty'),
@@ -127,7 +127,8 @@ export default {
// 企标名称
this.formInline.standardName = value[0].standardName
// 主起草人赋值给联络人
// this.formInline.contactPerson = value[0].
this.formInline.contactPerson = value[0].mainDraftingUser
this.formInline.contactPerson_dictText = value[0].mainDraftingUser_dictText
this.$emit('processNameChange', (this.formInline.standardNumber || '') + '-' + (this.formInline.standardName || '') + '-' + '复审')
},
// 选择用户得到用户名