Reply To: Distinguish availability types

Oh.. that’s not very good.. Anyway, I found a hack that let’s you do this (FYI, if anyone else has to to the same).

First run:
$avail = $res->checkAvailability(1, false);

That gives you the availability for reservations due to other reservations only. So set a suitable constant for that, and then run:

$avail = $res->checkAvailability(1, true);

This gives you the availability for reservations due to BOTH other reservations and filters. So if you compare with the constant you just created you can determine why the reservation is unavailable (if it is).

Anyway, some documentation on these functions would really help when you’re working with them. For instance I have no idea what the $mode parameter does (among many other things). And I don’t know what the Validate() method does either. If you have time please elaborate on these.