I would like to add a model to my plugin but in doing so, Inventree complains.
I tried using the normal app structure but without any success. Is there any way to add some more elaborated sample than the sample.py or extend the docs?
class TestPlugin(InvenTreePlugin, AppMixin):
AUTHOR = "Author"
DESCRIPTION = "Test app"
VERSION = PLUGIN_VERSION
NAME = "Test Plugin"class TestPlugin(InvenTreePlugin, AppMixin):
AUTHOR = "Author"
DESCRIPTION = "Test app"
VERSION = PLUGIN_VERSION
NAME = "Test Plugin"
SLUG = "testapp"
TITLE = "Test Plugin"
PUBLISH_DATE = datetime.date(2023, 6, 9)
WEBSITE = "https://www.test.com"
MIN_VERSION = '0.11.0'
Model:
class EnabledCategory(models.Model):
category = models.ForeignKey(PartCategory, related_name='get_all', on_delete=models.CASCADE)
Error Message:
Model class testapp.testapp.EnabledCategory doesn't declare an explicit app_label and isn't in an application in INSTALLED_APPS.
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too