mirror of
https://github.com/dwaxweiler/connector-mobilizon
synced 2025-06-05 21:59:25 +02:00
fix widget, wip on shortcut
This commit is contained in:
@ -24,10 +24,21 @@ class EventsListShortcut {
|
||||
), $atts
|
||||
);
|
||||
|
||||
$classNamePrefix = NAME;
|
||||
$url = Settings::getUrl();
|
||||
$eventsCount = $atts_with_overriden_defaults['events-count'];
|
||||
$groupName = $atts_with_overriden_defaults['group-name'];
|
||||
|
||||
if ($groupName) {
|
||||
$data = GraphQlClient::get_upcoming_events_by_group_name($url, (int) $eventsCount, $groupName);
|
||||
} else {
|
||||
$data = GraphQlClient::get_upcoming_events($url, (int) $eventsCount);
|
||||
}
|
||||
|
||||
$classNamePrefix = NAME;
|
||||
$locale = get_locale();
|
||||
$isShortOffsetNameShown = Settings::isShortOffsetNameShown();
|
||||
$timeZone = wp_timezone_string();
|
||||
|
||||
ob_start();
|
||||
require dirname(__DIR__) . '/view/events-list.php';
|
||||
$output = ob_get_clean();
|
||||
|
Reference in New Issue
Block a user