Students shouldn't be able to use Portal Chat during assessments.
We have thought of 3 possible solutions, you can provide another possible solution or sharing your opinion about these ones:
- Hide it via Session attribute. If the session contains an attribute to hide portal chat, the chat will be hidden and other possible tabs neither will receive messages because the Session contains "hide portal chat" attribute. (This one also has a problem, due to user can have multiple sessions if is using different web browsers, therefore user will be able to use it anyway)
- Hide it via DB (Sakai User Property), portal chat is hidden when a student begins an assessment and in case the user were using multiple tabs or multiple sessions, portal chat will not send any messages because the DB contains "hide portal chat" user property. (We think this is the correct way to start the development, but we are open to discuss with the community).