Support

Home Forums Event Espresso Premium Attendee Report , add remove columns

Attendee Report , add remove columns

Posted: January 12, 2016 at 5:09 am


adria vidal

January 12, 2016 at 5:09 am

Is possible to edit the columns? we make custom code editing the fields via uploads/espresso/

but admin pages seems to funcion on a different way

any suggestion?


Josh

  • Support Staff

January 12, 2016 at 10:28 am

Hi Adria,

In EE3, there are a few filter hooks where you can use the WordPress plugin API to override what’s displayed in some of the columns. Code examples follow:

add_filter('filter_hook_espresso_attendee_reports_price_option_column_title', 'my_custom_attendee_column_head', 10 );
function my_custom_attendee_column_head( $display ) {
    $display = 'Ticket/Amount paid';
    return $display;
}

add_filter('filter_hook_espresso_attendee_reports_price_option_column_cell', 'my_custom_attendee_price_display', 10, 2 );
function my_custom_attendee_price_display( $display, $attendee ) {
    $amount_pd = $attendee->amount_pd;
    $display = '<i>' . $display . '</i><br>Paid $' . $amount_pd;
    return $display;
}

You can add the above to a functions plugin or into your WordPress theme’s functions.php file.


adria vidal

January 13, 2016 at 3:05 am

great got the example running, how could i get a custom meta field for the attendees?


Josh

  • Support Staff

January 13, 2016 at 8:59 am

It depends on what your looking to get. Registrations are stored in their own table, and attendees (quite possibly better described as contacts) are stored in the posts table. So you may need to write some PHP and at the very least do a join to get info from the other table.


adria vidal

January 13, 2016 at 9:27 am

thanks will try to join some tables at wp_usermeta and wp_users.

And some simple way to make a filter to hide some of the attendee columns?


Josh

  • Support Staff

January 13, 2016 at 9:50 am

Hi Adria,

Like with the Screen Options tab?

https://www.evernote.com/shard/s4/sh/092e6d79-2b66-4c7b-9830-52dbcbb8b38c/39c7a168df2cc7a36c4d57547fdd388c


adria vidal

January 13, 2016 at 9:56 am

Maybe EE3 performs different i can’t see that options

https://www.dropbox.com/s/9w1ejl009lhj4wh/event%20list%20attend.png?dl=0


Josh

  • Support Staff

January 13, 2016 at 10:41 am

Oh right you are, sorry about that. The screenshot was from Event Espresso 4. In the case of EE3, I think you can add some jQuery to pre-set the checkboxes for the column filters that get hidden/show with the jQuery dataTables jQuery plugin.


adria vidal

January 13, 2016 at 10:57 am

any tip about these magic jquery? client have to hide/show everytime the fields to get the right see.


Josh

  • Support Staff

January 13, 2016 at 11:14 am

Do you have a specific question about this? There are loads of tips about how to use jQuery in their docs:

http://learn.jquery.com/


adria vidal

January 13, 2016 at 11:25 am

No, only if someone have done something similar with the order/view menu not remenbering the options. ;-D


Josh

  • Support Staff

January 13, 2016 at 11:55 am

It’s not supposed to remember anything, but you can use jQuery to override the options when it loads the page. Does that make sense?

The support post ‘Attendee Report , add remove columns’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso