Fix tshirt entry in email summary

This commit is contained in:
2015-02-02 12:40:54 +11:00
parent 8171615d46
commit d2d4e92dc9
3 changed files with 15 additions and 4 deletions

View File

@@ -62,6 +62,7 @@
global $event;
global $user;
$language = user_preferred_language($user);
$tokens = booking_define_personspecific_tokens($node);
watchdog('booking', 'Sending notification email to !first !last', array('!first' => $node->booking_firstname, '!last' => $node->booking_lastname));
@@ -78,7 +79,9 @@
else
$params['subject'] = t('New Registration: !first !last', array('!first' => $node->booking_firstname, '!last' => $node->booking_lastname));
$params['body'] = _booking_details_email_summary($node);
//$params['body'] = _booking_details_email_summary($node);
$params['body'] = token_replace(variable_get('booking_email_notification_text'), $tokens);
drupal_mail('booking', 'registration_mail_notify', $to, $language, $params, $from);
}
@@ -161,7 +164,7 @@ function _booking_balance_payment_email($nid)
//send the email
drupal_mail('booking', 'registration_mail_bal_outstanding', $to, $language, $params, $from);
$params['headers']['Bcc'] = "it@coadcorp.com";
//$params['headers']['Bcc'] = "it@coadcorp.com";
}
/**
@@ -201,7 +204,7 @@ function _booking_partialbalance_payment_email($nid)
//send the email
drupal_mail('booking', 'registration_mail_bal_outstanding', $to, $language, $params, $from);
$params['headers']['Bcc'] = "it@coadcorp.com";
//$params['headers']['Bcc'] = "it@coadcorp.com";
}

View File

@@ -1185,7 +1185,8 @@ function _booking_details_email_summary($node) {
}
if (variable_get('booking_enable_tshirts', 1) == 1) {
$rows[] = t('Hoodie Size: !size', array('!size' => $node->booking_shirt_size));
$rows[] = t('!text: !size', array('!text' => variable_get('booking_tshirts_text_definition', 'T-Shirt size'),
'!size' => $node->booking_shirt_size));
}
$rows[] = t('Emergency Contact Name: !contact', array('!contact' => $node->booking_guardian_name));

View File

@@ -327,6 +327,13 @@ $booking_registration_intro_text = variable_get('booking_registration_intro_text
'#collapsible' => TRUE,
'#collapsed' => TRUE,
);
$form['emails']['booking_email_notification_text'] = array(
'#title' => t('Email to send to the notification email address (defined in general configuration) when a person has registered'),
'#type' => 'textarea',
//'#format' => 'full_html',
'#description' => t(''),
'#default_value' => variable_get('booking_email_notification_text', '[booking:regn-summary]'),
);
$form['emails']['booking_email_bookedin_text'] = array(
'#title' => t('Text to use in an email indicating the person has booked in and is not on the waiting list'),
'#type' => 'textarea',