From 38ca903f3f1c237dc34beb8ba76affe9f5a267b3 Mon Sep 17 00:00:00 2001 From: cagataycivici Date: Tue, 30 Jun 2020 14:50:58 +0300 Subject: [PATCH] Resize, Toggle and Reorder demo update --- .../datatable/DataTableColResizeDemo.vue | 68 ++++++++++--------- .../datatable/DataTableColToggleDemo.vue | 40 +++++------ src/views/datatable/DataTableReorderDemo.vue | 46 ++++++------- 3 files changed, 78 insertions(+), 76 deletions(-) diff --git a/src/views/datatable/DataTableColResizeDemo.vue b/src/views/datatable/DataTableColResizeDemo.vue index 8fe930e73..aec2c2ce0 100755 --- a/src/views/datatable/DataTableColResizeDemo.vue +++ b/src/views/datatable/DataTableColResizeDemo.vue @@ -11,21 +11,23 @@
Fit Mode
- - - - - + + + + + + +
+ +
+
Expand Mode
+ + + + +
- -
Expand Mode
- - - - - -
@@ -34,38 +36,38 @@ -import CarService from '../../service/CarService'; +import ProductService from '../../service/ProductService'; export default { data() { return { - cars: null + products: null } }, - carService: null, + productService: null, created() { - this.carService = new CarService(); + this.productService = new ProductService(); }, mounted() { - this.carService.getCarsSmall().then(data => this.cars = data); + this.productService.getProductsSmall().then(data => this.products = data); } } @@ -76,20 +78,20 @@ export default { \ No newline at end of file diff --git a/src/views/datatable/DataTableColToggleDemo.vue b/src/views/datatable/DataTableColToggleDemo.vue index 859ad7c1d..ce7452ab3 100755 --- a/src/views/datatable/DataTableColToggleDemo.vue +++ b/src/views/datatable/DataTableColToggleDemo.vue @@ -9,14 +9,14 @@
- + - +
@@ -27,43 +27,43 @@ -import CarService from '../../service/CarService'; +import ProductService from '../../service/ProductService'; export default { data() { return { selectedColumns: null, columns: null, - cars: null + products: null } }, - carService: null, + productService: null, created() { - this.carService = new CarService(); + this.productService = new ProductService(); this.columns = [ - {field: 'year', header: 'Year'}, - {field: 'brand', header: 'Brand'}, - {field: 'color', header: 'Color'} + {field: 'name', header: 'Name'}, + {field: 'category', header: 'Category'}, + {field: 'quantity', header: 'Quantity'} ]; this.selectedColumns = this.columns; }, mounted() { - this.carService.getCarsSmall().then(data => this.cars = data); + this.productService.getProductsSmall().then(data => this.products = data); }, methods: { onToggle(value) { @@ -79,29 +79,29 @@ export default {