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

Fix search by variant on stock items #5660

Merged

Conversation

nvandoorn
Copy link
Contributor

Summary

This branch fixes the invalid SQL error that occurs when filtering stock locations by variant (#5506). The implementation changes are still a work in progress, so this pull request is in draft, but I wanted to put this up now so other contributors can see/use the feature spec.

Checklist

The following are mandatory for all PRs:

The following are not always needed:

  • 📖 I have updated the README to account for my changes.
  • 📑 I have documented new code with YARD.
  • 🛣️ I have opened a PR to update the guides.
  • ✅ I have added automated tests to cover my changes.
  • 📸 I have attached screenshots to demo visual changes.

@nvandoorn nvandoorn requested a review from a team as a code owner February 13, 2024 17:32
@nvandoorn nvandoorn marked this pull request as draft February 13, 2024 17:32
@github-actions github-actions bot added the changelog:solidus_backend Changes to the solidus_backend gem label Feb 13, 2024
@nvandoorn nvandoorn changed the title 5506 fix search by variant on stock items Fix search by variant on stock items Feb 13, 2024
Copy link

codecov bot commented Feb 13, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (020f3c2) 88.55% compared to head (c4bd75a) 88.55%.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #5660   +/-   ##
=======================================
  Coverage   88.55%   88.55%           
=======================================
  Files         685      685           
  Lines       16408    16408           
=======================================
  Hits        14530    14530           
  Misses       1878     1878           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@tvdeyen tvdeyen left a comment

Choose a reason for hiding this comment

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

I think the solution is good. For me the variants do not need to be sorted by sku, but who am I to judge. A least the screen is usable again after we broke it in 4.2 🙈

@tvdeyen tvdeyen added backport-v4.2 Backport this pull-request to v4.2 backport-v4.3 Backport this pull-request to v4.3 labels Feb 13, 2024
nvandoorn and others added 2 commits February 13, 2024 09:55
Before we fix this bug, we should reproduce it in a feature spec.

Co-authored-by: An Stewart <andrew@super.gd>
Co-authored-by: Adam Mueller <adam@super.gd>
This "fixes" the variant scope issue but I'm not sure it's the solution
we want. I suppose it depends if ordering by sku is important here.

Co-authored-by: An Stewart <andrew@super.gd>
@nvandoorn nvandoorn force-pushed the 5506-fix-search-by-variant-on-stock-items branch from f8ed5b0 to c4bd75a Compare February 13, 2024 17:56
@nvandoorn nvandoorn marked this pull request as ready for review February 13, 2024 17:57
@kennyadsl
Copy link
Member

Thanks, @nvandoorn!

@kennyadsl kennyadsl merged commit 9d9c031 into solidusio:main Feb 14, 2024
14 checks passed
Copy link

💚 All backports created successfully

Status Branch Result
v4.2
v4.3

Questions ?

Please refer to the Backport tool documentation and see the Github Action logs for details

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport-v4.2 Backport this pull-request to v4.2 backport-v4.3 Backport this pull-request to v4.3 changelog:solidus_backend Changes to the solidus_backend gem
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants