diff --git a/booking.emails.inc b/booking.emails.inc index ed1f6e0..f494baa 100644 --- a/booking.emails.inc +++ b/booking.emails.inc @@ -192,7 +192,7 @@ function _booking_partialbalance_payment_email($nid) //calculate the remaining parameters $to = $node->booking_email; - $subject = t('!event Partial Payment Required', array('!event' => $event->booking_eventname)); + $subject = t('!event Partial Payment Received', array('!event' => $event->booking_eventname)); $params['subject'] = $subject; $params['headers']['Bcc'] = "it@coadcorp.com, " . variable_get('booking_notify_email', variable_get('site_mail', ini_get('sendmail_from'))); diff --git a/booking.manual_payment.inc b/booking.manual_payment.inc index 7b5ab3f..ffe972b 100644 --- a/booking.manual_payment.inc +++ b/booking.manual_payment.inc @@ -150,11 +150,25 @@ function booking_manual_payment_admin_submit($form, &$form_state) { //add this payment to their existing balance $total_paid = $person->booking_amount_paid + $price; + //work out what their booking status is now + if ($person->booking_status == 1 || _booking_check_bookings_full() == FALSE) + { + //either they were already booked in, or there is room on the booked-in list + $status = 1; + } + else + { + //there must be a waiting list, so put them on that + $status = 2; + } + + /* //determine what their booking status is now if (_booking_check_bookings_full() == True || $person->booking_status == 2) $status = 2; else $status = 1; + */ watchdog('booking', 'Setting payment for regn id !nid to $!price and status to !status', array('!nid' => $key, '!price' => $price, '!status' => $status));