Closed Timusan closed 1 year ago
Hey @Timusan,
Salesman is purposely not managing products and only provides the interface for them. You should structure your catalog/products however you see fit and then add them to the admin if you wish. In wagtail, it can be a page, or it can be a simple Django model. The only requirement is that it implements salesman.core.typing.Product
protocol.
You can find the basic example here: https://django-salesman.readthedocs.io/en/latest/adding_products.html
For the admin part, the only thing Salesman is adding into admin is the Order, as that is the only thing that needs management by default. It can be disabled by setting SALESMAN_ADMIN_REGISTER=False
which can be useful in a case where you wish to register your own instead, but still keep the admin
module from salesman.
It could maybe be more clear to change the setting name to SALESMAN_ADMIN_REGISTER_ORDER
.
Thank you for the elaborate reply, it's clear now. 👍
And yes, I think renaming the setting to SALESMAN_ADMIN_REGISTER_ORDER
might explain its purpose better.
It is not very clear how to get an overview of Salesman's components, how to manage products, ... within Wagtail.
The
SALESMAN_ADMIN_REGISTER
setting seems to imply that it is set toTrue
by default and gives us all kinds of Admin views, however onlyOrders
is added to the Wagtail admin menu.Is the idea that we should build our own Admin views using ModelAdmin? Or are there default views for all components (Products, Baskets, ...) shipped and need they be enabled somehow?