Skip to content

Commit

Permalink
Merge pull request #1575 from lucasmarchd01/issue-1371
Browse files Browse the repository at this point in the history
Change instances of "Differentia Database" to "Differentiae Database"
  • Loading branch information
lucasmarchd01 authored Jul 25, 2024
2 parents 8289abb + 77e26b9 commit 6995beb
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 8 deletions.
14 changes: 9 additions & 5 deletions django/cantusdb_project/main_app/admin/source.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,15 @@ class SourceAdmin(BaseModelAdmin):
"id",
"provenance_notes",
)
readonly_fields = ("title", "siglum") + READ_ONLY + (
"number_of_chants",
"number_of_melodies",
"date_created",
"date_updated",
readonly_fields = (
("title", "siglum")
+ READ_ONLY
+ (
"number_of_chants",
"number_of_melodies",
"date_created",
"date_updated",
)
)
# from the Django docs:
# Adding a ManyToManyField to this list will instead use a nifty unobtrusive JavaScript “filter” interface
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,11 @@ def handle(self, *args, **options):
# if the source we're publishing has a different institution name than the
# one that already exists, save the source name as an alternate name.
if institution_name and institution_name != institution.name:
existing_alt_names: list = institution.alternate_names.split("\n") if institution.alternate_names else []
existing_alt_names: list = (
institution.alternate_names.split("\n")
if institution.alternate_names
else []
)
existing_alt_names.append(institution_name.strip())
deduped_names = set(existing_alt_names)
institution.alternate_names = "\n".join(list(deduped_names))
Expand Down
2 changes: 1 addition & 1 deletion django/cantusdb_project/main_app/models/differentia.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ class Differentia(BaseModel):
blank=True, null=True, max_length=255
) # values like `1--k-k-l-j-k-h--4` get stored here
mode = models.CharField(blank=True, null=True, max_length=255)
# differentia database stores information on mode, but we don't expect to ever need to display it
# differentiae database stores information on mode, but we don't expect to ever need to display it
# saeculorum - DD stores a volpiano snippet about the "saeculorum" part of the differentia, but we don't expect to ever need to display it
# amen - DD stores a volpiano snippet about the "amen" part of the differentia, but we don't expect to ever need to display it

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ <h3>{{ chant.incipit }}</h3>

{% if chant.diff_db %}
<div class="col">
<dt>Differentia&nbsp;Database</dt>
<dt>Differentiae&nbsp;Database</dt>
<dd>
{% if chant.diff_db.melodic_transcription %}
<p style="font-family: volpiano; font-size:28px; margin-bottom: 0px;">{{ chant.diff_db.melodic_transcription }}</p>
Expand Down

0 comments on commit 6995beb

Please sign in to comment.