Open section1 opened 4 months ago
I do some test to see if it's easy to fix... i'm not a programmer but i found this:
--- 3rdparty/sabre/vobject/lib/FreeBusyGenerator.php-ori 2024-06-25 10:23:42.000000000 +0000
+++ 3rdparty/sabre/vobject/lib/FreeBusyGenerator.php 2024-08-02 16:20:03.981952480 +0000
@@ -376,6 +376,14 @@ class FreeBusyGenerator
}
}
+ if (isset($component->ATTENDEE)) {
+ foreach ($component->ATTENDEE as $attendee) {
+ if (str_contains($attendee, 'user@domain.tld') && 'DECLINED' === $attendee['PARTSTAT']->getValue()) {
+ break 2;
+ }
+ }
+ }
+
$times = [];
if ($component->RRULE) {
but i don't know how to solve this part:
if (str_contains($attendee, 'user@domain.tld') && 'DECLINED' === $attendee['PARTSTAT']->getValue()) {
To automatically check the real current user availability...i hard-coded my user. Sure needs a lot of work and checks etc..is a dumb POC code.
i create this patch for version 28.0.9 ... I duplicate the EventIterator with one called FreeBusyEventIterator with some changes because not sure about others calls to this iterator are affected with this changes... i don't want to break more important parts than a freebusy status.
patch: https://github.com/section1/nextcloud-stuff/blob/main/nextcloud-28.0.9-fix-declined-freebusy.patch
cc @ChristophWurst @miaulalala @SebastianKrupinski
If the declining user is using the NC UI, then I think the better solution to this would be to set the STATUS property to CANCELLED. The Sabre code already checks for a CANCELLED status. This way we don't need to create a Sabre patch and it would have the site benefit of showing up on the declining users Calendar differently.
Hi @SebastianKrupinski , thanks for the respond, In my case and what i see in issues/help forum most users use a caldav client like thunderbird or the mobile phone etc so that still will don't work as expected..
BUT taking that out i have a doubt about that approach. Example a recurrent event with 10 attendees, someone decline the next coming event the STATUS property change to CANCELLED.. the doubt i have is: the STATUS change only is reflected to that user that declined the event or all attendees ?
The STATUS should only be applied to the declining user (The user that declined).
And you are correct this approach, will not work for external clients. Problem is unless I missed something in the RFC(s), it does not specify how to handle the event on the decliners calendar, so every client handles it differently.
The STATUS should only be applied to the declining user (The user that declined).
And you are correct this approach, will not work for external clients. Problem is unless I missed something in the RFC(s), it does not specify how to handle the event on the decliners calendar, so every client handles it differently.
Be careful with how you talk about things please 🙏 there's two different properties at work here. One is the PARTSTAT
on the ATTENDEE
- which is what changes when a user declines an invitation and triggers an iTIP message REPLY
and a SEQUENCE
increase, and the other is the STATUS
property CANCELLED
on the VEVENT
which is not a significant change property and will not trigger an iTIP message nor a SEQUENCE
change.
So if you're talking about declining that is different than setting the status to cancelled
I can provide more info for the users that have the same problem: Im using this patch in a production environment and users are happy now that slots are free in declined events. Basically the patch looks for the PARTSTAT property using the email of the user when checking for the user free/busy status.. If an event or an instance of a recursive event has declined in PARTSTAT for that email that "slot" don't count as Busy.. (this has a problem for example if two users have the same email not my case..and not sure about users without email.)
The other way to free a slot of an event that you don't want to attend is asking the organizer to remove you from the event but you depend of that "manual" interaction that 80% of the time never happens. and you have users more frustrated :D
The other way is deleting the event in your calendar...but this has a problem because for recurrent events when someone makes an update(like an attendee accept/decline one of the serie) the whole event appears again in your calendar.
⚠️ This issue respects the following points: ⚠️
Bug description
When you decline an even/meet the time slot still shows as busy in free/busy availability.
Steps to reproduce
Expected behavior
Userb shows as free.
Installation method
Community Manual installation with Archive
Nextcloud Server version
28
Operating system
Debian/Ubuntu
PHP engine version
PHP 8.1
Web server
Apache (supported)
Database engine version
MariaDB
Is this bug present after an update or on a fresh install?
Fresh Nextcloud Server install
Are you using the Nextcloud Server Encryption module?
None
What user-backends are you using?
Configuration report
List of activated Apps
Nextcloud Signing status
No response
Nextcloud Logs
No response
Additional info
No response