mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +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>
|
||||
<div class="chill-entity entity-address">
|
||||
<div class="chill-entity entity-address my-3">
|
||||
<div class="address multiline">
|
||||
<p v-if="address.text"
|
||||
class="street">
|
||||
@ -51,8 +51,6 @@
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
@ -10,18 +10,14 @@
|
||||
{{ error }}
|
||||
</div>
|
||||
|
||||
<div v-if="accompanyingCourse.location"
|
||||
class="chill-entity entity-address">
|
||||
<div class="address multiline">
|
||||
<p class="street">{{ accompanyingCourse.location.street }}
|
||||
<span class="streetnumber">{{ accompanyingCourse.location.streetNumber }}</span>
|
||||
</p>
|
||||
<p class="postcode">
|
||||
<span class="code">{{ accompanyingCourse.location.postcode.code }}</span>
|
||||
<span class="name">{{ accompanyingCourse.location.postcode.name }}</span>
|
||||
</p>
|
||||
<p class="country">{{ accompanyingCourse.location.country.name.fr }}</p>
|
||||
</div>
|
||||
<show-address
|
||||
v-if="accompanyingCourse.location"
|
||||
:address="accompanyingCourse.location">
|
||||
</show-address>
|
||||
|
||||
<div v-if="isTemporaryAddress"
|
||||
class="alert alert-warning">
|
||||
<p>{{ $t('courselocation.temporary_address_must_be_changed') }}</p>
|
||||
</div>
|
||||
|
||||
<ul class="record_actions">
|
||||
@ -45,11 +41,13 @@
|
||||
<script>
|
||||
import { mapState } from "vuex";
|
||||
import AddAddress from 'ChillMainAssets/vuejs/Address/components/AddAddress.vue';
|
||||
import ShowAddress from 'ChillMainAssets/vuejs/Address/components/ShowAddress.vue';
|
||||
|
||||
export default {
|
||||
name: "CourseLocation",
|
||||
components: {
|
||||
AddAddress
|
||||
AddAddress,
|
||||
ShowAddress
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
@ -83,6 +81,9 @@ export default {
|
||||
}),
|
||||
hasTemporaryAddressButton() { // return true if locationStatus equal 'none' or 'address'
|
||||
return this.accompanyingCourse.locationStatus !== 'person';
|
||||
},
|
||||
isTemporaryAddress() {
|
||||
return this.accompanyingCourse.locationStatus === 'address';
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
|
@ -69,6 +69,7 @@ const appMessages = {
|
||||
add_temporary_address: "Ajouter une adresse temporaire",
|
||||
edit_temporary_address: "Modifier l'adresse temporaire",
|
||||
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: {
|
||||
title: "Référent du parcours",
|
||||
|
Loading…
x
Reference in New Issue
Block a user