Skip to content

Disable ref lookup when References column is hidden - #583

Merged
qu1ck merged 1 commit into
openscopeproject:masterfrom
DominikPalo:fix-hidden-references-reflookup
Oct 6, 2026
Merged

qu1ck merged 1 commit into
openscopeproject:masterfrom
DominikPalo:fix-hidden-references-reflookup

Conversation

@DominikPalo

Copy link
Copy Markdown
Contributor

setShowBOMColumn is meant to disable and clear the ref lookup box when the References column is hidden, but it compared the column name against "references" while the column is named "References" (as used everywhere else, e.g. entryMatches and initDefaults). The branch never ran, so:

  • hiding References left the ref lookup box enabled, and
  • an active lookup kept filtering the BOM by a column that was no longer visible, with nothing on screen explaining why rows were missing.

Changes:

  • ibom.js: compare against "References", so hiding the column disables the box, clears it and drops its filter (the existing logic), and showing it re-enables the box.
  • util.js (initDefaults): also set the box's disabled state when References is restored as hidden from local storage. Without this the box was enabled again after a reload even though the column was still hidden.

Testing

KiCad Arduino_Uno template, local storage cleared before each run:

Step master this PR
Ref lookup J1 1 of 4 rows 1 of 4 rows
Hide References via the column menu box still enabled, value J1, BOM still filtered to 1 row box disabled and cleared, all 4 rows shown
Reload with References hidden box enabled box disabled
Show References again (n/a) box enabled, lookup J2 filters to 1 row

No console errors.

🤖 Generated with Claude Code

setShowBOMColumn compared the column name against "references" but the
column is named "References", so hiding it never disabled and cleared
the ref lookup box. An active lookup kept filtering the BOM by a column
that was no longer visible. Also apply the disabled state on page load
when References is hidden from a previous session.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@qu1ck
qu1ck merged commit d2fbaa1 into openscopeproject:master Oct 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants