Commit 40eff0bb authored by jiaxu.yan's avatar jiaxu.yan

Merge branch 'develop' of http://gitlab.91isoft.com:90/car-test/web into developer/yanjiaxu

# Conflicts:
#	src/utils/ModelDataSource.js
#	src/views/setting/standardTerms/components/vehicleModelDialog.vue
#	src/views/setting/testMatrix/index.vue
parents 5b70c2c7 ed7b7171
import request from '@/utils/request'
//获取任务详情
export function taskDetail(data) {
return request({
......
......@@ -115,4 +115,3 @@
top: 20px;
transform: translateX(100%);
}
......@@ -17,25 +17,23 @@
<!-- 上传按钮 -->
<el-button size="mini" type="primary">选取文件</el-button>
<!-- 上传提示 -->
<!-- <div class="el-upload__tip" slot="tip" v-if="showTip">-->
<!-- 请上传-->
<!-- <template v-if="fileSize">-->
<!-- 大小不超过 <b style="color: #f56c6c">{{ fileSize }}MB</b>-->
<!-- </template>-->
<!-- <template v-if="fileType">-->
<!-- 格式为 <b style="color: #f56c6c">{{ fileType.join('/') }}</b>-->
<!-- </template>-->
<!-- 的文件-->
<!-- </div>-->
<!-- <div class="el-upload__tip" slot="tip" v-if="showTip">-->
<!-- 请上传-->
<!-- <template v-if="fileSize">-->
<!-- 大小不超过 <b style="color: #f56c6c">{{ fileSize }}MB</b>-->
<!-- </template>-->
<!-- <template v-if="fileType">-->
<!-- 格式为 <b style="color: #f56c6c">{{ fileType.join('/') }}</b>-->
<!-- </template>-->
<!-- 的文件-->
<!-- </div>-->
<div class="el-upload__tip" slot="tip" v-if="showTip">
只能上传
<template v-if="fileType">
{{ fileType.join('/') }}
</template>
文件,
<template v-if="fileSize">
且不得超过{{ fileSize }}MB
</template>
<template v-if="fileSize"> 且不得超过{{ fileSize }}MB </template>
</div>
</el-upload>
......
......@@ -22,16 +22,16 @@
</el-upload>
<!-- 上传提示 -->
<!-- <div class="el-upload__tip" slot="tip" v-if="showTip">-->
<!-- 请上传-->
<!-- <template v-if="fileSize">-->
<!-- 大小不超过 <b style="color: #f56c6c">{{ fileSize }}MB</b>-->
<!-- </template>-->
<!-- <template v-if="fileType">-->
<!-- 格式为 <b style="color: #f56c6c">{{ fileType.join('/') }}</b>-->
<!-- </template>-->
<!-- 的文件-->
<!-- </div>-->
<!-- <div class="el-upload__tip" slot="tip" v-if="showTip">-->
<!-- 请上传-->
<!-- <template v-if="fileSize">-->
<!-- 大小不超过 <b style="color: #f56c6c">{{ fileSize }}MB</b>-->
<!-- </template>-->
<!-- <template v-if="fileType">-->
<!-- 格式为 <b style="color: #f56c6c">{{ fileType.join('/') }}</b>-->
<!-- </template>-->
<!-- 的文件-->
<!-- </div>-->
<div class="el-upload__tip" slot="tip" v-if="showTip">
只能上传
......@@ -39,16 +39,10 @@
{{ fileType.join('/') }}
</template>
文件,
<template v-if="fileSize">
且不得超过{{ fileSize }}MB
</template>
<template v-if="fileSize"> 且不得超过{{ fileSize }}MB </template>
</div>
<el-dialog
:visible.sync="dialogVisible"
width="800"
append-to-body
>
<el-dialog :visible.sync="dialogVisible" width="800" append-to-body>
<img
:src="dialogImageUrl"
style="display: block; max-width: 100%; margin: 0 auto"
......
......@@ -216,5 +216,4 @@ export default {
border: 1px solid #1a6fd7;
color: #1a6fd7;
}
</style>
......@@ -213,5 +213,4 @@ export default {
border: 1px solid #1a6fd7;
color: #1a6fd7;
}
</style>
......@@ -117,7 +117,7 @@ export default {
list-style-type: none;
margin-top: 5px;
padding: 0;
width:100%;
width: 100%;
li {
margin: 10px 0;
cursor: pointer;
......
......@@ -100,7 +100,7 @@ Vue.component('FooterButton', FooterButton)
Vue.use(directive)
Vue.use(plugins)
Vue.use(VueMeta)
import ModelDataSource from './utils/ModelDataSource';
import ModelDataSource from './utils/ModelDataSource'
Vue.use(ModelDataSource)
DictData.install()
......
......@@ -2,9 +2,9 @@
* Model 数据源
* 用于 单条记录的增删查改
*/
import _ from "lodash"
import request from "@/utils/request"
function ModelDataSource(vm, settings) {
import _ from 'lodash'
import request from '@/utils/request'
function ModelDataSource(vm, settings) {
this.vm = vm
this.settings = settings
this.errors = {}
......@@ -12,8 +12,8 @@
// this.dataKey = settings.
// this.defaultAttributes = settings.attributes;
this.init()
}
ModelDataSource.prototype = {
}
ModelDataSource.prototype = {
vm: null,
settings: null,
uuid: 0,
......@@ -50,18 +50,7 @@
data: params
})
.then(function (response) {
console.log(response)
if (response.data) {
for (let key in response.data) {
self[key] = response.data[key]
}
} else {
for (let key in response.data) {
self[key] = response.data[key]
}
}
successCallback()
successCallback(response)
})
.catch(function (error) {
failedCallback()
......@@ -93,7 +82,16 @@
data: _.omit(self, ['vm', 'settings', 'errors', 'debug'])
})
.then(function (response) {
successCallback(response)
if (response.data) {
for (let key in response.data) {
self[key] = response.data[key]
}
} else {
for (let key in response.data) {
self[key] = response.data[key]
}
}
successCallback()
})
.catch(function (error) {
// console.log(error.response)
......@@ -152,16 +150,16 @@
return ''
})
}
}
}
/**
/**
* Vue Plugin
*/
ModelDataSource.install = function (Vue) {
ModelDataSource.install = function (Vue) {
Vue.prototype.$modelDataSource = function (options) {
console.log(this, options);
console.log(this, options)
return new ModelDataSource(this, options)
}
}
}
export default ModelDataSource
export default ModelDataSource
......@@ -64,10 +64,10 @@
>新建</el-button
>
</el-col>
<right-toolbar
:show-search.sync="showSearch"
@queryTable="getList"
></right-toolbar>
<!-- <right-toolbar-->
<!-- :show-search.sync="showSearch"-->
<!-- @queryTable="getList"-->
<!-- ></right-toolbar>-->
</el-row>
<el-table
......@@ -328,18 +328,24 @@
label-width="100px"
>
<el-form-item label="商标:" prop="trademark">
<div v-if="clickNameForm.trademark">
<image-preview
:src="clickNameForm.trademark"
width="150px"
height="150px"
></image-preview>
</div>
<div v-else>暂无数据</div>
</el-form-item>
<el-form-item label="样品照片:" prop="samplePhotos">
<div v-if="clickNameForm.samplePhotos">
<image-preview
:src="clickNameForm.samplePhotos"
width="150px"
height="150px"
></image-preview>
</div>
<div v-else>暂无数据</div>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
......
......@@ -50,12 +50,12 @@
</el-form-item>
</el-form>
</div>
<div>
<right-toolbar
:show-search.sync="showSearch"
@queryTable="loadData"
></right-toolbar>
</div>
<!-- <div>-->
<!-- <right-toolbar-->
<!-- :show-search.sync="showSearch"-->
<!-- @queryTable="loadData"-->
<!-- ></right-toolbar>-->
<!-- </div>-->
</div>
<el-table
v-if="refreshTable"
......@@ -93,7 +93,6 @@
label="测试场景"
prop="testScenario"
min-width="200"
sortable
align="left"
>
</el-table-column>
......
<template>
<el-dialog
:visible.sync="dialogManger.dialogVisible"
:title="modelTitle"
title="修改"
width="1200"
append-to-body
destroy-on-close
......@@ -11,6 +11,7 @@
<el-form-item label="标准分类" prop="standardType">
<el-select
v-model="model.standardType"
disabled
style="width: 100%"
placeholder="请选择"
clearable
......@@ -96,7 +97,7 @@ export default {
data() {
return {
model: this.$modelDataSource({
url: '/standard/getInfo',
url: '/standard',
dataKey: 'model',
attributes: {
standardType: '',
......@@ -129,11 +130,11 @@ export default {
}
}
},
computed: {
modelTitle() {
return this.dialogManger.dialogEditId ? '编辑标准' : '新增标准'
}
},
// computed: {
// modelTitle() {
// return this.dialogManger.dialogEditId ? '编辑标准' : '新增标准'
// }
// },
watch: {
'dialogManger.dialogEditId'(newValue) {
this.model.fetch(
......
......@@ -20,16 +20,16 @@
prop="standardType"
align="left"
>
<!-- <template slot-scope="scope">-->
<!-- <div v-for="dict in classFicationList" :key="dict.dictValue">-->
<!-- <div-->
<!-- v-if="dict.dictValue == scope.row.standardType"-->
<!-- style="display: flex"-->
<!-- >-->
<!-- {{ dict.dictLabel }}-->
<!-- </div>-->
<!-- </div>-->
<!-- </template>-->
<template slot-scope="scope">
<div v-for="dict in classFicationList" :key="dict.dictValue">
<div
v-if="dict.dictValue == scope.row.standardType"
style="display: flex"
>
{{ dict.dictLabel }}
</div>
</div>
</template>
</el-table-column>
<el-table-column
prop="standardNo"
......@@ -43,7 +43,13 @@
label="标准名称"
min-width="200"
align="left"
/>
>
<template slot-scope="scope">
<div class="font-color" @click="downPdf(scope.row)">
{{ scope.row.name }}
</div>
</template>
</el-table-column>
<el-table-column
prop="standardStatus"
label="标准状态"
......@@ -116,6 +122,7 @@
ref="TixiDialog"
:dialog-manger="TixiDialogManger"
@close="TixiDialogManger.dialogVisible = false"
@refresh="TixiDialogManger.refreshList = true"
></tixi-dialog>
</page-standard>
</template>
......@@ -163,6 +170,10 @@ export default {
})
},
methods: {
downPdf(row) {
console.log('row', row)
window.open(process.env.VUE_APP_IMAGE_API + row.file)
},
viewTemplate() {
// this.$router.push({
// path: '/processing/reviewReport'
......@@ -199,7 +210,7 @@ export default {
<style scoped>
.font-color {
text-decoration: underline;
color: #1890ff;
color: #1a6fd7;
cursor: pointer;
}
</style>
......@@ -17,20 +17,27 @@
<tbody>
<!-- 循环遍历 keyPointList -->
<template v-for="(i, PointIndex) in tableData.keyPointList">
<tr :key="'PointIndex-2' + PointIndex">
<tr :key="'PointIndex' + PointIndex">
<td align="center" :rowspan="getRows(i)">
{{ i.text }}
</td>
</tr>
<!-- 循环遍历 reviewDetailsList -->
<template v-for="(v, reviewDetailIndex) in i.reviewDetailsList">
<tr :key="'reviewDetailIndex-3' + PointIndex + reviewDetailIndex">
<tr :key="'reviewDetailIndex' + PointIndex + reviewDetailIndex">
<td align="center">
{{ v.text }}
</td>
<td align="center">
<template v-for="(a, reviewSceneIndex) in v.reviewSceneList">
<div :key="'reviewSceneIndex-3' + reviewSceneIndex">
<div
:key="
'reviewSceneIndex' +
PointIndex +
reviewDetailIndex +
reviewSceneIndex
"
>
<span>{{ a.text }}</span>
<br />
</div>
......
......@@ -54,12 +54,12 @@
</el-form-item>
</el-form>
</div>
<div>
<right-toolbar
:show-search.sync="showSearch"
@queryTable="loadData"
></right-toolbar>
</div>
<!-- <div>-->
<!-- <right-toolbar-->
<!-- :show-search.sync="showSearch"-->
<!-- @queryTable="loadData"-->
<!-- ></right-toolbar>-->
<!-- </div>-->
</div>
<el-table
v-loading="loading"
......
......@@ -3,7 +3,7 @@
<page-standard>
<el-table
v-loading="loading"
height="calc(100vh - 300px)"
height="calc(100vh - 135px)"
:data="tableData"
border
:header-cell-style="headerCellStyle"
......@@ -215,8 +215,8 @@ export default {
}
} else {
cell.style.backgroundColor = '#F3F8FD'
for (var v = 1; v < selrange.length; v++) {
selrange[v].style.backgroundColor = '#F3F8FD'
for (var a = 1; a < selrange.length; a++) {
selrange[a].style.backgroundColor = '#F3F8FD'
}
}
}
......
......@@ -50,12 +50,12 @@
</el-form-item>
</el-form>
</div>
<div>
<right-toolbar
:show-search.sync="showSearch"
@queryTable="loadData"
></right-toolbar>
</div>
<!-- <div>-->
<!-- <right-toolbar-->
<!-- :show-search.sync="showSearch"-->
<!-- @queryTable="loadData"-->
<!-- ></right-toolbar>-->
<!-- </div>-->
</div>
<el-table
v-if="refreshTable"
......@@ -93,7 +93,6 @@
label="测试类型"
prop="testType"
min-width="200"
sortable
align="left"
>
</el-table-column>
......
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