mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-24 12:37:26 +01:00
Mech id upload buttons (#12364)
This commit is contained in:
committed by
variableundefined
parent
2ec03f63e5
commit
9c5acba4e8
@@ -172,12 +172,17 @@
|
||||
<h1>Following keycodes are present in this system:</h1>"}
|
||||
for(var/a in operation_req_access)
|
||||
output += "[get_access_desc(a)] - <a href='?src=[UID()];del_req_access=[a];user=\ref[user];id_card=\ref[id_card]'>Delete</a><br>"
|
||||
|
||||
output += "<a href='?src=[UID()];del_all_req_access=1;user=\ref[user];id_card=\ref[id_card]'><br><b>Delete All</b></a><br>"
|
||||
|
||||
output += "<hr><h1>Following keycodes were detected on portable device:</h1>"
|
||||
for(var/a in id_card.access)
|
||||
if(a in operation_req_access) continue
|
||||
var/a_name = get_access_desc(a)
|
||||
if(!a_name) continue //there's some strange access without a name
|
||||
output += "[a_name] - <a href='?src=[UID()];add_req_access=[a];user=\ref[user];id_card=\ref[id_card]'>Add</a><br>"
|
||||
if(!get_access_desc(a))
|
||||
continue //there's some strange access without a name
|
||||
output += "[get_access_desc(a)] - <a href='?src=[UID()];add_req_access=[a];user=\ref[user];id_card=\ref[id_card]'>Add</a><br>"
|
||||
|
||||
output += "<a href='?src=[UID()];add_all_req_access=1;user=\ref[user];id_card=\ref[id_card]'><br><b>Add All</b></a><br>"
|
||||
output += "<hr><a href='?src=[UID()];finish_req_access=1;user=\ref[user]'>Finish</a> <font color='red'>(Warning! The ID upload panel will be locked. It can be unlocked only through Exosuit Interface.)</font>"
|
||||
output += "</body></html>"
|
||||
user << browse(output, "window=exosuit_add_access")
|
||||
@@ -339,11 +344,27 @@
|
||||
operation_req_access += afilter.getNum("add_req_access")
|
||||
output_access_dialog(afilter.getObj("id_card"),afilter.getMob("user"))
|
||||
return
|
||||
if(href_list["add_all_req_access"] && add_req_access && afilter.getObj("id_card"))
|
||||
if(!in_range(src, usr))
|
||||
return
|
||||
var/obj/item/card/id/mycard = afilter.getObj("id_card")
|
||||
var/list/myaccess = mycard.access
|
||||
for(var/a in myaccess)
|
||||
if(get_access_desc(a))
|
||||
operation_req_access += a
|
||||
output_access_dialog(afilter.getObj("id_card"),afilter.getMob("user"))
|
||||
return
|
||||
if(href_list["del_req_access"] && add_req_access && afilter.getObj("id_card"))
|
||||
if(!in_range(src, usr)) return
|
||||
operation_req_access -= afilter.getNum("del_req_access")
|
||||
output_access_dialog(afilter.getObj("id_card"),afilter.getMob("user"))
|
||||
return
|
||||
if(href_list["del_all_req_access"] && add_req_access && afilter.getObj("id_card"))
|
||||
if(!in_range(src, usr))
|
||||
return
|
||||
operation_req_access = list()
|
||||
output_access_dialog(afilter.getObj("id_card"),afilter.getMob("user"))
|
||||
return
|
||||
if(href_list["finish_req_access"])
|
||||
if(!in_range(src, usr)) return
|
||||
add_req_access = 0
|
||||
|
||||
Reference in New Issue
Block a user