diff --git a/src/api/yingji/index.js b/src/api/yingji/index.js index 441eed7..e36fed4 100644 --- a/src/api/yingji/index.js +++ b/src/api/yingji/index.js @@ -4,7 +4,7 @@ * @Author: JC9527 * @Date: 2023-09-11 15:38:21 * @LastEditors: JC9527 - * @LastEditTime: 2023-09-28 13:22:58 + * @LastEditTime: 2023-09-30 00:52:32 */ import request from '@/utils/request' @@ -64,11 +64,11 @@ export default { }); }, // 查看计划明细 - planmx(data){ + planmx(params){ return request({ url: `/pharmaceuticals/bPlanEnterprise/planmx`, method:'post', - data, + params, }); }, // 查询计划企业列表 diff --git a/src/views/components/dialog/index.vue b/src/views/components/dialog/index.vue index c22533c..b299f39 100644 --- a/src/views/components/dialog/index.vue +++ b/src/views/components/dialog/index.vue @@ -56,7 +56,7 @@ -->
经济类型:
- + { + this.district.map((item)=>{ if(item.subdistrict == district) { name = item.institutionName } else { @@ -471,18 +472,25 @@ export default { let obj // 如果是苏州市或者是某个区 if(!this.disabled) { - if(this.form.subdistrict.length > 0){ + // console.log('123') + if(Array.isArray(this.form.subdistrict)){ if(this.form.subdistrict.length == 2) { - this.form.subdistrict = this.form.subdistrict[1] - this.subdistrict = this.form.subdistrict.slice(1, 11); + this.subdistrict = this.form.subdistrict[2].slice(1, 11); obj = { ...this.pages, ...this.form,subdistrict:this.subdistrict }; } else if(this.form.subdistrict.length == 1) { - this.form.subdistrict = this.form.subdistrict[0] - this.subdistrict = this.form.subdistrict.slice(1, 8); + this.subdistrict = this.form.subdistrict[1].slice(1, 8); obj = { ...this.pages, ...this.form,subdistrict:this.subdistrict }; + } else { + obj = {...this.pages,...this.form} } } else { - obj = {...this.pages,...this.form} + if(this.county){ + let subdistrict = this.form.subdistrict.slice(1, 8); + obj = { ...this.pages, ...this.form,subdistrict }; + } else { + let subdistrict = this.form.subdistrict.slice(1, 8); + obj = { ...this.pages, ...this.form,subdistrict }; + } } } else { // 不是苏州市是乡镇 @@ -647,9 +655,17 @@ export default { this.pages = pages; console.log(this.form) if(this.dept.ancestors.split(',').length == 2){ - this.subdistrict = this.form.subdistrict.slice(1, 8); + if(Array.isArray(this.form.subdistrict)) { + this.subdistrict = this.form.subdistrict.slice(1, 8); + } else { + this.subdistrict = this.form.subdistrict; + } } else if(this.dept.ancestors.split(',').length == 3){ - this.subdistrict = this.form.subdistrict.slice(1, 11); + if(Array.isArray(this.form.subdistrict)) { + this.subdistrict = this.form.subdistrict.slice(1, 11); + } else { + this.subdistrict = this.form.subdistrict; + } } this.getTable({...pages,...this.form,subdistrict:this.subdistrict}); }, @@ -767,36 +783,46 @@ export default { return ""; }, commentData(item,dept) { + // item.map((item)=>{ + // if(item.children instanceof Array && item.children.length == 0){ + // item.county = item.subdistrict + // delete item.children; + // } else { + // // this.props.value = 'subdistrict' + // this.commentData(item.children,dept) + // } + // }) item.map((item)=>{ - if(item.children instanceof Array && item.children.length == 0){ - item.county = item.subdistrict - delete item.children; - } else { - // this.props.value = 'subdistrict' - this.commentData(item.children,dept) - } + item.children.map((itemTwo)=>{ + itemTwo.county = itemTwo.subdistrict + }) }) - this.myDistrict = item; + // this.myDistrict = item; this.listOne = item if(dept.ancestors.split(',').length == 2) { this.listOne = this.listOne.filter((item)=>{ return item.institutionName == dept.deptName }) - // this.listOne.map((item)=>{ - // if(item.institutionName == dept.deptName) { - // this.form.subdistrict = item.county - // this.workingArea = item.county - // delete item.children - // } - // }) - // this.disabled = true; - } else if(dept.ancestors.split(',').length == 3) { this.listOne.map((item)=>{ if(item.institutionName == dept.deptName) { - this.form.subdistrict = item.subdistrict + console.log(item.county) + this.form.subdistrict = item.county this.workingArea = item.county + this.county = true; + // delete item.children } }) + // this.disabled = true; + } else if(dept.ancestors.split(',').length == 3) { + this.listOne.map((item)=>{ + item.children.map((itemTwo)=>{ + if(itemTwo.institutionName == dept.deptName) { + this.form.subdistrict = itemTwo.subdistrict + this.workingArea = itemTwo.county + this.county = false; + } + }) + }) this.disabled = true; } }, diff --git a/src/views/components/firmDialog/index.vue b/src/views/components/firmDialog/index.vue index 1c113ba..acd6e4f 100644 --- a/src/views/components/firmDialog/index.vue +++ b/src/views/components/firmDialog/index.vue @@ -20,18 +20,12 @@
- {{ - item.value == "null" - ? "" - : item.value == "false" - ? "暂无" - : item.value - }} - + :label="item.label" + v-for="(item, index) in listDes" + :key="index" + > + {{ item.value}} +
@@ -40,6 +34,18 @@ diff --git a/src/views/components/tempDialog/index.vue b/src/views/components/tempDialog/index.vue index d8c09fe..77826aa 100644 --- a/src/views/components/tempDialog/index.vue +++ b/src/views/components/tempDialog/index.vue @@ -4,7 +4,7 @@ * @Author: JC9527 * @Date: 2023-09-28 11:25:48 * @LastEditors: JC9527 - * @LastEditTime: 2023-09-28 16:41:42 + * @LastEditTime: 2023-09-30 01:07:17 -->