Pick-a-random-task now avoids tasks bordering other locked tasks

This Pull Request is to be applied AFTER #34 (which adds pick-a-random-task).

We noticed in the user feedback there was some concern about users being randomly given tasks which are right next to each other, which could lead to edit conflicts. This Pull Request adds some SQL to make sure that the random-task button avoids picking a task next to a currently-locked task, if possible. This should help prevent conflict :)