Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

v0.5.rst 8.2KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234
  1. =======================
  2. Oscar 0.5 release notes
  3. =======================
  4. Welcome to Oscar 0.5!
  5. These release notes cover the `new features`_ as well as `upgrading advice`_.
  6. .. _`new features`: `What's new in Oscar 0.5?`_
  7. .. _`upgrading advice`: `Upgrading`_
  8. Overview
  9. ========
  10. The main aim of this release was to add functionality to offers but scope
  11. expanded over time to include many fixes and improvements. Whilst there aren't
  12. that many new features from a customer perspective, a great deal of work has
  13. gone into reworking Oscar's structure to be more extensible.
  14. Thanks to all the contributors who helped with this release.
  15. What's new in Oscar 0.5?
  16. ========================
  17. Offers++
  18. ~~~~~~~~
  19. Most of the new features in 0.5 are around offers.
  20. * It is now possible to create custom ranges, conditions and benefits that can
  21. be used to create flexible offers. These ranges are created as Python classes
  22. conforming to a set interface which are registered at compile time to make
  23. them available in the dashboard.
  24. * Offer benefits can now apply to the shipping charge for an order. Previously,
  25. all benefits were applied against the basket lines. There are three shipping
  26. benefits ready to use:
  27. - Fixed discount off shipping (eg get £5 off your shipping costs)
  28. - Percentage discount off shipping (eg get 25% off your shipping costs)
  29. - Fixed price shipping (eg your shipping charge will be £5)
  30. * Offer benefits can now be deferred. That is, they don't affect either the
  31. basket lines nor the shipping charge. This is useful for creating benefits
  32. such as awarding loyalty points.
  33. * Several new ways of restricting an offer's availability have been introduced:
  34. - An offer's lifetime can now be controlled to the second rather to the day
  35. (ie the relevant model fields are datetimes rather than dates). This makes
  36. it possibly to run offers for a small amount of time (eg for a single
  37. lunchtime).
  38. - An offer can be restricted to a max number of applications per
  39. *basket/order*. For example, an offer can configured so that it can
  40. only be used once in a single order.
  41. - An offer can be restricted to a max number of applications per *user*.
  42. - An offer can be restricted to a max number of *global* applications.
  43. - An offer can be restricted to give a maximum total discount. After this
  44. amount of discount has been awarded, the offer becomes unavailable.
  45. .. figure:: screenshots/0.5/offer-restrictions.png
  46. :scale: 50%
  47. The restrictions editing page for an offer within the dashboard.
  48. * Offers can now be suspended and reinstated.
  49. * The offers dashboard has been rewritten.
  50. * There is now an offers homepage that lists all active offers.
  51. New dashboard skin
  52. ~~~~~~~~~~~~~~~~~~
  53. The design of the dashboard has been reworked, offering a better user experience
  54. throughout the dashboard. This work is still ongoing, further improvements in
  55. how the dashboard pages are laid out will appear in 0.6.
  56. .. figure:: screenshots/0.5/dashboard-nav.png
  57. The new dashboard navigation.
  58. Internationalisation
  59. ~~~~~~~~~~~~~~~~~~~~
  60. Oscar now uses Transifex_ to manage its translation files. Since 0.4, a
  61. considerable number of new languages are now supported (although many have
  62. partial coverage).
  63. .. _Transifex: https://www.transifex.com/projects/p/django-oscar/
  64. .. figure:: screenshots/0.5/transifex.png
  65. :scale: 80%
  66. A snippet from the Oscar Transifex page.
  67. Oscar's default templates also now support a simple language picker.
  68. New settings have been introduced to control how slugs are generated. By
  69. default, the unidecode package is used to gracefully handle non-ASCII chars in
  70. slugs.
  71. Minor features
  72. ~~~~~~~~~~~~~~
  73. There are several noteworthy smaller improvements
  74. * The basket page now updates using AJAX rather than page reloads.
  75. * Oscar's documentation has been reorganised and improved. This is part of an
  76. ongoing effort to improve it. Watch this space.
  77. * Oscar's template now use django-compressor_ to compress CSS and JS assets.
  78. * Products can now be deleted using the catalogue dashboard.
  79. * Warnings emails are sent to customers when their password or email address is
  80. changed.
  81. * Flash messages can now contain HTML.
  82. .. _django-compressor: http://django_compressor.readthedocs.org/en/latest/
  83. Minor improvements
  84. ~~~~~~~~~~~~~~~~~~
  85. Several improvements have been made to ease development of Oscar (and Oscar
  86. projects):
  87. * The sandbox can be configured to compile the LESS files directly. This is
  88. useful for developing Oscar's CSS/LESS files.
  89. * A new management command ``oscar_fork_statics`` has been added to help with
  90. setting up static files for a new Oscar project.
  91. * Alternative templates can now be used for different product classes in product
  92. browsing views.
  93. * jQuery upgraded to 1.9.1
  94. * Bootstrap upgraded to 2.3.1
  95. * The test runner can now be run with tox_.
  96. * Oscar ships with profiling tools. There is a decorator and middleware
  97. available in ``oscar.profiling`` that can be used to help profile Oscar sites.
  98. * Customers are notified if changes to their basket lead to new offers being
  99. applied (or if previously applied offers are no longer available).
  100. .. figure:: screenshots/0.5/html_flash_msg.png
  101. A flash message indicating that the customer's basket has now qualified for
  102. a new offer.
  103. * Some testing utilities have been extracted into a new package,
  104. django-oscar-testsupport_, so they can be used by Oscar extensions.
  105. * A Vagrant_ manifest is provided for testing Oscar against different database
  106. vendors.
  107. * Oscar's javascript has been rewritten to be cleaner and more extensible.
  108. * Coverage data is now submitted to coveralls.io_
  109. .. _coveralls.io: https://coveralls.io/r/tangentlabs/django-oscar
  110. .. _django-oscar-testsupport: https://github.com/tangentlabs/django-oscar-testsupport
  111. .. _tox: http://testrun.org/tox/latest/
  112. .. _Vagrant: http://www.vagrantup.com/
  113. Upgrading
  114. =========
  115. This section describes changes in core Oscar that you need to be aware of if you
  116. are upgrading from 0.4. See the :doc:`upgrading guidelines </topics/upgrading>`
  117. for further details on the steps you need to take.
  118. Migrations
  119. ~~~~~~~~~~
  120. There are new migrations in the following apps to be aware of.
  121. * Address:
  122. - ``0002``: Make ``postcode`` nullable on the ``Address`` model
  123. * Catalogue:
  124. - ``0009``: Add a ``rating`` field to the product model
  125. - ``0010``: Populate the new ``rating`` field
  126. .. note::
  127. Note, if you are using a customised version of the catalogue app, then you
  128. should create a similar data migration to ``0010`` in your own project.
  129. * Offer:
  130. - ``0007``: Add ``max_global_appliations`` field to ``ConditionalOffer`` model
  131. - ``0008``: Add ``num_applications`` field to ``ConditionalOffer`` model
  132. - ``0009``: Rename ``max_applications`` field to ``max_basket_applications``
  133. - ``0010``: Add ``max_user_applications`` field to ``ConditionalOffer`` model
  134. - ``0011``: Add ``proxy_class`` field to ``Range`` model
  135. - ``0012``: Add ``proxy_class`` field to ``Condition`` model and make
  136. ``range``, ``type`` and ``value`` nullable.
  137. - ``0013``: Add unique index on ``proxy_class`` for the ``Range`` model
  138. - ``0014``: Empty migration after branch merge
  139. - ``0015``: Add ``max_discount`` field to ``ConditionalOffer`` model
  140. - ``0016``: Add ``status`` field to ``ConditionalOffer`` model
  141. - ``0017``: Change ``start_date`` and ``end_date`` to datetimes.
  142. - ``0018``: Rename ``start_date`` and ``end_date`` to ``start_datetime`` and
  143. ``end_datetime`` respectively.
  144. - ``0019``: Add ``proxy_class`` field to ``Benefit`` model and make
  145. ``range``, ``type`` and ``value`` nullable.
  146. * Order:
  147. - ``0007``: Add ``frequency`` field to ``OrderDiscount`` model
  148. - ``0008``: Add ``category`` field to ``OrderDiscount`` model
  149. - ``0009``: Add ``message`` field to ``OrderDiscount`` model
  150. * Partner:
  151. - ``0004``: Add ``code`` field to ``Partner`` model
  152. - ``0005``: Populate the new ``code`` field
  153. - ``0006``: Add unique index on ``code`` field
  154. - ``0007``: Remove unique index from ``name`` field and make nullable
  155. .. note::
  156. Note, if you are using a customised version of the partner app, then you
  157. should create a similar data migration to ``0005`` in your own project.