Dynamic Google Calendar ID #296
Answered
by
bopismaster1
bopismaster1
asked this question in
Q&A
-
I'm trying to embed google calendar in our dashboard that has multiple users, is there's away that the dynamic calendar is Dynamic? |
Beta Was this translation helpful? Give feedback.
Answered by
bopismaster1
Apr 9, 2024
Replies: 1 comment 1 reply
-
I found a workaround on this, for create event to $event->calendarId=$calendar_id; in short public static function create(array $properties, string $calendarId = null, $optParams = [],$calendar_id=null)
|
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
bopismaster1
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I found a workaround on this, for create event
go to "vendor\spatie\laravel-google-calendar\src\Event.php"
got to line 61 (Create Function)
add calendar_id as params
change $event->calendarId = static::getGoogleCalendar($calendarId)->getCalendarId();
to
$event->calendarId=$calendar_id;
in short
public static function create(array $properties, string $calendarId = null, $optParams = [],$calendar_id=null)
{
$event = new static;