Toggle menu

Configuration and Users

Core Configuration

Room Bookings uses the Slot Booking framework. All of the configuration set in the Core Slot Bookings Settings also needs to be set up.

Room Booking End Point

The Room Booking configuration is held in the config.[environment].RoomBooking.getConfig end point.

PropertyTypeDescription
approvalsPaymentsObjectAn object that holds the two grace periods below
approvalsPayments.approvalGracePeriodObjectHow long to hold a booking for between booking and approval. Bookings that aren't approved in this time period are automatically cancelled

approvalGracePeriod: {
    units: "days",
    value: 7,
    workflow: "P7D"
}
approvalsPayments.paymentGracePeriodObjectHow long to hold a booking for between approval and payment. Bookings that aren't paid for in this time period are automatically cancelled

paymentGracePeriod: {
    units: "days",
    value: 7,
    workflow: "P7D"
}
BuildingsArray of IntegersThe parent article IDs beneath which all of the buildings are located. See Buildings and Floors. This populates the buildings drop-down in various forms
cancellationReasonsArray of stringsThese reasons populate the drop-down field on the cancellation form. For example:
cancellationReasons: [
    "Event cancelled",
    "Found a cheaper room",
    "Other"
]
commercialBookerTypesArray of ObjectsLeave this array blank to disable this functionality.

On the booking form a user may be prompted to confirm what their relationship is to the organisation providing the room (for example member, non-member) Each object in this array populates an option on the form, for example

commercialBookerTypes: [{
        type: "Non-Member",
        displayName: "Non-Member",
        option: "Not a member of the centre",
        default: true
    },{
        type: "Member",
        displayName: "Member",
        option: "A member of the centre",
        default: false
    },{
        type: "Commercial",
        displayName: "Commercial",
        option: "A commercial organisation",
        default: false
    },
]
commsObjectThe name and address emails will appear to come from, for example

comms: {
    fromAddress: "test@gosshosted.com",
    fromName: "Room Booking"
}
dataProtectionStatementURLStringThe full URL of a web page with your data protection/privacy statement. This is displayed in booking forms
facilitiesMetadataPropertyIdIntegerThe ID of a metadata property. Values describe room facilities (eg computer, whiteboard etc) and populate the room creation forms. See Creating Rooms
minuteBookingIncrementsArray of integersThese values are used in the booking form and populate the "Minutes" drop-down when picking booking start and end times. The default is [0, 15, 30, 45]
minuteBookingIntervalIntegerA value in minutes. This value sets the latest start time of a booking relative to the room closing time.

For example, in a room that closed at 17:00, setting it as 30 would mean the latest a booking could start would be at 16:30, setting it as 60 would mean the latest a booking could start would be at 16:00
myBookingsArticleIdStringThe article ID of an article using the My Slot Bookings template
purposeOptionsArray of objectsThis configuration is optional. If present a drop-down will appear on the booking form from which the booker will have to pick one of the following options to categorise the purpose of the booking.

Each object in the array has two properties, "value" and "display" which is the format expected by the drop-down form field. For example:

const purposeOptions = [
    { value: "publicmeeting", display: "Public Meeting" },
    { value: "publicevent", display: "Public Event" },
    { value: "privateevent", display: "Private Event" },
    { value: "other", display: "Other" }
]
reservationDurationIntegerA time in seconds.

Once a booker has checked the availability of a room, the time slot will be held for this number of seconds (ie they have this long to complete the booking form)
roomTypesMetadataPropertyIdIntegerThe ID of a metadata property. Values describe the room (eg meeting room, hall etc) and populate the room creation forms. See Creating Rooms
slotBookSearchRootMetaDataPropertyIntegerThe ID of a metadata property. Values of this property are article IDs. These article IDs should be articles that describe buildings (ie have child/grandchild articles using the Slot Book template).

If you relate a value to the form used to create rooms, that value will be set as the value of the Slot Book Search Root in the room's article extras, overriding the SLOTBOOKSEARCHROOT below. This value would be used if your booking forms let you pick which room to make a booking in - the default forms don't do this because you make your booking directly from a room's calendar
slotTypeIdIntegerThe ID of an article using the Slot Type Template. This article provides the default booking type that will be made in the room calendars
slotTypeMapArray of objectsThis array populates the "Booking Type" drop-down on the form used to create rooms.

Each object sets the type of appointment (ie Slot Type) that will be made by a booking. buildingId and commercial will filter the options in the drop-down based upon the other values (the building and whether or not the room needs to be paid for) picked on the create a room form. The description is the display value in the drop-down. All of this configuration simply controls the options on the form used to create rooms - it doesn't affect the booking forms

For example:

slotTypeMap: [{
        slotTypeId: 1473,
        buildingId: 3311,
        description: "A meeting",
        commercial: false
    },
    {
        slotTypeId: 3147,
        buildingId: 3311,
        description: "A party",
        commercial: true
    }
]
slotTypeRootMetadataPropertyIntegerThe ID of a metadata property. Values of this property are article IDs. These article IDs should be articles that have child articles using the Slot Type template.

If you relate a value to the form used to create rooms, that value will be set as the value of the Slot Type Search Root in the room's article extras, overriding the SLOTTYPESEARCHROOT set below. This value would be used if your booking forms let you pick which type of appointment you are booking - the default forms don't do this because all bookings are of the same type (the slotTypeId set above)
superAdminGroupStringThe name of a site user group. Users in this group can administer and book onto all rooms
termsAndConditionsURLStringThe full URL of a web page with your terms and conditions. This is displayed in booking forms
APPOINTMENTCREATEFORMIntegerThe ID of the SBCREATEAPPOINTMENTROOMBOOKING. This form is used to make bookings that don't require payment
APPOINTMENTVIEWFORMIntegerThe ID of the SBVIEWAPPOINTMENTBOOKING form. This form is used to view bookings that didn't require payment
COMMERCIALAPPOINTMENTCREATEFORMIntegerThe ID of the SBCHAINEDCREATEAPPOINTMENTCOMMERCIALROOMBOOKING form. This form is used to make bookings that do require payment
EVENTVIEWFORMIntegerThe ID of the "view events" form. This form is used to view Bookings events (ie not room bookings, but actual events) if you relate an event article to your room. This functionality isn't used by Room Bookings
SLOTBOOKSEARCHROOTIntegerThe parent article ID of a set of articles using the Slot Type template. This value will be added to the article extras of all of your rooms but isn't used by the default booking forms
SLOTTYPESEARCHROOTIntegerThe parent article ID of a set of articles using the Slot Type template. Each of these slot type articles describe a type of appointment that can be booked into the room calendars (note that by default all bookings are of the same type - the slotTypeId set above). This value will be added to the article extras of all of your rooms but isn't used by the default booking forms

Payment Configuration

The payment provider configuration in the end point is divided into three distinct sections. The first holds the configuration for your payment providers, the second adds building or room specific settings, and the third maps providers to buildings or rooms. This allows different buildings to use different settings and providers.

Providers

The supported providers are:

  • Adelante (multi-item)
  • Capita SCP (single item)
  • PayPal

Each provider's settings are held in a dedicated object (ie one per provider). This example shows Capita configuration:

const capitaSCPConfig = {
    provider: PaymentProviders.CAPITA_SCP,
    scpId: '12345678',
    siteId: '123',
    HMAC: 'abc<--->xyz',
    HMACKeyId: '456',
    wsUrl: 'https://subdomain.e-paycapita.com/scp/scpws/'
};

Building or Room Specific Settings

Once the base provider settings have been defined, building and room specific settings can be added. 

The name of each configuration must have the format building+articleID+configName where the article ID is the ID of the building (see Buildings and Floors) or room+articleID+configName if you want to set up configuration by room.

This example shows two buildings (articles 3130 and 3040), both of which use the same underlying Capita configuration, but have their own fund codes and reference numbers:

const building3130capitaSCPConfig = Object.assign({}, capitaSCPConfig);
const building3040capitaSCPConfig = Object.assign({}, capitaSCPConfig);

building3130capitaSCPConfig.fundCode = "81";
building3130capitaSCPConfig.custRef1 = "MS - 590600204510000";

building3040capitaSCPConfig.fundCode = "81";
building3040capitaSCPConfig.custRef1 = "DH - 590600204510000";

Building to Provider Mapping

Once the configuration objects have been built up, they are then mapped to buildings.

The names of these objects must have the format building+articleID:

const paymentConfig = {
    building3130: building3130capitaSCPConfig,
    building3040: building3040capitaSCPConfig
};

Enabling Payments

Finally three top level settings enable your provider configuration:

paymentProviders: [PaymentProviders.CAPITAFS, PaymentProviders.PAYPALV2, PaymentProviders.CAPITA_SCP, PaymentProviders.ADELANTEV5, PaymentProviders.ADELANTEV6],
paymentProviderLevel: "Building",
paymentConfig: paymentConfig

PropertyTypeDescription
paymentProvidersArrayThe various providers that have been configured
paymentProviderLevelStringEither "Building" or "Room"
paymentConfigObjectThe configuration mapping described above

When a payment form is displayed on the site, the form first looks for paymentProvderLevel, then adds the ID of the building or room that's being booked to look up the relevant payment provider and its configuration.

Metadata

There are five sets of metadata used by Room Bookings.

Room Booking Metadata
 

PropertyDescription
FacilitiesThese values describe features in a room, for example, PC, Projector, Tea and coffee making etc.

The ID of this property is set as the facilitiesMetadataPropertyId in the configuration. Values appear on the form used to create rooms.

This property is also picked in the Room Search article extras, and values appear as a filter in the search
roomTypesThese values describe types of room, for example Meeting Room, Hall etc.

The ID of this property is set as the roomTypesMetadataPropertyId in the configuration. Values appear on the form used to create rooms.

This property is also picked in the Room Search article extras, and values appear as a filter in the search
Slot Book Search RootsThe values of this property are the IDs of articles that represent buildings. They can be related to the forms used to create rooms, and will override the default SLOTBOOKSEARCHROOT in the configuration
Slot TypesThe values of this property are the IDs of articles that represent the types of thing that can be booked (ie articles that use the Slot Type template). They can be used in the booking form to let the person making the booking pick what they want to use the room for, overriding the default slotTypeId in the configuration
Slot Type Search RootsThe values of this property are the IDs of parent articles that have articles using the Slot Type template beneath them. They can be used by the form used to create rooms to set the SLOTTYPESEARCHROOT in the article extras of the Slot Booking template (each of which represents  room)

Users

Room Bookings defines users in the following broad categories.

Bookers

These are users who can book the room. When you create a room you can set the user groups who will be able to book it.

Administrators

These users are responsible for approving bookings and can also cancel and amend bookings. When you create a room you can set the administrator user group.

Room Managers

These users have the ability to update the room details and archive the room. They don't have access to the bookings in the room.

When you create a room you can pick the manager group from a drop-down list. The items in the drop-down are mappings to website user groups. Mappings are used so that the groups and users responsible for a room can be updated and the room doesn't become the responsibility of a single user.

Creating Room Manager Group Mappings

The drop-down list on the create a room form is populated by mappings set up in iCM using the "Room Bookings - Manage Groups" form shortcut.

The shortcut displays existing mappings, which can be edited:

User Mappings
 

When you create a new mapping you are prompted to enter a name (which will appear in the form drop-down) and pick site user groups who will be able to manage the room:

Create Mapping
 

Last modified on October 03, 2024

Share this page

Facebook icon Twitter icon email icon

Print

print icon