Feature: [address reference] adapt vue app AccompanyingCourse to allow to open address details modal

This commit is contained in:
Julien Fastré 2023-03-22 10:37:38 +01:00
parent adc80d5080
commit 204c28d373
Signed by: julienfastre
GPG Key ID: BDE2190974723FCB
4 changed files with 424 additions and 400 deletions

View File

@ -15,7 +15,8 @@
:person="participation.person" :person="participation.person"
:returnPath="getAccompanyingCourseReturnPath"> :returnPath="getAccompanyingCourseReturnPath">
<template v-slot:record-actions> <template v-slot:end-bloc>
<div class="item-row separator">
<ul class="record_actions"> <ul class="record_actions">
<button-location <button-location
v-if="hasCurrentHouseholdAddress" v-if="hasCurrentHouseholdAddress"
@ -38,10 +39,12 @@
</button> </button>
</li> </li>
</ul> </ul>
</div>
</template> </template>
</person-render-box> </person-render-box>
<teleport to="body"> <teleport to="body">
<modal v-if="modal.showModal" :modalDialogClass="modal.modalDialogClass" @close="modal.showModal = false"> <modal v-if="modal.showModal" :modalDialogClass="modal.modalDialogClass" @close="modal.showModal = false">
<template v-slot:header> <template v-slot:header>

View File

@ -12,7 +12,8 @@
hLevel : 3, hLevel : 3,
isConfidential : true isConfidential : true
}"> }">
<template v-slot:record-actions> <template v-slot:end-bloc>
<div class="item-row separator">
<ul class="record_actions"> <ul class="record_actions">
<li> <li>
<write-comment <write-comment
@ -46,6 +47,7 @@
</button> </button>
</li> </li>
</ul> </ul>
</div>
</template> </template>
</person-render-box> </person-render-box>
@ -59,7 +61,8 @@
addInfo: false, addInfo: false,
hLevel: 3 hLevel: 3
}"> }">
<template v-slot:record-actions> <template v-slot:end-bloc>
<div class="item-row separator">
<ul class="record_actions"> <ul class="record_actions">
<li> <li>
<write-comment <write-comment
@ -93,6 +96,7 @@
</button> </button>
</li> </li>
</ul> </ul>
</div>
</template> </template>
</third-party-render-box> </third-party-render-box>
</template> </template>

View File

@ -43,7 +43,8 @@
{{ $t(getGenderTranslation) + ' ' + $d(birthdate, 'text') }} {{ $t(getGenderTranslation) + ' ' + $d(birthdate, 'text') }}
</time> </time>
<time v-else-if="person.birthdate && person.deathdate" :datetime="person.deathdate" :title="person.deathdate"> <time v-else-if="person.birthdate && person.deathdate" :datetime="person.deathdate"
:title="person.deathdate">
{{ $d(birthdate) }} - {{ $d(deathdate) }} {{ $d(birthdate) }} - {{ $d(deathdate) }}
</time> </time>
@ -51,7 +52,9 @@
{{ $t('renderbox.deathdate') + ' ' + deathdate }} {{ $t('renderbox.deathdate') + ' ' + deathdate }}
</time> </time>
<span v-if="options.addAge && person.birthdate" class="age">{{ $tc('renderbox.years_old', person.age) }}</span> <span v-if="options.addAge && person.birthdate" class="age">{{
$tc('renderbox.years_old', person.age)
}}</span>
</p> </p>
</div> </div>
</div> </div>
@ -128,7 +131,8 @@
</div> </div>
</div> </div>
<div class="item-col mx-3" v-if="this.showResidentialAddresses && (person.current_residential_addresses || []).length > 0"> <div class="item-col mx-3"
v-if="this.showResidentialAddresses && (person.current_residential_addresses || []).length > 0">
<div class="float-button bottom"> <div class="float-button bottom">
<div class="box"> <div class="box">
<ul class="list-content fa-ul"> <ul class="list-content fa-ul">
@ -175,6 +179,9 @@
</div> </div>
</div> </div>
<slot name="end-bloc"></slot>
</section> </section>
</div> </div>
@ -300,6 +307,7 @@ div.flex-table {
div.item-col:first-child { div.item-col:first-child {
width: 33%; width: 33%;
} }
div.item-col:last-child { div.item-col:last-child {
justify-content: flex-start; justify-content: flex-start;
@ -310,8 +318,14 @@ div.flex-table {
.age { .age {
margin-left: 0.5em; margin-left: 0.5em;
&:before { content: '('; }
&:after { content: ')'; } &:before {
content: '(';
}
&:after {
content: ')';
}
} }
</style> </style>

View File

@ -59,7 +59,8 @@
<ul class="list-content fa-ul"> <ul class="list-content fa-ul">
<li v-if="thirdparty.address"> <li v-if="thirdparty.address">
<i class="fa fa-li fa-map-marker"></i> <i class="fa fa-li fa-map-marker"></i>
<address-render-box :address="thirdparty.address" :isMultiline="isMultiline"></address-render-box> <address-render-box :address="thirdparty.address"
:isMultiline="isMultiline"></address-render-box>
</li> </li>
<li v-if="thirdparty.telephone"> <li v-if="thirdparty.telephone">
<i class="fa fa-li fa-mobile"></i> <i class="fa fa-li fa-mobile"></i>
@ -90,9 +91,8 @@
</div> </div>
</div> </div>
</div> </div>
</div> </div>
<slot name="end-bloc"></slot>
</section> </section>
</div> </div>
@ -119,7 +119,8 @@ export default {
fr: { fr: {
children: "Personnes de contact: ", children: "Personnes de contact: ",
child_of: "Contact de: ", child_of: "Contact de: ",
}} }
}
}, },
props: ['thirdparty', 'options'], props: ['thirdparty', 'options'],
computed: { computed: {
@ -160,6 +161,7 @@ export default {
&:before { &:before {
content: " " content: " "
} }
&.tparty-parent { &.tparty-parent {
font-weight: bold; font-weight: bold;
font-variant: all-small-caps; font-variant: all-small-caps;
@ -170,6 +172,7 @@ export default {
&::after { &::after {
content: " | "; content: " | ";
} }
&:last-child::after { &:last-child::after {
content: "" content: ""
} }