Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

116
Visualizações
How to completely customise DataGridPro's checkbox selection

I'm working on a React project that uses Material-UI, and has a DataGridPro component. We need the checkbox selection to work a bit differently from what's implemented.

As per this example, selectionModel is an array that contains the ID of every selected row. We need to work with an exclusion list and a selection list:

  • Select all and add items to the exclusion list on deselect
  • Select only some rows, which would go to into the selection list

Is it possible to change the way checkbox selection works on DataGridPro this much? Also, is it possible to detect a click on the "select all" checkbox in the setSelectionModel method?

Thanks in advance for any suggestions.

about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

As you mentioned, controlled selection allows you to completely customize which row is selected. Then it is up to you to define the logic.

To detect when the "select all" checkbox is clicked, you can use headerSelectionCheckboxChange event (doc)

about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda