You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
The child node "product_family_provider" at path "leaphly_cart" must be configured. #7
Hi Francesco,
yes we have to improve doc :)
the objective of family_provider is to provide the family of a product, so given a request it could identify the kind of the product, and then retrieve the correct handler.
What it does:
Image you are using doctrine with inheritance, so given a product id you could have different classes so
it looks for the product id, than it does a query, and return the class name, this class name will be used as context for the strategy and get the proper handler.
eg:
request: { product_id: 20}
the ClassNameProductFamilyProvider->getProductFamily(request)
$context = ClassName(query->get(request->product_id))
hi i know this is kind of old but I'm stuck on product_family_provider to!! and do I relay need it because i have categories for products i don't need types!! I moved from sylius cart because it lacks of documentation in hope i will find simpler cart system can u please provide me good documentation so I can enable Leaphly Cart Bundle
Matthers of the mind people treat me like I'm def dumb and blind this life is hard to devine .. rolling with github because we ahead of our time ..catch us on the grind ... Never shameful always Shine... Focusing on our state of mind
Activity
liuggio commentedon Nov 9, 2013
Hi Francesco,
yes we have to improve doc :)
the objective of family_provider is to provide the family of a product, so given a request it could identify the kind of the product, and then retrieve the correct handler.
For example in the sandbox is used here: https://github.com/leaphly/leaphly-sandbox/blob/master/src/Acme/CartBundle/Resources/config/mongodb.xml#L19
The family provider must extend this interface https://github.com/leaphly/CartBundle/blob/master/Provider/ProductFamilyProviderInterface.php
and a simple one is here: https://github.com/leaphly/CartBundle/blob/master/Provider/ClassNameProductFamilyProvider.php
What it does:
Image you are using doctrine with inheritance, so given a product id you could have different classes so
it looks for the product id, than it does a query, and return the class name, this class name will be used as context for the strategy and get the proper handler.
eg:
request: { product_id: 20}
the ClassNameProductFamilyProvider->getProductFamily(request)
$context = ClassName(query->get(request->product_id))
Is it make sense to you?
atheleron commentedon Mar 25, 2014
hi i know this is kind of old but I'm stuck on product_family_provider to!! and do I relay need it because i have categories for products i don't need types!! I moved from sylius cart because it lacks of documentation in hope i will find simpler cart system can u please provide me good documentation so I can enable Leaphly Cart Bundle
liuggio commentedon Mar 25, 2014
@atheleron I'm really sorry for this trouble this bundle is under heavy dev.
and is not stable version.
benjivds commentedon Jul 14, 2014
Hi how can i remove the product_family_provider or remove the error? I need to know i think it's blocking a lot of ppl
Greetings
liuggio commentedon Jul 14, 2014
Hi,
have created a service like: https://github.com/leaphly/leaphly-sandbox/blob/master/src/Acme/CartBundle/Resources/config/mongodb.xml#L19
The family provider must extend this interface https://github.com/leaphly/CartBundle/blob/master/Provider/ProductFamilyProviderInterface.php
and a simple one is here: https://github.com/leaphly/CartBundle/blob/master/Provider/ClassNameProductFamilyProvider.php
and then configured here:
https://github.com/leaphly/leaphly-sandbox/blob/master/app/config/leaphly/dbdriver.mongodb.yml#L14
benjivds commentedon Jul 14, 2014
Thank you @liuggio working now
piux commentedon Sep 6, 2014
hi @liuggio the links are 404, i have this error.
piux commentedon Sep 7, 2014
i found the classprovider, but how can i extend them? where do i get documentation
liuggio commentedon Sep 7, 2014
Note:
thanks for using this bundle the don't use it in production is not stable
and slowly mantained.
On Sun, Sep 7, 2014 at 2:43 AM, piux notifications@github.com wrote:
liuggio_______________
/|_ We reject kings, presidents and voting.
/o ) / We believe in rough consensus
) v _/\ and running code (I.E.T.F. credo)
Youngrafael95 commentedon Jan 6, 2023
Matthers of the mind people treat me like I'm def dumb and blind this life is hard to devine .. rolling with github because we ahead of our time ..catch us on the grind ... Never shameful always Shine... Focusing on our state of mind