private void btnBuscarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnBuscarActionPerformed
        String text = txtBuscar.getText().toString();
        AdministradorCRUD adao =  new AdministradorCRUD(MyConnection.getConnection());
        ArrayList<Administrador> listado = new ArrayList<>();
        Administrador admin = null;
        if(text.isEmpty()){
            listado = adao.getAll();
        }else{
            String option = jComboBox1.getSelectedItem().toString();
            switch(option){
                case "Alias":
                    admin = new Administrador(text, null, null);
                    listado = adao.getById(admin);
                    break;
                    
                case "DNI":
                    admin = new Administrador(null, null, text);
                    listado = adao.getByDNI(admin);
                    break;
            }
        }
        if(listado.isEmpty()){
            JOptionPane.showMessageDialog(this, "No se encontraron coincidencias");
        }else{
            volcarDatos(listado);
        }
    }//GEN-LAST:event_btnBuscarActionPerformed