平台件项目库 关联平台件不勾选法规修改

This commit is contained in:
zyx.net
2023-09-20 16:24:02 +08:00
parent 73b590a8fe
commit 92dc4fc096
3 changed files with 28 additions and 13 deletions
@@ -149,6 +149,7 @@
pageSize: 10, pageSize: 10,
total: 0, total: 0,
type:'', type:'',
flag:'',
id:'', id:'',
ids:'', ids:'',
} }
@@ -157,9 +158,11 @@
}, },
methods: { methods: {
transferModel(id,type,ids) { transferModel(id,flag,type,ids) {
console.log(id,flag,type,ids)
this.id = id this.id = id
this.type = type this.type = type
this.flag = flag,
this.ids = ids this.ids = ids
this.queryParam = {} this.queryParam = {}
this.selectQuery = {} this.selectQuery = {}
@@ -180,8 +183,13 @@
projectLibraryIds: this.id, projectLibraryIds: this.id,
...this.queryParam ...this.queryParam
} }
let val = {
projectLibraryIds: this.ids,
platformProjectLibraryIds: this.id,
...this.queryParam
}
this.loading = true this.loading = true
postAction('project/projectLibraryBase/listPlatform', query).then((res) => { postAction(this.flag == '2' ? '/project/projectLibraryBase/listPlatformAll' : 'project/projectLibraryBase/listPlatform', this.flag == '2' ? val : query).then((res) => {
if (res.success) { if (res.success) {
this.data = res.result || [] this.data = res.result || []
this.data.forEach((item,index) => { this.data.forEach((item,index) => {
@@ -124,14 +124,14 @@ export default {
}, },
{ {
title: this.$t('design') + '-' + this.$t('typeOfDeliverables'), title: this.$t('design') + '-' + this.$t('typeOfDeliverables'),
dataIndex: 'designdeliverableTypeName', dataIndex: 'designDeliverableTypeName',
align: 'left', align: 'left',
ellipsis: true, ellipsis: true,
width: 120 width: 120
}, },
{ {
title: this.$t('verify') + '-' + this.$t('typeOfDeliverables'), title: this.$t('verify') + '-' + this.$t('typeOfDeliverables'),
dataIndex: 'deliverableTypeName', dataIndex: 'verifyDeliverableTypeName',
align: 'left', align: 'left',
ellipsis: true, ellipsis: true,
width: 120 width: 120
@@ -143,8 +143,9 @@ export default {
pageNo: 1, pageNo: 1,
pageSize: 10, pageSize: 10,
total: 0, total: 0,
flag:'', id:'',
type:'', type:'',
flag:'',
ids:'', ids:'',
} }
}, },
@@ -152,11 +153,12 @@ export default {
}, },
methods: { methods: {
transferModel(flag,type,ids) { transferModel(id,flag,type,ids) {
this.visible = true this.visible = true
this.flag = flag this.id = id
this.type = type this.type = type
this.ids = ids this.ids = ids
this.flag = flag
this.queryParam = {} this.queryParam = {}
this.selectedRowKeys = [] this.selectedRowKeys = []
this.replacePage() this.replacePage()
@@ -180,13 +182,16 @@ export default {
this.replacePage() this.replacePage()
}, },
replacePage() { replacePage() {
console.log(this.id)
let query = { let query = {
pageNo: this.pageNo, pageNo: this.pageNo,
pageSize: this.pageSize, pageSize: this.pageSize,
projectLibraryId: this.id,
roleCode: 0,
...this.queryParam ...this.queryParam
} }
this.loading = true this.loading = true
postAction(this.url.transferUrl, query).then((res) => { getAction('/platform/projectLawsInventoryEO/page', query).then((res) => {
if (res.success) { if (res.success) {
this.dataList = res.result.records || [] this.dataList = res.result.records || []
this.total = res.result.total this.total = res.result.total
@@ -210,7 +215,7 @@ export default {
this.confirmLoading = true this.confirmLoading = true
let selectedRowKeys = JSON.parse(JSON.stringify(this.selectedRowKeys)) let selectedRowKeys = JSON.parse(JSON.stringify(this.selectedRowKeys))
this.confirmLoading = false this.confirmLoading = false
this.$emit('associatedplattwoForm',selectedRowKeys.join(','),this.type,this.ids) this.$emit('associatedplattwoForm',selectedRowKeys.join(','),this.flag,this.type,this.ids)
this.selectedRowKeys = [] this.selectedRowKeys = []
// postAction(this.url.addModel, { // postAction(this.url.addModel, {
// dummyInventoryBaseId: selectedRowKeys.join(','), // dummyInventoryBaseId: selectedRowKeys.join(','),
@@ -1982,18 +1982,20 @@
} }
}else{ }else{
flag = '2' flag = '2'
this.selectedRowKeys = this.dataSource.map(val => val.id)
console.log(this.selectedRowKeys)
this.$refs.associatedplatRef.transferModel(flag,type,this.selectedRowKeys.join(',')) this.$refs.associatedplatRef.transferModel(flag,type,this.selectedRowKeys.join(','))
} }
}, },
associatedplatForm(id,flag,type,ids){ associatedplatForm(id,flag,type,ids){
if(flag == '1'){ if(flag == '1'){
this.$refs.associatedplatthreeRef.transferModel(id,type,ids) this.$refs.associatedplatthreeRef.transferModel(id,flag,type,ids)
}else{ }else{
this.$refs.associatedplattwoRef.transferModel(id,type,ids) this.$refs.associatedplattwoRef.transferModel(id,flag,type,ids)
} }
}, },
associatedplattwoForm(id,type,ids){ associatedplattwoForm(id,flag,type,ids){
this.$refs.associatedplatthreeRef.transferModel(id,type,ids) this.$refs.associatedplatthreeRef.transferModel(id,flag,type,ids)
}, },
associatedplatthreeForm(id){ associatedplatthreeForm(id){
this.getList() this.getList()