Skip to content

Commit 4af4656

Browse files
authored
Merge pull request #2243 from antgonza/fix-2216
fix #2216
2 parents 24b7d8e + adf98a3 commit 4af4656

File tree

3 files changed

+10
-0
lines changed

3 files changed

+10
-0
lines changed

qiita_pet/handlers/artifact_handlers/base_handlers.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -216,6 +216,8 @@ def artifact_summary_get_request(user, artifact_id):
216216
'processing_jobs': processing_jobs,
217217
'summary': summary,
218218
'job': job_info,
219+
'artifact_timestamp': artifact.timestamp.strftime(
220+
"%Y-%m-%d %H:%m"),
219221
'errored_jobs': errored_jobs}
220222

221223

qiita_pet/handlers/artifact_handlers/tests/test_base_handlers.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,7 @@ def test_artifact_summary_get_request(self):
9292
(2L, '1_s_G1_L001_sequences_barcodes.fastq.gz (raw barcodes)')]
9393
exp = {'name': 'Raw data 1',
9494
'artifact_id': 1,
95+
'artifact_timestamp': '2012-10-01 09:10',
9596
'visibility': 'private',
9697
'editable': True,
9798
'buttons': ('<button onclick="if (confirm(\'Are you sure you '
@@ -120,6 +121,7 @@ def test_artifact_summary_get_request(self):
120121
obs = artifact_summary_get_request(user, 1)
121122
exp = {'name': 'Raw data 1',
122123
'artifact_id': 1,
124+
'artifact_timestamp': '2012-10-01 09:10',
123125
'visibility': 'private',
124126
'editable': True,
125127
'buttons': ('<button onclick="if (confirm(\'Are you sure you '
@@ -155,6 +157,7 @@ def test_artifact_summary_get_request(self):
155157
obs = artifact_summary_get_request(user, 1)
156158
exp = {'name': 'Raw data 1',
157159
'artifact_id': 1,
160+
'artifact_timestamp': '2012-10-01 09:10',
158161
'visibility': 'private',
159162
'editable': True,
160163
'buttons': ('<button onclick="if (confirm(\'Are you sure you '
@@ -184,6 +187,7 @@ def test_artifact_summary_get_request(self):
184187
obs = artifact_summary_get_request(demo_u, 1)
185188
exp = {'name': 'Raw data 1',
186189
'artifact_id': 1,
190+
'artifact_timestamp': '2012-10-01 09:10',
187191
'visibility': 'public',
188192
'editable': False,
189193
'buttons': '',
@@ -210,6 +214,7 @@ def test_artifact_summary_get_request(self):
210214
(5L, '1_seqs.demux (preprocessed demux)')]
211215
exp = {'name': 'Demultiplexed 1',
212216
'artifact_id': 2,
217+
'artifact_timestamp': '2012-10-01 10:10',
213218
'visibility': 'private',
214219
'editable': True,
215220
'buttons': ('<button onclick="if (confirm(\'Are you sure you '
@@ -245,6 +250,8 @@ def test_artifact_summary_get_request(self):
245250
obs = artifact_summary_get_request(user, 8)
246251
exp = {'name': 'noname',
247252
'artifact_id': 8,
253+
# this value changes on build so copy from obs
254+
'artifact_timestamp': obs['artifact_timestamp'],
248255
'visibility': 'sandbox',
249256
'editable': True,
250257
'buttons': '',

qiita_pet/templates/artifact_ajax/artifact_summary.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,7 @@ <h4>
103103
</h4>
104104
{% if processing_parameters %}
105105
<p style="padding: 10px 10px 10px 10px; border-radius: 10px; background: #EEE;">
106+
<b>Timestamp:</b> {{artifact_timestamp}} ||
106107
<b>Processing parameters:</b>
107108
{% for key in processing_parameters %}
108109
<i>{% raw key %}</i>: <i>{% raw processing_parameters[key] %}</i>

0 commit comments

Comments
 (0)