9 changed files with 720 additions and 213 deletions
@ -0,0 +1,371 @@ |
|||
<template> |
|||
<div class="app-container"> |
|||
<div> |
|||
<div class="tab-header webtop"> |
|||
<div>选择车辆页面</div> |
|||
<div> |
|||
<el-button type="primary" size="small" @click="AddUpdateReturn">确定</el-button> |
|||
<el-button type="info" size="small" @click="handleReturn()">关闭</el-button> |
|||
</div> |
|||
</div> |
|||
<div class=""> |
|||
<div class="searchcon"> |
|||
<el-button size="small" class="searchbtn" @click="clicksearchShow">{{ searchxianshitit }}</el-button> |
|||
<div v-show="isSearchShow" class="search"> |
|||
<el-form ref="listQueryform" :inline="true" :model="listQuery" label-width="100px" class="tab-header"> |
|||
<el-row> |
|||
<el-form-item label="品牌:" class="searchlist"> |
|||
<el-select v-model="listQuery.params.brandSid" placeholder="请选择" filterable clearable> |
|||
<el-option v-for="item in carBrand_list" :key="item.sid" :label="item.brandName" :value="item.sid"/> |
|||
</el-select> |
|||
</el-form-item> |
|||
<el-form-item label="功能:" class="searchlist"> |
|||
<el-select v-model="listQuery.params.vehicleType" placeholder="请选择" filterable clearable> |
|||
<el-option v-for="item in vehicleType_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictKey"/> |
|||
</el-select> |
|||
</el-form-item> |
|||
<el-form-item label="系列:" class="searchlist"> |
|||
<el-select v-model="listQuery.params.productLine" placeholder="请选择" filterable clearable> |
|||
<el-option v-for="item in productLine_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictKey"/> |
|||
</el-select> |
|||
</el-form-item> |
|||
<el-form-item label="变速箱:" class="searchlist"> |
|||
<el-select v-model="listQuery.params.gearboxType" placeholder="请选择" filterable clearable> |
|||
<el-option v-for="item in gearboxType_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictKey"/> |
|||
</el-select> |
|||
</el-form-item> |
|||
<el-form-item label="驱动:" class="searchlist"> |
|||
<el-select v-model="listQuery.params.driveForm" placeholder="请选择" filterable clearable> |
|||
<el-option v-for="item in driveForm_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictKey"/> |
|||
</el-select> |
|||
</el-form-item> |
|||
<el-form-item label="排放标准:" class="searchlist"> |
|||
<el-select v-model="listQuery.params.emissionStandard" placeholder="请选择" filterable clearable> |
|||
<el-option v-for="item in emissionStandard_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictKey"/> |
|||
</el-select> |
|||
</el-form-item> |
|||
</el-row> |
|||
<el-row> |
|||
<el-form-item label="马力:" class="searchlist"> |
|||
<el-select v-model="listQuery.params.power" placeholder="请选择" filterable clearable> |
|||
<el-option v-for="item in power_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictKey"/> |
|||
</el-select> |
|||
</el-form-item> |
|||
<el-form-item label="燃料:" class="searchlist"> |
|||
<el-select v-model="listQuery.params.fuelType" placeholder="请选择" filterable clearable> |
|||
<el-option v-for="item in fuelType_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictKey"/> |
|||
</el-select> |
|||
</el-form-item> |
|||
<el-form-item label="版本:" class="searchlist"> |
|||
<el-select v-model="listQuery.params.vehicleVersion" placeholder="请选择" filterable clearable> |
|||
<el-option v-for="item in vehicleVersion_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictKey"/> |
|||
</el-select> |
|||
</el-form-item> |
|||
<el-form-item label="车型:" class="searchlist"> |
|||
<el-input v-model="listQuery.params.vehicleAlias" placeholder="" clearable style="width: 150px"/> |
|||
</el-form-item> |
|||
<el-form-item label="快捷检索:" class="searchlist"> |
|||
<el-input v-model="listQuery.params.modelName" placeholder="" clearable style="width: 150px"/> |
|||
</el-form-item> |
|||
</el-row> |
|||
</el-form> |
|||
<div class="btn" style="text-align: center;"> |
|||
<el-button type="primary" @click="handleFilter" size="small">查询</el-button> |
|||
<el-button type="primary" @click="handleReset" size="small">重置</el-button> |
|||
</div> |
|||
</div> |
|||
</div> |
|||
<div class="listtop"> |
|||
<div class="tit">现车库存列表</div> |
|||
<!-- <pageye v-show="list.length > 0" :total="listQuery.total" :page.sync="listQuery.current" :limit.sync="listQuery.size" class="pagination" @pagination="getList"/>--> |
|||
</div> |
|||
<div class=""> |
|||
<el-table :key="tableKey" ref="multipleTable" v-loading="listLoading" :data="list" border style="width: 100%" @selection-change="handleSelectionChange"> |
|||
<el-table-column width="50px" type="selection" align="center"/> |
|||
<el-table-column width="80px" label="序号" type="index" :index="indexMethod" align="center"/> |
|||
<el-table-column label="品牌" align="center"> |
|||
<template slot-scope="scope"> |
|||
<span>{{ scope.row.brandName }}</span> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column label="车型" align="center"> |
|||
<template slot-scope="scope"> |
|||
<span>{{ scope.row.vehicleAlias }}</span> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column label="车架号" align="center"> |
|||
<template slot-scope="scope"> |
|||
<span>{{ scope.row.vinNo }}</span> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column label="颜色" align="center"> |
|||
<template slot-scope="scope"> |
|||
<span>{{ scope.row.color }}</span> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column label="存放地点" align="center"> |
|||
<template slot-scope="scope"> |
|||
<span>{{ scope.row.location }}</span> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column label="销售指导价(万元)" align="center"> |
|||
<template slot-scope="scope"> |
|||
<span>{{ scope.row.guidedPrice }}</span> |
|||
</template> |
|||
</el-table-column> |
|||
</el-table> |
|||
</div> |
|||
<div class="pages"> |
|||
<div class="tit"/> |
|||
<!-- 翻页 --> |
|||
<Pagination v-show="list.length > 0" :total="listQuery.total" :page.sync="listQuery.current" :limit.sync="listQuery.size" class="pagination" @pagination="getList"/> |
|||
</div> |
|||
</div> |
|||
</div> |
|||
</div> |
|||
</template> |
|||
|
|||
<script> |
|||
import Pagination from '@/components/pagination' |
|||
import req from '@/api/weishoumaiduan/unsold' |
|||
import { typeValues, brandDown, getPathSidByUserSid } from '@/api/cheliang/dictcommons.js' |
|||
|
|||
export default { |
|||
name: 'vehicle', |
|||
components: { |
|||
Pagination |
|||
}, |
|||
data() { |
|||
return { |
|||
useOrg: '', |
|||
carBrand_list: [], |
|||
vehicleType_list: [], |
|||
productLine_list: [], |
|||
gearboxType_list: [], |
|||
driveForm_list: [], |
|||
emissionStandard_list: [], |
|||
power_list: [], |
|||
fuelType_list: [], |
|||
vehicleVersion_list: [], |
|||
isSearchShow: false, |
|||
searchxianshitit: '隐藏查询条件', |
|||
tableKey: 0, |
|||
showbackState: 30, |
|||
sids: [], |
|||
list: [], |
|||
number: '', |
|||
listLoading: false, |
|||
listQuery: { |
|||
current: 1, |
|||
size: 10, |
|||
params: { |
|||
brandSid: '', |
|||
driveForm: '', |
|||
emissionStandard: '', |
|||
fuelType: '', |
|||
gearboxType: '', |
|||
modelName: '', |
|||
power: '', |
|||
productLine: '', |
|||
vehicleAlias: '', |
|||
vehicleType: '', |
|||
vehicleVersion: '', |
|||
userSid: '', |
|||
vinNoList: [] |
|||
}, |
|||
total: 1 |
|||
} |
|||
} |
|||
}, |
|||
methods: { |
|||
// 搜索条件效果 |
|||
clicksearchShow() { |
|||
this.isSearchShow = !this.isSearchShow |
|||
if (this.isSearchShow) { |
|||
this.searchxianshitit = '隐藏查询条件' |
|||
} else { |
|||
this.searchxianshitit = '显示查询条件' |
|||
} |
|||
}, |
|||
init() { |
|||
this.getPathSid() |
|||
this.shujuzidian() |
|||
this.getList() |
|||
}, |
|||
getPathSid() { |
|||
const userSid = window.sessionStorage.getItem('userSid') |
|||
getPathSidByUserSid({ userSid: userSid }).then((res) => { |
|||
if (res.success) { |
|||
this.useOrg = res.data |
|||
} |
|||
}) |
|||
}, |
|||
shujuzidian() { |
|||
// 下拉框-品牌 |
|||
brandDown({ useOrg: this.useOrg }).then((res) => { |
|||
if (res.success) { |
|||
this.carBrand_list = res.data |
|||
console.log('下拉框请求品牌', res.data) |
|||
} |
|||
}) |
|||
typeValues({ type: 'vehicleFunction' }).then((res) => { |
|||
if (res.success) { |
|||
this.vehicleType_list = res.data |
|||
} |
|||
}) |
|||
typeValues({ type: 'productLine' }).then((res) => { |
|||
if (res.code === '200') { |
|||
this.productLine_list = res.data |
|||
} |
|||
}) |
|||
typeValues({ type: 'driver' }).then((res) => { |
|||
if (res.code === '200') { |
|||
this.driveForm_list = res.data |
|||
} |
|||
}) |
|||
typeValues({ type: 'horsepower' }).then((res) => { |
|||
if (res.code === '200') { |
|||
this.power_list = res.data |
|||
} |
|||
}) |
|||
typeValues({ type: 'vehicleVersion' }).then((res) => { |
|||
if (res.code === '200') { |
|||
this.vehicleVersion_list = res.data |
|||
} |
|||
}) |
|||
typeValues({ type: 'fuelType' }).then((res) => { |
|||
if (res.code === '200') { |
|||
this.fuelType_list = res.data |
|||
} |
|||
}) |
|||
typeValues({ type: 'gearbox' }).then((res) => { |
|||
if (res.code === '200') { |
|||
this.gearboxType_list = res.data |
|||
} |
|||
}) |
|||
typeValues({ type: 'emissionStandard' }).then((res) => { |
|||
if (res.code === '200') { |
|||
this.emissionStandard_list = res.data |
|||
} |
|||
}) |
|||
}, |
|||
indexMethod(index) { |
|||
var pagestart = (this.listQuery.current - 1) * this.listQuery.size |
|||
var pageindex = index + 1 + pagestart |
|||
return pageindex |
|||
}, |
|||
// 返回 |
|||
handleReturn() { |
|||
this.$emit('doback') |
|||
}, |
|||
// 查询列表信息 |
|||
getList() { |
|||
this.listLoading = true |
|||
req.pageList(this.listQuery).then((response) => { |
|||
this.listLoading = false |
|||
if (response.success) { |
|||
this.listQuery.total = response.data.total |
|||
this.list = response.data.records |
|||
} |
|||
}) |
|||
this.listQuery.params.vinNoList = [] |
|||
}, |
|||
// 查询按钮 |
|||
handleFilter() { |
|||
this.getList() |
|||
}, |
|||
// 重置按钮 |
|||
handleReset() { |
|||
this.listQuery = { |
|||
current: 1, |
|||
size: 10, |
|||
params: { |
|||
brandSid: '', |
|||
driveForm: '', |
|||
emissionStandard: '', |
|||
fuelType: '', |
|||
gearboxType: '', |
|||
modelName: '', |
|||
power: '', |
|||
productLine: '', |
|||
vehicleAlias: '', |
|||
vehicleType: '', |
|||
vehicleVersion: '', |
|||
userSid: window.sessionStorage.getItem('userSid'), |
|||
vinNoList: [] |
|||
}, |
|||
total: 0 |
|||
} |
|||
this.getList() |
|||
}, |
|||
handleSelectionChange(row) { |
|||
this.sids = [] |
|||
const aa = [] |
|||
row.forEach((element) => { |
|||
aa.push({ |
|||
vinNo: element.vinNo, |
|||
vehicleAlias: element.vehicleAlias, |
|||
priceDate: element.priceDate, |
|||
priced: element.priced |
|||
}) |
|||
}) |
|||
this.sids = aa |
|||
}, |
|||
showData(value) { |
|||
const aa = [] |
|||
if (value.length > 0) { |
|||
for (var i = 0; i < value.length; i++) { |
|||
aa.push(value[i].vinNo) |
|||
} |
|||
this.listQuery.params.vinNoList = aa |
|||
} else { |
|||
this.listQuery.params.vinNoList = [] |
|||
} |
|||
this.listQuery.params.userSid = window.sessionStorage.getItem('userSid') |
|||
this.init() |
|||
}, |
|||
// 添加修改返回 |
|||
AddUpdateReturn() { |
|||
if (this.sids.length > 0) { |
|||
this.$emit('backData', this.sids) |
|||
} else { |
|||
this.$notify({ |
|||
title: '提示', |
|||
message: '请选择至少一条车型记录!', |
|||
type: 'error', |
|||
duration: 2000 |
|||
}) |
|||
} |
|||
} |
|||
} |
|||
} |
|||
</script> |
|||
<style scoped> |
|||
.btn { |
|||
padding: 15px 0 15px 0; |
|||
border: 1px solid #e0e3eb; |
|||
} |
|||
|
|||
.tab-header { |
|||
background-color: #edf1f7; |
|||
padding: 8px 20px; |
|||
margin-bottom: 0 !important; |
|||
} |
|||
|
|||
.tab-header /deep/ .el-form-item { |
|||
margin-bottom: 10px; |
|||
} |
|||
.listtop { |
|||
display: flex; |
|||
justify-content: space-between; |
|||
align-items: center; |
|||
border: 1px solid #dfe4ed; |
|||
height: 40px; |
|||
} |
|||
.tit { |
|||
margin-bottom: -10px; |
|||
} |
|||
.pagination { |
|||
margin-bottom: -10px; |
|||
} |
|||
</style> |
@ -0,0 +1,239 @@ |
|||
<template> |
|||
<div class="app-container"> |
|||
<div> |
|||
<!--标题按钮部分开始--> |
|||
<div class="tab-header webtop"> |
|||
<!--标题--> |
|||
<div>车辆未售买断详情</div> |
|||
<!--start 添加修改按钮--> |
|||
<div> |
|||
<el-button type="danger" @click="openRevoke()">撤 回 </el-button> |
|||
</div> |
|||
</div> |
|||
<!--标题按钮部分结束--> |
|||
<!--Start 新增修改部分--> |
|||
<div class="listconadd"> |
|||
<div class="wlInfo"><span>车辆未售买断申请</span></div> |
|||
<el-form ref="form_obj" :model="formobj" :rules="rules" label-position="top"> |
|||
<el-row> |
|||
<el-col :span="4"> |
|||
<span>申请日期:</span> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<span style="margin-left: 5px">{{ formobj.createTime }}</span> |
|||
</el-col> |
|||
<el-col :span="4"> |
|||
<span>申请人:</span> |
|||
</el-col> |
|||
<el-col :span="8"> |
|||
<span style="margin-left: 5px">{{ formobj.applicationName }}</span> |
|||
</el-col> |
|||
</el-row> |
|||
<el-row> |
|||
<el-col :span="4" class="el-form-item-right"> |
|||
<span>买断原因:</span> |
|||
</el-col> |
|||
<el-col :span="20"> |
|||
<el-form-item> |
|||
{{ formobj.reason }} |
|||
</el-form-item> |
|||
</el-col> |
|||
</el-row> |
|||
</el-form> |
|||
<div class="tableStyle"> |
|||
<div style="margin-left: 5px;font-weight: bold">车辆列表</div> |
|||
</div> |
|||
<el-table :key="tableKey" :data="formobj.detailsList" :index="index" border style="width: 100%"> |
|||
<el-table-column fixed width="80px" label="序号" type="index" :index="index + 1" align="center"/> |
|||
<el-table-column label="车架号" align="center"> |
|||
<template slot-scope="scope"> |
|||
<span>{{ scope.row.vinNo }}</span> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column label="车型" align="center"> |
|||
<template slot-scope="scope"> |
|||
<span>{{ scope.row.modelName }}</span> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column label="入库日期" align="center"> |
|||
<template slot-scope="scope"> |
|||
<span>{{ scope.row.inboundDate }}</span> |
|||
</template> |
|||
</el-table-column> |
|||
<el-table-column label="入库价" align="center"> |
|||
<template slot-scope="scope"> |
|||
<span>{{ scope.row.inboundPrice }}</span> |
|||
</template> |
|||
</el-table-column> |
|||
</el-table> |
|||
</div> |
|||
</div> |
|||
<!--End 添加修改部分--> |
|||
<span class="el-icon-picture-outline">流程图</span> |
|||
<flow :xmlData="xmlData" :taskData="taskList"></flow> |
|||
<!--End 添加修改部分--> |
|||
</div> |
|||
</template> |
|||
|
|||
<script> |
|||
import req from '@/api/weishoumaiduan/unsold' |
|||
import flow from '../../../baseoutsourcingapplication/workflow/flow' |
|||
|
|||
export default { |
|||
name: 'weishoumaiduanYiBanInfo', |
|||
components: { |
|||
flow |
|||
}, |
|||
data() { |
|||
return { |
|||
dialogStatus: '', |
|||
viewState: 1, |
|||
index: 0, |
|||
tableKey: 0, |
|||
list1: [], |
|||
xmlData: '', // 模型xml数据 |
|||
taskList: [], |
|||
// 表单数据 |
|||
formobj: {}, |
|||
rules: {}, |
|||
transactState: '', // 办理状态 |
|||
// 环节所需参数 |
|||
linkByParameter: { |
|||
businessSid: '', |
|||
comment: '', |
|||
instanceId: '', |
|||
taskId: '', |
|||
orgSidPath: '', |
|||
taskDefKey: '', |
|||
userSid: '' |
|||
} |
|||
} |
|||
}, |
|||
created() { |
|||
console.log('url:' + window.location.href) |
|||
var one = window.location.href.indexOf('&data') + 6 |
|||
const data = window.location.href.substr(one) // url解码unescape()已从web中移除,尽量不使用 |
|||
const obj = JSON.parse(decodeURIComponent(data)) |
|||
console.log('iframe页面获取的obj:', obj) |
|||
// 点击(同意、终止、驳回、驳回)操作时所需的参数 |
|||
this.linkByParameter.businessSid = obj.businessSid |
|||
this.linkByParameter.instanceId = obj.instanceId |
|||
this.linkByParameter.taskId = obj.taskId |
|||
this.linkByParameter.taskDefKey = obj.taskDefKey |
|||
this.linkByParameter.orgSidPath = window.sessionStorage.getItem('orgSidPath') |
|||
this.linkByParameter.userSid = window.sessionStorage.getItem('userSid') |
|||
// 加载表单数据 |
|||
this.showInfo(obj.businessSid) |
|||
// 加载流程图相关的数据 |
|||
this.getModelDetail(obj.deployId) |
|||
this.getFlowViewer(obj.instanceId) |
|||
}, |
|||
mounted() { |
|||
window.parent.postMessage({ |
|||
cmd: 'returnHeight', |
|||
params: { |
|||
// 告诉父级页面,子页面的弹框高度。 |
|||
code: 2, |
|||
data: document.body.scrollHeight + 'px' |
|||
} |
|||
}, '*') |
|||
}, |
|||
methods: { |
|||
showInfo(sid) { |
|||
req.fetchBySid(sid).then((res) => { |
|||
if (res.success) { |
|||
this.formobj = res.data |
|||
} |
|||
}) |
|||
}, |
|||
/** xml 文件 */ |
|||
getModelDetail(deployId) { |
|||
// 发送请求,获取xml |
|||
req.readXml(deployId).then((res) => { |
|||
this.xmlData = res.data |
|||
}) |
|||
}, |
|||
// 已办环节的节点 |
|||
getFlowViewer(procInsId) { |
|||
req.getFlowViewer(procInsId).then((res) => { |
|||
this.taskList = res.data |
|||
}) |
|||
}, |
|||
/** 确认撤回任务 */ |
|||
openRevoke() { |
|||
this.$confirm('是否确认执行撤回操作', '提示', { |
|||
confirmButtonText: '确定', |
|||
cancelButtonText: '取消', |
|||
type: 'warning' |
|||
}).then(() => { |
|||
this.handleRevoke() |
|||
}).catch(() => { |
|||
this.$message({ |
|||
type: 'info', |
|||
message: '已取消撤回' |
|||
}) |
|||
}) |
|||
}, |
|||
/** 撤回任务 */ |
|||
handleRevoke() { |
|||
req.revokeProcess(this.linkByParameter).then((response) => { |
|||
if (response.success) { |
|||
this.$notify({ |
|||
title: '提示', |
|||
message: '执行成功', |
|||
type: 'success', |
|||
duration: 2000 |
|||
}) |
|||
this.nodeDialogVisible = false |
|||
// 子页面向父级页面传递值 |
|||
window.parent.postMessage({ |
|||
cmd: 'returnHeight', |
|||
params: { |
|||
// 操作成功,告诉父级页面关闭弹框 |
|||
code: 1 |
|||
} |
|||
}, '*') |
|||
} |
|||
}) |
|||
} |
|||
} |
|||
} |
|||
</script> |
|||
|
|||
<style scoped> |
|||
.wlInfo { |
|||
text-align: center; |
|||
font-size: 28px; |
|||
line-height: 90px; |
|||
} |
|||
.tableStyle { |
|||
background-color: #FFFFFF; |
|||
display: flex; |
|||
justify-content: flex-start; |
|||
align-items: center; |
|||
border: 1px solid #dfe4ed; |
|||
height: 40px; |
|||
} |
|||
/deep/ .el-col-4 { |
|||
text-align: right; |
|||
float: left; |
|||
font-size: 14px; |
|||
color: #606266; |
|||
line-height: 40px !important; |
|||
font-weight: 600; |
|||
} |
|||
/deep/ .el-col-8 { |
|||
text-align: left; |
|||
float: left; |
|||
font-size: 14px; |
|||
color: #606266; |
|||
line-height: 40px !important; |
|||
font-weight: 600; |
|||
} |
|||
|
|||
.icon { |
|||
color: #e84026; |
|||
margin-right: 4px; |
|||
} |
|||
</style> |
|||
|
Loading…
Reference in new issue