You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
65 lines
1.1 KiB
65 lines
1.1 KiB
<template>
|
|
<div>
|
|
<b-button-toolbar>
|
|
<b-button
|
|
v-if="handleShow"
|
|
variant="info"
|
|
size="sm"
|
|
class="mr-2"
|
|
@click="handleShow"
|
|
>{{ $t('Info') }}
|
|
</b-button>
|
|
<b-button
|
|
v-if="handleEdit"
|
|
size="sm"
|
|
class="mr-2"
|
|
@click="handleEdit"
|
|
>{{ $t('Edit') }}
|
|
</b-button>
|
|
<b-button
|
|
v-if="handleDelete"
|
|
variant="danger"
|
|
size="sm"
|
|
@click="confirmDelete = true"
|
|
>{{ $t('Delete') }}
|
|
</b-button>
|
|
</b-button-toolbar>
|
|
|
|
<ConfirmDelete
|
|
v-if="handleDelete"
|
|
:visible="confirmDelete"
|
|
:handle-delete="handleDelete"
|
|
@close="confirmDelete = false"
|
|
/>
|
|
</div>
|
|
</template>
|
|
|
|
<script>
|
|
import ConfirmDelete from './ConfirmDelete';
|
|
|
|
export default {
|
|
name: 'ActionCell',
|
|
components: {
|
|
ConfirmDelete
|
|
},
|
|
props: {
|
|
handleShow: {
|
|
type: Function,
|
|
required: false
|
|
},
|
|
handleEdit: {
|
|
type: Function,
|
|
required: false
|
|
},
|
|
handleDelete: {
|
|
type: Function,
|
|
required: false
|
|
}
|
|
},
|
|
data() {
|
|
return {
|
|
confirmDelete: false
|
|
};
|
|
}
|
|
};
|
|
</script>
|
|
|