# Angus' Events Plugin :calendar:

**URL:** https://meta.discourse.org/t/angus-events-plugin/69776
**Category:** Plugin
**Created:** [September 11, 2017, 2:44am UTC](https://meta.discourse.org/t/angus-events-plugin/69776 "2017-09-11T02:44:59Z")
**Posts on this page:** 20
**Page:** 6

<div class="post-metadata">

### Author: ![angus](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/angus/32/341715_2.png) [@angus](https://meta.discourse.org/u/angus)
#### Post date: [February 20, 2018, 1:48am UTC](https://meta.discourse.org/t/angus-events-plugin/69776/105 "2018-02-20T01:48:32Z")

</div>

> [@ChrisBeach](#):
>
> @angus One bug I noticed on my site, the start time input field no longer shows a drop down of times. I’m unable to add an event.

Fixed: [BUGFIX: time setup · angusmcleod/discourse-events@f899310 · GitHub](https://github.com/angusmcleod/discourse-events/commit/f899310158984f18619cc7783c9abef53cb59126)

---

<div class="post-metadata">

### Author: ![ChrisBeach](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/chrisbeach/32/214628_2.png) [@ChrisBeach](https://meta.discourse.org/u/ChrisBeach)
#### Post date: [February 20, 2018, 7:28am UTC](https://meta.discourse.org/t/angus-events-plugin/69776/106 "2018-02-20T07:28:08Z")

</div>

Thanks @angus, that fixed the problem I was seeing

---

<div class="post-metadata">

### Author: ![adorfer](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/adorfer/32/82089_2.png) [@adorfer](https://meta.discourse.org/u/adorfer)
#### Post date: [February 21, 2018, 1:53am UTC](https://meta.discourse.org/t/angus-events-plugin/69776/107 "2018-02-21T01:53:52Z")

</div>

> [@angus](#):
>
> events event label format

Thanks a lot! (i should have looked at the documentation.)

---

<div class="post-metadata">

### Author: ![angus](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/angus/32/341715_2.png) [@angus](https://meta.discourse.org/u/angus)
#### Post date: [February 21, 2018, 2:50am UTC](https://meta.discourse.org/t/angus-events-plugin/69776/108 "2018-02-21T02:50:29Z")

</div>

@tobiaseigen @ChrisBeach I’ve fine-tuned the event display to:

- handle all the edge cases for all-day event blocks;
- add titles to the start of each row for multi-day / multi-row events
- Allow multi-day titles to take multiple cells;
- Clearly delineate the start and end of multi-day events when multi-day events are back to back.

 ![Screenshot%20at%20Feb%2021%2010-47-50](https://global.discourse-cdn.com/meta/original/3X/4/2/4257f29a3433f2a3bbbd508d673e6edd1fcbf5d9.png)

> [@tobiaseigen](#):
>
> Pacific Time Zone seems to appear 3 times in the pulldown list when selecting time zones.

Yeah, one is US/Pacific, one is Canada/Pacific and one is US/Pacific-New (apparently it’s different from US/Pacific). I tried to do a bit of formatting on the timezone labels as some can be a bit long (i.e. remove the country), but it’s hard to come up with good formatting rules as timezones don’t have really have any universal conventions. I’ve removed the formatting for now, so you’ll just see the full labels.

 ![Screenshot%20at%20Feb%2021%2010-49-55](https://global.discourse-cdn.com/meta/original/3X/6/7/673b1c8154efeb57150083d1bd53bde1c66ab1c0.png)

---

<div class="post-metadata">

### Author: ![tobiaseigen](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/tobiaseigen/32/539204_2.png) [@tobiaseigen](https://meta.discourse.org/u/tobiaseigen)
#### Post date: [February 21, 2018, 4:31pm UTC](https://meta.discourse.org/t/angus-events-plugin/69776/109 "2018-02-21T16:31:20Z")

</div>

awesome! looking good. the “select a timezone” issue is pretty minor.

I had a poke around in your sandbox and noticed a few oddities. See screenshot. one multiday event goes off the right side of the screen. The “x more” is showing on a day when there are only two events. One of those is pushed down on the day as well. I can see what you’re doing there but it looks weird - wonder how google calendar handles that use case?

 ![00%20AM](https://global.discourse-cdn.com/meta/original/3X/5/5/5595575f54a83177c4477737c1760c4c5a2540e1.png)

~~I also added an event myself to the calendar and it’s not showing up.~~

---

<div class="post-metadata">

### Author: ![angus](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/angus/32/341715_2.png) [@angus](https://meta.discourse.org/u/angus)
#### Post date: [February 23, 2018, 3:22am UTC](https://meta.discourse.org/t/angus-events-plugin/69776/110 "2018-02-23T03:22:47Z")

</div>

Thanks again :slight_smile:

**Arrangement of events**

> [@tobiaseigen](#):
>
> one multiday event goes off the right side of the screen…One of those is pushed down on the day as well.

These are minor style calculation issues (fixed).

In most cases, the scenario you’re referring to here:

> [@tobiaseigen](#):
>
> The “x more” is showing on a day when there are only two events.

is necessary (the same is true in Google Calendar). This mostly happens because there are overlapping all-day events that end on different days. The plugin tries to ‘fill in’ when possible, but it can’t in a scenario like this.

 ![08%20AM](https://global.discourse-cdn.com/meta/original/3X/0/8/083ceeabdd8001266a20cd8f4aaac33995acc6d8.png)

If the hidden all-day event started on the 23rd, all of the events fit, e.g.

 ![46%20AM](https://global.discourse-cdn.com/meta/original/3X/b/d/bd9f707e5ac50767f217038a46e6f8c55a40ad16.png)

It’s a bit like a jigsaw puzzle.

There was one edge case which was handled differently in this plugin from Google Calendar, which is when there are overlapping all-day events that end on different days, causing a gap on a day in which there is also a normal event. In that case Google Calendar will ‘fill in’ the normal event.

 ![Screenshot%20at%20Feb%2022%2009-48-26](https://global.discourse-cdn.com/meta/original/3X/e/c/ec902a1a1a432a7d3deae446c3633a9d603dd8ff.png)

I’ve updated the calendar sort logic to handle this case (see ‘Blacklight’ in above screenshots). I’ve also increased the height of day cells to handle 4 event rows and made some slight adjustments to the ‘x more’ style.

**Routing and API**

I’ve added proper routing to the calendar, so that only the topics with events for the date range displayed are loaded at one time.

![13%20AM](https://global.discourse-cdn.com/meta/optimized/3X/e/5/e534b51c4ab102f9b0d54da38dcbf88ce4f05f55_2_621x32.png)

This also means that there is now an API for retrieving an arbitrary range of events created with this plugin

- `domain.com/calendar?start=start_date&end=end_date` will retrieve events in all categories within the specified range

- `domain.com/c/category_slug/l/calendar?start=start_date&end=end_date` will retrieve events in the specified category within the specified range

- `start` and `end` dates are ISO86 format: YYYY-MM-DD

---

<div class="post-metadata">

### Author: ![adorfer](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/adorfer/32/82089_2.png) [@adorfer](https://meta.discourse.org/u/adorfer)
#### Post date: [February 23, 2018, 5:04pm UTC](https://meta.discourse.org/t/angus-events-plugin/69776/111 "2018-02-23T17:04:03Z")

</div>

For “normal discourse categories” i can append an “.rss” to the url, in order to receive an RSS formatted feed.

with “/callendar.rss” or “/agenda.rss” this does not seem to work.  
At least i just receive an empty reply. (not even a 404)

Is there different way to obtain that?

---

<div class="post-metadata">

### Author: ![DavidGNavas](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/davidgnavas/32/68313_2.png) [@DavidGNavas](https://meta.discourse.org/u/DavidGNavas)
#### Post date: [February 23, 2018, 6:27pm UTC](https://meta.discourse.org/t/angus-events-plugin/69776/112 "2018-02-23T18:27:28Z")

</div>

This plugin is awesome!

Any chances to convert this plugin to official and enjoy it in Discourse hosted instances?

---

<div class="post-metadata">

### Author: ![ChrisBeach](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/chrisbeach/32/214628_2.png) [@ChrisBeach](https://meta.discourse.org/u/ChrisBeach)
#### Post date: [February 23, 2018, 7:22pm UTC](https://meta.discourse.org/t/angus-events-plugin/69776/113 "2018-02-23T19:22:06Z")

</div>

> [@DavidGNavas](#):
>
> Any chances to convert this plugin to official and enjoy it in Discourse hosted instances?

I’d like to see this for the benefit of self-hosted instances too. The events plugin is really useful and universal. Making it an official plugin would reduce the risk of breaking changes between core and plugin. Obviously it’s up to the Discourse team as the more official plugins they support, the less agility they have to improve core.

---

<div class="post-metadata">

### Author: ![ChrisBeach](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/chrisbeach/32/214628_2.png) [@ChrisBeach](https://meta.discourse.org/u/ChrisBeach)
#### Post date: [February 25, 2018, 4:27pm UTC](https://meta.discourse.org/t/angus-events-plugin/69776/114 "2018-02-25T16:27:44Z")

</div>

Minor bug: when clicking on a day in the calendar (mobile view), the calendar may switch to a different month (which is fine), but when this happens, the day selection highlight is lost.

Day highlight (blue circle) showing:

 ![image](https://global.discourse-cdn.com/meta/original/3X/6/9/692bd94274699bb0c1bb04903ffcc9c16f34607c.jpeg)

Tapped on the 1st March and now no day highlight showing (same with subsequent taps on days in March)

 ![image](https://global.discourse-cdn.com/meta/original/3X/f/6/f6964caca10e720cf0ceb8d0126e9c03506b2e83.jpeg)

---

<div class="post-metadata">

### Author: ![angus](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/angus/32/341715_2.png) [@angus](https://meta.discourse.org/u/angus)
#### Post date: [February 26, 2018, 3:30pm UTC](https://meta.discourse.org/t/angus-events-plugin/69776/115 "2018-02-26T15:30:59Z")

</div>

Thanks @ChrisBeach, I’ll fix this in the next day or so.

---

<div class="post-metadata">

### Author: ![angus](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/angus/32/341715_2.png) [@angus](https://meta.discourse.org/u/angus)
#### Post date: [February 27, 2018, 4:51am UTC](https://meta.discourse.org/t/angus-events-plugin/69776/116 "2018-02-27T04:51:25Z")

</div>

> [@DavidGNavas](#):
>
> Any chances to convert this plugin to official and enjoy it in Discourse hosted instances?

> [@ChrisBeach](#):
>
> I’d like to see this for the benefit of self-hosted instances too.

You’ll have to ask @sam.

> [@adorfer](#):
>
> For “normal discourse categories” i can append an “.rss” to the url, in order to receive an RSS formatted feed.

I’ve added rss feeds to the site-wide `/calendar` and `/agenda` routes, e.g.

[https://discourse.angusmcleod.com.au/calendar.rss](https://discourse.angusmcleod.com.au/calendar.rss)  
[https://discourse.angusmcleod.com.au/agenda.rss](https://discourse.angusmcleod.com.au/agenda.rss)

The calendar feed accepts `start` and `end` query parameters.

[Add /calendar and /agenda rss feeds · angusmcleod/discourse-events@16fba94 · GitHub](https://github.com/angusmcleod/discourse-events/commit/16fba9491c4a6b22456d7b4d07ee4af4a96efe00)

> [@ChrisBeach](#):
>
> Minor bug: when clicking on a day in the calendar (mobile view), the calendar may switch to a different month (which is fine), but when this happens, the day selection highlight is lost.

Fixed: [BUGFIX: selected date wasn't month-aware · angusmcleod/discourse-events@1c6c5bb · GitHub](https://github.com/angusmcleod/discourse-events/commit/1c6c5bb299901e2edc7a5e965b7eb7bb3f86f842)

---

<div class="post-metadata">

### Author: ![adorfer](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/adorfer/32/82089_2.png) [@adorfer](https://meta.discourse.org/u/adorfer)
#### Post date: [February 27, 2018, 5:10am UTC](https://meta.discourse.org/t/angus-events-plugin/69776/117 "2018-02-27T05:10:22Z")

</div>

> [@angus](#):
>
> I’ve added rss feeds to the site-wide /calendar and /agenda routes, e.g.
> 
> [https://discourse.angusmcleod.com.au/calendar.rss](https://discourse.angusmcleod.com.au/calendar.rss)
> 
> [https://discourse.angusmcleod.com.au/agenda.rss](https://discourse.angusmcleod.com.au/agenda.rss)

Thanks a lot, it’s highly appreciated!

---

<div class="post-metadata">

### Author: ![adorfer](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/adorfer/32/82089_2.png) [@adorfer](https://meta.discourse.org/u/adorfer)
#### Post date: [February 27, 2018, 9:52am UTC](https://meta.discourse.org/t/angus-events-plugin/69776/118 "2018-02-27T09:52:50Z")

</div>

There seems to be an issue:

when adding “to google callendar”  
the URL’s end-date is always “current date” (or posting date?), even if it is “without end date”.  
(despite that current date is wrong value.)

eg. from [this event](https://forum.freifunk.net/t/03-03-2018-oddd18-open-data-day-duesseldorf/18348)  
you get “[https://calendar.google.com/calendar/r/eventedit?text=03032018+ODDD18+Open+Data+Day+Dsseldorf&dates=20180304T100010Z/20180227T094116Z&details=Event+Details:+forum.freifunk.net/t/03-03-2018-oddd18-open-data-day-duesseldorf/18348&location=Haus+der+Universität,+14,+Schadowplatz,+Stadtmitte,+Stadtbezirk+1,+Düsseldorf,+Regierungsbezirk+Düsseldorf,+Nordrhein-Westfalen,+40212,+Deutschland&sf=true&output=xml](https://calendar.google.com/calendar/r/eventedit?text=03032018+ODDD18+Open+Data+Day+Dsseldorf&dates=20180304T100010Z/20180227T094116Z&details=Event+Details:+forum.freifunk.net/t/03-03-2018-oddd18-open-data-day-duesseldorf/18348&location=Haus+der+Universit%C3%A4t,+14,+Schadowplatz,+Stadtmitte,+Stadtbezirk+1,+D%C3%BCsseldorf,+Regierungsbezirk+D%C3%BCsseldorf,+Nordrhein-Westfalen,+40212,+Deutschland&sf=true&output=xml)”

BTW: 2nd small issue: handling of diacritical characters (here: “Umlauts” like “ü” are not passed to the URL.

---

<div class="post-metadata">

### Author: ![tran](https://avatars.discourse-cdn.com/v4/letter/t/dec6dc/32.png) [@tran](https://meta.discourse.org/u/tran)
#### Post date: [February 28, 2018, 4:04am UTC](https://meta.discourse.org/t/angus-events-plugin/69776/119 "2018-02-28T04:04:14Z")

</div>

I can choose the end date, but the end date will not be displayed in my topic, only the start date. When you add to the Google Calendar, the title can only recognize English numbers and symbols, but my website is not English - based,so the title is empty.

---

<div class="post-metadata">

### Author: ![angus](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/angus/32/341715_2.png) [@angus](https://meta.discourse.org/u/angus)
#### Post date: [February 28, 2018, 1:48pm UTC](https://meta.discourse.org/t/angus-events-plugin/69776/120 "2018-02-28T13:48:19Z")

</div>

@adorfer Thanks, I’ll have a look at these issues tomorrow.

@tran Thanks. I’ll have a look at the Google Calendar issue tomorrow. For the end date issue, could you give me some more details and / or an example? I just tested the functionality on my sandbox and it’s working fine, see e.g. [https://discourse.angusmcleod.com.au/t/late-night-jamming/302](https://discourse.angusmcleod.com.au/t/late-night-jamming/302)

---

<div class="post-metadata">

### Author: ![tran](https://avatars.discourse-cdn.com/v4/letter/t/dec6dc/32.png) [@tran](https://meta.discourse.org/u/tran)
#### Post date: [March 1, 2018, 2:21am UTC](https://meta.discourse.org/t/angus-events-plugin/69776/121 "2018-03-01T02:21:28Z")

</div>

@angus THX for replying. Amazing, the end date is normally now.

> [@tran](#):
>
> the title can only recognize English numbers and symbols

My language is Chinese, the title cannot be displayed in Chinese.

---

<div class="post-metadata">

### Author: ![ChrisBeach](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/chrisbeach/32/214628_2.png) [@ChrisBeach](https://meta.discourse.org/u/ChrisBeach)
#### Post date: [March 1, 2018, 4:53pm UTC](https://meta.discourse.org/t/angus-events-plugin/69776/122 "2018-03-01T16:53:40Z")

</div>

Bug report: I edited a post to add a date, and set it to be “all day”

The date was then displayed on the post with a time of “00:00” and when editing the post again, I noticed the “all day” checkbox was unticked.

---

<div class="post-metadata">

### Author: ![angus](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/angus/32/341715_2.png) [@angus](https://meta.discourse.org/u/angus)
#### Post date: [March 2, 2018, 4:31am UTC](https://meta.discourse.org/t/angus-events-plugin/69776/123 "2018-03-02T04:31:14Z")

</div>

@ChrisBeach The all day bug should be fixed now. Let me know how you go.

@adorfer @tran There were a few issues with adding to Google Calendar, some on my side, some weirdness with Google Calendar. Everything should work now.

Also, special characters should work in titles of events imported to Google Calendar now.

 ![08%20PM](https://global.discourse-cdn.com/meta/original/3X/4/d/4dc8cf28b264d10470068aaecd775daca8905bb2.png)

* * *

 ![14%20PM](https://global.discourse-cdn.com/meta/original/3X/b/0/b0b9b4bc2f57323121c7fa58900be93f1836b790.png)

---

<div class="post-metadata">

### Author: ![tran](https://avatars.discourse-cdn.com/v4/letter/t/dec6dc/32.png) [@tran](https://meta.discourse.org/u/tran)
#### Post date: [March 2, 2018, 7:23am UTC](https://meta.discourse.org/t/angus-events-plugin/69776/124 "2018-03-02T07:23:42Z")

</div>

@angus The special characters problem still exists.

 ![image](https://global.discourse-cdn.com/meta/original/3X/2/d/2d83900ab2c73253d4be160fdf485d28f743fa7a.png)

[https://www.uiters.com/t/topic/86](https://www.uiters.com/t/topic/86)

[Previous page](https://meta.discourse.org/t/angus-events-plugin/69776.md?page=5)

[Next page](https://meta.discourse.org/t/angus-events-plugin/69776.md?page=7)
