diff --git a/src/views/modules/events/appeal-development-list.vue b/src/views/modules/events/appeal-development-list.vue index 84a13368..caaf035c 100644 --- a/src/views/modules/events/appeal-development-list.vue +++ b/src/views/modules/events/appeal-development-list.vue @@ -13,7 +13,16 @@ --> - + + + + - + @@ -41,8 +50,7 @@ -
-
+ {{ $t('export') }} --> -
+ { @@ -236,11 +246,45 @@ export default { }, created: function () { this.getPeoList() + this.getOptions() }, - watch: { - - }, + watch: { + ids: function (val) { + if (val.length === 0) { + this.dataForm.streetId = '' + this.dataForm.communityId = '' + this.dataForm.gridId = '' + } + if (val.length === 1) { + this.dataForm.streetId = this.ids[0] + this.dataForm.communityId = '' + this.dataForm.gridId = '' + } + if (val.length === 2) { + this.dataForm.streetId = this.ids[0] + this.dataForm.communityId = this.ids[1] + this.dataForm.gridId = '' + } + if (val.length === 3) { + this.dataForm.streetId = this.ids[0] + this.dataForm.communityId = this.ids[1] + this.dataForm.gridId = this.ids[2] + } + } + }, methods: { + getOptions () { + this.$http + .get(`/sys/user/deptOptions/getByLoginUser`) + .then(({ data: res }) => { + if (res.code !== 0) { + return this.$message.error(res.msg) + } + this.options = res.data.options + }) + .catch(() => { + }) + }, getPeoList () { console.log(this.dataList) }, diff --git a/src/views/modules/events/appeal-enforce-list.vue b/src/views/modules/events/appeal-enforce-list.vue index f735b4d4..c1654898 100644 --- a/src/views/modules/events/appeal-enforce-list.vue +++ b/src/views/modules/events/appeal-enforce-list.vue @@ -13,7 +13,16 @@
--> - + + + + - + @@ -41,8 +50,7 @@ -
-
+ {{ $t('export') }} --> -
+ { @@ -236,11 +246,45 @@ export default { }, created: function () { this.getPeoList() + this.getOptions() }, - watch: { - - }, + watch: { + ids: function (val) { + if (val.length === 0) { + this.dataForm.streetId = '' + this.dataForm.communityId = '' + this.dataForm.gridId = '' + } + if (val.length === 1) { + this.dataForm.streetId = this.ids[0] + this.dataForm.communityId = '' + this.dataForm.gridId = '' + } + if (val.length === 2) { + this.dataForm.streetId = this.ids[0] + this.dataForm.communityId = this.ids[1] + this.dataForm.gridId = '' + } + if (val.length === 3) { + this.dataForm.streetId = this.ids[0] + this.dataForm.communityId = this.ids[1] + this.dataForm.gridId = this.ids[2] + } + } + }, methods: { + getOptions () { + this.$http + .get(`/sys/user/deptOptions/getByLoginUser`) + .then(({ data: res }) => { + if (res.code !== 0) { + return this.$message.error(res.msg) + } + this.options = res.data.options + }) + .catch(() => { + }) + }, getPeoList () { console.log(this.dataList) }, diff --git a/src/views/modules/events/appeal-peo-list.vue b/src/views/modules/events/appeal-peo-list.vue index d6cca166..9f2920a1 100644 --- a/src/views/modules/events/appeal-peo-list.vue +++ b/src/views/modules/events/appeal-peo-list.vue @@ -13,7 +13,16 @@ - + + + + - + @@ -41,8 +50,8 @@ -
-
+ + {{ $t('export') }} --> -
+ { @@ -237,10 +248,46 @@ export default { created: function () { }, - watch: { - - }, + watch: { + ids: function (val) { + if (val.length === 0) { + this.dataForm.streetId = '' + this.dataForm.communityId = '' + this.dataForm.gridId = '' + } + if (val.length === 1) { + this.dataForm.streetId = this.ids[0] + this.dataForm.communityId = '' + this.dataForm.gridId = '' + } + if (val.length === 2) { + this.dataForm.streetId = this.ids[0] + this.dataForm.communityId = this.ids[1] + this.dataForm.gridId = '' + } + if (val.length === 3) { + this.dataForm.streetId = this.ids[0] + this.dataForm.communityId = this.ids[1] + this.dataForm.gridId = this.ids[2] + } + } + }, + created: function () { + this.getOptions() + }, methods: { + getOptions () { + this.$http + .get(`/sys/user/deptOptions/getByLoginUser`) + .then(({ data: res }) => { + if (res.code !== 0) { + return this.$message.error(res.msg) + } + this.options = res.data.options + }) + .catch(() => { + }) + }, dealAction (id) { this.$parent.selectComponent = 'AppealDetailView' this.$router.push({ path: '/events-appeal-peo', query: { id: id } })