【bug】标协会员会议维护不显示发布 列表不显示已提醒字段

This commit is contained in:
fengachen
2021-10-22 16:03:33 +08:00
parent 69894599c9
commit cc6a0c3e32
2 changed files with 62 additions and 59 deletions
@@ -51,8 +51,8 @@
</j-date>
</a-form-item>
</a-col>
<a-col :xl="6" :lg="7" :md="8" :sm="24">
<!-- 标协会议不显示-->
<a-col :xl="6" :lg="7" :md="8" :sm="24" v-if="$route.query.meetingType === '5' ">
<a-form-item label="已提醒" :labelCol="labelCol" :wrapperCol="wrapperCol">
<j-dict-select-tag style="width: 100%"
dict-code="yn"
@@ -62,7 +62,8 @@
</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" v-has:[authorCode.search]="'committeeMeeting:search'">查询</a-button>
<a-button type="primary" icon="search" @click="searchQuery"
v-has:[authorCode.search]="'committeeMeeting:search'">查询</a-button>
<a-button icon="reload" @click="searchReset" class="reset-button">重置</a-button>
</span>
</a-col>
@@ -73,11 +74,18 @@
<!-- 操作按钮区域-->
<div class="table-operator">
<a-button type="primary" icon="plus" @click="handleAdd" v-has:[authorCode.add]="'committeeMeeting:add'">新增</a-button>
<a-button type="primary" icon="export" @click="handleExportXls('会议维护')" v-has:[authorCode.search]="'committeeMeeting:export'">导出</a-button>
<a-button type="danger" icon="delete" @click="batchDel" v-has:[authorCode.batchDel]="'committeeMeeting:batchDel'">批量删除</a-button>
<a-button type="primary" icon="plus" @click="handleAdd" v-has:[authorCode.add]="'committeeMeeting:add'">新增
</a-button>
<a-button type="primary" icon="export" @click="handleExportXls('会议维护')"
v-has:[authorCode.search]="'committeeMeeting:export'">导出
</a-button>
<a-button type="danger" icon="delete" @click="batchDel"
v-has:[authorCode.batchDel]="'committeeMeeting:batchDel'">批量删除
</a-button>
<!--只有工作会议与分标委会议才有-->
<a-button type="primary" @click="publishRemind" v-if="meetingType === '5' " v-has="'committeeMeeting:publish'">发布</a-button>
<a-button type="primary" @click="publishRemind" v-if="meetingType === '5' " v-has="'committeeMeeting:publish'">
发布
</a-button>
</div>
<!-- /操作按钮区域-end-->
@@ -89,7 +97,7 @@
bordered
rowKey="id"
:scroll="{x:true}"
:columns="columns"
:columns="newColumns"
:dataSource="dataSource"
:pagination="ipagination"
:loading="loading"
@@ -98,7 +106,8 @@
class="j-table-force-nowrap">
<template slot="htmlSlot" slot-scope="text,record">
<j-ellipsis class="primary-color" @click="toAttendance(record)" v-if="text" :value="text" :length="20"></j-ellipsis>
<j-ellipsis class="primary-color" @click="toAttendance(record)" v-if="text" :value="text"
:length="20"></j-ellipsis>
<span v-else></span>
</template>
@@ -185,13 +194,6 @@ export default {
width: 100,
scopedSlots: {customRender: 'text'}
},
{
title: '已提醒',
align: 'center',
dataIndex: 'remind_dictText',
width: 80,
scopedSlots: {customRender: 'text'}
},
{
title: '负责人',
align: 'center',
@@ -204,7 +206,8 @@ export default {
align: 'center',
dataIndex: 'startTime',
width: 160,
customRender: (text, record) => (<j-ellipsis value={record.startTime + '~' + record.endTime} length={20}></j-ellipsis>)
customRender: (text, record) => (
<j-ellipsis value={record.startTime + '~' + record.endTime} length={20}></j-ellipsis>)
},
{
title: '召开地点',
@@ -241,51 +244,51 @@ export default {
scopedSlots: {customRender: 'action'}
},
],
newColumns: [],
// 权限编码
authorCode:{
},
authorCode: {},
// 分标委的权限编码
committeeMeetingAuthorCode:{
add:'committeeMeeting:add',
search:'committeeMeeting:search',
export:'committeeMeeting:export',
batchDel:'committeeMeeting:batchDel',
upload:'committeeMeeting:upload',
edit:'committeeMeeting:edit',
delete:'committeeMeeting:delete'
committeeMeetingAuthorCode: {
add: 'committeeMeeting:add',
search: 'committeeMeeting:search',
export: 'committeeMeeting:export',
batchDel: 'committeeMeeting:batchDel',
upload: 'committeeMeeting:upload',
edit: 'committeeMeeting:edit',
delete: 'committeeMeeting:delete'
},
// 标协会议的权限编码
standardsMeetingAuthorCode:{
add:'standardsMeeting:add',
search:'standardsMeeting:search',
export:'standardsMeeting:export',
batchDel:'standardsMeeting:batchDel',
upload:'standardsMeeting:upload',
edit:'standardsMeeting:edit',
delete:'standardsMeeting:delete'
standardsMeetingAuthorCode: {
add: 'standardsMeeting:add',
search: 'standardsMeeting:search',
export: 'standardsMeeting:export',
batchDel: 'standardsMeeting:batchDel',
upload: 'standardsMeeting:upload',
edit: 'standardsMeeting:edit',
delete: 'standardsMeeting:delete'
}
}
},
created() {
this.filters.meetingType = this.meetingType
// 分标委会议需要加上分标委id
if(this.meetingType === '5'){
if (this.meetingType === '5') {
// 在这改变v-has 的值 用分标委的会议权限
this.authorCode = Object.assign({},this.committeeMeetingAuthorCode)
this.authorCode = Object.assign({}, this.committeeMeetingAuthorCode)
this.filters.caseCommitteeId = this.caseCommitteeId
}
// 如果是标协会议 用标协会议权限
if(this.meetingType === '2'){
this.authorCode = Object.assign({},this.standardsMeetingAuthorCode)
if (this.meetingType === '2') {
this.authorCode = Object.assign({}, this.standardsMeetingAuthorCode)
}
this.loadData(1)
// 不是分标委会议去掉提醒字段
if (this.meetingType !== 5) {
console.log(this.columns)
if (this.meetingType !== '5') {
this.newColumns = [...this.columns]
// 找出提醒字段的索引
let index = this.columns.findIndex(item => item.dataIndex === 'remind_dictText')
this.columns.splice(index, 1)
this.newColumns = this.newColumns.filter(item => item.dataIndex !== 'remind_dictText')
} else {
this.newColumns = [...this.columns]
}
},
computed: {
@@ -297,23 +300,23 @@ export default {
return this.$route.query.meetingType + ''
},
// 分标委id
caseCommitteeId(){
caseCommitteeId() {
return this.$route.query.id ? this.$route.query.id : undefined
},
// eslint-disable-next-line
url() {
let meetingType = this.$route.query.meetingType + ''
let meetingType = this.$route.query.meetingType + ''
// 标协会议
if(meetingType === '2'){
if (meetingType === '2') {
return {
list: '/meeting/standardsMeeting/page',
delete: '/meeting/standardsMeeting/delete',
deleteBatch: '/meeting/standardsMeeting/deleteBatch',
exportXlsUrl: '/meeting/standardsMeeting/exportXls',
}
}else if(meetingType === '5') {
} else if (meetingType === '5') {
// 分标委会议
return {
return {
list: '/meeting/committeeMeeting/page',
delete: '/meeting/committeeMeeting/delete',
deleteBatch: '/meeting/committeeMeeting/deleteBatch',
@@ -328,21 +331,21 @@ export default {
* */
handleAdd() {
// 分标委的新增应该是需要分标委的id
if(this.meetingType === '5'){
if (this.meetingType === '5') {
this.$router.push({
path: '/incomePayments/meetManage/AddOrDetailMeet',
query: {
meetingType:this.meetingType,
caseCommitteeId:this.caseCommitteeId
meetingType: this.meetingType,
caseCommitteeId: this.caseCommitteeId
}
})
}
// 标协会议新增
if(this.meetingType === '2'){
if (this.meetingType === '2') {
this.$router.push({
path: '/incomePayments/meetManage/AddOrDetailMeet',
query: {
meetingType:this.meetingType
meetingType: this.meetingType
}
})
}
@@ -365,12 +368,12 @@ export default {
* 参会情况
* */
toAttendance(record) {
let path =''
let path = ''
let meetingType = this.$route.query.meetingType + ''
// 分标委会议与标协会议的跳转
if(meetingType === '2' ){
if (meetingType === '2') {
path = '/incomePayments/meetManage/AttendanceStandardsMeeting'
}else if(meetingType === '5'){
} else if (meetingType === '5') {
path = '/incomePayments/meetManage/AttendanceCommitteeMeeting'
}
this.$router.push({
@@ -378,7 +381,7 @@ export default {
query: {
id: record.id,
meetingName: record.meetingName,
meetingType:meetingType
meetingType: meetingType
}
})
},
@@ -197,7 +197,7 @@ export default {
// 选择多个会议的时候不需要提醒字段 这样写是因为无法精准定位每一个人对应的每一个会议 这个人是否被提醒
if (meetingList.length > 1) {
// 去掉列表的提醒字段
this.newColumns = this.newColumns.filter(item => item.dataIndex !== 'remind')
this.newColumns = this.newColumns.filter(item => item.dataIndex !== 'remind_dictText')
}
this.searchReset()
},