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

Improve "Depends on" option #4347

Open
MinaDoncheva opened this issue Oct 8, 2024 · 0 comments
Open

Improve "Depends on" option #4347

MinaDoncheva opened this issue Oct 8, 2024 · 0 comments

Comments

@MinaDoncheva
Copy link
Contributor

MinaDoncheva commented Oct 8, 2024

Is your feature request related to a problem? Please describe.
"Depends on" is needed in every type of widget (dropdown, textbox, etc.), and the way it works now assumes that the property in the dependent entity and the one in the entity it depends on are called the same. For example, when we filter cities by country, both of the properties are called "Country"; however, when we want to take the BaseUnit of a Product to work as its UoM, the names are different.

Describe the solution you'd like

  • "Depends on" to be checkbox added to the widget type and to contain the property which value we take, the entity which will be filtered by the taken value and the property from that entity that we need.
  • Another checkbox would be useful to make that field editable.

Additional context
For example, we want the UoM property to take the value of the BaseUnit for the chosen Product. In this case, the "Depends on" option for UoM will take the Product value (Id), link it to the Product entity, and take the BaseUnit property of the Product entity.

Another case would be getting the Price value from the Product entity and using it in OrderItems. However, here we would make that field editable.

Acceptance Criteria

Country-City use-case:

At entity: Customer
At property: City

    widgetDependsOnProperty=Country
    widgetDependsOnEntity=Country
    widgetDependsOnValueFrom=Id
    widgetDependsOnFilterBy=Country

Product-UoM use-case:

At entity: SalesOrderItem
At property: UoM

    widgetDependsOnProperty=Product
    widgetDependsOnEntity=Product
    widgetDependsOnValueFrom=BaseUnit
    widgetDependsOnFilterBy=Id
@MinaDoncheva MinaDoncheva changed the title Option for dependent properties to be editable Improve "Depends on" option Oct 15, 2024
delchev added a commit that referenced this issue Oct 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant