Open timeverts opened 4 years ago
Thank you for your description, I think you are right. I will look into this and try to fix it.
@jerome2710, do you still have plans/capability to implement custom purchasable support?
@timeverts I have looked briefly into this. Given the fact that for product bundles you would like to give the user the ability to pick a variant, it is not possible to migrate to purchasables. A product is not a purchasable, but the variants underneath it are. Therefore I got stuck finding the correct relations.
If you have a suggestion, I'm happy to look into this again.
Having had a brief look at your code, unless I'm mistaken, it doesn't appear as though custom purchasables can be included within product bundles.
Some examples of custom purchasables are:
All custom purchasables extend the same
craft\commerce\base\Purchasable
class. The default Commerce product (which is actually a Variant) extends this class too, so it's really a custom purchasable itself.If you want to see an example of supporting custom purchasables, take a look at the Promotions section in Commerce.