5-29代码更改
This commit is contained in:
parent
a2b04b8f04
commit
793313ef6b
@ -149,15 +149,16 @@ function gettreedata() {
|
|||||||
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
|
||||||
filePath.value = res.data[0].path + res.data[0].nodeName + '/'
|
|
||||||
if (treedata.value[0]) {
|
if (treedata.value[0]) {
|
||||||
pathid.value = treedata.value[0].id
|
pathid.value = treedata.value[0].id
|
||||||
|
filePath.value = res.data[0].path + res.data[0].nodeName + '/'
|
||||||
nextTick(() => {
|
nextTick(() => {
|
||||||
treeRef.value?.setCurrentKey(pathid.value);
|
treeRef.value?.setCurrentKey(pathid.value);
|
||||||
});
|
});
|
||||||
getdata()
|
getdata()
|
||||||
} else {
|
} else {
|
||||||
tableData.value.length = 0
|
tableData.value.length = 0
|
||||||
|
loading.value = false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -360,8 +361,9 @@ const fileObj: any = ref({
|
|||||||
//上传组件
|
//上传组件
|
||||||
const upfile = ref(false)
|
const upfile = ref(false)
|
||||||
function openFile() {
|
function openFile() {
|
||||||
|
titleon.value = false
|
||||||
title.value = "上传文件"
|
title.value = "上传文件"
|
||||||
localStorage.setItem('filepath', filePath.value);
|
localStorage.setItem('filepath', '/filestemporary/');
|
||||||
localStorage.setItem('storageKey', JSON.stringify(['sdlocal']));
|
localStorage.setItem('storageKey', JSON.stringify(['sdlocal']));
|
||||||
upfile.value = true
|
upfile.value = true
|
||||||
fileObj.value = {
|
fileObj.value = {
|
||||||
@ -376,12 +378,15 @@ function openFile() {
|
|||||||
judge.value = true
|
judge.value = true
|
||||||
}
|
}
|
||||||
//上传文件并扫描
|
//上传文件并扫描
|
||||||
|
const titleon = ref(false)
|
||||||
function upfileZip() {
|
function upfileZip() {
|
||||||
selectNodesByProjectId({ projectId: projectId.value }).then((res: any) => {
|
selectNodesByProjectId({ projectId: projectId.value }).then((res: any) => {
|
||||||
if (res.msg == "该项目已经初始化完成,局部更新请选择节点上传文件!") {
|
if (res.msg == "该项目已经初始化完成,局部更新请选择节点上传文件!") {
|
||||||
ElMessage.warning(res.msg)
|
ElMessage.warning(res.msg)
|
||||||
return
|
return
|
||||||
} else {
|
} else {
|
||||||
|
titleon.value = true
|
||||||
|
// 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(['sdlocal']));
|
||||||
@ -458,6 +463,7 @@ function submitfile() {
|
|||||||
if (res.code == 0) {
|
if (res.code == 0) {
|
||||||
tonstatus()
|
tonstatus()
|
||||||
upfile.value = false
|
upfile.value = false
|
||||||
|
titleon.value = true
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
@ -492,7 +498,7 @@ function submitfile() {
|
|||||||
fileObj.value.targetPath = filePath.value
|
fileObj.value.targetPath = filePath.value
|
||||||
fileObj.value.fileName = fileName.join(',')
|
fileObj.value.fileName = fileName.join(',')
|
||||||
fileObj.value.fileSize = fileSize.join(',')
|
fileObj.value.fileSize = fileSize.join(',')
|
||||||
fileObj.value.sourcePath = '/temporary'
|
fileObj.value.sourcePath = '/filestemporary'
|
||||||
addFiles(fileObj.value).then((res: any) => {
|
addFiles(fileObj.value).then((res: any) => {
|
||||||
if (res.code == 0) {
|
if (res.code == 0) {
|
||||||
closeDialog()
|
closeDialog()
|
||||||
@ -924,6 +930,9 @@ function tonstatus() {
|
|||||||
</el-dialog>
|
</el-dialog>
|
||||||
<el-dialog :title="title" v-model="upfile" width="50%" :before-close="fileClose" top="30px" draggable
|
<el-dialog :title="title" v-model="upfile" width="50%" :before-close="fileClose" top="30px" draggable
|
||||||
:close-on-click-modal="false" destroy-on-close>
|
:close-on-click-modal="false" destroy-on-close>
|
||||||
|
<div v-if="titleon" style="width: 100%;text-align: center;font-size: 18px;margin-bottom: 15px;color: red;" >
|
||||||
|
请保持压缩包内第一层文件夹名称与项目名称一致!!!
|
||||||
|
</div>
|
||||||
<el-scrollbar :height="judge ? '400px' : ''">
|
<el-scrollbar :height="judge ? '400px' : ''">
|
||||||
<el-form ref="ruleFormRef" style="max-width: 100%" :model="fileObj" :rules="moderqqqules"
|
<el-form ref="ruleFormRef" style="max-width: 100%" :model="fileObj" :rules="moderqqqules"
|
||||||
label-width="auto" class="demo-ruleForm" status-icon>
|
label-width="auto" class="demo-ruleForm" status-icon>
|
||||||
@ -944,6 +953,7 @@ function tonstatus() {
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
</el-scrollbar>
|
</el-scrollbar>
|
||||||
|
|
||||||
<div style="width: 100%;display: flex;justify-content: end;">
|
<div style="width: 100%;display: flex;justify-content: end;">
|
||||||
<el-button type="primary" @click="submitfile">确定</el-button>
|
<el-button type="primary" @click="submitfile">确定</el-button>
|
||||||
<el-button @click="fileClose">取消</el-button>
|
<el-button @click="fileClose">取消</el-button>
|
||||||
|
@ -149,14 +149,18 @@ async function submitForm(formEl: any) {
|
|||||||
if (valid) {
|
if (valid) {
|
||||||
if (projectForme.value.id) {
|
if (projectForme.value.id) {
|
||||||
updateSdproject(projectForme.value).then((res: any) => {
|
updateSdproject(projectForme.value).then((res: any) => {
|
||||||
getdata()
|
if (res.code == 0) {
|
||||||
ElMessage.success("修改成功")
|
getdata()
|
||||||
|
ElMessage.success("修改成功")
|
||||||
|
}
|
||||||
frame.value = false
|
frame.value = false
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
addSdproject(projectForme.value).then((res: any) => {
|
addSdproject(projectForme.value).then((res: any) => {
|
||||||
getdata()
|
if (res.code == 0) {
|
||||||
ElMessage.success("添加成功")
|
getdata()
|
||||||
|
ElMessage.success("添加成功")
|
||||||
|
}
|
||||||
frame.value = false
|
frame.value = false
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@ -186,14 +190,14 @@ function typeName(arr: any, itemCode: any) {
|
|||||||
});
|
});
|
||||||
return nameone
|
return nameone
|
||||||
}
|
}
|
||||||
const logqing= ref(false)
|
const logqing = ref(false)
|
||||||
const logTxt = ref('')
|
const logTxt = ref('')
|
||||||
function Loglist(row:any){
|
function Loglist(row: any) {
|
||||||
title.value = row.projectName + '_项目描述'
|
title.value = row.projectName + '_项目描述'
|
||||||
logqing.value = true
|
logqing.value = true
|
||||||
logTxt.value = row.description
|
logTxt.value = row.description
|
||||||
}
|
}
|
||||||
function handleClose1(){
|
function handleClose1() {
|
||||||
logqing.value = false
|
logqing.value = false
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
@ -240,13 +244,14 @@ function handleClose1(){
|
|||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<div class="ellipsis">
|
<div class="ellipsis">
|
||||||
<span class="single-line-ellipsis">{{ scope.row.description }}</span>
|
<span class="single-line-ellipsis">{{ scope.row.description }}</span>
|
||||||
<img src="@/assets/MenuIcon/xqing.png" alt="" title="详情" @click="Loglist(scope.row)" style="cursor: pointer;" >
|
<img src="@/assets/MenuIcon/xqing.png" alt="" title="详情" @click="Loglist(scope.row)"
|
||||||
</div>
|
style="cursor: pointer;">
|
||||||
|
</div>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<!-- <el-table-column prop="projectProps" label="项目信息"></el-table-column> -->
|
<!-- <el-table-column prop="projectProps" label="项目信息"></el-table-column> -->
|
||||||
|
|
||||||
<el-table-column fixed="right" label="操作" width="80" align="center">
|
<el-table-column fixed="right" label="操作" width="80" align="center">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<span
|
<span
|
||||||
@ -304,28 +309,30 @@ function handleClose1(){
|
|||||||
</el-dialog>
|
</el-dialog>
|
||||||
<el-dialog :title="title" v-model="logqing" width="60%" :before-close="handleClose1" top="30px" draggable
|
<el-dialog :title="title" v-model="logqing" width="60%" :before-close="handleClose1" top="30px" draggable
|
||||||
:close-on-click-modal="false" destroy-on-close>
|
:close-on-click-modal="false" destroy-on-close>
|
||||||
<div class="texlog">
|
<div class="texlog">
|
||||||
<el-scrollbar height="80vh">
|
<el-scrollbar height="80vh">
|
||||||
{{ logTxt }}
|
{{ logTxt }}
|
||||||
</el-scrollbar>
|
</el-scrollbar>
|
||||||
</div>
|
</div>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.texlog{
|
.texlog {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
border: 1px solid #ccc;
|
border: 1px solid #ccc;
|
||||||
border-radius: 5px;
|
border-radius: 5px;
|
||||||
}
|
}
|
||||||
.ellipsis{
|
|
||||||
|
.ellipsis {
|
||||||
display: flex;
|
display: flex;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
}
|
}
|
||||||
|
|
||||||
.single-line-ellipsis {
|
.single-line-ellipsis {
|
||||||
width: 800px;
|
width: 800px;
|
||||||
/* 限制容器宽度 */
|
/* 限制容器宽度 */
|
||||||
|
10
web/src/views/testdata/datamanagement/index.vue
vendored
10
web/src/views/testdata/datamanagement/index.vue
vendored
@ -5,7 +5,7 @@ export default {
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, onMounted, nextTick, defineAsyncComponent ,watch,onBeforeUnmount} from "vue";
|
import { ref, onMounted, nextTick, defineAsyncComponent, watch, onBeforeUnmount } from "vue";
|
||||||
import { Search } from '@element-plus/icons-vue'
|
import { Search } from '@element-plus/icons-vue'
|
||||||
import { useAppStore } from '@/store/modules/app';
|
import { useAppStore } from '@/store/modules/app';
|
||||||
import { useUserStore } from '@/store/modules/user';
|
import { useUserStore } from '@/store/modules/user';
|
||||||
@ -179,6 +179,7 @@ function gettreedata() {
|
|||||||
getdata()
|
getdata()
|
||||||
} else {
|
} else {
|
||||||
tableData.value.length = 0
|
tableData.value.length = 0
|
||||||
|
loading.value = false
|
||||||
}
|
}
|
||||||
|
|
||||||
})
|
})
|
||||||
@ -276,7 +277,7 @@ function handleClose(formEl: any) {
|
|||||||
//删除子节点
|
//删除子节点
|
||||||
function delSubItem(row: any) {
|
function delSubItem(row: any) {
|
||||||
ElMessageBox.confirm(
|
ElMessageBox.confirm(
|
||||||
'您确定要删除该项目吗?',
|
'您确定要删除该节点及其中的文件吗?',
|
||||||
'警告',
|
'警告',
|
||||||
{
|
{
|
||||||
confirmButtonText: '确定',
|
confirmButtonText: '确定',
|
||||||
@ -333,10 +334,10 @@ function getdata() {
|
|||||||
queryParams.value.taskId = projectId.value
|
queryParams.value.taskId = projectId.value
|
||||||
queryParams.value.id = creatform.value.parentId
|
queryParams.value.id = creatform.value.parentId
|
||||||
tsFilesPage(queryParams.value).then((res: any) => {
|
tsFilesPage(queryParams.value).then((res: any) => {
|
||||||
|
loading.value = false
|
||||||
queryParams.value.current = res.data.current
|
queryParams.value.current = res.data.current
|
||||||
queryParams.value.size = res.data.size
|
queryParams.value.size = res.data.size
|
||||||
total.value = res.data.total
|
total.value = res.data.total
|
||||||
loading.value = false
|
|
||||||
tableData.value = res.data.records
|
tableData.value = res.data.records
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@ -1288,7 +1289,6 @@ async function submitzip(formEl: any) {
|
|||||||
tableIdarr.value.length = 0
|
tableIdarr.value.length = 0
|
||||||
filetableRef.value!.clearSelection()
|
filetableRef.value!.clearSelection()
|
||||||
}
|
}
|
||||||
|
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
@ -1656,7 +1656,7 @@ function repstring(row: any) {
|
|||||||
</template>
|
</template>
|
||||||
</el-tree>
|
</el-tree>
|
||||||
<el-button type="primary" @click="scan()" style="width: 100%;" :loading="tonloading">{{ buttonmsg
|
<el-button type="primary" @click="scan()" style="width: 100%;" :loading="tonloading">{{ buttonmsg
|
||||||
}}</el-button>
|
}}</el-button>
|
||||||
</div>
|
</div>
|
||||||
<div class="moveBtn" v-move>
|
<div class="moveBtn" v-move>
|
||||||
<div class="moveBtn-line"></div>
|
<div class="moveBtn-line"></div>
|
||||||
|
@ -153,19 +153,15 @@ function backups() {
|
|||||||
if (ids.length > 0) {
|
if (ids.length > 0) {
|
||||||
automaticFileBackupByIds(params).then((res: any) => {
|
automaticFileBackupByIds(params).then((res: any) => {
|
||||||
if (res.code == 0) {
|
if (res.code == 0) {
|
||||||
// ElMessage.success(res.msg)
|
comparearr.value.length = 0
|
||||||
tonstatus()
|
tonstatus()
|
||||||
// getlocaltree()
|
|
||||||
// getminiotree()
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
automaticFileBackup(params).then((res: any) => {
|
automaticFileBackup(params).then((res: any) => {
|
||||||
if (res.code == 0) {
|
if (res.code == 0) {
|
||||||
// ElMessage.success(res.msg)
|
comparearr.value.length = 0
|
||||||
tonstatus()
|
tonstatus()
|
||||||
// getlocaltree()
|
|
||||||
// getminiotree()
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@ -189,17 +185,19 @@ function getchayi() {
|
|||||||
params.taskId = projectId.value
|
params.taskId = projectId.value
|
||||||
}
|
}
|
||||||
compareLocalList(params).then((res: any) => {
|
compareLocalList(params).then((res: any) => {
|
||||||
// debugger
|
|
||||||
localOnlyFiles.value = res.data
|
localOnlyFiles.value = res.data
|
||||||
gettreeTwo()
|
gettreeTwo()
|
||||||
|
comparearr.value.length = 0
|
||||||
})
|
})
|
||||||
compareMd5List(params).then((res: any) => {
|
compareMd5List(params).then((res: any) => {
|
||||||
md5MismatchedFiles.value = res.data
|
md5MismatchedFiles.value = res.data
|
||||||
gettreeTwo()
|
gettreeTwo()
|
||||||
|
comparearr.value.length = 0
|
||||||
})
|
})
|
||||||
compareMinioList(params).then((res: any) => {
|
compareMinioList(params).then((res: any) => {
|
||||||
minioOnlyFiles.value = res.data
|
minioOnlyFiles.value = res.data
|
||||||
gettreeTwo()
|
gettreeTwo()
|
||||||
|
comparearr.value.length = 0
|
||||||
})
|
})
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -347,7 +345,7 @@ function diffColor() {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
function diffClose() {
|
function diffClose() {
|
||||||
comparearr.value.length = 0
|
// comparearr.value.length = 0
|
||||||
workall.value.length = 0
|
workall.value.length = 0
|
||||||
differential.value = false
|
differential.value = false
|
||||||
diffFile2()
|
diffFile2()
|
||||||
|
Loading…
Reference in New Issue
Block a user