Skip to content

Conversation

@CroogQT
Copy link

@CroogQT CroogQT commented May 5, 2022

Fixes: #8704

Allows a user to shift click a checkbox to set the "checked" value of all check boxes between their selection and their previous selection to the new value of their selected checkbox.

@LHBL2003
Copy link

LHBL2003 commented May 6, 2022

So does this new feature support my feature suggestion?

#9307

Or is something else meant here?

@kkthxbye-code
Copy link
Contributor

@LHBL2003 - This is not related to your issue no.

@CroogQT
Copy link
Author

CroogQT commented May 6, 2022

Hopefully this will help clarify the intent of #8704 as I understand it.

multiselect.mov

@kkthxbye-code
Copy link
Contributor

Tried it out, works great!

Found a very minor issue:

  • Click one or more checkboxes
  • Search for something in the Quick Search input
  • Remove the search string from Quick Search again
  • Shift click any checkbox

Everything from the bottom of the table and to where you clicked will be marked. The reason is that when using the Quick Search the table is replaced by HTMX. As such the state of the previous element will be wrong (doesn't exist anymore) and it will mark everything as it never finds the target element.

Maybe you can clear the state whenever a HTMX table has been rendered.

@CroogQT
Copy link
Author

CroogQT commented May 10, 2022

Tried it out, works great!

Found a very minor issue:

* Click one or more checkboxes

* Search for something in the Quick Search input

* Remove the search string from Quick Search again

* Shift click any checkbox

Everything from the bottom of the table and to where you clicked will be marked. The reason is that when using the Quick Search the table is replaced by HTMX. As such the state of the previous element will be wrong (doesn't exist anymore) and it will mark everything as it never finds the target element.

Maybe you can clear the state whenever a HTMX table has been rendered.

Ah! Great catch and great solution! Will implement shortly. Thanks for the feedback! :)

@kkthxbye-code
Copy link
Contributor

@CroogQT - Expect getting some time to work on this? I think it's a great usability improvement.

If you don't have the time I can give it a shot fixing the last small bug.

@jeremystretch
Copy link
Member

Honestly I'm ok with merging this as-is, even with the bug. Happy to open a separate bug report to track the remaining work.

@kkthxbye-code
Copy link
Contributor

More than fine by me.

@jeremystretch jeremystretch merged commit a71b2e2 into netbox-community:develop Jun 17, 2022
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 17, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

shift click to select multiple boxes

4 participants