diff --git a/src/views/yingji/enforcing.vue b/src/views/yingji/enforcing.vue index 37d97ea..38b9763 100644 --- a/src/views/yingji/enforcing.vue +++ b/src/views/yingji/enforcing.vue @@ -11,7 +11,7 @@
-
年月:
+
年份:
行政区划:
-
经济类型:
- + @@ -31,10 +23,10 @@
行业类型:
@@ -42,8 +34,13 @@
是否重点:
- - + +
@@ -53,10 +50,10 @@
重大危险源等级:
@@ -65,10 +62,10 @@
企业分色:
@@ -128,7 +125,7 @@
{{ filterTable( - options.major_hazard_level, + dict.type.major_hazard_level, scope.row.majorHazardLevel ) }} @@ -145,14 +142,14 @@
{{ scope.row.indusTypeClass != "null" - ? filterTable(options.category, scope.row.indusTypeClass) + ? filterTable(dict.type.category, scope.row.indusTypeClass) : "" }}
@@ -160,7 +157,7 @@
{{ scope.row.enterColorChart != "null" - ? filterTable(options.entpr_color, scope.row.enterColorChart) + ? filterTable(dict.entpr_color, scope.row.enterColor) : "" }}
@@ -253,24 +250,14 @@ export default { data() { return { tableData: [], - option:[], - form: { - subdistrict: [], - frimType: "", - indusTypeClass: "", - isPoint: "", - majorHazardLevel: "", - entprColor: "", - uscCode: "", - }, - + option: [], + form: {}, xzqh: "", searchBefore: { pageSize: 10, pageNum: 1, }, xzList: [], - options: {}, load1: true, total: 0, main: { @@ -589,67 +576,48 @@ export default { details: null, //== subdistrict: [], - isPointOption: [ - { - dictValue: 1, - dictLabel: "是", - }, - { - dictValue: 0, - dictLabel: "否", - }, - ], - guimoOption: [ - { - dictValue: 1, - dictLabel: "规模以上", - }, - { - dictValue: 0, - dictLabel: "规模一下", - }, - ], }; }, created() { this.getList(); - this.getDict(); }, + dicts: [ + "economic_categories", + "economic_subcategory", + "special_governance", + "enterprise_status", + "standardization_level", + "safety_level", + "category", + "major_hazard_level", + "entpr_color", + "is_point", + ], + methods: { // 匹配行政区划 - componendDistrict(district){ - let name - this.option.map((item)=>{ - if(item.value == district) { - name = item.label + componendDistrict(district) { + let name; + this.option.map((item) => { + if (item.value == district) { + name = item.label; } else { - item.children.map((itemTwo)=>{ - if(itemTwo.value == district) { - name = item.label + '-' + itemTwo.label + item.children.map((itemTwo) => { + if (itemTwo.value == district) { + name = item.label + "-" + itemTwo.label; } - }) + }); } - }) - return name + }); + return name; }, // 获取行政区划树 quhuadizhi(district) { - this.option = district - }, - getDict() { - listDist({ - list: "economic_categories,category,major_hazard_level,entpr_color" - }).then((res) => { - this.options = res.data; - }); + this.option = district; }, filterTable(a, b) { - let arr = []; if (!b) return; - arr = a.filter((value) => { - return value.dictValue == b; - }); - return arr[0].dictLabel || b; + return this.selectDictLabel(a, b); }, shutDownDetail() { this.addShow = false; @@ -666,45 +634,77 @@ export default { }); } this.listDes.forEach((value1, index1) => { - if (value1.eng == "isPoint") { + //重大危险源等级 + if (value1.eng == "majorHazardLevel") { this.listDes[index1].value = this.filterTable( - this.isPointOption, + this.dict.type.major_hazard_level, value1.value ); } - if (value1.eng == "majorHazardLevel") { + //经济类型大类 + if (value1.eng == "ecoTypeLarge") { this.listDes[index1].value = this.filterTable( - this.options.major_hazard_level, + this.dict.type.economic_categories, value1.value ); } - if (value1.eng == "ecoTypeLarge") { + //经济类型小类 + if (value1.eng == "ecoTypeSmall") { this.listDes[index1].value = this.filterTable( - this.options.economic_categories, + this.dict.type.economic_subcategory, value1.value ); } - if (value1.eng == "indusTypeClass") { + //专项治理类别 + if (value1.eng == "specialGovernance") { + this.listDes[index1].value = this.filterTable( + this.dict.type.special_governance, + value1.value + ); + } + //隶属关系 + //企业经营状态 + if (value1.eng == "operatingStatus") { + this.listDes[index1].value = this.filterTable( + this.dict.type.enterprise_status, + value1.value + ); + } + //标准化等级 + if (value1.eng == "standLevel") { + this.listDes[index1].value = this.filterTable( + this.dict.type.standardization_level, + value1.value + ); + } + //安全监管等级 + if (value1.eng == "safetySupervisionLevel") { this.listDes[index1].value = this.filterTable( - this.options.category, + this.dict.type.safety_level, value1.value ); } - if (value1.eng == "enterColorChart") { + //检查来源 + //文书类型 + // 检查方式 + // 企业分色 + if (value1.eng == "entprColor") { this.listDes[index1].value = this.filterTable( - this.options.entpr_color, + this.dict.type.entpr_color, value1.value ); } - if (value1.eng == "safetyDepart") { + // 行业类型 + if (value1.eng == "indusTypeClass") { this.listDes[index1].value = this.filterTable( - this.isPointOption, + this.dict.type.category, value1.value ); } - if (value1.eng == "fullSafety") { + //是否重点 + if (value1.eng == "isPoint") { this.listDes[index1].value = this.filterTable( - this.guimoOption, + this.dict.type.is_point, value1.value ); } @@ -764,16 +764,16 @@ export default { return ""; }, }, - mounted() { - this.checkListTwo = this.checkList; - // this.$nextTick(()=>{ - // let dom = document.getElementsByClassName('tables'); - // let height = dom[0].getBoundingClientRect(); - // let windowHeight = window.innerHeight; - // let relativeHeight = windowHeight - height.top - // this.main.height = relativeHeight - 50 - // }) - }, + // mounted() { + // this.checkListTwo = this.checkList; + // // this.$nextTick(()=>{ + // // let dom = document.getElementsByClassName('tables'); + // // let height = dom[0].getBoundingClientRect(); + // // let windowHeight = window.innerHeight; + // // let relativeHeight = windowHeight - height.top + // // this.main.height = relativeHeight - 50 + // // }) + // }, };