aboutsummaryrefslogtreecommitdiff
path: root/captain/web.f90
diff options
context:
space:
mode:
authorJeffrey Armstrong <jeff@approximatrix.com>2022-06-29 08:33:07 -0400
committerJeffrey Armstrong <jeff@approximatrix.com>2022-06-29 08:33:07 -0400
commitfb7136be64188cab7db34ac3ad6c8f27098173de (patch)
tree8660bbd7aec6a256dcaf672d5ffc4ac9c2d96fc4 /captain/web.f90
parent6e59e791b7b4d1184e70378544b6ace433ab33aa (diff)
downloadlevitating-fb7136be64188cab7db34ac3ad6c8f27098173de.tar.gz
levitating-fb7136be64188cab7db34ac3ad6c8f27098173de.zip
Initial work to show artifacts on job pages.
Diffstat (limited to 'captain/web.f90')
-rw-r--r--captain/web.f9021
1 files changed, 21 insertions, 0 deletions
diff --git a/captain/web.f90 b/captain/web.f90
index e7ade4f..0bd21ee 100644
--- a/captain/web.f90
+++ b/captain/web.f90
@@ -729,6 +729,7 @@ contains
function generate_one_job_html(req) result(res)
use captain_db
+ use config
use server_response
use special_filenames, only: get_task_result_static_filename
use request_utils, only: get_status_utf8, get_player_link => player_link, &
@@ -749,6 +750,7 @@ contains
character(len=:), pointer::task_results_filename, one_link, local_task_results_filename
character(len=:), pointer::player_link, instruction_link
+ character(len=FILENAME_NAME_LENGTH), dimension(:), pointer::releases
logical::file_exists
res => null()
@@ -817,6 +819,25 @@ contains
res = trim(res)//nl//nl//"<p><strong>None reported yet</strong></p>"
end if
+ if(get_job_upload_count_by_category_db(job_id, "releases") > 0 .and. &
+ req%auth_level >= global_permissions%get("access-releases")) &
+ then
+
+ res = trim(res)//nl//"<h3>Releases</h3>"//nl//"<ul>"
+ releases => get_job_uploads_by_category_db(job_id, "releases")
+ do i = 1, size(releases)
+
+ one_link => html_link("/releases/"//trim(releases(i)), &
+ trim(releases(i)))
+
+ res = trim(res)//nl//" <li>"//trim(one_link)//"</li>"
+
+ end do
+
+ res = trim(res)//nl//"</ul>"
+
+ end if
+
else
allocate(character(len=64) :: res)