mazzamuz
Forum Replies Created
Viewing 2 replies - 1 through 2 (of 2 total)
-
i had major issues with the update. – it just didnt work allround? rolled back to Version: 4.1.3
Hi there – same issue here…would love a calendar specific to BP groups.
so i inspected the classes
The EM_Calendar::output() calls self::get($args);
which then calls self::get_default_search($args);As per the documentation (which is a bit missleading)
https://wp-events-plugin.com/documentation/event-search-attributes/ the documentation says EM_Calendar::output() only accepts two attributes..100% correct by get default search seems to extend thisNow EM_Events::output(); works with group=my it also goes to self::get_default_search($args); so i just replace the self::get_default_search($args); in em-calender nad viola it worked
$defaults = array( 'orderby' => get_option('dbem_events_default_orderby'), 'order' => get_option('dbem_events_default_order'), 'bookings' => false, //if set to true, only events with bookings enabled are returned 'status' => 1, //approved events only 'format_header' => '', //events can have custom html above the list 'format_footer' => '', //events can have custom html below the list 'town' => false, 'state' => false, 'country' => false, 'region' => false, 'blog' => get_current_blog_id(), 'private' => current_user_can('read_private_events'), 'private_only' => false, 'post_id' => false ); if( EM_MS_GLOBAL && !is_admin() ){ if( empty($array['blog']) && is_main_site() && get_site_option('dbem_ms_global_events') ){ $array['blog'] = false; } } if( is_admin() ){ //figure out default owning permissions $defaults['owner'] = !current_user_can('edit_others_events') ? get_current_user_id() : false; if( !array_key_exists('status', $array) && current_user_can('edit_others_events') ){ $defaults['status'] = false; //by default, admins see pending and live events } } //$atts = parent::get_default_search($defaults, $array); $defaults['full'] = ($atts['full']==true) ? 1:0; $defaults['long_events'] = ($atts['long_events']==true) ? 1:0; return apply_filters('em_events_get_default_search', parent::get_default_search($defaults,$array), $array, $defaults);
Viewing 2 replies - 1 through 2 (of 2 total)