vendure-ecommerce / vendure

The commerce platform with customization in its DNA.
https://www.vendure.io
Other
5.65k stars 1k forks source link

Missing inheritFilters field for Collection for InitialData #2484

Closed rsat closed 10 months ago

rsat commented 11 months ago

Describe the bug

When importing data or populating there is no option to set inheritFilters to false. Probably this was kept from before the inheritFilters was introduced

https://github.com/vendure-ecommerce/vendure/blob/218561f04cbaf738c0f18302b67b1b077a056a7f/packages/core/src/data-import/types.ts#L23-L33

https://github.com/vendure-ecommerce/vendure/blob/218561f04cbaf738c0f18302b67b1b077a056a7f/packages/core/src/data-import/providers/populator/populator.ts#L137-L152

To Reproduce Steps to reproduce the behavior:

  1. Import data with collections
  2. All collections are set to InheritFilters to true by default when importing data.

Expected behavior

Imported Collections should keep setting inheritFilters to true by default but should be able to set as false if desired.

Environment (please complete the following information):

Additional context Could create the pull request with the fix for approval

michaelbromley commented 11 months ago

Hi Ricardo!

You're right - the format has not been updated when we added the inheritFilters toggle in v2. If you are willing to make a PR then that would be very welcome!

bhardwajakshit commented 10 months ago

@michaelbromley, Raised a PR for this: https://github.com/vendure-ecommerce/vendure/pull/2534

michaelbromley commented 10 months ago

@bhardwajakshit thanks for the fix!