|
|
@ -418,6 +418,7 @@ export default { |
|
|
this.moveChatToTop(); |
|
|
this.moveChatToTop(); |
|
|
// 借助file对象保存 |
|
|
// 借助file对象保存 |
|
|
file.msgInfo = msgInfo; |
|
|
file.msgInfo = msgInfo; |
|
|
|
|
|
file.chat = this.chat; |
|
|
// 滚到最低部 |
|
|
// 滚到最低部 |
|
|
this.scrollToBottom(); |
|
|
this.scrollToBottom(); |
|
|
return true; |
|
|
return true; |
|
|
@ -430,13 +431,13 @@ export default { |
|
|
msgInfo.loadStatus = 'ok'; |
|
|
msgInfo.loadStatus = 'ok'; |
|
|
msgInfo.id = m.id; |
|
|
msgInfo.id = m.id; |
|
|
this.isReceipt = false; |
|
|
this.isReceipt = false; |
|
|
this.chatStore.insertMessage(msgInfo, this.chat); |
|
|
this.chatStore.insertMessage(msgInfo, file.chat); |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
onUploadImageFail(file, err) { |
|
|
onUploadImageFail(file, err) { |
|
|
let msgInfo = JSON.parse(JSON.stringify(file.msgInfo)); |
|
|
let msgInfo = JSON.parse(JSON.stringify(file.msgInfo)); |
|
|
msgInfo.loadStatus = 'fail'; |
|
|
msgInfo.loadStatus = 'fail'; |
|
|
this.chatStore.insertMessage(msgInfo, this.chat); |
|
|
this.chatStore.insertMessage(msgInfo, file.chat); |
|
|
}, |
|
|
}, |
|
|
onUploadFileBefore(file) { |
|
|
onUploadFileBefore(file) { |
|
|
// 检查是否被封禁 |
|
|
// 检查是否被封禁 |
|
|
@ -469,6 +470,7 @@ export default { |
|
|
this.moveChatToTop(); |
|
|
this.moveChatToTop(); |
|
|
// 借助file对象保存 |
|
|
// 借助file对象保存 |
|
|
file.msgInfo = msgInfo; |
|
|
file.msgInfo = msgInfo; |
|
|
|
|
|
file.chat = this.chat; |
|
|
// 滚到最低部 |
|
|
// 滚到最低部 |
|
|
this.scrollToBottom(); |
|
|
this.scrollToBottom(); |
|
|
return true; |
|
|
return true; |
|
|
@ -486,13 +488,13 @@ export default { |
|
|
msgInfo.loadStatus = 'ok'; |
|
|
msgInfo.loadStatus = 'ok'; |
|
|
msgInfo.id = m.id; |
|
|
msgInfo.id = m.id; |
|
|
this.isReceipt = false; |
|
|
this.isReceipt = false; |
|
|
this.chatStore.insertMessage(msgInfo, this.chat); |
|
|
this.chatStore.insertMessage(msgInfo, file.chat); |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
onUploadFileFail(file, res) { |
|
|
onUploadFileFail(file, res) { |
|
|
let msgInfo = JSON.parse(JSON.stringify(file.msgInfo)); |
|
|
let msgInfo = JSON.parse(JSON.stringify(file.msgInfo)); |
|
|
msgInfo.loadStatus = 'fail'; |
|
|
msgInfo.loadStatus = 'fail'; |
|
|
this.chatStore.insertMessage(msgInfo, this.chat); |
|
|
this.chatStore.insertMessage(msgInfo, file.chat); |
|
|
}, |
|
|
}, |
|
|
onDeleteMessage(msgInfo) { |
|
|
onDeleteMessage(msgInfo) { |
|
|
uni.showModal({ |
|
|
uni.showModal({ |
|
|
|