Skip to content

Fixes #133: Fix search index display_attrs referencing non-existent fields#135

Merged
DanSheps merged 1 commit into
DanSheps:mainfrom
jsenecal:fix/issue-133-search-display-attrs
Jan 20, 2026
Merged

Fixes #133: Fix search index display_attrs referencing non-existent fields#135
DanSheps merged 1 commit into
DanSheps:mainfrom
jsenecal:fix/issue-133-search-display-attrs

Conversation

@jsenecal
Copy link
Copy Markdown
Collaborator

@jsenecal jsenecal commented Jan 8, 2026

Summary

  • Fix SupportContractAssignmentIndex.display_attrs referencing fields from SupportContract instead of SupportContractAssignment
  • Fix LicenseAssignmentIndex.display_attrs referencing fields from License instead of LicenseAssignment
  • Add regression tests for display_attrs validation

Test plan

  • New tests pass: test_search.py
  • Full test suite passes (392 tests)

…istent fields

SupportContractAssignmentIndex and LicenseAssignmentIndex had display_attrs
that referenced fields from their parent models instead of their own fields.

This caused a FieldDoesNotExist error when searching for devices with
support contract assignments.

Changes:
- SupportContractAssignmentIndex: use contract, sku, device instead of vendor, start, renewal
- LicenseAssignmentIndex: use license, vendor, device instead of manufacturer
- Add regression tests for display_attrs validation
@jsenecal jsenecal force-pushed the fix/issue-133-search-display-attrs branch from 3e07673 to f1fd3d5 Compare January 8, 2026 18:17
@jsenecal jsenecal requested a review from DanSheps January 8, 2026 18:18
@DanSheps DanSheps enabled auto-merge January 20, 2026 02:45
@DanSheps DanSheps disabled auto-merge January 20, 2026 02:45
@DanSheps DanSheps merged commit b150c61 into DanSheps:main Jan 20, 2026
4 checks passed
@jsenecal jsenecal deleted the fix/issue-133-search-display-attrs branch January 20, 2026 15:55
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