Merge branch 'fix_addresses_issues' into bootstrap5_replacing_scratch

This commit is contained in:
2021-07-14 14:01:08 +02:00
8 changed files with 96 additions and 14 deletions

View File

@@ -131,7 +131,8 @@ export default {
this.$store.dispatch('addDateToAddressAndAddressToPerson', {
personId: this.personId,
addressId: this.$store.state.address.address_id,
body: { validFrom: {datetime: `${this.validFrom}T00:00:00+0100`}}
body: { validFrom: {datetime: `${this.validFrom}T00:00:00+0100`}},
backUrl: this.backUrl
})
},
getEditAddress() {

View File

@@ -95,9 +95,10 @@ const store = createStore({
postAddressToPerson(payload.personId, payload.addressId)
.then(person => new Promise((resolve, reject) => {
commit('addAddressToPerson', person);
resolve();
commit('setLoading', false);
commit('setSuccess', true);
window.location.assign(payload.backUrl);
resolve();
}))
.catch((error) => {
commit('catchError', error);