commit 42a778d0c84a50c79a817e97a031f8bf1c890c14
Author: root <root@srv-xen-moodle08.tauntons.ac.uk>
Date:   Wed Dec 2 06:22:46 2009 +0000

    Fixed Force Book to cope with DST issues

diff --git a/blocks/mrbs/web/force_book.php b/blocks/mrbs/web/force_book.php
index 45f2f78..4e23ad6 100644
--- a/blocks/mrbs/web/force_book.php
+++ b/blocks/mrbs/web/force_book.php
@@ -11,12 +11,18 @@ function mrbsForceMove($room_id, $starttime, $endtime,$name,$id=null){
 
     $output='';
 
+    $dststarttime = mrbs_uncorrect_dst($starttime);
+    $dstendtime = mrbs_uncorrect_dst($endtime);
+
     # Select any meetings which overlap ($starttime,$endtime) for this room:
     $sql = 'SELECT '.$CFG->prefix.'mrbs_entry.id AS entryid, '.$CFG->prefix.'mrbs_entry.name as entryname, '.$CFG->prefix.'mrbs_entry.description, type,'.$CFG->prefix.'mrbs_entry.create_by, '.$CFG->prefix.'mrbs_room.room_name, '.$CFG->prefix.'mrbs_entry.name, '.$CFG->prefix.'mrbs_entry.start_time, '.$CFG->prefix.'mrbs_entry.end_time, '.$CFG->prefix.'mrbs_room.description, area_id
               FROM '.$CFG->prefix.'mrbs_entry join '.$CFG->prefix.'mrbs_room on '.$CFG->prefix.'mrbs_entry.room_id = '.$CFG->prefix.'mrbs_room.id
              WHERE (('.$CFG->prefix.'mrbs_entry.start_time>='.$starttime.' AND '.$CFG->prefix.'mrbs_entry.end_time<'.$endtime.')
              OR ('.$CFG->prefix.'mrbs_entry.start_time<'.$starttime.' AND '.$CFG->prefix.'mrbs_entry.end_time>'.$starttime.')
-             OR ('.$CFG->prefix.'mrbs_entry.start_time<'.$endtime.' AND '.$CFG->prefix.'mrbs_entry.end_time>='.$endtime.'))';
+             OR ('.$CFG->prefix.'mrbs_entry.start_time<'.$endtime.' AND '.$CFG->prefix.'mrbs_entry.end_time>='.$endtime.')
+             OR ('.$CFG->prefix.'mrbs_entry.start_time>='.$dststarttime.' AND '.$CFG->prefix.'mrbs_entry.end_time<'.$dstendtime.')
+             OR ('.$CFG->prefix.'mrbs_entry.start_time<'.$dststarttime.' AND '.$CFG->prefix.'mrbs_entry.end_time>'.$dststarttime.')
+             OR ('.$CFG->prefix.'mrbs_entry.start_time<'.$dstendtime.' AND '.$CFG->prefix.'mrbs_entry.end_time>='.$dstendtime.'))';
 
     //this is so that if a booking is being edited (normally extended) and forcing the booking a confusing email doesn't get sent to the force booker
     if(!empty($id)){

