项目详情 相关人员名单表头排序

This commit is contained in:
范强强
2023-10-20 13:56:05 +08:00
parent 7788adc21d
commit 3666038b2a
@@ -72,24 +72,24 @@
</div> </div>
</a-col> </a-col>
<!-- <a-col :md="12" :sm="8">--> <!-- <a-col :md="12" :sm="8">-->
<!-- <div class="box-title-text-search">--> <!-- <div class="box-title-text-search">-->
<!-- <div class="title-text-search" :title="$t('certifiedEngineer')">--> <!-- <div class="title-text-search" :title="$t('certifiedEngineer')">-->
<!-- <span>{{$t('certifiedEngineer')}}</span>--> <!-- <span>{{$t('certifiedEngineer')}}</span>-->
<!-- </div>--> <!-- </div>-->
<!-- <a-select class="box-input-search"--> <!-- <a-select class="box-input-search"-->
<!-- v-model="queryParam.certificationEngineer"--> <!-- v-model="queryParam.certificationEngineer"-->
<!-- :placeholder="$t('PleaseSelect')+$t('certifiedEngineer')">--> <!-- :placeholder="$t('PleaseSelect')+$t('certifiedEngineer')">-->
<!-- <a-select-option v-for="(item, key) in dictOptionsValue"--> <!-- <a-select-option v-for="(item, key) in dictOptionsValue"-->
<!-- :key="item.certificationEngineer"--> <!-- :key="item.certificationEngineer"-->
<!-- :value="item.certificationEngineer">--> <!-- :value="item.certificationEngineer">-->
<!-- <span class="itemOption" :title=" item.certificationEngineerName ">--> <!-- <span class="itemOption" :title=" item.certificationEngineerName ">-->
<!-- {{ item.certificationEngineerName }}--> <!-- {{ item.certificationEngineerName }}-->
<!-- </span>--> <!-- </span>-->
<!-- </a-select-option>--> <!-- </a-select-option>-->
<!-- </a-select>--> <!-- </a-select>-->
<!-- </div>--> <!-- </div>-->
<!-- </a-col>--> <!-- </a-col>-->
</template> </template>
<span style="float: right;overflow: hidden;margin-right: 11px;margin-bottom: 20px" <span style="float: right;overflow: hidden;margin-right: 11px;margin-bottom: 20px"
class="table-page-search-submitButtons"> class="table-page-search-submitButtons">
@@ -165,9 +165,9 @@
:title="$t('projectInterfacePersonCertificationEngineerSetting')"> :title="$t('projectInterfacePersonCertificationEngineerSetting')">
{{$t('projectInterfacePersonCertificationEngineerSetting')}} {{$t('projectInterfacePersonCertificationEngineerSetting')}}
</span> </span>
<span slot="certifiedEngineer" :title="$t('certifiedEngineer')"> <!-- <span slot="certifiedEngineer" :title="$t('certifiedEngineer')">-->
{{$t('certifiedEngineer')}} <!-- {{$t('certifiedEngineer')}}-->
</span> <!-- </span>-->
</a-table> </a-table>
<!-- <div class="page">--> <!-- <div class="page">-->
<!-- <a-pagination--> <!-- <a-pagination-->
@@ -363,7 +363,7 @@
data() { data() {
return { return {
toggleSearchStatus: false, toggleSearchStatus: false,
firstLevelDutyTerritoryList:[], firstLevelDutyTerritoryList: [],
visible: false, visible: false,
queryParam: {}, queryParam: {},
selectVisible: false, selectVisible: false,
@@ -375,7 +375,7 @@
align: 'left', align: 'left',
dataIndex: 'firstLevelDutyTerritory', dataIndex: 'firstLevelDutyTerritory',
ellipsis: true, ellipsis: true,
sorter:true, sorter: true,
width: 100 width: 100
}, },
{ {
@@ -383,23 +383,23 @@
align: 'left', align: 'left',
dataIndex: 'dutyTerritory_dictText', dataIndex: 'dutyTerritory_dictText',
ellipsis: true, ellipsis: true,
sorter:true, sorter: true,
width: 100 width: 100
}, },
{ {
align: 'left', align: 'left',
dataIndex: 'lawEngineerName', dataIndex: 'lawEngineerName',
slots: { title: 'regulatoryEngineer' }, scopedSlots: { title: 'regulatoryEngineer' },
ellipsis: true, ellipsis: true,
sorter:true, sorter: true,
width: 153 width: 153
}, },
{ {
align: 'left', align: 'left',
slots: { title: 'engineeringInterfacePerson' }, scopedSlots: { title: 'engineeringInterfacePerson' },
dataIndex: 'engineeringInterfacePersonName', dataIndex: 'engineeringInterfacePersonName',
ellipsis: true, ellipsis: true,
sorter:true, sorter: true,
width: 153 width: 153
}, },
// { // {
@@ -411,18 +411,18 @@
// }, // },
{ {
align: 'left', align: 'left',
slots: { title: 'projectInterfacePersonRegulationEngineerSetting' }, scopedSlots: { title: 'projectInterfacePersonRegulationEngineerSetting' },
dataIndex: 'engineerLawSetName', dataIndex: 'engineerLawSetName',
ellipsis: true, ellipsis: true,
sorter:true, sorter: true,
width: 213 width: 213
}, },
{ {
align: 'left', align: 'left',
slots: { title: 'projectInterfacePersonCertificationEngineerSetting' }, scopedSlots: { title: 'projectInterfacePersonCertificationEngineerSetting' },
dataIndex: 'engineerAttSetName', dataIndex: 'engineerAttSetName',
ellipsis: true, ellipsis: true,
sorter:true, sorter: true,
width: 213 width: 213
}, },
{ {
@@ -430,7 +430,7 @@
align: 'left', align: 'left',
dataIndex: 'remark', dataIndex: 'remark',
ellipsis: true, ellipsis: true,
sorter:true, sorter: true,
width: 188 width: 188
}, },
{ {
@@ -471,11 +471,11 @@
align: 'left', align: 'left',
dataIndex: 'replacementPerson', dataIndex: 'replacementPerson',
width: 180, width: 180,
scopedSlots: {customRender: 'replacementPerson'} scopedSlots: { customRender: 'replacementPerson' }
} }
], ],
dataSource: [], dataSource: [],
selectDataSource:[], selectDataSource: [],
loading: false, loading: false,
editVisible: false, editVisible: false,
confirmLoading: false, confirmLoading: false,
@@ -550,10 +550,10 @@
selectedRowKeys: [], selectedRowKeys: [],
dictOptionsValue: [], dictOptionsValue: [],
administrators: false, administrators: false,
userIds:'', userIds: '',
userName:'', userName: '',
orderBy: '1', orderBy: '1',
orderByField: '', orderByField: ''
} }
}, },
computed: { computed: {
@@ -594,14 +594,14 @@
} }
}) })
}, },
PersonnelSelectionOneChange(value, id, index){ PersonnelSelectionOneChange(value, id, index) {
this.selectDataSource[index][value] = id this.selectDataSource[index][value] = id
this.selectDataSource = [...this.selectDataSource] this.selectDataSource = [...this.selectDataSource]
}, },
selecthandleCancel(){ selecthandleCancel() {
this.selectVisible = false this.selectVisible = false
}, },
selecthandleSubmit(){ selecthandleSubmit() {
if (this.selectDataSource.length > 0) { if (this.selectDataSource.length > 0) {
let replacementUserList = [] let replacementUserList = []
this.selectDataSource.forEach(res => { this.selectDataSource.forEach(res => {
@@ -648,14 +648,15 @@
this.getUserAllDutyTerritoryList() this.getUserAllDutyTerritoryList()
}, },
tableOnChange(pagination, filters, sorter) { tableOnChange(pagination, filters, sorter) {
console.log(sorter)
this.orderBy = sorter.order == 'ascend' ? '1' : '2' this.orderBy = sorter.order == 'ascend' ? '1' : '2'
if (sorter.columnKey == 'dutyTerritory_dictText') { if (sorter.columnKey == 'dutyTerritory_dictText') {
this.orderByField = 'dutyTerritory' this.orderByField = 'dutyTerritory'
} else if (sorter.columnKey == 'lawEngineerName') { } else if (sorter.columnKey == 'lawEngineerName') {
this.orderByField = 'lawEngineer' this.orderByField = 'lawEngineer'
}else if (sorter.columnKey == 'engineeringInterfacePersonName') { } else if (sorter.columnKey == 'engineeringInterfacePersonName') {
this.orderByField = 'engineeringInterfacePerson' this.orderByField = 'engineeringInterfacePerson'
}else if (sorter.columnKey == 'engineerLawSetName') { } else if (sorter.columnKey == 'engineerLawSetName') {
this.orderByField = 'engineerLawSet' this.orderByField = 'engineerLawSet'
} else if (sorter.columnKey == 'engineerAttSetName') { } else if (sorter.columnKey == 'engineerAttSetName') {
this.orderByField = 'engineerAttSet' this.orderByField = 'engineerAttSet'
@@ -790,7 +791,7 @@
projectId: this.$route.query.id, projectId: this.$route.query.id,
...this.queryParam, ...this.queryParam,
orderBy: this.orderBy, orderBy: this.orderBy,
orderByField: this.orderByField, orderByField: this.orderByField
} }
this.loading = true this.loading = true
postAction(this.url.page, query).then((res) => { postAction(this.url.page, query).then((res) => {