From 03f3f7638955fb0232b3e91dc5bb0a84b0666c3f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=AE=8B=E4=BC=9F=E4=BD=B3?= <2797716443@qq.com> Date: Fri, 13 Aug 2021 10:56:46 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E9=9C=80=E6=B1=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pages/creatProcess/xmpg2/step1.vue | 7 +- .../pages/details.vue | 1 - .../pages/details.vue | 367 ++++++++++++++---- 3 files changed, 285 insertions(+), 90 deletions(-) diff --git a/src/pages/processCenter/pages/creatProcess/xmpg2/step1.vue b/src/pages/processCenter/pages/creatProcess/xmpg2/step1.vue index 7923603a6..296f65bc7 100644 --- a/src/pages/processCenter/pages/creatProcess/xmpg2/step1.vue +++ b/src/pages/processCenter/pages/creatProcess/xmpg2/step1.vue @@ -445,7 +445,7 @@ export default { }, //获取项目数据 getProjectData() { - this.$http.get("sarStandProjectLibrary/queryProject", { + this.$http.get("sarStandProjectLibrary/queryProjectWorkFlow", { ...this.projectSearch }, { _this: this @@ -520,12 +520,7 @@ export default { { _this: this }, res => { - if (!res.data.length) { - this.dataList = [] - this.$message.warning("请选择带有分解单的标准"); - } else { this.listForm.breakdownList = res.data; - } }); }, //标准的多选框改变 diff --git a/src/pages/regulatoryRepository/accessStandardsAndRegulations/pages/details.vue b/src/pages/regulatoryRepository/accessStandardsAndRegulations/pages/details.vue index 6ee8ff256..9527ef9ca 100644 --- a/src/pages/regulatoryRepository/accessStandardsAndRegulations/pages/details.vue +++ b/src/pages/regulatoryRepository/accessStandardsAndRegulations/pages/details.vue @@ -501,7 +501,6 @@ export default { } }) }, e => { - }); }, selectInfoMore() { diff --git a/src/pages/regulatoryRepository/localProductsOrProjectLibrary/pages/details.vue b/src/pages/regulatoryRepository/localProductsOrProjectLibrary/pages/details.vue index 2c68a966a..03148760b 100644 --- a/src/pages/regulatoryRepository/localProductsOrProjectLibrary/pages/details.vue +++ b/src/pages/regulatoryRepository/localProductsOrProjectLibrary/pages/details.vue @@ -39,7 +39,7 @@
@@ -340,17 +466,25 @@ export default { standCommonlySearch: { standSort: '', standNumber: '', - standType: '' + standType: '', + page: 1, + Size: this.$store.getters.userInfo.configContent }, //用来存放项目id + sarAccessListDatas: [], proId: '', size: this.$store.getters.userInfo.configContent, pageSizeNo: this.$store.getters.userInfo.configContent, pageSize: this.$store.getters.userInfo.configContent, pageNo: 1, + pageDo: 1, + pageSizeDo: this.$store.getters.userInfo.configContent, standardData: [], //添加标准数据 + detailedId: '', //清单id totalNo: 0, + totalDo: 0, standModel: false, // 选择标准抽屉状态 + detailedListModel: false, //调取清单的抽屉状态 selectList: [], //选择标准的选择框 selectList1: [], //选择标准的选择框 dataList: [],//清单里的标准数据 @@ -361,6 +495,11 @@ export default { Height: 0, localProEO: {}, localProLib: {}, + // 查询相关参数 + sarSarAccessEOSearch: { + projectName: "", + detailedListName: "", + }, takeingFlag: false, exportModelFlag: false, exportName: '', @@ -373,18 +512,29 @@ export default { } }, methods: { - // 搜索 + //搜索清单 + searchSarAccess(){ + this.pageDo = 1 + this.pageSizeDo = this.$store.getters.userInfo.configContent; + this.transfer() + }, + // 搜索标准 search() { this.pageNo = 1 this.pageSizeNo = this.$store.getters.userInfo.configContent; - this.addList() + this.getStand() + }, + clearSearchAccess(){ + this.sarSarAccessEOSearch.projectName = '' + this.sarSarAccessEOSearch.detailedListName = '' + this.transfer() }, clearSearch() { this.pageNo = 1 this.standCommonlySearch.standSort = '' this.standCommonlySearch.standNumber = '' this.standCommonlySearch.standType = '' - this.addList() + this.getStand() }, pageChange(page) { this.page = page; @@ -396,36 +546,76 @@ export default { }, pageChangeNo(page) { this.pageNo = page - this.addList() + this.getStand() + }, + pageChangeDo(page){ + this.pageDo = page + this.transfer() + }, + pageSizeChangeDo(pageSize){ + this.pageDo = pageSize + this.transfer() }, pageSizeChangeNo(pageSize) { - this.pageSizeNo = this.$store.getters.userInfo.configContent; - this.addList() - + this.pageSizeNo = pageSize + this.getStand() }, //添加标准select的改变 selectThree(data) { this.standList = data; }, - //点击添加事件 - addList() { - this.$http.get("sarStandardsInfo/sar-standards-info/getSarStandardsInfoPage", { - page: this.pageNo, - pageSize: this.pageSizeNo, - standSort: this.standCommonlySearch.standSort, - standNumber: this.standCommonlySearch.standNumber, - standType: this.standCommonlySearch.standType + // 表格选择框 + selectOne(data) { + this.selectedList = []; + for (let i = 0; i < data.length; i++) { + this.selectedList.push(data[i].id); + } + }, + // 点击 table查看按钮 事件 + showTable(item) { + sessionStorage.setItem("accessRow", JSON.stringify(item)); + this.$store.commit("setDetailMap", this.$route.path); + this.$router.push({ + name: "AccessStandardDetails", + params: { + id: item.id + } + }); + }, + //点击获取项目清单 + transfer(){ + this.$http.get("sarLawsDetailedList/sar-laws-detailed-list/getAllStand", { + page: 1, + pageSize: this.pageSize, + ...this.sarSarAccessEOSearch, + sortKey: 2 }, { - _this: this, + _this: this }, res => { - console.log('res') - console.log(res) - this.standardData = res.data.list; - this.totalNo = res.data.count + this.sarAccessListDatas = res.data.records; + this.sarSarAccessEOSearch.page = 1 + this.totalNo = res.data.total + this.detailedListModel = true }, e => { }); - this.standModel = true; }, + //点击添加标准事件 + // addList() { + // this.$http.get("sarStandardsInfo/sar-standards-info/getSarStandardsInfoPage", { + // page: this.pageNo, + // pageSize: this.pageSizeNo, + // standSort: this.standCommonlySearch.standSort, + // standNumber: this.standCommonlySearch.standNumber, + // standType: this.standCommonlySearch.standType + // }, { + // _this: this, + // }, res => { + // this.standardData = res.data.list; + // this.totalNo = res.data.count + // }, e => { + // }); + // this.standModel = true; + // }, // 点击批量删除事件 deleteList() { if (this.selectList.length < 1) { @@ -488,6 +678,10 @@ export default { }, e => { }) }, + //调取清单取消事件 + cancelDetailed(){ + this.detailedListModel = false; + }, //添加标准取消事件 cancelStand() { this.standModel = false; @@ -537,6 +731,23 @@ export default { _this.standModel = false; } }, + //获取标准 + getStandrd(data){ + this.detailedId = data.id + this.getStand(); + }, + getStand(data){ + this.$http.get("sarLawsAttrDetailedList/sar-laws-attr-detailed-list/selectLawsById", { + id:this.detailedId, + ...this.standCommonlySearch, + }, { + _this: this + }, res => { + this.standardData = res.data.records + this.totalDo = res.data.total + this.standModel = true; + }) + }, //选择清单确定事件 OkDrawer() { if (this.selectList.length === 1) { @@ -587,7 +798,6 @@ export default { window.open(routeUrl.href, '_blank') }, back() { - console.log(this.$route.query.tabName); this.$router.push({ path: this.$store.state.detailMap, query: { @@ -597,9 +807,7 @@ export default { this.$store.commit('setDetailMap', '') }, showLocalProductData(item) { - console.log(item) this.localProEO = JSON.parse(JSON.stringify(item)) - console.log(this.localProEO) this.proId = this.localProEO.id // 查询详情表格数据 this.$http.get('sarStandProjectLibrary/queryStandInfo', { @@ -609,7 +817,6 @@ export default { loading: 'loading' }, res => { this.dataList = res.data.records - console.log(res) this.total = res.data.total }, e => { }) @@ -645,7 +852,6 @@ export default { } this.exportName = '' this.exportModelFlag = true - console.log(this.saveExportType); }, //取消导出 cancal() { @@ -655,19 +861,16 @@ export default { exportTestItem() { if (this.saveExportType === 'apart') { if (this.selectList != null && this.selectList != '') { - console.log(this.selectList); let ids = '\'' + this.selectList[0].standId + '\'' for (let i = 1; i < this.selectList.length; i++) { ids += ',\'' + this.selectList[i].standId + '\'' } const exportURL = interfaceUrl + 'sarStandProjectLibrary/exportStandAttrInfoExcel?' + 'exportType' + this.saveExportType + '&ids=' + ids + '&exportName=' + this.exportName + '&id=' + this.localProEO.id - console.log(exportURL, '_self') window.open(exportURL, '_self') this.$message.success('导出信息成功') } } else if (this.saveExportType === 'all') { - console.log(this.selectList); let ids = '' if (this.dataList.length === 0) { this.$message.error('暂无导出数据') @@ -680,7 +883,6 @@ export default { } const exportURL = interfaceUrl + 'sarStandProjectLibrary/exportStandAttrInfoExcel?' + 'exportType' + this.saveExportType + '&ids=' + ids + '&exportName=' + this.exportName + '&id=' + this.localProEO.id - console.log(exportURL, '_self') window.open(exportURL, '_self') this.$message.success('导出信息成功') } @@ -733,7 +935,6 @@ export default { this.standSortOptions = res.data.STANDCLASSIFY // 标准类别 this.setMap(this.zrbmMap, res.data.ZRBMCLASS) this.setMap(this.textStatusMap, res.data.WBZTCLASS) - console.log(this.getLocalPro) this.showLocalProductData(this.getLocalPro) }, e => { })