Update wizard tutorial to use tryton.cfg to register model

Closes #15089
(grafted from b5a764a7c2a909bef03ea9f5e2ed2858d42d147f)

--HG--
branch : 8.0
This commit is contained in:
Lars Wuerfel
2026-09-28 18:07:34 +02:00
parent 60e6824f69
commit 3debac9c7b
+9 -7
View File
@@ -24,15 +24,17 @@ First we define a :class:`~trytond.model.ModelView` class in
end_date = fields.Date("End Date", required=True)
And we register it in the :class:`~trytond.pool.Pool` in :file:`__init__.py`:
And we register it in the :class:`~trytond.pool.Pool` in :file:`tryton.cfg`:
.. code-block:: python
.. code-block:: ini
[tryton]
...
[register]
...
model:
opportunity.ConvertStart
def register():
Pool.register(
...,
opportunity.ConvertStart,
module='opportunity', type_='model')
Then the form view record in :file:`opportunity.xml`: