Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(dataset): limit funding org to 1024 characters #425

Merged
merged 1 commit into from
Feb 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Generated by Django 4.2.2 on 2024-02-09 20:37

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('archive_api', '0027_add_dataset_desc_limit'),
]

operations = [
migrations.AlterModelOptions(
name='historicaldataset',
options={'get_latest_by': ('history_date', 'history_id'), 'ordering': ('-history_date', '-history_id'), 'verbose_name': 'historical data set', 'verbose_name_plural': 'historical data sets'},
),
migrations.AlterField(
model_name='historicaldataset',
name='history_date',
field=models.DateTimeField(db_index=True),
),
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Generated by Django 4.2.2 on 2024-02-09 20:40

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('archive_api', '0028_alter_historicaldataset_options_and_more'),
]

operations = [
migrations.AlterField(
model_name='dataset',
name='funding_organizations',
field=models.TextField(blank=True, max_length=1024, null=True),
),
migrations.AlterField(
model_name='historicaldataset',
name='funding_organizations',
field=models.TextField(blank=True, max_length=1024, null=True),
),
]
2 changes: 1 addition & 1 deletion archive_api/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -357,7 +357,7 @@ def data_set_id(self):
qaqc_status = models.IntegerField(choices=QAQC_STATUS_CHOICES, blank=True, null=True)
qaqc_method_description = models.TextField(blank=True, null=True)
ngee_tropics_resources = models.BooleanField(blank=True, null=True)
funding_organizations = models.TextField(blank=True, null=True)
funding_organizations = models.TextField(blank=True, null=True, max_length=1024)
doe_funding_contract_numbers = models.CharField(max_length=100, blank=True, null=True)
acknowledgement = models.TextField(blank=True, null=True)
reference = models.TextField(blank=True, null=True, max_length=2255)
Expand Down
2 changes: 1 addition & 1 deletion ui/static/js/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ $(document).ready(function () {
}
});

$.getJSON("static/js/metadata/dataset.json?v=20231026", function (data) {
$.getJSON("static/js/metadata/dataset.json?v=20240209", function (data) {
templates.datasets = data;
createEditForm('datasets');
});
Expand Down
2 changes: 1 addition & 1 deletion ui/static/js/metadata/dataset.json
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@
"label": "Dataset Funding organization(s)",
"sequence": 16,
"multiple": false,
"description": "<p>Identify the agencies and offices that funded the work to generate the dataset. Separate multiple funders with a comma and a space.</p>"
"description": "<p>Identify the agencies and offices that funded the work to generate the dataset. Separate multiple funders with a comma and a space. <b>This field has a limit of 1024 characters.</b></p>"
},
"doe_funding_contract_numbers": {
"type": "string",
Expand Down
Loading