From 430f579041e4e2e76683a1c3997d0b73e914ebdd Mon Sep 17 00:00:00 2001 From: Maksim Sukharev Date: Thu, 31 Oct 2024 17:44:15 +0100 Subject: [PATCH 1/6] fix: migrate NcDateTimePicker to v-model usage Signed-off-by: Maksim Sukharev --- .../ConversationSettings/LobbySettings.vue | 28 +++++++++++-------- 1 file changed, 16 insertions(+), 12 deletions(-) diff --git a/src/components/ConversationSettings/LobbySettings.vue b/src/components/ConversationSettings/LobbySettings.vue index 6e7b07e8195..9fa425f7d19 100644 --- a/src/components/ConversationSettings/LobbySettings.vue +++ b/src/components/ConversationSettings/LobbySettings.vue @@ -24,8 +24,8 @@ + clearable />
{{ getTimeZone }}
@@ -143,16 +142,21 @@ export default { return new Date(date.getTime() + 3600000) }, - lobbyTimer() { - // A timestamp of 0 means that there is no lobby, but it would be - // interpreted as the Unix epoch by the DateTimePicker. - if (this.conversation.lobbyTimer === 0) { - return undefined - } + lobbyTimer: { + get() { + // A timestamp of 0 means that there is no lobby, but it would be + // interpreted as the Unix epoch by the DateTimePicker. + if (this.conversation.lobbyTimer === 0) { + return undefined + } - // PHP timestamp is second-based; JavaScript timestamp is - // millisecond based. - return this.conversation.lobbyTimer * 1000 + // PHP timestamp is second-based; JavaScript timestamp is + // millisecond based. + return this.conversation.lobbyTimer * 1000 + }, + set(value) { + this.saveLobbyTimer(value) + } }, dateTimePickerAttrs() { From 01d4df6197dfa5278a7a86da2a49baca69a82ab2 Mon Sep 17 00:00:00 2001 From: Maksim Sukharev Date: Fri, 1 Nov 2024 17:19:17 +0100 Subject: [PATCH 2/6] fix: migrate NcActionInput to v-model usage Signed-off-by: Maksim Sukharev --- .../MessageButtonsBar/MessageButtonsBar.vue | 30 ++++++++++--------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/src/components/MessagesList/MessagesGroup/Message/MessageButtonsBar/MessageButtonsBar.vue b/src/components/MessagesList/MessagesGroup/Message/MessageButtonsBar/MessageButtonsBar.vue index 7687fda279c..da53d321c52 100644 --- a/src/components/MessagesList/MessagesGroup/Message/MessageButtonsBar/MessageButtonsBar.vue +++ b/src/components/MessagesList/MessagesGroup/Message/MessageButtonsBar/MessageButtonsBar.vue @@ -204,11 +204,10 @@ - + :min="new Date()"> @@ -216,7 +215,7 @@ + @click.stop="setReminder(customReminderTimestamp)"> @@ -437,7 +436,7 @@ export default { frequentlyUsedEmojis: [], submenu: null, currentReminder: null, - customReminderDateTime: new Date(moment().add(2, 'hours').minute(0).second(0).valueOf()), + customReminderTimestamp: moment().add(2, 'hours').minute(0).second(0).valueOf(), } }, @@ -502,6 +501,17 @@ export default { return moment(this.message.lastEditTimestamp * 1000).format('lll') }, + customReminderDateTime: { + get() { + return new Date(this.customReminderTimestamp) + }, + set(value) { + if (value !== null) { + this.customReminderTimestamp = value.valueOf() + } + }, + }, + reminderOptions() { const currentDateTime = moment() @@ -734,14 +744,6 @@ export default { } }, - setCustomReminderDateTime(event) { - this.customReminderDateTime = new Date(event.target.value) - }, - - setCustomReminder() { - this.setReminder(this.customReminderDateTime.valueOf()) - }, - editMessage() { if (!this.isEditable) { return From 6cbb2e258a550b2b099415d8b9dea76f5623ce20 Mon Sep 17 00:00:00 2001 From: Maksim Sukharev Date: Fri, 1 Nov 2024 17:28:42 +0100 Subject: [PATCH 3/6] fix: migrate NcTextArea to v-model usage Signed-off-by: Maksim Sukharev --- src/components/AdminSettings/SIPBridge.vue | 2 +- .../Matterbridge/MatterbridgeSettings.vue | 2 +- src/components/RightSidebar/Participants/Participant.vue | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/components/AdminSettings/SIPBridge.vue b/src/components/AdminSettings/SIPBridge.vue index 93084994eac..4baee47103a 100644 --- a/src/components/AdminSettings/SIPBridge.vue +++ b/src/components/AdminSettings/SIPBridge.vue @@ -58,7 +58,7 @@ {{ t('spreed', 'Dial-in information') }} - @@ -150,11 +150,6 @@ export default { }) }, - updateSecret(value) { - this.secret = value - this.debounceUpdateServers() - }, - async updateServers() { this.loading = true diff --git a/src/components/AdminSettings/TurnServer.vue b/src/components/AdminSettings/TurnServer.vue index 9e2a381b955..969ffeb4543 100644 --- a/src/components/AdminSettings/TurnServer.vue +++ b/src/components/AdminSettings/TurnServer.vue @@ -30,14 +30,13 @@ @update:value="updateServer" /> + :label="t('spreed', 'TURN server secret')" /> Date: Fri, 1 Nov 2024 17:55:57 +0100 Subject: [PATCH 6/6] fix: migrate NcRichContenteditable to v-model usage Signed-off-by: Maksim Sukharev --- src/components/NewMessage/NewMessage.vue | 2 +- src/components/UIShared/EditableTextField.vue | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/components/NewMessage/NewMessage.vue b/src/components/NewMessage/NewMessage.vue index 4bf9ecb15dd..70a075dc41f 100644 --- a/src/components/NewMessage/NewMessage.vue +++ b/src/components/NewMessage/NewMessage.vue @@ -74,7 +74,7 @@ :text="t('spreed','Adding a mention will only notify users who did not read the message.')" />