ratiw / vuetable-2

data table simplify! -- datatable component for Vue 2.x. See documentation at
https://vuetable.com
MIT License
2.15k stars 399 forks source link

JSON array in field params #230

Open miigueeleelz opened 7 years ago

miigueeleelz commented 7 years ago

How to access a specific position in a json array inside field params?.

For example

employees: [ { name : 'Richard' }, { name : 'Gerard' } ]

and inside field params.

fields: [ { name: 'employees[0].name', sortField: 'name', title: 'Name', titleClass: 'text-left', dataClass: 'text-left' },

It's my example, but the field name is empty in Vuetable

ratiw commented 7 years ago

@miigueeleelz Array referencing does not support in Vuetable's fields definition. If it is always at 0 position, use __slot special field instead.