feat: 新增多语言文案与组件国际化适配

本次提交完成了大量多语言相关的新增与优化工作:
1. 新增充值、案例、会员资产、订单等页面的中文/英文翻译文案
2. 新增企业微信客服、时间选择、支付弹窗等组件的多语言包
3. 优化工具函数与自定义页面的多语言适配,替换硬编码提示文案
4. 新增会员等级规则、积分商品、退款管理等页面的国际化支持
5. 修复企业微信JS-SDK的错误提示文案硬编码问题
This commit is contained in:
2026-06-26 09:09:46 +08:00
parent 2d8846c64c
commit 066ca61d97
97 changed files with 2704 additions and 716 deletions

View File

@@ -4,7 +4,7 @@
<!-- 搜索区域 -->
<view class="search-wrap uni-flex uni-row" style="margin-bottom: 20rpx;">
<view class="flex-item input-wrap">
<input class="uni-input" maxlength="50" v-model="keyword" @confirm="search()" placeholder="请输入您要搜索的商品" />
<input class="uni-input" maxlength="50" v-model="keyword" @confirm="search()" :placeholder="$lang('searchPlaceholder')" />
<text class="iconfont icon-sousuo3" @click.stop="search()"></text>
</view>
<view class="iconfont" :class="{ 'icon-apps': isList, 'icon-list': !isList }" @click="changeListStyle()"></view>
@@ -28,11 +28,11 @@
<view class="scroll-desc">{{ merch.desc }}</view>
<view class="scroll-hint" v-if="isShowScrollHint">
<text class="scroll-icon">↓</text>
<text class="scroll-text">上滑查看更多</text>
<text class="scroll-text">{{ $lang('desc.scrollUpToViewMore') }}</text>
</view>
</view>
<view class="expand-tip" v-if="merch.desc && merch.desc.length > 50" @click.stop="toggleDesc">
<text class="hint-arrow">{{ isDescExpanded ? '↑ 收起' : '↓ 展开' }}</text>
<text class="hint-arrow">{{ isDescExpanded ? $lang('desc.collapse') : $lang('desc.expand') }}</text>
</view>
</view>
</view>
@@ -42,14 +42,14 @@
<view class="sort-wrap">
<view class="comprehensive-wrap" :class="{ 'color-base-text': orderType === '' }"
@click="sortTabClick('')">
<text :class="{ 'color-base-text': orderType === '' }">综合</text>
<text :class="{ 'color-base-text': orderType === '' }">{{ $lang('sort.comprehensive') }}</text>
</view>
<view :class="{ 'color-base-text': orderType === 'sale_num' }" @click="sortTabClick('sale_num')">销量
<view :class="{ 'color-base-text': orderType === 'sale_num' }" @click="sortTabClick('sale_num')">{{ $lang('sort.sales') }}
</view>
<view class="price-wrap" @click="sortTabClick('discount_price')">
<text :class="{ 'color-base-text': orderType === 'discount_price' }">价格</text>
<text :class="{ 'color-base-text': orderType === 'discount_price' }">{{ $lang('sort.price') }}</text>
<view class="iconfont-wrap">
<view class="iconfont icon-iconangledown-copy asc"
:class="{ 'color-base-text': priceOrder === 'asc' && orderType === 'discount_price' }">
@@ -61,7 +61,7 @@
</view>
<view :class="{ 'color-base-text': orderType === 'screen' }" class="screen-wrap" @click="showScreen = true">
<text @click="showScreen = true">筛选</text>
<text @click="showScreen = true">{{ $lang('sort.filter') }}</text>
<view @click="showScreen = true" class="iconfont-wrap">
<view class="iconfont icon-shaixuan color-tip"></view>
</view>
@@ -99,8 +99,7 @@
parseFloat(showPrice(item)).toFixed(2).split('.')[1] }}</text>
</view>
<view class="discount-price" v-else>
<text class="price price-style large">{{ $lang('Make') ? $lang('Make') : '立即咨询'
}}</text>
<text class="price price-style large">{{ $lang('goods.consultNow') }}</text>
</view>
@@ -118,8 +117,7 @@
<text>{{ showMarketPrice(item) }}</text>
</view>
<view class="block-wrap">
<view class="sale color-tip" v-if="item.sale_show">已售{{ item.sale_num }}{{ item.unit
? item.unit : '件' }}</view>
<view class="sale color-tip" v-if="item.sale_show">{{ $lang('goods.sold', { num: item.sale_num, unit: item.unit ? item.unit : $lang('goods.defaultUnit') }) }}</view>
</view>
<view class="cart-action-wrap" v-if="config.control && item.is_virtual == 0">
<!-- 购物车图标 -->
@@ -193,8 +191,7 @@
parseFloat(showPrice(item)).toFixed(2).split('.')[1] }}</text>
</view>
<view class="discount-price" v-else>
<text class="price price-style large">{{ $lang('Make') ? $lang('Make') : '立即咨询'
}}</text>
<text class="price price-style large">{{ $lang('goods.consultNow') }}</text>
</view>
<view class="member-price-tag"
v-if="item.member_price && item.member_price == showPrice(item)">
@@ -210,8 +207,7 @@
</view>
<view class="pro-info" v-if="item.isinformation == 0">
<view class="block-wrap">
<view class="sale color-tip" v-if="item.sale_show">已售{{ item.sale_num }}{{ item.unit
? item.unit : '件' }}</view>
<view class="sale color-tip" v-if="item.sale_show">{{ $lang('goods.sold', { num: item.sale_num, unit: item.unit ? item.unit : $lang('goods.defaultUnit') }) }}</view>
</view>
<view class="cart-action-wrap" v-if="config.control && item.is_virtual == 0">
<!-- 购物车图标 -->
@@ -258,7 +254,7 @@
</view>
</view>
</view>
<view v-if="goodsList.length == 0 && emptyShow"><ns-empty text="暂无商品"></ns-empty></view>
<view v-if="goodsList.length == 0 && emptyShow"><ns-empty :text="$lang('goods.noGoods')"></ns-empty></view>
</block>
</mescroll-uni>
@@ -266,7 +262,7 @@
<!-- 筛选弹出框 -->
<uni-drawer :visible="showScreen" mode="right" @close="showScreen = false" class="screen-wrap">
<view class="title color-tip">筛选</view>
<view class="title color-tip">{{ $lang('filter.title') }}</view>
<scroll-view scroll-y>
<!-- 包邮 -->
<!-- <view class="item-wrap">
@@ -298,10 +294,10 @@
<!-- 分类筛选项 -->
<view class="category-list-wrap">
<text class="first">全部分类</text>
<text class="first">{{ $lang('filter.allCategories') }}</text>
<view class="class-box">
<view @click="selectedCategory('')" class="list-wrap">
<text :class="{ selected: !categoryId, 'color-base-text': !categoryId }">全部</text>
<text :class="{ selected: !categoryId, 'color-base-text': !categoryId }">{{ $lang('filter.all') }}</text>
</view>
<view @click="selectedCategory(item.category_id)" v-for="(item, index) in categoryList"
:key="index" class="list-wrap">
@@ -313,8 +309,8 @@
</view>
</scroll-view>
<view class="footer" :class="{ 'safe-area': isIphoneX }">
<button type="default" class="footer-box" @click="resetData">重置</button>
<button type="primary" class="footer-box1" @click="screenData">确定</button>
<button type="default" class="footer-box" @click="resetData">{{ $lang('filter.reset') }}</button>
<button type="primary" class="footer-box1" @click="screenData">{{ $lang('filter.confirm') }}</button>
</view>
</uni-drawer>
<loading-cover ref="loadingCover"></loading-cover>

View File

@@ -53,57 +53,57 @@ export default {
begin_time:'',//团购开始时间
end_time:''//团购结束时间
},
groundingArray: ['下架', '上架'],
groundingArray: [this.$lang('grounding.offShelf'), this.$lang('grounding.onShelf')],
pickuptypeArray: ['当日达', '次日达', '隔日达'],//, '自定义'
pickuptypeArray: [this.$lang('pickupType.sameDay'), this.$lang('pickupType.nextDay'), this.$lang('pickupType.dayAfter')],//, '自定义'
currCategory: 0, // 当前所设置的商品分类
virtualDeliverArray: [{
name: '自动发货',
value: 'auto_deliver',
},
{
name: '手动发货',
value: 'artificial_deliver',
},
{
name: '到店核销',
value: 'verify',
}
],
virtualDeliverValue: {
'auto_deliver': '自动发货',
'artificial_deliver': '手动发货',
'verify': '到店核销'
},
virtualReceiveArray: [{
name: '自动收货',
value: 'auto_receive',
},
{
name: '买家确认收货',
value: 'artificial_receive',
},
],
virtualReceiveValue: {
'auto_receive': '自动收货',
'artificial_receive': '买家确认收货',
},
validityTypeArray: ['永久', '购买后几日有效', '指定过期日期'],
virtualDeliverArray: [{
name: this.$lang('virtualDeliver.auto'),
value: 'auto_deliver',
},
{
name: this.$lang('virtualDeliver.manual'),
value: 'artificial_deliver',
},
{
name: this.$lang('virtualDeliver.verify'),
value: 'verify',
}
],
virtualDeliverValue: {
'auto_deliver': this.$lang('virtualDeliver.auto'),
'artificial_deliver': this.$lang('virtualDeliver.manual'),
'verify': this.$lang('virtualDeliver.verify')
},
virtualReceiveArray: [{
name: this.$lang('virtualReceive.auto'),
value: 'auto_receive',
},
{
name: this.$lang('virtualReceive.buyerConfirm'),
value: 'artificial_receive',
},
],
virtualReceiveValue: {
'auto_receive': this.$lang('virtualReceive.auto'),
'artificial_receive': this.$lang('virtualReceive.buyerConfirm'),
},
validityTypeArray: [this.$lang('validityType.permanent'), this.$lang('validityType.daysAfterPurchase'), this.$lang('validityType.specifiedDate')],
virtualIndate: 0,
minDate: '',
carmiLength: '添加卡密',
limitLength: [ //限购
{
name: '单次限购',
value: '1'
},
{
name: '长期限购',
value: '2'
}
],
carmiLength: this.$lang('carmi.add'),
limitLength: [ //限购
{
name: this.$lang('limitType.single'),
value: '1'
},
{
name: this.$lang('limitType.longTerm'),
value: '2'
}
],
current: 0,
goodsFormArray: [],
goodsForm: [],
@@ -163,7 +163,7 @@ export default {
if(res.result.detail){
this.goodsData = res.result.detail
this.$util.showToast({
title: '商品不存在',
title: this.$lang('message.goodsNotExist'),
});
setTimeout(() => {
this.$util.redirectTo('/pages_goods/list', {}, 'redirectTo');
@@ -489,7 +489,7 @@ export default {
addShopCategory() {
if (this.shopCategoryNumber == 10) {
this.$util.showToast({
title: '商品可以属于多个分类,最多10个'
title: this.$lang('message.maxCategory')
});
return;
}
@@ -526,7 +526,7 @@ export default {
this.goodsData.carmichael = uni.getStorageSync('editGoodsCarmichael') ? JSON.parse(uni.getStorageSync('editGoodsCarmichael')) : [];
if (this.goodsData.carmichael.length > 0) {
this.carmiLength = '添加卡密【' + this.goodsData.carmichael.length + '】'
this.carmiLength = this.$lang('carmi.addWithCount', { count: this.goodsData.carmichael.length })
}
}
@@ -564,21 +564,21 @@ export default {
if (this.goodsData.goodsname.length == 0) {
this.$util.showToast({
title: '请输入商品名称'
title: this.$lang('message.pleaseEnterGoodsName')
});
return false;
}
if (this.goodsData.subtitle.length > 100) {
this.$util.showToast({
title: '商品简介不能超过100个字符'
title: this.$lang('message.subtitleMaxLength', { max: 100 })
});
return false;
}
if (this.goodsData.goods_image.length == 0) {
this.$util.showToast({
title: '请上传商品图片'
title: this.$lang('message.pleaseUploadGoodsImage')
});
return false;
}
@@ -628,20 +628,20 @@ export default {
if (this.goodsData.price == 0) {
this.$util.showToast({
title: '请输入销售价'
title: this.$lang('message.pleaseEnterSalePrice')
});
return false;
}
if (isNaN(this.goodsData.price) || !this.$util.data().regExp.digit.test(this.goodsData.price)) {
this.$util.showToast({
title: '[销售价]格式输入错误'
title: this.$lang('message.salePriceFormatError')
});
return false;
}
if (this.goodsData.productprice.length > 0 && (isNaN(this.goodsData.productprice) || !this.$util.data().regExp.digit.test(this.goodsData.productprice))) {
this.$util.showToast({
title: '[原价价]格式输入错误'
title: this.$lang('message.originalPriceFormatError')
});
return false;
}
@@ -651,26 +651,26 @@ export default {
// 总库存
if (this.goodsData.total == 0) {
this.$util.showToast({
title: '请输入库存'
title: this.$lang('message.pleaseEnterStock')
});
return false;
}
if (isNaN(this.goodsData.total) || !this.$util.data().regExp.number.test(this.goodsData.total)) {
this.$util.showToast({
title: '[库存]格式输入错误'
title: this.$lang('message.stockFormatError')
});
return false;
}
if (isNaN(this.goodsData.goods_start_count) || !this.$util.data().regExp.number.test(this.goodsData.goods_start_count)) {
this.$util.showToast({
title: '[起售]格式输入错误'
title: this.$lang('message.minOrderFormatError')
});
return false;
}
if (this.goodsData.goods_start_count < 0) {
this.$util.showToast({
title: '起售数量不能小于0'
title: this.$lang('message.minOrderNotLessThanZero')
});
return false;
}
@@ -901,7 +901,7 @@ export default {
getGoodsForm() {
getOrderFormList().then(res=>{
if (res.data) {
let goodsForm = ['请选择商品表单'];
let goodsForm = [this.$lang('placeholder.selectGoodsForm')];
res.data.forEach((item, index) => {
goodsForm.push(item.form_name);
if (this.goodsData.form_id && this.goodsData.form_id == item.id) this.goodsData.goods_form_index = index + 1;
@@ -922,7 +922,7 @@ export default {
getSupplyList() {
getSupplyList().then(res=>{
if (res.data) {
let supplyForm = ['请选择供应商'];
let supplyForm = [this.$lang('placeholder.selectSupplier')];
res.data.forEach((item, index) => {
supplyForm.push(item.title);
if (this.goodsData.supplier_id && this.goodsData.supplier_id == item.supplier_id) this.goodsData.supply_index = index + 1;

View File

@@ -6,7 +6,7 @@
<view class="flex-item input-wrap" @click.stop="search()" @tap.stop="search()">
<input class="uni-input" maxlength="50" v-model="keyword" confirm-type="search" @confirm="search()"
@click.stop="search()" @tap.stop="search()"
:placeholder="isEnEnv ? 'Please enter product keywords' : '请输入商品关键词'" />
:placeholder="$lang('goods_list.searchPlaceholder')" />
<text class="iconfont icon-sousuo3" @click.stop="search()" @tap.stop="search()"></text>
</view>
</view>
@@ -14,10 +14,10 @@
<!-- 排序 -->
<view class="sort-wrap">
<view class="comprehensive-wrap" :class="{ 'color-base-text': order === '' }" @click="sortTabClick('')">
<text :class="{ 'color-base-text': order === '' }">{{ isEnEnv ? 'Comprehensive' : '综合' }}</text>
<text :class="{ 'color-base-text': order === '' }">{{ $lang('goods_list.comprehensive') }}</text>
</view>
<view class="price-wrap" @click="sortTabClick('point')">
<text :class="{ 'color-base-text': order === 'point' }">{{ isEnEnv ? 'Points' : '积分' }}</text>
<text :class="{ 'color-base-text': order === 'point' }">{{ $lang('goods_list.points') }}</text>
<view class="iconfont-wrap">
<view class="iconfont icon-shangsanjiao-copy"
:class="{ 'color-base-text': priceOrder === 'asc' && order === 'point' }"></view>
@@ -26,8 +26,7 @@
</view>
</view>
<view class="price-wrap" @click="sortTabClick('create_time')">
<text :class="{ 'color-base-text': order === 'create_time' }">{{ isEnEnv ? 'New Arrival' : '上新时间'
}}</text>
<text :class="{ 'color-base-text': order === 'create_time' }">{{ $lang('goods_list.newArrival') }}</text>
<view class="iconfont-wrap">
<view class="iconfont icon-shangsanjiao-copy"
:class="{ 'color-base-text': priceOrder === 'asc' && order === 'create_time' }"></view>
@@ -36,7 +35,7 @@
</view>
</view>
<view :class="{ 'color-base-text': order === 'screen' }" class="screen-wrap">
<text @click="sortTabClick('screen')">{{ isEnEnv ? 'Filter' : '筛选' }}</text>
<text @click="sortTabClick('screen')">{{ $lang('goods_list.filter') }}</text>
<view @click="sortTabClick('screen')" class="iconfont-wrap">
<view class="iconfont icon-shaixuan color-tip"></view>
</view>
@@ -60,7 +59,7 @@
<view class="lineheight-clear">
<view class="discount-price">
<text class="unit ">{{ item.point }}</text>
<text class="unit font-size-tag">{{ isEnEnv ? 'Points' : '积分' }}</text>
<text class="unit font-size-tag">{{ $lang('goods_list.points') }}</text>
<block v-if="item.price > 0 && item.pay_type > 0">
<text class="unit font-size-tag">+</text>
<text class="unit font-size-tag">{{ $lang('common.currencySymbol')
@@ -73,7 +72,7 @@
</view>
</view>
<view class="pro-info" v-if="item.stock_show">
<view class="font-size-activity-tag color-tip">{{ isEnEnv ? 'Stock ' : '库存' }}{{
<view class="font-size-activity-tag color-tip">{{ $lang('goods_list.stock') }}{{
item.stock }}</view>
<view class="sale font-size-activity-tag color-tip" @click="toDetail(item)">
<!-- <button type="primary" size="mini">立即兑换</button> -->
@@ -84,7 +83,7 @@
</view>
<view class="empty" v-if="goodsList.length == 0">
<ns-empty :isIndex="false"
:text="isEnEnv ? 'No point products available' : '暂无积分商品'"></ns-empty>
:text="$lang('goods_list.noGoods')"></ns-empty>
</view>
</view>
</block>
@@ -92,26 +91,25 @@
<!-- 筛选弹出框 -->
<uni-drawer :visible="showScreen" mode="right" @close="showScreen = false" class="screen-wrap">
<view class="title color-tip">{{ isEnEnv ? 'Filter' : '筛选' }}</view>
<view class="title color-tip">{{ $lang('goods_list.filter') }}</view>
<scroll-view scroll-y>
<!-- 价格筛选项 -->
<view class="item-wrap">
<view class="label"><text>{{ isEnEnv ? 'Point Range' : '积分区间' }}</text></view>
<view class="label"><text>{{ $lang('goods_list.pointRange') }}</text></view>
<view class="price-wrap">
<input class="uni-input" type="digit" v-model="minPoint"
:placeholder="isEnEnv ? 'Min' : '最低'" />
:placeholder="$lang('goods_list.minPlaceholder')" />
<view class="h-line"></view>
<input class="uni-input" type="digit" v-model="maxPoint"
:placeholder="isEnEnv ? 'Max' : '最高'" />
:placeholder="$lang('goods_list.maxPlaceholder')" />
</view>
</view>
<!-- 分类筛选项 -->
<view class="category-list-wrap">
<text class="first">{{ isEnEnv ? 'All Categories' : '全部分类' }}</text>
<text class="first">{{ $lang('goods_list.allCategories') }}</text>
<view class="class-box">
<view @click="selectedCategory('')" class="list-wrap"><text
:class="{ selected: !categoryId, 'color-base-text': !categoryId }">{{ isEnEnv ? 'All' :
'全部' }}</text></view>
:class="{ selected: !categoryId, 'color-base-text': !categoryId }">{{ $lang('goods_list.all') }}</text></view>
<view @click="selectedCategory(item.category_id)" v-for="(item, index) in categoryList"
:key="index" class="list-wrap">
<text
@@ -122,8 +120,8 @@
</view>
</scroll-view>
<view class="footer" :class="{ 'safe-area': isIphoneX }">
<button type="default" class="footer-box" @click="resetData">{{ isEnEnv ? 'Reset' : '重置' }}</button>
<button type="primary" class="footer-box1" @click="screenData">{{ isEnEnv ? 'Confirm' : '确定' }}</button>
<button type="default" class="footer-box" @click="resetData">{{ $lang('goods_list.reset') }}</button>
<button type="primary" class="footer-box1" @click="screenData">{{ $lang('goods_list.confirm') }}</button>
</view>
</uni-drawer>
@@ -285,26 +283,26 @@ export default {
// }
if (!Number(this.maxPoint) && this.maxPoint) {
this.$util.showToast({
title: this.isEnEnv ? 'Please enter the maximum price' : '请输入最高价'
title: this.$lang('goods_list.pleaseEnterMaxPrice')
});
return;
}
if (Number(this.minPoint) < 0 || Number(this.maxPoint) < 0) {
this.$util.showToast({
title: this.isEnEnv ? 'Filter price cannot be less than 0' : '筛选价格不能小于0'
title: this.$lang('goods_list.priceCannotBeLessThanZero')
});
return;
}
if (this.minPoint != '' && Number(this.minPoint) > Number(this.maxPoint) && this.maxPoint) {
this.$util.showToast({
title: this.isEnEnv ? 'Minimum price cannot be greater than maximum price' : '最低价不能大于最高价'
title: this.$lang('goods_list.minCannotBeGreaterThanMax')
});
return;
}
if (this.maxPoint != '' && Number(this.maxPoint) < Number(this.minPoint)) {
this.$util.showToast({
title: this.isEnEnv ? 'Maximum price cannot be less than minimum price' : '最高价不能小于最低价'
title: this.$lang('goods_list.maxCannotBeLessThanMin')
});
return;
}

View File

@@ -92,7 +92,7 @@ export default {
uni.removeStorageSync("pay_flag");
} else {
this.$util.showToast({
title: '未获取到创建订单所需数据!'
title: this.$lang('payment.toast.orderDataNotFound')
});
setTimeout(() => {
this.$util.redirectTo(this.$util.INDEX_PAGE_URL);
@@ -119,7 +119,7 @@ export default {
if (this.$refs.loadingCover) this.$refs.loadingCover.hide();
} else {
this.$util.showToast({
title: '未获取到创建订单所需数据!'
title: this.$lang('payment.toast.orderDataNotFound')
});
setTimeout(() => {
this.$util.redirectTo(this.$util.INDEX_PAGE_URL);
@@ -280,9 +280,9 @@ export default {
this.isSub = false;
if (res.data.error_code == 10 || res.data.error_code == 12) {
uni.showModal({
title: '订单未创建',
title: this.$lang('payment.modal.orderNotCreated'),
content: res.message,
confirmText: '去设置',
confirmText: this.$lang('payment.modal.goToSet'),
success: res => {
if (res.confirm) {
this.selectAddress();
@@ -309,13 +309,13 @@ export default {
if (this.orderPaymentData.is_virtual == 1) {
if (!this.orderCreateData.member_address.mobile.length) {
this.$util.showToast({
title: '请输入您的手机号码'
title: this.$lang('payment.toast.pleaseEnterMobile')
});
return false;
}
if (!this.$util.verifyMobile(this.orderCreateData.member_address.mobile)) {
this.$util.showToast({
title: '请输入正确的手机号码'
title: this.$lang('payment.toast.pleaseEnterCorrectMobile')
});
return false;
}
@@ -324,7 +324,7 @@ export default {
if (this.orderPaymentData.is_virtual == 0) {
if (!this.orderCreateData.delivery || !this.orderCreateData.delivery.delivery_type) {
this.$util.showToast({
title: '商家未设置配送方式'
title: this.$lang('payment.toast.noDeliveryMethod')
});
return false;
}
@@ -332,7 +332,7 @@ export default {
if (this.orderCreateData.delivery.delivery_type != 'store') {
if (!this.orderCreateData.member_address) {
this.$util.showToast({
title: '请先选择您的收货地址'
title: this.$lang('payment.toast.pleaseSelectAddress')
});
return false;
}
@@ -341,26 +341,26 @@ export default {
if (this.orderCreateData.delivery.delivery_type == 'store') {
if (!this.orderCreateData.delivery.store_id) {
this.$util.showToast({
title: '没有可提货的门店,请选择其他配送方式'
title: this.$lang('payment.toast.noPickupStore')
});
return false;
}
if (!this.member_address.mobile) {
this.$util.showToast({
title: '请输入预留手机'
title: this.$lang('payment.toast.pleaseEnterReservedMobile')
});
return false;
}
if (!this.$util.verifyMobile(this.member_address.mobile)) {
this.$util.showToast({
title: '请输入正确的预留手机'
title: this.$lang('payment.toast.pleaseEnterCorrectReservedMobile')
});
return false;
}
if (!this.orderCreateData.delivery.buyer_ask_delivery_time.start_date || !this.orderCreateData.delivery.buyer_ask_delivery_time.end_date) {
this.$util.showToast({
title: '请选择自提时间'
title: this.$lang('payment.toast.pleaseSelectPickupTime')
});
return false;
}
@@ -369,13 +369,13 @@ export default {
if (this.orderCreateData.delivery.delivery_type == 'local') {
if (!this.orderCreateData.delivery.store_id) {
this.$util.showToast({
title: '没有可配送的门店,请选择其他配送方式'
title: this.$lang('payment.toast.noDeliveryStore')
});
return false;
}
if (this.orderPaymentData.config.local.is_use && this.orderPaymentData.delivery.local.info && this.orderPaymentData.delivery.local.info.time_is_open == 1 && (!this.orderCreateData.delivery.buyer_ask_delivery_time.start_date || !this.orderCreateData.delivery.buyer_ask_delivery_time.end_date)) {
this.$util.showToast({
title: '请选择配送时间'
title: this.$lang('payment.toast.pleaseSelectDeliveryTime')
});
return false;
}
@@ -526,7 +526,7 @@ export default {
start_date:data.data.start_date,
end_date:data.data.end_date
};
if (data.data.title == '今天' || data.data.title == '明天') {
if (data.data.title == this.$lang('payment.time.today') || data.data.title == this.$lang('payment.time.tomorrow')) {
this.orderCreateData.buyer_ask_delivery_title = data.data.title + '(' + data.data.time + ')'
} else {
this.orderCreateData.buyer_ask_delivery_title = data.data.month + '(' + data.data.time + ')'