My Work > Counselling Diary

29th July 2007

Online Counselling Diary

I created an online multi-user diary for the use on the College Counselling Department Intranet which went live in early 2007. Written in PHP and using a MySQL database, it allows Counsellors, Student Services Staff and Students to make appointments. The data in the screenshots below has been edited / Rolling Stonsed to protect any sensitive information.

It had to be a completely anonymous service with not even the Counsellors necessarily knowing the name of the client. This led to problems as I had to make sure clients couldn’t book more than one appointment. They would book their first appointment and then future sessions would be set up by their Counsellor. To get around this, I store the client’s user name in a hashed format.

Figure 1: Staff View of the Diary
The Staff side of the diary (figure 1) allows staff to quickly book and edit appointments. I've created a calendar (on the left menu panel) to allow for quick navigation around the months. Each 'slot' is displayed in a different colour depending on which Counsellor is on duty. There is also information on the slot's availability, comments, icons to show who booked the appointment (counsellor, staff or student) and icons for afterwards to show if the client attended or not. There is also a ‘Quick Book’ icon and an icon that brings up the Edit window (figure 2) when clicked.

Figure 2: The Edit Window
The Edit window 'greys out' the background to ensure that it has focus and it allows the user to set all the details for the slot.

Figure 3: Templates
To allow staff to quickly set the data for many slots, I set up the ability to apply a template to a date range in the diary (figure 3). The grid in template view is ‘coloured in’ by simply clicking on a square. This fills it with the colour selected in the radio group on the right. The template is then saved and can be applied to the diary. This is all done with Javascript and CSS.

Figure 4: Student View of the Diary
On the student side of things (figure 4), a basic grid is displayed showing which sessions and Counsellors are available for them to book. The client is allowed to book an appointment in a period from the next day up to for four weeks into the future. The client is only allowed to book one session and a hash of their username is stored. This also allows us to show them their appointment when they return to the page and allows to them to cancel it in the future if they so wish. When a client books in this way an e-mail is sent to the Counsellor and a confirmation page for the client is made available for them to print out. If a client cancels an appointment another e-mail is sent to the Counsellor.

If anyone is interested in my Diary, I may be able to make an edited version of the code available. E-mail me on website@samjking.co.uk