Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 5 Next »

Booker25 allows multiple ways to define when a reservation is blocking another reservation. One of these ways is the Double Booking Matching Condition, which can be configured at the dimension level.

See https://gen25-jira.atlassian.net/wiki/spaces/BPD/pages/644186154/Dimensions+and+how+to+configure+them#Define-Dimensions for a description of the this and other fields on Dimension.

Simple Conditions

A basic double booking matching condition should follow the format of a SOQL WHERE-clause: https://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=&cad=rja&uact=8&ved=2ahUKEwjazaav_oT5AhVggv0HHRdEBr0QFnoECBQQAQ&url=https%3A%2F%2Fdeveloper.salesforce.com%2Fdocs%2Fatlas.en-us.soql_sosl.meta%2Fsoql_sosl%2Fsforce_api_calls_soql_select_conditionexpression.htm&usg=AOvVaw1-zM0tWs6m8YDGdFadBW1D. When inserting or updating a reservation, this condition is applied to existing reservations in the database, to find matches. Any existing reservations that do not match this condition are ignored and will not lead to double booking conflicts.

Simple Condition Example

For example, say you configure the following Double Booking Matching Condition on the Resource dimension: B25__Account__r.Type = ‘VIP'
This will result in existing reservations belonging to VIP accounts to be considered when checking for double bookings. And non-VIP account’s reservations will be ignored and can be over-booked. So if you would have two rooms each with a reservation already in it, one belonging to a VIP account and one belonging to a non-VIP account, you would still be able to book a reservation into the non-VIP room. But booking into the room already occupied by the VIP account will result in a double booking conflict.

Conditions with Placeholders

Optionally, you can include a placeholder indicating a field on the reservation being inserted or updated (as opposed to the other fields which refer to fields on the existing reservations already in the database).

Placeholder Example

For example, lets say you have a picklist named Gender__c on Contact, and you configure the following condition containing a placeholder: B25__Contact__r.Gender__c != {B25__Contact__r.Gender__c}
This will result in a double booking conflict when you are mixing different genders in one room. It will match the contact’s gender of the reservation being inserted or updated to the contact’s gender of any reservations already present in the room. If they are different, the existing reservation will block the reservation being inserted or updated.

Placeholder and Grouping Example

The above example can be combined with the resource-grouping feature to solve a common campus use-case. Lets say you have multiple beds in a large dorm-room, and you group all the bed resources together. Combined with the above condition this will make it so that as soon as one bed is occupied by a certain gender, you will not be able to insert a reservation for a different gender in another bed. But as long as the room is empty, you are free to assign the first bed to any gender.

Considerations

As long as you are not using placeholders, your condition can be anything you want as long as it’s a valid SOQL WHERE-clause, including ANDs and ORs.

When you are using placeholders, your condition must follow a couple of rules:

  • It must follow the form <field> <operator> <placeholder>

  • You are not allowed to use ORs and ANDs

  • The only allowed operators are = and !=

  • The placeholder must be surrounded in curly brackets {...}

  • No labels