various fixes accompanying period

This commit is contained in:
Julien Fastré 2021-08-20 15:07:24 +02:00
parent 026ac91e69
commit bf0a24b38e
3 changed files with 14 additions and 5 deletions

View File

@ -120,7 +120,8 @@ class AccompanyingPeriodWorkEvaluation implements TrackUpdateInterface, TrackCre
* @var Collection
* @ORM\OneToMany(
* targetEntity=AccompanyingPeriodWorkEvaluationDocument::class,
* mappedBy="accompanyingPeriodWorkEvaluation"
* mappedBy="accompanyingPeriodWorkEvaluation",
* cascade={"remove"}
* )
* @Serializer\Groups({"read"})
*/

View File

@ -68,12 +68,15 @@
</li>
</ul>
</div>
<ul class="record_actions">
<ul class="record_actions" v-if="availableForCheckGoal.length > 0">
<li>
<button :title="$t('add_an_objective')" class="btn btn-create"
@click="toggleAddObjective"></button>
</li>
</ul>
<div v-else>
<span class="chill-no-data-statement">{{ $t('no_goals_available') }}</span>
</div>
</div>
<div><!-- empty for results --></div>
</div>
@ -102,11 +105,14 @@
</li>
</ul>
</div>
<ul class="record_actions">
<ul class="record_actions" v-if="evaluationsForAction.length > 0">
<li>
<button :title="$t('add_an_evaluation')" class="btn btn-create" @click="toggleAddEvaluation"></button>
</li>
</ul>
<div v-else>
<span class="chill-no-data-statement">{{ $t('no_evaluations_available') }}</span>
</div>
</div>
</div>
@ -255,6 +261,8 @@ const i18n = {
choose_thirdparties: "Choisir des tiers",
fix_these_errors: "Veuillez corriger les erreurs suivantes :",
available_evaluations_text: "Évaluations disponibles pour ajout :",
no_evaluations_available: "Aucune évaluation disponible",
no_goals_available: "Aucun objectif disponible",
}
}
};

View File

@ -19,11 +19,11 @@
<dt v-if="evaluation.warningInterval">{{ $t('warningInterval') }} :</dt>
<dd v-if="evaluation.warningInterval">{{ evaluation.warningInterval }}</dd>
<template v-if="evaluation.documents.length > 1">
<template v-if="evaluation.documents.length > 0">
<dt>{{ $t('documents') }} :</dt>
<dd>
<ul>
<li v-for="d in evaluation.documents" :key="d.id">
<li v-for="d in evaluation.documents">
{{ d.template.name.fr }}
<a :href="buildEditLink(d.storedObject)" class="btn btn-action btn-sm">
<i class="fa fa-edit"></i>