[update] 修改UAT问题:企标复审计划增加批量复审功能

This commit is contained in:
lideqin
2024-09-14 09:08:26 +08:00
parent 2f9f471883
commit 652c5c6675
3 changed files with 31 additions and 3 deletions
+4 -1
View File
@@ -65,6 +65,8 @@ const getEnterpriseRecheckPlanPage = (params) => getAction('/enterprise/recheckP
// 企标复审计划-根据id获取数据 // 企标复审计划-根据id获取数据
const getEnterpriseRecheckPlanById = (id, params) => getAction(`/enterprise/recheckPlan/getById/${id}`, params) const getEnterpriseRecheckPlanById = (id, params) => getAction(`/enterprise/recheckPlan/getById/${id}`, params)
// 企标复审计划-批量复审
const reviewPlanBatchReview = (params) => postAction('/enterprise/recheckPlan/batchStartRecheckPlan', params)
export { export {
getEnterpriseStandardTableHeader, getEnterpriseStandardTableHeader,
@@ -101,5 +103,6 @@ export {
getEnterpriseStandardPlanPage, getEnterpriseStandardPlanPage,
getEnterpriseRecheckPlanPage, getEnterpriseRecheckPlanPage,
getEnterpriseRecheckPlanById getEnterpriseRecheckPlanById,
reviewPlanBatchReview
} }
@@ -126,6 +126,7 @@ module.exports = {
publishDate: '发布日期', publishDate: '发布日期',
reviewDate: '复审日期', reviewDate: '复审日期',
initReview: '发起复审', initReview: '发起复审',
batchReview: '批量复审',
reviewResult: '复审结果', reviewResult: '复审结果',
principalDrafter: '主起草人', principalDrafter: '主起草人',
mainDraftingUnit: '主起草单位' mainDraftingUnit: '主起草单位'
@@ -61,6 +61,11 @@
@click="handleInitReview"> @click="handleInitReview">
{{ $t('enterpriseStandardLibrary.reviewPlan.initReview') }} {{ $t('enterpriseStandardLibrary.reviewPlan.initReview') }}
</a-button> </a-button>
<!-- 批量复审 -->
<a-button icon="plus" type="primary" ghost v-has="'enterpriseStandardLibrary:reviewPlan:initReview'"
@click="handleBatchReview">
{{ $t('enterpriseStandardLibrary.reviewPlan.batchReview') }}
</a-button>
</div> </div>
<div> <div>
@@ -73,7 +78,7 @@
:dataSource="dataSource" :dataSource="dataSource"
:pagination="ipagination" :pagination="ipagination"
:loading="loading" :loading="loading"
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange, type: 'radio'}" :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
@change="handleTableChange"> @change="handleTableChange">
<!-- 企标编号/企标名称 --> <!-- 企标编号/企标名称 -->
@@ -101,6 +106,7 @@
<script> <script>
import JTable from '@/components/jero/JTable' import JTable from '@/components/jero/JTable'
import { JeroListMixin } from '@/mixins/JeroListMixin' import { JeroListMixin } from '@/mixins/JeroListMixin'
import { reviewPlanBatchReview } from '../../../api/enterpriseStandardLibraryApi'
export default { export default {
name: 'ReviewPlanList', name: 'ReviewPlanList',
@@ -208,7 +214,7 @@ export default {
}, },
// 发起复审 // 发起复审
handleInitReview () { handleInitReview () {
if (this.selectedRowKeys.length <= 0) { if (this.selectedRowKeys.length !== 1) {
this.$message.warning(this.$t('selectARecord')) this.$message.warning(this.$t('selectARecord'))
return return
} }
@@ -218,6 +224,24 @@ export default {
recheckPlanId: this.selectedRowKeys[0] recheckPlanId: this.selectedRowKeys[0]
} }
}) })
},
// 批量复审
handleBatchReview () {
if (this.selectedRowKeys.length <= 0) {
this.$message.warning(this.$t('selectAtLeastOne'))
return
}
const param = {}
param.recheckPlanIds = this.selectedRowKeys.join(',')
reviewPlanBatchReview(param).then(res => {
if (res.success) {
this.$message.success(res.message)
this.loadData()
this.selectedRowKeys = []
} else {
this.$message.warning(res.message)
}
})
} }
} }
} }