start making csv import/export more dynamic
This commit is contained in:
@@ -1315,6 +1315,19 @@ function _booking_paypal_form_builder($node, &$form_state, $person, $invoiceid,
|
||||
return $form;
|
||||
}
|
||||
|
||||
/**
|
||||
* Helper function to provide a list of columns in the booking_person table
|
||||
* This will be used to select which fields to import/export to/from a CSV
|
||||
*/
|
||||
function _booking_get_person_fields() {
|
||||
$query = db_query('SHOW COLUMNS FROM {booking_person}');
|
||||
$list_of_columns = new stdClass();
|
||||
while ($res = db_fetch_array($query)) {
|
||||
$list_of_columns->$res['Field'] = $res['Field'];
|
||||
}
|
||||
return $list_of_columns;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Helper function to format registrations details for summary in the confirmation email
|
||||
|
Reference in New Issue
Block a user