From 737d697b9e813592740afb7b2f6be1251ff77bcb Mon Sep 17 00:00:00 2001 From: George Katsikas <giorgakis.katsikas@gmail.com> Date: Thu, 12 Sep 2024 16:06:38 +0200 Subject: [PATCH] add publication date & xml metadata to proceedings --- scipost_django/proceedings/forms.py | 2 ++ .../0012_proceedings_metadata_xml_and_more.py | 22 +++++++++++++++++++ scipost_django/proceedings/models.py | 5 +++++ 3 files changed, 29 insertions(+) create mode 100644 scipost_django/proceedings/migrations/0012_proceedings_metadata_xml_and_more.py diff --git a/scipost_django/proceedings/forms.py b/scipost_django/proceedings/forms.py index d73f34742..c464eb747 100644 --- a/scipost_django/proceedings/forms.py +++ b/scipost_django/proceedings/forms.py @@ -21,6 +21,7 @@ class ProceedingsForm(forms.ModelForm): "submissions_open", "submissions_deadline", "submissions_close", + "publication_date", "template_latex_tgz", "logo", "cover_image", @@ -33,6 +34,7 @@ class ProceedingsForm(forms.ModelForm): "submissions_open": forms.DateInput(attrs={"type": "date"}), "submissions_deadline": forms.DateInput(attrs={"type": "date"}), "submissions_close": forms.DateInput(attrs={"type": "date"}), + "publication_date": forms.DateInput(attrs={"type": "date"}), "event_start_date": forms.DateInput(attrs={"type": "date"}), "event_end_date": forms.DateInput(attrs={"type": "date"}), } diff --git a/scipost_django/proceedings/migrations/0012_proceedings_metadata_xml_and_more.py b/scipost_django/proceedings/migrations/0012_proceedings_metadata_xml_and_more.py new file mode 100644 index 000000000..1f2136c38 --- /dev/null +++ b/scipost_django/proceedings/migrations/0012_proceedings_metadata_xml_and_more.py @@ -0,0 +1,22 @@ +# Generated by Django 4.2.15 on 2024-09-12 14:05 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + dependencies = [ + ("proceedings", "0011_alter_proceedings_fellowships"), + ] + + operations = [ + migrations.AddField( + model_name="proceedings", + name="metadata_xml", + field=models.TextField(blank=True), + ), + migrations.AddField( + model_name="proceedings", + name="publication_date", + field=models.DateField(blank=True, null=True), + ), + ] diff --git a/scipost_django/proceedings/models.py b/scipost_django/proceedings/models.py index cafacbd39..9ccd6dccd 100644 --- a/scipost_django/proceedings/models.py +++ b/scipost_django/proceedings/models.py @@ -58,10 +58,15 @@ class Proceedings(TimeStampedModel): submissions_deadline = models.DateField() submissions_close = models.DateField() + publication_date = models.DateField(blank=True, null=True) + # Proceedings optinal preface preface_title = models.CharField(max_length=256, blank=True) preface_text = models.TextField(blank=True) + # Metadata + metadata_xml = models.TextField(blank=True) + # Templates template_latex_tgz = models.FileField( verbose_name="Template (LaTeX, gzipped tarball)", -- GitLab