Skip to content

fix(query-builder): returnFields should be '*' on entity change / all fileds are selected#15445

Merged
gedinakova merged 6 commits intomasterfrom
thristodorova/query-builder-fix-return-fields
Mar 12, 2025
Merged

fix(query-builder): returnFields should be '*' on entity change / all fileds are selected#15445
gedinakova merged 6 commits intomasterfrom
thristodorova/query-builder-fix-return-fields

Conversation

@teodosiah
Copy link
Copy Markdown
Contributor

Closes #

Additional information (check all that apply):

  • Bug fix
  • New functionality
  • Documentation
  • Demos
  • CI/CD

Checklist:

  • All relevant tags have been applied to this PR
  • This PR includes unit tests covering all the new code (test guidelines)
  • This PR includes API docs for newly added methods/properties (api docs guidelines)
  • This PR includes feature/README.MD updates for the feature docs
  • This PR includes general feature table updates in the root README.MD
  • This PR includes CHANGELOG.MD updates for newly added functionality
  • This PR contains breaking changes
  • This PR includes ng update migrations for the breaking changes (migrations guidelines)
  • This PR includes behavioral changes and the feature specification has been updated with them

@teodosiah teodosiah added ❌ status: awaiting-test PRs awaiting manual verification query-builder labels Mar 4, 2025
@teodosiah teodosiah requested a review from gedinakova March 4, 2025 09:54
this._expressionTree.entity = this._entityNewValue.name;
this._expressionTree.returnFields = [];

if (this.fields.length === this._selectedReturnFields.length) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could be done with a ternary expression as well.


// Verify the returnFields
exprTreeReturnFields = JSON.stringify(fix.componentInstance.queryBuilder.expressionTree.returnFields);
expect(exprTreeReturnFields).toBe(`["*"]`);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about the case when all fields get explicitly checked again or via the "Select All" checkbox (for the same entity)? This is not covered in a test and doesn't seem to work yet.

@teodosiah teodosiah requested a review from gedinakova March 7, 2025 11:10
@gedinakova gedinakova added 💥 status: in-test PRs currently being tested and removed ❌ status: awaiting-test PRs awaiting manual verification labels Mar 11, 2025
@gedinakova gedinakova added ✅ status: verified Applies to PRs that have passed manual verification and removed 💥 status: in-test PRs currently being tested labels Mar 12, 2025
@gedinakova gedinakova self-assigned this Mar 12, 2025
@gedinakova gedinakova merged commit a7b6942 into master Mar 12, 2025
5 checks passed
@gedinakova gedinakova deleted the thristodorova/query-builder-fix-return-fields branch March 12, 2025 08:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

query-builder ✅ status: verified Applies to PRs that have passed manual verification

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants