Support

Home Forums Event Espresso Premium Event with sub-events

Event with sub-events

Posted: November 28, 2017 at 1:56 pm

Viewing 13 reply threads


mediaroad_eu

November 28, 2017 at 1:56 pm

Hi there,

I have a client who organizes conferences with multiple sub-events: eg. there is a Conference XYZ that is composed of:
> Sub-event 01 – morning session
> Sub-event 02 – afternoon session

Users, who register to this event, should be able to select which sub-events they want to attend. For instance:
> User A would like to attend Subevent 01 and Sub-event 02;
> User B would only like to attend Sub-event 02.

Is there a way to make this setup happen with Event Espresso?

I tried to accomplish this with the Tickets system but it doesn’t work as my client wants it to work.

I created:
> Ticket A for the morning session and
> Ticket B for the afternoon session.

But, there are 2 problems with this solution:
1. If someone wants to attend both sessions, I need to fill in his contact details twice in the registration form (for Ticket A and B)
2. I can’t find in the dashboard a way to sort registrations according to tickets (eg. I would like to see – and export – all registrations of people who wish to attend Conference XYZ and selected Ticket B).

Is it possible to set-up your plugin in this way and if yes, how?

Thanks & best regards,

Paulina


Tony

  • Support Staff

November 29, 2017 at 3:00 am

Hi there,

There’s a couple of different ways you can set this up.

1. If someone wants to attend both sessions, I need to fill in his contact details twice in the registration form (for Ticket A and B)

With your current setup you can disable the questions for the additional registrtants on the event and EE will only ask for 1 set of details. So in the event you would make sure none of the question group are selected in the bottom section shown here – http://take.ms/1CBvc

2. I can’t find in the dashboard a way to sort registrations according to tickets (eg. I would like to see – and export – all registrations of people who wish to attend Conference XYZ and selected Ticket B).

That’s not something we currently have available.

You can filter down to the event and then also filter down to a specific datetime that a ticket applies to, but not the ticket type but you can filter that further within the CSV itself as the ticket name is included there.

Do you need the set limits for each individual session or just the event as a whole?


mediaroad_eu

November 29, 2017 at 6:11 am

Hi Tony,
Thank you very much for your message.
Ad issue 01: If someone wants to attend both sessions, I need to fill in his contact details twice in the registration form (for Ticket A and B)
The solution you proposed only partially solves my problem.
Let’s imagine I have 2 participants: Mr. Y and Mr. Z.
I would like both of them to attend both morning (Ticket A) and afternoon (Ticket B) sessions.
Now, in the registration form, there is an option to copy attendee #1 data to other attendees.
In my case, I can copy Attendee #1 info form ticket A to Attendee #3 for Ticket B (Mr. Y – attendee #1 will attend both sessions).
But I have Mr. Z (attendee #2) who also wants to attend both sessions and I cannot copy his data from one Ticket A to ticket B.
Is there any solution to this?

Ad issue 02: sorting registrations according to tickets in the dashboard.
Thanks. It helps. I have however one additional question: is there a way to customize the CSV export for certain events? eg. For my text event, I only need tyo export fields that were included in the registration form. I do not need transaction status etc. Is there a way to to this?
Thank you in advance!


mediaroad_eu

November 29, 2017 at 6:58 am

Regarding issue 02, I would like to exclude the following fields from the CSV export – is it possible?

Transaction ID[TXN_ID]
Attendee ID[ATT_ID]
Time registration occurred[REG_date]
Unique Code for this registration[REG_code]
Count of this registration in the group registration [REG_count]
Registration’s share of the transaction total[REG_final_price]
Currency
Transaction Amount Due
Amount Paid
Payment Date(s)
Payment Method(s)
Gateway Transaction ID(s)
Check-Ins


Tony

  • Support Staff

November 29, 2017 at 9:43 am

But I have Mr. Z (attendee #2) who also wants to attend both sessions and I cannot copy his data from one Ticket A to ticket B.
Is there any solution to this?

To do that you’re going to need an additional ticket option:

Ticket A
Ticket B
Ticket A + B

The user then selects either A, B, or A + B and selects the specific qty of each they need.

If you need to capture registration info for each attendee you need the question groups selected for additional attendee.

Ad issue 02: sorting registrations according to tickets in the dashboard.
Thanks. It helps. I have however one additional question: is there a way to customize the CSV export for certain events? eg. For my text event, I only need tyo export fields that were included in the registration form. I do not need transaction status etc. Is there a way to to this?

Yes, the output for the CSV is filterable.

You can use a function like this:

https://github.com/eventespresso/ee-code-snippet-library/blob/master/admin/registration_report_limit_columns_shown.php

You add the column headers you DO want in the CSV report onto a new element in the array, all others will be excluded.

This applies to all reports rather than just an individual event.


mediaroad_eu

November 30, 2017 at 9:25 am

Thank you very much for this!
One more question regarding the CSV export: if I use this function, will the CSV automatically include the custom fileds & custom question groups that are in the registration form?
The reason I’m asking is because it might happen that registration forms for different events will include different question groups. So It is fifficult to include the full list of fields.
In fact, it would be easier to have a function defining which fields should be excluded from the export.
Thanks in advance!
Best regards,
Paulina


mediaroad_eu

November 30, 2017 at 9:41 am

Sorry, I just found something on the forum.
Can I use this function instead?
Also, if I use this function, should I use the Site Specific plugin to push the code into the website?
Thanks & sorry for spamming with million questions 😉


Tony

  • Support Staff

November 30, 2017 at 9:54 am

Yes, you can, I created that function for the specific reason your asking about but as you asked for specific fields above I went with the other earlier.

It takes a little more setting up in that you’ll need to add all of the excluded fields but then yes, it will keep the various custom questions in the CSV for you.

Also, if I use this function, should I use the Site Specific plugin to push the code into the website?

Yes, we recommend using a plugin for custom functions rather than your themes functions.php for a few reasons, mainly because if you change themes you are back to square one.

Thanks & sorry for spamming with million questions

No problem at all, its why we are here 🙂


mediaroad_eu

December 1, 2017 at 8:00 am

Hi Tony,
I used this custom function but it doesn’t work.
I used the code included below.
Each time I’m trying to activate the plugin, I get:
Parse error: syntax error, unexpected ‘s’ (T_STRING) in /home/mediaroa/public_html/wp-content/plugins/mediaroadeventexport/eventexportplugin.php on line 23

In my case, this line is a field name…

The code was copied from this function. All fields were copied from the exported CSV.

<?php
/*
Plugin Name: Event export plugin for mediaroad.eu
Description: Site specific code for mediaroad.eu
*/
/* Begin Adding Functions Below This Line; Do not include an opening PHP tag as this sample code already includes one! */
/*
Plugin Name: Exclude custom fields from EE registrations export.
Description: Allows you to set felds that will be excluded from the registrations CSV export file.
Author: Tony Warwick
Version: 1.0
*/
function ee_exclude_custom_fields_from_export($reg_csv_array, $reg_row) {
	
	$fields_to_exclude_from_csv = array(
		//Add the fields you wish to exclude from the CSV here.
		//These excluded fields are an example of how to remove fields, your list will be different.
		__( 'Transaction ID[TXN_ID]', 'event_espresso' ),
		__( 'Transaction ID[TXN_ID]', 'event_espresso' ),
		__( 'Attendee ID[ATT_ID]', 'event_espresso' ),
		__( 'Time registration occurred[REG_date]', 'event_espresso' ),
		__( 'Unique Code for this registration[REG_code]', 'event_espresso' ),
		__( 'Count of this registration in the group registration [REG_count]', 'event_espresso' ),
		__( 'Registration's share of the transaction total[REG_final_price]', 'event_espresso' ),
		__( 'Currency', 'event_espresso' ),
		__( 'Transaction Amount Due', 'event_espresso' ),
		__( 'Payment Date(s)', 'event_espresso' ),
		__( 'Payment Method(s)', 'event_espresso' ),
		__( 'Gateway Transaction ID(s)', 'event_espresso' ),
		__( 'Check-Ins', 'event_espresso' )
	);
	
	foreach( $fields_to_exclude_from_csv as $single_field_to_exclude ) {
		//For each field within $fields_to_exclude_from_csv, check if that value is within the CSV array.
		if ( array_key_exists( $single_field_to_exclude, $reg_csv_array )) {
			//If the field is set remove it from the array.
			unset( $reg_csv_array[$single_field_to_exclude] );
		}
	}
	return $reg_csv_array;
}
add_filter( 'FHEE__EE_Export__report_registrations__reg_csv_array', 'ee_exclude_custom_fields_from_export', 100, 2 );
/* Stop Adding Functions */


mediaroad_eu

December 1, 2017 at 8:23 am

I think there is an issue with one field name:
Registration’s share of the transaction total[REG_final_price]

I think that the problem is the apostrophe ‘s in in the name of the field but I don’t know how to fix it… I copied that field name from the CSV I exported.

Do you have any suggestions how to exclude this field?


Tony

  • Support Staff

December 1, 2017 at 10:38 am

Yes, its that field.

You can either use:

__( 'Registration\'s share of the transaction total[REG_final_price]', 'event_espresso' ),

Or

__( "Registration's share of the transaction total[REG_final_price]", 'event_espresso' ),

Either of those should work.

Side note, if your site will always be in English (US) you can remove the translation function around each of those strings…

__( '{string}', '{text_domain}'),

Would just be the name of the column:

__( 'Registration\'s share of the transaction total[REG_final_price]', 'event_espresso' ),

would be

'Registration\'s share of the transaction total[REG_final_price]',


mediaroad_eu

December 3, 2017 at 9:09 am

Hi Tony!
Thank your for this!
I have another question:
So, I have this custom function that excludes certain fields from the CSV export.
Is there any way to make this function export fields in the same order as they appear on the registration form?
I’m asking because I realised that custom fields I added to the form are exported in some random order that doesn’t make much sense from the admin perspective.
Thank you & best regards,
Paulina


Tony

  • Support Staff

December 4, 2017 at 6:24 am

Hmm, I don’t believe so, at least not without using an ‘include’ function rather than the exculde function you are now.

For example, here’s another snippet where you set the columns to include, in that version it also orders them in the order set when you include them:

https://github.com/eventespresso/ee-code-snippet-library/blob/master/admin/tw_ee_registration_report_limit_columns_shown.php

But that runs into the same problem you asked about above.

I’ll check in with our developers on this to see if there is anything I’m missing (may take a little due to time differences)


mediaroad_eu

December 4, 2017 at 8:05 am

Thank you!

Viewing 13 reply threads

The support post ‘Event with sub-events’ 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