1
0
-1

Currently I have set up a datalist to allow the requestor to view their own request using the below filter
I would like to know how to allow the HOD to view their own respective section request only.

Example, HR can only view HR member request, while Finance can only view their own.

    CommentAdd your comment...

    1 answer

    1.  
      1
      0
      -1

      Save the department id into the database when first time submitting the form record (you can use a hidden field with "#currentUser.department.id#") then use the Hash Variable#CurrentUserHashVariable to filter your datalist , example:

      select * from app_fd_tableName where c_deptCode = "#currentUser.department.id#"

      Reference: JDBC Datalist Database Binder 

      1. Aaron Tan

        If not mistaken the variable, '"#currentUser.department.id#" is not applicable for community version of joget, correct ? 

        If that is the case, then I am unable to perform as per your suggestion.

      CommentAdd your comment...