|
|
|
@ -167,14 +167,18 @@ function fulcrm_shoppingcart_buy_eventbookingtype_form_submit( $form, &$form_sta
|
|
|
|
|
$form_state[ 'fulcrm_shoppingcart' ][ 'eventbookingtype' ][ 'event' ][ 'name' ] );
|
|
|
|
|
|
|
|
|
|
$eventslotbookings = array();
|
|
|
|
|
foreach ( $form_state[ 'fulcrm_shoppingcart' ][ 'eventbookingtype' ][ 'eventslotbookings' ] as $eventslotbooking ) {
|
|
|
|
|
$eventpart_id = fulcrm_apiv2_url_to_pk( $eventslotbooking[ 'eventslot' ][ 'eventpart' ] );
|
|
|
|
|
$eventslot_id = fulcrm_apiv2_url_to_pk( $eventslotbooking[ 'eventslot' ][ 'url' ] );
|
|
|
|
|
if ( array_key_exists( 'eventbookingtypeslots', $form_state[ 'fulcrm_shoppingcart' ][ 'eventbookingtype' ] ) ) {
|
|
|
|
|
foreach ( $form_state[ 'fulcrm_shoppingcart' ][ 'eventbookingtype' ][ 'eventbookingtypeslots' ] as $eventbookingtypeslots ) {
|
|
|
|
|
$eventpart_id = fulcrm_apiv2_url_to_pk( $eventbookingtypeslots[ 'eventslot' ][ 'eventpart' ] );
|
|
|
|
|
$eventslot_id = fulcrm_apiv2_url_to_pk( $eventbookingtypeslots[ 'eventslot' ][ 'url' ] );
|
|
|
|
|
|
|
|
|
|
if ( array_key_exists( $eventpart_id, $eventslotbookings ) )
|
|
|
|
|
drupal_set_message( 'XXX cannot yet cope with multiple choice event slot bookings; defaulting to first.', 'warning' );
|
|
|
|
|
if ( array_key_exists( $eventpart_id, $eventslotbookings ) )
|
|
|
|
|
drupal_set_message( 'XXX cannot yet cope with multiple choice event slot bookings; defaulting to first.', 'warning' );
|
|
|
|
|
|
|
|
|
|
$eventslotbookings[ $eventpart_id ] = $eventslot_id;
|
|
|
|
|
$eventslotbookings[ $eventpart_id ] = $eventslot_id;
|
|
|
|
|
}
|
|
|
|
|
} else {
|
|
|
|
|
drupal_set_message( 'XXX no eventbookingtypeslots to choose from?', 'warning' );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if ( $person_uuid ) {
|
|
|
|
|