nextcloud/calendar

Improvements for Free/Busy UI

georgehrke opened this issue Β· 87 comments

Improvements to be added:

  • Modify event time from within Free/Busy view
  • Add / Remove attendees from within Free/Busy view
  • Show role of attendee

Sorry for reuse this issue, but is it possible to get only the the busy / free information (in a public cal, for e.g.) ?

Hi, is there any progress on this? Where is the work now and what is needed to be done to have implemented free/bust feature? Thank you very much. We would really like to see this feature :) πŸ‘

No progress on this yet. Milestone is theoretically assigned (1.8.0) but if you want to step in and help coding - you are very welcome πŸ™ˆ @Laykou

@georgehrke @tcitworld do you have any work in progress or pointers? :)

No work in progress so far.

First part of the work would be the logic part:

  • dig into the CalDAV standard to see how FreeBusy requests for different users are made
  • take curl (or any other tool to send http requests) to check if these requests are implemented in the Nextcloud CalDAV server
  • if no: start implementing it in the server
  • afterwords implement a FreeBusy service (similar to https://github.com/nextcloud/calendar/blob/master/js/app/service/calendarService.js) that sends CalDAV requests to the server to gather FreeBusy data.

take curl (or any other tool to send http requests) to check if these requests are implemented in the Nextcloud CalDAV server
if no: start implementing it in the server

As far as I can remember it didn't work out of the box with Thunderbird/Lightning or Evolution clients.

This feature is a valuable one. I am willing to pay someone to implement it.

Without a free/busy implementation that Outlook can use, my wife won't share her calendar with me. She won't use Nextcloud calendar.

My wife needs to show her co-workers when she's away from the office on personal matters without revealing the matter. She can do that with Outlook by marking events as "private". She would keep her personal calendar on Nextcloud, where mine resides, if Nextcloud offered free/busy info that is compatible with Outlook.

I’m willing to throw some coins at this as well.

@talmage @silverhook You may use Bountysource to post a bounty on this issue : https://www.bountysource.com/issues/39954053-free-busy-support

@tcitworld, just threw some coin into the BountySource kitty, to get the ball rolling.

Here’s a live preview of how much is stored there right now:
Bountysource

Thanks @tcitworld! I added to the bounty.

In the DaviCal this is issue too: https://gitlab.com/davical-project/davical/issues/69
But "Free/Busy" status available directly (example link): http://calendar.davical.local/freebusy.php/username/home

I cant see free or busy my friends for evil plans!

screenshot - 21 09 2017 - 19 56 14

So the Nextcloud server supports free/busy, it now "just" needs to be shown in the UI and then πŸ₯‡

🐩

how far is the status of this ? Because I want to use the nextcloud calendar in my iCal client on my Mac. Or will it only available in the webclient view? Many thanks

@immae1 The Nextcloud CalDAV server will support FreeBusy beginning with Nextcloud 13.
That means you will be able to use FreeBusy with Thunderbird, Apple Calendar, etc. very soon.

The web client (=> FreeBusy in your browser) is currently scheduled for Calendar 1.8.0 later this year.

Great that the FreeBusy support has been realized with Nextcloud 13.
How to configure that in Outlook 2016?
What to put into the free/busy-options?

Perhaps one of the following lines?
https:// ... /3rdparty/sabre/vobject/lib/FreeBusyData.php
https:// ... /3rdparty/sabre/vobject/lib/FreeBusyGenerator.php

@scm1599 Please ask that the developers of the outlook connector plugin you are using.

Thanks
Really? I think Outlook needs to directly communicate with the FreeBusy-Server of Nextcloud 13.

By the way, I use the Outlook CalDav Synchronizer
http://caldavsynchronizer.org

We provide CalDAV Free/Busy scheduling as standardized in https://tools.ietf.org/html/rfc6638

I don't have a Windows machine, so I can't tell you what options to use in Outlook.
But as it's a CalDAV feature, you should reach out to the developers of the Outlook CalDav Synchronizer plugin.

Perhaps one of the following lines?
https:// ... /3rdparty/sabre/vobject/lib/FreeBusyData.php
https:// ... /3rdparty/sabre/vobject/lib/FreeBusyGenerator.php

That won't work, because you can't call these files directly.

OK, Thanks

If you use CalDav Syncroniser:
You find the settings for private events in CalDav Syncroniser -> Syncronisation Profiles (Advanced Settings) -> Event Mapping Configuration -> Privacy Settings.
The Flag "Map Outlook Private flag to DAV CLASS:CONFIDENTION instead of PRIVATE" seems to work fine.

Thank you. The 'Event Mapping Configuration' is an interesting option.
However, Outlook needs a web-link to the free-busy-server configured in the free-Busy options in the Outlook configuration. The big question: Which link to configure in Outlook. The link must point the Nextcloud-server that provides the free-busy information.

Does anybody have an idea?

Also Intersting how to use it in Outlook:
For Microsoft Outlook 2010 or later versions:

  1. Click the File tab, and then click Options.

  2. On the left pane, click Calendar.

  3. Click the Free/Busy Options button, click the Permissions tab, and then click Other Free/busy.

  4. Under the Internet Free/busy section, in the Search locations box, type the fully qualified path of the location that you want to search for the free/busy information. You can use any valid URL format, such as: http://... , file://\... , or ftp://... .

    Outlook supports %NAME% and %SERVER% substitutions.

    The following is an example of how to use these substitutions:
    ftp://%SERVER%/Freebusy/%NAME%.vfb

    In an Simple Mail Transfer Protocol (SMTP) address, Outlook replaces %NAME% with all the characters before the at (@) symbol and replaces %SERVER% with all the characters following the @ symbol.

  5. Click OK to exit.

I'm confused after reading through this thread. Is the Free/Busy information already available from a Nextcloud 13 Server? If yes, what is the URL to be used?

I'm very confused too. In fact I didn't find a valuable solution by now. Visibility of any single date can be edited, but no default visibility on a per calandar basis. Assuming you have a calendar with a huge ammount of entries and you share this calendar, any details are visible by default and you need to edit every single entry, right?

I'm also confused. Nextcloud definitely supports free/busy as a feature for the "Self-Hosted Nextcloud 13":
https://nextcloud.com/pr20180206/
Here it says: "... was updated to support free/busy scheduling in native calendar applications ..."

Outlook also supports this feature, as 'Mannshoch' explained above.

Why is it so difficult to use it?

@georgehrke You said that NC 13 support the Free/Busy feature. How could I use this? Is there a Tutorial or something else how I could configure my iCal installation?

@georgehrke How can a public user (via shared link) send a CalDev request to update the event to let the sender (of the shared link) know that the public user is attending this event?

I found that nextcloud does support free/busy information as specified in rfc6638.

Though, it appears that the users email addresses for both the person doing the query (the "organizer"), and any attendees you want information on, need to be set before the query will work.

Additionally the request nextcloud supports is a query that involves making a formated POST request (see https://tools.ietf.org/html/rfc6638#appendix-B.5 ), and is not an .ics file with FREEBUSY entries like what evolution (and outlook) are looking for with their "Internet free/busy URL" field.

I could probably turn my python test into a script that dumps a formatted freebusy ics file for a specific user if that'd actually help anyone.

@detrout Yes, please. I would like to try your script, because the only thing stopping me from migrating from google calendar to nextcloud is the free/busy support. For me this feature is essential and I am willing to help where I can to bring it to life. But I've never worked with CalDAV so this is new to me. Thanks anyway :)

I'm very confused too. In fact I didn't find a valuable solution by now. Visibility of any single date can be edited, but no default visibility on a per calandar basis. Assuming you have a calendar with a huge ammount of entries and you share this calendar, any details are visible by default and you need to edit every single entry, right?

I just got the same problem.
It would be very nice, to config the whole basic-calendar just to diplay every event in a busy content,if u share this.

so there is now way yet to use free/busy in outlook?

@georgehrke is one of the developers of the calendar app, he is involved in the server caldav component, he is not involved in the Outlook plugin.

I think that if he says that you (for example @simonbuehler) have to ask to the Outlook plugin developers, you could trust him.

A lot of the requests here are either about the Outlook plugin or the server.

If you need documentation for a functionality of the server, ask in the server repository.

I do not mean at all to be rude, I am only trying to help you in asking questions in the right place. This maximizes the probability of having an answer...

Before I put down money in this one, could you please describe what this feature entails?

Will there be UI components? How will they work? Would this allow outside people to schedule appointments in my calendar with a simple link? Would it be different?

@detrout did you have any success with generating a ics endpoint that could be used by outlook?

Anyone, can you please take the Outlook discussion to https://help.nextcloud.com?

This issue is about providing a web-ui for Free/Busy, not about outlook. Thx!

(We provide a Free/Busy API as standardised in RFC6638. There are no plans to implement other Free/Busy APIs. If the Outlook Plugin needs modifications to support RFC6638, please reach out to the respective developers. But this ticket / repository is really the wrong place to have this discussion)

janLo commented

Is tehre a list of clients that support this way? KOrganizer for example seems to support free/busy scheduling somehow and there is documentation how to achieve this with davical but I cannot get it to work with nextcloud.

We don't provide a freebusy.php url like Davical.

Is there a list of clients that support this way?

I have already successfully used Nextcloud's Free/Busy with Thunderbird and macOS Calendar/iOS Calendar. I don't have any information about KOrganizer, Evolution or Outlook.

If KOrganizer, as described in the link you provided, indeed only supports this freebusy.php request, please open a ticket in their bug tracker asking for proper Free/Busy support as defined in RFC6638.

Edit: Also feel free to open a feature request in https://github.com/nextcloud/server/issues to request a freebusy.php similar to Davical.

janLo commented

A bit of research and debugging reveald to me that kde-pim seems to do support caldav freebusy-events via this code. Before it retrieves the information it does a principal-search with the email of the selected user:

<?xml version="1.0" encoding="utf-8"?>
<principal-property-search xmlns="DAV:">
 <property-search xmlns="DAV:">
  <prop xmlns="DAV:">
   <calendar-user-address-set xmlns="urn:ietf:params:xml:ns:caldav"/>
  </prop>
  <match xmlns="DAV:">user@example.com</match>
 </property-search>
 <prop xmlns="DAV:">
  <schedule-inbox-URL xmlns="urn:ietf:params:xml:ns:caldav"/>
 </prop>
</principal-property-search>

... which NC answerts with a HTTP 400:

<?xml version="1.0" encoding="utf-8"?>
<d:error xmlns:d="DAV:" xmlns:s="http://sabredav.org/ns">
  <s:exception>Sabre\DAV\Exception\BadRequest</s:exception>
  <s:message>Depth must be 0</s:message>
</d:error>

this lets the kde-pim believe that there is no scheduling information. Any ideas on which side the error sits?

@janLo This seems to be a bug in kde-pim.

From RFC 3744 Section 9.4:

 This report is only defined when the Depth header has value "0";

The error message <s:message>Depth must be 0</s:message> lets me assume that kde-pim sends a Depth of 1 or Infinity.

janLo commented

Ok, it seems to be 1 by default. The tcpdump actually also says its set to 1. Thank you.

@janLo Can you please report this in their bugtracker? :) Thx!

janLo commented

I'm trying to find ut, which tracker to use for the pim components. But even if I fix this I do not get a proper result. It seems that response to the request is empty:

Status: 207 Multi-Status
X-Powered-By: PHP/7.2.11
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate
Pragma: no-cache
Set-Cookie: oc_sessionPassphrase=xxx; path=/; secure; HttpOnly
X-Frame-Options: SAMEORIGIN
Set-Cookie: __Host-nc_sameSiteCookielax=true; path=/; httponly;secure; expires=Fri, 31-Dec-2100 23:59:59 GMT; SameSite=lax
Set-Cookie: __Host-nc_sameSiteCookiestrict=true; path=/; httponly;secure; expires=Fri, 31-Dec-2100 23:59:59 GMT; SameSite=strict
Content-Security-Policy: default-src 'none';
Set-Cookie: xxx; path=/; secure; HttpOnly
Set-Cookie: cookie_test=test; expires=Wed, 24-Oct-2018 14:40:35 GMT; Max-Age=3600
Content-Type: application/xml; charset=utf-8
Vary: Brief,Prefer

<?xml version="1.0"?>
<d:multistatus xmlns:d="DAV:" xmlns:s="http://sabredav.org/ns" xmlns:cal="urn:ietf:params:xml:ns:caldav" xmlns:cs="http://calendarserver.org/ns/" xmlns:card="urn:ietf:params:xml:ns:carddav" xmlns:oc="http://owncloud.org/ns" xmlns:nc="http://nextcloud.org/ns"/>

The email in the response is one of the users email addressses in NC.

janLo commented

There is also still bugs.kde.org around. I've asked in the IRC and hope of an answer.

Besides that I'm interested why the result is empty if I fix the depth issue - and what to actually expect here if I use an E-Mail-Adresse that is put in a profile of a NC user or one in the form @.

Yeah, but the last time I asked someone from KDEPIM at Akademy (KDE’s annual conference) they said that (at least a subset of) the KDEPIM team doesn’t even read the bugs.kde.org any more.

That was several years ago, so this may have changed. I’m pretty sure at least Daniel Vratil follows b.k.o. actively. Could even be up his alley.

Perhaps best would be if you put it on b.k.o and post the link here (happy to +1 the bug there) and if nothing happens for a while we can try to put it on p.k.o as well.

@janLo Searching for the property calendar-user-address-set is not supported yet, i opened an issue: nextcloud/server#12033

@georgehrke : I think the title of this issue should more clearly reflect that this feature request is for the Web-UI component. Like others, I have also been trying to figure out how to use free-busy from Thunderbird/lightning with no success. If there is information on how to do that, I would appreciate a link, as I can't figure out what link I should give others to subscribe to my free-busy.

Thank you,

tarek : )

If there is information on how to do that, I would appreciate a link, as I can't figure out what link I should give others to subscribe to my free-busy.

There is no link to give to other users. In the scheduling dialog of Thunderbird you can just enter other user's email addresses and their free/busy info will show up.

There seems some misunderstandings about how free/busy work and what it does.
If I enter an username, how do thunderbird get the free/busy information of this user?
Is it only able if the Maildomain reflect the nextcloud domain? e.g: user@example.com -> http://www.example.com/nextcloud/ ?

Somehow I thought about a WebDAV link which contain reduced Information. Or the mentioned WebUI which allow showing reduced Data on nextcloud and could be shared by Link.

If I enter an username, how do thunderbird get the free/busy information of this user?

As far as I can tell you can't enter usernames in thunderbird, you have to enter the email-address.
This email-address is the one set by the admin in the user-management or set by the user in the personal settings. Other clients allow you to enter the display name.

There is a screenshot of the Thunderbird scheduling dialog in nextcloud/server#11822

Oh sorry. I mixed up "username" with "mail-address". I use Nextcloud in a way that the username is equal with the users Mail address.

Hi there. Here is an issue with event organizer handling. It doesn't checked against Free/Busy status. Even if organizer is specified explicitly as participant of his event.
For example, here is Event 1 scheduled on 9am on Monday by "Mr. X". If somebody wants to create Event 2 at the same time where "Mr. X" is participant, Thunderbird doesn't display dark-blue busy segment in "Mr. X" line.

Hi there. Here is an issue with event organizer handling. It doesn't checked against Free/Busy status. Even if organizer is specified explicitly as participant of his event.
For example, here is Event 1 scheduled on 9am on Monday by "Mr. X". If somebody wants to create Event 2 at the same time where "Mr. X" is participant, Thunderbird doesn't display dark-blue busy segment in "Mr. X" line.

It is valid only for shared calendars. Personal cloud calendar works well in regards to organizer occupancy detection.

@nikchuk Please open up a proper issue in https://github.com/nextcloud/server/issues and mention me. Thx

@nikchuk Please open up a proper issue in https://github.com/nextcloud/server/issues and mention me. Thx

@georgehrke done
nextcloud/server#14319

Pull-Request: #1731

Edit: I won't directly close this issue after that PR is merged, because there are a few further requirements i have, which are not yet implemented. E.g. being able to move the event from within the Free/Busy view.

#1731 brings a first implementation and was just merged. As said earlier, let's keep this open to track further improvements.

Hello, the Free/Busy function is already at this stage really very successful and will greatly enrich our cooperation in the team. Many thanks for this!
For the further development I would like to make a design proposal. While the Free/Busy window is open, the calendar cannot be used. Since you can only see the date in the Free/Busy overview through the calendar days, you can quickly lose track of which day you are on.
In this case, it would help the overview a lot if the Free/Busy window would show the weekday as well as the date.

Any help needed in this one?

Any help needed in this one?

Sure, any time :) Are you still interested? I'm currently also polishing this and that on the free/busy UI :)

Related to free/busy I think it would also be beneficial if there was a way to define office hours for a Nextcloud account. This isn't directly a feature of the free/busy view, but more likely something to be added to Nextcloud server and the DAV app. Because then this will also work for those who don't actually use the Calendar app but just Nextcloud as a caldav server.

I'll have to figure out how this could be integrated and then I might open a ticket for this feature in the server repo.

Edit: I'm onto something: https://sabre.io/dav/scheduling/

Since sabre/dav 3.1 availability is supported. This feature allows users to specify for example when their working hours are, such as 9am to 5pm on a daily basis.

That's what I've been looking for. Looks like what's needed is extending \OCA\DAV\CalDAV\Schedule\Plugin::isAvailableAtTime.

Edit 2: we have the property storage already, so we "just" need a way for users to fill the info as described at sabre-io/dav#1127 (comment)

To do it on the server you update the propertystorage table with the information you need:

  • path => uri to users inbox (calendars/princpal/inbox)
  • name => {urn:ietf:params:xml:ns:caldav}calendar-availability
  • valuetype => 1
  • value => BEGIN:VCALENDAR ... your vavailability component

Edit 3: opened a ticket in server to address this limitation in our custom property back-end nextcloud/server#27421

Coming from #531, I'm asking me if this Free/Busy feature will reach my needs:

Given a calendar named "Work" owned by user "Alice"
And "Alice" wants to share her calendar "Work" with "Bob" allowing him to see only Free/Busy status
And "Alice" wants to share her calendar "Work" with "Colin" allowing him to see all event details.

Is this scenario possible with this feature?

Scenario: Share one calendar with multiple users and various permissions.

It's possible. You don't have to share your calendar with others for them to see you availability.

You don't have to share your calendar with others for them to see you availability.

Interesting! Do you know if its possible for a user (ie. "Bob" in my example) to see "Alice" calendar through CalDAV without share?

The contents of the calendar are only visible with a share.

Do you know if its possible for a user to see availability though CalDAV?

Yes, that's the whole free-busy feature.

Let's use https://help.nextcloud.com/c/apps/calendar/42 for all further questions.

I just noticed that the todo list in this ticket id done. How shall we proceed? There is a bounty on the ticket. Are the original backers still around?

Add / Remove attendees from within Free/Busy view

Wait. We don't have this. We actually have none of the items. They were checked prematurely.

Those controls/edits are possible in the event UI, but not in the free/busy UI.

hi, is this still available to pick up?

@0xc0Der Feel free to!

hi, I started working on it.

At first I had problem installing the deps. with make dev-setup. but, after removing package-lock.json file, it worked fine.

After running make watch-js, I couldn't find the dev server. on what port is it?

@0xc0Der Please use the forum for help with setting up a development environment: https://help.nextcloud.com/c/dev/11

xeruf commented

Also it is quite cumbersome having to enter them for each day, I would like to be able to define them once and then select a date range, maybe add a power-input that uses osm date range syntax?

I had thought the NExtcloud Hub 6 would implement these features as they are related to meetings.

@hamza221 Some mockups which might be helpful :)

image

Differences from current free/busy view:

  • Use components for all the elements (eg, date picker, today/previous day/next day buttons)
  • Add a heading "Find a time"
  • Add the time and time zone below the date in the top left corner
  • Nice-to-haves:
    • The "guide" for the color (currently below the free/busy section) can be shifted into a small help section on the top right, which on hover opens a tooltip showing the guide
    • change the colors:
      • busy: --color-error in 0.3 opacity
      • out of office/unavailable: --color-background-darker
      • busy tentatively: --color-warning in 0.3 opacity
      • unknown: --color-info in 0.3 opacity

New features:

  • Allow selecting different times in the modal itself: the selected time is indicated by the border (2px solid --color-primary-element with --border-radius)
  • Selected time is also reflected in the top left date and time
  • Show detailed attendees: Attendee names are shown as well as avatar and role, similar to how it's shown in the attendee list in the sidebar
  • Add and remove attendees: Add attendees via a select component, similar to the attendee list in the sidebar,
  • newly added attendees are shown at the bottom
  • Remove attendees using a close button
  • A done button to save changes

ccing @nextcloud/designers for feedback :)

Very cool @nimishavijay, looks great! :) Only 3 things come to mind:

  • Scroll point: Currently when opening the free/busy modal, it always starts at midnight. Instead, it should scroll so the current time slot is in the middle. If it’s a full-day event, it could start at e.g. 8/9/10 AM, something of the sort. (If the person has out of office set, at their start of day for example)
  • Color contrast: We need to make sure that the out of office, busy etc. blocks have proper contrast and/or are understandable without color. E.g. for out of office we could use grey with diagonal hatch pattern lines, and for busy we could use the red with diagonal criss-cross lines.
  • Width: Since this element will most likely always scroll horizontally, it would be good to give it more space to the sides. Currently it is a box inside the modal, but it could also extend to the left and right edge (the text on the left should still be aligned with the other text of course). This is mostly a detail though, and least important of the points. :)

Currently the date indicated in the top left corner is the date shown on the fullcalendar component, not the actual event date. so it's a bit unclear what time to show
@nimishavijay

As discussed we will try to keep the interactivity inside the fullcalendar component to a minimum because of technical limitations. Updated mockups:

image

Wow, thats going to be a evry nifty feature, Now i cant wait for Hub 8 to be release