mirror of
https://github.com/kuaifan/dootask.git
synced 2025-12-12 19:35:50 +00:00
no message
This commit is contained in:
parent
e7f2c8fbde
commit
43ff98353d
@ -22,6 +22,10 @@ import {mapState} from "vuex";
|
||||
export default {
|
||||
name: 'DialogUpload',
|
||||
props: {
|
||||
dialogId: {
|
||||
type: Number,
|
||||
default: 0
|
||||
},
|
||||
maxSize: {
|
||||
type: Number,
|
||||
default: 204800
|
||||
@ -36,7 +40,7 @@ export default {
|
||||
},
|
||||
|
||||
computed: {
|
||||
...mapState(['userToken', 'dialogId']),
|
||||
...mapState(['userToken']),
|
||||
|
||||
headers() {
|
||||
return {
|
||||
|
||||
@ -73,6 +73,7 @@
|
||||
<DialogUpload
|
||||
ref="chatUpload"
|
||||
class="chat-upload"
|
||||
:dialog-id="dialogId"
|
||||
@on-progress="chatFile('progress', $event)"
|
||||
@on-success="chatFile('success', $event)"
|
||||
@on-error="chatFile('error', $event)"/>
|
||||
@ -277,11 +278,11 @@ export default {
|
||||
break;
|
||||
|
||||
case 'error':
|
||||
this.tempMsgs = this.tempMsgs.filter(({id}) => id != tempId)
|
||||
this.tempMsgs = this.tempMsgs.filter(({id}) => id != file.tempId)
|
||||
break;
|
||||
|
||||
case 'success':
|
||||
this.tempMsgs = this.tempMsgs.filter(({id}) => id != tempId)
|
||||
this.tempMsgs = this.tempMsgs.filter(({id}) => id != file.tempId)
|
||||
this.sendSuccess(file.data)
|
||||
break;
|
||||
}
|
||||
|
||||
6
resources/assets/js/store/actions.js
vendored
6
resources/assets/js/store/actions.js
vendored
@ -600,7 +600,7 @@ export default {
|
||||
state[key].push(data);
|
||||
}
|
||||
//
|
||||
if (data.parent_id) {
|
||||
if (index > -1 && data.parent_id) {
|
||||
dispatch("getTaskOne", data.parent_id);
|
||||
}
|
||||
if (data.is_update_complete) {
|
||||
@ -866,6 +866,10 @@ export default {
|
||||
state.taskFiles.push(data)
|
||||
}
|
||||
})
|
||||
dispatch("saveTask", {
|
||||
id: task_id,
|
||||
file_num: result.data.length
|
||||
});
|
||||
resolve(result)
|
||||
}).catch(e => {
|
||||
console.error(e);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user