wagtail-longclaw/docs/usage/products.rst

21 wiersze
836 B
ReStructuredText
Czysty Zwykły widok Historia

2017-03-24 08:50:25 +00:00
.. _products:
2017-02-12 21:36:31 +00:00
Adding Products
===============
2017-02-22 16:15:21 +00:00
Your new longclaw project has ``products`` app installed with a ``ProductVariant`` model.
You should add your own custom fields to ``ProductVariant`` to meet the demands of your catalogue.
2017-02-12 21:36:31 +00:00
2017-02-22 16:15:21 +00:00
A ``ProductVariant`` is a child of the longclaw ``Product`` model and is used to represent variants of a single product.
E.g different sizes, colours etc.
2017-02-12 21:36:31 +00:00
Writing the templates
-----------------------
Since ``ProductIndex`` and ``Product`` are Wagtail pages, HTML templates should be created for each.
2017-03-06 07:37:14 +00:00
The developer should refer to the `Wagtail documentation <http://docs.wagtail.io/en/v1.8.1/topics/writing_templates.html>`_ for further details.
2017-03-24 10:07:16 +00:00
Basic example templates are provided in ``your_project/templates/longclawproducts/`` when creating a project
2017-02-22 16:15:21 +00:00
with the longclaw project template.
2017-02-12 21:36:31 +00:00