Commit 1124e0f9 authored by jiaxu.yan's avatar jiaxu.yan

feat(适配接口改动): 适配接口改动 修改页面 未完成任务 车型检查表单 确认审查结果

parent 4b44127f
......@@ -354,15 +354,9 @@ export default {
})
},
goUpdate() {
if (this.type === '1') {
this.$router.push({
path: '/processing/write-check-form?id=' + this.taskId
})
} else {
this.$router.push({
path: '/processing/type-check-form?id=' + this.taskId
})
}
this.$router.push({
path: '/processing/write-check-form?id=' + this.taskId
})
},
getRows,
getRows2
......
......@@ -282,6 +282,7 @@ export default {
data() {
return {
isShow: true,
auditRequirement: 0,
testScenarioList: [
{ value: 0, label: 'TBOX-蜂窝以太网接口', check: false },
......@@ -446,19 +447,17 @@ export default {
amount3: 15
}
],
taskId: ''
}
},
created() {
if (this.dataList.length > 0) {
const firstItem = this.dataList[0]
this.columns = Object.keys(firstItem)
taskId: '',
type: ''
}
},
mounted() {
if (this.$route.query.id) {
this.taskId = this.$route.query.id
}
if (this.$route.query.type) {
this.type = this.$route.query.type
}
this.getTask()
},
methods: {
......
......@@ -57,7 +57,7 @@
clearable
>
<el-option
v-for="dict in dict.type.sys_job_status"
v-for="dict in dict.type.system_task_status"
:key="dict.value"
:label="dict.label"
:value="dict.value"
......@@ -147,7 +147,7 @@
<script>
import page from '@/mixins/page'
export default {
dicts: ['sys_job_status', 'sys_scene_type', 'task_type'],
dicts: ['system_task_status', 'sys_scene_type', 'task_type'],
mixins: [page],
data() {
return {
......
......@@ -26,7 +26,11 @@
</div>
<!-- 步骤条 -->
<div class="top-content">
<div v-for="(item, index) in detailsList" :key="index">
<div
v-for="(item, index) in detailsList"
:key="index"
class="top-content-item"
>
<div
:class="{
'exclamation-point': item.warn,
......@@ -44,11 +48,11 @@
>
<span class="inner-text">{{ index + 1 }}</span>
</div>
<span
v-show="item.result && item.result.passed !== null"
class="tick-class"
>
<i class="el-icon-check" />
<span class="tick-class">
<i
v-show="item.result && item.result.passed !== null"
class="el-icon-check"
/>
</span>
</div>
</div>
......@@ -550,13 +554,20 @@ export default {
flex-direction: row;
/* 设置为纵向排列 */
flex-wrap: wrap;
.top-content-item {
display: flex;
// flex-direction: row;
justify-content: space-between;
align-items: center;
width: 100px;
}
/* 当容器不足时自动换行 */
.tick-class {
float: right;
// float: right;
position: relative;
top: -1.8em;
left: -1em;
width: 20px;
// top: -1.8em;
// left: -1em;
i {
color: #25c173;
......
......@@ -56,7 +56,7 @@
clearable
>
<el-option
v-for="dict in dict.type.sys_job_status"
v-for="dict in dict.type.system_task_status"
:key="dict.value"
:label="dict.label"
:value="dict.value"
......@@ -179,7 +179,7 @@
>
<span v-if="item.reviewStatus !== 'NEW'"
>{{ item.reviewStatus !== 'FINISH' ? '(共耗时' : '已耗时('
}}{{ getHourDiff(item.taskBeginTime) }})</span
}}{{ getHourDiff(item.systemTaskBeginTime) }})</span
>
</div>
</template>
......@@ -210,7 +210,7 @@
>
<span v-if="item.carReviewStatus !== 'NEW'"
>{{ item.carReviewStatus !== 'FINISH' ? '(共耗时' : '已耗时('
}}{{ getHourDiff(item.taskBeginTime) }})</span
}}{{ getHourDiff(item.carTaskBeginTime) }})</span
>
</div>
</template>
......@@ -269,7 +269,7 @@
></el-progress>
</div>
<div
v-if="item.carReviewStatus && item.carReviewStatus !== 'NONE'"
v-if="item.carTestStatus && item.carTestStatus !== 'NONE'"
class="cell-item"
>
<el-progress
......@@ -374,9 +374,10 @@ import taskDialog from './components/dialog'
import { getHourDiff } from '@/utils/diff'
import { mapGetters } from 'vuex'
import { reviewTaskStart, reviewCarTaskStart } from '@/api/task/task'
import request from '@/utils/request'
export default {
dicts: [
'sys_job_status',
'system_task_status',
'system_review_test_btn',
'test_cartype_type_btn',
'test_cartype_task_btn',
......@@ -406,29 +407,29 @@ export default {
...mapGetters(['userId'])
},
methods: {
// loadData() {
// this.loading = true
// request({
// url: this.listUrl,
// method: 'post',
// data: this.queryParams
// })
// .then(res => {
// if (res.code === 200) {
// console.log(res.rows)
// res.rows[0].carReviewStatus = 'CONFIRM'
// this.tableData = res.rows
// this.total = res.total
// }
// this.loading = false
// })
// .catch(error => {
// if (error.msg) {
// this.$message.error(error.msg)
// }
// this.loading = false
// })
// },
loadData() {
this.loading = true
request({
url: this.listUrl,
method: 'post',
data: this.queryParams
})
.then(res => {
if (res.code === 200) {
console.log(res.rows)
res.rows[0].carReviewStatus = 'FINISH'
this.tableData = res.rows
this.total = res.total
}
this.loading = false
})
.catch(error => {
if (error.msg) {
this.$message.error(error.msg)
}
this.loading = false
})
},
/**
* 企业留档文件
* @param item 对象
......@@ -583,6 +584,11 @@ export default {
path: '/processing/confirm-result?type=1&id=' + id
})
break
case 'FINISH':
this.$router.push({
path: '/processing/confirm-result?type=2&id=' + id
})
break
}
},
// 车型测试
......@@ -626,13 +632,13 @@ export default {
// 确认车型检验结果
case 'CONFIRM':
this.$router.push({
path: '/processing/vehicle-type?id=' + id
path: '/processing/vehicle-type?type=1&id=' + id
})
break
// 查看车型审查记录
case 'FINISH':
this.$router.push({
path: '/processing/vehicle-type'
path: '/processing/vehicle-type?type=2&id=' + id
})
}
},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment