Vue : Filter on array of object for search
You define model
as an empty object in your data
method.
Even if you are setting the value of model
later, your filteredRow
method will fire when the component renders the template, meaning this.model.data
will be undefined
at that point.
The simplest fix would be to give model.data
an initial value in the data
method:
data() { return { model: { data: [] }, columns: {}, query: { search_input: '' }, }},