Commit 5ce0097d authored by dcy's avatar dcy

Merge remote-tracking branch 'origin/dev' into dev

parents 1e6a36c0 7986b1e4
......@@ -68,7 +68,7 @@ export function getProductFeeList(prodCreateReqVO){
url: '/ecw/offer/calculation/prod-fee-List',
method: 'post',
data: prodCreateReqVO
})
})
}
// 获取费用清单
......@@ -77,5 +77,14 @@ export function getProductFee(calculationFeeParamVO){
url: '/ecw/offer/calculation/fee-List',
method: 'post',
data: calculationFeeParamVO
})
}
\ No newline at end of file
})
}
// 特价申请
export function createOfferSpecial(data) {
return request({
url: '/ecw/offer/special/apply',
method: 'put',
data: data
})
}
......@@ -271,15 +271,15 @@ export const constantRoutes = [
path: 'special/:offerId(\\d+)',
component: (resolve) => import('@/views/ecw/offer/special'),
props: true,
name: 'offer',
meta: {title: '特价申请', icon: '', activeMenu: '/offer/special'}
name: 'special',
meta: {title: '特价申请', icon: '', activeMenu: '/offer/index'}
},
{
path: 'discount/:id(\\d+)',
path: 'discount',
component: (resolve) => import('@/views/ecw/offer/specialDiscount'),
props: true,
name: 'offer',
meta: {title: '优惠申请', icon: '', activeMenu: '/offer/discount'}
name: 'discount',
meta: {title: '优惠申请', icon: '', activeMenu: '/offer/index'}
},
]
}
......
......@@ -49,9 +49,9 @@
prop="address"
label="操作">
<template v-slot="{row}">
<el-button size="mini" type="text" v-hasPermi="['ecw:offer:update']" @click="$router.push('/offer/discount/' + row.lineId)">优惠申请</el-button>
<el-button size="mini" type="text" v-hasPermi="['ecw:offer:update']">佣金规则</el-button>
<el-button size="mini" type="text" v-hasPermi="['ecw:offer:update']">管理折扣</el-button>
<el-button size="mini" type="text" v-hasPermi="['ecw:offer:update']" @click="$router.push(`'/offer/discount?offerId=${row.offerId}&offerProdId=${row.offerProdId}`)">优惠申请</el-button>
<!-- <el-button size="mini" type="text" v-hasPermi="['ecw:offer:update']">佣金规则</el-button>-->
<!-- <el-button size="mini" type="text" v-hasPermi="['ecw:offer:update']">管理折扣</el-button>-->
</template>
</el-table-column>
......
<template>
<div>
<h3>优惠申请</h3>
{{ id }}
<div class="app-container">
<el-row type="flex" justify="center">
<el-col :xs="24" :sm="24" :md="24" :lg="20" :xl="16">
<el-card class="box-card">
<div slot="header" class="clearfix">
<span>优惠申请</span>
</div>
offerId: {{ form.offerId }}<br>
offerProdId: {{ form.offerProdId }}<br>
clearanceFreight: {{ form.clearanceFreight }}<br>
seaFreight: {{ form.seaFreight }}
<div>
<el-button type="primary" @click="handleSubmit">提交</el-button>
</div>
</el-card>
</el-col>
</el-row>
</div>
</template>
<script>
import {createOfferSpecial, getOffer} from "@/api/ecw/offer"
export default {
name: "specialDiscount",
props: {
id: String
},
created() {
if(this.$route.query.offerId){
this.form.offerId = this.$route.query.offerId - 0
}
if(this.$route.query.offerProdId){
this.form.offerProdId = this.$route.query.offerProdId - 0
}
getOffer(this.form.offerId).then(r => {
const line = r.data.offerProdRespVOList.find(e => e.offerProdId = this.form.offerProdId)
console.log(line)
const {
clearanceFreight,
seaFreight
} = line
this.form = {
...this.form,
clearanceFreight,
seaFreight
}
})
},
data() {
return {
form: {
// "applyResult": "",
// "applyStatus": 0,
"clearanceFreight": 0,
"offerId": 0,
"offerProdId": 0,
"seaFreight": 0
}
}
},
methods: {
handleSubmit(){
createOfferSpecial(this.form).then(r => {
this.$message.success(r.msg || '提交成功')
})
}
}
}
</script>
......
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