Sylius/Sylius — pull request #2271 by aramalipoor (2014-12-20 19:21:37+00:00)
Title: [PoC] Add traditional calendar support and some useful twig filters

Q | A
------------- | -------------
Bug fix? | no
New feature? | yes
BC breaks? | no
Deprecations? | no
License | MIT
Doc PR | -

This is just a proposal to add support for traditional calendar systems into Sylius. I'm so new to Symfony2 so please forgive me if you see some bad practices ;)

I've also added some useful twig filters such as `sylius_rtl` which chekcs if current locale is RTL so that we can load RTL stylesheets and whatnot.

Your comments are really appreciated ;)

Here is a list of twig filters/functions I've proposed:
* `sylius_language([code])` Returns localized language name of current (or given) locale code.
* `sylius_rtl([code])` Returns true if current (or given) locale code is of an RTL-type language.
* `date` Override's Twig default date filter with calendar-aware conversion. (Based on current locale)

Further steps are:
* Add calendar-aware `date`, `time` and `datetime` form types.
* etc.