This commit is contained in:
kuaifan 2022-06-05 23:15:40 +08:00
parent b9b45e8e4f
commit ab24af6e79
3 changed files with 5 additions and 4 deletions

View File

@ -436,9 +436,9 @@ export default {
watch: {
'$route': {
handler (route) {
if ($A.isJson(window.__sendDialogMsg) && window.__sendDialogMsg.time > $A.Time()) {
const {msgFile, msgRecord, msgText} = window.__sendDialogMsg;
window.__sendDialogMsg = null;
if (this.$store.state.dialogMsgTransfer.time > $A.Time()) {
this.$store.state.dialogMsgTransfer.time = 0;
const {msgFile, msgRecord, msgText} = this.$store.state.dialogMsgTransfer;
this.$nextTick(() => {
if ($A.isArray(msgFile) && msgFile.length > 0) {
this.sendFileMsg(msgFile);

View File

@ -1107,7 +1107,7 @@ export default {
} else {
this.$nextTick(() => {
if (this.windowMax768) {
window.__sendDialogMsg = {
this.$store.state.dialogMsgTransfer = {
time: $A.Time() + 10,
msgText: this.msgText,
msgFile: this.msgFile,

View File

@ -66,6 +66,7 @@ const stateData = {
// 会话聊天
dialogMsgs: [],
dialogMsgTransfer: {time: 0},
dialogInputCache: $A.getStorageArray("cacheDialogInput"),
// 文件