forked from rewiko/crud
-
Notifications
You must be signed in to change notification settings - Fork 39
Open
ZaidMaslouhi/dataui-nestjs-crud
#2Description
Description
When using a join condition that includes an array-like value (such as a date range) in the on clause, the current parsing mechanism fails to correctly convert the query string to a plain object.
Specific Example
The following query string causes issues:
join[]=events||id,name||on[0]=event.date||$between||16-12-2023,23-12-2023
Current Behavior
- The parsing logic breaks when encountering comma-separated values within the on clause
- This prevents the correct transformation of the query string to a usable object for filtering
Expected Behavior
The join condition should successfully parse the query string, correctly handling array-like values such as date ranges.
Potential Impact
- Prevents users from using complex join conditions with range-based filters
- Limits the flexibility of querying across related entities with multiple condition types
Reproduction Steps
- Construct a query string with a join condition containing a comma-separated value
- Attempt to parse the query string
- Observe the parsing failure
Additional Context
This issue is particularly problematic for date range queries and similar scenarios requiring multiple values in a single condition.
Possible Solutions
- Enhance the parsing logic to correctly handle comma-separated values
- Implement a more flexible parsing mechanism for complex join conditions
Metadata
Metadata
Assignees
Labels
No labels