From b59c9c11ba54732ab857e8f447a2878bcfb52f3d Mon Sep 17 00:00:00 2001 From: shenyanpei Date: Thu, 6 Jan 2022 14:42:12 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B8=85=E5=8D=95=E9=87=8C=E9=9D=A2=E6=9F=A5?= =?UTF-8?q?=E8=AF=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pages/details.vue | 130 ++++++++++-------- .../localProductsOrProjectLibrary/index.vue | 57 ++++---- .../pages/details.vue | 4 +- 3 files changed, 109 insertions(+), 82 deletions(-) diff --git a/src/pages/regulatoryRepository/accessStandardsAndRegulations/pages/details.vue b/src/pages/regulatoryRepository/accessStandardsAndRegulations/pages/details.vue index 24dff2e71..814cf97f8 100644 --- a/src/pages/regulatoryRepository/accessStandardsAndRegulations/pages/details.vue +++ b/src/pages/regulatoryRepository/accessStandardsAndRegulations/pages/details.vue @@ -462,39 +462,44 @@ export default { }, { _this: this }, res => { - res.data.records.forEach(item => { - if (item.nylx === "[]") { - item.nylx = null; - } - if (item.typeApplicable === "[]") { - item.typeApplicable = null; - } - if (item.sycpx === "[]") { - item.sycpx = null; - } - if(item.zrbm === "[]"){ - item.zrbm = null - } - if (item.zccssrqgj === "undefined") { - item.zccssrqgj = '-' - } - if (item.xcxssrqgj === "undefined") { - item.xcxssrqgj = '-' - } - if (item.ssrq === "undefined") { - item.ssrq = '-' - } - }); - this.standinfoList = res.data.records; - this.standardFormTotal = res.data.total; - this.standinfoList.forEach(item => { - if (item.standYear === null) { - item.standNumber = item.standSortShow + " " + item.standNumber; - } else { - item.standNumber = item.standSortShow + " " + item.standNumber + "-" + item.standYear; - } - }); - this.standInfoTableLoading = false + if (res.data !== null) { + res.data.records.forEach(item => { + if (item.nylx === "[]") { + item.nylx = null; + } + if (item.typeApplicable === "[]") { + item.typeApplicable = null; + } + if (item.sycpx === "[]") { + item.sycpx = null; + } + if(item.zrbm === "[]"){ + item.zrbm = null + } + if (item.zccssrqgj === "undefined") { + item.zccssrqgj = '-' + } + if (item.xcxssrqgj === "undefined") { + item.xcxssrqgj = '-' + } + if (item.ssrq === "undefined") { + item.ssrq = '-' + } + }); + this.standinfoList = res.data.records; + this.standardFormTotal = res.data.total; + this.standinfoList.forEach(item => { + if (item.standYear === null) { + item.standNumber = item.standSortShow + " " + item.standNumber; + } else { + item.standNumber = item.standSortShow + " " + item.standNumber + "-" + item.standYear; + } + }); + this.standInfoTableLoading = false + } else { + this.standinfoList = [] + } + }, e => { this.standInfoTableLoading = false }); @@ -506,30 +511,35 @@ export default { }, { _this: this }, res => { - res.data.records.forEach(item => { - if (item.nylx === "[]") { - item.nylx = null; - } - if (item.typeApplicable === "[]") { - item.typeApplicable = null; - } - if (item.sycpx === "[]") { - item.sycpx = null; - } - if(item.zrbm === "[]"){ - item.zrbm = null - } - }); - this.standinfoList = res.data.records; - this.standardFormTotal = res.data.total; - this.standinfoList.forEach(item => { - if (item.standYear === null) { - item.standNumber = item.standSortShow + " " + item.standNumber; - } else { - item.standNumber = item.standSortShow + " " + item.standNumber + "-" + item.standYear; - } - }); - this.standInfoTableLoading = false + if (res.data !== null) { + res.data.records.forEach(item => { + if (item.nylx === "[]") { + item.nylx = null; + } + if (item.typeApplicable === "[]") { + item.typeApplicable = null; + } + if (item.sycpx === "[]") { + item.sycpx = null; + } + if(item.zrbm === "[]"){ + item.zrbm = null + } + }); + this.standinfoList = res.data.records; + this.standardFormTotal = res.data.total; + this.standinfoList.forEach(item => { + if (item.standYear === null) { + item.standNumber = item.standSortShow + " " + item.standNumber; + } else { + item.standNumber = item.standSortShow + " " + item.standNumber + "-" + item.standYear; + } + }); + this.standInfoTableLoading = false + } else { + this.standinfoList = [] + } + }, e => { this.standInfoTableLoading = false }); @@ -773,13 +783,17 @@ export default { * 高级检索 */ selectMoreBtn() { - this.isAdvancedSearch = true; + this.standardForm.zrbm = '' + this.standardForm.responseUnit = '' + this.standardForm.standName = '' + this.standardForm.standNumber = '' this.standardFormList.standName = ""; this.standardFormList.typeApplicable = ""; this.standardFormList.nylx = ""; this.standardFormList.zrbm = ""; this.standardFormList.sycpx = ""; this.showTableFlag = false; + this.isAdvancedSearch = true; this.page = 1; this.standardForm.page = 1; this.selectInfoMore(); diff --git a/src/pages/regulatoryRepository/localProductsOrProjectLibrary/index.vue b/src/pages/regulatoryRepository/localProductsOrProjectLibrary/index.vue index cfe589da2..d9dda2b2c 100644 --- a/src/pages/regulatoryRepository/localProductsOrProjectLibrary/index.vue +++ b/src/pages/regulatoryRepository/localProductsOrProjectLibrary/index.vue @@ -4,7 +4,7 @@
+ @keyup.enter.native="getLocalProductTableBtns"> 查询 + @click="getLocalProductTableBtns">查询 @@ -477,7 +477,7 @@ export default { projectClassification: "", // 项目状态 projectStatus: "", - page: "" + page: 1 }, //查询3类 projectLibrarySearchDefault: { @@ -1210,6 +1210,37 @@ export default { this.SarExportSearchEo = this.localProTableSearch; this.$http.get("sarStandProjectLibrary/queryProject", { ...this.localProTableSearch, + page: this.page, + pageSize: this.pageSize, + }, { + _this: this, loading: "loading" + }, res => { + if (this.localProTableSearch.prodectCode === "Maintenance") { + this.localProTableList = res.data.Maintenance.records; + this.productTypeOptions = this.projectData + this.xmztOptions = this.projectStatus + this.total = res.data.Maintenance.total; + } else if (this.localProTableSearch.prodectCode === "notMaintenance") { + this.localProTableList = res.data.notMaintenance.records; + this.productTypeOptions = this.notProjectData + this.xmztOptions = this.notProjectStatus + this.total = res.data.notMaintenance.total; + } + }, e => { + }); + // this.$refs.selection.selectAll(false) + }, + + getLocalProductTableBtns() { + this.projectLibrarySearch.page = 1; + this.isAdvancedSearch = false; + this.getLocalProductTables(); + }, + getLocalProductTables() { + this.localProTableSearch.prodectCode = this.ifMaintaince; + this.localProTableSearch.dataType = this.insideTabsActiveName; + this.SarExportSearchEo = this.localProTableSearch; + this.$http.get("sarStandProjectLibrary/queryProject", { ...this.projectLibrarySearch, page: this.page, pageSize: this.pageSize, @@ -1227,26 +1258,6 @@ export default { this.xmztOptions = this.notProjectStatus this.total = res.data.notMaintenance.total; } - // this.localProTableList.map((item) => { - // this.xmztOptions.map((opr) => { - // if (item.productBrand === opr.value) { - // item.productBrand = opr.label - // } - // }) - // this.scxxOptions.map((xmItem) => { - // if (item.saleMarket === xmItem.value) { - // item.saleMarket = xmItem.label - // } - // }) - // this.scxxOptions.map((xmItem) => { - // if (item.targetMarket === xmItem.value) { - // item.targetMarket = xmItem.label - // } - // }) - // }) - // if ((this.localProTableList.length === 0 || this.localProTableList === []) && this.localProTableSearch.page !== 1) { - // this.pageChange(1) - // } }, e => { }); // this.$refs.selection.selectAll(false) diff --git a/src/pages/regulatoryRepository/localProductsOrProjectLibrary/pages/details.vue b/src/pages/regulatoryRepository/localProductsOrProjectLibrary/pages/details.vue index 2c23a3371..af3445f7f 100644 --- a/src/pages/regulatoryRepository/localProductsOrProjectLibrary/pages/details.vue +++ b/src/pages/regulatoryRepository/localProductsOrProjectLibrary/pages/details.vue @@ -845,7 +845,9 @@ export default { // 查询详情表格数据 this.$http.get('sarStandProjectLibrary/queryStandInfoNew', { id: this.localProEO.id, - cars: "1" + cars: "1", + current: 1, + pageSize: this.$store.getters.userInfo.configContent }, { _this: this, loading: 'loading'