Closed ghost closed 1 year ago
I got it to work by using data as a function like this
let filter = this.nameFilter
ajax: {
url: "/repuestos/datatable",
data: function (data) {
data.name= filter.name
}
}
In my table options i have
ajax: { url: 'backend/test', data: { name: this.nameFilter } }
when i do
console.log(this.$refs.table.opts.ajax.data)
orconsole.log(this.$refs.table.dataTable.ajax.data)
they both show the value changing yet the value its not sending when using
this.$refs.table.reload()
i also tried assigning the values this way:
this.$refs.table.opts.ajax.data = { 'name' : this.nameFilter }
and
this.$refs.table.dataTable.ajax.data = { 'name' : this.nameFilter }
with the same exact results
I think im missing something how should i approach it?