From 2cb42dccf365e220808923cee1b318fde0110547 Mon Sep 17 00:00:00 2001 From: Benedict Date: Mon, 7 Aug 2023 14:59:18 -0400 Subject: [PATCH 1/3] easier to file access ticket for self --- code/game/machinery/ARES/ARES_procs.dm | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/code/game/machinery/ARES/ARES_procs.dm b/code/game/machinery/ARES/ARES_procs.dm index b636934640bb..48d9cc5f8417 100644 --- a/code/game/machinery/ARES/ARES_procs.dm +++ b/code/game/machinery/ARES/ARES_procs.dm @@ -984,8 +984,13 @@ GLOBAL_LIST_INIT(maintenance_categories, list( return TRUE if("new_access") + var/ticket_holder var/priority_report = FALSE - var/ticket_holder = tgui_input_text(operator, "Who is the ticket for? (Please use precise name, with punctuation and capitalisation.)", "Ticket Holder", encode = FALSE) + var/is_self = tgui_alert(operator, "Is this request for yourself?", "Ticket Holder", list("Yes", "No")) + if(is_self != "Yes") + ticket_holder = tgui_input_text(operator, "Who is the ticket for? (Please use precise name, with punctuation and capitalisation.)", "Ticket Holder", encode = FALSE) + else + ticket_holder = last_login if(!ticket_holder) return FALSE var/details = tgui_input_text(operator, "What is the purpose of this access ticket?", "Ticket Details", encode = FALSE) From cef06330455b7f374e1c6885eedbd1199e961e08 Mon Sep 17 00:00:00 2001 From: Benedict Date: Mon, 7 Aug 2023 15:11:05 -0400 Subject: [PATCH 2/3] changes to view status --- tgui/packages/tgui/interfaces/WorkingJoe.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/tgui/packages/tgui/interfaces/WorkingJoe.js b/tgui/packages/tgui/interfaces/WorkingJoe.js index e4c97770066a..0244cc497013 100644 --- a/tgui/packages/tgui/interfaces/WorkingJoe.js +++ b/tgui/packages/tgui/interfaces/WorkingJoe.js @@ -727,19 +727,19 @@ const AccessRequests = (props, context) => { )} {access_tickets.map((ticket, i) => { - let view_status = 'Ticket is pending assignment.'; + let view_status = 'Access Ticket is pending assignment.'; let view_icon = 'circle-question'; if (ticket.status === 'assigned') { - view_status = 'Ticket is assigned.'; + view_status = 'Access Ticket is assigned.'; view_icon = 'circle-plus'; } else if (ticket.status === 'rejected') { - view_status = 'Ticket has been rejected.'; + view_status = 'Access Ticket has been rejected.'; view_icon = 'circle-xmark'; } else if (ticket.status === 'cancelled') { - view_status = 'Ticket was cancelled by reporter.'; + view_status = 'Access Ticket was cancelled by reporter.'; view_icon = 'circle-stop'; } else if (ticket.status === 'completed') { - view_status = 'Ticket has been successfully resolved.'; + view_status = 'Access Ticket has been successfully resolved.'; view_icon = 'circle-check'; } let can_cancel = 'Yes'; From 7a91fde3a2bc9e7f4f8d4a81b245ad00aeee9c8f Mon Sep 17 00:00:00 2001 From: Benedict Date: Mon, 7 Aug 2023 16:10:04 -0400 Subject: [PATCH 3/3] Now can see recipient for access request in access request tab --- code/game/machinery/ARES/ARES_procs.dm | 4 ++-- tgui/packages/tgui/interfaces/WorkingJoe.js | 6 ++++++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/code/game/machinery/ARES/ARES_procs.dm b/code/game/machinery/ARES/ARES_procs.dm index 48d9cc5f8417..142fae44a212 100644 --- a/code/game/machinery/ARES/ARES_procs.dm +++ b/code/game/machinery/ARES/ARES_procs.dm @@ -987,9 +987,9 @@ GLOBAL_LIST_INIT(maintenance_categories, list( var/ticket_holder var/priority_report = FALSE var/is_self = tgui_alert(operator, "Is this request for yourself?", "Ticket Holder", list("Yes", "No")) - if(is_self != "Yes") + if(is_self == "No") ticket_holder = tgui_input_text(operator, "Who is the ticket for? (Please use precise name, with punctuation and capitalisation.)", "Ticket Holder", encode = FALSE) - else + else if(is_self == "Yes") ticket_holder = last_login if(!ticket_holder) return FALSE diff --git a/tgui/packages/tgui/interfaces/WorkingJoe.js b/tgui/packages/tgui/interfaces/WorkingJoe.js index 0244cc497013..7413e321308a 100644 --- a/tgui/packages/tgui/interfaces/WorkingJoe.js +++ b/tgui/packages/tgui/interfaces/WorkingJoe.js @@ -721,6 +721,9 @@ const AccessRequests = (props, context) => { Time + + For + Details @@ -764,6 +767,9 @@ const AccessRequests = (props, context) => { {ticket.time} + + {ticket.title} + {ticket.details}