Im passing the property to vue-good-table :select-options="{enabled: true}" to show checkbox for each row. I want to conditionally override this for certain rows. For example, if the column 'isAuthorized' has the value false, the checkbox should not be shown for that row. How to achieve this? Should I implement custom checkbox under <template slot="table-row" slot-scope="props">? Is there a built-in feature available in vue-good table?
Is it possible to enable/disable checkbox in vue-good-table?
1.8k views Asked by Prem At
1
I ran into same issue and found a way:
You can set
vgtDisabled:trueon the rows that should not be selectable. Similarly, you can setvgtSelected:truefor the rows that should be already checked by default.I found by looking into source of the component here: https://github.com/xaksis/vue-good-table/blob/d2d0a781ed823c40a3bf14efceac82626e48d67c/src/components/Table.vue#L238