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

Allow any calendar the user has access to, to be selected for the 'conflict calendar' #5934

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

pjrobertson
Copy link
Contributor

This is an attempted fix for #3786

Any calendar should be selectable for the 'conflict calendars', even if the user doesn't have write access to it. (e.g. a company has a 'holidays' calendar that a user should be able to select for conflicts.

Copy link

github-actions bot commented May 4, 2024

Hello there,
Thank you so much for taking the time and effort to create a pull request to our Nextcloud project.

We hope that the review process is going smooth and is helpful for you. We want to ensure your pull request is reviewed to your satisfaction. If you have a moment, our community management team would very much appreciate your feedback on your experience with this PR review process.

Your feedback is valuable to us as we continuously strive to improve our community developer experience. Please take a moment to complete our short survey by clicking on the following link: https://cloud.nextcloud.com/apps/forms/s/i9Ago4EQRZ7TWxjfmeEpPkf6

Thank you for contributing to Nextcloud and we hope to hear from you soon!

Copy link

codecov bot commented May 8, 2024

Codecov Report

Attention: Patch coverage is 0% with 7 lines in your changes missing coverage. Please review.

Project coverage is 23.67%. Comparing base (692ea9e) to head (67d1435).
Report is 2 commits behind head on main.

Files Patch % Lines
src/store/calendars.js 0.00% 4 Missing ⚠️
src/components/AppointmentConfigModal.vue 0.00% 3 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##               main    #5934      +/-   ##
============================================
- Coverage     23.67%   23.67%   -0.01%     
  Complexity      457      457              
============================================
  Files           249      249              
  Lines         11774    11778       +4     
  Branches       2203     2204       +1     
============================================
  Hits           2788     2788              
- Misses         8669     8673       +4     
  Partials        317      317              
Flag Coverage Δ
javascript 15.25% <0.00%> (-0.01%) ⬇️
php 59.53% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@ChristophWurst ChristophWurst added 3. to review Waiting for reviews enhancement New feature request labels Jul 31, 2024
…he 'conflict' calendar

Signed-off-by: Patrick Robertson <[email protected]>
Signed-off-by: Richard Steinmetz <[email protected]>
@st3iny st3iny force-pushed the conflictCalendars branch from fc98cfd to 67d1435 Compare August 6, 2024 08:50
Copy link
Member

@st3iny st3iny left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tested this and the frontend parts work. However, incoming shared calendars are not considered by the backend when calculating slots during booking.

The CalDAV backend inside server code has to be changed to fix this as far as I can see.

Conflict calendars are queried from the backend by their URIs but shared calendars are stored in another table oc_dav_shares. So they won't be listed and thus no slots will be blocked by events in incoming shared (read-only) calendars

https://github.com/nextcloud/server/blob/eeb6ddb176adc7488b74d004dceafee960603ebc/apps/dav/lib/CalDAV/CalDavBackend.php#L613-L617

@miaulalala
Copy link
Contributor

I tested this and the frontend parts work. However, incoming shared calendars are not considered by the backend when calculating slots during booking.

The CalDAV backend inside server code has to be changed to fix this as far as I can see.

Conflict calendars are queried from the backend by their URIs but shared calendars are stored in another table oc_dav_shares. So they won't be listed and thus no slots will be blocked by events in incoming shared (read-only) calendars

nextcloud/server@eeb6ddb/apps/dav/lib/CalDAV/CalDavBackend.php#L613-L617

Are you sure? https://github.com/nextcloud/server/blob/9d4b9440986afddc28dad99c7987f9c31513ae9f/apps/dav/lib/CalDAV/CalendarProvider.php#L37 should already search shared calendars

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3. to review Waiting for reviews enhancement New feature request feedback-requested
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants