Hi Stephen, is there a way to include the payment gateway on the booking export?
We have a client with PayPal and ‘offline payment’ enabled. ‘Reserve pending tickets’ is off.
The client can export bookings, including ‘pending’ status bookees to output the data for those offline people. We can’t however differentiate between PayPal people who didn’t complete, and Offline payment people (who are valid, and should be chased for payment).
At the moment they either A) output confirmed bookings, and exclude offline payment people, or B) output pending people too, but can’t tell if they’re incomplete PayPal or genuine offline payment people.
If you have a function to hook into the export process to include the payment gateway on the booking export, that’d be ideal?
Thanks in advance.
Chris Dunst
Hi Chris,
Yes this is possible:
add_filter( 'eventorganiser_export_bookings_headers', function( $columns ) {
$columns['paymentgateway'] = 'gateway';
return $columns;
} );
add_filter('eventorganiser_export_bookings_cell_paymentgateway', function( $cell, $booking ) {
return eo_get_booking_meta( $booking->ID, 'gateway' );
}, 10, 2 );
Stephen Harris
You’re a star, thanks Stephen.
I haven’t tried it yet, but I’m sure it’ll do the job.
All the best.
Chris Dunst