Skip to content
This repository has been archived by the owner on Nov 26, 2021. It is now read-only.

Commit

Permalink
fix #820
Browse files Browse the repository at this point in the history
  • Loading branch information
matfish2 committed Apr 17, 2020
1 parent 3a88261 commit 58bd846
Show file tree
Hide file tree
Showing 9 changed files with 51 additions and 125 deletions.
3 changes: 3 additions & 0 deletions compiled/components/VtClientTable.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,9 @@ var _default2 = {
getOpenChildRows: function getOpenChildRows() {
var rows = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
return this.$refs.table.getOpenChildRows(rows);
},
resetQuery: function resetQuery() {
this.$refs.table.resetQuery();
}
},
computed: {
Expand Down
3 changes: 3 additions & 0 deletions compiled/components/VtServerTable.js
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,9 @@ var _default2 = {
},
getResponseData: function getResponseData(response) {
return this.$refs.table.getResponseData(response);
},
resetQuery: function resetQuery() {
this.$refs.table.resetQuery();
}
},
provide: function provide() {
Expand Down
2 changes: 1 addition & 1 deletion dist/vue-tables-2.min.js

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions dist/vue-tables.js

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions lib/components/VtClientTable.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,9 @@ export default {
},
getOpenChildRows(rows = null) {
return this.$refs.table.getOpenChildRows(rows);
},
resetQuery() {
this.$refs.table.resetQuery()
}
},
computed: {
Expand Down
38 changes: 23 additions & 15 deletions lib/components/VtServerTable.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,24 +37,24 @@ export default {
}
},
computed: {
customQueries: {
get() {
return this.$refs.table.customQueries;
customQueries: {
get() {
return this.$refs.table.customQueries;
},
set(val) {
this.$refs.table.customQueries = val;
}
},
set(val) {
this.$refs.table.customQueries = val;
}
},
data() {
return this.$refs.table.tableData
return this.$refs.table.tableData
}
},
methods: {
refresh() {
this.$refs.table.refresh();
this.$refs.table.refresh();
},
getData() {
return this.$refs.table.getData();
return this.$refs.table.getData();
},
setFilter(val) {
this.$refs.table.setFilter(val);
Expand All @@ -73,6 +73,9 @@ export default {
},
getResponseData(response) {
return this.$refs.table.getResponseData(response);
},
resetQuery() {
this.$refs.table.resetQuery()
}
},
provide() {
Expand All @@ -85,7 +88,8 @@ export default {
prop: "data"
},
render(h) {
return <r-l-server-table url={this.url} columns={this.columns} name={this.name} options={this.options} ref="table" scopedSlots={
return <r-l-server-table url={this.url} columns={this.columns} name={this.name} options={this.options}
ref="table" scopedSlots={
{
default: function (props) {
return props.override ? h(props.override, {
Expand All @@ -95,27 +99,31 @@ export default {
<div class={props.theme.row}>
<div class={props.theme.column}>
{!props.opts.filterByColumn && props.opts.filterable ?
<div class={`${props.theme.field} ${props.theme.inline} ${props.theme.left} VueTables__search`}>
<div
class={`${props.theme.field} ${props.theme.inline} ${props.theme.left} VueTables__search`}>
{props.slots.beforeFilter}
<vt-generic-filter/>
{props.slots.afterFilter}
</div> : ''}
{props.slots.afterFilterWrapper}

{props.perPageValues.length > 1 ? <div class={`${props.theme.field} ${props.theme.inline} ${props.theme.right} VueTables__limit`}>
{props.perPageValues.length > 1 ? <div
class={`${props.theme.field} ${props.theme.inline} ${props.theme.right} VueTables__limit`}>
{props.slots.beforeLimit}
<vt-per-page-selector/>
{props.slots.afterLimit}
</div> : ''}

{props.opts.pagination.dropdown && props.totalPages > 1 ?
<div class="VueTables__pagination-wrapper">
<div class={`${props.theme.field} ${props.theme.inline} ${props.theme.right} VueTables__dropdown-pagination`}>
<div
class={`${props.theme.field} ${props.theme.inline} ${props.theme.right} VueTables__dropdown-pagination`}>
<vt-dropdown-pagination/>
</div>
</div> : ''}

{props.opts.columnsDropdown ? <div class={`VueTables__columns-dropdown-wrapper ${props.theme.right} ${props.theme.dropdown.container}`}>
{props.opts.columnsDropdown ? <div
class={`VueTables__columns-dropdown-wrapper ${props.theme.right} ${props.theme.dropdown.container}`}>
<vt-columns-dropdown/>
</div> : ''}
</div>
Expand Down
2 changes: 1 addition & 1 deletion lib/v-client-table.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import merge from "merge";
import Table from "./table";
import stateData from "./state/data";
import resizableColumns from "./helpers/resizeable-columns";
import VtClientTable from "./components/VtClientTable.jsx";
import VtClientTable from "./components/VtClientTable";

var data = require("./mixins/data");
var created = require("./mixins/created");
Expand Down
117 changes: 13 additions & 104 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "vue-tables-2",
"description": "Vue.js 2 grid components",
"version": "2.0.14",
"version": "2.0.15",
"keywords": [
"vue2",
"vuex",
Expand Down

0 comments on commit 58bd846

Please sign in to comment.