perf: 优化删除文章和移动端删除文件

This commit is contained in:
jmal 2024-07-10 10:05:17 +08:00
parent 05065e7a40
commit 34bdd488e9
3 changed files with 5 additions and 3 deletions

View File

@ -3240,7 +3240,7 @@ export default {
// 根据权限设置菜单 // 根据权限设置菜单
this.setMenusByPermission(row) this.setMenusByPermission(row)
} else { } else {
if (row.suffix && row.suffix === 'md') { if (row.suffix && row.suffix === 'md' && this.queryFileType !== 'trash') {
this.menus.splice(2, 0, { this.menus.splice(2, 0, {
iconClass: 'menu-edit1', iconClass: 'menu-edit1',
label: '编辑', label: '编辑',

View File

@ -670,7 +670,8 @@ export default {
api.delete({ api.delete({
currentDirectory: this.rowContextData.path, currentDirectory: this.rowContextData.path,
username: this.$store.state.user.name, username: this.$store.state.user.name,
fileIds: fileIds fileIds: fileIds,
sweep: true
}).then(() => { }).then(() => {
// 刷新列表 // 刷新列表
this.getFileList() this.getFileList()

View File

@ -300,7 +300,8 @@ export default {
api.delete({ api.delete({
currentDirectory: '', currentDirectory: '',
username: this.$store.state.user.name, username: this.$store.state.user.name,
fileIds: fileIds fileIds: fileIds,
sweep: true
}).then(() => { }).then(() => {
// 移除列表 // 移除列表
this.getArticleList() this.getArticleList()