Using the translate mixin in page table

parent 4f7c3c08
......@@ -2,7 +2,7 @@
<data-tables :data="data" :actions-def="actionsDef">
<el-table-column prop="id" label="Id" width="100">
</el-table-column>
<el-table-column prop="title" label="Title">
<el-table-column prop="title" :label="translate('page', 'title')">
</el-table-column>
<el-table-column prop="slug" label="Slug">
</el-table-column>
......@@ -21,15 +21,17 @@
<script>
import axios from 'axios'
import Translate from '../../../../Core/Assets/js/mixins/Translate'
let data;
export default {
mixins: [Translate],
data() {
return {
data,
actionsDef: {
def: [{
name: 'Create a page',
name: this.translate('page', 'create page'),
icon: 'edit',
handler: () => {
window.location = route('admin.page.page.create');
......@@ -48,7 +50,7 @@
},
goToEdit(scope) {
window.location = scope.row.urls.edit_url;
}
},
},
mounted() {
this.fetchData();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment