Select rows in Vuetify Data Table

后端 未结 2 1129
小蘑菇
小蘑菇 2021-01-24 22:49

I was wondering how can I select/unselect a row by clicking a row in a datatable in Vuetify. It would be even better if I could select a range by using shift+click or shift+arr

2条回答
  •  长发绾君心
    2021-01-24 23:29

    I think you want to use v-model instead...

    
          
    
    

    Demo


    You can also the Vuetify Data Table select function to toggle the selected rows. This is easier than having custom methods to handle the selection logic.

    Demo 2

提交回复
热议问题