Skip to content
Open
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
9 changes: 7 additions & 2 deletions physionet-django/project/forms.py
Original file line number Diff line number Diff line change
Expand Up @@ -1089,14 +1089,19 @@ class Meta:
class DataAccessRequestForm(forms.ModelForm):
class Meta:
model = DataAccessRequest
fields = ('data_use_title', 'data_use_purpose', 'agree_dua')
fields = ('data_use_title', 'data_use_purpose', 'publications_link', 'collaborators', 'agree_dua')
help_texts = {
'data_use_title': """Title of the project you would like to use the data for""",
'data_use_purpose': """Detailed description of the data use.""",
'publications_link': """Link to relevant publications related to this research project""",
'collaborators': """List of collaborators (Name, email addresses) who will be working """
"""with you on this project""",
}
labels = {
'data_use_title': 'Research Project Title',
'data_use_purpose': 'Research Project Details'
'data_use_purpose': 'Research Project Details',
'publications_link': 'Link to Relevant Publications',
'collaborators': 'List of Collaborators'
}

agree_dua = forms.BooleanField(required=True)
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Generated by Django 4.2.18 on 2025-03-12 14:02

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('project', '0078_delete_archivedproject'),
]

operations = [
migrations.AddField(
model_name='dataaccessrequest',
name='collaborators',
field=models.TextField(blank=True, help_text='List of collaborators (Name, email addresses)', null=True),
),
migrations.AddField(
model_name='dataaccessrequest',
name='publications_link',
field=models.URLField(blank=True, null=True),
),
]
2 changes: 2 additions & 0 deletions physionet-django/project/modelcomponents/access.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,8 @@ class DataAccessRequest(models.Model):

data_use_title = models.CharField(max_length=200, default='')
data_use_purpose = SafeHTMLField(blank=False, max_length=10000)
publications_link = models.URLField(blank=True, null=True)
collaborators = models.TextField(blank=True, null=True, help_text="List of collaborators (Name, email addresses)")

status = models.PositiveSmallIntegerField(default=0, choices=REJECT_ACCEPT)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,15 @@ <h1>Data Access Request - {{ project }}</h1>
<h2>{{ access_request.data_use_title }}</h2>
<small class="text-muted">submitted on {{ access_request.request_datetime }}{% if access_request.is_accepted %}, valid {% if access_request.valid_until %}until {{ access_request.valid_until }}{% else %}forever {% endif %}{% endif %}{% include 'project/data_access_request_badge.html' with data_access_request=access_request %}</small>
<p>{{ access_request.data_use_purpose|safe }}</p>

{% if access_request.publications_link %}
<h4 class="mt-4">Relevant Publications</h4>
<p><a href="{{ access_request.publications_link }}" target="_blank">{{ access_request.publications_link }}</a></p>
{% endif %}

{% if access_request.collaborators %}
<h4 class="mt-4">Collaborators</h4>
<p>{{ access_request.collaborators }}</p>
{% endif %}
</div>
{% endblock %}
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ <h2>Previous Requests</h2>
<th>Last status update</th>
<th>Title</th>
<th>Data Use Purpose</th>
<th>Publications Link</th>
<th>Collaborators</th>
<th>Responder Comment</th>
</tr>
</thead>
Expand All @@ -21,6 +23,8 @@ <h2>Previous Requests</h2>
<td>{{ req.decision_datetime|date }}</td>
<td>{{ req.data_use_title }}</td>
<td>{{ req.data_use_purpose | safe }}</td>
<td>{% if req.publications_link %}<a href="{{ req.publications_link }}" target="_blank">{{ req.publications_link }}</a>{% endif %}</td>
<td>{{ req.collaborators }}</td>
<td>{{ req.responder_comments | safe }}</td>
</tr>
{% endfor %}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,16 @@ <h3>Project Description</h3>
<div class="alert alert-secondary">
<h4>{{ access_request.data_use_title }}</h4>
{{ access_request.data_use_purpose|safe }}

{% if access_request.publications_link %}
<h5 class="mt-3">Relevant Publications</h5>
<p><a href="{{ access_request.publications_link }}" target="_blank">{{ access_request.publications_link }}</a></p>
{% endif %}

{% if access_request.collaborators %}
<h5 class="mt-3">Collaborators</h5>
<p>{{ access_request.collaborators }}</p>
{% endif %}
</div>

<br>
Expand Down