Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Sylius - E-Commerce for Symfony2

Sylius - E-Commerce for Symfony2

Sylius presentation at the biggest Symfony community event - SymfonyCon 2014 in Madrid, Spain.

7ae8ff67c92e2087f2e84884449d6da6?s=128

Pawel Jedrzejewski

November 28, 2014
Tweet

Transcript

  1. Sylius - E-Commerce for Symfony2 SymfonyCon, 28th November 2014 in

    Madrid, Spain
  2. Paweł Jędrzejewski Huge beliver in Open Source Creator of Sylius

    Co-Founder at !
  3. ? What is Sylius?

  4. Sylius E-Commerce Platform for PHP

  5. 160+ Code contributors 550,000+ Downloads 250+ Translators running in production

    thousands of man-hours Combined experience
  6. ? Why new e-commerce?

  7. None
  8. OLD „PHP” way MONOLITHIC NOT Developer-friendly Untesteble hacky

  9. None
  10. !!! Reinventing the wheel is bad…

  11. None
  12. None
  13. ? How does it look?

  14. PROTOTYPE ALERT!

  15. None
  16. RESPONSIVE BY DEFAULT!

  17. ? What can you build using Sylius?

  18. None
  19. None
  20. None
  21. None
  22. None
  23. None
  24. You need to innovate, in order to compete.

  25. Innovation requires flexibility.

  26. ? What makes Sylius different?

  27. sylius STACK Sylius components Sylius bundles Sylius platform

  28. Sylius components Sylius bundles Sylius platform sylius STACK

  29. components and bundles

  30. sylius e-Commerce toolset Product Cart Order Shipping Taxation Payment Inventory

    Currency Pricing Promotion Money Addressing
  31. sylius Generic toolset Flow Settings Taxonomy Resource Sequence Variation Attribute

    Locale
  32. Sylius platform Core Web Interface Symfony Doctrine CMF Payum

  33. None
  34. None
  35. Payum

  36. Payum Paypal Express Checkout Paypal Pro Checkout Paypal Rest Stripe.js

    Stripe Checkout Authorize.Net AIM Be2Bill CreditCard Be2Bill Onsite Payex
  37. Payum Paypal Express Checkout Paypal Pro Checkout Paypal Rest Stripe.js

    Stripe Checkout Authorize.Net AIM Be2Bill CreditCard Be2Bill Onsite Payex Offline Klarna Checkout DineroMail BitPay Paydollar PaylinkJustpay TcomPayWay Sagepay Redsys
  38. Payum Paypal Express Checkout Paypal Pro Checkout Paypal Rest Stripe.js

    Stripe Checkout Authorize.Net AIM Be2Bill CreditCard Be2Bill Onsite Payex Offline Klarna Checkout DineroMail BitPay Paydollar PaylinkJustpay TcomPayWay Sagepay Redsys 2Checkout Authorize.Net Buckaroo CardSave Dummy eWAY First Data GoCardless Manual
  39. Paypal Express Checkout Paypal Pro Checkout Paypal Rest Stripe.js Stripe

    Checkout Authorize.Net AIM Be2Bill CreditCard Be2Bill Onsite Payex Offline Klarna Checkout DineroMail BitPay Paydollar PaylinkJustpay TcomPayWay Sagepay Redsys 2Checkout Authorize.Net Buckaroo CardSave Dummy eWAY First Data GoCardless Manual Migs Mollie MultiSafepay Netaxept (BBS) Netbanx Pacnet PayFast Payflow PaymentExpress (DPS)
  40. CLEAN CODE • Decoupled architecture • DRY, SOLID, KISS •

    Testable code • DependencyInjection and many other design patterns
  41. Modern Foundation • Symfony full-stack combined with tons of excellent

    libraries from the community • Shares the platform with great projects like OroCRM, Akeneo PIM, Drupal, eZ Publish • Built on the shoulders of the open source giants
  42. None
  43. Behavior DRIVEN DEVELOPMENT • StoryBDD with Behat maintains high level

    of communication quality among the community • We communicate using examples • Behat scenarios are executed as acceptance tests automatically on every change • SpecBDD using phpspec punishes us for any bad design decision • CodeQuality
  44. Feature descriptions

  45. Executed on travis-ci.org

  46. Code quality

  47. Compared to „old” solutions

  48. !!! Show me the code!

  49. <?php ! namespace App\Bundle\CoreBundle\Entity; ! use Doctrine\ORM\Mapping as ORM; use

    Sylius\Component\Core\Model\Product as BaseProduct; ! /** * @ORM\Entity */ class Product extends BaseProduct { /** * @ORM\Column(type="decimal") */ private $fee; ! // Getters/setters. }
  50. $ app/console do:sc:up —force # app/config.yml ! sylius_product: classes: product:

    model: App\Bundle\CoreBundle\Entity\Product +
  51. <?php ! namespace App\Bundle\CoreBundle\Form\Type; ! use Sylius\Bundle\CoreBundle\Form\Type\ProductType as BaseProductType; use

    Symfony\Component\Form\FormBuilderInterface; ! class ProductType extends BaseProductType { public function buildForm(FormBuilderInterface $builder, array $options) { parent::buildForm($builder, $options); ! $builder ->add('fee', 'percentage') ->remove('price') ; } }
  52. ENJOY! # app/config.yml ! sylius_product: classes: product: model: App\Bundle\CoreBundle\Entity\Product form:

    App\Bundle\CoreBundle\Form\Type\ProductType +
  53. ENJOY IT EVEN MORE! # app/config.yml ! sylius_product: classes: product:

    model: App\Bundle\CoreBundle\Entity\Product controller: Your\Class repository: Your\Class form: App\Bundle\CoreBundle\Form\Type\ProductType +
  54. ? How to get started?

  55. Install SyliuS $ composer create-project sylius/sylius -s dev $ cd

    sylius $ app/console sylius:install $ composer create-project sylius/sylius-standard or
  56. What NEXT? We went crazy! • Deeper SymfonyCMF integration DONE

    • Flexible Multi-Channel DONE • Multi-Werehouse DONE • Full, RESTful JSON and XML API DONE • ORM or ElasticSearch search engine MERGED • CLONE RYAN WEAVER FOR DOCS SAKE!!!
  57. DOCS.sylius.org

  58. sylius.org

  59. github.com/sylius/sylius

  60. @pjedrzejewski @Sylius @Lakion pjedrzejewski.com sylius.org lakion.com THANK YOU! joind.in/12943

  61. Image Credits https://www.flickr.com/photos/ilikespoons/8395923694/ https://www.flickr.com/photos/kalexanderson/5421517469 https://www.flickr.com/photos/woolamaloo_gazette/12822529314 https://www.flickr.com/photos/dey/44559604 https://www.flickr.com/photos/suckamc/8474229421 https://www.flickr.com/photos/kwl/4247555680