提交 66755add authored 作者: huaxinzhu's avatar huaxinzhu

入驻优化;获取服务费率

上级 5b6ca0ad
......@@ -111,3 +111,12 @@ export function UploadImg(data) {
data: data
})
}
// 根据类目 获取服务费
export function getByCategoryData(query) {
return request({
url: '/local/serviceFee/getByCategory',
method: 'get',
params: query
})
}
......@@ -73,7 +73,6 @@
})
},
nextStep() {
// this.$router.push("/agreement");
this.$router.push("/fillMainInf");
},
}
......
......@@ -23,16 +23,13 @@
<!-- <p>服务电话:4000-188-199</p>-->
<p style="padding-top: 40px;"><el-button type="primary" @click="reSubmit">重新提交</el-button></p>
</div>
</div>
</el-card>
</div>
</template>
<script>
import { getInfo } from '@/api/module/entry';
import { getInfo,getShopInf } from '@/api/module/entry';
export default {
name: "ReviewFail",
data() {
......@@ -41,6 +38,10 @@
}
},
created() {
if(this.$route.params.msg) {
this.msg = this.$route.params.msg;
}
/** 页面刷新,更新 客户审核状态 */
getInfo().then(res=> {
if (res.code == 1 && res.data.user) {
if (res.data.user.state == 1) {
......@@ -51,16 +52,16 @@
}
if (res.data.user.state == 3) {
this.$router.push({path: '/reviewFail'});
getShopInf().then(res=> {
if (res.code == 1 && res.data.Apply.content != '') {
this.msg = res.data.Apply.content;
}
});
}
} else {
this.$router.push({path: '/reviewFail'});
}
});
},
mounted() {
if(this.$route.params.msg) {
this.msg = this.$route.params.msg;
}
/** 禁止 浏览器 后退 */
history.pushState(null,null,document.URL);
window.addEventListener('popstate', function () {
......
......@@ -29,22 +29,26 @@
</template>
<script>
import { getInfo } from '@/api/module/entry';
export default {
name: "ReviewSuccess",
data() {
return {}
},
created() {
// 刷新当前页面,如果sys操作,审核通过,那么这个applyState状态值会变为 1,代表审核通过,可以直接跳转登录页面,审核拒绝,则 为3,跳转到失败页面
if (this.$store.state.user.applyState == 1) {
this.$router.push({path: '/home/index'});
}
if (this.$store.state.user.applyState == 2) {
this.$router.push({path: '/reviewing'});
}
if (this.$store.state.user.applyState == 3) {
this.$router.push({path: '/reviewFail'});
}
getInfo().then(res=> {
if (res.code == 1 && res.data.user) {
if (res.data.user.state == 1) {
this.$router.push({path: '/home/index'});
}
if (res.data.user.state == 2) {
this.$router.push({path: '/reviewing'})
}
if (res.data.user.state == 3) {
this.$router.push({path: '/reviewFail'});
}
}
});
},
mounted() {
/** 禁止 浏览器 后退 */
......
......@@ -41,7 +41,6 @@
// 获取客户是否有审核信息
getShopInf().then(res => {
if(res.code === 1) {
//debugger
switch(res.data.state) {
case 0:
switch(res.data.status){
......@@ -49,10 +48,7 @@
this.$router.push({path: '/process'});
break;
case(1):
this.$router.push({path: '/fillBrandInf'});
break;
case(2):
this.$router.push({path: '/fillShopInf',});
this.$router.push({path: '/fillShopInf'});
break;
}
break;
......
......@@ -112,7 +112,7 @@
</template>
<script>
import { NewGetCategory, GetFreight, UploadImg } from '@/api/module/goods'
import { NewGetCategory, GetFreight, UploadImg, getByCategoryData } from '@/api/module/goods'
import { getBrandsInf } from '@/api/module/brand/brand'
import { getAreaList } from '@/api/module/retreat/address'
export default {
......@@ -153,9 +153,6 @@
}
}
return {
//loading: false,
// categoryStr: '',
goodsInfoDataClone: {},
areaOptions: [], // 地址 省
brandOptions: [], // 商品品牌
goodsInfoForm: {
......@@ -205,7 +202,7 @@
// checkStrictly: true
},
fuckoptions: [],
catefee: 0,
} // return end
},
components: {},
......@@ -226,8 +223,6 @@
this.getSSQArea();
},
mounted() {
//深拷贝一份最开始的数据,为初始化准备
//this.goodsInfoDataClone = this.deepClone(this.goodsinfodata);
if(this.goodsinfodata.goods_id) {
this.goodsInfoForm = this.goodsinfodata;
if( this.goodsInfoForm.imgs.length > 0 ) {
......@@ -241,6 +236,9 @@
this.goodsInfoForm.categoryStr = this.goodsinfodata.categoryStr;
this.goodsInfoForm.categoryList = this.goodsinfodata.categoryList;
}
// 初始化 服务费率
this.getByCategoryFee(this.goodsInfoForm.categoryList)
},
methods: {
// 数据初始化
......@@ -280,7 +278,6 @@
this.SSQGoodsList = [];
this.editGoodsTypeDialog = true;
this.SSQGoodsList = this.goodsInfoForm.categoryList
//console.log('点击修改类目数据:',this.SSQGoodsList);
},
getSSQArea(node, resolve) {
......@@ -301,6 +298,8 @@
this.goodsInfoForm.categoryStr = ssqLabelList[0] + '/' + ssqLabelList[1] + '/' + ssqLabelList[2];
this.editGoodsTypeDialog = false;
this.$message({type:'success',message:'修改成功'});
// 修改类目后更新 服务费率
this.getByCategoryFee(this.goodsInfoForm.categoryList)
}else {
this.$message({type: 'warning',message: '请选择完整三级类目'});
}
......@@ -421,7 +420,26 @@
this.$router.push({path: '/system/shop/brand'});
},
// 通用 方法
/** 根据类目 获取服务费率
* 传一级类目
* */
getByCategoryFee(cateList) {
let data = {
category_id: ''
}
this.cateFee = 0;
if (Array.isArray(cateList) && cateList.length > 0) {
data.category_id = cateList[0];
}
// console.log(8888,data);
getByCategoryData(data).then(res=> {
if ( res.code == 1 ) {
this.cateFee = res.data.service_fee_ratio
}
});
},
// 图片转换为 base64
getBase64(file) {
return new Promise(function (resolve, reject) {
......@@ -439,9 +457,6 @@
};
});
},
} // methods end
}
</script>
......
......@@ -20,8 +20,8 @@
</el-table-column>
<el-table-column align="center" prop="sl_price" label="结算价">
<template slot-scope="scope">
<span
class="sl-price-span-input">{{ scope.row.sl_price = scope.row.js_price ? scope.row.js_price : '' }}</span>
<span class="sl-price-span-input">{{ scope.row.sl_price = scope.row.js_price ? scope.row.js_price : '' }}</span>
<!-- <span>{{ settlePricecalc(scope.row.js_price) }}</span>-->
</template>
</el-table-column>
<el-table-column align="center" prop="price" label="指导价">
......@@ -217,7 +217,8 @@ export default {
},
},
created() {
//this.orgGoodsPam = this.parameterdata;
// console.log("服务费率:");
},
mounted() {
if(this.parameterdata.pamTableList && this.parameterdata.pamTableList.length > 0) {
......@@ -387,6 +388,13 @@ export default {
});
},
/** 结算价格计算 */
settlePricecalc(jsPriceVal) {
let jsPriceNum = '';
return jsPriceNum
}
} // methods end
}
</script>
......
......@@ -270,8 +270,10 @@
this.isShowGoodsDetails = false;
}
},
mounted() {},
mounted() {
},
methods: {
// 规格子组件,传给父组件的数据
calcSpeTable(data) {
//console.log('原始值',data);
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论