diff --git a/src/views/modules/custom/voterregistration.vue b/src/views/modules/custom/voterregistration.vue
index f3a1d8d..d025e46 100644
--- a/src/views/modules/custom/voterregistration.vue
+++ b/src/views/modules/custom/voterregistration.vue
@@ -3,7 +3,7 @@
-
+
{
+ this.$http.get(`/custom/voterregistrationconfig/getConfigByType`, { params: { configType: '0', pid: '' } }).then(({ data: res }) => {
if (res.code !== 0) {
return this.$message.error(res.msg)
}
this.constituencyList = res.data
}).catch(() => {})
},
- getGroupList () {
- this.$http.get(`/custom/voterregistrationconfig/getConfigByType/1`).then(({ data: res }) => {
+ getGroupList (code) {
+ let pid = ''
+ this.constituencyList.find((item) => {
+ if (item.configCode === code) {
+ pid = item.id
+ }
+ })
+ if (pid === '') {
+ this.groupList = []
+ return
+ }
+ this.$http.get(`/custom/voterregistrationconfig/getConfigByType`, { params: { configType: '', pid: pid } }).then(({ data: res }) => {
if (res.code !== 0) {
return this.$message.error(res.msg)
}
@@ -171,7 +181,7 @@ export default {
}).catch(() => {})
},
getParticipationPrincipleList () {
- this.$http.get(`/custom/voterregistrationconfig/getConfigByType/2`).then(({ data: res }) => {
+ this.$http.get(`/custom/voterregistrationconfig/getConfigByType`, { params: { configType: '2', pid: '' } }).then(({ data: res }) => {
if (res.code !== 0) {
return this.$message.error(res.msg)
}