diff --git a/web-app/django/VIM/apps/instruments/migrations/0012_alter_instrumentname_source_name.py b/web-app/django/VIM/apps/instruments/migrations/0012_alter_instrumentname_source_name.py new file mode 100644 index 00000000..5c5e3f31 --- /dev/null +++ b/web-app/django/VIM/apps/instruments/migrations/0012_alter_instrumentname_source_name.py @@ -0,0 +1,19 @@ +# Generated by Django 4.2.5 on 2025-12-17 16:12 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + dependencies = [ + ("instruments", "0011_language_html_direction"), + ] + + operations = [ + migrations.AlterField( + model_name="instrumentname", + name="source_name", + field=models.CharField( + help_text="Who or what called the instrument this?", max_length=255 + ), + ), + ] diff --git a/web-app/django/VIM/apps/instruments/models/instrument_name.py b/web-app/django/VIM/apps/instruments/models/instrument_name.py index b31af750..cef40451 100644 --- a/web-app/django/VIM/apps/instruments/models/instrument_name.py +++ b/web-app/django/VIM/apps/instruments/models/instrument_name.py @@ -6,7 +6,7 @@ class InstrumentName(models.Model): language = models.ForeignKey("Language", on_delete=models.PROTECT) name = models.CharField(max_length=100, blank=False) source_name = models.CharField( - max_length=50, blank=False, help_text="Who or what called the instrument this?" + max_length=255, blank=False, help_text="Who or what called the instrument this?" ) # Stand-in for source data; format TBD verification_status = models.CharField( max_length=50, diff --git a/web-app/django/VIM/apps/instruments/views/update_umil_db.py b/web-app/django/VIM/apps/instruments/views/update_umil_db.py index 74a52731..5d717397 100644 --- a/web-app/django/VIM/apps/instruments/views/update_umil_db.py +++ b/web-app/django/VIM/apps/instruments/views/update_umil_db.py @@ -45,6 +45,7 @@ def add_name(request: HttpRequest) -> JsonResponse: }, status=400, ) + # Fetch the instrument from the database, if it does not exist return does not exist error instrument = get_object_or_404(Instrument, wikidata_id=wikidata_id) diff --git a/web-app/django/VIM/templates/instruments/detail.html b/web-app/django/VIM/templates/instruments/detail.html index a605595a..ff11c666 100644 --- a/web-app/django/VIM/templates/instruments/detail.html +++ b/web-app/django/VIM/templates/instruments/detail.html @@ -115,7 +115,7 @@