From d885ab4292145c0534d2cfae161070e6c772ac04 Mon Sep 17 00:00:00 2001 From: Jan Haase <105806818+cheminfolab@users.noreply.github.com> Date: Sat, 6 Apr 2024 11:44:44 +0200 Subject: [PATCH] minor modifications --- backend/api/urls.py | 2 +- backend/chemicals/models.py | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/backend/api/urls.py b/backend/api/urls.py index a4d6c6c..2832270 100644 --- a/backend/api/urls.py +++ b/backend/api/urls.py @@ -16,7 +16,7 @@ router.register(r'building', BuildingViewSet, basename='buildings') router.register(r'unit', UnitViewSet, basename='units') router.register(r'substance', SubstanceViewSet, basename='substances') -router.register(r'component', ComponentViewSet, basename='containers') +router.register(r'component', ComponentViewSet, basename='components') router.register(r'compound', CompoundViewSet, basename='compounds') router.register(r'container', ContainerViewSet, basename='containers') diff --git a/backend/chemicals/models.py b/backend/chemicals/models.py index 1681436..2ec4ec0 100644 --- a/backend/chemicals/models.py +++ b/backend/chemicals/models.py @@ -47,6 +47,9 @@ class Meta: def __str__(self): return self.name + class Meta: + verbose_name_plural = 'Categories' + # compound class: # # Organika @@ -160,7 +163,7 @@ class Substance(models.Model): pubchem_cid = models.IntegerField(blank=True, null=True) # STRUCTURE - structure = models.ManyToManyField(Structure, blank=True, null=True, related_name='substance_structures') + structure = models.ManyToManyField(Structure, blank=True, related_name='substance_structures') # STEREOCHEMISTRY?? enantiomers, distereomers, racemic mixtures? # PROPERTIES