mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
activity: do not override location if already exist (when validating new activity)
This commit is contained in:
parent
d50d68aa86
commit
dca17c409b
@ -110,10 +110,8 @@ export default function prepareLocations(store) {
|
|||||||
console.log('default loation id', window.default_location_id);
|
console.log('default loation id', window.default_location_id);
|
||||||
if (window.default_location_id) {
|
if (window.default_location_id) {
|
||||||
for (let group of store.state.availableLocations) {
|
for (let group of store.state.availableLocations) {
|
||||||
console.log(group);
|
|
||||||
let location = group.locations.find((l) => l.id === window.default_location_id);
|
let location = group.locations.find((l) => l.id === window.default_location_id);
|
||||||
console.log(location);
|
if (location !== undefined & store.state.activity.location === null) {
|
||||||
if (location !== undefined) {
|
|
||||||
store.dispatch('updateLocation', location);
|
store.dispatch('updateLocation', location);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user