Commit bd8881bc by damodmg

更新

parent 3c93c437
<!DOCTYPE html><html><head><meta charset=utf-8><meta name=viewport content="width=device-width,initial-scale=1"><link rel=stylesheet type=text/css href=./static/css/iconfont.css><link rel=stylesheet type=text/css href=./static/css/common.css><link rel="shortcut icon" type=image/x-icon href=./static/img/favicon.ico><title>积分商城</title><link href=./static/css/app.db5d260f0b1744fdd411f21ff1c5b4c3.css rel=stylesheet></head><body><div id=app></div><script src=//web-1251519181.file.myqcloud.com/lib/vue/2.5.2/vue.min.js></script><script src=//web-1251519181.file.myqcloud.com/lib/vue-router/3.0.2/vue-router.min.js></script><script src=//web-1251519181.file.myqcloud.com/lib/vuex/3.1.0/vuex.min.js></script><script src=//web-1251519181.file.myqcloud.com/lib/elementUI/index.2.5.4.js></script><script src=//web-1251519181.file.myqcloud.com/components/header.2.0.33.js></script><script src=//web-1251519181.file.myqcloud.com/components/aside-menu.2.0.11.js></script><script src=//web-1251519181.file.myqcloud.com/components/footer.2.0.04.js></script><script src=//web-1251519181.file.myqcloud.com/components/store-linkage.2.0.35.js></script><script src=//web-1251519181.file.myqcloud.com/components/store-new.2.0.11.js></script><script src=//web-1251519181.file.myqcloud.com/components/card.2.0.06.js></script><script src=//web-1251519181.file.myqcloud.com/components/export-excel.2.0.11.js></script><script src=//web-1251519181.file.myqcloud.com/components/people.2.0.26.js></script><script src=//web-1251519181.file.myqcloud.com/components/delete.2.0.00.js></script><script type=text/javascript src=./static/js/manifest.3ad1d5771e9b13dbdad2.js></script><script type=text/javascript src=./static/js/vendor.3c5834cc437c7b2d524e.js></script><script type=text/javascript src=./static/js/app.b6a5d5bf3e563f72b6a6.js></script></body></html> <!DOCTYPE html><html><head><meta charset=utf-8><meta name=viewport content="width=device-width,initial-scale=1"><link rel=stylesheet type=text/css href=./static/css/iconfont.css><link rel=stylesheet type=text/css href=./static/css/common.css><link rel="shortcut icon" type=image/x-icon href=./static/img/favicon.ico><title>积分商城</title><link href=./static/css/app.a9046e68b004d18a36f6683a29ba1228.css rel=stylesheet></head><body><div id=app></div><script src=//web-1251519181.file.myqcloud.com/lib/vue/2.5.2/vue.min.js></script><script src=//web-1251519181.file.myqcloud.com/lib/vue-router/3.0.2/vue-router.min.js></script><script src=//web-1251519181.file.myqcloud.com/lib/vuex/3.1.0/vuex.min.js></script><script src=//web-1251519181.file.myqcloud.com/lib/elementUI/index.2.5.4.js></script><script src=//web-1251519181.file.myqcloud.com/components/header.2.0.33.js></script><script src=//web-1251519181.file.myqcloud.com/components/aside-menu.2.0.11.js></script><script src=//web-1251519181.file.myqcloud.com/components/footer.2.0.04.js></script><script src=//web-1251519181.file.myqcloud.com/components/store-linkage.2.0.35.js></script><script src=//web-1251519181.file.myqcloud.com/components/store-new.2.0.11.js></script><script src=//web-1251519181.file.myqcloud.com/components/card.2.0.06.js></script><script src=//web-1251519181.file.myqcloud.com/components/export-excel.2.0.11.js></script><script src=//web-1251519181.file.myqcloud.com/components/people.2.0.26.js></script><script src=//web-1251519181.file.myqcloud.com/components/delete.2.0.00.js></script><script type=text/javascript src=./static/js/manifest.3ad1d5771e9b13dbdad2.js></script><script type=text/javascript src=./static/js/vendor.3c5834cc437c7b2d524e.js></script><script type=text/javascript src=./static/js/app.d4d96241f2d47ab91340.js></script></body></html>
\ No newline at end of file \ No newline at end of file
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -86,9 +86,9 @@ export default { ...@@ -86,9 +86,9 @@ export default {
}, },
methods: { methods: {
limitSkuCode() { limitSkuCode() {
let reg = /^[0-9a-zA-Z]+?$/; let reg = /^[0-9a-zA-Z\-]+?$/;
if (!reg.test(this.giftProSkuCode)) { if (!reg.test(this.giftProSkuCode)) {
this.$message.error('请输入数字或者字母'); this.$message.error('请输入数字或者字母或-');
this.giftProSkuCode = ''; this.giftProSkuCode = '';
} }
}, },
......
...@@ -118,7 +118,7 @@ ...@@ -118,7 +118,7 @@
</el-form-item> --> </el-form-item> -->
<el-form-item label="展现门店" required style="position:relative"> <el-form-item label="展现门店" required style="position:relative">
<vue-gic-store-linkage :disabled="isInfo" @getDisGroupList="getDisGroupList" :msg="sendChildData" :openFlag="openFlag" ref="selectTree" @sendSelectGroupData="getSelectGroupData"></vue-gic-store-linkage> <vue-gic-store-linkage :disabled="isInfo" @getDisGroupList="getDisGroupList" :msg="sendChildData" :openFlag="openFlag" ref="selectTree" @sendSelectGroupData="getSelectGroupData"></vue-gic-store-linkage>
<span v-if="sendChildData.storeType === 1" class="store-tip">若选中的门店分组下有新增的门店,系统不会默认选中此新增门店,请重新确认选择并保存礼品</span> <span v-if="sendChildData.storeType === 1" class="store-tip">若选中的父分组下有新增的门店分组,系统不会默认选中此新增门店分组,请重新确认选择并保存礼品</span>
</el-form-item> </el-form-item>
<el-form-item label="限兑"> <el-form-item label="限兑">
<el-checkbox v-model="couponForm.limitTimesStatus" @change="refashData()">每个会员限制兑换</el-checkbox> <el-checkbox v-model="couponForm.limitTimesStatus" @change="refashData()">每个会员限制兑换</el-checkbox>
......
...@@ -174,7 +174,7 @@ export default { ...@@ -174,7 +174,7 @@ export default {
this.skuJson.push({ this.skuJson.push({
standardId: '', standardId: '',
standardName: '', standardName: '',
valueList: [{ valueName: '', valueId: '' }] valueList: [{ valueName: '', valueId: '', propImg: '' }]
}); });
}, },
//删除规格 //删除规格
...@@ -182,6 +182,7 @@ export default { ...@@ -182,6 +182,7 @@ export default {
this.skuJson.splice(index, 1); this.skuJson.splice(index, 1);
this.handleSku(); this.handleSku();
this.$emit('IsAgreeUpload', this.isStdImg); this.$emit('IsAgreeUpload', this.isStdImg);
this.$emit('getStandradList', this.skuJson); this.$emit('getStandradList', this.skuJson);
this.$emit('getSkuList', this.skuList); this.$emit('getSkuList', this.skuList);
}, },
...@@ -214,7 +215,7 @@ export default { ...@@ -214,7 +215,7 @@ export default {
}, },
// 添加规格值 // 添加规格值
addValue(item) { addValue(item) {
item.valueList.push({ valueName: '', valueId: '' }); item.valueList.push({ valueName: '', valueId: '', propImg: '' });
}, },
// 删除规格值 // 删除规格值
deleteValue(item, index) { deleteValue(item, index) {
...@@ -317,7 +318,7 @@ export default { ...@@ -317,7 +318,7 @@ export default {
}, },
// 点击规格下拉选中 // 点击规格下拉选中
getSelected(i, item) { getSelected(i, item) {
item.valueList = [{ valueName: '', valueId: '' }]; item.valueList = [{ valueName: '', valueId: '', propImg: '' }];
item.standardName = i.standardName; item.standardName = i.standardName;
item.standardId = i.standardId; item.standardId = i.standardId;
this.refash = !this.refash; this.refash = !this.refash;
...@@ -330,6 +331,7 @@ export default { ...@@ -330,6 +331,7 @@ export default {
getSelectedValue(i, item, index) { getSelectedValue(i, item, index) {
item.valueList[index].valueName = i.valueName; item.valueList[index].valueName = i.valueName;
item.valueList[index].valueId = i.valueId; item.valueList[index].valueId = i.valueId;
item.valueList[index].propImg = i.propImg;
this.refash = !this.refash; this.refash = !this.refash;
this.handleSku(); this.handleSku();
this.$emit('IsAgreeUpload', this.isStdImg); this.$emit('IsAgreeUpload', this.isStdImg);
...@@ -392,6 +394,13 @@ export default { ...@@ -392,6 +394,13 @@ export default {
item2.propImg = response.result[0].qcloudImageUrl; item2.propImg = response.result[0].qcloudImageUrl;
this.$message.success('上传成功'); this.$message.success('上传成功');
this.refash = !this.refash; this.refash = !this.refash;
for (let item of this.skuList) {
for (let i of item) {
if (i.valueId === item2.valueId) {
i.propImg = response.result[0].qcloudImageUrl;
}
}
}
this.$emit('IsAgreeUpload', this.isStdImg); this.$emit('IsAgreeUpload', this.isStdImg);
this.$emit('getSkuList', this.skuList); this.$emit('getSkuList', this.skuList);
this.$emit('getStandradList', this.skuJson); this.$emit('getStandradList', this.skuJson);
...@@ -503,9 +512,9 @@ export default { ...@@ -503,9 +512,9 @@ export default {
}); });
}, },
limitCodeType() { limitCodeType() {
let reg = /^[0-9a-zA-Z]+?$/; let reg = /^[0-9a-zA-Z\-]+?$/;
if (!reg.test(this.code)) { if (!reg.test(this.code)) {
this.$message.error('请输入数字或者字母'); this.$message.error('请输入数字或者字母或-');
this.code = ''; this.code = '';
} }
}, },
...@@ -610,8 +619,9 @@ export default { ...@@ -610,8 +619,9 @@ export default {
} }
} else if (item1.length - index2 === 3) { } else if (item1.length - index2 === 3) {
//规格编码 //规格编码
if (!reg.test(item2.valueName)) { let regExp = /^[A-Za-z0-9\-]{1,32}$/;
this.$message.error('请输入数字或者字母'); if (!regExp.test(item2.valueName)) {
this.$message.error('请输入数字或者字母或-');
item2.valueName = ''; item2.valueName = '';
} }
item2.valueName = item2.valueName.slice(0, 32); item2.valueName = item2.valueName.slice(0, 32);
......
...@@ -7,10 +7,10 @@ ...@@ -7,10 +7,10 @@
<el-breadcrumb-item>积分商城</el-breadcrumb-item> <el-breadcrumb-item>积分商城</el-breadcrumb-item>
<el-breadcrumb-item>商品</el-breadcrumb-item> <el-breadcrumb-item>商品</el-breadcrumb-item>
<el-breadcrumb-item :to="{ path: '/gift' }">礼品</el-breadcrumb-item> <el-breadcrumb-item :to="{ path: '/gift' }">礼品</el-breadcrumb-item>
<el-breadcrumb-item>{{ mallProId === '-1' ? '新建' : '编辑' }}礼品</el-breadcrumb-item> <el-breadcrumb-item>{{ giftId === '-1' ? '新建' : '编辑' }}礼品</el-breadcrumb-item>
</el-breadcrumb> </el-breadcrumb>
<h3> <h3>
<span>{{ mallProId === '-1' ? '新建' : '编辑' }}礼品</span> <span>{{ giftId === '-1' ? '新建' : '编辑' }}礼品</span>
</h3> </h3>
</div> </div>
<div class="section"> <div class="section">
...@@ -128,7 +128,7 @@ ...@@ -128,7 +128,7 @@
</el-form-item> --> </el-form-item> -->
<el-form-item label="展现门店" required style="position:relative"> <el-form-item label="展现门店" required style="position:relative">
<vue-gic-store-linkage :disabled="isInfo" @getDisGroupList="getDisGroupList" :msg="sendChildData" :openFlag="openFlag" ref="selectTree" @sendSelectGroupData="getSelectGroupData"></vue-gic-store-linkage> <vue-gic-store-linkage :disabled="isInfo" @getDisGroupList="getDisGroupList" :msg="sendChildData" :openFlag="openFlag" ref="selectTree" @sendSelectGroupData="getSelectGroupData"></vue-gic-store-linkage>
<span v-if="sendChildData.storeType === 1" class="store-tip">若选中的门店分组下有新增的门店,系统不会默认选中此新增门店,请重新确认选择并保存礼品</span> <span v-if="sendChildData.storeType === 1" class="store-tip">若选中的父分组下有新增的门店分组,系统不会默认选中此新增门店分组,请重新确认选择并保存礼品</span>
</el-form-item> </el-form-item>
<el-form-item label="限兑"> <el-form-item label="限兑">
<el-checkbox v-model="giftForm.limitTimesStatus" @change="refashData()">每个会员限制兑换</el-checkbox> <el-checkbox v-model="giftForm.limitTimesStatus" @change="refashData()">每个会员限制兑换</el-checkbox>
...@@ -205,7 +205,7 @@ ...@@ -205,7 +205,7 @@
<span style="font-size: 12px;color: rgb(144, 147, 153);margin-left:10px;display: inline-block;vertical-align: middle;">公众号积分商城不支持此功能,小程序积分商城请升级至V3.1.1及以上版本</span> <span style="font-size: 12px;color: rgb(144, 147, 153);margin-left:10px;display: inline-block;vertical-align: middle;">公众号积分商城不支持此功能,小程序积分商城请升级至V3.1.1及以上版本</span>
</el-checkbox-group> </el-checkbox-group>
</el-form-item> </el-form-item>
<el-form-item label="配送方式" required v-if="giftType !== 1" prop="changeTypeList"> <el-form-item label="配送方式" v-if="giftType !== 1" prop="changeType">
<el-radio-group v-model="giftForm.changeType" @change="changeDeliver" :disabled="editChangeTypeStatus"> <el-radio-group v-model="giftForm.changeType" @change="changeDeliver" :disabled="editChangeTypeStatus">
<el-radio :label="3" <el-radio :label="3"
>在线发货 >在线发货
...@@ -226,10 +226,10 @@ ...@@ -226,10 +226,10 @@
</el-form-item> </el-form-item>
<div class="section-content1" v-show="giftForm.changeType === 1"> <div class="section-content1" v-show="giftForm.changeType === 1">
<h3>选择卡券</h3> <h3>选择卡券</h3>
<el-form-item label="选择卡券" required v-show="mallProId === '-1'" style="margin-bottom:66px;"> <el-form-item label="选择卡券" required v-show="giftId === '-1'" style="margin-bottom:66px;">
<el-button plain @click="showCard">添加卡券</el-button> <el-button plain @click="showCard">添加卡券</el-button>
</el-form-item> </el-form-item>
<el-form-item label="选择卡券" required v-show="mallProId !== '-1'"> </el-form-item> <el-form-item label="选择卡券" required v-show="giftId !== '-1'"> </el-form-item>
<el-table :data="cardList" style="width: 900px;margin-left:170px;margin-top:-44px;" v-show="cardList.length > 0"> <el-table :data="cardList" style="width: 900px;margin-left:170px;margin-top:-44px;" v-show="cardList.length > 0">
<el-table-column label="卡券名称" prop="cardName"> </el-table-column> <el-table-column label="卡券名称" prop="cardName"> </el-table-column>
<el-table-column label="有效期" prop="limitDay"> <el-table-column label="有效期" prop="limitDay">
...@@ -332,6 +332,7 @@ export default { ...@@ -332,6 +332,7 @@ export default {
projectName: 'integral-mall', projectName: 'integral-mall',
giftType: '', //礼品类型 giftType: '', //礼品类型
mallProId: '', //礼品id mallProId: '', //礼品id
giftId: '', //礼品Id
linkIndex: 0, linkIndex: 0,
giftForm: { giftForm: {
proReferId: '', //礼品关联id proReferId: '', //礼品关联id
...@@ -376,7 +377,8 @@ export default { ...@@ -376,7 +377,8 @@ export default {
exchangeDateDayArr: [{ required: true, message: '请选择时间', trigger: 'change' }], exchangeDateDayArr: [{ required: true, message: '请选择时间', trigger: 'change' }],
exchangeDateWeekArr: [{ required: true, message: '请选择时间', trigger: 'change' }], exchangeDateWeekArr: [{ required: true, message: '请选择时间', trigger: 'change' }],
limitTimeBegin: [{ required: true, message: '请选择时间', trigger: 'change' }], limitTimeBegin: [{ required: true, message: '请选择时间', trigger: 'change' }],
changeTypeList: [{ type: 'array', required: true, message: '请至少选择一个配送方式', trigger: 'change' }] changeTypeList: [{ type: 'array', required: true, message: '请至少选择一个配送方式', trigger: 'change' }],
changeType: [{ required: true, message: '请选择一个配送方式', trigger: 'change' }]
}, },
refundTypeStatus: false, refundTypeStatus: false,
uploadAction: window.location.origin + '/api-plug/upload-img?requestProject=integral-mall', uploadAction: window.location.origin + '/api-plug/upload-img?requestProject=integral-mall',
...@@ -464,6 +466,7 @@ export default { ...@@ -464,6 +466,7 @@ export default {
}; };
this.giftType = Number(this.$route.query.type); //列表上实物是1虚拟是0 this.giftType = Number(this.$route.query.type); //列表上实物是1虚拟是0
this.canEdit = Boolean(this.$route.query.canEdit); this.canEdit = Boolean(this.$route.query.canEdit);
this.giftId = this.$route.query.giftId;
this.mallProId = this.$route.query.giftId; this.mallProId = this.$route.query.giftId;
if (this.$route.query.proReferId !== '-1') { if (this.$route.query.proReferId !== '-1') {
//编辑 //编辑
...@@ -484,7 +487,7 @@ export default { ...@@ -484,7 +487,7 @@ export default {
this.stockDisabled = this.giftForm.changeType === 5 ? true : false; this.stockDisabled = this.giftForm.changeType === 5 ? true : false;
this.refundTypeStatus = this.giftForm.changeType === 5 ? true : false; this.refundTypeStatus = this.giftForm.changeType === 5 ? true : false;
} }
if (this.mallProId !== '-1') { if (this.giftId !== '-1') {
// setTimeout(() => { // setTimeout(() => {
// this.groupIdDisableList = this.$refs.selectTree.getDisGroupList; // this.groupIdDisableList = this.$refs.selectTree.getDisGroupList;
// }, 1000); // }, 1000);
...@@ -534,7 +537,8 @@ export default { ...@@ -534,7 +537,8 @@ export default {
getDisGroupList(arr) { getDisGroupList(arr) {
this.groupIdDisableList = arr; this.groupIdDisableList = arr;
if (this.mallProId !== '-1') { // console.log(this.mallProId);
if (this.giftId !== '-1') {
this.getInfo(); this.getInfo();
} }
}, },
...@@ -645,7 +649,7 @@ export default { ...@@ -645,7 +649,7 @@ export default {
// 获取详情 // 获取详情
getInfo() { getInfo() {
let params = { let params = {
integralMallProId: this.mallProId integralMallProId: this.giftId
}; };
request.post('/api-integral-mall/get-integral-mall-pro', qs.stringify(params)).then(res => { request.post('/api-integral-mall/get-integral-mall-pro', qs.stringify(params)).then(res => {
if (res.data.errorCode === 0) { if (res.data.errorCode === 0) {
...@@ -898,9 +902,9 @@ export default { ...@@ -898,9 +902,9 @@ export default {
}); });
}, },
limitProCodeType() { limitProCodeType() {
let reg = /^[0-9a-zA-Z]+?$/; let reg = /^[0-9a-zA-Z\-]+?$/;
if (!reg.test(this.giftForm.proCode)) { if (!reg.test(this.giftForm.proCode)) {
this.$message.error('请输入数字或者字母'); this.$message.error('请输入数字或者字母或-');
this.giftForm.proCode = ''; this.giftForm.proCode = '';
} }
}, },
...@@ -1226,6 +1230,7 @@ export default { ...@@ -1226,6 +1230,7 @@ export default {
}, },
getSkuList(val) { getSkuList(val) {
this.skuList = val; this.skuList = val;
// console.log('skuList', this.skuList);
// return; // return;
this.handleSku(); this.handleSku();
if (this.giftProStandardJson.length > 0) { if (this.giftProStandardJson.length > 0) {
...@@ -1252,6 +1257,7 @@ export default { ...@@ -1252,6 +1257,7 @@ export default {
let skuPrice = []; let skuPrice = [];
let skuSta = []; let skuSta = [];
if (skuArr[0]) { if (skuArr[0]) {
// console.log('skuSta1', skuSta);
for (let i in skuArr) { for (let i in skuArr) {
// console.log(777, skuArr[0]); // console.log(777, skuArr[0]);
//先获取sku价格条码这些 //先获取sku价格条码这些
...@@ -1264,7 +1270,9 @@ export default { ...@@ -1264,7 +1270,9 @@ export default {
// outArr[k].proName = skuArr[0][k].proName; // outArr[k].proName = skuArr[0][k].proName;
// outArr[k].proId = skuArr[0][k].proId; // outArr[k].proId = skuArr[0][k].proId;
} }
skuSta.push(outArr); skuSta.push(outArr);
// console.log('skuSta2', skuSta);
skuPrice.push(outArr1); skuPrice.push(outArr1);
} }
// console.log() // console.log()
...@@ -1455,7 +1463,7 @@ export default { ...@@ -1455,7 +1463,7 @@ export default {
this.$refs[form].validate(valid => { this.$refs[form].validate(valid => {
if (valid) { if (valid) {
let params = { let params = {
integralMallProId: this.mallProId === '-1' ? '' : this.mallProId, //礼品id integralMallProId: this.giftId === '-1' ? '' : this.mallProId, //礼品id
proType: this.giftForm.changeType === 1 ? 2 : 3, //发货方式是微信兑换券传2其他传3 proType: this.giftForm.changeType === 1 ? 2 : 3, //发货方式是微信兑换券传2其他传3
giftType: this.giftType === 0 ? 0 : 1, //0、虚拟 1、实物 giftType: this.giftType === 0 ? 0 : 1, //0、虚拟 1、实物
proName: this.giftForm.proName.trim(), //礼品名称 proName: this.giftForm.proName.trim(), //礼品名称
......
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