|
@@ -1153,7 +1153,14 @@ export default { |
|
|
tempName = targetFile.archName + ` - 副本(${ ++ nowNum})`; |
|
|
tempName = targetFile.archName + ` - 副本(${ ++ nowNum})`; |
|
|
isExists = this.workFileList.find(file => file.archName === tempName); |
|
|
isExists = this.workFileList.find(file => file.archName === tempName); |
|
|
} |
|
|
} |
|
|
copyFile.archName = tempName; |
|
|
|
|
|
|
|
|
let hour = '0' + new Date().getHours(); |
|
|
|
|
|
let minute ='0' + new Date().getMinutes(); |
|
|
|
|
|
let seconds = '0' + new Date().getSeconds(); |
|
|
|
|
|
hour = hour.substr(hour.length-2); |
|
|
|
|
|
minute = minute.substr(minute.length-2); |
|
|
|
|
|
seconds = seconds.substr(seconds.length-2); |
|
|
|
|
|
|
|
|
|
|
|
copyFile.archName = tempName + '-' + hour + minute + seconds; |
|
|
copyFile.modifyUserId = sessionStorage.userId; |
|
|
copyFile.modifyUserId = sessionStorage.userId; |
|
|
copyFile.modifyTime = new Date(); |
|
|
copyFile.modifyTime = new Date(); |
|
|
copyFile.createUserId = sessionStorage.userId; |
|
|
copyFile.createUserId = sessionStorage.userId; |
|
@@ -1163,7 +1170,7 @@ export default { |
|
|
const addFileRes = await services.addFile(copyFile); |
|
|
const addFileRes = await services.addFile(copyFile); |
|
|
this.fetchFolderFiles(); |
|
|
this.fetchFolderFiles(); |
|
|
}, |
|
|
}, |
|
|
deleteFileClick(fileId, createUserId, archName) { |
|
|
|
|
|
|
|
|
deleteFileClick(fileId, createUserId, archName, ipfscid) { |
|
|
var thisApp = this; |
|
|
var thisApp = this; |
|
|
if (createUserId != sessionStorage.userId) { |
|
|
if (createUserId != sessionStorage.userId) { |
|
|
thisApp.$notify({ |
|
|
thisApp.$notify({ |
|
@@ -1189,6 +1196,12 @@ export default { |
|
|
offset: 100, |
|
|
offset: 100, |
|
|
duration: 2500, |
|
|
duration: 2500, |
|
|
}); |
|
|
}); |
|
|
|
|
|
for(let key in thisApp.localFileHashMap) { |
|
|
|
|
|
if(thisApp.localFileHashMap[key] === ipfscid) { |
|
|
|
|
|
delete thisApp.localFileHashMap[key]; |
|
|
|
|
|
break; |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
thisApp.fetchFolderFiles(); |
|
|
thisApp.fetchFolderFiles(); |
|
|
} |
|
|
} |
|
|
}) |
|
|
}) |
|
|