Skip to content

Property editors with store configured in configuration don't render #721

@BenWhite27

Description

@BenWhite27

Which component is this issue related to?

Umbraco Commerce (Core)

Which Umbraco Commerce version are you using? (Please write the exact version, example: 10.1.0)

15.3.5

Bug summary

It seems that when you configure a Data Type for Stock or Price (maybe others) with a specific store selected. The PropertyEditor doesn't read the configured store correctly and fails to display if it can't get the store from the content hierarchy.

Specifics

From source map, line 70 of stock\property-editor-ui-stock.element.ts

const storeId = this.config?.find(p => p.alias === 'storeId')?.value;

It seems that this.config is not set at this point and instead the configuration should be read from the provided config argument to the method.

Steps to reproduce

  1. Create a DataType for either Stock or Price and configure it with a specific store via the configuration.
  2. Add DataType as property to a DocumentType.
  3. Create a Document of that type in the content tree that does not have a Store within the hierarchy
  4. See that the property editor does not render.

Expected result / actual result

Property editor should render correctly using configured store for context.

Dependencies

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions