Commit 0c132b8c by damodmg

去掉空格

parent f4ae35ab
<!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.6f200d512a060b3384c3b1ae476e1e89.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.20.js></script><script src=//web-1251519181.file.myqcloud.com/components/aside-menu.2.0.05.js></script><script src=//web-1251519181.file.myqcloud.com/components/footer.2.0.02.js></script><script src=//web-1251519181.file.myqcloud.com/components/store-linkage.2.0.03.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.03.js></script><script src=//web-1251519181.file.myqcloud.com/components/export-excel.2.0.04.js></script><script type=text/javascript src=./static/js/manifest.3ad1d5771e9b13dbdad2.js></script><script type=text/javascript src=./static/js/vendor.bf93010d9b9b1322a27b.js></script><script type=text/javascript src=./static/js/app.f557804b3b431ffd06bf.js></script></body></html>
\ No newline at end of file
<!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.ab0f9277d1addaaf9eb8506e5d1115e1.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.20.js></script><script src=//web-1251519181.file.myqcloud.com/components/aside-menu.2.0.05.js></script><script src=//web-1251519181.file.myqcloud.com/components/footer.2.0.02.js></script><script src=//web-1251519181.file.myqcloud.com/components/store-linkage.2.0.03.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.03.js></script><script src=//web-1251519181.file.myqcloud.com/components/export-excel.2.0.04.js></script><script type=text/javascript src=./static/js/manifest.3ad1d5771e9b13dbdad2.js></script><script type=text/javascript src=./static/js/vendor.bf93010d9b9b1322a27b.js></script><script type=text/javascript src=./static/js/app.27cd306e481cef3c3da3.js></script></body></html>
\ 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.
......@@ -16,7 +16,7 @@
<div class="operate-top">
<div class="fl">
<div class="search-item">
<el-input v-model="searchValue" placeholder="请输入优惠券名称进行搜索" prefix-icon="el-icon-search" clearable class="w-280" @keyup.enter.native="getSearchList" @clear="getSearchList"> </el-input>
<el-input v-model.trim="searchValue" placeholder="请输入优惠券名称进行搜索" prefix-icon="el-icon-search" clearable class="w-280" @keyup.enter.native="getSearchList" @clear="getSearchList"> </el-input>
</div>
<div class="search-item">
<el-select v-model="shelf" placeholder="上下架状态" clearable class="w-140" @change="getListCurr">
......
......@@ -79,7 +79,7 @@
<td v-for="(item2, index2) in item1" :key="index2" style="width:120px" v-if="item1.length - index2 > 1">
<!-- {{ item1[7] }} -->
<span v-if="item1.length - index2 < 7">
<el-input size="small" v-model="item2.valueName" @blur="skuInput(item1, item2, index1, index2)" @input="setSkuValueName"> </el-input>
<el-input size="small" v-model.trim="item2.valueName" @blur="skuInput(item1, item2, index1, index2)" @input="setSkuValueName"> </el-input>
</span>
<!-- <span v-else-if="item1.length === index2 + 1" style="color:red">{{ item2.valueName ? item2.valueName : '' }}</span> -->
......
......@@ -224,7 +224,7 @@ export default {
this.pageSize = this.giftListObj.pageSize;
this.total = this.giftListObj.total;
this.shelf = this.giftListObj.shelf;
this.searchValue = this.giftListObj.searchValue;
this.searchValue = this.giftListObj.searchValue.trim();
this.giftType = this.giftListObj.giftType;
this.sortType = this.giftListObj.sortType;
this.sortColumn = this.giftListObj.sortColumn;
......@@ -255,7 +255,7 @@ export default {
pageSize: this.pageSize,
sortType: this.sortType,
sortColumn: this.sortColumn,
giftName: this.searchValue,
giftName: this.searchValue.trim(),
giftType: this.giftType ? this.giftType : -1,
shelf: this.shelf ? this.shelf : -1, //上架状态
goodsType: this.goodsType //商品类型
......@@ -476,7 +476,7 @@ export default {
total: this.total,
shelf: this.shelf,
giftType: this.giftType,
searchValue: this.searchValue,
searchValue: this.searchValue.trim(),
sortType: this.sortType,
sortColumn: this.sortColumn
};
......
......@@ -18,7 +18,7 @@
<div class="section-content">
<h3>基础信息</h3>
<el-form-item label="礼品名称" prop="proName">
<el-input v-model="giftForm.proName" class="w-600" type="text" placeholder="请输入礼品名称" @input="value => goodsLimit(value)">
<el-input v-model.trim="giftForm.proName" class="w-600" type="text" placeholder="请输入礼品名称" @input="value => goodsLimit(value)">
<span slot="suffix">{{ proNameLen }}/30</span>
</el-input>
</el-form-item>
......@@ -73,19 +73,19 @@
<tbody>
<tr>
<td style="width:120px">
<el-input size="small" v-model="giftForm.proCode" placeholder="请输入内容" @input="limitProCode" @blur="limitProCodeType"> </el-input>
<el-input size="small" v-model.trim="giftForm.proCode" placeholder="请输入内容" @input="limitProCode" @blur="limitProCodeType"> </el-input>
</td>
<td style="width:120px">
<el-input size="small" v-model="giftForm.integralCost" placeholder="请输入内容" @blur="limitCostType"> </el-input>
<el-input size="small" v-model.trim="giftForm.integralCost" placeholder="请输入内容" @blur="limitCostType"> </el-input>
</td>
<td style="width:120px">
<el-input size="small" v-model="giftForm.cashCost" placeholder="请输入内容" @blur="limitCash"> </el-input>
<el-input size="small" v-model.trim="giftForm.cashCost" placeholder="请输入内容" @blur="limitCash"> </el-input>
</td>
<td style="width:120px">
<el-input size="small" v-model="giftForm.virtualStock" placeholder="请输入内容" :disabled="stockDisabled" @blur="limitStock"> </el-input>
<el-input size="small" v-model.trim="giftForm.virtualStock" placeholder="请输入内容" :disabled="stockDisabled" @blur="limitStock"> </el-input>
</td>
<td style="width:120px">
<el-input size="small" v-model="giftForm.proCodeQuery" placeholder="请输入内容" @input="limintProCodeQuery" @blur="limitproCodeQueryType"> </el-input>
<el-input size="small" v-model.trim="giftForm.proCodeQuery" placeholder="请输入内容" @input="limintProCodeQuery" @blur="limitproCodeQueryType"> </el-input>
</td>
</tr>
</tbody>
......@@ -320,6 +320,13 @@ export default {
callback();
}
};
const proNameValidator = (rule, value, callback) => {
if (!value.trim()) {
return callback(new Error('请输入礼品名称'));
} else {
callback();
}
};
return {
getTimeAll: getInputVal.formatDate,
getTime: getInputVal.getTime,
......@@ -364,7 +371,7 @@ export default {
memberGradeList: [], //会员等级列表
submitLoading: false, //按钮加载中
giftRules: {
proName: [{ required: true, message: '请输入礼品名称', trigger: 'blur' }],
proName: [{ validator: proNameValidator, trigger: 'blur' }],
costValue: [{ required: true, message: '请输入礼品成本', trigger: 'blur' }],
memberGrade: [{ required: true, message: '请选择适用会员', trigger: 'blur' }],
proCategoryId: [{ required: true, message: '请选择礼品分类', trigger: 'blur' }],
......@@ -591,6 +598,7 @@ export default {
request.post('/api-integral-mall/get-integral-mall-pro', qs.stringify(params)).then(res => {
if (res.data.errorCode === 0) {
this.giftForm.proName = res.data.result.proName; //名称
this.proNameLen = getInputVal.getZhLen(this.giftForm.proName);
this.giftForm.proCategoryId = res.data.result.proCategoryId; //分类
this.giftForm.proCode = res.data.result.proCode; //编码
this.giftForm.integralCost = res.data.result.integralCost; //积分
......@@ -1274,25 +1282,34 @@ export default {
}
}
}
if (!item.stock && item.stock !== 0) {
this.$message.error('请填写库存');
return false;
}
if (Number(item.giftProSkuCash) !== 0) {
if (!item.giftProSkuCash) {
this.$message.error('请填写现金');
return false;
}
if (item.giftProSkuCash === '') {
this.$message.error('请填写现金');
return false;
}
if (Number(item.giftProSkuIntegral) !== 0) {
if (!item.giftProSkuIntegral) {
this.$message.error('请填写积分');
return false;
}
// if (Number(item.giftProSkuCash) !== 0) {
// if (!item.giftProSkuCash) {
// console.log(item.giftProSkuCash);
// this.$message.error('请填写现金');
// return false;
// }
// }
if (item.giftProSkuIntegral === '') {
this.$message.error('请填写积分');
return false;
}
// if (Number(item.giftProSkuIntegral) !== 0) {
// if (!item.giftProSkuIntegral) {
// this.$message.error('请填写积分');
// return false;
// }
// }
}
}
// 检验规格图片
if (this.IsAgreeUploadStatus) {
if (this.giftProStandardJson[0].valueList) {
......@@ -1306,6 +1323,7 @@ export default {
}
// spu未填校验||this.giftForm.cashCost===''||this.giftForm.virtualStock===''
if (this.giftForm.integralCost === '') {
this.$message.error('请填写礼品积分');
return false;
......@@ -1365,7 +1383,7 @@ export default {
integralMallProId: this.mallProId === '-1' ? '' : this.mallProId, //礼品id
proType: this.giftForm.changeType === 1 ? 2 : 3, //发货方式是微信兑换券传2其他传3
giftType: this.giftType === 0 ? 0 : 1, //0、虚拟 1、实物
proName: this.giftForm.proName, //礼品名称
proName: this.giftForm.proName.trim(), //礼品名称
giftImageUrls: giftImageUrls.join(','), //礼品主图
giftImageFiledCodes: giftImageFiledCodes.join(','),
proReferId: this.giftForm.proReferId, //关联id
......
......@@ -27,7 +27,7 @@
</el-select>
</div> -->
<div class="search-item">
<el-input v-model="searchValue" style="width:260px;" placeholder="请输入会员/卡券/订单进行搜索" prefix-icon="el-icon-search" clearable @keyup.enter.native="handleInputSearch(searchValue)" @clear="handleInputSearch(searchValue)"> </el-input>
<el-input v-model.trim="searchValue" style="width:260px;" placeholder="请输入会员/卡券/订单进行搜索" prefix-icon="el-icon-search" clearable @keyup.enter.native="handleInputSearch(searchValue)" @clear="handleInputSearch(searchValue)"> </el-input>
</div>
</div>
<div class="fr">
......
......@@ -29,7 +29,7 @@
</el-select>
</div>
<div class="search-item">
<el-input style="width:260px;" v-model="searchValue" placeholder="请输入会员/商品/订单进行搜索" prefix-icon="el-icon-search" clearable @keyup.enter.native="handleInputSearch(searchValue)" @clear="handleInputSearch(searchValue)"> </el-input>
<el-input style="width:260px;" v-model.trim="searchValue" placeholder="请输入会员/商品/订单进行搜索" prefix-icon="el-icon-search" clearable @keyup.enter.native="handleInputSearch(searchValue)" @clear="handleInputSearch(searchValue)"> </el-input>
</div>
</div>
<div class="fr">
......
......@@ -27,7 +27,7 @@
</el-select>
</div>
<div class="search-item">
<el-input class="w-340" v-model="searchValue" placeholder="请输入商品/会员/订单/退款编号进行搜索" prefix-icon="el-icon-search" clearable @keyup.enter.native="handleInputSearch(searchValue)" @clear="handleInputSearch(searchValue)"> </el-input>
<el-input class="w-340" v-model.trim="searchValue" placeholder="请输入商品/会员/订单/退款编号进行搜索" prefix-icon="el-icon-search" clearable @keyup.enter.native="handleInputSearch(searchValue)" @clear="handleInputSearch(searchValue)"> </el-input>
</div>
</div>
</div>
......
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