DocStore bundle: create a vue component for uploading document

This commit is contained in:
nobohan
2022-02-23 15:46:21 +01:00
parent 8f597eb254
commit 154f976762
3 changed files with 79 additions and 0 deletions

View File

@@ -0,0 +1,58 @@
<template>
<a class="btn btn-create" :title="$t(buttonTitle)" @click="openModal">
<span>{{ $t(buttonTitle) }}</span>
</a>
<teleport to="body">
<div>
<modal v-if="modal.showModal"
:modalDialogClass="modal.modalDialogClass"
@close="modal.showModal = false">
<template v-slot:header>
modal-header
</template>
<template v-slot:body>
modal body
</template>
<template v-slot:footer>
modal-footer
</template>
</modal>
</div>
</teleport>
</template>
<script>
import Modal from 'ChillMainAssets/vuejs/_components/Modal';
export default {
name: "AddAsyncUpload",
components: {
Modal
},
props: [
'buttonTitle',
],
data() {
return {
modal: {
showModal: false,
modalDialogClass: "modal-dialog-centered modal-md"
},
}
},
computed: {
},
methods: {
openModal() {
this.modal.showModal = true;
},
}
}
</script>