diff --git a/booking.emails.inc b/booking.emails.inc
index 148e9fe..7171c6a 100644
--- a/booking.emails.inc
+++ b/booking.emails.inc
@@ -328,12 +328,12 @@ function _booking_custom_email($nid, $email_type, $sender = 'contact') {
'!email' => variable_get('booking_logistics_email', variable_get('site_mail', ini_get('sendmail_from')))
));
// Test email attachments with dummy file
- $attachment = array(
- 'filecontent' => file_get_contents(DRUPAL_ROOT . '/README.txt'),
- 'filename' => 'test.txt',
- 'filemime' => 'text/plain',
- );
- $params['attachment'] = $attachment;
+ //$attachment = array(
+ // 'filecontent' => file_get_contents(DRUPAL_ROOT . '/README.txt'),
+ // 'filename' => 'test.txt',
+ // 'filemime' => 'text/plain',
+ //);
+ //$params['attachment'] = $attachment;
}
//load the node matching this id
diff --git a/booking.helper.inc b/booking.helper.inc
index 5ad3fef..a4c3080 100644
--- a/booking.helper.inc
+++ b/booking.helper.inc
@@ -1620,16 +1620,18 @@ function _booking_studygroup_email_summary($node) {
$studygroups = $studygroups_query->fetchAllAssoc('sid');
//for ($i = 1; $i <= variable_get('booking_studygroup_count','0'); $i++)
- foreach ($studygroups as $studygroup)
- {
+ foreach ($studygroups as $studygroup) {
//calculate the session references
$sessionid = "session" . $studygroup->sid;
$roleid = $sessionid . "_role";
//check that this study group session has been defined for this attendee
- if (!empty($node->$sessionid))
- {
- $rows[] = t($studygroup->booking_studygroup_descrip . ": Group " . $node->$sessionid . ", " . _booking_studygroup_role_lookup($node->$roleid));
+ if (!empty($node->$sessionid)) {
+ //$rows[] = t($studygroup->booking_studygroup_descrip . ": Group " . $node->$sessionid . ", " . _booking_studygroup_role_lookup($node->$roleid));
+ $rows[] = t('!role for group !descrip, which will occur on !weekday. !explan', array(
+ '!descrip' => $studygroup->booking_studygroup_descrip, '!weekday' => $studygroup->booking_studygroup_weekday,
+ '!explan' => $studygroup->booking_studygroup_explanation, '!role' => _booking_studygroup_role_lookup($node->$roleid),
+ ));
}
}
}
@@ -1639,7 +1641,13 @@ function _booking_studygroup_email_summary($node) {
}
if(variable_get('booking_enable_html_mail', 0) == 1) {
- return implode("\n
", $rows);
+ $output = "\n
Mail hook:\n@info", array('@info' => print_r( $message, true))); + //watchdog('booking_debug', "
Mail hook:\n@info", array('@info' => print_r( $message, true))); } /** @@ -1011,7 +1011,7 @@ function booking_mail_alter(&$message) { foreach($headers as $key => $value) { $message['headers'][$key] = $value; } - //watchdog('booking_debug', "
Mail alter hook:\n@info", array('@info' => print_r( $message, true))); + watchdog('booking_debug', "
Mail alter hook:\n@info", array('@info' => print_r( $message, true))); } /** diff --git a/booking.studygroups_admin.inc b/booking.studygroups_admin.inc index b4cd5ca..abf1de5 100644 --- a/booking.studygroups_admin.inc +++ b/booking.studygroups_admin.inc @@ -112,14 +112,30 @@ function booking_studygroups_define_form($node, &$form_state, $create, $editid = } if(!isset($form_state['storage']['confirm'])) { + $form['booking_studygroup_weekday'] = array ( + '#type' => 'textfield', + '#title' => t('Day of the week this study group will be held (eg Monday)'), + '#size' => 60, + '#maxlength' => 150, + '#required' => TRUE, + '#default_value' => !empty($data->booking_studygroup_weekday) ? $data->booking_studygroup_weekday : '', + ); $form['booking_studygroup_descrip'] = array ( '#type' => 'textfield', - '#title' => t('Description of this study group (eg Monday)'), + '#title' => t('Description of this study group (eg Study Group 1)'), '#size' => 60, '#maxlength' => 150, '#required' => TRUE, '#default_value' => !empty($data->booking_studygroup_descrip) ? $data->booking_studygroup_descrip : '', - ); + ); + $form['booking_studygroup_explanation'] = array ( + '#type' => 'textfield', + '#title' => t('Explanation for this study group (eg Matthew chapter 1)'), + '#size' => 60, + '#maxlength' => 150, + '#required' => TRUE, + '#default_value' => !empty($data->booking_studygroup_explanation) ? $data->booking_studygroup_explanation : '', + ); $form['booking_num_group_sessions'] = array ( '#type' => 'textfield',