更新0801

This commit is contained in:
xyc 2025-08-01 13:43:03 +08:00
parent 24bc3c0872
commit 49a81f5fb9
2 changed files with 13 additions and 13 deletions

View File

@ -7,8 +7,8 @@ const permission = {
state: {
routes: [],
addRoutes: [],
sidebarRouters: [], // 左侧边菜单的路由,被 Sidebar/index.vue 使用
topbarRouters: [], // 顶部菜单的路由,被 TopNav/index.vue 使用
sidebarRouters: [], // 左侧边菜单的路由,被 Sidebar/file.vue 使用
topbarRouters: [], // 顶部菜单的路由,被 TopNav/file.vue 使用
},
mutations: {
SET_ROUTES: (state, routes) => {

View File

@ -289,14 +289,14 @@ import {
addBatchInspectionFile, queryTreeFolder
} from './api/file'
import driveFileUpload from '@/components/FileUpload/index.vue'
import { getAccessToken } from '@/utils/auth'
import {getAccessToken} from '@/utils/auth'
// import cos from "@/utils/cosUpload"
import cos from '@/utils/cos'
import {getLastPathSegment} from "@/utils/ruoyi";
export default {
name: 'index',
components: { driveFileUpload },
components: {driveFileUpload},
data() {
return {
uploadProgress: 0,
@ -309,7 +309,7 @@ export default {
//
ids: [],
fileList: [],
headers: { Authorization: 'Bearer ' + getAccessToken() }, //
headers: {Authorization: 'Bearer ' + getAccessToken()}, //
//
single: true,
//
@ -409,7 +409,7 @@ export default {
this.queryParams.dictType = 'repair_report_role';
break;
}
this.queryParams.fatherId= this.$route.query.folderId || null //
this.queryParams.fatherId = this.$route.query.folderId || null //
this.fatherId = this.queryParams.fatherId
this.getList()
@ -529,7 +529,7 @@ export default {
})
}
},
getRowClassName({ row }) {
getRowClassName({row}) {
console.log('返回的class', row.id === this.selectFile.id ? 'highlight-row' : '')
//
return row.id === this.selectFile.id ? 'highlight-row' : ''
@ -742,7 +742,7 @@ export default {
function traverse(nodes, parentDisabled = false) {
return nodes.map(node => {
let newNode = { ...node }
let newNode = {...node}
//
if (newNode.children && newNode.children.length > 0) {
@ -837,7 +837,7 @@ export default {
},
//
Deleteanniu(id) {
this.$modal.confirm('是否确认删除inspectionFile编号为"' + id + '"的数据项?').then(function() {
this.$modal.confirm('是否确认删除inspectionFile编号为"' + id + '"的数据项?').then(function () {
return delInspectionFile(id)
}).then(() => {
this.getList()
@ -852,7 +852,7 @@ export default {
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids
this.$modal.confirm('是否确认删除inspectionFile编号为"' + ids + '"的数据项?').then(function() {
this.$modal.confirm('是否确认删除inspectionFile编号为"' + ids + '"的数据项?').then(function () {
return delInspectionFile(ids)
}).then(() => {
this.getList()
@ -931,14 +931,14 @@ export default {
return reject()
}
this.$message.success('上传成功:' + data.Location)
this.fileList.push({ name: file.name, url: data.Location })
this.fileList.push({name: file.name, url: data.Location})
resolve()
}
)
})
},
// 使 cos-js-sdk
async uploadToCOS({ file }) {
async uploadToCOS({file}) {
const fileName = `files/${file.name}` //
cos.putObject(
{
@ -1126,7 +1126,7 @@ export default {
/* 时间样式 */
.step-time {
font-size: 14px;
//color: #666;
//color: #666;
}
/* 文件名称高亮 */