IntelliPen Document Visibility Fields
IntelliPen now features a ‘visibility’ field (on table tb_documents) in the .net version, which is used in conjunction with controlling whether documents are visible to the end-user or not. This is a brief oversight of how this is intended to work.
The basic premise is that the Visibility field contains a bit mask number, which defines which Role Types are allowed to see a document. Example Role Types are:
- Administrator
- Member
- Employer
- Trustee
In the .config file, there is a setting called intelliScanSettings/visibilityEntities. Using the above examples you would set this to:
<add key=”visibilityEntities” value=”Administrator,Member,Employer,Trustee ” />
The positions of these values is important and once set should never be changed. Using the above setting as an example, the different role types would each have a unique number, as follows:
- Administrator = 1
- Member = 2
- Employer = 4
- Trustee = 8
These numbers are then bitwise compared with the Visibility value of a document to determine if the user is allowed to see the document.
So, if a document has the following visibility values, and given the role values as above, then the document is viewable as follows.
- Visibility = 5 (means that Administrator-1 and Employer-4 can see it 1 + 4 = 5)
- Visibility = 1 (only Administrator-1 can see it)
- Visibility = 15 (everyone can see it 1 + 2 + 4 + 8 = 15)
- Visibility = 9 (only administrator and trustee can see if 1+8 = 9)
see also:
tb_documents (table)
tb_RoleTypes (table)
Need more information? Please don’t hesitate to raise a ZenDesk ticket citing this article.
See anything that may be wrong? Please don’t hesitate to let us know.
Last updated 29th October 2020