enhancement: Enable reply box for whatsapp template message (#2082)

* remove 24-hours reply restriction in WhatsApp

* remove the console.logs

* move reply policy to separate constants file

* fix spelling mistake
This commit is contained in:
Muhsin Keloth 2021-04-12 16:15:11 +05:30 committed by GitHub
parent 7eb766a457
commit 04a9dc630a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 49 additions and 16 deletions

View file

@ -133,7 +133,7 @@ export default {
return !!this.uiSettings.enter_to_send_enabled;
},
isPrivate() {
if (this.currentChat.can_reply) {
if (this.currentChat.can_reply || this.isATwilioWhatsappChannel) {
return this.isOnPrivateNote;
}
return true;
@ -230,7 +230,7 @@ export default {
return;
}
if (canReply) {
if (canReply || this.isATwilioWhatsappChannel) {
this.replyType = REPLY_EDITOR_MODES.REPLY;
} else {
this.replyType = REPLY_EDITOR_MODES.NOTE;
@ -305,7 +305,7 @@ export default {
setReplyMode(mode = REPLY_EDITOR_MODES.REPLY) {
const { can_reply: canReply } = this.currentChat;
if (canReply) this.replyType = mode;
if (canReply || this.isATwilioWhatsappChannel) this.replyType = mode;
if (this.showRichContentEditor) {
return;
}