Compare commits
4 Commits
a7cf67e6e4
...
d3c15d4d75
| Author | SHA1 | Date | |
|---|---|---|---|
| d3c15d4d75 | |||
| 848640e284 | |||
| bd0b25d059 | |||
| ba939b8eb6 |
3
.gitignore
vendored
3
.gitignore
vendored
@@ -67,3 +67,6 @@ doc/test-data/**/~$*
|
|||||||
db_config.conf
|
db_config.conf
|
||||||
|
|
||||||
~*.*
|
~*.*
|
||||||
|
|
||||||
|
|
||||||
|
./.playwright-cli
|
||||||
|
|||||||
@@ -46,49 +46,6 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- 统计卡片区域 -->
|
|
||||||
<div class="statistics-section">
|
|
||||||
<div class="stat-card" @click="handleStatusFilter('uploading')">
|
|
||||||
<div class="stat-icon uploading">
|
|
||||||
<i class="el-icon-upload"></i>
|
|
||||||
</div>
|
|
||||||
<div class="stat-content">
|
|
||||||
<div class="stat-label">上传中</div>
|
|
||||||
<div class="stat-value">{{ statistics.uploading }}</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="stat-card" @click="handleStatusFilter('parsing')">
|
|
||||||
<div class="stat-icon parsing">
|
|
||||||
<i class="el-icon-loading"></i>
|
|
||||||
</div>
|
|
||||||
<div class="stat-content">
|
|
||||||
<div class="stat-label">解析中</div>
|
|
||||||
<div class="stat-value">{{ statistics.parsing }}</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="stat-card" @click="handleStatusFilter('parsed_success')">
|
|
||||||
<div class="stat-icon success">
|
|
||||||
<i class="el-icon-success"></i>
|
|
||||||
</div>
|
|
||||||
<div class="stat-content">
|
|
||||||
<div class="stat-label">解析成功</div>
|
|
||||||
<div class="stat-value">{{ statistics.parsed_success }}</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="stat-card" @click="handleStatusFilter('parsed_failed')">
|
|
||||||
<div class="stat-icon failed">
|
|
||||||
<i class="el-icon-error"></i>
|
|
||||||
</div>
|
|
||||||
<div class="stat-content">
|
|
||||||
<div class="stat-label">解析失败</div>
|
|
||||||
<div class="stat-value">{{ statistics.parsed_failed }}</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- 文件上传记录列表 -->
|
<!-- 文件上传记录列表 -->
|
||||||
<div class="file-list-section">
|
<div class="file-list-section">
|
||||||
<div class="list-toolbar">
|
<div class="list-toolbar">
|
||||||
@@ -129,7 +86,11 @@
|
|||||||
{{ scope.row.enterpriseNames || '-' }}
|
{{ scope.row.enterpriseNames || '-' }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="uploadTime" label="上传时间" width="160"></el-table-column>
|
<el-table-column prop="uploadTime" label="上传时间" width="180">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
{{ formatUploadTime(scope.row.uploadTime) }}
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column prop="uploadUser" label="上传人" width="100"></el-table-column>
|
<el-table-column prop="uploadUser" label="上传人" width="100"></el-table-column>
|
||||||
<el-table-column label="操作" width="120" fixed="right">
|
<el-table-column label="操作" width="120" fixed="right">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
@@ -240,7 +201,6 @@
|
|||||||
>
|
>
|
||||||
</span>
|
</span>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
accept=".pdf,.csv,.xlsx,.xls"
|
|
||||||
|
|
||||||
<!-- 名单选择弹窗 -->
|
<!-- 名单选择弹窗 -->
|
||||||
<el-dialog
|
<el-dialog
|
||||||
@@ -342,6 +302,7 @@ import {
|
|||||||
getFileUploadList,
|
getFileUploadList,
|
||||||
getFileUploadStatistics,
|
getFileUploadStatistics,
|
||||||
} from "@/api/ccdiProjectUpload";
|
} from "@/api/ccdiProjectUpload";
|
||||||
|
import { parseTime } from "@/utils/ruoyi";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "UploadData",
|
name: "UploadData",
|
||||||
@@ -987,13 +948,6 @@ export default {
|
|||||||
|
|
||||||
// === 辅助方法 ===
|
// === 辅助方法 ===
|
||||||
|
|
||||||
/** 状态筛选 */
|
|
||||||
handleStatusFilter(status) {
|
|
||||||
this.queryParams.fileStatus = status;
|
|
||||||
this.queryParams.pageNum = 1;
|
|
||||||
this.loadFileList();
|
|
||||||
},
|
|
||||||
|
|
||||||
/** 分页变化 */
|
/** 分页变化 */
|
||||||
handlePageChange(pageNum) {
|
handlePageChange(pageNum) {
|
||||||
this.queryParams.pageNum = pageNum;
|
this.queryParams.pageNum = pageNum;
|
||||||
@@ -1047,6 +1001,11 @@ export default {
|
|||||||
const i = Math.floor(Math.log(bytes) / Math.log(k));
|
const i = Math.floor(Math.log(bytes) / Math.log(k));
|
||||||
return parseFloat((bytes / Math.pow(k, i)).toFixed(2)) + " " + sizes[i];
|
return parseFloat((bytes / Math.pow(k, i)).toFixed(2)) + " " + sizes[i];
|
||||||
},
|
},
|
||||||
|
/** 格式化上传时间 */
|
||||||
|
formatUploadTime(time) {
|
||||||
|
const formatted = parseTime(time, "{y}-{m}-{d} {h}:{i}:{s}");
|
||||||
|
return formatted || "-";
|
||||||
|
},
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
@@ -1322,77 +1281,6 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 统计卡片区域
|
|
||||||
.statistics-section {
|
|
||||||
display: grid;
|
|
||||||
grid-template-columns: repeat(4, 1fr);
|
|
||||||
gap: 16px;
|
|
||||||
margin-bottom: 16px;
|
|
||||||
|
|
||||||
.stat-card {
|
|
||||||
background: #fff;
|
|
||||||
border-radius: 4px;
|
|
||||||
padding: 20px;
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
gap: 16px;
|
|
||||||
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
|
|
||||||
cursor: pointer;
|
|
||||||
transition: all 0.3s;
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
transform: translateY(-2px);
|
|
||||||
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
|
|
||||||
}
|
|
||||||
|
|
||||||
.stat-icon {
|
|
||||||
width: 48px;
|
|
||||||
height: 48px;
|
|
||||||
border-radius: 50%;
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
justify-content: center;
|
|
||||||
font-size: 24px;
|
|
||||||
|
|
||||||
&.uploading {
|
|
||||||
background: rgba(64, 158, 255, 0.1);
|
|
||||||
color: #409eff;
|
|
||||||
}
|
|
||||||
|
|
||||||
&.parsing {
|
|
||||||
background: rgba(230, 162, 60, 0.1);
|
|
||||||
color: #e6a23c;
|
|
||||||
}
|
|
||||||
|
|
||||||
&.success {
|
|
||||||
background: rgba(103, 194, 58, 0.1);
|
|
||||||
color: #67c23a;
|
|
||||||
}
|
|
||||||
|
|
||||||
&.failed {
|
|
||||||
background: rgba(245, 108, 108, 0.1);
|
|
||||||
color: #f56c6c;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.stat-content {
|
|
||||||
flex: 1;
|
|
||||||
|
|
||||||
.stat-label {
|
|
||||||
font-size: 14px;
|
|
||||||
color: #909399;
|
|
||||||
margin-bottom: 4px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.stat-value {
|
|
||||||
font-size: 24px;
|
|
||||||
font-weight: 600;
|
|
||||||
color: #303133;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// 文件列表区域
|
// 文件列表区域
|
||||||
.file-list-section {
|
.file-list-section {
|
||||||
background: #fff;
|
background: #fff;
|
||||||
@@ -1523,9 +1411,6 @@ export default {
|
|||||||
gap: 16px;
|
gap: 16px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.statistics-section {
|
|
||||||
grid-template-columns: repeat(2, 1fr);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@media (max-width: 768px) {
|
@media (max-width: 768px) {
|
||||||
@@ -1551,10 +1436,6 @@ export default {
|
|||||||
grid-template-columns: 1fr;
|
grid-template-columns: 1fr;
|
||||||
}
|
}
|
||||||
|
|
||||||
.statistics-section {
|
|
||||||
grid-template-columns: 1fr;
|
|
||||||
}
|
|
||||||
|
|
||||||
.file-list-section .list-toolbar {
|
.file-list-section .list-toolbar {
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
align-items: flex-start;
|
align-items: flex-start;
|
||||||
|
|||||||
@@ -60,6 +60,7 @@ import ParamConfig from "./components/detail/ParamConfig";
|
|||||||
import PreliminaryCheck from "./components/detail/PreliminaryCheck";
|
import PreliminaryCheck from "./components/detail/PreliminaryCheck";
|
||||||
import SpecialCheck from "./components/detail/SpecialCheck";
|
import SpecialCheck from "./components/detail/SpecialCheck";
|
||||||
import DetailQuery from "./components/detail/DetailQuery";
|
import DetailQuery from "./components/detail/DetailQuery";
|
||||||
|
import {getProject} from "@/api/ccdiProject";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "ProjectDetail",
|
name: "ProjectDetail",
|
||||||
@@ -111,7 +112,43 @@ export default {
|
|||||||
/** 初始化页面数据 */
|
/** 初始化页面数据 */
|
||||||
initPageData() {
|
initPageData() {
|
||||||
// 这里应该从API获取项目详细信息
|
// 这里应该从API获取项目详细信息
|
||||||
this.mockProjectInfo();
|
if (!this.projectId) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
this.projectInfo.projectName = "";
|
||||||
|
this.updatePageTitle();
|
||||||
|
getProject(this.projectId)
|
||||||
|
.then((res) => {
|
||||||
|
const data = res.data || {};
|
||||||
|
this.projectInfo = {
|
||||||
|
...this.projectInfo,
|
||||||
|
...data,
|
||||||
|
projectId: data.projectId || this.projectId,
|
||||||
|
projectName: data.projectName || "",
|
||||||
|
projectDesc: data.projectDesc || data.description || "",
|
||||||
|
projectStatus: String(
|
||||||
|
data.projectStatus !== undefined && data.projectStatus !== null
|
||||||
|
? data.projectStatus
|
||||||
|
: data.status !== undefined && data.status !== null
|
||||||
|
? data.status
|
||||||
|
: this.projectInfo.projectStatus
|
||||||
|
),
|
||||||
|
};
|
||||||
|
this.updatePageTitle();
|
||||||
|
})
|
||||||
|
.catch(() => {
|
||||||
|
this.$message.error("Failed to load project details");
|
||||||
|
this.updatePageTitle();
|
||||||
|
});
|
||||||
|
},
|
||||||
|
updatePageTitle() {
|
||||||
|
const title = this.projectInfo.projectName || `ProjectDetail-${this.projectId}`;
|
||||||
|
this.$route.meta.title = title;
|
||||||
|
this.$store.dispatch("settings/setTitle", title);
|
||||||
|
this.$store.dispatch("tagsView/updateVisitedView", {
|
||||||
|
path: this.$route.path,
|
||||||
|
title,
|
||||||
|
});
|
||||||
},
|
},
|
||||||
/** 格式化更新时间 */
|
/** 格式化更新时间 */
|
||||||
formatUpdateTime(time) {
|
formatUpdateTime(time) {
|
||||||
@@ -217,7 +254,7 @@ export default {
|
|||||||
},
|
},
|
||||||
/** 刷新页面 */
|
/** 刷新页面 */
|
||||||
handleRefresh() {
|
handleRefresh() {
|
||||||
this.mockProjectInfo();
|
this.initPageData();
|
||||||
this.$message.success("刷新成功");
|
this.$message.success("刷新成功");
|
||||||
},
|
},
|
||||||
/** 导出报告 */
|
/** 导出报告 */
|
||||||
|
|||||||
Reference in New Issue
Block a user