Navigation Menu

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(client-vue): boolean filters support #4314

Merged
merged 14 commits into from Apr 26, 2022

Conversation

ThomasKientz
Copy link
Contributor

@ThomasKientz ThomasKientz commented Apr 4, 2022

Check List

  • Tests has been run in packages where changes made if available
  • Linter has been run for changed code
  • Tests for the changes have been added if not covered yet
  • Docs have been added / updated if required

Issue Reference this PR resolves

4201

Description of Changes Made (if issue reference is not provided)

Nested boolean operators in filters like the example given in the docs are not compatible with the current version of query-builder Vue component.

I have improved the query-builder in order to take into account nested boolean operators. I have also added tests.

[
  {
    or: [
      {
        and: [
          {
            member: "Fluide.nom",
            operator: "contains",
            values: ["eau"],
          },
          {
            member: "Fluide.friendly",
            operator: "equals",
            values: ["0"],
          },
        ],
      },
      {
        and: [
          {
            member: "Fluide.nom",
            operator: "contains",
            values: ["zzz"],
          },
          {
            member: "Fluide.friendly",
            operator: "equals",
            values: ["89"],
          },
        ],
      },
    ],
  },
];

@ThomasKientz ThomasKientz requested a review from a team as a code owner April 4, 2022 13:58
@github-actions github-actions bot added the pr:community Contribution from Cube.js community members. label Apr 4, 2022
@codecov
Copy link

codecov bot commented Apr 19, 2022

Codecov Report

Merging #4314 (5a9f96e) into master (69a75dc) will decrease coverage by 10.15%.
The diff coverage is n/a.

@@             Coverage Diff             @@
##           master    #4314       +/-   ##
===========================================
- Coverage   69.11%   58.95%   -10.16%     
===========================================
  Files         240      134      -106     
  Lines       22836    10952    -11884     
  Branches     2585     2585               
===========================================
- Hits        15782     6457     -9325     
+ Misses       6777     4218     -2559     
  Partials      277      277               
Flag Coverage Δ
cube-backend 58.95% <ø> (ø)
cubesql ?

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
rust/cubesql/cubesql/src/transport/service.rs
...nt/src/models/v1_load_request_query_filter_base.rs
...le/engine/information_schema/postgres/pg_depend.rs
rust/cubesql/cubesql/src/sql/dataframe.rs
...ql/src/sql/database_variables/mysql/global_vars.rs
rust/cubesql/cubesql/e2e/tests/postgres.rs
rust/cubesql/cubesql/src/sql/postgres/writer.rs
...ne/information_schema/postgres/key_column_usage.rs
rust/cubesql/cubesql/src/telemetry/mod.rs
...pile/engine/information_schema/postgres/pg_proc.rs
... and 96 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 69a75dc...5a9f96e. Read the comment docs.

@ThomasKientz
Copy link
Contributor Author

@vasilev-alex could you review this PR please ?

@vasilev-alex vasilev-alex changed the title Vue filters feat(client-vue): boolean filters support Apr 26, 2022
@vasilev-alex vasilev-alex merged commit 8a3bb3d into cube-js:master Apr 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr:community Contribution from Cube.js community members.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants