Johannes Wachter
Johannes Wachter
Core Developer – Sulu GmbH
Sulu Core Developer and Open-Source Enthusiast.

Sylius Workshop

After 3 very intense days it's time to recap what we have learend in these 72 hours. 

We were really eager to find out more about building a bridge between Sylius and Sulu. So, together with our colleagues from MASSIVE ART we kicked of the meeting with Paweł Jędrzejewski and started to dive into the Symfony eCommerce platform.

The big picture

The architecture of the components, bundles and the application (admin, API and website) gave us a first impression of the possibilities provided by the system. With good examples and funny anecdotes from his daily work Paweł was able to pack the flood of information into small pieces. Time was running fast and a first small test project with Sylius was implemented very quickly (see in my public repository wachterjohannes/sylius-training).

This small project lets us add a new entity called "WarrantyPlan" with an admin UI to manage different warranty plans. In the end we also extended the "Customer" entity with a reference to a single warranty plan - also manageable in the Admin-UI.

The first day gave a good overview of the vision and current state of the project - and a very interesting insight to a young and dynamic startup in a similar environment like us.

Plugin development

The second day was very interesting for the Sulu team. We wanted to see how other open source projects in the Symfony world treat the topic "plugin" or "extensions". And we felt very comfortable when we hear that this Sylius-Plugins are only Symfony-Bundles with a different name.

Just like Sulu, Sylius relies fully on the Symfony framework and uses the container extensively (like tagged-services or decorated services) - in many places we hade to chuckle how similar the systems are. Plugins can stick into lots of hooks, forms, templates and even entities. Only one place is quite different to Sulu - the extensive use of forms.

We also used the second day to implement another test example - a plugin to handle gift wrapping for an order (see my public repository wachterjohannes/sylius-gift-wrapping-extension).

Sulu and Sylius

On the third day we talked about possible integrations and cooperation of Sulu and Sylius. There were some really interesting discussions how projects could be implemented using both technologies. In the end there was a working prototype which uses rabbitmq to create an article for each product in Sulu. Into the "shop" (Sulu's Website) we have added a cart page and actions to add articles (or products) into the cart. To follow the checkout process we internally linked to the Sylius checkout page and the customer can do the checkout there.

In our opinion, this would be a really good starting point for a real-world project.

I would like to thank Paweł for the really great workshop and the hacking day on Wednesday. We are looking forward to a successful cooperation!