Adding recursive search of objects by default
e.g. { rows: [{ name: 'Device 1', project: { name: 'Project 1' ] matches both Device and Project
Adding support to :search-fields for nested properties
e.g. ['project.name'] for the above to match only the project name field
I intend to refactor the filtering and sorting logic out of the data-table into a service/helper in a follow-up if there's time. This would have two key advantages:
Increase (and simplify) testability by decoupling it from data-tables and Vue
Opens the possibility for supporting different approaches (.e.g server side)
This PR is likely easier to review commit by commit.
Fixes #35 by:
{ rows: [{ name: 'Device 1', project: { name: 'Project 1' ]
matches bothDevice
andProject
:search-fields
for nested properties e.g.['project.name']
for the above to match only the project name fieldI intend to refactor the filtering and sorting logic out of the data-table into a service/helper in a follow-up if there's time. This would have two key advantages:
This PR is likely easier to review commit by commit.