BUG 31150

This commit is contained in:
aixianling
2022-10-31 11:23:30 +08:00
parent d04559427e
commit d6cdc715b5

View File

@@ -87,7 +87,8 @@ export default {
computed: {
...mapState(['user']),
isMakeUp: v => v.$route.hash == "#makeup",
pageTitle: v => v.isMakeUp ? "补录换届" : "换届设置"
pageTitle: v => v.isMakeUp ? "补录换届" : "换届设置",
oid: v => v.$route.query.oid
},
watch: {
'form.type'() {
@@ -95,7 +96,9 @@ export default {
}
},
created() {
this.org = new this.MODEL.PartyOrg(this.$route.query.oid)
if (!!this.oid) {
this.org = new this.MODEL.PartyOrg(this.oid)
}
!!this.isMakeUp ? this.getSession() : this.getDetail()
},
methods: {
@@ -113,7 +116,7 @@ export default {
pureBack: true,
params: {id}
}).then((res) => {
if (res?.data&&res?.code=='0') {
if (res?.data && res?.code == '0') {
this.form = res.data
}
})
@@ -125,7 +128,7 @@ export default {
pureBack: true,
params: {organizationId}
}).then((res) => {
if (res?.data&&res?.code=='0') {
if (res?.data && res?.code == '0') {
this.form = res.data
}
})
@@ -146,7 +149,8 @@ export default {
const action = `/app/${this.isMakeUp ? 'apporganizationgeneralelection' : 'apporganizationchangeconfig'}/${!!this.form.id ? 'update' : 'add'}`
const addOrMakeup = !this.isMakeUp
this.instance.post(action, {
...this.form, organizationId, organizationName, addOrMakeup
organizationId, organizationName,
...this.form, addOrMakeup
}).then(res => {
if (res.code == 0) {
this.$message.success('提交成功')