mirror of
https://gitlab.ub.uni-bielefeld.de/sfb1288inf/nopaque.git
synced 2025-06-14 10:00:40 +00:00
Some cosmetic fixes
This commit is contained in:
@ -12,8 +12,9 @@ class JobInputTable(Table):
|
||||
url = LinkCol('Download', 'jobs.download_job_input',
|
||||
url_kwargs=dict(job_id='job.id',
|
||||
job_input_id='input_id'),
|
||||
anchor_attrs={'class': 'waves-effect waves-light btn-small',
|
||||
'download': ''})
|
||||
anchor_attrs={'class': 'waves-effect waves-light btn-floating',
|
||||
'download': ''},
|
||||
text_fallback='<i class="material-icons">file_download</i>')
|
||||
|
||||
|
||||
class JobInputItem(object):
|
||||
|
@ -6,6 +6,7 @@ from . import tasks
|
||||
from . tables import JobInputItem, JobInputTable
|
||||
from ..models import Job, JobInput, JobResult
|
||||
import os
|
||||
import html
|
||||
|
||||
|
||||
@jobs.route('/<int:job_id>')
|
||||
@ -16,8 +17,8 @@ def job(job_id):
|
||||
abort(403)
|
||||
items = [JobInputItem(input.filename, job, input.id)
|
||||
for input in job.inputs]
|
||||
# Convert table object to html string
|
||||
job_input_table = JobInputTable(items).__html__()
|
||||
# Convert table object to html string and unescape <>& for al little hack to use icons in buttons
|
||||
job_input_table = html.unescape(JobInputTable(items).__html__())
|
||||
# Add class "list" to tbody element. Needed for "List.js"
|
||||
job_input_table = job_input_table.replace('tbody', 'tbody class="list"', 1)
|
||||
return render_template('jobs/job.html.j2',
|
||||
|
Reference in New Issue
Block a user