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

ProductVariant updates not persisted when custom field relation defined #997

Closed
michaelbromley opened this issue Jul 20, 2021 · 0 comments
Closed
Assignees
Labels
type: bug 🐛 Something isn't working @vendure/core

Comments

@michaelbromley
Copy link
Member

Describe the bug
When a "relation" custom field is defined on ProductVariant, updating with the updateProductVariants mutation will return the old values of direct properties (e.g. stockOnHand, sku). Fields which rely on a related entity (name, price) are correctly updated.

To Reproduce
Steps to reproduce the behavior:

  1. Define a relation custom field on ProductVariant
  2. In the AdminUI, edit a variant, e.g. increase the stock.
  3. Save, and then refresh the page
  4. See that the stock has reverted to the original value.

Expected behavior
Updates should work

Environment (please complete the following information):

  • @vendure/core version: v1.1.1+
  • Nodejs version: any
  • Database (mysql/postgres etc): any

Additional context
I think it is related to this commit from v1.1.1: 510025a

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug 🐛 Something isn't working @vendure/core
Projects
None yet
Development

No branches or pull requests

1 participant