Tuesday 21 March 2017 11:12:40 am - 4 replies
I want to create categories for my products and each category contains a set of products already I created, but the problem is that ezplatform does not have a catogory system that makes the following hierarchy:
Categories -> sub categories -----> products
Do you have any ideas to create this hierarchy ??
please i need your help. thank you in advance.
Tuesday 21 March 2017 9:09:37 pm
Would it be acceptable to categorize your products using the ez content tree?
Many ezpublish traditionally use the content tree for categorization.
Some use the folder content type other use a custom content type, say called, 'product_category'.
Other users might use the above and a custom content type item (what used to be called a content class attribute) which is made of a custom datatype created specifically for product categorization or other such meta data storage and organization, etc. In the past people have also re-used existing content type datatypes in a simple way or extended them for more complex needs. Such as you describe in part. As such you might learn more in this regard (datatypes) by searching for available ezplatform custom datatypes on projects.ez.no or https://github.com/ezpublishlegacy or https://github.com/ezecosystem
Another question would be are you building your ecommerce system in ezplatform from scratch or leveraging the available eZ Platform Stylus integration? Stylus might be the way to go for future thinking projects.
Please feel free to ask further questions
I hope this helps.
Thursday 23 March 2017 9:29:57 am
thank you // Heath for your answer,
firstly : i will build my e-commerce site at zero with the ez platform and i have no idea about eZ pltaform Stylus integration ?? what isd this stuff ??
Secondly : I am a beginner with ezplatform, I have difficulties to understand how I can create controllers to display a content folder if I do a categorization system with content tree using the files. Because ezplatform uses some library and I can not understand these libraries
Thursday 23 March 2017 5:06:16 pm
Your very welcome. I am happy to help.
I must apologize I mistyped Stylus when I ment Sylius.
Sylius is a eCommerce framework for PHP on top of Symfony.
Sylius is the new top of the line way for many to integrate ecommerce shop features with eZ!
eZ + Sylius:
I understand you are a beginner with eZ Platform yet you should not let that hold you back from taking full advantage of all the best available tools like Sylius.
Still, that said, the difficulties to display a content of a specific type (like folder) are quite separate from the storage model of said content. Just think of the eZ Content Tree as a FileSystem if you will.
Folders in modern filesystems are often part of a Hierarchy. Some Folders have child folders which contain child folders which contain child files, etc.
You could store your product content objects into Product Category Folders named by a subcategory identifier which suites your needs, like 'Crampons', 'Carabiners', 'Rope', 'Backpacks', 'Sunglasses', 'Footwear', etc with your products stored as child objects of the 'Product Category Folders'. It's really quite simple.
In many simple situations you don't even need to worry about creating custom controllers to simply display content from the content tree as this has been abstracted by eZ for you. It's dynamic (an idea which comes from ezpublish legacy).
You can study the ezplaform implementation of this feature because the code is open source and free for you to learn from as required. Remember eZ Platform is implemented on Symfony (Full Stack) which means eZ has taken it's own ideas and features and built them using and extending the Symfony we all know and love. No hidden magic per say
Now to address your needs (you will need this) regarding creating, using custom controllers and consuming custom content in unique ways you may find that the following blog series can help you jump start your learning. I have been recommending this wonderful early bird contribution by Joe Kepley @ Blend Interactive for quite some time. I found it's insights to be very helpful when I first started adopting eZ Platform.
Again as always please feel free to ask questions
I hope this helps!
You must be logged in to post messages in this topic!