Skip to content

How to use filter with laravel API #104

@eduardoarandah

Description

@eduardoarandah

Notes for lesson 13:
https://github.com/ratiw/vuetable-2-tutorial/wiki/lesson-13

If you are using this package in laravel for your API
https://github.com/santigarcor/laravel-vuetable

You need an extra param called "searchable"

Example

  <div class="form-inline">
    <input type="text" class="form-control mb-2 mr-sm-2" v-model="searchText" placeholder="Search..." @keyup="search">        
  </div>

method:

search () {
  this.moreParams={
    searchable: [
      'user.name',            
      'user.lastname',            
    ],
    'filter': this.searchText
  }
  Vue.nextTick( () => this.$refs.vuetable.refresh())
},

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions