+ Post New Thread
Results 1 to 11 of 11
Home Access Plus+ Thread, Cannot override static bookings in Projects:; I have upgraded to version 8.7 and when logged in as a domain admin I cannot override any static bookings ...
  1. #1

    Join Date
    Nov 2011
    Location
    Birmingham
    Posts
    90
    Thank Post
    15
    Thanked 11 Times in 8 Posts
    Rep Power
    5

    Cannot override static bookings

    I have upgraded to version 8.7 and when logged in as a domain admin I cannot override any static bookings although I can cancel normal bookings and make bookings on behalf of people.

    When I try to override I get the normal form but the lesson drop down menu is blank where it is filled in on a standard booking. (see attahced) As always thank you.

    Cannot override static bookings-screenshot.jpg

  2. IDG Tech News
  3. #2
    nickbro's Avatar
    Join Date
    Jul 2010
    Location
    Gilwern, Wales
    Posts
    2,580
    Thank Post
    27
    Thanked 385 Times in 323 Posts
    Rep Power
    89
    Hmm I think I know why that does that, it's because the lesson you are overriding isn't free

  4. #3
    nickbro's Avatar
    Join Date
    Jul 2010
    Location
    Gilwern, Wales
    Posts
    2,580
    Thank Post
    27
    Thanked 385 Times in 323 Posts
    Rep Power
    89
    Try this to fix it:

    ~/bookingsystem/default.aspx: line 342 should read
    Code:
    } catch (e) { }
    change it to:
    Code:
                } catch (e) 
                {
                    $("#bfmultilesson").hide();
                    canmulti = false; 
                }

  5. #4

    Join Date
    Nov 2011
    Location
    Birmingham
    Posts
    90
    Thank Post
    15
    Thanked 11 Times in 8 Posts
    Rep Power
    5
    You are correct the room does have a static booking in but in v7 I was able to override static bookings, was this removed?

    Tried adding the code you posted and restarted IIS and it had no effect.

    Thank you

  6. #5

    Join Date
    Nov 2011
    Location
    Birmingham
    Posts
    90
    Thank Post
    15
    Thanked 11 Times in 8 Posts
    Rep Power
    5
    It looks like I got it working going from your lead but I'll be completely honest I have no idea if I've broken something else.

    ~/bookingsystem/default.aspx: line 336 reads
    Code:
    		            canmulti = true;
    		        }
    		        else {
    		            $("#bfmultilesson").hide();
    		            canmulti = false;
    		        }
    		    } catch (e) 
                {
                    $("#bfmultilesson").hide();
                    canmulti = false; 
                }
    I change it to:
    Code:
    		            canmulti = false;
    		        }
    		        else {
    		            $("#bfmultilesson").hide();
    		            canmulti = false;
    		        }
    		    } catch (e) 
                {
                    $("#bfmultilesson").hide();
                    canmulti = false; 
                }

  7. #6
    nickbro's Avatar
    Join Date
    Jul 2010
    Location
    Gilwern, Wales
    Posts
    2,580
    Thank Post
    27
    Thanked 385 Times in 323 Posts
    Rep Power
    89
    Odd, can't see any difference there, here is some corrected code:

    Code:
                try {
                    if (curres.MultiRoom) {
                        $("#bfmultilesson").show();
                        $("#bfmultiroom option").remove();
                        var l1 = false;
                        var l2 = "";
                        var l3 = 0;
                        var i = 0;
                        for (i = 0; i < curres.Data.length; i++)
                        {
                            if (!l1) l1 = (curres.Data[i].Lesson == lesson);
                            if (l1) {
                                l3++;
                                if ( (curres.MaxLessons > 0 && l3 > curres.MaxLessons) || 
                                     (l3 > availbookings[0] && availbookings[0] > 0 ) || curres.Data[i].Name != "FREE") {
                                    break;
                                }
                                $("#bfmultiroom").append('<option value="' + l2 + curres.Data[i].Lesson + '">' + l3 + ' Lesson' + (l3 == 1 ? '' : 's') + '</option>');
                                l2 += curres.Data[i].Lesson + ',';
                            }
                        }
                        if (i == 0) { canmulti = false; $("#bfmultilesson").hide(); }
                        canmulti = true;
                    }
                    else {
                        $("#bfmultilesson").hide();
                        canmulti = false;
                    }
                } catch (e) 
                {
                    $("#bfmultilesson").hide();
                    canmulti = false; 
                }

  8. #7
    nickbro's Avatar
    Join Date
    Jul 2010
    Location
    Gilwern, Wales
    Posts
    2,580
    Thank Post
    27
    Thanked 385 Times in 323 Posts
    Rep Power
    89
    Sorry, this is the correct code:
    Code:
                try {
                    if (curres.MultiRoom) {
                        $("#bfmultilesson").show();
                        $("#bfmultiroom option").remove();
                        var l1 = false;
                        var l2 = "";
                        var l3 = 0;
                        for (var i = 0; i < curres.Data.length; i++)
                        {
                            if (!l1) l1 = (curres.Data[i].Lesson == lesson);
                            if (l1) {
                                l3++;
                                if ( (curres.MaxLessons > 0 && l3 > curres.MaxLessons) || 
                                     (l3 > availbookings[0] && availbookings[0] > 0 ) || curres.Data[i].Name != "FREE") {
                                    break;
                                }
                                $("#bfmultiroom").append('<option value="' + l2 + curres.Data[i].Lesson + '">' + l3 + ' Lesson' + (l3 == 1 ? '' : 's') + '</option>');
                                l2 += curres.Data[i].Lesson + ',';
                            }
                        }
                        if (l2 == "") { canmulti = false; $("#bfmultilesson").hide(); }
                        canmulti = true;
                    }
                    else {
                        $("#bfmultilesson").hide();
                        canmulti = false;
                    }
                } catch (e) 
                {
                    $("#bfmultilesson").hide();
                    canmulti = false; 
                }

  9. #8

    Join Date
    Nov 2011
    Location
    Birmingham
    Posts
    90
    Thank Post
    15
    Thanked 11 Times in 8 Posts
    Rep Power
    5
    I tried the above code and it restored the ability to multi book rooms which are free but I can not override bookings that are static.

  10. #9
    nickbro's Avatar
    Join Date
    Jul 2010
    Location
    Gilwern, Wales
    Posts
    2,580
    Thank Post
    27
    Thanked 385 Times in 323 Posts
    Rep Power
    89
    Ok, you may need to turn off the multi-lesson booking mode on that resource

  11. #10

    Join Date
    Nov 2011
    Location
    Birmingham
    Posts
    90
    Thank Post
    15
    Thanked 11 Times in 8 Posts
    Rep Power
    5
    Sorry how do you turn it off per resource?

  12. #11
    nickbro's Avatar
    Join Date
    Jul 2010
    Location
    Gilwern, Wales
    Posts
    2,580
    Thank Post
    27
    Thanked 385 Times in 323 Posts
    Rep Power
    89
    hapConfig.xml
    HTML Code:
    <resource name="ICT2" type="Room" admins="Inherit"  enabled="True" emailadmins="False" enablecharging="False"  showto="All" hidefrom="" years="Inherit"  quantities="" readonlyto="" readwriteto=""  multilessonto="None" />
    make sure multilessonto="None"

SHARE:
+ Post New Thread

Similar Threads

  1. HAP+ SIMS.net Timetable to Static Bookings
    By nickbro in forum Home Access Plus+
    Replies: 2
    Last Post: 26th September 2011, 05:26 PM
  2. Staff Cannot access Booking and helpdesk
    By spacevortex in forum Home Access Plus+
    Replies: 2
    Last Post: 25th May 2011, 11:52 PM
  3. Replies: 29
    Last Post: 21st May 2010, 03:58 PM
  4. Books & CDS
    By russdev in forum Books and Manuals
    Replies: 19
    Last Post: 22nd March 2006, 02:33 PM
  5. A Good Free Online PHP Book
    By Diello in forum Coding
    Replies: 1
    Last Post: 22nd June 2005, 10:05 AM

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •