2 changed files with 244 additions and 98 deletions
@ -0,0 +1,238 @@ |
|||||
|
<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.applyPeoName }}</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> |
||||
|
<span style="margin-left: 5px">{{ formobj.modpriceReason }}</span> |
||||
|
</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.baseModelModpriceModels" :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" header-align="center" width="250"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.vehicleAlias }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="常用配置" align="left" header-align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.configName }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column prop="applyForDeposit" label="成本价" header-align="center" align="center" width="150"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.costPrice }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="现销售指导价(万元)" header-align="center" align="center" width="150"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.remarks }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="价格增减数额" header-align="center" align="center" width="200"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.incOrDecInPrice }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="备注" header-align="center" width="200"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.remarks }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
</div> |
||||
|
</div> |
||||
|
<!--End 添加修改部分--> |
||||
|
<span class="el-icon-picture-outline">流程图</span> |
||||
|
<flow :xmlData="xmlData" :taskData="taskList"></flow> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import req from '@/api/kucunguanli/price' |
||||
|
import flow from '../../../baseoutsourcingapplication/workflow/flow' |
||||
|
|
||||
|
export default { |
||||
|
name: 'tiaojiaInfo', |
||||
|
components: { |
||||
|
flow |
||||
|
}, |
||||
|
data() { |
||||
|
return { |
||||
|
dialogStatus: '', |
||||
|
index: 0, |
||||
|
tableKey: 0, |
||||
|
xmlData: '', // 模型xml数据 |
||||
|
taskList: [], |
||||
|
// 表单数据 |
||||
|
formobj: {}, |
||||
|
// 环节所需参数 |
||||
|
linkByParameter: { |
||||
|
businessSid: '', |
||||
|
comment: '', |
||||
|
instanceId: '', |
||||
|
taskId: '', |
||||
|
orgSidPath: '', |
||||
|
taskDefKey: '', |
||||
|
userSid: '' |
||||
|
}, |
||||
|
rules: {} |
||||
|
} |
||||
|
}, |
||||
|
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)) |
||||
|
// 点击(同意、终止、驳回、驳回)操作时所需的参数 |
||||
|
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 |
||||
|
}) |
||||
|
// 子页面向父级页面传递值 |
||||
|
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; |
||||
|
} |
||||
|
</style> |
||||
|
|
Loading…
Reference in new issue