Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -523,7 +523,11 @@ export default {
|| this.$t('visio.drawer.dayTimeRange', {0: formatDay(this.entry.start), 1: range});
},
showProgress() {
return this.entry.state === LIVE && !!this.entry.start;
// A meeting people joined ahead of its slot is live before its start:
// there is no elapsed time to show yet. Only a slot is compared with this
// browser's clock; a call without one starts at the server's.
return this.entry.state === LIVE && !!this.entry.start
&& (!this.entry.end || this.entry.start.getTime() <= this.now.getTime());
},
/**
* How long the meeting has been running.
Expand Down
10 changes: 8 additions & 2 deletions webapp/src/main/webapp/vue-apps/VisioDrawer/js/VisioMerge.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ const STATE_STARTED = 'started';
* <p>
* The same window decides which occurrence of a series a running call is held
* in, so the two answers cannot disagree: what the drawer calls live is what it
* lets you join.
* lets you join. A single event is not bound by it once its call is started.
*/
export const JOIN_AHEAD_MS = 15 * 60 * 1000;

Expand Down Expand Up @@ -86,6 +86,9 @@ export function normalizeEvent(event) {
key: `event-${eventId}-${occurrenceId}`,
eventId: eventId,
occurrenceId: occurrenceId,
// An occurrence of a series comes either computed (an occurrence, no id) or
// as an exceptional occurrence with an id of its own and its parent.
recurrent: !!(event.occurrence || event.parent || event.parentId || event.recurrence),
title: event.summary || '',
start: start,
end: end,
Expand Down Expand Up @@ -284,6 +287,9 @@ function isStarted(callId, startedIds) {
* claiming it would announce next week's meeting as happening now, which is the
* whole point of the attribution.
* <p>
* A single event has no other date to be confused with: its started call is its
* meeting, live however early people joined it.
* <p>
* The past side needs no bound of its own: the drawer reads only PAST_WINDOW_MS
* back, so an occurrence old enough to be a stale claim is never fetched.
*
Expand All @@ -292,7 +298,7 @@ function isStarted(callId, startedIds) {
* @returns {boolean} true when the occurrence may hold the call
*/
function canHoldCall(event, nowTime) {
return event.start.getTime() - nowTime <= JOIN_AHEAD_MS;
return !event.recurrent || event.start.getTime() - nowTime <= JOIN_AHEAD_MS;
}

/**
Expand Down
Loading