diff --git a/run.py b/run.py index 39e5e6d..acc284c 100644 --- a/run.py +++ b/run.py @@ -719,7 +719,12 @@ async def html_job(request, job_id): if job.count == 0: raise NotFound() - return {"job": job[0], 'relative_path_to_root': '../', 'path': request.path} + job = job[0] + + app = Repo.select().where(Repo.url == job.url_or_path) + app = app[0] if app else None + + return {"job": job, 'app': app, 'relative_path_to_root': '../', 'path': request.path} @app.route('/apps/') diff --git a/templates/job.html b/templates/job.html index b222d0b..18a8aba 100644 --- a/templates/job.html +++ b/templates/job.html @@ -4,8 +4,9 @@

- Job '{{job.name}}' - Job '{{job.name}}' DELETED + Job '{{job.name}}' #{{job.id}} + Job '{{job.name}}' #{{job.id}} DELETED + <% if app %>for <{ app.name }> <% endif %>