From c6e988945a12e3bc5cc9c9e2ceb881fdb5ce6f62 Mon Sep 17 00:00:00 2001 From: Nathan Coad Date: Thu, 26 May 2016 12:02:31 +1000 Subject: [PATCH] recreate tableselect completely --- booking.emails.inc | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/booking.emails.inc b/booking.emails.inc index c13eacc..3788085 100644 --- a/booking.emails.inc +++ b/booking.emails.inc @@ -251,8 +251,17 @@ function _booking_manual_email_selecttype_dropdown_callback($form, &$form_state) } else { $new_default_values = array("1815" => TRUE); } - $form['table']['#header'] = $header; - $form['table']['#options'] = $options; + + $form['table'] = array ( + '#type' => 'tableselect', + '#header' => $header, + '#options' => $options, + //'#default_value' => $values, + '#empty' => t('No attendees found.'), + '#attributes' => array('id' => 'sort-table'), + '#prefix' => '
', + '#suffix' => '
', + ); watchdog('booking_debug', "
Manual email new form table\n@info
", array('@info' => print_r( $form['table'], true))); //$form['table']['#default_value'] = $new_default_values; $form['table'] = form_process_tableselect($form['table']);