mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-12 21:34:25 +00:00
main: add the coordinates of the postal code if no full address is selected
This commit is contained in:
parent
5be3b3f423
commit
5781f2af89
@ -588,6 +588,12 @@ export default {
|
|||||||
newAddress = Object.assign(newAddress, {
|
newAddress = Object.assign(newAddress, {
|
||||||
'point': this.entity.selected.address.point.coordinates
|
'point': this.entity.selected.address.point.coordinates
|
||||||
});
|
});
|
||||||
|
} else {
|
||||||
|
if (this.entity.selected.postcode.coordinates) {
|
||||||
|
newAddress = Object.assign(newAddress, {
|
||||||
|
'point': this.entity.selected.postcode.coordinates
|
||||||
|
});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// add the address reference, if any
|
// add the address reference, if any
|
||||||
|
@ -141,7 +141,6 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
addAddress() {
|
addAddress() {
|
||||||
console.log('addAddress: pass here ?? never, it seems');
|
|
||||||
this.entity.selected.writeNew.address = true;
|
this.entity.selected.writeNew.address = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -101,6 +101,7 @@ export default {
|
|||||||
this.entity.selected.city = value;
|
this.entity.selected.city = value;
|
||||||
this.entity.selected.postcode.name = value.name;
|
this.entity.selected.postcode.name = value.name;
|
||||||
this.entity.selected.postcode.code = value.code;
|
this.entity.selected.postcode.code = value.code;
|
||||||
|
this.entity.selected.postcode.coordinates = value.center.coordinates;
|
||||||
this.entity.selected.writeNew.postcode = false;
|
this.entity.selected.writeNew.postcode = false;
|
||||||
console.log('writeNew.postcode false, in selectCity');
|
console.log('writeNew.postcode false, in selectCity');
|
||||||
this.$emit('getReferenceAddresses', value);
|
this.$emit('getReferenceAddresses', value);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user