[add] -增加问题征集 相关的功能

This commit is contained in:
fengchenchen
2022-07-14 17:00:19 +08:00
parent 063bf9086e
commit a596796da5
6 changed files with 328 additions and 10 deletions
+6 -1
View File
@@ -26,6 +26,10 @@ const addGenerateCodeList = (params) => postAction('/meeting/randomCode/add', pa
// 国际研讨会--列表页编辑一条随机码数据
const editGenerateCodeList = (params) => postAction('/meeting/randomCode/edit', params)
// 标协会议-问题征集详情-查询标准号下拉框数据
const getStandardNumberList = (params) => getAction('/meeting/standardsMeeting/getStandardNumberList', params)
export {
getUserInfo,
getMeetInfoById,
@@ -37,5 +41,6 @@ export {
getGeneratedCodeList,
generateCode,
addGenerateCodeList,
editGenerateCodeList
editGenerateCodeList,
getStandardNumberList
}
@@ -46,9 +46,12 @@
<!-- 编辑的时候按照不同的类型显示不同的数据: 标准宣贯、学习培训一起显示; 信息交流会单独显示 -->
<j-dict-select-tag
ref="standardMeetingType"
v-decorator="['tbMeetingType',validatorRules.tbMeetingType]" :trigger-change="true"
style="width: 100%" dict-code="standard_meeting_type"
v-decorator="['tbMeetingType',validatorRules.tbMeetingType]"
:trigger-change="true"
style="width: 100%"
dict-code="standard_meeting_type"
placeholder="请选择标协会议类型"
@change="tbMeetingTypeChange"
></j-dict-select-tag>
</a-form-item>
</a-col>
@@ -139,8 +142,8 @@
</a-row>
<!--会议信息end-->
<!-- 会议问题征集--只有标协会议存在 -->
<section v-if="meetingType === '2'" >
<!-- 会议问题征集--只有标协会议存在 -->
<section v-if="meetingType === '2' && (tbMeetingType === 1 || tbMeetingType === 2)" >
<!-- 选择是否需要问题征集-->
<a-row :gutter="24">
<a-col :xxl="8" :xl="12" :sm="24">
@@ -568,6 +571,8 @@ export default {
meetingType: '',
// 是否需要 问题征集
isAddQuestion: 0,
// 标协会议类型
tbMeetingType: undefined,
}
},
computed: {
@@ -706,10 +711,6 @@ export default {
if (this.meetingType === '2') {
console.log('this.model', this.model)
let otherKeys = []
if(this.model.isAddQuestion) {
otherKeys = ['endTimeAddQuestion', 'questionList']
}
this.form.setFieldsValue(pick(this.model, 'signInTime', 'tbMeetingType', 'meetingCostsVip', 'isAddQuestion', ...otherKeys))
// 编辑情况下 判断类型改变“标协会议类型”选择框的下拉框数
if (this.model.id) {
let arr = this.$refs.standardMeetingType.getCurrentDictOptions()
@@ -717,10 +718,18 @@ export default {
// 信息交流会议
this.$refs.standardMeetingType.setCurrentDictOptions(arr.splice(2, 1))
}else {
this.model.isAddQuestion = Number(this.model.isAddQuestion)
this.isAddQuestion = this.model.isAddQuestion
if(this.model.isAddQuestion) {
otherKeys = ['endTimeAddQuestion', 'questionList']
}
// 标准宣贯或者学习培训
this.$refs.standardMeetingType.setCurrentDictOptions(arr.splice(0, 2))
}
}
setTimeout(() => {
this.form.setFieldsValue(pick(this.model, 'signInTime', 'tbMeetingType', 'meetingCostsVip', 'isAddQuestion', ...otherKeys))
})
}
// 如果是工作组会议 赋值工作组
if (this.meetingType === '1') {
@@ -843,6 +852,19 @@ export default {
}
},
/*
* 监听标协会议类型变化
* */
tbMeetingTypeChange(val) {
this.tbMeetingType = Number(val)
// 标准宣贯、学习培训 有问题征集功能
if (this.tbMeetingType === 1 || this.tbMeetingType === 2) {
this.isAddQuestion = 0
this.$nextTick(() => {
this.form.setFieldsValue({ isAddQuestion: this.isAddQuestion })
})
}
},
/*
* 会议负责人
* */
selectPerson(val) {
@@ -47,6 +47,21 @@
<a-col :xxl="8" :xl="12" :sm="24">
<label>预计参加人数</label><span>{{ currentMeetingInfo.estimatedNumber }}</span>
</a-col>
<!-- 标协会议标准宣贯学习培训是有 问题征集相关操作 和信息的-->
<template v-if="currentMeetingInfo.meetingType === '2' && (currentMeetingInfo.tbMeetingType === '1' || currentMeetingInfo.tbMeetingType === '2')">
<a-col :xxl="8" :xl="12" :sm="24">
<label>问题征集</label><span>{{ currentMeetingInfo.isAddQuestion === '1' ? '需要' : '不需要' }}</span>
</a-col>
<a-col :xxl="8" :xl="12" :sm="24" v-if="currentMeetingInfo.isAddQuestion === '1'">
<label>征集截止时间</label><span>{{ currentMeetingInfo.endTimeAddQuestion }}</span>
</a-col>
<a-row class="flex-col mul-row-row" v-if="currentMeetingInfo.isAddQuestion === '1'">
<label class="label">标准号及标准名称</label>
<span class="mul-row-content">
<span class="content" v-for="(item,index) of currentMeetingInfo.questionList" :key="index">{{ '标准号' + item.standardNumber + '&nbsp;&nbsp;' + ' 标准名称' + item.standardName }}</span>
</span>
</a-row>
</template>
<a-col :xxl="8" :xl="12" :sm="24">
<label>酒店名称</label><span>{{ currentMeetingInfo.hotelName }}</span>
</a-col>
@@ -965,6 +980,7 @@ export default {
display: block;
.content{
display: block;
white-space: pre-wrap;
}
}
</style>
@@ -0,0 +1,203 @@
<template>
<div>
<a-card :bordered="false">
<!-- 查询区域-start -->
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="问题征集截止时间" :labelCol="labelCol" :wrapperCol="wrapperCol">
<span>{{model.registerDeadline}}</span>
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="状态" :labelCol="labelCol" :wrapperCol="wrapperCol">
<span>{{model.addQuestionStatue}}</span>
</a-form-item>
</a-col>
</a-row>
<a-row>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="标准号" :labelCol="labelCol" :wrapperCol="wrapperCol">
<a-select style="width:100%" placeholder="请选择标准号" v-model="queryParam.standardNumber" show-search allowClear>
<a-select-option v-for="item in standardNumberArr" :key="item" :value="item">{{item}}</a-select-option>
</a-select>
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<a-form-item label="提问人" :labelCol="labelCol" :wrapperCol="wrapperCol">
<a-input placeholder="请输入提问人" v-model="queryParam.dutyCode" :maxLength='50'></a-input>
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<span class="table-page-search-submitButtons">
<a-button type="primary" icon="search" @click="searchQuery">查询</a-button>
<a-button icon="reload" @click="searchReset" class="reset-button">重置</a-button>
</span>
</a-col>
</a-row>
</a-form>
</div>
<!-- 查询区域-end-->
<!-- 操作按钮区域-->
<div class="table-operator">
<a-button type="primary" icon="export" @click="handleExportXls('问题征集')">导出</a-button>
</div>
<!-- 操作按钮区域-end-->
<!-- table表格区域-->
<div>
<a-table
ref="table"
size="middle"
bordered
rowKey="id"
:columns="columns"
:scroll="{x: 1600}"
:dataSource="dataSource"
:pagination="ipagination"
:loading="loading"
:rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
@change="handleTableChange"
class="j-table-force-nowrap">
<template slot="text" slot-scope="text">
<a-tooltip>
<template v-if="text" slot="title">{{ text }}</template>
<div class="table-text">{{ text }}</div>
</a-tooltip>
</template>
</a-table>
</div>
<business-management-module ref="modalForm" @ok="modalFormOk"></business-management-module>
</a-card>
</div>
</template>
<script>
import {JeroListMixin} from '@/mixins/JeroListMixin'
import {getStandardNumberList} from '../../../../api/incomeMeetingApi'
import {downloadPostFile } from '../../../../api/manage'
export default {
name: 'ProblemCollectionList',
components: {},
mixins: [JeroListMixin],
computed: {
importExcelUrl: function () {
return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`
}
},
data() {
return {
model: {},
labelCol: {
xs: {span: 24},
sm: {span: 5}
},
wrapperCol: {
xs: {span: 24},
sm: {span: 10}
},
columns: [
{
title: '序号',
dataIndex: '',
key: 'rowIndex',
width: 60,
align: 'center',
customRender: function (t, r, index) {
return parseInt(index) + 1
}
}, {
title: '标准号',
align: 'center',
width: 280,
dataIndex: 'standardNumber',
scopedSlots: {customRender: 'text'}
},
{
title: '标准名称',
align: 'center',
width: 250,
dataIndex: 'standardName',
scopedSlots: {customRender: 'text'}
},
{
title: '章条编号',
align: 'center',
width: 280,
dataIndex: 'number',
scopedSlots: {customRender: 'text'}
},
{
title: '问题描述',
align: 'center',
width: 180,
dataIndex: 'questionName'
},
{
title: '提问人',
align: 'center',
width: 100,
dataIndex: 'status_dictText'
},
{
title: '提问人邮箱',
align: 'center',
width: 180,
dataIndex: 'createTime'
}
],
url: {
list: '/payMeetingQuestion/payMeetingQuestion/list',
exportXlsUrl: '/payMeetingQuestion/payMeetingQuestion/exportXls',
},
// 标准号下拉框的数据
standardNumberArr: [],
disableMixinCreated: true // 禁止初始化请求接口
}
},
methods: {
// 刷新列表页
refresh(record) {
this.initData(record)
this.getStandardNumberListFunc()
this.loadData(1)
},
// 初始化数据
initData(record) {
this.model = Object.assign({}, record)
this.filters.meetingId = record.id
},
// 获取 标准类别名称
getStandardNumberListFunc() {
this.standardNumberArr = []
getStandardNumberList({meetingId: this.model.id}).then(res => {
if(res.success) {
this.standardNumberArr = res.result || []
}
})
},
// 导出
handleExportXls(fileName) {
if (!fileName || typeof fileName != 'string') {
fileName = '导出文件'
}
let param = this.getQueryParams()
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
param['selections'] = this.selectedRowKeys.join(',')
}
console.log('导出参数', param)
downloadPostFile(this.url.exportXlsUrl, fileName + '.xlsx', param)
},
}
}
</script>
<style scoped lang="less">
@import '~@assets/less/common.less';
</style>
@@ -0,0 +1,58 @@
<!--问题征集的模态框-->
<template>
<j-modal
:title="title"
:width="width"
:visible="visible"
:confirmLoading="confirmLoading"
switchFullscreen
fullscreen
:footer="null"
@cancel="handleCancel"
cancelText="关闭">
<a-spin :spinning="confirmLoading">
<problem-collection-list ref="problemCollectionList"></problem-collection-list>
</a-spin>
</j-modal>
</template>
<script>
import ProblemCollectionList from './ProblemCollectionList'
export default {
name: 'ProblemCollectionModal',
components: {
ProblemCollectionList
},
data() {
return {
title: '问题征集详情',
width: 1200,
visible: false,
confirmLoading: false,
form: this.$form.createForm(this),
model: {},
}
},
methods: {
show(record) {
this.visible = true
this.title = `${record.meetingName}问题征集详情`
this.$nextTick(() => {
this.$refs.problemCollectionList.refresh(record)
})
},
close() {
this.$emit('close')
this.visible = false
},
handleCancel() {
this.close()
},
}
}
</script>
<style scoped>
</style>
@@ -143,12 +143,15 @@
<!-- <a @click="applyMsg">报名信息</a>-->
<a @click="handleEdit(record)" v-has:[authorCode.edit]="'committeeMeeting:edit'">编辑</a>
<a @click="handleDelete(record.id)" v-has:[authorCode.delete]="'committeeMeeting:delete'">删除</a>
<!-- 标协会议(标准宣贯学习培训 且需要问题征集)的时候 有问题征集 功能-->
<a v-if="meetingType === '2'" v-show="(record.tbMeetingType === 1 || record.tbMeetingType === 2) && record.isAddQuestion" @click="problemCollectionDetail(record)" v-has="'standardsMeeting:problemCollection'">问题征集</a>
</span>
</a-table>
</div>
<publish-remind-modal ref="publishRemindModal" @ok="modalFormOk"></publish-remind-modal>
<upload-meet-file-modal ref="modalForm" @ok="modalFormOk"></upload-meet-file-modal>
</a-card>
<problem-collection-modal ref="problemCollectionModal"></problem-collection-modal>
</div>
</template>
@@ -163,6 +166,8 @@ import PublishRemindModal from '@views/projectManagement/modules/PublishRemindMo
import UploadMeetFileModal from '@views/incomePayments/meetManage/modules/UploadMeetFileModal'
import PageHeaderTitle from '@comp/layouts/PageHeaderTitle'
import '@/assets/less/TableExpand.less'
// 问题征集 组件
import ProblemCollectionModal from '../incomePayments/meetManage/modules/ProblemCollectionModal'
export default {
name: 'CommitteeMeeting',
@@ -172,7 +177,8 @@ export default {
JDictSelectTag,
PublishRemindModal,
UploadMeetFileModal,
PageHeaderTitle
PageHeaderTitle,
ProblemCollectionModal
},
mixins: [JeroListMixin, RangeDateMixin],
data() {
@@ -497,6 +503,14 @@ export default {
this.lastQueryParam = {...this.queryParam}
this.loadData(1)
},
/*
* 问题征集按钮点击后的回调
* */
problemCollectionDetail(record) {
if(!record.isAddQuestion || !this.meetingType === '2') return
if(!(record.tbMeetingType === 1 || record.tbMeetingType === 2)) return
this.$refs.problemCollectionModal.show(record)
}
}
}
</script>