9.22 IS_ALLOWED Function
Caution:
This API is deprecated and will be removed in a future release.
Use APEX_HUMAN_TASK instead.
This function checks whether the given user is permitted to perform a certain operation on a Task.
Syntax
APEX_APPROVAL.IS_ALLOWED (
    p_task_id                IN NUMBER,
    p_operation              IN apex_approval.t_task_operation,
    p_user                   IN VARCHAR2 DEFAULT apex_application.g_user,
    p_new_participant        IN VARCHAR2 DEFAULT NULL )
RETURN BOOLEAN;Parameters
| Parameter | Description | 
|---|---|
| p_task_id | The Task ID. | 
| p_operation | The operation to check (see constants c_task_op_###). | 
| p_user | The user to check for. Default is logged in user. | 
| p_new_participant | (Optional) The new assignee in case of Delegate operation. | 
Returns
TRUE if the user given by p_user is permitted to perform the operation given by p_operation, FALSE otherwise.
                  
Example
DECLARE
    l_is_allowed boolean;
BEGIN
    l_is_allowed := apex_approval.is_allowed(
        p_task_id         => 1234,
        p_operation       => apex_approval.c_task_op_delegate
        p_user            => 'STIGER',
        p_new_participant => 'SMOON'
    );
    IF l_is_allowed THEN
        dbms_output.put_line('STIGER is a allowed to delegate the task to SMOON for task 1234');
    END IF;
END;Parent topic: APEX_APPROVAL (Deprecated)