Browse Source

完善单车返利管理

master
yunuo970428 3 years ago
parent
commit
7bdd010481
  1. 56
      anrui-scm/anrui-scm-ui/src/api/bikerebate/bicyclerebatemanagement.js
  2. 11
      anrui-scm/anrui-scm-ui/src/api/cheliang/dictcommons.js
  3. 133
      anrui-scm/anrui-scm-ui/src/views/bikerebate/bikerebatemanagement/bicyclerebatemanagement.vue
  4. 288
      anrui-scm/anrui-scm-ui/src/views/bikerebate/bikerebatemanagement/bicyclerebatemanagementAdd.vue
  5. 333
      anrui-scm/anrui-scm-ui/src/views/bikerebate/bikerebatemanagement/bicyclerebatemanagementByVehicle.vue
  6. 303
      anrui-scm/anrui-scm-ui/src/views/bikerebate/bikerebatemanagement/bicyclerebatemanagementEdit.vue
  7. 119
      anrui-scm/anrui-scm-ui/src/views/bikerebate/bikerebatemanagement/bicyclerebatemanagementInfo.vue

56
anrui-scm/anrui-scm-ui/src/api/bikerebate/bicyclerebatemanagement.js

@ -0,0 +1,56 @@
import request from '@/utils/request'
export default {
// 查询分页列表
listPage: function(data) {
return request({
url: '/scm/v1/scmvehrebate/listPage',
method: 'post',
data: data,
headers: { 'Content-Type': 'application/json' }
})
},
// 选择车辆信息--查询分页列表
pageList: function(data) {
return request({
url: '/base/v1/basevehicle/vehicleRebateList',
method: 'post',
data: data,
headers: { 'Content-Type': 'application/json' }
})
},
// 删除
delete: function(params) {
return request({
url: '/scm/v1/scmvehrebate/delBySids',
method: 'DELETE',
data: params,
headers: { 'Content-Type': 'application/json' }
})
},
// 新增保存修改记录
save: function(data) {
return request({
url: '/scm/v1/scmvehrebate/save',
method: 'post',
data: data,
headers: { 'Content-Type': 'application/json' }
})
},
// 编辑保存修改记录
update: function(data) {
return request({
url: '/scm/v1/scmvehrebate/update',
method: 'post',
data: data,
headers: { 'Content-Type': 'application/json' }
})
},
// 通过sid查询一条记录
fetchBySid: function(data) {
return request({
url: '/scm/v1/scmvehrebate/fetchDetailsBySid/' + data,
method: 'get'
})
}
}

11
anrui-scm/anrui-scm-ui/src/api/cheliang/dictcommons.js

@ -26,16 +26,6 @@ export function getListOrg(data) {
})
}
// 获取厂商
export function getNamesDownes(data) {
return request({
url: '/base/v1/basemanufacturer/namesDown',
method: 'get',
params: data,
data: qs.stringify(data),
})
}
// 根据登陆人sid查询分公司 (孟哲写的接口)
export function getPathSidByUserSid(data) {
return request({
@ -69,7 +59,6 @@ export function getGressionUserList(data) {
})
}
// 根据当前登录用户分公司sid获取本分公司下存放地点
export function fetchByUseOrgSid(data) {
return request({

133
anrui-scm/anrui-scm-ui/src/views/bikerebate/bikerebatemanagement/bicyclerebatemanagement.vue

@ -9,13 +9,15 @@
<div v-show="isSearchShow" class="search">
<el-form ref="listQueryform" :inline="true" :model="listQuery" label-width="100px" class="tab-header">
<el-form-item label="品牌">
<el-input v-model="listQuery.params.mainSid" placeholder="请输入车架号" clearable/>
<el-select v-model="listQuery.params.brandSid" placeholder="请选择" filterable clearable>
<el-option v-for="item in brand_list" :key="item.sid" :label="item.brandName" :value="item.sid"/>
</el-select>
</el-form-item>
<el-form-item label="车型">
<el-input v-model="listQuery.params.mainSid" placeholder="请输入车架号" clearable/>
<el-input v-model="listQuery.params.vehModelName" placeholder="" clearable/>
</el-form-item>
<el-form-item label="车架号">
<el-input v-model="listQuery.params.mainSid" placeholder="请输入车架号" clearable/>
<el-input v-model="listQuery.params.vinNo" placeholder="" clearable/>
</el-form-item>
<el-form-item label="创建日期">
<el-date-picker v-model="listQuery.params.createStartTime" type="date" clearable value-format="yyyy-MM-dd" placeholder="选择日期"/>
@ -23,13 +25,17 @@
<el-date-picker v-model="listQuery.params.createEndTime" type="date" clearable value-format="yyyy-MM-dd" placeholder="选择日期"/>
</el-form-item>
<el-form-item label="返利类型">
<el-input v-model="listQuery.params.mainSid" placeholder="请输入车架号" clearable/>
<el-select v-model="listQuery.params.rebateTypeKey" placeholder="请选择" filterable clearable>
<el-option v-for="item in rebateType_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictKey"/>
</el-select>
</el-form-item>
<el-form-item label="返利名称">
<el-input v-model="listQuery.params.mainSid" placeholder="请输入车架号" clearable/>
<el-input v-model="listQuery.params.rebateName" placeholder="" clearable/>
</el-form-item>
<el-form-item label="状态">
<el-input v-model="listQuery.params.mainSid" placeholder="请输入车架号" clearable/>
<el-select v-model="listQuery.params.state" placeholder="请选择" filterable clearable>
<el-option v-for="item in state_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictKey"/>
</el-select>
</el-form-item>
</el-form>
<div class="btn" style="text-align: center;">
@ -56,112 +62,112 @@
</el-table-column>
<el-table-column label="状态" align="center" width="200">
<template slot-scope="scope">
<span>{{ scope.row.nodeState }}</span>
<span>{{ scope.row.state === '0' ? '未计提' : scope.row.state === '1' ? '已计提' : scope.row.state === '2' ? '已核对' : '' }}</span>
</template>
</el-table-column>
<el-table-column label="品牌" align="center" width="200">
<template slot-scope="scope">
<span>{{ scope.row.createTime }}</span>
<span>{{ scope.row.brandName }}</span>
</template>
</el-table-column>
<el-table-column label="车型" align="center" width="200">
<template slot-scope="scope">
<span>{{ scope.row.applyPeoName }}</span>
<span>{{ scope.row.vehModelName }}</span>
</template>
</el-table-column>
<el-table-column label="车架号" align="center" width="250">
<template slot-scope="scope">
<span>{{ scope.row.createOrgName }}</span>
<span>{{ scope.row.vinNo }}</span>
</template>
</el-table-column>
<el-table-column label="厂家结算价" align="center" width="200">
<template slot-scope="scope">
<span>{{ scope.row.applyTitle }}</span>
<span>{{ scope.row.manufactorSettlementPrice }}</span>
</template>
</el-table-column>
<el-table-column label="其中运费" align="center" width="200">
<template slot-scope="scope">
<span>{{ scope.row.modpriceReason }}</span>
<span>{{ scope.row.freight }}</span>
</template>
</el-table-column>
<el-table-column label="创建日期" align="center" width="120">
<template slot-scope="scope">
<span>{{ scope.row.modpriceReason }}</span>
<span>{{ scope.row.createTime }}</span>
</template>
</el-table-column>
<el-table-column label="返利类型" align="center" width="150">
<template slot-scope="scope">
<span>{{ scope.row.modpriceReason }}</span>
<span>{{ scope.row.rebateTypeValue }}</span>
</template>
</el-table-column>
<el-table-column label="返利名称" align="center" width="150">
<template slot-scope="scope">
<span>{{ scope.row.modpriceReason }}</span>
<span>{{ scope.row.rebateName }}</span>
</template>
</el-table-column>
<el-table-column label="计算标准" align="center" width="100">
<template slot-scope="scope">
<span>{{ scope.row.modpriceReason }}</span>
<span>{{ scope.row.calculationStandard }}</span>
</template>
</el-table-column>
<el-table-column label="预计返利" align="center" width="120">
<template slot-scope="scope">
<span>{{ scope.row.modpriceReason }}</span>
<span>{{ scope.row.estimateRebate }}</span>
</template>
</el-table-column>
<el-table-column label="所属年月" align="center" width="120">
<template slot-scope="scope">
<span>{{ scope.row.modpriceReason }}</span>
<span>{{ scope.row.palceGenDate }}</span>
</template>
</el-table-column>
<el-table-column label="预提日期" align="center" width="120">
<template slot-scope="scope">
<span>{{ scope.row.modpriceReason }}</span>
<span>{{ scope.row.withholdingDate }}</span>
</template>
</el-table-column>
<el-table-column label="上传日期" align="center" width="120">
<template slot-scope="scope">
<span>{{ scope.row.modpriceReason }}</span>
<span>{{ scope.row.uploadDate }}</span>
</template>
</el-table-column>
<el-table-column label="上传金额" align="center" width="150">
<template slot-scope="scope">
<span>{{ scope.row.modpriceReason }}</span>
<span>{{ scope.row.uploadMoney }}</span>
</template>
</el-table-column>
<el-table-column label="二次上传日期" align="center" width="120">
<template slot-scope="scope">
<span>{{ scope.row.modpriceReason }}</span>
<span>{{ scope.row.secondaryUploadDate }}</span>
</template>
</el-table-column>
<el-table-column label="二次上传金额" align="center" width="120">
<template slot-scope="scope">
<span>{{ scope.row.modpriceReason }}</span>
<span>{{ scope.row.secondaryUploadMoney }}</span>
</template>
</el-table-column>
<el-table-column label="待确定金额" align="center" width="120">
<template slot-scope="scope">
<span>{{ scope.row.modpriceReason }}</span>
<span>{{ scope.row.stayDetermineMoney }}</span>
</template>
</el-table-column>
<el-table-column label="费用" align="center" width="120">
<template slot-scope="scope">
<span>{{ scope.row.modpriceReason }}</span>
<span>{{ scope.row.money }}</span>
</template>
</el-table-column>
<el-table-column label="是否调整" align="center" width="100">
<template slot-scope="scope">
<span>{{ scope.row.modpriceReason }}</span>
<span>{{ scope.row.isAdjustment }}</span>
</template>
</el-table-column>
<el-table-column label="调整金额" align="center" width="100">
<template slot-scope="scope">
<span>{{ scope.row.modpriceReason }}</span>
<span>{{ scope.row.adjustmentMoney }}</span>
</template>
</el-table-column>
<el-table-column label="调整说明" align="center" width="120">
<template slot-scope="scope">
<span>{{ scope.row.modpriceReason }}</span>
<span>{{ scope.row.adjustmentRemarks }}</span>
</template>
</el-table-column>
</el-table>
@ -172,17 +178,20 @@
</div>
</div>
</div>
<bicyclerebatemanagementAdd v-show="viewState == 2 || viewState == 3" ref="divAdd" @doback="resetState" @reloadlist="getList"/>
<bicyclerebatemanagementAdd v-show="viewState == 2" ref="divAdd" @doback="resetState" @reloadlist="getList"/>
<bicyclerebatemanagementEdit v-show="viewState == 3" ref="divEdit" @doback="resetState" @reloadlist="getList"/>
<bicyclerebatemanagementInfo v-show="viewState == 4" ref="divInfo" @doback="resetState"/>
</div>
</template>
<script>
import req from '@/api/othermenu/shangzhuangtiaojia'
import req from '@/api/bikerebate/bicyclerebatemanagement'
import Pagination from '@/components/pagination'
import pageye from '@/components/pagination/pageye'
import ButtonBar from '@/components/ButtonBar'
import { getPathSidByUserSid, typeValues, brandDown } from '@/api/cheliang/dictcommons'
import bicyclerebatemanagementAdd from './bicyclerebatemanagementAdd'
import bicyclerebatemanagementEdit from './bicyclerebatemanagementEdit'
import bicyclerebatemanagementInfo from './bicyclerebatemanagementInfo'
export default {
@ -192,6 +201,7 @@ export default {
pageye,
ButtonBar,
bicyclerebatemanagementAdd,
bicyclerebatemanagementEdit,
bicyclerebatemanagementInfo
},
data() {
@ -229,18 +239,40 @@ export default {
],
isSearchShow: false,
searchxianshitit: '显示查询条件',
viewState: 4,
viewState: 1,
// -----------
tableKey: 0,
list: [],
sids: [],
FormLoading: false,
listLoading: false,
brand_list: [],
rebateType_list: [],
state_list: [
{
dictKey: 0,
dictValue: '未计提'
},
{
dictKey: 1,
dictValue: '已计提'
},
{
dictKey: 2,
dictValue: '已核对'
}
],
listQuery: {
params: {
createBySid: '',
createOrgSid: '',
createEndTime: '',
createStartTime: ''
createStartTime: '',
rebateName: '',
rebateTypeKey: '',
state: '',
vinNo: '',
vehModelName: '',
brandSid: ''
},
current: 1,
size: 5,
@ -251,12 +283,30 @@ export default {
},
created() {
//
this.getList()
this.init()
},
mounted() {
this.$refs['btnbar'].setButtonList(this.btnList)
},
methods: {
init() {
typeValues({ type: 'rebateType' }).then((res) => {
if (res.success) {
this.rebateType_list = res.data
}
})
getPathSidByUserSid({ userSid: window.sessionStorage.getItem('userSid') }).then((resp) => {
if (resp.success) {
this.listQuery.params.createOrgSid = resp.data
brandDown({ useOrg: this.listQuery.params.createOrgSid }).then((res) => {
if (res.success) {
this.brand_list = res.data
}
})
this.getList()
}
})
},
//
clicksearchShow() {
this.isSearchShow = !this.isSearchShow
@ -302,7 +352,6 @@ export default {
//
getList() {
this.listLoading = true
this.listQuery.params.createBySid = window.sessionStorage.getItem('userSid')
req.listPage(this.listQuery).then((response) => {
console.log('列表查询结果:', response)
this.listLoading = false
@ -323,15 +372,21 @@ export default {
handleReset() {
this.listQuery = {
params: {
createBySid: '',
createOrgSid: '',
createEndTime: '',
createStartTime: ''
createStartTime: '',
rebateName: '',
rebateTypeKey: '',
state: '',
vinNo: '',
vehModelName: '',
brandSid: ''
},
current: 1,
size: 5,
total: 0
}
this.getList()
this.init()
},
toAdd() {
this.viewState = 2
@ -339,7 +394,7 @@ export default {
},
toEdit(row) {
this.viewState = 3
this.$refs['divAdd'].showEdit(row)
this.$refs['divEdit'].showEdit(row)
},
toInfo(row) {
this.viewState = 4

288
anrui-scm/anrui-scm-ui/src/views/bikerebate/bikerebatemanagement/bicyclerebatemanagementAdd.vue

@ -22,19 +22,23 @@
<span>返利类型</span>
</el-col>
<el-col :span="4">
<el-form-item><span>{{ formobj.createOrgName }}</span></el-form-item>
<el-form-item>
<el-select v-model="formobj.rebateTypeValue" placeholder="请选择" filterable clearable @change="changeRebateType">
<el-option v-for="item in rebateType_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictValue"/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="4" class="tleftb">
<span>厂家返利名称</span>
</el-col>
<el-col :span="4">
<el-form-item><span>{{ formobj.applyPeoName }}</span></el-form-item>
<el-form-item><el-input v-model="formobj.rebateName" class="addinputw" placeholder="" clearable></el-input></el-form-item>
</el-col>
<el-col :span="4" class="tleftb">
<span>所属年月</span>
</el-col>
<el-col :span="4">
<el-form-item><span>{{ formobj.createTime }}</span></el-form-item>
<el-form-item><el-date-picker v-model="formobj.palceGenDate" type="date" clearable value-format="yyyy-MM-dd" placeholder="选择日期"/></el-form-item>
</el-col>
</el-row>
<el-row>
@ -42,23 +46,27 @@
<span>计算方式</span>
</el-col>
<el-col :span="4">
<el-form-item><el-input v-model="formobj.modpriceReason" clearable placeholder="" class="addinputw"></el-input></el-form-item>
<el-form-item>
<el-select v-model="formobj.calculationModeValue" placeholder="请选择" filterable clearable @change="changeCalculationMode">
<el-option v-for="item in calculationMode_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictValue"/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="4" class="tleftb">
<span>计算标注(%)</span>
<span>计算标(%)</span>
</el-col>
<el-col :span="12">
<el-form-item><el-input v-model="formobj.modpriceReason" clearable placeholder="" class="addinputw"></el-input></el-form-item>
<el-form-item><el-input v-model="formobj.calculationStandard" @keyup.native="UpNumber" clearable placeholder="" class="addinputw"></el-input></el-form-item>
</el-col>
</el-row>
<div class="title">
<div>返利车辆列表</div>
<div>
<el-button type="primary" size="mini" icon="el-icon-plus" @click="addjacket()">添加</el-button>
<el-button type="primary" size="mini" icon="el-icon-plus" @click="addjacket()">批量选择</el-button>
<el-button type="primary" size="mini" icon="el-icon-plus" class="btntopblueline">添加</el-button>
<el-button type="primary" size="mini" icon="el-icon-plus" class="btntopblueline" @click="addjacket()">批量选择</el-button>
</div>
</div>
<el-table :key="tableKey" :data="formobj.baseVehinstallModpricedetails" :index="index" border style="width: 100%">
<el-table :key="tableKey" :data="formobj.scmVehRebateVehs" :index="index" border style="width: 100%" show-summary :summary-method="getSummaries">
<el-table-column fixed width="80px" label="序号" type="index" :index="index + 1" align="center"/>
<el-table-column fixed prop="name" label="操作" width="100px" align="center" header-align="center">
<template slot-scope="scope">
@ -68,27 +76,27 @@
</el-table-column>
<el-table-column label="车架号" align="center">
<template slot-scope="scope">
<span>{{ scope.row.jacketName }}</span>
<span>{{ scope.row.vinNo }}</span>
</template>
</el-table-column>
<el-table-column label="厂家结算价" align="center">
<template slot-scope="scope">
<span>{{ scope.row.vinNo }}</span>
<span>{{ scope.row.manufactorSettlementPrice }}</span>
</template>
</el-table-column>
<el-table-column label="其中运费" align="center">
<template slot-scope="scope">
<span>{{ scope.row.modelName }}</span>
<span>{{ scope.row.freight }}</span>
</template>
</el-table-column>
<el-table-column label="预计返利" align="center">
<el-table-column prop="estimateRebate" label="预计返利" align="center">
<template slot-scope="scope">
<el-input v-model="scope.row.vehGuidedPrice" clearable placeholder="" class="addinputw"></el-input>
<span>{{ estimateRebate(scope.row) }}</span>
</template>
</el-table-column>
<el-table-column label="备注" align="center">
<template slot-scope="scope">
<span>{{ scope.row.costPrice }}</span>
<el-input v-model="scope.row.remarks" clearable placeholder="" class="addinputw"></el-input>
</template>
</el-table-column>
</el-table>
@ -96,112 +104,169 @@
</div>
</div>
<!--End 添加修改部分-->
<bicyclerebatemanagementByVehicle v-show="viewState == 2" ref="divSelect" @backData="backData" @doback="resetState"/>
</div>
</template>
<script>
import req from '@/api/othermenu/shangzhuangtiaojia'
import { getPathSidByUserSid, fetchBySid } from '@/api/cheliang/dictcommons'
import req from '@/api/bikerebate/bicyclerebatemanagement'
import { typeValues, fetchBySid } from '@/api/cheliang/dictcommons'
import bicyclerebatemanagementByVehicle from './bicyclerebatemanagementByVehicle'
export default {
name: 'bicyclerebatemanagementAdd',
components: {
bicyclerebatemanagementByVehicle
},
data() {
return {
viewTitle: '',
index: 0,
tableKey: 0,
viewState: 1,
rebateType_list: [], //
calculationMode_list: [], //
//
formobj: {
applyPeoName: '',
applyTitle: '',
createBySid: '',
createOrgName: '',
createOrgSid: '',
modpriceReason: '',
nodeState: '',
rebateTypeKey: '',
rebateTypeValue: '',
rebateName: '',
palceGenDate: '',
calculationModeKey: '',
calculationModeValue: '',
calculationStandard: '',
sid: '',
useOrgName: '',
createOrgSid: '',
createOrgName: '',
useOrgSid: '',
baseVehinstallModpricedetails: []
useOrgName: '',
scmVehRebateVehs: []
},
rules: {},
submitdisabled: false
}
},
methods: {
//
newDate() {
let date = new Date()
let year = date.getFullYear() //
let month = date.getMonth() + 1 //
let day = date.getDate() //
if (month < 10) {
month = '0' + month
}
if (day < 10) {
day = '0' + day
}
this.formobj.createTime = year + '-' + month + '-' + day
},
init() {
getPathSidByUserSid({ userSid: window.sessionStorage.getItem('userSid') }).then((resp) => {
typeValues({ type: 'rebateType' }).then((res) => {
if (res.success) {
this.rebateType_list = res.data
}
})
typeValues({ type: 'calculationMode' }).then((resp) => {
if (resp.success) {
this.formobj.createOrgSid = resp.data
this.formobj.useOrgSid = resp.data
fetchBySid(this.formobj.createOrgSid).then((res) => {
if (res.success) {
this.formobj.createOrgName = res.data.name
this.formobj.useOrgName = res.data.name
}
})
this.calculationMode_list = resp.data
}
})
fetchBySid(this.formobj.createOrgSid).then((res) => {
if (res.success) {
this.formobj.createOrgName = res.data.name
this.formobj.useOrgName = res.data.name
}
})
},
showAdd() {
this.init()
this.newDate()
UpNumber(e) {
if (this.formobj.calculationModeValue === '') {
this.formobj.calculationStandard = ''
this.$message({ showClose: true, type: 'error', message: '请先选择计算方式' })
return
} else {
if (this.formobj.calculationModeKey === '001') {
e.target.value = e.target.value.replace(/[^\d.]/g, '') // ."-"
e.target.value = e.target.value.replace(/^00/, '0.') // 0
e.target.value = e.target.value.replace(/\.{2,}/g, '.') // .
e.target.value = e.target.value.replace(/^(\-)*(\d+)\.(\d\d).*$/, '$1$2.$3') //
if (e.target.value.indexOf('.') < 0 && e.target.value !== '' && e.target.value !== '-') {
// 0102
e.target.value = parseFloat(e.target.value)
}
this.formobj.calculationStandard = e.target.value
} else if (this.formobj.calculationModeKey === '002') {
e.target.value = e.target.value.replace(/[^\d]/g, '') // ."-"
e.target.value = e.target.value.replace(/^00/, '0') // 0
if (e.target.value.indexOf('.') < 0 && e.target.value !== '' && e.target.value !== '-') {
// 0102
console.log(e.target.value)
e.target.value = parseFloat(e.target.value)
}
this.formobj.calculationStandard = e.target.value
}
}
},
estimateRebate(row) {
if (this.formobj.calculationModeKey === '001') {
var price = ''
price = parseFloat(row.manufactorSettlementPrice) - parseFloat(row.freight)
row.estimateRebate = this.multiplication(price, (parseFloat(this.formobj.calculationStandard) / 100))
} else if (this.formobj.calculationModeKey === '002') {
row.estimateRebate = this.formobj.calculationStandard
}
return row.estimateRebate
},
multiplication(arg1, arg2) {
var m = 0
var s1 = arg1.toString()
var s2 = arg2.toString()
try {
m += s1.split('.')[1].length
} catch (e) {}
try {
m += s2.split('.')[1].length
} catch (e) {}
return Number(s1.replace('.', '')) * Number(s2.replace('.', '')) / Math.pow(10, m)
},
showAdd(createOrgSid) {
this.$nextTick(() => {
this.$refs['form_obj'].clearValidate()
this.init()
})
this.formobj.createBySid = window.sessionStorage.getItem('userSid')
this.formobj.applyPeoName = window.sessionStorage.getItem('name')
this.formobj.createOrgSid = createOrgSid
this.formobj.useOrgSid = createOrgSid
this.viewTitle = '【新增】单车返利'
},
showEdit(row) {
this.$nextTick(() => {
this.$refs['form_obj'].clearValidate()
changeRebateType(value) {
let bb = null
this.rebateType_list.forEach((e) => {
if (e.dictValue === value) {
bb = {
key: e.dictKey,
value: e.dictValue
}
}
})
this.viewTitle = '【编辑】单车返利'
console.log('编辑回显', row.sid)
req.fetchBySid(row.sid).then((resp) => {
this.formobj = resp.data
}).catch((e) => {
this.formobj = row
this.formobj.rebateTypeKey = bb.key
},
changeCalculationMode(value) {
let bb = null
this.calculationMode_list.forEach((e) => {
if (e.dictValue === value) {
bb = {
key: e.dictKey,
value: e.dictValue
}
}
})
this.formobj.calculationModeKey = bb.key
},
//
addjacket() {
this.viewState = 2
this.$refs['divSelect'].showData(this.formobj.baseVehinstallModpricedetails)
this.$refs['divSelect'].showData(this.formobj.scmVehRebateVehs)
},
backData(value) {
this.viewState = 1
if (value.length > 0) {
value.forEach((e) => {
this.formobj.baseVehinstallModpricedetails.push({
adjustVehGuidedPrice: '',
costPrice: e.costPrice,
guidedPrice: e.guidedPrice,
incOrDecInPrice: '',
jacketName: e.jacketName,
jacketSid: e.jacketSid,
mainSid: '',
modelName: e.modelName,
modelSid: e.modelSid,
sid: '',
vehGuidedPrice: '',
this.formobj.scmVehRebateVehs.push({
vinNo: e.vinNo,
manufactorSettlementPrice: e.manufactorSettlementPrice,
freight: e.freight,
brandName: e.brandName,
brandSid: e.brandSid,
vehModelName: e.vehModelName,
vehModelSid: e.vehModelSid,
vehSid: e.vehSid,
estimateRebate: '',
remarks: ''
})
})
@ -209,7 +274,7 @@ export default {
},
//
dataDelete(index) {
this.formobj.baseVehinstallModpricedetails.splice(index, 1)
this.formobj.scmVehRebateVehs.splice(index, 1)
},
resetState() {
this.viewState = 1
@ -218,7 +283,7 @@ export default {
this.$refs['form_obj'].validate((valid) => {
if (valid) {
this.submitdisabled = true
req.saveOrUpdate(this.formobj).then((resp) => {
req.save(this.formobj).then((resp) => {
this.submitdisabled = false
if (resp.success) {
this.$message({
@ -236,22 +301,64 @@ export default {
}
})
},
//
getSummaries(param) {
const { columns, data } = param
const sums = []
columns.forEach((column, index) => {
if (index === 0) {
sums[index] = '合计'
return
}
const values = data.map(item => Number(item[column.property]))
if (column.property === 'estimateRebate') {
sums[index] = values.reduce((prev, curr) => {
const value = Number(curr)
if (!isNaN(value)) {
return prev + curr
} else {
return prev
}
}, 0)
sums[index] += ''
// this.formobj.currentAmount = sums[index] += ''
} else {
if (!values.every(value => isNaN(value))) {
sums[index] = values.reduce((prev, curr) => {
const value = Number(curr)
if (!isNaN(value)) {
return prev + curr
} else {
return prev
}
}, 0)
sums[index] += ''
this.amount = sums[index] += ''
} else {
sums[index] = ''
}
}
})
return sums
},
// ===
handleReturn(isreload) {
if (isreload === 'true') this.$emit('reloadlist')
//
this.formobj = {
applyPeoName: '',
applyTitle: '',
createBySid: '',
createOrgName: '',
createOrgSid: '',
modpriceReason: '',
nodeState: '',
rebateTypeKey: '',
rebateTypeValue: '',
rebateName: '',
palceGenDate: '',
calculationModeKey: '',
calculationModeValue: '',
calculationStandard: '',
sid: '',
useOrgName: '',
createOrgSid: '',
createOrgName: '',
useOrgSid: '',
baseVehinstallModpricedetails: []
useOrgName: '',
scmVehRebateVehs: []
}
this.$refs['form_obj'].resetFields()
this.$emit('doback')
@ -267,12 +374,5 @@ export default {
justify-content: space-between;
align-items: center;
}
.rowStyle {
border-left: 0px;
}
.colOneStyle {
border-right: 0px !important;
border-bottom: 0px !important;
}
</style>

333
anrui-scm/anrui-scm-ui/src/views/bikerebate/bikerebatemanagement/bicyclerebatemanagementByVehicle.vue

@ -0,0 +1,333 @@
<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="main-content">
<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-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-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-form>
<div class="btn" style="text-align: center;">
<el-button type="primary" icon="el-icon-search" @click="handleFilter" size="small">查询</el-button>
<el-button type="primary" icon="el-icon-refresh" @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>
</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/bikerebate/bicyclerebatemanagement'
import { typeValues, brandDown, getPathSidByUserSid } from '@/api/cheliang/dictcommons.js'
export default {
name: 'xuanzecheliang',
components: {
Pagination
},
data() {
return {
useOrg: '',
buyerOrgSid: '',
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: '',
buyerOrgSid: '',
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
this.listQuery.params.userSid = window.sessionStorage.getItem('userSid')
this.listQuery.params.buyerOrgSid = this.buyerOrgSid
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: '',
vinNoList: []
},
total: 0
}
this.getList()
},
handleSelectionChange(row) {
this.sids = []
const aa = []
row.forEach((element) => {
aa.push({
vinNo: element.vinNo,
vehSid: element.sid,
brandName: element.brandName,
brandSid: element.carBrand,
manufactorSettlementPrice: element.costPrice,
freight: element.freight,
vehModelName: element.vehicleAlias,
vehModelSid: element.modelSid
})
})
this.sids = aa
},
showData(value, buyerOrgSid) {
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.buyerOrgSid = buyerOrgSid
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>
</style>

303
anrui-scm/anrui-scm-ui/src/views/bikerebate/bikerebatemanagement/bicyclerebatemanagementEdit.vue

@ -0,0 +1,303 @@
<template>
<div class="app-container">
<div>
<!--标题按钮部分开始-->
<div class="tab-header webtop">
<!--标题-->
<div>{{ viewTitle }}</div>
<!--start 添加修改按钮-->
<div>
<el-button type="primary" size="small" :disabled="submitdisabled" @click="save()">保存
</el-button>
<el-button type="info" size="small" @click="handleReturn()">关闭</el-button>
</div>
</div>
<!--标题按钮部分结束-->
<!--Start 新增修改部分-->
<div class="listconadd">
<div class="titwu"><span>单车返利</span></div>
<el-form ref="form_obj" :model="formobj" :rules="rules" class="formadd">
<el-row style="border-top: 1px solid #E0E3EB">
<el-col :span="4" class="tleftb">
<span>返利类型</span>
</el-col>
<el-col :span="4">
<el-form-item>
<el-select v-model="formobj.rebateTypeValue" placeholder="请选择" filterable clearable @change="changeRebateType">
<el-option v-for="item in rebateType_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictValue"/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="4" class="tleftb">
<span>厂家返利名称</span>
</el-col>
<el-col :span="4">
<el-form-item><el-input v-model="formobj.rebateName" class="addinputw" placeholder="" clearable></el-input></el-form-item>
</el-col>
<el-col :span="4" class="tleftb">
<span>所属年月</span>
</el-col>
<el-col :span="4">
<el-form-item><el-date-picker v-model="formobj.palceGenDate" type="date" clearable value-format="yyyy-MM-dd" placeholder="选择日期"/></el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="4" class="tleftb">
<span>计算方式</span>
</el-col>
<el-col :span="4">
<el-form-item>
<el-select v-model="formobj.calculationModeValue" placeholder="请选择" filterable clearable @change="changeCalculationMode">
<el-option v-for="item in calculationMode_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictValue"/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="4" class="tleftb">
<span>计算标准(%)</span>
</el-col>
<el-col :span="12">
<el-form-item><el-input v-model="formobj.calculationStandard" @keyup.native="UpNumber" clearable placeholder="" class="addinputw"></el-input></el-form-item>
</el-col>
</el-row>
<div class="title">
<div>返利车辆</div>
</div>
<el-row>
<el-col :span="4" class="tleftb">
<span>车架号</span>
</el-col>
<el-col :span="4">
<el-form-item>
<span>{{ formobj.vinNo }}</span>
</el-form-item>
</el-col>
<el-col :span="4" class="tleftb">
<span>厂家结算价</span>
</el-col>
<el-col :span="4">
<el-form-item>
<span>{{ formobj.manufactorSettlementPrice }}</span>
</el-form-item>
</el-col>
<el-col :span="4" class="tleftb">
<span>其中运费</span>
</el-col>
<el-col :span="4">
<el-form-item>
<span>{{ formobj.freight }}</span>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="4" class="tleftb">
<span>预计返利</span>
</el-col>
<el-col :span="4">
<el-form-item>
<span>{{ estimateRebate() }}</span>
</el-form-item>
</el-col>
<el-col :span="4" class="tleftb">
<span>备注</span>
</el-col>
<el-col :span="12">
<el-form-item>
<el-input v-model="formobj.remarks" clearable placeholder="" class="addinputw"></el-input>
</el-form-item>
</el-col>
</el-row>
</el-form>
</div>
</div>
<!--End 添加修改部分-->
</div>
</template>
<script>
import req from '@/api/bikerebate/bicyclerebatemanagement'
import { typeValues } from '@/api/cheliang/dictcommons'
export default {
name: 'bicyclerebatemanagementEdit',
data() {
return {
viewTitle: '',
rebateType_list: [], //
calculationMode_list: [], //
//
formobj: {
rebateTypeKey: '',
rebateTypeValue: '',
rebateName: '',
palceGenDate: '',
calculationModeKey: '',
calculationModeValue: '',
calculationStandard: '',
sid: '',
createOrgSid: '',
createOrgName: '',
useOrgSid: '',
useOrgName: '',
vinNo: '',
manufactorSettlementPrice: '',
freight: '',
estimateRebate: '',
remarks: ''
},
rules: {},
submitdisabled: false
}
},
methods: {
init() {
typeValues({ type: 'rebateType' }).then((res) => {
if (res.success) {
this.rebateType_list = res.data
}
})
typeValues({ type: 'calculationMode' }).then((resp) => {
if (resp.success) {
this.calculationMode_list = resp.data
}
})
},
UpNumber(e) {
if (this.formobj.calculationModeValue === '') {
this.formobj.calculationStandard = ''
this.$message({ showClose: true, type: 'error', message: '请先选择计算方式' })
return
} else {
if (this.formobj.calculationModeKey === '001') {
e.target.value = e.target.value.replace(/[^\d.]/g, '') // ."-"
e.target.value = e.target.value.replace(/^00/, '0.') // 0
e.target.value = e.target.value.replace(/\.{2,}/g, '.') // .
e.target.value = e.target.value.replace(/^(\-)*(\d+)\.(\d\d).*$/, '$1$2.$3') //
if (e.target.value.indexOf('.') < 0 && e.target.value !== '' && e.target.value !== '-') {
// 0102
e.target.value = parseFloat(e.target.value)
}
this.formobj.calculationStandard = e.target.value
} else if (this.formobj.calculationModeKey === '002') {
e.target.value = e.target.value.replace(/[^\d]/g, '') // ."-"
e.target.value = e.target.value.replace(/^00/, '0') // 0
if (e.target.value.indexOf('.') < 0 && e.target.value !== '' && e.target.value !== '-') {
// 0102
console.log(e.target.value)
e.target.value = parseFloat(e.target.value)
}
this.formobj.calculationStandard = e.target.value
}
}
},
estimateRebate() {
if (this.formobj.calculationModeKey === '001') {
var price = ''
price = parseFloat(this.formobj.manufactorSettlementPrice) - parseFloat(this.formobj.freight)
this.formobj.estimateRebate = this.multiplication(price, (parseFloat(this.formobj.calculationStandard) / 100))
} else if (this.formobj.calculationModeKey === '002') {
this.formobj.estimateRebate = this.formobj.calculationStandard
}
return this.formobj.estimateRebate
},
multiplication(arg1, arg2) {
var m = 0
var s1 = arg1.toString()
var s2 = arg2.toString()
try {
m += s1.split('.')[1].length
} catch (e) {}
try {
m += s2.split('.')[1].length
} catch (e) {}
return Number(s1.replace('.', '')) * Number(s2.replace('.', '')) / Math.pow(10, m)
},
changeRebateType(value) {
let bb = null
this.rebateType_list.forEach((e) => {
if (e.dictValue === value) {
bb = {
key: e.dictKey,
value: e.dictValue
}
}
})
this.formobj.rebateTypeKey = bb.key
},
changeCalculationMode(value) {
let bb = null
this.calculationMode_list.forEach((e) => {
if (e.dictValue === value) {
bb = {
key: e.dictKey,
value: e.dictValue
}
}
})
this.formobj.calculationModeKey = bb.key
},
showEdit(row) {
this.init()
this.$nextTick(() => {
this.$refs['form_obj'].clearValidate()
})
this.viewTitle = '【编辑】单车返利'
req.fetchBySid(row.sid).then((resp) => {
this.formobj = resp.data
}).catch((e) => {
this.formobj = row
})
},
save() {
this.$refs['form_obj'].validate((valid) => {
if (valid) {
this.submitdisabled = true
req.update(this.formobj).then((resp) => {
this.submitdisabled = false
if (resp.success) {
this.$message({
showClose: true,
type: 'success',
message: resp.msg
})
this.handleReturn('true')
}
}).catch(() => {
this.submitdisabled = false
})
} else {
return false
}
})
},
// ===
handleReturn(isreload) {
if (isreload === 'true') this.$emit('reloadlist')
//
this.formobj = {
rebateTypeKey: '',
rebateTypeValue: '',
rebateName: '',
palceGenDate: '',
calculationModeKey: '',
calculationModeValue: '',
calculationStandard: '',
sid: '',
createOrgSid: '',
createOrgName: '',
useOrgSid: '',
useOrgName: '',
vinNo: '',
manufactorSettlementPrice: '',
freight: '',
estimateRebate: '',
remarks: ''
}
this.$refs['form_obj'].resetFields()
this.$emit('doback')
}
}
}
</script>
<style scoped>
</style>

119
anrui-scm/anrui-scm-ui/src/views/bikerebate/bikerebatemanagement/bicyclerebatemanagementInfo.vue

@ -20,19 +20,19 @@
<span>返利类型</span>
</el-col>
<el-col :span="4">
<el-form-item><span>{{ formobj.createOrgName }}</span></el-form-item>
<el-form-item><span>{{ formobj.rebateTypeValue }}</span></el-form-item>
</el-col>
<el-col :span="4" class="tleftb">
<span>厂家返利名称</span>
</el-col>
<el-col :span="4">
<el-form-item><span>{{ formobj.applyPeoName }}</span></el-form-item>
<el-form-item><span>{{ formobj.rebateName }}</span></el-form-item>
</el-col>
<el-col :span="4" class="tleftb">
<span>所属年月</span>
</el-col>
<el-col :span="4">
<el-form-item><span>{{ formobj.createTime }}</span></el-form-item>
<el-form-item><span>{{ formobj.palceGenDate }}</span></el-form-item>
</el-col>
</el-row>
<el-row>
@ -40,46 +40,62 @@
<span>计算方式</span>
</el-col>
<el-col :span="4">
<el-form-item><el-input v-model="formobj.modpriceReason" clearable placeholder="" class="addinputw"></el-input></el-form-item>
<el-form-item><span>{{ formobj.calculationModeValue }}</span></el-form-item>
</el-col>
<el-col :span="4" class="tleftb">
<span>计算标(%)</span>
<span>计算标(%)</span>
</el-col>
<el-col :span="12">
<el-form-item><el-input v-model="formobj.modpriceReason" clearable placeholder="" class="addinputw"></el-input></el-form-item>
<el-form-item><span>{{ formobj.calculationStandard }}</span></el-form-item>
</el-col>
</el-row>
<div class="title">
<div>返利车辆列表</div>
<div>返利车辆</div>
</div>
<el-table :key="tableKey" :data="formobj.baseVehinstallModpricedetails" :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.jacketName }}</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.modelName }}</span>
</template>
</el-table-column>
<el-table-column label="预计返利" align="center">
<template slot-scope="scope">
<el-input v-model="scope.row.vehGuidedPrice" clearable placeholder="" class="addinputw"></el-input>
</template>
</el-table-column>
<el-table-column label="备注" align="center">
<template slot-scope="scope">
<span>{{ scope.row.costPrice }}</span>
</template>
</el-table-column>
</el-table>
<el-row>
<el-col :span="4" class="tleftb">
<span>车架号</span>
</el-col>
<el-col :span="4">
<el-form-item>
<span>{{ formobj.vinNo }}</span>
</el-form-item>
</el-col>
<el-col :span="4" class="tleftb">
<span>厂家结算价</span>
</el-col>
<el-col :span="4">
<el-form-item>
<span>{{ formobj.manufactorSettlementPrice }}</span>
</el-form-item>
</el-col>
<el-col :span="4" class="tleftb">
<span>其中运费</span>
</el-col>
<el-col :span="4">
<el-form-item>
<span>{{ formobj.freight }}</span>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="4" class="tleftb">
<span>预计返利</span>
</el-col>
<el-col :span="4">
<el-form-item>
<span>{{ formobj.estimateRebate }}</span>
</el-form-item>
</el-col>
<el-col :span="4" class="tleftb">
<span>备注</span>
</el-col>
<el-col :span="12">
<el-form-item>
<span>{{ formobj.remarks }}</span>
</el-form-item>
</el-col>
</el-row>
</el-form>
</div>
</div>
@ -88,29 +104,15 @@
</template>
<script>
import req from '@/api/othermenu/shangzhuangtiaojia'
import req from '@/api/bikerebate/bicyclerebatemanagement'
export default {
name: 'bicyclerebatemanagementInfo',
data() {
return {
viewTitle: '',
index: 0,
tableKey: 0,
//
formobj: {
applyPeoName: '',
applyTitle: '',
createBySid: '',
createOrgName: '',
createOrgSid: '',
modpriceReason: '',
nodeState: '',
sid: '',
useOrgName: '',
useOrgSid: '',
baseVehinstallModpricedetails: []
},
formobj: {},
rules: {},
submitdisabled: false
}
@ -121,7 +123,6 @@ export default {
this.$refs['form_obj'].clearValidate()
})
this.viewTitle = '单车返利详情'
console.log('编辑回显', row.sid)
req.fetchBySid(row.sid).then((resp) => {
this.formobj = resp.data
}).catch((e) => {
@ -132,19 +133,7 @@ export default {
handleReturn(isreload) {
if (isreload === 'true') this.$emit('reloadlist')
//
this.formobj = {
applyPeoName: '',
applyTitle: '',
createBySid: '',
createOrgName: '',
createOrgSid: '',
modpriceReason: '',
nodeState: '',
sid: '',
useOrgName: '',
useOrgSid: '',
baseVehinstallModpricedetails: []
}
this.formobj = {}
this.$refs['form_obj'].resetFields()
this.$emit('doback')
}

Loading…
Cancel
Save