This commit is contained in:
Ross
2021-02-05 10:47:27 +00:00
parent cddc3c09e2
commit b8cb09b5c5
19 changed files with 227 additions and 44 deletions
+13 -12
View File
@@ -21,7 +21,8 @@ import string
from anatomy.models import Modality
from generic.models import Examination, Site, Condition, Sign
from generic.models import Examination, Condition, Sign
#from generic.models import Examination, Site, Condition, Sign
image_storage = FileSystemStorage(
# Physical file location ROOT
@@ -62,12 +63,12 @@ class Long(models.Model):
DEFAULT_SITE_ID = 1
site = models.ManyToManyField(
Site,
blank=True,
default=DEFAULT_SITE_ID,
help_text=
"If we know the source of the image")
#site = models.ManyToManyField(
# Site,
# blank=True,
# default=DEFAULT_SITE_ID,
# help_text=
# "If we know the source of the image")
verified = models.BooleanField(default=False)
created_date = models.DateTimeField(default=timezone.now)
published_date = models.DateTimeField(blank=True, null=True)
@@ -181,11 +182,11 @@ class LongCreationDefault(models.Model):
related_name="long_default",
on_delete=models.CASCADE)
site = models.ManyToManyField(
Site,
blank=True,
default=1,
help_text="Default site to use when creating a new long")
#site = models.ManyToManyField(
# Site,
# blank=True,
# default=1,
# help_text="Default site to use when creating a new long")
def get_absolute_url(self):
return reverse('longs:long_create')