Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
W
web
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
中汽测评-信息安全测评系统
web
Commits
c4e60f89
Commit
c4e60f89
authored
Mar 19, 2024
by
mzx
Committed by
jiaxu.yan
Mar 19, 2024
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat(查看试验方案): 接口对接
parent
2a963f72
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
59 additions
and
74 deletions
+59
-74
test.js
src/api/task/test.js
+9
-0
reviewDetailsTable.js
src/utils/reviewDetailsTable.js
+13
-0
index.vue
src/views/processing/carTest/review-form/index.vue
+37
-74
No files found.
src/api/task/test.js
0 → 100644
View file @
c4e60f89
import
request
from
'@/utils/request'
export
function
testDetail
(
data
)
{
return
request
({
url
:
'/car/test/task/getById'
,
method
:
'post'
,
data
})
}
src/utils/reviewDetailsTable.js
View file @
c4e60f89
...
...
@@ -10,6 +10,19 @@ export function getRows(i) {
return
n
+
1
}
/**
* 根据章节号合并单元格
* @param {*} i 章节号
*/
export
function
getRows3
(
i
)
{
let
n
=
0
if
(
i
.
testCaseList
)
{
n
=
i
.
testCaseList
.
length
}
return
n
+
1
}
/**
* 根据要求合并单元格
* @param {*} i 标准要求
...
...
src/views/processing/carTest/review-form/index.vue
View file @
c4e60f89
...
...
@@ -50,7 +50,6 @@
<!--查看试验方案列表-->
<div>
<div
class=
"form-review-questionnaire"
>
<!--查看试验方案列表-->
<table
class=
"table"
>
<col
style=
"width: 100px"
/>
<thead>
...
...
@@ -68,60 +67,40 @@
</tr>
</thead>
<tbody>
<!-- 循环遍历 keyPointList -->
<template
v-for=
"(i, PointIndex) in tableData.keyPointList"
>
<template
v-for=
"(i, PointIndex) in tableData"
>
<tr
:key=
"'PointIndex1' + PointIndex"
>
<td
align=
"center"
:rowspan=
"getRows(i)"
>
{{
'7.1.1'
}}
<td
align=
"center"
:rowspan=
"getRows
3
(i)"
>
{{
i
.
chapter
}}
</td>
<td
align=
"center"
:rowspan=
"getRows(i)"
>
<td
align=
"center"
:rowspan=
"getRows
3
(i)"
>
{{
i
.
text
}}
</td>
<td
align=
"center"
:rowspan=
"getRows(i)"
>
{{
i
.
te
xt
}}
<td
align=
"center"
:rowspan=
"getRows
3
(i)"
>
{{
i
.
te
stMethod
}}
</td>
</tr>
<!-- 循环遍历 reviewDetailsList -->
<template
v-for=
"(v, reviewDetailIndex) in i.reviewDetailsList"
>
<tr
:key=
"'reviewDetailIndex' + PointIndex + reviewDetailIndex"
>
<td
align=
"center"
>
{{
'测试场景'
}}
<template
v-for=
"(v, testCaseIndex) in i.testCaseList"
>
<tr
:key=
"'testCaseIndex' + PointIndex + testCaseIndex"
>
<td
align=
"center"
rowspan=
"1"
>
{{
v
.
testScenario
}}
</td>
<td
align=
"center"
>
{{
'测试类型'
}}
<td
align=
"center"
rowspan=
"1"
>
{{
v
.
testType
}}
</td>
<td
align=
"center"
>
{{
'用例编号'
}}
<td
align=
"center"
rowspan=
"1"
>
{{
v
.
usecaseNo
}}
</td>
<td
align=
"center"
>
{{
'用例名称'
}}
<td
align=
"center"
rowspan=
"1"
>
{{
v
.
name
}}
</td>
<td
align=
"center"
>
{{
'工具'
}}
<td
align=
"center"
rowspan=
"1"
>
{{
v
.
tools
}}
</td>
<td
align=
"center"
>
{{
v
.
tex
t
}}
<td
align=
"center"
rowspan=
"1"
>
{{
v
.
inpu
t
}}
</td>
<td
align=
"center"
>
<template
v-for=
"(a, reviewSceneIndex) in v.reviewSceneList"
>
<div
:key=
"
'reviewSceneIndex' +
PointIndex +
reviewDetailIndex +
reviewSceneIndex
"
>
<span>
{{
reviewSceneIndex
+
1
+
'、'
+
a
.
text
}}
</span>
<br
/>
</div>
</
template
>
<td
align=
"center"
rowspan=
"1"
>
{{
v
.
description
}}
</td>
</tr>
</
template
>
...
...
@@ -148,9 +127,10 @@
</template>
<!--js逻辑-->
<
script
>
import
{
getRows
,
getRows2
}
from
'../../../../utils/reviewDetailsTable'
import
{
getRows
3
}
from
'../../../../utils/reviewDetailsTable'
import
routerMixins
from
'@/mixins/router'
import
{
listInspection
}
from
'../../../../api/setting/standardTerms'
import
{
testDetail
}
from
'../../../../api/task/test'
import
{
getBySubtaskId
}
from
'../../../../api/task/task'
export
default
{
name
:
'Index'
,
mixins
:
[
routerMixins
],
...
...
@@ -169,39 +149,22 @@ export default {
}
},
mounted
()
{
this
.
init
()
this
.
getTestDetail
()
this
.
getTest
()
},
methods
:
{
/**
* 获取任务详情
*/
async
getTest
()
{
// this.loading = true
// const res = await reviewTaskDetail({
// taskId: '1767377960098127873'
// })
// this.loading = false
// if (res.code === 200) {
// await this.getTaskDetail()
// this.model = res.data
// } else {
// this.$modal.msgError(res.msg)
// }
getRows3
,
getTest
()
{
getBySubtaskId
({
taskId
:
'1768527384203460609'
}).
then
(
res
=>
{
if
(
res
===
200
)
{
this
.
task
=
res
.
data
}
})
},
// async getTaskDetail() {
// const result = await getBySubtaskId({
// id: '1767377960098127873'
// })
// if (result.code === 200) {
// this.task = result.data
// }
// }
getRows
,
getRows2
,
/** 获取体系审查、车型审查检验内容 */
init
()
{
/** 获取任务详情 */
getTestDetail
()
{
this
.
loading
=
true
listInspection
({
id
:
'1744181159757221888
'
}).
then
(
res
=>
{
testDetail
({
taskId
:
'1768527384203460609
'
}).
then
(
res
=>
{
this
.
tableData
=
res
.
data
this
.
loading
=
false
})
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment