Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Only Listen To Broadcast Events For Current Day? #17

Open
dxfan227 opened this issue Apr 7, 2019 · 2 comments
Open

Only Listen To Broadcast Events For Current Day? #17

dxfan227 opened this issue Apr 7, 2019 · 2 comments
Labels
enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed

Comments

@dxfan227
Copy link

dxfan227 commented Apr 7, 2019

Is it possible to have the route only listen for events only on the current day of the event? I want my map to default to a certain route ....but not day of events.

right now it shows an event that's in 20 days, I don't need that route estimate right now obviously.

I think it would be something here?

// Let's see if we can handle it if (notification === "CALENDAR_EVENTS") { // Ok, we should be able to handle this for (var e in payload) { var event = payload[e]; if(event.location){ override = event.location; } if(override)break; } } else { Log.log(notification," notification type is not supported (yet)"); return; } // Update the destination override if needed if(override){ var o = this.state.overrideDestination; if(JSON.stringify(this.state.overrideDestination) != JSON.stringify(override)){ // New override this.state.overrideDestination = override; this.getDirections(); } }else if(this.state.overrideDestination){ // No more overrides this.state.overrideDestination = undefined; this.getDirections(); } }

@mrdis
Copy link
Owner

mrdis commented Apr 26, 2019

It's not currently possible.
I don't think I will be able to implement this anytime soon, feel free to submit a pull request :)

@mrdis mrdis added enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed labels Apr 26, 2019
@DavidD303
Copy link

Couldn't you add a statement before it updates the destination location to have it compare the startDate in the notification to the current date? I have zero javascript experience so I could be totally incorrect but it seems like it could be an easy fix?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

3 participants