接口项更改
This commit is contained in:
parent
f722ecea6e
commit
f7a3023629
@ -36,4 +36,12 @@ export function storagesBytype(params:any) {
|
|||||||
method: 'get',
|
method: 'get',
|
||||||
params:params
|
params:params
|
||||||
});
|
});
|
||||||
|
}
|
||||||
|
//查询存储元内容
|
||||||
|
export function storagesType(params:any) {
|
||||||
|
return request({
|
||||||
|
url: '/admin/storagesType',
|
||||||
|
method: 'get',
|
||||||
|
params:params
|
||||||
|
});
|
||||||
}
|
}
|
@ -3,6 +3,7 @@ import { ElMessageBox, ElMessage } from "element-plus";
|
|||||||
import { ref,reactive,computed,nextTick,watch} from "vue";
|
import { ref,reactive,computed,nextTick,watch} from "vue";
|
||||||
import {uploadFileReq} from "@/api/file-operator";
|
import {uploadFileReq} from "@/api/file-operator";
|
||||||
import axios from "axios";
|
import axios from "axios";
|
||||||
|
import { storagesType } from "@/api/storage";
|
||||||
import common from "@/components/file/common";
|
import common from "@/components/file/common";
|
||||||
import {removeDuplicateSlashes} from "fast-glob/out/managers/patterns";
|
import {removeDuplicateSlashes} from "fast-glob/out/managers/patterns";
|
||||||
import { useEventBus } from '@vueuse/core';
|
import { useEventBus } from '@vueuse/core';
|
||||||
@ -444,20 +445,25 @@ export default function useFileUpload() {
|
|||||||
let s3UploadType = common.storageType.s3Type;
|
let s3UploadType = common.storageType.s3Type;
|
||||||
let onedriveUploadType = common.storageType.micrsoftType;
|
let onedriveUploadType = common.storageType.micrsoftType;
|
||||||
let storagea
|
let storagea
|
||||||
if( param.storageKey === 'local'||param.storageKey === 'sdlocal' ){
|
storagesType({key:param.storageKey}).then((name)=>{
|
||||||
storagea = 'local'
|
console.log(name.data.type)
|
||||||
}else if( param.storageKey === 'minio'){
|
storagea = name.data.type
|
||||||
storagea = 'minio'
|
if (proxyUploadType.includes( storagea)) {
|
||||||
}
|
fileProxyUpload(file, res.data, fileIndex);
|
||||||
if (proxyUploadType.includes( storagea)) {
|
} else if (s3UploadType.includes( storagea)) {
|
||||||
fileProxyUpload(file, res.data, fileIndex);
|
s3FileUpload(file, res.data, fileIndex);
|
||||||
} else if (s3UploadType.includes( storagea)) {
|
} else if (onedriveUploadType.includes( storagea)) {
|
||||||
s3FileUpload(file, res.data, fileIndex);
|
onedriveUpload(file, res.data, fileIndex);
|
||||||
} else if (onedriveUploadType.includes( storagea)) {
|
} else if ( storagea === 'upyun') {
|
||||||
onedriveUpload(file, res.data, fileIndex);
|
upyunFileUpload(file, res.data, fileIndex);
|
||||||
} else if ( storagea === 'upyun') {
|
}
|
||||||
upyunFileUpload(file, res.data, fileIndex);
|
})
|
||||||
}
|
// if( param.storageKey === 'local' ){
|
||||||
|
// storagea = 'local'
|
||||||
|
// }else if( param.storageKey === 'minio'){
|
||||||
|
// storagea = 'minio'
|
||||||
|
// }
|
||||||
|
|
||||||
}).catch((err) => {
|
}).catch((err) => {
|
||||||
baseOnUploadError(fileIndex, err)
|
baseOnUploadError(fileIndex, err)
|
||||||
});
|
});
|
||||||
|
@ -35,6 +35,10 @@ const props = defineProps({
|
|||||||
type: String,
|
type: String,
|
||||||
required: true
|
required: true
|
||||||
},
|
},
|
||||||
|
taskId: {
|
||||||
|
type: String,
|
||||||
|
required: true
|
||||||
|
},
|
||||||
});
|
});
|
||||||
const statusMessage = ref('')
|
const statusMessage = ref('')
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
@ -88,7 +92,7 @@ function convertParagraphsToNewlines(html) {
|
|||||||
// 保存文件内容
|
// 保存文件内容
|
||||||
const saveCcontent = () => {
|
const saveCcontent = () => {
|
||||||
const content = convertParagraphsToNewlines(editor.value.getHTML())
|
const content = convertParagraphsToNewlines(editor.value.getHTML())
|
||||||
saveContent({ id: props.rowId, content: content }).then((res) => {
|
saveContent({ id: props.rowId, content: content,taskId:props.taskId}).then((res) => {
|
||||||
loadContent()
|
loadContent()
|
||||||
ElMessage.success('保存成功')
|
ElMessage.success('保存成功')
|
||||||
})
|
})
|
||||||
|
@ -43,6 +43,10 @@ const props = defineProps({
|
|||||||
type: String,
|
type: String,
|
||||||
default: false
|
default: false
|
||||||
},
|
},
|
||||||
|
taskId: {
|
||||||
|
type: String,
|
||||||
|
required: true
|
||||||
|
},
|
||||||
});
|
});
|
||||||
|
|
||||||
// 配置项
|
// 配置项
|
||||||
@ -199,7 +203,7 @@ const handleEdit = (rowIndex, colIndex, event) => {
|
|||||||
const saveChanges = () => {
|
const saveChanges = () => {
|
||||||
// 构造表格数据(示例使用\t分隔)
|
// 构造表格数据(示例使用\t分隔)
|
||||||
// const csvData = rawData.map(row => row.join('\t')).join('\n');
|
// const csvData = rawData.map(row => row.join('\t')).join('\n');
|
||||||
batchModify({ id: props.rowId, modifications: tabledata.value }).then((res) => {
|
batchModify({ id: props.rowId, modifications: tabledata.value,taskId:props.taskId }).then((res) => {
|
||||||
ElMessage.success('保存成功')
|
ElMessage.success('保存成功')
|
||||||
if (props.fileUrl) {
|
if (props.fileUrl) {
|
||||||
abortLoading();
|
abortLoading();
|
||||||
|
@ -51,6 +51,7 @@ onBeforeUnmount(() => {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
const projectId = ref()
|
const projectId = ref()
|
||||||
|
const storageKey:any = ref()
|
||||||
//websocket
|
//websocket
|
||||||
let ws1
|
let ws1
|
||||||
function setupWebSocket() {
|
function setupWebSocket() {
|
||||||
@ -99,11 +100,14 @@ const vMove = {
|
|||||||
|
|
||||||
const projectArr = ref([])
|
const projectArr = ref([])
|
||||||
const projectName = ref('')
|
const projectName = ref('')
|
||||||
|
const localStorageId = ref('')
|
||||||
//获取所有项目
|
//获取所有项目
|
||||||
function getProject() {
|
function getProject() {
|
||||||
projectList().then((res: any) => {
|
projectList().then((res: any) => {
|
||||||
projectArr.value = res.data
|
projectArr.value = res.data
|
||||||
projectId.value = projectArr.value[0].id
|
projectId.value = projectArr.value[0].id
|
||||||
|
storageKey.value = projectArr.value[0].key
|
||||||
|
localStorageId.value = projectArr.value[0].localStorageId
|
||||||
projectName.value = projectArr.value[0].projectName
|
projectName.value = projectArr.value[0].projectName
|
||||||
ws1 = new WebSocket(userStore.WebSocketUrl + '/websocket/' + 'projectId_' + projectId.value)
|
ws1 = new WebSocket(userStore.WebSocketUrl + '/websocket/' + 'projectId_' + projectId.value)
|
||||||
setupWebSocket()
|
setupWebSocket()
|
||||||
@ -146,6 +150,8 @@ const filePath = ref('')
|
|||||||
function gettreedata() {
|
function gettreedata() {
|
||||||
treeloading.value = true
|
treeloading.value = true
|
||||||
treeForm.value.projectId = projectId.value
|
treeForm.value.projectId = projectId.value
|
||||||
|
let keyar = projectArr.value.find(item => item.localStorageId === localStorageId.value);
|
||||||
|
storageKey.value = keyar.key
|
||||||
getNodesTree(treeForm.value).then((res: any) => {
|
getNodesTree(treeForm.value).then((res: any) => {
|
||||||
treedata.value = res.data
|
treedata.value = res.data
|
||||||
treeloading.value = false
|
treeloading.value = false
|
||||||
@ -361,7 +367,7 @@ function openFile() {
|
|||||||
titleon.value = false
|
titleon.value = false
|
||||||
title.value = "上传文件"
|
title.value = "上传文件"
|
||||||
localStorage.setItem('filepath', '/filestemporary/');
|
localStorage.setItem('filepath', '/filestemporary/');
|
||||||
localStorage.setItem('storageKey', JSON.stringify(['sdlocal']));
|
localStorage.setItem('storageKey', JSON.stringify([storageKey.value]));
|
||||||
upfile.value = true
|
upfile.value = true
|
||||||
fileObj.value = {
|
fileObj.value = {
|
||||||
projectId: '', //所属项目ID
|
projectId: '', //所属项目ID
|
||||||
@ -386,7 +392,7 @@ function upfileZip() {
|
|||||||
// ElMessage.warning("请保持压缩包内第一个文件夹与项目名称一致!!!")
|
// ElMessage.warning("请保持压缩包内第一个文件夹与项目名称一致!!!")
|
||||||
title.value = "上传项目包并扫描"
|
title.value = "上传项目包并扫描"
|
||||||
localStorage.setItem('filepath', '/temporary');
|
localStorage.setItem('filepath', '/temporary');
|
||||||
localStorage.setItem('storageKey', JSON.stringify(['sdlocal']));
|
localStorage.setItem('storageKey', JSON.stringify([storageKey.value]));
|
||||||
upfile.value = true
|
upfile.value = true
|
||||||
fileObj.value = {
|
fileObj.value = {
|
||||||
projectId: '', //所属项目ID
|
projectId: '', //所属项目ID
|
||||||
@ -443,7 +449,7 @@ function delfileOne(row: any) {
|
|||||||
type: "FILE"
|
type: "FILE"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
storageKey: "sdlocal"
|
storageKey: storageKey.value
|
||||||
}
|
}
|
||||||
batchDeleteReq(JSON.stringify(parmas)).then((res) => {
|
batchDeleteReq(JSON.stringify(parmas)).then((res) => {
|
||||||
})
|
})
|
||||||
|
@ -84,7 +84,7 @@ function editproject(row: any) {
|
|||||||
//删除项目弹框
|
//删除项目弹框
|
||||||
function delproject(row: any) {
|
function delproject(row: any) {
|
||||||
ElMessageBox.confirm(
|
ElMessageBox.confirm(
|
||||||
'您确定要删除该项目及其中的节点和文件吗?',
|
'您确定要删除该存储空间吗?',
|
||||||
'警告',
|
'警告',
|
||||||
{
|
{
|
||||||
confirmButtonText: '确定',
|
confirmButtonText: '确定',
|
||||||
@ -93,6 +93,10 @@ function delproject(row: any) {
|
|||||||
}
|
}
|
||||||
)
|
)
|
||||||
.then(() => {
|
.then(() => {
|
||||||
|
if(row.storeContent){
|
||||||
|
ElMessage.warning('已有项目绑定该存储空间,请先解除关联!')
|
||||||
|
return
|
||||||
|
}
|
||||||
loading.value = true
|
loading.value = true
|
||||||
storagestorageId(row.id).then((res: any) => {
|
storagestorageId(row.id).then((res: any) => {
|
||||||
if (res.code == 0) {
|
if (res.code == 0) {
|
||||||
@ -286,10 +290,10 @@ function handleClose1() {
|
|||||||
<el-form-item label=" 存储源名称" prop="name">
|
<el-form-item label=" 存储源名称" prop="name">
|
||||||
<el-input v-model="projectForme.name" />
|
<el-input v-model="projectForme.name" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label=" 存储源别名">
|
<el-form-item label=" 存储源别名" prop="key">
|
||||||
<el-input v-model="projectForme.key" />
|
<el-input v-model="projectForme.key" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label=" 存储源备注">
|
<el-form-item label=" 存储源备注" prop="remark">
|
||||||
<el-input v-model="projectForme.remark" />
|
<el-input v-model="projectForme.remark" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label=" 存储策略" prop="type">
|
<el-form-item label=" 存储策略" prop="type">
|
||||||
|
81
web/src/views/testdata/datamanagement/index.vue
vendored
81
web/src/views/testdata/datamanagement/index.vue
vendored
@ -13,7 +13,7 @@ import { ElMessageBox, ElMessage, ElMain } from "element-plus";
|
|||||||
import Page from '@/components/Pagination/page.vue';
|
import Page from '@/components/Pagination/page.vue';
|
||||||
import AudioPlayer from '@/components/file/preview/AudioPlayer.vue';
|
import AudioPlayer from '@/components/file/preview/AudioPlayer.vue';
|
||||||
import { batchDeleteReq } from "@/api/file-operator";
|
import { batchDeleteReq } from "@/api/file-operator";
|
||||||
import { tstaskList, obtaintestData, getTsNodesTree, confirmDeleteNodes,addTsNodes, selectTsNodesByTskeId, updateTsNodes, deleteTsNodesById, tsFilesPage, addTsFiles, testDataScanById, updateTsFiles, deleteTsFilesById, listTsFiles, deleteTsFilesByIds, compress, Decompression, compare, downloadToLocal, uploadToBackup, addTsFile, list, moveFileFolder, copyFileFolder, startSimpleNavi, stopSimpleNavi } from "@/api/datamanagement";
|
import { tstaskList, obtaintestData, getTsNodesTree, confirmDeleteNodes, addTsNodes, selectTsNodesByTskeId, updateTsNodes, deleteTsNodesById, tsFilesPage, addTsFiles, testDataScanById, updateTsFiles, deleteTsFilesById, listTsFiles, deleteTsFilesByIds, compress, Decompression, compare, downloadToLocal, uploadToBackup, addTsFile, list, moveFileFolder, copyFileFolder, startSimpleNavi, stopSimpleNavi } from "@/api/datamanagement";
|
||||||
import ZUpload from '@/components/file/ZUpload.vue'
|
import ZUpload from '@/components/file/ZUpload.vue'
|
||||||
import useFileUpload from "@/components/file/file/useFileUpload";
|
import useFileUpload from "@/components/file/file/useFileUpload";
|
||||||
import useHeaderStorageList from "@/components/header/useHeaderStorageList";
|
import useHeaderStorageList from "@/components/header/useHeaderStorageList";
|
||||||
@ -106,11 +106,15 @@ watch(() => projectId.value, (newVal) => {
|
|||||||
|
|
||||||
const projectArr = ref([])
|
const projectArr = ref([])
|
||||||
const taskName = ref('')
|
const taskName = ref('')
|
||||||
|
const localStorageId = ref('')
|
||||||
|
const storageKey:any = ref()
|
||||||
//获取所有项目
|
//获取所有项目
|
||||||
function getProject() {
|
function getProject() {
|
||||||
tstaskList().then((res: any) => {
|
tstaskList().then((res: any) => {
|
||||||
projectArr.value = res.data
|
projectArr.value = res.data
|
||||||
projectId.value = projectArr.value[0].id
|
projectId.value = projectArr.value[0].id
|
||||||
|
storageKey.value = projectArr.value[0].key
|
||||||
|
localStorageId.value = projectArr.value[0].localStorageId
|
||||||
taskName.value = projectArr.value[0].taskName
|
taskName.value = projectArr.value[0].taskName
|
||||||
ws1 = new WebSocket(userStore.WebSocketUrl + '/websocket/' + 'taskId_' + projectId.value)
|
ws1 = new WebSocket(userStore.WebSocketUrl + '/websocket/' + 'taskId_' + projectId.value)
|
||||||
setupWebSocket()
|
setupWebSocket()
|
||||||
@ -120,17 +124,9 @@ function getProject() {
|
|||||||
}
|
}
|
||||||
//扫描
|
//扫描
|
||||||
function scan() {
|
function scan() {
|
||||||
selectTsNodesByTskeId({ taskId: projectId.value }).then((res: any) => {
|
|
||||||
|
|
||||||
if (res.msg == "该项目已经初始化完成,局部更新请选择节点上传文件!") {
|
testDataScanById({ id: projectId.value }).then((res: any) => {
|
||||||
ElMessage.warning(res.msg)
|
tonstatus()
|
||||||
return
|
|
||||||
|
|
||||||
} else {
|
|
||||||
testDataScanById({ id: projectId.value }).then((res: any) => {
|
|
||||||
tonstatus()
|
|
||||||
})
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -167,6 +163,8 @@ const filepath = ref('')
|
|||||||
function gettreedata() {
|
function gettreedata() {
|
||||||
treeloading.value = true
|
treeloading.value = true
|
||||||
treeForm.value.taskId = projectId.value
|
treeForm.value.taskId = projectId.value
|
||||||
|
let keyar = projectArr.value.find(item => item.localStorageId === localStorageId.value);
|
||||||
|
storageKey.value = keyar.key
|
||||||
getTsNodesTree(treeForm.value).then((res: any) => {
|
getTsNodesTree(treeForm.value).then((res: any) => {
|
||||||
treedata.value = res.data
|
treedata.value = res.data
|
||||||
treeloading.value = false
|
treeloading.value = false
|
||||||
@ -229,15 +227,23 @@ function addSubItem(row: any) {
|
|||||||
}
|
}
|
||||||
//修改子项目
|
//修改子项目
|
||||||
function editSubItem(row: any) {
|
function editSubItem(row: any) {
|
||||||
title.value = "修改子节点"
|
confirmDeleteNodes({ id: row.nodeId }).then((res: any) => {
|
||||||
frame.value = true
|
if (res.data.data.status == 1) {
|
||||||
if (row.subRegions) {
|
title.value = "修改子节点"
|
||||||
delete row.subRegions
|
frame.value = true
|
||||||
}
|
if (row.subRegions) {
|
||||||
if (row.createTime) {
|
delete row.subRegions
|
||||||
delete row.createTime
|
}
|
||||||
}
|
if (row.createTime) {
|
||||||
projectForme.value = JSON.parse(JSON.stringify(row))
|
delete row.createTime
|
||||||
|
}
|
||||||
|
projectForme.value = JSON.parse(JSON.stringify(row))
|
||||||
|
} else {
|
||||||
|
ElMessage.warning("该节点中含有已备份的文件,无法修改")
|
||||||
|
return
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
}
|
}
|
||||||
//表单确定
|
//表单确定
|
||||||
async function submitForm(formEl: any) {
|
async function submitForm(formEl: any) {
|
||||||
@ -286,7 +292,7 @@ function delSubItem(row: any) {
|
|||||||
}
|
}
|
||||||
)
|
)
|
||||||
.then(() => {
|
.then(() => {
|
||||||
confirmDeleteNodes({id:row.nodeId}).then((res: any) => {
|
confirmDeleteNodes({ id: row.nodeId }).then((res: any) => {
|
||||||
if (res.data.data.status == 1) {
|
if (res.data.data.status == 1) {
|
||||||
loading.value = true
|
loading.value = true
|
||||||
deleteTsNodesById({ id: row.nodeId, path: row.path }).then((res: any) => {
|
deleteTsNodesById({ id: row.nodeId, path: row.path }).then((res: any) => {
|
||||||
@ -364,7 +370,7 @@ const upfile = ref(false)
|
|||||||
function openFile() {
|
function openFile() {
|
||||||
title.value = "上传文件"
|
title.value = "上传文件"
|
||||||
localStorage.setItem('filepath', creatform.value.workPath ? creatform.value.workPath : filepath.value);
|
localStorage.setItem('filepath', creatform.value.workPath ? creatform.value.workPath : filepath.value);
|
||||||
localStorage.setItem('storageKey', JSON.stringify(['local']));
|
localStorage.setItem('storageKey', JSON.stringify([storageKey.value]));
|
||||||
upfile.value = true
|
upfile.value = true
|
||||||
fileObj.value = {
|
fileObj.value = {
|
||||||
taskId: '', //所属项目ID
|
taskId: '', //所属项目ID
|
||||||
@ -410,7 +416,7 @@ function delfileOne(row: any) {
|
|||||||
type: "FILE"
|
type: "FILE"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
storageKey: "minio"
|
storageKey: "storageKey.value"
|
||||||
}
|
}
|
||||||
batchDeleteReq(JSON.stringify(parmas)).then((res) => {
|
batchDeleteReq(JSON.stringify(parmas)).then((res) => {
|
||||||
})
|
})
|
||||||
@ -492,7 +498,7 @@ function delfile(row: any) {
|
|||||||
)
|
)
|
||||||
.then(() => {
|
.then(() => {
|
||||||
loading.value = true
|
loading.value = true
|
||||||
deleteTsFilesById({ id: row.id, type: 'local' }).then((res: any) => {
|
deleteTsFilesById({ id: row.id, type: 'local',taskId:projectId.value }).then((res: any) => {
|
||||||
if (res.code == 0) {
|
if (res.code == 0) {
|
||||||
getdata()
|
getdata()
|
||||||
ElMessage({
|
ElMessage({
|
||||||
@ -528,7 +534,7 @@ function delprojectArr() {
|
|||||||
)
|
)
|
||||||
.then(() => {
|
.then(() => {
|
||||||
loading.value = true
|
loading.value = true
|
||||||
deleteTsFilesByIds({ ids: ids.join(','), type: 'local' }).then((res: any) => {
|
deleteTsFilesByIds({ ids: ids.join(','), type: 'local',taskId:projectId.value }).then((res: any) => {
|
||||||
if (res.code == 0) {
|
if (res.code == 0) {
|
||||||
ElMessage({
|
ElMessage({
|
||||||
type: 'success',
|
type: 'success',
|
||||||
@ -871,6 +877,7 @@ function paste() {
|
|||||||
newFileName: [],
|
newFileName: [],
|
||||||
rename: '',
|
rename: '',
|
||||||
type: '',
|
type: '',
|
||||||
|
taskId:projectId.value
|
||||||
}
|
}
|
||||||
repeatObj.newPath = creatform.value.workPath ? creatform.value.workPath : filepath.value
|
repeatObj.newPath = creatform.value.workPath ? creatform.value.workPath : filepath.value
|
||||||
repeatObj.parentId = creatform.value.parentId ? creatform.value.parentId : '00'
|
repeatObj.parentId = creatform.value.parentId ? creatform.value.parentId : '00'
|
||||||
@ -894,6 +901,7 @@ function paste() {
|
|||||||
repeatObj.newFileName.push(items.fileName)
|
repeatObj.newFileName.push(items.fileName)
|
||||||
})
|
})
|
||||||
repeatObj.newFileName = repeatObj.newFileName.join(',')
|
repeatObj.newFileName = repeatObj.newFileName.join(',')
|
||||||
|
|
||||||
if (copytype.value == 'move') {
|
if (copytype.value == 'move') {
|
||||||
moveFileFolder(repeatObj).then((res: any) => {
|
moveFileFolder(repeatObj).then((res: any) => {
|
||||||
if (res.code == 0) {
|
if (res.code == 0) {
|
||||||
@ -984,6 +992,7 @@ function copycover(row: any) {
|
|||||||
newFileName: [],
|
newFileName: [],
|
||||||
rename: '',
|
rename: '',
|
||||||
type: '',
|
type: '',
|
||||||
|
taskId:projectId.value
|
||||||
}
|
}
|
||||||
repeatObj.newPath = creatform.value.workPath ? creatform.value.workPath : filepath.value
|
repeatObj.newPath = creatform.value.workPath ? creatform.value.workPath : filepath.value
|
||||||
repeatObj.parentId = creatform.value.parentId ? creatform.value.parentId : '00'
|
repeatObj.parentId = creatform.value.parentId ? creatform.value.parentId : '00'
|
||||||
@ -1059,6 +1068,7 @@ function copysomefile() {
|
|||||||
newFileName: [],
|
newFileName: [],
|
||||||
rename: '',
|
rename: '',
|
||||||
type: '',
|
type: '',
|
||||||
|
taskId:projectId.value
|
||||||
}
|
}
|
||||||
repeatObj.newPath = creatform.value.workPath ? creatform.value.workPath : filepath.value
|
repeatObj.newPath = creatform.value.workPath ? creatform.value.workPath : filepath.value
|
||||||
repeatObj.parentId = creatform.value.parentId ? creatform.value.parentId : '00'
|
repeatObj.parentId = creatform.value.parentId ? creatform.value.parentId : '00'
|
||||||
@ -1123,6 +1133,7 @@ async function submitrename(formEl: any) {
|
|||||||
newFileName: [],
|
newFileName: [],
|
||||||
rename: '',
|
rename: '',
|
||||||
type: '',
|
type: '',
|
||||||
|
taskId:projectId.value
|
||||||
}
|
}
|
||||||
repeatObj.newPath = creatform.value.workPath ? creatform.value.workPath : filepath.value
|
repeatObj.newPath = creatform.value.workPath ? creatform.value.workPath : filepath.value
|
||||||
repeatObj.parentId = creatform.value.parentId ? creatform.value.parentId : '00'
|
repeatObj.parentId = creatform.value.parentId ? creatform.value.parentId : '00'
|
||||||
@ -1288,6 +1299,7 @@ async function submitzip(formEl: any) {
|
|||||||
zipObj.value.compressedPath = zipObj.value.compressedPath
|
zipObj.value.compressedPath = zipObj.value.compressedPath
|
||||||
}
|
}
|
||||||
zipObj.value.path = filepath.value
|
zipObj.value.path = filepath.value
|
||||||
|
zipObj.value.taskId = projectId.value
|
||||||
compress(zipObj.value).then((res: any) => {
|
compress(zipObj.value).then((res: any) => {
|
||||||
if (res.code == 0) {
|
if (res.code == 0) {
|
||||||
zipfiles.value = false
|
zipfiles.value = false
|
||||||
@ -1299,7 +1311,7 @@ async function submitzip(formEl: any) {
|
|||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
Decompression({ id: jiezip.value.id, parentId: zipParentid.value, decompressionPath: zipObj.value.compressedPath, path: filepath.value }).then((res: any) => {
|
Decompression({ id: jiezip.value.id, parentId: zipParentid.value, decompressionPath: zipObj.value.compressedPath, path: filepath.value,taskId:projectId.value }).then((res: any) => {
|
||||||
if (res.code == 0) {
|
if (res.code == 0) {
|
||||||
ElMessage.success('解压成功')
|
ElMessage.success('解压成功')
|
||||||
getdata()
|
getdata()
|
||||||
@ -1525,7 +1537,8 @@ const maptime: any = ref(1)
|
|||||||
const qvehuan: any = ref(false)
|
const qvehuan: any = ref(false)
|
||||||
const qvehuan1: any = ref(false)
|
const qvehuan1: any = ref(false)
|
||||||
function frequency(row: any) {
|
function frequency(row: any) {
|
||||||
startSimpleNavi({ samTimes: maptime.value, id: fredid.value, token: userStore.userId }).then((res: any) => {
|
startSimpleNavi({ samTimes: maptime.value, id: fredid.value, token: userStore.userId,taskId:projectId.value
|
||||||
|
}).then((res: any) => {
|
||||||
if (res.code == '0' && row) {
|
if (res.code == '0' && row) {
|
||||||
ElMessage.success("切换成功")
|
ElMessage.success("切换成功")
|
||||||
getSSELink()
|
getSSELink()
|
||||||
@ -1640,7 +1653,7 @@ function repstring(row: any) {
|
|||||||
<span class="custom-tree-node">
|
<span class="custom-tree-node">
|
||||||
<span class="text">{{ data.nodeName }}</span>
|
<span class="text">{{ data.nodeName }}</span>
|
||||||
<span class="img_tree">
|
<span class="img_tree">
|
||||||
<!-- <img src="@/assets/project/xiu.png" alt="" title="编辑" @click="editSubItem(data)"> -->
|
<img src="@/assets/project/xiu.png" alt="" title="编辑" @click="editSubItem(data)">
|
||||||
<img src="@/assets/project/del.png" alt="" title="删除" @click="delSubItem(data)">
|
<img src="@/assets/project/del.png" alt="" title="删除" @click="delSubItem(data)">
|
||||||
<!-- <img src="@/assets/images/chayi.png" alt="" title="差异性对比" @click="opendifference(data)"> -->
|
<!-- <img src="@/assets/images/chayi.png" alt="" title="差异性对比" @click="opendifference(data)"> -->
|
||||||
<img src="@/assets/project/jia.png" alt="" title="添加子项目" @click="addSubItem(data)">
|
<img src="@/assets/project/jia.png" alt="" title="添加子项目" @click="addSubItem(data)">
|
||||||
@ -1696,7 +1709,8 @@ function repstring(row: any) {
|
|||||||
<!-- <el-table-column type="index" label="序号" width="70" align="center"></el-table-column> -->
|
<!-- <el-table-column type="index" label="序号" width="70" align="center"></el-table-column> -->
|
||||||
<el-table-column prop="fileName" label="文件名称" width="200">
|
<el-table-column prop="fileName" label="文件名称" width="200">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<div class="tableweight" v-if="scope.row.isFile == 'FOLDER'" @click="openNode(scope.row)" >{{ scope.row.fileName }} </div>
|
<div class="tableweight" v-if="scope.row.isFile == 'FOLDER'" @click="openNode(scope.row)">{{
|
||||||
|
scope.row.fileName }} </div>
|
||||||
<div v-else-if="scope.row.isFile == 'FILE'">{{ scope.row.fileName }} </div>
|
<div v-else-if="scope.row.isFile == 'FILE'">{{ scope.row.fileName }} </div>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
@ -2057,13 +2071,13 @@ function repstring(row: any) {
|
|||||||
@update="CloseView" />
|
@update="CloseView" />
|
||||||
<el-dialog :close-on-click-modal="false" :title="title" v-model="textedit" :before-close="textClose" top="30px"
|
<el-dialog :close-on-click-modal="false" :title="title" v-model="textedit" :before-close="textClose" top="30px"
|
||||||
draggable width="60%" destroy-on-close>
|
draggable width="60%" destroy-on-close>
|
||||||
<textEdit :rowId="rowId" :fileUrl="fileUrl1" />
|
<textEdit :rowId="rowId" :fileUrl="fileUrl1" :taskId="projectId" />
|
||||||
|
|
||||||
<!-- <txtexl :file-url="fileUrl" /> -->
|
<!-- <txtexl :file-url="fileUrl" /> -->
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
<el-dialog :close-on-click-modal="false" :title="title" v-model="textedit1" :before-close="texexceltClose"
|
<el-dialog :close-on-click-modal="false" :title="title" v-model="textedit1" :before-close="texexceltClose"
|
||||||
top="30px" draggable width="60%" destroy-on-close>
|
top="30px" draggable width="60%" destroy-on-close>
|
||||||
<txtexl :file-url="fileUrl" :rowId="rowId" />
|
<txtexl :file-url="fileUrl" :rowId="rowId" :taskId="projectId" />
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
@ -2157,7 +2171,7 @@ function repstring(row: any) {
|
|||||||
|
|
||||||
.img_tree {
|
.img_tree {
|
||||||
display: flex;
|
display: flex;
|
||||||
width: 13%;
|
width: 20%;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
|
|
||||||
@ -2180,7 +2194,8 @@ function repstring(row: any) {
|
|||||||
background: #dbf500;
|
background: #dbf500;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
.tableweight:hover{
|
|
||||||
|
.tableweight:hover {
|
||||||
color: #409eff;
|
color: #409eff;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -653,7 +653,7 @@ const handleMenuClick = (action: string, type: any) => {
|
|||||||
size: currentNode.value.fileSize,
|
size: currentNode.value.fileSize,
|
||||||
type: currentNode.value.isFile
|
type: currentNode.value.isFile
|
||||||
}]
|
}]
|
||||||
uploadToBackup({ parameterLists: params }).then((res: any) => {
|
uploadToBackup({ parameterLists: params,taskId:projectId.value }).then((res: any) => {
|
||||||
if (res.code == '0') {
|
if (res.code == '0') {
|
||||||
ElMessage.success("上传成功")
|
ElMessage.success("上传成功")
|
||||||
localOnlyFiles.value = localOnlyFiles.value.filter((item: any) => item.id !== currentNode.value.id)
|
localOnlyFiles.value = localOnlyFiles.value.filter((item: any) => item.id !== currentNode.value.id)
|
||||||
@ -667,7 +667,7 @@ const handleMenuClick = (action: string, type: any) => {
|
|||||||
break
|
break
|
||||||
case 'delete':
|
case 'delete':
|
||||||
// 处理删除逻辑
|
// 处理删除逻辑
|
||||||
deleteTsFilesById({ id: currentNode.value.id, type: type }).then((res: any) => {
|
deleteTsFilesById({ id: currentNode.value.id, type: type,taskId:projectId.value }).then((res: any) => {
|
||||||
if (res.code == '0') {
|
if (res.code == '0') {
|
||||||
ElMessage.success("删除成功")
|
ElMessage.success("删除成功")
|
||||||
getlocaltree()
|
getlocaltree()
|
||||||
@ -708,7 +708,7 @@ function tableBeifen(row: any) {
|
|||||||
}]
|
}]
|
||||||
loading1.value = true
|
loading1.value = true
|
||||||
loading2.value = true
|
loading2.value = true
|
||||||
uploadToBackup({ parameterLists: params }).then((res: any) => {
|
uploadToBackup({ parameterLists: params,taskId:projectId.value }).then((res: any) => {
|
||||||
if (res.code == '0') {
|
if (res.code == '0') {
|
||||||
ElMessage.success("上传成功")
|
ElMessage.success("上传成功")
|
||||||
diffSure(false)
|
diffSure(false)
|
||||||
@ -740,7 +740,7 @@ function moretableBeifen() {
|
|||||||
})
|
})
|
||||||
loading1.value = true
|
loading1.value = true
|
||||||
loading2.value = true
|
loading2.value = true
|
||||||
uploadToBackup({ parameterLists: beifenArr3 }).then((res: any) => {
|
uploadToBackup({ parameterLists: beifenArr3,taskId:projectId.value }).then((res: any) => {
|
||||||
if (res.code == '0') {
|
if (res.code == '0') {
|
||||||
diffSure(false)
|
diffSure(false)
|
||||||
diffChange(false)
|
diffChange(false)
|
||||||
@ -829,7 +829,7 @@ function delhuifu() {
|
|||||||
ids.value.push(item.id)
|
ids.value.push(item.id)
|
||||||
})
|
})
|
||||||
loading3.value = true
|
loading3.value = true
|
||||||
deleteTsFilesByIds({ ids: ids.value.join(','), type: 'minio' }).then((res: any) => {
|
deleteTsFilesByIds({ ids: ids.value.join(','), type: 'minio',taskId:projectId.value }).then((res: any) => {
|
||||||
if (res.code == '0') {
|
if (res.code == '0') {
|
||||||
ElMessage.success("删除成功")
|
ElMessage.success("删除成功")
|
||||||
diffMiss(false)
|
diffMiss(false)
|
||||||
@ -868,7 +868,7 @@ function bfclick(type: any) {
|
|||||||
beifenArr2.forEach((items: any) => {
|
beifenArr2.forEach((items: any) => {
|
||||||
beifenArr3.push({ path: items.workPath, name: items.fileName, size: items.fileSize, type: items.isFile })
|
beifenArr3.push({ path: items.workPath, name: items.fileName, size: items.fileSize, type: items.isFile })
|
||||||
})
|
})
|
||||||
uploadToBackup({ parameterLists: beifenArr3 }).then((res: any) => {
|
uploadToBackup({ parameterLists: beifenArr3,taskId:projectId.value }).then((res: any) => {
|
||||||
if (res.code == '0') {
|
if (res.code == '0') {
|
||||||
ElMessage.success("上传成功")
|
ElMessage.success("上传成功")
|
||||||
diffChange(false)
|
diffChange(false)
|
||||||
@ -966,7 +966,7 @@ function openPreview(row: any, type: any) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
function geturl(row: any, type1: any, pan: any) {
|
function geturl(row: any, type1: any, pan: any) {
|
||||||
obtainUrl({ id: row.id, type: type1 }).then((res: any) => {
|
obtainUrl({ id: row.id, type: type1,taskId:projectId.value }).then((res: any) => {
|
||||||
if (pan) {
|
if (pan) {
|
||||||
ViewfileUrl.value = res.data.url
|
ViewfileUrl.value = res.data.url
|
||||||
isViewfile.value = true
|
isViewfile.value = true
|
||||||
|
Loading…
Reference in New Issue
Block a user