django-eav2/eav/__init__.py

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

11 lines
263 B
Python
Raw Normal View History

2010-09-27 13:28:52 +00:00
def register(model_cls, config_cls=None):
from eav.registry import Registry # noqa: PLC0415
2021-10-16 17:43:02 +00:00
2010-09-27 13:28:52 +00:00
Registry.register(model_cls, config_cls)
2021-10-16 17:43:02 +00:00
2010-09-27 13:28:52 +00:00
def unregister(model_cls):
from eav.registry import Registry # noqa: PLC0415
2021-10-16 17:43:02 +00:00
2010-09-27 13:28:52 +00:00
Registry.unregister(model_cls)