Skip to content

fix(ui): properly handles ID field component type based on payload.db.defaultIDType - #7416

Merged
jacobsfletch merged 3 commits into
betafrom
fix/beta/ID-contains-filter
Aug 5, 2024
Merged

jacobsfletch merged 3 commits into
betafrom
fix/beta/ID-contains-filter

Conversation

@PatrikKozak

Copy link
Copy Markdown
Contributor

Description

Fixes #7354

Since the defaultIDType for IDs in postgres are of type number - the contains operator should be available in the filter options.

This PR checks the defaultIDType of ID and properly outputs the correct component type for IDs

I.e if ID is of type number - the filter operators for ID should correspond to the the operators of type number as well

The contains operator only belongs on fields of type string, aka of component type text

  • I have read and understand the CONTRIBUTING.md document in this repository.

Type of change

  • Bug fix (non-breaking change which fixes an issue)

Checklist:

  • Existing test suite passes locally with my changes

@PatrikKozak
PatrikKozak requested a review from AlessioGr as a code owner July 29, 2024 18:24
@PatrikKozak PatrikKozak changed the title Fix/beta/id contains filter fix: properly handles ID field component type based on payload.db.defaultIDType Jul 29, 2024
@jacobsfletch jacobsfletch changed the title fix: properly handles ID field component type based on payload.db.defaultIDType fix(ui): properly handles ID field component type based on payload.db.defaultIDType Aug 5, 2024
@jacobsfletch
jacobsfletch merged commit 62666a9 into beta Aug 5, 2024
@jacobsfletch
jacobsfletch deleted the fix/beta/ID-contains-filter branch August 5, 2024 20:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Integer field (e.g. ID) with contains filter on postgres breaks/crashes the application completely.

2 participants