nextcloud / calendar

📆 Calendar app for Nextcloud
https://apps.nextcloud.com/apps/calendar
GNU Affero General Public License v3.0
958 stars 235 forks source link

Allow shared (read-only) calendars as appointment conflict calendars #3786

Open ChristophWurst opened 2 years ago

ChristophWurst commented 2 years ago
**Is your feature request related to a problem? Please describe.** As a user I might have calendars shared to me by other users, e.g. a company-wide calendar. **Describe the solution you'd like** It would be nice if I could select that shared calendar for appointment conflicts as well. Then company-wide events would also block appointment slots. **Describe alternatives you've considered** N/a **Additional context** - [ ] https://github.com/nextcloud/server/issues/30068
violoncelloCH commented 2 years ago

in general, being able to chose which calendars are treated as conflict calendars for appointments would be useful!

ChristophWurst commented 2 years ago

in general, being able to chose which calendars are treated as conflict calendars for appointments would be useful!

Coming with v3.1 https://github.com/nextcloud/calendar/pull/3770

reos-rcrozier commented 2 years ago

I was about to make a feature request similar to this, but am going to comment here instead.

In our case most often Appointments are to be used for arranging meetings with an external party (who can't see shared calendars). For this reason it would be most useful to have an Appointments URL that can be a combination of the public Appointment calendars of several users.

For example, if several people in the company are trying to arrange an appointment with some external party you would ideally send them one link which provides the appointments available that work for all three employees. This would be really handy.

This seems different from what you propose because one has to set up a new Appointments set for every combination of users to be present at a meeting.

Blechlawine commented 2 years ago

would this also apply to subscription calendars as well? Or just calendars shared within nextcloud?

reos-rcrozier commented 2 years ago

@Blechlawine if you're replying to me, I was only thinking of calendars shared within Nextcloud, but actually I mean the Appointments sets shared within Nextcloud,

My idea is users can set up their own appointments sets, just as one can now, and I could somehow select from them to make the combined appointments set for several people.

Blechlawine commented 2 years ago

@reos-rcrozier I was replying to op, but what your're describing sounds very useful as well

ChristophWurst commented 2 years ago

I'm sure there are cases where subscriptions as conflict source make sense :+1:

I just don't know if the change is in scope for this ticket when someone picks it up. We can re-evaluate afterwards and create a another ticket if not.

rasos commented 1 year ago

We have an organization wide calendar with team meetings which is shared by an organization-admin account. That should be definitely be taken into account when checking for conflicts to offer free time slots.

pjrobertson commented 4 months ago

It seems like the server isse was fixed in NC 24.0.8 and 25.0.2 - does this mean that we can revisit this issue now? See https://github.com/nextcloud/server/issues/30068

ChristophWurst commented 4 months ago

https://github.com/nextcloud/server/issues/30068 was closed by a script

pjrobertson commented 4 months ago

You're right, I missed that. I was trying to investigate this today. It seems like it should actually be possible right now though, without changing the server.

Right now the calendars are taken from selectableConflictCalendars() here. This in turn gets its base calendars to filter from the store getter ownSortedCalendars().

Could we not just add a new getter/get the base calendars and then make sure not to filter out the .filter(calendar => !calendar.isSharedWithMe). I'll submit a PR with this thinking

ChristophWurst commented 4 months ago

Try but I don't think it will work. The backend logic will fail to access those calendars and therefore conflicts are not detected.

pjrobertson commented 4 months ago

I put out a PR #5934, but I think I understand what you're saying now. I'm still struggling to set up a testing environment that includes my local calendar app, so haven't been able to test if this actually works or not

ChristophWurst commented 4 months ago

You can find some resources for dev envs at https://nextcloud.com/developer

pjrobertson commented 4 months ago

Yeah, I've been through that multiple times but there's little info on testing an existing app, and when I tried it it was throwing all sorts of errors. I unfortunately don't have time to debug for half a day :(

viktorix commented 2 weeks ago

+1 🙏