when option uniq is true, display message if you select multiple suggestions

This commit is contained in:
2021-05-10 19:13:50 +02:00
parent f7c08f02c2
commit 040884a039
4 changed files with 11 additions and 2 deletions

View File

@@ -71,6 +71,7 @@
@click.prevent="$emit('addNewPersons', { selected, modal })">
<i class="fa fa-plus fa-fw"></i>{{ $t('action.add')}}
</button>
{{ $t(checkUniq) }}
</template>
</modal>
@@ -144,6 +145,12 @@ export default {
},
options() {
return this.options;
},
checkUniq() {
if (this.options.uniq === true && this.selectedCounter > 1) {
return "error_only_one_person";
}
return '';
}
},
methods: {