Collections functions
General functions
Node functions
Render functions
Theme permission functions
User functions
Resource functions

resource_request_visible()

Description

Can the logged in user see the request specified?

Parameters

ColumnTypeDefaultDescription
$request array Array of request details

Return

bool *

Location

include/request_functions.php lines 1264 to 1279

Definition

 
function resource_request_visible(array $request) : bool
    
{
    global 
$userref;
    
$show_this_request=false;
    
# Show request if the user can accept requests (permission "Rb")
    
if (checkperm("Rb") && ($request["assigned_to"]==$userref))
        {
        
$show_this_request=true;
        }
    
# Show request if the user can assign requests (permission "Ra")
    
if(checkperm('Ra'))
        {
        
$show_this_request=true;
        }
    return 
$show_this_request;
    }

This article was last updated 21st May 2024 11:05 Europe/London time based on the source file dated 17th April 2024 16:25 Europe/London time.