mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-12 21:34:25 +00:00
import ShowAddress in CourseLocation, with alert if temporary address
This commit is contained in:
parent
d6e41e5ac7
commit
17dd52c3dc
@ -1,5 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="chill-entity entity-address">
|
<div class="chill-entity entity-address my-3">
|
||||||
<div class="address multiline">
|
<div class="address multiline">
|
||||||
<p v-if="address.text"
|
<p v-if="address.text"
|
||||||
class="street">
|
class="street">
|
||||||
@ -51,8 +51,6 @@
|
|||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
@ -10,18 +10,14 @@
|
|||||||
{{ error }}
|
{{ error }}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div v-if="accompanyingCourse.location"
|
<show-address
|
||||||
class="chill-entity entity-address">
|
v-if="accompanyingCourse.location"
|
||||||
<div class="address multiline">
|
:address="accompanyingCourse.location">
|
||||||
<p class="street">{{ accompanyingCourse.location.street }}
|
</show-address>
|
||||||
<span class="streetnumber">{{ accompanyingCourse.location.streetNumber }}</span>
|
|
||||||
</p>
|
<div v-if="isTemporaryAddress"
|
||||||
<p class="postcode">
|
class="alert alert-warning">
|
||||||
<span class="code">{{ accompanyingCourse.location.postcode.code }}</span>
|
<p>{{ $t('courselocation.temporary_address_must_be_changed') }}</p>
|
||||||
<span class="name">{{ accompanyingCourse.location.postcode.name }}</span>
|
|
||||||
</p>
|
|
||||||
<p class="country">{{ accompanyingCourse.location.country.name.fr }}</p>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<ul class="record_actions">
|
<ul class="record_actions">
|
||||||
@ -45,11 +41,13 @@
|
|||||||
<script>
|
<script>
|
||||||
import { mapState } from "vuex";
|
import { mapState } from "vuex";
|
||||||
import AddAddress from 'ChillMainAssets/vuejs/Address/components/AddAddress.vue';
|
import AddAddress from 'ChillMainAssets/vuejs/Address/components/AddAddress.vue';
|
||||||
|
import ShowAddress from 'ChillMainAssets/vuejs/Address/components/ShowAddress.vue';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "CourseLocation",
|
name: "CourseLocation",
|
||||||
components: {
|
components: {
|
||||||
AddAddress
|
AddAddress,
|
||||||
|
ShowAddress
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@ -83,6 +81,9 @@ export default {
|
|||||||
}),
|
}),
|
||||||
hasTemporaryAddressButton() { // return true if locationStatus equal 'none' or 'address'
|
hasTemporaryAddressButton() { // return true if locationStatus equal 'none' or 'address'
|
||||||
return this.accompanyingCourse.locationStatus !== 'person';
|
return this.accompanyingCourse.locationStatus !== 'person';
|
||||||
|
},
|
||||||
|
isTemporaryAddress() {
|
||||||
|
return this.accompanyingCourse.locationStatus === 'address';
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
@ -69,6 +69,7 @@ const appMessages = {
|
|||||||
add_temporary_address: "Ajouter une adresse temporaire",
|
add_temporary_address: "Ajouter une adresse temporaire",
|
||||||
edit_temporary_address: "Modifier l'adresse temporaire",
|
edit_temporary_address: "Modifier l'adresse temporaire",
|
||||||
assign_course_address: "Désigner comme l'adresse du parcours",
|
assign_course_address: "Désigner comme l'adresse du parcours",
|
||||||
|
temporary_address_must_be_changed: "Cette addresse est temporaire et doit être remplacée rapidement par celle d'un usager de référence.",
|
||||||
},
|
},
|
||||||
referrer: {
|
referrer: {
|
||||||
title: "Référent du parcours",
|
title: "Référent du parcours",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user