- Issue created by @garethb_uk
- Merge request !14Issue #3462493: Error: Call to undefined method... → (Open) created by sayan_k_dutta
- 🇮🇳India sayan_k_dutta
sayan_k_dutta → changed the visibility of the branch 3478960-commerce-specific-products to hidden.
- 🇮🇳India sayan_k_dutta
sayan_k_dutta → changed the visibility of the branch 2.0.x to hidden.
- 🇮🇳India sayan_k_dutta
sayan_k_dutta → changed the visibility of the branch 2.0.x to active.
- 🇩🇪Germany jurgenhaas Gottmadingen
jurgenhaas → changed the visibility of the branch 2.0.x to hidden.
- 🇩🇪Germany jurgenhaas Gottmadingen
jurgenhaas → changed the visibility of the branch 2.1.x to hidden.
- 🇩🇪Germany jurgenhaas Gottmadingen
Here is what's happening: when commerce conditions use a
commerce_entity_select
or aentity_autocomplete
field type in a configuration form, ECA changes that to a text field which accepts a comma separated list of product IDs.The commerce product trait, however, contains a form submit handler that expects an array with each item containing the key
target_id
with the product IDs. From those IDs, they lookup the UUIDs of each product and store that as configuration.We can't have that configuration as such because ECA needs to store the comma separated ID list as this is required again next time the ECA model is being edited.
However, we need to adjust the plugin configuration right before execution/evaluation in the same way to provide the UUIDs instead of IDs.
This is certainly a bigger task and then also needs someone for testing. Not sure, if I can get to it soon.
- 🇺🇸United States nicxvan
@sayan using the issue queue for questions is better.
No problem opening am issue fork, if you don't add to it someone else will!
- Status changed to Needs work
2 months ago 6:21pm 21 January 2025 - 🇳🇴Norway zaporylie
The scope here is slightly bigger than what's described in the issue title and summary, as suggested in #9. In short, commerce condition plugins are not correctly handled due to form decoration at the eca deriver level. I am bumping the severity to Major as reusing commerce Condition Plugins is one of the biggest potential value of using ECA with Commerce.
Backstory: I am working on recipes and want to react to the add-to-cart event (that part works fine) but only if a certain condition is met - order type is X (doesn't work). The issue is that bundles are stored as an array, but the eca_commerce_commerce plugin expects them to be string