Added ajax function to individually manage room allocation

This commit is contained in:
2014-06-03 18:39:34 +10:00
parent 9aef5c23ed
commit eff81fdbba
4 changed files with 277 additions and 12 deletions

View File

@@ -1659,16 +1659,19 @@ function booking_view($node, $view_mode) {
}
$rows[] = array(t('Temporary UUID:'), $node->booking_tempid);
//if room allocation is defined, display that
if (! empty($node->rid))
{
//display room allocation data if enabled
if (variable_get('booking_enable_roomallocations', 0) == 1)
{
$room_heading = t("<h2>Room Allocation</h2><p>!link</p>",
array('!link' => l(t('Edit Room Allocation'), t('admin/booking/!id/edit-room', array('!id' => $node->nid)))
));
$room_rows = array();
$room_rows[] = array(t('Room Location'), _booking_room_location_lookup($node->booking_room_location_id));
$room_rows[] = array(t('Room Number'), $node->booking_room_number);
$room_rows[] = array(t('Bed Type'), _booking_room_bedtype_lookup($node->booking_room_bedtype));
$node->content['room-heading'] = array(
'#markup' => "<h2>Room Details</h2>",
'#markup' => $room_heading,
'#weight' => 2,
);