Plugin de Eventos do Angus đź“…

Thanks for all the feedback everyone. I’ll tackle it in pieces.

I’ve started by adding all day events and optional end date/times.

https://github.com/angusmcleod/discourse-events/commit/cc1cb2cdec060d63a3a6f8c7f3af96a763d9f5f6

The UI should be self explanatory.

Examples:

  1. All day event over multiple days:

    Modal:

    Label: 49%20PM

  2. Single event time without end:

    Modal:

    Label: 20%20PM

Some notes:

  • Behind the scenes, “All day” means 00:00 to 23:59 on the relevant day(s). You won’t see these times in the UI if the event is all day, but those are the times being saved to the db. This is easier to work with if we want to use the events in other formats such as calendars and ics feeds.

  • The sql query that removes past events from the agenda when the events remove past events from agenda setting has been changed slightly. It now:

    1. First checks if the event has an end and if the end is passed;

    2. then checks if the start has passed.

    This is necessary because not all events will have end times now. This means that if you have not set an end time for your event, and you have the events remove past events from agenda setting on, the event will not appear in the agenda as soon as the start time passes.

You can test it out (and see some examples I just made) here: https://discourse.angusmcleod.com.au/c/events/l/agenda

cc @allanlasser @ron_jeremy @tobiaseigen

9 curtidas