mirror of
https://github.com/Findus23/acronomy.git
synced 2024-09-19 15:33:45 +02:00
add stub flag
This commit is contained in:
parent
708f87a270
commit
4424919133
2 changed files with 3 additions and 2 deletions
|
@ -48,7 +48,7 @@ class EditForm(ModelForm):
|
|||
|
||||
class Meta:
|
||||
model = Acronym
|
||||
fields = ['name', 'full_name', "description_md", "tags"]
|
||||
fields = ['name', 'full_name', "description_md", "stub", "tags"]
|
||||
|
||||
|
||||
class AddForm(ModelForm):
|
||||
|
@ -57,7 +57,7 @@ class AddForm(ModelForm):
|
|||
class Meta:
|
||||
model = Acronym
|
||||
|
||||
fields = ['name', 'full_name', "description_md", "tags"]
|
||||
fields = ['name', 'full_name', "description_md", "stub", "tags"]
|
||||
|
||||
|
||||
class WikipediaForm(ModelForm):
|
||||
|
|
|
@ -21,6 +21,7 @@ class Acronym(models.Model):
|
|||
description_html = models.TextField(editable=False)
|
||||
history = HistoricalRecords(excluded_fields=["created_date"])
|
||||
tags = models.ManyToManyField(Tag, related_name="acronyms")
|
||||
stub = models.BooleanField(default=True, help_text="check if this is a minimal entry that should be extended")
|
||||
created_date = models.DateTimeField(auto_now_add=True)
|
||||
modified_date = models.DateTimeField(auto_now=True)
|
||||
|
||||
|
|
Loading…
Reference in a new issue