Adding attendees under the Attendance tab in the Admin, my client would like to have ‘Existing user’ and ‘Attending’ as the default values. Is there a way to change these defaults?
So far I’ve managed to change them in the attendance.php (stachethemes_event_calendarviewadminevents absattendance) together with the icons belonging to the different states in the main.js (.../stachethemes_event_calendar/assets/js/admin).
But there are still some issues I haven’t been able to resolve myself…
Could you give me a little push in the right direction?
I have another request, can I sort the list of existing users on last name (or a different slug/ parameter, now it's on display name) on the attendance tab?
Hi,
Adding attendees under the Attendance tab in the Admin, my client would like to have ‘Existing user’ and ‘Attending’ as the default values. Is there a way to change these defaults?
So far I’ve managed to change them in the attendance.php (stachethemes_event_calendarviewadminevents absattendance) together with the icons belonging to the different states in the main.js (.../stachethemes_event_calendar/assets/js/admin).
But there are still some issues I haven’t been able to resolve myself…
Could you give me a little push in the right direction?
High regards!
Hi,
Open your theme or child-theme functions.php file and add following code:
Stachethemes Developer
Hi,
Thank you this works (perfectly)!
I have another request, can I sort the list of existing users on last name (or a different slug/ parameter, now it's on display name) on the attendance tab?
High regards,
Jochem
This code should order the attendees in the admin by last name.
Stachethemes Developer
Also nice to have ;-)
But I meant the list 'Existing users' under 'Add attendees' on the Attendance tab.
See attachment.
Jochem
...correct attachment
Open file stachethemes_event_calendar\view\admin\events\index.php
and edit lines 77 and 90 from:
to:
This change will be included in the next update.
Stachethemes Developer
Great! (and perfect support)
Hi,
Can this list 'Existing users' (under 'Add attendees' on the Attendance tab) show only a specific user role?
Now it shows all users - including the deceased members of my client.
Regards,
Jochem
Edit further the code by adding role__in filter:
The new filter is this one:
Just change administrator with the role(s) you need.
Example:
Stachethemes Developer
Super!!
Hi,
Since the last update - 3.1.7 - these codes don't work anymore. You have an idea why?
Regards,
Jochem
Hi,
Some of the changes were included in the update.
Which code exactly does not work?
Stachethemes Developer
Hi,
This one:
Yes, we've recently edited the calendar name in the dashboard so the hook changed.
Here's the new code:
Stachethemes Developer
Thx it works again!