|
|
@ -4,7 +4,7 @@
|
|
|
|
* @Author: JC9527
|
|
|
|
* @Author: JC9527
|
|
|
|
* @Date: 2023-09-04 10:20:06
|
|
|
|
* @Date: 2023-09-04 10:20:06
|
|
|
|
* @LastEditors: JC9527
|
|
|
|
* @LastEditors: JC9527
|
|
|
|
* @LastEditTime: 2023-10-10 16:14:06
|
|
|
|
* @LastEditTime: 2023-10-11 10:28:00
|
|
|
|
-->
|
|
|
|
-->
|
|
|
|
<template>
|
|
|
|
<template>
|
|
|
|
<div class="plan-management">
|
|
|
|
<div class="plan-management">
|
|
|
@ -189,6 +189,7 @@
|
|
|
|
district:[],
|
|
|
|
district:[],
|
|
|
|
plannedYear:''
|
|
|
|
plannedYear:''
|
|
|
|
},
|
|
|
|
},
|
|
|
|
|
|
|
|
district:[],
|
|
|
|
mydistrict:'',
|
|
|
|
mydistrict:'',
|
|
|
|
props:{
|
|
|
|
props:{
|
|
|
|
value:'county',
|
|
|
|
value:'county',
|
|
|
@ -268,11 +269,11 @@
|
|
|
|
if(!this.disabled) {
|
|
|
|
if(!this.disabled) {
|
|
|
|
if(Array.isArray(newForm.district)){
|
|
|
|
if(Array.isArray(newForm.district)){
|
|
|
|
if(newForm.district.length == 2) {
|
|
|
|
if(newForm.district.length == 2) {
|
|
|
|
let district = this.form.district[1].slice(0, 11);
|
|
|
|
this.district = this.form.district[1].slice(0, 10);
|
|
|
|
obj = { ...this.pages, ...this.form,district };
|
|
|
|
obj = { ...this.pages, ...this.form,district:this.district };
|
|
|
|
} else if(newForm.district.length == 1) {
|
|
|
|
} else if(newForm.district.length == 1) {
|
|
|
|
let district = this.form.district[0].slice(0, 8);
|
|
|
|
this.district = this.form.district[0].slice(0, 7);
|
|
|
|
obj = { ...this.pages, ...this.form,district };
|
|
|
|
obj = { ...this.pages, ...this.form,district:this.district };
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
obj = { ...this.pages, ...this.form};
|
|
|
|
obj = { ...this.pages, ...this.form};
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -280,11 +281,11 @@
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
// 判断是区县
|
|
|
|
// 判断是区县
|
|
|
|
if(this.county){
|
|
|
|
if(this.county){
|
|
|
|
let district = this.form.district.slice(0, 8);
|
|
|
|
this.district = this.form.district.slice(0, 7);
|
|
|
|
obj = { ...this.pages, ...this.form,district };
|
|
|
|
obj = { ...this.pages, ...this.form,district:this.district };
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
let district = this.form.district.slice(0, 11);
|
|
|
|
this.district = this.form.district.slice(0, 10);
|
|
|
|
obj = { ...this.pages, ...this.form,district };
|
|
|
|
obj = { ...this.pages, ...this.form,district:this.district };
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
@ -294,8 +295,8 @@
|
|
|
|
// obj = { ...this.pages, ...this.form,subdistrict:this.subdistrict };
|
|
|
|
// obj = { ...this.pages, ...this.form,subdistrict:this.subdistrict };
|
|
|
|
// } else if(this.dept.ancestors.split(',').length == 3){
|
|
|
|
// } else if(this.dept.ancestors.split(',').length == 3){
|
|
|
|
// let district = this.form.district.slice(1, 11);
|
|
|
|
// let district = this.form.district.slice(1, 11);
|
|
|
|
let district = this.form.district;
|
|
|
|
this.district = this.form.district;
|
|
|
|
obj = { ...this.pages, ...this.form,district };
|
|
|
|
obj = { ...this.pages, ...this.form,district:this.district };
|
|
|
|
// }
|
|
|
|
// }
|
|
|
|
}
|
|
|
|
}
|
|
|
|
// console.log(obj,'obj')
|
|
|
|
// console.log(obj,'obj')
|
|
|
@ -328,24 +329,24 @@
|
|
|
|
// console.log('123123页码发生变化')
|
|
|
|
// console.log('123123页码发生变化')
|
|
|
|
this.pages = pages
|
|
|
|
this.pages = pages
|
|
|
|
let district
|
|
|
|
let district
|
|
|
|
if(this.dept.ancestors.split(',').length == 2){
|
|
|
|
// if(this.dept.ancestors.split(',').length == 2){
|
|
|
|
if(Array.isArray(this.form.district)) {
|
|
|
|
// if(Array.isArray(this.form.district)) {
|
|
|
|
if(this.form.district.length == 2) {
|
|
|
|
// if(this.form.district.length == 2) {
|
|
|
|
district = this.form.district[1].slice(0, 11);
|
|
|
|
// district = this.form.district[1].slice(0, 10);
|
|
|
|
}
|
|
|
|
// }
|
|
|
|
} else {
|
|
|
|
// } else {
|
|
|
|
district = this.form.district.slice(0, 8);
|
|
|
|
// district = this.form.district.slice(0, 7);
|
|
|
|
}
|
|
|
|
// }
|
|
|
|
} else if(this.dept.ancestors.split(',').length == 3){
|
|
|
|
// } else if(this.dept.ancestors.split(',').length == 3){
|
|
|
|
district = this.form.district[1].slice(0, 11);
|
|
|
|
// district = this.form.district[1].slice(0, 10);
|
|
|
|
} else {
|
|
|
|
// } else {
|
|
|
|
if(this.form.district.length == 2) {
|
|
|
|
// if(this.form.district.length == 2) {
|
|
|
|
district = this.form.district[1].slice(0, 11);
|
|
|
|
// district = this.form.district[1].slice(0, 10);
|
|
|
|
} else if(this.form.district.length == 1){
|
|
|
|
// } else if(this.form.district.length == 1){
|
|
|
|
district = this.form.district[0].slice(0, 8);
|
|
|
|
// district = this.form.district[0].slice(0, 7);
|
|
|
|
}
|
|
|
|
// }
|
|
|
|
}
|
|
|
|
// }
|
|
|
|
this.getList({...pages,...this.form,district:district})
|
|
|
|
this.getList({...pages,...this.form,district:this.district})
|
|
|
|
},
|
|
|
|
},
|
|
|
|
// 选中的数据
|
|
|
|
// 选中的数据
|
|
|
|
handleSelectionChange(val) {
|
|
|
|
handleSelectionChange(val) {
|
|
|
@ -372,21 +373,21 @@
|
|
|
|
type: "warning",
|
|
|
|
type: "warning",
|
|
|
|
})
|
|
|
|
})
|
|
|
|
.then(() => {
|
|
|
|
.then(() => {
|
|
|
|
let district
|
|
|
|
// let district
|
|
|
|
if(Array.isArray(this.form.district)){
|
|
|
|
// if(Array.isArray(this.form.district)){
|
|
|
|
if(this.form.district.length == 1){
|
|
|
|
// if(this.form.district.length == 1){
|
|
|
|
district = this.form.district[0];
|
|
|
|
// district = this.form.district[0];
|
|
|
|
} else if(this.form.district.length == 2){
|
|
|
|
// } else if(this.form.district.length == 2){
|
|
|
|
district = this.form.district[1];
|
|
|
|
// district = this.form.district[1];
|
|
|
|
}
|
|
|
|
// }
|
|
|
|
} else {
|
|
|
|
// } else {
|
|
|
|
district = this.form.district;
|
|
|
|
// district = this.form.district;
|
|
|
|
}
|
|
|
|
// }
|
|
|
|
this.download(
|
|
|
|
this.download(
|
|
|
|
"/pharmaceuticals/bPlanEnterprise/exportplan",
|
|
|
|
"/pharmaceuticals/bPlanEnterprise/exportplan",
|
|
|
|
{
|
|
|
|
{
|
|
|
|
...this.form,
|
|
|
|
...this.form,
|
|
|
|
district
|
|
|
|
district:this.district
|
|
|
|
},
|
|
|
|
},
|
|
|
|
`计划管理.xlsx`
|
|
|
|
`计划管理.xlsx`
|
|
|
|
);
|
|
|
|
);
|
|
|
@ -403,6 +404,7 @@
|
|
|
|
// this.pages.pageSize = 10;
|
|
|
|
// this.pages.pageSize = 10;
|
|
|
|
// this.$refs.mypagination.defaultPages();
|
|
|
|
// this.$refs.mypagination.defaultPages();
|
|
|
|
// let obj
|
|
|
|
// let obj
|
|
|
|
|
|
|
|
this.district = [];
|
|
|
|
if(this.dept.ancestors.split(',').length == 1) {
|
|
|
|
if(this.dept.ancestors.split(',').length == 1) {
|
|
|
|
this.form = {
|
|
|
|
this.form = {
|
|
|
|
plannedYear:'',
|
|
|
|
plannedYear:'',
|
|
|
@ -427,10 +429,10 @@
|
|
|
|
if(!this.disabled) {
|
|
|
|
if(!this.disabled) {
|
|
|
|
if(Array.isArray(this.form.district)){
|
|
|
|
if(Array.isArray(this.form.district)){
|
|
|
|
if(this.form.district.length == 2) {
|
|
|
|
if(this.form.district.length == 2) {
|
|
|
|
let district = this.form.district[1].slice(0, 11);
|
|
|
|
let district = this.form.district[1].slice(0, 10);
|
|
|
|
obj = { ...this.pages, ...this.form,district };
|
|
|
|
obj = { ...this.pages, ...this.form,district };
|
|
|
|
} else if(this.form.district.length == 1) {
|
|
|
|
} else if(this.form.district.length == 1) {
|
|
|
|
let district = this.form.district[0].slice(0, 8);
|
|
|
|
let district = this.form.district[0].slice(0, 7);
|
|
|
|
obj = { ...this.pages, ...this.form,district };
|
|
|
|
obj = { ...this.pages, ...this.form,district };
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
obj = { ...this.pages, ...this.form};
|
|
|
|
obj = { ...this.pages, ...this.form};
|
|
|
@ -439,10 +441,10 @@
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
// 判断是区县
|
|
|
|
// 判断是区县
|
|
|
|
if(this.county){
|
|
|
|
if(this.county){
|
|
|
|
let district = this.form.district.slice(0, 8);
|
|
|
|
let district = this.form.district.slice(0, 7);
|
|
|
|
obj = { ...this.pages, ...this.form,district };
|
|
|
|
obj = { ...this.pages, ...this.form,district };
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
let district = this.form.district.slice(0, 11);
|
|
|
|
let district = this.form.district.slice(0, 10);
|
|
|
|
obj = { ...this.pages, ...this.form,district };
|
|
|
|
obj = { ...this.pages, ...this.form,district };
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -520,12 +522,12 @@
|
|
|
|
// let { district} = this.form;
|
|
|
|
// let { district} = this.form;
|
|
|
|
let district
|
|
|
|
let district
|
|
|
|
if(this.dept.ancestors.split(',').length == 2) {
|
|
|
|
if(this.dept.ancestors.split(',').length == 2) {
|
|
|
|
district = this.form.district.slice(0, 8);
|
|
|
|
district = this.form.district.slice(0, 7);
|
|
|
|
} else if(this.dept.ancestors.split(',').length == 3) {
|
|
|
|
} else if(this.dept.ancestors.split(',').length == 3) {
|
|
|
|
district = this.form.district;
|
|
|
|
district = this.form.district;
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
if(this.form.district.length == 1) {
|
|
|
|
if(this.form.district.length == 1) {
|
|
|
|
district = this.form.district.slice(0, 8);
|
|
|
|
district = this.form.district.slice(0, 7);
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
district = this.form.district;
|
|
|
|
district = this.form.district;
|
|
|
|
}
|
|
|
|
}
|
|
|
|