mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
otf: replace button by link in show modale
This commit is contained in:
parent
1eb8d04a32
commit
decc3c7463
@ -42,16 +42,16 @@
|
||||
</template>
|
||||
|
||||
<template v-slot:footer>
|
||||
<button v-if="action === 'show'"
|
||||
@click="goToLocation(id, type)"
|
||||
<a v-if="action === 'show'"
|
||||
:href="buildLocation(id, type)"
|
||||
:title="$t(titleMessage)"
|
||||
class="btn btn-show">{{ $t(buttonMessage) }}
|
||||
</button>
|
||||
<button v-else
|
||||
</a>
|
||||
<a v-else
|
||||
class="btn btn-save"
|
||||
@click="saveAction">
|
||||
{{ $t('action.save')}}
|
||||
</button>
|
||||
</a>
|
||||
</template>
|
||||
|
||||
</modal>
|
||||
@ -174,11 +174,12 @@ export default {
|
||||
|
||||
this.modal.showModal = false;
|
||||
},
|
||||
goToLocation(id, type) {
|
||||
buildLocation(id, type) {
|
||||
if (type == 'person') {
|
||||
window.location = `../../person/${id}/general`;
|
||||
// TODO i18n
|
||||
return `/fr/person/${id}/general`;
|
||||
} else if (type == 'thirdparty') {
|
||||
window.location = `../../thirdparty/thirdparty/${id}/show`;
|
||||
return `/fr/thirdparty/thirdparty/${id}/show`;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user