打通结果总览项目分析弹窗入口

This commit is contained in:
wkc
2026-03-25 14:02:45 +08:00
parent 2793cf437c
commit b14eef8482
6 changed files with 199 additions and 3 deletions

View File

@@ -0,0 +1,50 @@
const assert = require("assert");
const fs = require("fs");
const path = require("path");
const entry = fs.readFileSync(
path.resolve(
__dirname,
"../../src/views/ccdiProject/components/detail/PreliminaryCheck.vue"
),
"utf8"
);
const people = fs.readFileSync(
path.resolve(
__dirname,
"../../src/views/ccdiProject/components/detail/RiskPeopleSection.vue"
),
"utf8"
);
const model = fs.readFileSync(
path.resolve(
__dirname,
"../../src/views/ccdiProject/components/detail/RiskModelSection.vue"
),
"utf8"
);
[
'import ProjectAnalysisDialog from "./ProjectAnalysisDialog";',
"ProjectAnalysisDialog",
"projectAnalysisDialogVisible",
"<project-analysis-dialog",
':visible.sync="projectAnalysisDialogVisible"',
].forEach((token) => assert(entry.includes(token), token));
[
'@view-project-analysis="handleRiskPeopleProjectAnalysis"',
'@view-project-analysis="handleRiskModelProjectAnalysis"',
].forEach((token) => assert(entry.includes(token), token));
[
'@click="handleViewProject(scope.row)"',
'$emit("view-project-analysis", row)',
'scope.row.actionLabel || "查看项目"',
].forEach((token) => assert(people.includes(token), token));
[
'@click="handleViewProject(scope.row)"',
'$emit("view-project-analysis", row)',
'scope.row.actionLabel || "查看项目"',
].forEach((token) => assert(model.includes(token), token));

View File

@@ -0,0 +1,29 @@
const assert = require("assert");
const fs = require("fs");
const path = require("path");
const entry = fs.readFileSync(
path.resolve(
__dirname,
"../../src/views/ccdiProject/components/detail/PreliminaryCheck.vue"
),
"utf8"
);
[
"currentProjectAnalysisPerson",
"projectAnalysisSource",
"openProjectAnalysisDialog(source, person)",
'this.projectAnalysisSource = source || "riskPeople"',
"this.currentProjectAnalysisPerson = person || null",
"this.projectAnalysisDialogVisible = true",
'this.openProjectAnalysisDialog("riskPeople", row)',
'this.openProjectAnalysisDialog("riskModelPeople", row)',
'projectAnalysisSource: "riskPeople"',
].forEach((token) => assert(entry.includes(token), token));
[
':person="currentProjectAnalysisPerson"',
':source="projectAnalysisSource"',
"@close=\"handleProjectAnalysisDialogClose\"",
].forEach((token) => assert(entry.includes(token), token));