nextcloud / nextcloud/calendar

rooms availability displays slots blocked by room twice

Open
#8,657 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

0. to triage bug Feature: Scheduling
Dominant language
JavaScript
Stars
1.2k
Forks
332
Avg merge
16h 13m
Merged PRs (30d)
137

Description

Steps to reproduce
  1. Have a room
    • For example by creating it through:

      php occ calendar-resource:building:create \
        --address="Testweg 23, 12345 Berlin, Germany" \
        "Berlin office"
      
      php occ calendar-resource:story:create 1 "Second floor"
      
      php occ calendar-resource:room:create \
        --wheelchair-accessible=1 \
        --capacity=25 \
        --room-number=201 \
        --contact-person-user-id="demouser" \
        1 \
        "berlin-office-room-201" \
        "Meeting room 201" \
        "room.berlin.office.201@example.invalid" \
        "Meeting room"
      
  2. Create event A with the room "room.berlin.office.201@example.invalid" as attendee
  3. Start creating event B
  4. Search for a room
  5. Check the availability for "Meeting room 201"
Expected behavior
  • Blocker for event A is shown once.
  • Blocker for event A does not have the name "undefined".
    • I'm not sure what the expected behavior for the title is. I can think of:
      • Never show it (seem simplest solution)
      • Show it, if user has access to the event/is a participant.
Actual behavior
Image
Calendar app version

6.5.2

CalDAV-clients used

No response

Browser

No response

Client operating system

No response

Server operating system

No response

Web server

None

Database engine version

None

PHP engine version

None

Nextcloud version

No response

Updated from an older installed version or fresh install

None

List of activated apps

Nextcloud configuration

Web server error log

Log file

Browser log

Additional info

Either freeBusyResourceEventSource or freeBusyBlockedForAllEventSource seems redundant.

			return [
				freeBusyResourceEventSource(
					this.uniqueComponentId,
					this.organizer.attendeeProperty,
					this.attendees.map((a) => a.attendeeProperty),
				),
				....
				freeBusyBlockedForAllEventSource(
					this.organizer.attendeeProperty,
					this.attendees.map((a) => a.attendeeProperty),
					this.resources,
				),
			]

freeBusyResourceEventSource seems produces the blue block with name "undefined".
freeBusyBlockedForAllEventSource produces the grey block.

Intention of freeBusyResourceEventSource might have been to display time of the actual attendees (and not the selected resources).

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the room availability search using the provided occ commands, then trace the event-source construction around freeBusyResourceEventSource and freeBusyBlockedForAllEventSource. Determine why the same blocker is rendered twice and why one shows "undefined"; done means event A appears once with an appropriate title or no title, with the relevant availability behavior covered by the existing tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.