refactor: 替换多页面国际化文本为硬编码中文内容

移除项目内大部分$lang()国际化调用,替换为直接中文文本,统一前端展示文案
This commit is contained in:
2026-06-23 08:55:16 +08:00
parent 750ed2dac7
commit f258987e0e
180 changed files with 2207 additions and 4701 deletions

View File

@@ -30,7 +30,7 @@ export default {
typeof callback == 'function' && callback(this.authInfo); typeof callback == 'function' && callback(this.authInfo);
} else { } else {
this.$util.showToast({ this.$util.showToast({
title: res.message ? res.message : this.$lang('auth.configError') title: res.message ? res.message : '小程序配置错误'
}); });
} }
} }
@@ -67,7 +67,7 @@ export default {
typeof callback == 'function' && callback(this.authInfo); typeof callback == 'function' && callback(this.authInfo);
} else { } else {
this.$util.showToast({ this.$util.showToast({
title: res.message ? res.message : this.$lang('auth.configError') title: res.message ? res.message : '小程序配置错误'
}); });
} }
} }

View File

@@ -4,7 +4,6 @@
*/ */
import IMAGE_CONFIG from './image-config.js'; import IMAGE_CONFIG from './image-config.js';
import Platform from './platform.js'; import Platform from './platform.js';
import lang from './lang.js';
export class CustomerService { export class CustomerService {
constructor(vueInstance, externalConfig = null) { constructor(vueInstance, externalConfig = null) {
@@ -101,16 +100,16 @@ export class CustomerService {
if (!config || !config.type) { if (!config || !config.type) {
result.isValid = false; result.isValid = false;
result.errors.push(lang('customerService.typeNotConfigured')); result.errors.push('客服类型未配置');
return result; return result;
} }
if (config.type === 'wxwork') { if (config.type === 'wxwork') {
if (!wxworkConfig || !wxworkConfig.enable) { if (!wxworkConfig || !wxworkConfig.enable) {
result.warnings.push(lang('customerService.wxworkNotEnabled')); result.warnings.push('企业微信未启用');
} }
if (!wxworkConfig.contact_url) { if (!wxworkConfig.contact_url) {
result.warnings.push(lang('customerService.wxworkContactUrlNotConfigured')); result.warnings.push('企业微信活码链接未配置');
} }
} }
@@ -139,12 +138,12 @@ export class CustomerService {
// #ifdef H5 // #ifdef H5
window.location.href = aiChatUrl; window.location.href = aiChatUrl;
// #endif // #endif
uni.showToast({ title: lang('customerService.openFailed'), icon: 'none' }); uni.showToast({ title: '打开客服失败', icon: 'none' });
} }
}); });
} catch (e) { } catch (e) {
console.error('跳转 AI智能客服异常:', e); console.error('跳转 AI智能客服异常:', e);
uni.showToast({ title: lang('customerService.openFailed'), icon: 'none' }); uni.showToast({ title: '打开客服失败', icon: 'none' });
} }
} }
@@ -224,7 +223,7 @@ export class CustomerService {
// 检查是否有企业微信配置 // 检查是否有企业微信配置
if (!config.wxwork_url && !config.corpid) { if (!config.wxwork_url && !config.corpid) {
console.error('企业微信配置不完整,缺少 wxwork_url 或 corpid'); console.error('企业微信配置不完整,缺少 wxwork_url 或 corpid');
uni.showToast({ title: lang('customerService.wxworkConfigIncomplete'), icon: 'none' }); uni.showToast({ title: '企业微信配置不完整', icon: 'none' });
this.fallbackToPhoneCall(); this.fallbackToPhoneCall();
return; return;
} }
@@ -268,12 +267,12 @@ export class CustomerService {
}, },
fail: (err) => { fail: (err) => {
console.error('【跳转第三方小程序失败】', err); console.error('【跳转第三方小程序失败】', err);
uni.showToast({ title: lang('customerService.thirdMiniAppFailed'), icon: 'none' }); uni.showToast({ title: '跳转失败,请稍后重试', icon: 'none' });
} }
}); });
// #endif // #endif
// #ifdef H5 // #ifdef H5
uni.showToast({ title: lang('customerService.thirdMiniAppOnlyInWechat'), icon: 'none' }); uni.showToast({ title: '第三方小程序客服仅在微信小程序中可用', icon: 'none' });
// #endif // #endif
return; return;
} }
@@ -287,7 +286,7 @@ export class CustomerService {
uni.setClipboardData({ uni.setClipboardData({
data: config.third_url, data: config.third_url,
success: () => { success: () => {
uni.showToast({ title: lang('customerService.linkCopiedOpenBrowser'), icon: 'none' }); uni.showToast({ title: '链接已复制,请在浏览器打开', icon: 'none' });
} }
}); });
// #endif // #endif
@@ -353,7 +352,7 @@ export class CustomerService {
// #endif // #endif
// #ifdef MP // #ifdef MP
uni.setClipboardData({ data: serviceUrl }); uni.setClipboardData({ data: serviceUrl });
uni.showToast({ title: lang('customerService.linkCopied'), icon: 'none' }); uni.showToast({ title: '客服链接已复制', icon: 'none' });
// #endif // #endif
return; return;
} }
@@ -381,11 +380,11 @@ export class CustomerService {
if (res.code === 0 && res.data?.mobile) { if (res.code === 0 && res.data?.mobile) {
uni.makePhoneCall({ phoneNumber: res.data.mobile }); uni.makePhoneCall({ phoneNumber: res.data.mobile });
} else { } else {
uni.showToast({ title: lang('customerService.noPhone'), icon: 'none' }); uni.showToast({ title: '暂无客服电话', icon: 'none' });
} }
}, },
fail: () => { fail: () => {
uni.showToast({ title: lang('customerService.getPhoneFailed'), icon: 'none' }); uni.showToast({ title: '获取客服电话失败', icon: 'none' });
} }
}); });
} }
@@ -393,23 +392,23 @@ export class CustomerService {
showNoServicePopup() { showNoServicePopup() {
const siteInfo = this.vm.$store.state.siteInfo || {}; const siteInfo = this.vm.$store.state.siteInfo || {};
const message = siteInfo?.site_tel const message = siteInfo?.site_tel
? lang('customerService.contactPhone', { phone: siteInfo.site_tel }) ? `请联系客服,客服电话是 ${siteInfo.site_tel}`
: lang('customerService.noServiceOffline'); : '抱歉,商家暂无客服,请线下联系';
uni.showModal({ title: lang('customerService.contactCustomerService'), content: message, showCancel: false }); uni.showModal({ title: '联系客服', content: message, showCancel: false });
} }
showConfigErrorPopup(errors) { showConfigErrorPopup(errors) {
uni.showModal({ uni.showModal({
title: lang('customerService.configError'), title: '客服配置错误',
content: lang('customerService.configErrorMsg', { errors: errors.join('\n') }), content: `配置有误:\n${errors.join('\n')}`,
showCancel: false showCancel: false
}); });
} }
fallbackToOriginalService() { fallbackToOriginalService() {
uni.showModal({ uni.showModal({
title: lang('common.tip'), title: '提示',
content: lang('customerService.cannotAddWxwork'), content: '无法直接添加企业微信,是否使用其他方式联系客服?',
success: (res) => { success: (res) => {
if (res.confirm) { if (res.confirm) {
this.openWxworkService(true); this.openWxworkService(true);
@@ -420,8 +419,8 @@ export class CustomerService {
fallbackToPhoneCall() { fallbackToPhoneCall() {
uni.showModal({ uni.showModal({
title: lang('common.tip'), title: '提示',
content: lang('customerService.onlineServiceUnavailable'), content: '在线客服不可用,是否拨打电话联系客服?',
success: (res) => { success: (res) => {
if (res.confirm) this.makePhoneCall(); if (res.confirm) this.makePhoneCall();
} }
@@ -568,12 +567,12 @@ export class CustomerService {
// #ifdef H5 // #ifdef H5
window.location.href = aiChatUrl; window.location.href = aiChatUrl;
// #endif // #endif
uni.showToast({ title: lang('customerService.openFailed'), icon: 'none' }); uni.showToast({ title: '打开客服失败', icon: 'none' });
} }
}); });
} catch (e) { } catch (e) {
console.error('跳转 AI智能客服异常:', e); console.error('跳转 AI智能客服异常:', e);
uni.showToast({ title: lang('customerService.openFailed'), icon: 'none' }); uni.showToast({ title: '打开客服失败', icon: 'none' });
} }
} }
@@ -581,7 +580,7 @@ export class CustomerService {
* 打开客服选择对话框(预留方法) * 打开客服选择对话框(预留方法)
*/ */
openCustomerSelectPopupDialog() { openCustomerSelectPopupDialog() {
uni.showToast({ title: lang('customerService.developing'), icon: 'none' }); uni.showToast({ title: '客服选择功能开发中', icon: 'none' });
} }
/** /**
@@ -611,7 +610,7 @@ export class CustomerService {
if (qyweixinUrl) { if (qyweixinUrl) {
window.location.href = qyweixinUrl; window.location.href = qyweixinUrl;
} else { } else {
uni.showToast({ title: lang('customerService.wxworkNotConfigured'), icon: 'none' }); uni.showToast({ title: '企业微信客服未配置', icon: 'none' });
} }
} }
} else { } else {
@@ -630,7 +629,7 @@ export class CustomerService {
if (!validation.isValid) { if (!validation.isValid) {
console.error('客服配置无效:', validation.errors); console.error('客服配置无效:', validation.errors);
uni.showToast({ title: lang('customerService.unavailable'), icon: 'none' }); uni.showToast({ title: '客服暂不可用', icon: 'none' });
return; return;
} }
@@ -647,7 +646,7 @@ export class CustomerService {
// #ifdef MP-WEIXIN // #ifdef MP-WEIXIN
if (!wxworkConfig?.enable || !wxworkConfig?.contact_url) { if (!wxworkConfig?.enable || !wxworkConfig?.contact_url) {
console.warn('企业微信配置不完整,使用原生客服'); console.warn('企业微信配置不完整,使用原生客服');
uni.showToast({ title: lang('customerService.wxworkConfigIncomplete'), icon: 'none' }); uni.showToast({ title: '企业微信配置不完整', icon: 'none' });
} }
// #endif // #endif
@@ -668,7 +667,7 @@ export class CustomerService {
}); });
} catch (error) { } catch (error) {
console.error('客服处理失败:', error); console.error('客服处理失败:', error);
uni.showToast({ title: lang('customerService.openFailed'), icon: 'none' }); uni.showToast({ title: '打开客服失败', icon: 'none' });
} }
} }
} }

View File

@@ -326,7 +326,7 @@ export default {
} }
this.$util.showToast({ this.$util.showToast({
title: this.$lang('diy.noCustomPageData') title: '未配置自定义页面数据'
}); });
this.diyData = {}; this.diyData = {};
return; return;
@@ -560,7 +560,7 @@ export default {
if (res.code == 0 && res.data) { if (res.code == 0 && res.data) {
this.currentPosition = res.data.formatted_addresses.recommend; // 结合知名地点形成的描述性地址,更具人性化特点 this.currentPosition = res.data.formatted_addresses.recommend; // 结合知名地点形成的描述性地址,更具人性化特点
} else { } else {
this.currentPosition = this.$lang('diy.locationNotObtained'); this.currentPosition = '未获取到定位';
} }
} }
}); });
@@ -572,7 +572,7 @@ export default {
this.nearestStore = this.defaultStoreInfo; this.nearestStore = this.defaultStoreInfo;
this.nearestStore.show_address = this.nearestStore.full_address.replace(/,/g, ' ') + ' ' + this.nearestStore.address; this.nearestStore.show_address = this.nearestStore.full_address.replace(/,/g, ' ') + ' ' + this.nearestStore.address;
} }
if (this.currentPosition == '') this.currentPosition = this.$lang('diy.locationNotObtained'); if (this.currentPosition == '') this.currentPosition = '未获取到定位';
this.openChooseStorePopup(); this.openChooseStorePopup();
} }
}, },

View File

@@ -2,7 +2,6 @@ import Config from './config.js'
import Util from './util.js' import Util from './util.js'
import store from '@/store/index.js' import store from '@/store/index.js'
import Platform from './platform.js' import Platform from './platform.js'
import lang from './lang.js'
const { appType, appTypeName } = Platform.getPlatformInfo(); const { appType, appTypeName } = Platform.getPlatformInfo();
@@ -10,7 +9,7 @@ export default {
sendRequest(params) { sendRequest(params) {
if (!Config.baseUrl) { if (!Config.baseUrl) {
uni.showToast({ uni.showToast({
title: lang('http.domainNotConfigured'), title: '未配置请求域名',
'icon': 'none', 'icon': 'none',
duration: 10000 duration: 10000
}); });
@@ -78,7 +77,7 @@ export default {
fail: (res) => { fail: (res) => {
if (res.errMsg && res.errMsg == 'request:fail url not in domain list') { if (res.errMsg && res.errMsg == 'request:fail url not in domain list') {
uni.showToast({ uni.showToast({
title: lang('http.domainNotInList', { domain: Config.baseUrl }), title: Config.baseUrl + '不在request 合法域名列表中',
'icon': 'none', 'icon': 'none',
duration: 10000 duration: 10000
}); });
@@ -89,7 +88,7 @@ export default {
complete: (res) => { complete: (res) => {
if ((res.errMsg && res.errMsg != "request:ok") || (res.statusCode && [200, 500].indexOf(res.statusCode) == -1)) { if ((res.errMsg && res.errMsg != "request:ok") || (res.statusCode && [200, 500].indexOf(res.statusCode) == -1)) {
uni.showToast({ uni.showToast({
title: lang('http.requestFailed', { domain: Config.baseUrl }), title: Config.baseUrl + '请求失败',
'icon': 'none', 'icon': 'none',
duration: 10000 duration: 10000
}); });
@@ -135,7 +134,7 @@ export default {
fail: (res) => { fail: (res) => {
if (res.errMsg && res.errMsg == 'request:fail url not in domain list') { if (res.errMsg && res.errMsg == 'request:fail url not in domain list') {
uni.showToast({ uni.showToast({
title: lang('http.domainNotInList', { domain: Config.baseUrl }), title: Config.baseUrl + '不在request 合法域名列表中',
'icon': 'none', 'icon': 'none',
duration: 10000 duration: 10000
}); });
@@ -146,7 +145,7 @@ export default {
complete: (res) => { complete: (res) => {
if ((res.errMsg && res.errMsg != "request:ok") || (res.statusCode && [200, 500].indexOf(res.statusCode) == -1)) { if ((res.errMsg && res.errMsg != "request:ok") || (res.statusCode && [200, 500].indexOf(res.statusCode) == -1)) {
uni.showToast({ uni.showToast({
title: lang('http.requestFailed', { domain: Config.baseUrl }), title: Config.baseUrl + '请求失败',
'icon': 'none', 'icon': 'none',
duration: 10000 duration: 10000
}); });

View File

@@ -1,6 +1,4 @@
// 文件分享工具函数 // 文件分享工具函数
import lang from './lang.js';
export default { export default {
/** /**
* 生成文件预览链接 * 生成文件预览链接
@@ -32,7 +30,7 @@ export default {
* @param {string} title - 分享标题,默认使用文件名 * @param {string} title - 分享标题,默认使用文件名
* @param {string} desc - 分享描述,默认使用固定文案 * @param {string} desc - 分享描述,默认使用固定文案
*/ */
shareFile(file, title = file.name, desc = lang('share.filePreview') + file.name) { shareFile(file, title = file.name, desc = '查看企业文件:' + file.name) {
// 生成文件预览链接 // 生成文件预览链接
const filePreviewUrl = this.generateFilePreviewUrl(file); const filePreviewUrl = this.generateFilePreviewUrl(file);
@@ -46,17 +44,17 @@ export default {
url: filePreviewUrl url: filePreviewUrl
}).catch(err => { }).catch(err => {
console.error('分享失败:', err); console.error('分享失败:', err);
uni.showToast({ title: lang('share.failed'), icon: 'none' }); uni.showToast({ title: '分享失败', icon: 'none' });
}); });
} else { } else {
// 不支持 Web Share API 的浏览器 // 不支持 Web Share API 的浏览器
uni.setClipboardData({ uni.setClipboardData({
data: filePreviewUrl, data: filePreviewUrl,
success: () => { success: () => {
uni.showToast({ title: lang('share.linkCopied'), icon: 'success' }); uni.showToast({ title: '链接已复制,请粘贴分享', icon: 'success' });
}, },
fail: () => { fail: () => {
uni.showToast({ title: lang('common.copyFailed'), icon: 'none' }); uni.showToast({ title: '复制失败', icon: 'none' });
} }
}); });
} }
@@ -65,7 +63,7 @@ export default {
// #ifdef MP-WEIXIN // #ifdef MP-WEIXIN
// 微信小程序分享 // 微信小程序分享
uni.showActionSheet({ uni.showActionSheet({
itemList: [lang('share.sendToFriend'), lang('share.sendToMoments')], itemList: ['发送给朋友', '分享到朋友圈'],
success: (res) => { success: (res) => {
if (res.tapIndex === 0) { if (res.tapIndex === 0) {
// 发送给朋友 // 发送给朋友
@@ -73,10 +71,10 @@ export default {
title: title, title: title,
path: filePreviewUrl, path: filePreviewUrl,
success: () => { success: () => {
uni.showToast({ title: lang('share.success'), icon: 'success' }); uni.showToast({ title: '分享成功', icon: 'success' });
}, },
fail: () => { fail: () => {
uni.showToast({ title: lang('share.failed'), icon: 'none' }); uni.showToast({ title: '分享失败', icon: 'none' });
} }
}); });
} else if (res.tapIndex === 1) { } else if (res.tapIndex === 1) {
@@ -85,10 +83,10 @@ export default {
title: desc, title: desc,
path: filePreviewUrl, path: filePreviewUrl,
success: () => { success: () => {
uni.showToast({ title: lang('share.success'), icon: 'success' }); uni.showToast({ title: '分享成功', icon: 'success' });
}, },
fail: () => { fail: () => {
uni.showToast({ title: lang('share.failed'), icon: 'none' }); uni.showToast({ title: '分享失败', icon: 'none' });
} }
}); });
} }

View File

@@ -2,7 +2,6 @@ import Config from './config.js'
import store from '@/store/index.js' import store from '@/store/index.js'
import Http from './http.js' import Http from './http.js'
import Platform from './platform.js' import Platform from './platform.js'
import lang from './lang.js'
import { import {
Weixin Weixin
} from 'common/js/wx-jssdk.js'; } from 'common/js/wx-jssdk.js';
@@ -669,7 +668,7 @@ export default {
tMonth = doHandleMonth(tMonth + 1); tMonth = doHandleMonth(tMonth + 1);
tDate = doHandleMonth(tDate); tDate = doHandleMonth(tDate);
const week = [lang('common.sunday'), lang('common.monday'), lang('common.tuesday'), lang('common.wednesday'), lang('common.thursday'), lang('common.friday'), lang('common.saturday')] const week = ['周日', '周一', '周二', '周三', '周四', '周五', '周六']
return { return {
't': time, 't': time,
'y': tYear, 'y': tYear,
@@ -706,7 +705,7 @@ export default {
var _data = data; var _data = data;
var imgs = []; var imgs = [];
uni.showLoading({ uni.showLoading({
title: lang('common.uploading') title: '图片上传中'
}) })
for (var i = 0; i < tempFilePaths.length; i++) { for (var i = 0; i < tempFilePaths.length; i++) {
var path = await _self.upload_file_server(tempFilePaths[i], _data, params.path, var path = await _self.upload_file_server(tempFilePaths[i], _data, params.path,
@@ -715,7 +714,7 @@ export default {
if (imgs.length == tempFilePaths.length) { if (imgs.length == tempFilePaths.length) {
uni.hideLoading() uni.hideLoading()
uni.showToast({ uni.showToast({
title: lang('common.uploadSuccess'), title: '上传成功',
icon: 'none' icon: 'none'
}) })
typeof callback == 'function' && callback(imgs); typeof callback == 'function' && callback(imgs);
@@ -725,7 +724,7 @@ export default {
fail: err => { fail: err => {
uni.hideLoading() uni.hideLoading()
uni.showToast({ uni.showToast({
title: lang('common.uploadFailed'), title: '上传失败',
icon: 'none' icon: 'none'
}) })
} }
@@ -776,7 +775,7 @@ export default {
oInput.style.display = 'none'; oInput.style.display = 'none';
uni.hideKeyboard(); uni.hideKeyboard();
this.showToast({ this.showToast({
title: lang('common.copySuccess') title: '复制成功'
}); });
typeof callback == 'function' && callback(); typeof callback == 'function' && callback();
@@ -1040,7 +1039,7 @@ export default {
}); });
} else { } else {
this.showToast({ this.showToast({
title: lang('common.noCustomerService'), title: '抱歉,商家暂无客服,请线下联系',
}) })
} }
} }

View File

@@ -91,12 +91,12 @@
<!-- 查看更多(仅非滚动模式显示) --> <!-- 查看更多(仅非滚动模式显示) -->
<view class="view-more" v-if="viewMore.support && viewMore.control && list.length > 0" <view class="view-more" v-if="viewMore.support && viewMore.control && list.length > 0"
:style="viewMoreStyle" @tap.stop="toListPage"> :style="viewMoreStyle" @tap.stop="toListPage">
<text>{{ viewMore.text || $lang('article.viewMore') }}</text> <text>{{ viewMore.text || '查看更多' }}</text>
<uni-icons type="arrowright" size="12" :color="viewMore.color" /> <uni-icons type="arrowright" size="12" :color="viewMore.color" />
</view> </view>
</template> </template>
<view v-if="list.length === 0 && !loading" class="empty-placeholder"> <view v-if="list.length === 0 && !loading" class="empty-placeholder">
<text class="empty-text">{{ $lang('article.noRelatedArticles') }}</text> <text class="empty-text">暂无相关文章</text>
</view> </view>
</view> </view>
</view> </view>
@@ -327,7 +327,7 @@ export default {
}, },
viewMore() { viewMore() {
// control 默认 true 与后端 design.js + diy_view.php 对齐(老数据没 viewMore 时也走显示) // control 默认 true 与后端 design.js + diy_view.php 对齐(老数据没 viewMore 时也走显示)
return Object.assign({ support: true, control: true, text: this.$lang('article.viewMore'), color: '#999999', iconSize: 24 }, return Object.assign({ support: true, control: true, text: '查看更多', color: '#999999', iconSize: 24 },
this.value.viewMore || {}); this.value.viewMore || {});
}, },
// 阅读区样式(文字色 + 图标大小 + 文字大小) // 阅读区样式(文字色 + 图标大小 + 文字大小)

View File

@@ -75,7 +75,7 @@
color: value.btnStyle.theme == 'diy' ? value.btnStyle.textColor : '', color: value.btnStyle.theme == 'diy' ? value.btnStyle.textColor : '',
borderRadius: value.btnStyle.aroundRadius * 2 + 'rpx' borderRadius: value.btnStyle.aroundRadius * 2 + 'rpx'
}"> }">
{{ item.is_bargaining ? $lang('bargain.continueBargain') : value.btnStyle.text }} {{ item.is_bargaining ? '继续砍价' : value.btnStyle.text }}
</button> </button>
</view> </view>
</view> </view>

View File

@@ -517,13 +517,13 @@ export default {
if (_num > parseInt(data.stock)) { if (_num > parseInt(data.stock)) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('goods.insufficientStock') title: '商品库存不足'
}); });
return; return;
} }
if (data.is_limit && data.max_buy && _num > parseInt(data.max_buy)) { if (data.is_limit && data.max_buy && _num > parseInt(data.max_buy)) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('goods.maxBuyLimit', { max: data.max_buy, unit: data.unit || this.$lang('goods.piece') }) title: `该商品每人限购${data.max_buy}${data.unit || '件'}`
}); });
return; return;
} }

View File

@@ -51,7 +51,7 @@
</scroll-view> </scroll-view>
<view class="category-item-all" @tap.stop="$refs.templateFourPopup.open()"> <view class="category-item-all" @tap.stop="$refs.templateFourPopup.open()">
<view class="category-item-all-wrap"> <view class="category-item-all-wrap">
<text class="text">{{ $lang('category.expand') }}</text> <text class="text">展开</text>
<image class="img" :src="$util.img('/public/uniapp/category/unfold.png')" mode="aspectFill" show-menu-by-longpress></image> <image class="img" :src="$util.img('/public/uniapp/category/unfold.png')" mode="aspectFill" show-menu-by-longpress></image>
</view> </view>
</view> </view>
@@ -68,7 +68,7 @@
</view> </view>
</scroll-view> </scroll-view>
<view class="pack-up" @tap.stop="$refs.templateFourPopup.close()"> <view class="pack-up" @tap.stop="$refs.templateFourPopup.close()">
<text>{{ $lang('category.clickToCollapse') }}</text> <text>点击收起</text>
<text class="iconfont icon-iconangledown-copy"></text> <text class="iconfont icon-iconangledown-copy"></text>
</view> </view>
</view> </view>
@@ -102,7 +102,7 @@
@tologin="toLogin" @selectsku="selectSku($event, index)" @addCart="addCartPoint" @tologin="toLogin" @selectsku="selectSku($event, index)" @addCart="addCartPoint"
@loadfinish="getHeightArea"></diy-category-item> @loadfinish="getHeightArea"></diy-category-item>
</view> </view>
<view class="end-tips" ref="endTips" :style="{ opacity: endTips }">{{ $lang('category.reachedBottom') }}</view> <view class="end-tips" ref="endTips" :style="{ opacity: endTips }">已经到底了~</view>
</scroll-view> </scroll-view>
<view class="content-wrap" <view class="content-wrap"
@@ -120,12 +120,12 @@
</block> </block>
<view class="category-empty" v-else> <view class="category-empty" v-else>
<image :src="$util.img('public/uniapp/category/empty.png')" mode="widthFix" show-menu-by-longpress></image> <image :src="$util.img('public/uniapp/category/empty.png')" mode="widthFix" show-menu-by-longpress></image>
<view class="tips">{{ $lang('category.noCategory') }}</view> <view class="tips">暂时没有分类哦!</view>
</view> </view>
</view> </view>
<view class="category-empty" v-else> <view class="category-empty" v-else>
<image :src="$util.img('public/uniapp/category/empty.png')" mode="widthFix" show-menu-by-longpress></image> <image :src="$util.img('public/uniapp/category/empty.png')" mode="widthFix" show-menu-by-longpress></image>
<view class="tips">{{ $lang('category.noCategory') }}</view> <view class="tips">暂时没有分类哦!</view>
</view> </view>
<!-- <view class="cart-box" v-if="(value.template == 2 || value.template == 4) && value.quickBuy && storeToken && categoryTree && categoryTree.length"> <!-- <view class="cart-box" v-if="(value.template == 2 || value.template == 4) && value.quickBuy && storeToken && categoryTree && categoryTree.length">
@@ -409,7 +409,7 @@ export default {
success: res => { success: res => {
if (res.code >= 0) { if (res.code >= 0) {
let item = res.data; let item = res.data;
item.unit = item.unit || this.$lang('goods.piece'); item.unit = item.unit || '件';
if (item.sku_images) item.sku_images = item.sku_images.split(','); if (item.sku_images) item.sku_images = item.sku_images.split(',');
else item.sku_images = []; else item.sku_images = [];

View File

@@ -265,7 +265,7 @@ export default {
// #ifndef MP-WEIXIN // #ifndef MP-WEIXIN
if (item?.channelType === 'wechat') { if (item?.channelType === 'wechat') {
uni.showToast({ uni.showToast({
title: this.$lang('channel.wechatOnly'), title: '视频号仅支持在微信小程序环境中播放',
icon: 'none', icon: 'none',
duration: 2000 duration: 2000
}); });

View File

@@ -26,16 +26,16 @@
</view> </view>
<view class="coupon-num" :style="{ color: value.moneyColor }" v-else> <view class="coupon-num" :style="{ color: value.moneyColor }" v-else>
<text class="coupon-size">{{ item.discount | moneyConduct }}</text> <text class="coupon-size">{{ item.discount | moneyConduct }}</text>
<text class="font-size-tag coupon-sign">{{ $lang('coupon.discountSuffix') }}</text> <text class="font-size-tag coupon-sign">折</text>
</view> </view>
<view class="coupon-type font-size-tag" :style="{ color: value.limitColor }"> <view class="coupon-type font-size-tag" :style="{ color: value.limitColor }">
{{ item.at_least > 0 ? $lang('coupon.thresholdAvailable', { amount: Number(item.at_least) }) : $lang('coupon.noThreshold') }} {{ item.at_least > 0 ? '满' + Number(item.at_least) + '元可用' : '无门槛优惠券' }}
</view> </view>
</view> </view>
<view class="coupon-get" :style="couponBtnStyle" v-if="item.useState == 0"> <view class="coupon-get" :style="couponBtnStyle" v-if="item.useState == 0">
{{ value.btnStyle.text }} {{ value.btnStyle.text }}
</view> </view>
<view class="coupon-get" :style="couponBtnStyle" v-if="parseInt(item.useState)">{{ $lang('coupon.goUse') }}</view> <view class="coupon-get" :style="couponBtnStyle" v-if="parseInt(item.useState)">去使用</view>
</view> </view>
</swiper-item> </swiper-item>
@@ -61,16 +61,16 @@
</view> </view>
<view class="coupon-num" :style="{ color: value.moneyColor }" v-else> <view class="coupon-num" :style="{ color: value.moneyColor }" v-else>
<text class="coupon-size">{{ item.discount | moneyConduct }}</text> <text class="coupon-size">{{ item.discount | moneyConduct }}</text>
<text class="font-size-tag coupon-sign">{{ $lang('coupon.discountSuffix') }}</text> <text class="font-size-tag coupon-sign">折</text>
</view> </view>
<view class="coupon-type font-size-tag" :style="{ color: value.limitColor }"> <view class="coupon-type font-size-tag" :style="{ color: value.limitColor }">
{{ item.at_least > 0 ? $lang('coupon.thresholdAvailable', { amount: Number(item.at_least) }) : $lang('coupon.noThreshold') }} {{ item.at_least > 0 ? '满' + Number(item.at_least) + '元可用' : '无门槛优惠券' }}
</view> </view>
</view> </view>
<view class="coupon-get" :style="couponBtnStyle" v-if="item.useState == 0"> <view class="coupon-get" :style="couponBtnStyle" v-if="item.useState == 0">
{{ value.btnStyle.text || $lang('coupon.receive') }} {{ value.btnStyle.text || '领取' }}
</view> </view>
<view class="coupon-get use" :style="couponBtnStyle" v-if="parseInt(item.useState)">{{ $lang('coupon.useNow') }} <view class="coupon-get use" :style="couponBtnStyle" v-if="parseInt(item.useState)">去使用
</view> </view>
</view> </view>
</swiper-item> </swiper-item>
@@ -95,19 +95,20 @@
</view> </view>
<view class="coupon-num" :style="{ color: value.moneyColor }" v-else> <view class="coupon-num" :style="{ color: value.moneyColor }" v-else>
<text class="coupon-size">{{ item.discount | moneyConduct }}</text> <text class="coupon-size">{{ item.discount | moneyConduct }}</text>
<text class="font-size-tag coupon-sign">{{ $lang('coupon.discountSuffix') }}</text> <text class="font-size-tag coupon-sign">折</text>
</view> </view>
<view class="coupon-type font-size-tag"> <view class="coupon-type font-size-tag">
<text :style="{ color: value.limitColor }">{{ item.at_least > 0 ? $lang('coupon.thresholdAvailable', { amount: Number(item.at_least) }) : $lang('coupon.noThreshold') }}</text> <text :style="{ color: value.limitColor }">{{ item.at_least > 0 ? '满' +
<view class="item-text" v-if="item.goods_type == 1">{{ $lang('coupon.allGoodsAvailable') }}</view> Number(item.at_least) + '元可用' : '无门槛优惠券' }}</text>
<view class="item-text" v-else-if="item.goods_type == 2">{{ $lang('coupon.designatedGoodsAvailable') }}</view> <view class="item-text" v-if="item.goods_type == 1">所有商品可用</view>
<view class="item-text" v-else-if="item.goods_type == 3">{{ $lang('coupon.designatedGoodsUnavailable') }}</view> <view class="item-text" v-else-if="item.goods_type == 2">指定商品可用</view>
<view class="item-text" v-else-if="item.goods_type == 3">指定商品不可用</view>
</view> </view>
<view class="coupon-get" :style="couponBtnStyle" v-if="item.useState == 0"> <view class="coupon-get" :style="couponBtnStyle" v-if="item.useState == 0">
{{ value.btnStyle.text || $lang('coupon.receive') }} {{ value.btnStyle.text || '领取' }}
</view> </view>
<view class="coupon-get" :style="couponBtnStyle" v-if="parseInt(item.useState)">{{ $lang('coupon.goUse') }}</view> <view class="coupon-get" :style="couponBtnStyle" v-if="parseInt(item.useState)">去使用</view>
</view> </view>
</swiper-item> </swiper-item>
</swiper> </swiper>
@@ -132,16 +133,16 @@
</view> </view>
<view class="coupon-num" :style="{ color: value.moneyColor }" v-else> <view class="coupon-num" :style="{ color: value.moneyColor }" v-else>
<text class="coupon-size">{{ item.discount | moneyConduct }}</text> <text class="coupon-size">{{ item.discount | moneyConduct }}</text>
<text class="font-size-tag coupon-sign">{{ $lang('coupon.discountSuffix') }}</text> <text class="font-size-tag coupon-sign">折</text>
</view> </view>
<view class="coupon-type font-size-tag" :style="{ color: value.limitColor }"> <view class="coupon-type font-size-tag" :style="{ color: value.limitColor }">
{{ item.at_least > 0 ? $lang('coupon.thresholdAvailable', { amount: Number(item.at_least) }) : $lang('coupon.noThreshold') }} {{ item.at_least > 0 ? '满' + Number(item.at_least) + '元可用' : '无门槛优惠券' }}
</view> </view>
</view> </view>
<view class="coupon-get" :style="couponBtnStyle" v-if="item.useState == 0"> <view class="coupon-get" :style="couponBtnStyle" v-if="item.useState == 0">
{{ value.btnStyle.text || $lang('coupon.useNow') }} {{ value.btnStyle.text || '立即使用' }}
</view> </view>
<view class="coupon-get" :style="couponBtnStyle" v-if="parseInt(item.useState)">{{ $lang('coupon.goUse') }}</view> <view class="coupon-get" :style="couponBtnStyle" v-if="parseInt(item.useState)">去使用</view>
</view> </view>
</swiper-item> </swiper-item>
</swiper> </swiper>
@@ -159,11 +160,11 @@
<view class="coupon-num" v-if="item.discount == '0.00'" <view class="coupon-num" v-if="item.discount == '0.00'"
:style="{ color: value.moneyColor }"> :style="{ color: value.moneyColor }">
<text class="coupon-size">{{ item.money | moneyConduct }}</text> <text class="coupon-size">{{ item.money | moneyConduct }}</text>
<text class="font-size-tag coupon-sign">{{ $lang('coupon.currencyUnit') }}</text> <text class="font-size-tag coupon-sign">元</text>
</view> </view>
<view class="coupon-num" v-else :style="{ color: value.moneyColor }"> <view class="coupon-num" v-else :style="{ color: value.moneyColor }">
<text class="coupon-size">{{ item.discount | moneyConduct }}</text> <text class="coupon-size">{{ item.discount | moneyConduct }}</text>
<text class="font-size-tag coupon-sign">{{ $lang('coupon.discountSuffix') }}</text> <text class="font-size-tag coupon-sign">折</text>
</view> </view>
</view> </view>
<view class="coupon-line"></view> <view class="coupon-line"></view>
@@ -172,14 +173,14 @@
<view class="coupon-name" :style="{ color: value.nameColor }">{{ <view class="coupon-name" :style="{ color: value.nameColor }">{{
item.coupon_name }}</view> item.coupon_name }}</view>
<text class="coupon-least" :style="{ color: value.limitColor }" <text class="coupon-least" :style="{ color: value.limitColor }"
v-if="item.at_least > 0">{{ $lang('coupon.thresholdAvailable', { amount: Number(item.at_least) }) }}</text> v-if="item.at_least > 0">满{{ Number(item.at_least) }}元可用</text>
<text class="coupon-least" :style="{ color: value.limitColor }" <text class="coupon-least" :style="{ color: value.limitColor }"
v-else>{{ $lang('coupon.noThreshold') }}</text> v-else>无门槛优惠券</text>
</view> </view>
<view class="coupon-get" :style="couponBtnStyle" v-if="item.useState == 0">{{ <view class="coupon-get" :style="couponBtnStyle" v-if="item.useState == 0">{{
value.btnStyle.text || $lang('coupon.claimNow') }}</view> value.btnStyle.text || '立即领取' }}</view>
<view class="coupon-get" :style="couponBtnStyle" v-if="parseInt(item.useState)"> <view class="coupon-get" :style="couponBtnStyle" v-if="parseInt(item.useState)">
{{ $lang('coupon.goUse') }}</view> 去使用</view>
</view> </view>
</view> </view>
</view> </view>
@@ -200,32 +201,32 @@
marginLeft: couponItemHeight + 'px' marginLeft: couponItemHeight + 'px'
}" @tap.stop="couponAction(item, index)"> }" @tap.stop="couponAction(item, index)">
<view class="coupon-content"> <view class="coupon-content">
<view class="price-wrap"> <view class="price-wrap">
<text class="price" :style="{ color: value.moneyColor }">{{ (item.discount == '0.00' <text class="price" :style="{ color: value.moneyColor }">{{ (item.discount == '0.00'
? item.money : item.discount) | moneyConduct }}</text> ? item.money : item.discount) | moneyConduct }}</text>
<text class="unit">{{ item.discount == '0.00' ? $lang('coupon.currencyUnit') : $lang('coupon.discountSuffix') }}</text> <text class="unit">{{ item.discount == '0.00' ? '元' : '折' }}</text>
</view>
<text class="text">{{ $lang('coupon.coupon') }}</text>
</view> </view>
<text class="btn" v-if="item.useState == 0" :style="{ <text class="text">优惠券</text>
color: value.btnStyle.textColor, </view>
backgroundColor: value.btnStyle.bgColor, <text class="btn" v-if="item.useState == 0" :style="{
borderTopLeftRadius: value.btnStyle.aroundRadius * 2 + 'rpx', color: value.btnStyle.textColor,
borderBottomLeftRadius: value.btnStyle.aroundRadius * 2 + 'rpx' backgroundColor: value.btnStyle.bgColor,
}"> borderTopLeftRadius: value.btnStyle.aroundRadius * 2 + 'rpx',
<text class="btn-content">{{ value.btnStyle.text }}</text> borderBottomLeftRadius: value.btnStyle.aroundRadius * 2 + 'rpx'
</text> }">
<text class="btn" v-if="parseInt(item.useState)" :style="{ <text class="btn-content">{{ value.btnStyle.text }}</text>
color: value.btnStyle.textColor, </text>
backgroundColor: value.btnStyle.bgColor, <text class="btn" v-if="parseInt(item.useState)" :style="{
borderTopLeftRadius: value.btnStyle.aroundRadius * 2 + 'rpx', color: value.btnStyle.textColor,
borderBottomLeftRadius: value.btnStyle.aroundRadius * 2 + 'rpx' backgroundColor: value.btnStyle.bgColor,
}"> borderTopLeftRadius: value.btnStyle.aroundRadius * 2 + 'rpx',
<text class="btn-content">{{ $lang('coupon.goUse') }}</text> borderBottomLeftRadius: value.btnStyle.aroundRadius * 2 + 'rpx'
</text> }">
<text class="limit" :style="{ color: value.limitColor }" <text class="btn-content">去使用</text>
v-if="parseFloat(item.at_least) > 0">{{ $lang('coupon.thresholdUse', { amount: item.at_least | moneyConduct }) }}</text> </text>
<text class="limit" :style="{ color: value.limitColor }" v-else>{{ $lang('coupon.noThresholdUse') }}</text> <text class="limit" :style="{ color: value.limitColor }"
v-if="parseFloat(item.at_least) > 0">满{{ item.at_least | moneyConduct }}元使用</text>
<text class="limit" :style="{ color: value.limitColor }" v-else>无门槛使用</text>
</view> </view>
<div v-if="computedCouponList.length <= 2" @tap.stop="$util.redirectTo('/pages_goods/category')" <div v-if="computedCouponList.length <= 2" @tap.stop="$util.redirectTo('/pages_goods/category')"
@@ -237,9 +238,9 @@
}"> }">
<div class="coupon-content" :style="{ color: value.moneyColor }"> <div class="coupon-content" :style="{ color: value.moneyColor }">
<span class="price">+</span> <span class="price">+</span>
<span class="text">{{ $lang('coupon.noCoupon') }}</span> <span class="text">暂无优惠券</span>
</div> </div>
<span class="limit" :style="{ color: value.limitColor }">{{ $lang('coupon.goBrowse') }}</span> <span class="limit" :style="{ color: value.limitColor }">去逛逛</span>
</div> </div>
</swiper-item> </swiper-item>
</swiper> </swiper>
@@ -256,25 +257,25 @@
<view class="coupon-num" v-if="item.discount == '0.00'" <view class="coupon-num" v-if="item.discount == '0.00'"
:style="{ color: value.moneyColor }"> :style="{ color: value.moneyColor }">
<text class="coupon-size">{{ item.money | moneyConduct }}</text> <text class="coupon-size">{{ item.money | moneyConduct }}</text>
<text class="font-size-tag coupon-sign">{{ $lang('coupon.currencyUnit') }}</text> <text class="font-size-tag coupon-sign">元</text>
</view> </view>
<view class="coupon-num" v-else :style="{ color: value.moneyColor }"> <view class="coupon-num" v-else :style="{ color: value.moneyColor }">
<text class="coupon-size">{{ item.discount | moneyConduct }}</text> <text class="coupon-size">{{ item.discount | moneyConduct }}</text>
<text class="font-size-tag coupon-sign">{{ $lang('coupon.discountSuffix') }}</text> <text class="font-size-tag coupon-sign">折</text>
</view> </view>
</view> </view>
<view class="coupon-type"> <view class="coupon-type">
<text class="coupon-name" :style="{ color: value.limitColor }" <text class="coupon-name" :style="{ color: value.limitColor }"
v-if="item.at_least > 0">{{ $lang('coupon.thresholdAvailable', { amount: Number(item.at_least) }) }}</text> v-if="item.at_least > 0">满{{ Number(item.at_least) }}元可用</text>
<text class="coupon-name" :style="{ color: value.limitColor }" v-else>{{ $lang('coupon.noThreshold') }}</text> <text class="coupon-name" :style="{ color: value.limitColor }" v-else>无门槛优惠券</text>
<view class="coupon-least" :style="{ color: value.limitColor }">有效期至{{ <view class="coupon-least" :style="{ color: value.limitColor }">有效期至{{
$util.timeStampTurnTime(item.end_time, 'yearmonthday') }}</view> $util.timeStampTurnTime(item.end_time, 'yearmonthday') }}</view>
</view> </view>
<view class="coupon-line"></view> <view class="coupon-line"></view>
<view class="coupon-get" :style="couponBtnStyle" v-if="item.useState == 0"> <view class="coupon-get" :style="couponBtnStyle" v-if="item.useState == 0">
{{ value.btnStyle.text || $lang('coupon.claimNow') }} {{ value.btnStyle.text || '立即领取' }}
</view> </view>
<view class="coupon-get" :style="couponBtnStyle" v-if="parseInt(item.useState)">{{ $lang('coupon.goUse') }} <view class="coupon-get" :style="couponBtnStyle" v-if="parseInt(item.useState)">去使用
</view> </view>
</view> </view>
</view> </view>
@@ -403,7 +404,7 @@ export default {
couponTap(item, index) { couponTap(item, index) {
if (item.count == item.lead_count) { if (item.count == item.lead_count) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('coupon.couponTaken') title: '该优惠券已抢光'
}); });
return; return;
} }
@@ -426,7 +427,7 @@ export default {
var data = res.data; var data = res.data;
let msg = res.message; let msg = res.message;
if (res.code == 0) { if (res.code == 0) {
msg = this.$lang('coupon.receiveSuccess'); msg = '领取成功';
if (res.data.is_exist == 1) { if (res.data.is_exist == 1) {
for (let i = 0; i < that.couponList.length; i++) { for (let i = 0; i < that.couponList.length; i++) {
if (that.couponList[i].coupon_type_id == item.coupon_type_id) { if (that.couponList[i].coupon_type_id == item.coupon_type_id) {

View File

@@ -138,7 +138,7 @@ export default {
}, },
success: res => { success: res => {
if (res.code >= 0) { if (res.code >= 0) {
this.$util.showToast({ title: this.$lang('fenxiao.followSuccess') }); this.$util.showToast({ title: '关注成功' });
this.list[index].is_collect = 1; this.list[index].is_collect = 1;
this.list[index].collect_id = res.data; this.list[index].collect_id = res.data;
} }
@@ -149,8 +149,8 @@ export default {
//取消关注 //取消关注
delFollowTip(e, index) { delFollowTip(e, index) {
uni.showModal({ uni.showModal({
title: this.$lang('common.tip'), title: '提示',
content: this.$lang('fenxiao.confirmUnfollow'), content: '确认取消关注该商品吗',
success: res => { success: res => {
if (res.confirm) { if (res.confirm) {
this.delFollow(e.collect_id, index); this.delFollow(e.collect_id, index);
@@ -167,7 +167,7 @@ export default {
success: res => { success: res => {
let msg = ''; let msg = '';
if (res.code == 0) { if (res.code == 0) {
msg = this.$lang('fenxiao.unfollowSuccess'); msg = '取消成功';
} else { } else {
msg = res.message; msg = res.message;
} }

View File

@@ -139,7 +139,7 @@ export default {
// 提交按钮文字:与后端 design.html <button>提交</button> 默认对齐,开放给 formConfig 覆盖 // 提交按钮文字:与后端 design.html <button>提交</button> 默认对齐,开放给 formConfig 覆盖
// 走 mergedFormConfig(兼容 camelCase / snake_case),让 formConfig.submitText 能正确覆盖 // 走 mergedFormConfig(兼容 camelCase / snake_case),让 formConfig.submitText 能正确覆盖
submitText() { submitText() {
return this.mergedFormConfig.submitText || this.$lang('form.submit'); return this.mergedFormConfig.submitText || '提交';
}, },
// 后端把表单样式配置统一存放在 data.formConfig 子对象中(与后端 design.js getDefaultFormData().formConfig 字段名一致)。 // 后端把表单样式配置统一存放在 data.formConfig 子对象中(与后端 design.js getDefaultFormData().formConfig 字段名一致)。
// 这里做一次归一化:优先取 formConfig;如果历史数据是扁平结构(直接挂在 value 上),也做兼容。 // 这里做一次归一化:优先取 formConfig;如果历史数据是扁平结构(直接挂在 value 上),也做兼容。
@@ -298,12 +298,12 @@ export default {
form_id: this.value.form_id || 0, form_id: this.value.form_id || 0,
form_data: JSON.stringify(submitData), form_data: JSON.stringify(submitData),
component_id: this.value.id || '', component_id: this.value.id || '',
form_name: this.value.form_name || this.$lang('form.defaultForm') form_name: this.value.form_name || '默认表单'
}, },
success: function(res) { success: function(res) {
if (res.code === 0) { if (res.code === 0) {
uni.showToast({ uni.showToast({
title: self.$lang('form.submitSuccess'), title: '提交成功',
icon: 'success' icon: 'success'
}); });
// 重置表单 // 重置表单
@@ -312,7 +312,7 @@ export default {
} }
} else { } else {
uni.showToast({ uni.showToast({
title: res.message || self.$lang('form.submitFailed'), title: res.message || '提交失败',
icon: 'none' icon: 'none'
}); });
} }

View File

@@ -60,7 +60,7 @@
</view> </view>
<view class="sale" v-if="goodsValue.saleStyle.control" <view class="sale" v-if="goodsValue.saleStyle.control"
:style="{ color: goodsValue.theme == 'diy' ? goodsValue.saleStyle.color : '' }"> :style="{ color: goodsValue.theme == 'diy' ? goodsValue.saleStyle.color : '' }">
已售{{ item.sale_num }}{{ item.unit ? item.unit : $lang('goods.piece') }} 已售{{ item.sale_num }}{{ item.unit ? item.unit : '件' }}
</view> </view>
</view> </view>
@@ -168,7 +168,7 @@
</view> </view>
<view class="sale" v-if="goodsValue.saleStyle.control" <view class="sale" v-if="goodsValue.saleStyle.control"
:style="{ color: goodsValue.theme == 'diy' ? goodsValue.saleStyle.color : '' }"> :style="{ color: goodsValue.theme == 'diy' ? goodsValue.saleStyle.color : '' }">
已售{{ item.sale_num }}{{ item.unit ? item.unit : $lang('goods.piece') }} 已售{{ item.sale_num }}{{ item.unit ? item.unit : '件' }}
</view> </view>
</view> </view>
</view> </view>
@@ -238,7 +238,7 @@
</view> </view>
<view class="sale" v-if="goodsValue.saleStyle.control" <view class="sale" v-if="goodsValue.saleStyle.control"
:style="{ color: goodsValue.theme == 'diy' ? goodsValue.saleStyle.color : '' }"> :style="{ color: goodsValue.theme == 'diy' ? goodsValue.saleStyle.color : '' }">
已售{{ dataItem.sale_num }}{{ dataItem.unit ? dataItem.unit : $lang('goods.piece') }} 已售{{ dataItem.sale_num }}{{ dataItem.unit ? dataItem.unit : '件' }}
</view> </view>
</view> </view>
</view> </view>

View File

@@ -53,7 +53,7 @@
¥{{ showMarketPrice(dataItem) }}</view> ¥{{ showMarketPrice(dataItem) }}</view>
<view class="sale" v-if="goodsValue.saleStyle.control" <view class="sale" v-if="goodsValue.saleStyle.control"
:style="{ color: goodsValue.theme == 'diy' ? goodsValue.saleStyle.color : '' }"> :style="{ color: goodsValue.theme == 'diy' ? goodsValue.saleStyle.color : '' }">
售{{ dataItem.sale_num }}{{ dataItem.unit ? dataItem.unit : $lang('goods.piece') }} 售{{ dataItem.sale_num }}{{ dataItem.unit ? dataItem.unit : '件' }}
</view> </view>
</view> </view>
</view> </view>

View File

@@ -147,13 +147,13 @@
<text>{{ showMarketPrice(item) }}</text> <text>{{ showMarketPrice(item) }}</text>
</view> </view>
<view class="sale font-size-activity-tag color-tip">已售{{ <view class="sale font-size-activity-tag color-tip">已售{{
item.sale_num }}{{ item.unit ? item.unit : $lang('goods.piece') }}</view> item.sale_num }}{{ item.unit ? item.unit : '件' }}</view>
</view> </view>
</view> </view>
</view> </view>
</view> </view>
<view v-if="!isloading && goodsList[pageIndex].list.length == 0"> <view v-if="!isloading && goodsList[pageIndex].list.length == 0">
<ns-empty :text="$lang('category.noGoodsInCategory')" :isIndex="false"></ns-empty> <ns-empty text="该分类下暂无商品" :isIndex="false"></ns-empty>
</view> </view>
</block> </block>
</mescroll-uni> </mescroll-uni>
@@ -193,7 +193,7 @@ export default {
pageIndex: 0, //当前选中分类id pageIndex: 0, //当前选中分类id
cateList: [{ cateList: [{
//header分类 //header分类
category_name: this.$lang('common.home') category_name: '首页'
}], }],
twoCategorylist: [], //二级分类 twoCategorylist: [], //二级分类
twoCategorylistId: 0, //二级分类所在的swiper twoCategorylistId: 0, //二级分类所在的swiper
@@ -323,7 +323,7 @@ export default {
let obj = { let obj = {
list: [] list: []
}; };
obj.category_name = this.value.title ? this.value.title : this.$lang('common.home'); obj.category_name = this.value.title ? this.value.title : '首页';
arr.push(obj); arr.push(obj);
this.cateList = arr.concat(res.data); this.cateList = arr.concat(res.data);
Object.keys(this.cateList).forEach((key, index) => { Object.keys(this.cateList).forEach((key, index) => {

View File

@@ -14,7 +14,7 @@
</view> </view>
<view class="fui-remark jump" style="padding-right: 20rpx; text-align: center; line-height: 140rpx;"> <view class="fui-remark jump" style="padding-right: 20rpx; text-align: center; line-height: 140rpx;">
<span style="font-size:24rpx;padding: 14rpx 18rpx;border-radius:8rpx" <span style="font-size:24rpx;padding: 14rpx 18rpx;border-radius:8rpx"
:style="{ background: item.BtBgColor, color: item.BtColor }" @tap.stop="previewSqs()">{{ $lang('form.addNow') }}</span> :style="{ background: item.BtBgColor, color: item.BtColor }" @tap.stop="previewSqs()">立即添加</span>
</view> </view>
</view> </view>
</view> </view>

View File

@@ -12,7 +12,7 @@
style="border-radius:6rpx;width: 60rpx;"></image> style="border-radius:6rpx;width: 60rpx;"></image>
</view> </view>
<view class="fui-cell-text" style="color:#333;">{{ item.title }}</view> <view class="fui-cell-text" style="color:#333;">{{ item.title }}</view>
<view class="fui-cell-remark" style="font-size: 24rpx;">{{ lang == 'en-us' ? 'view' : $lang('common.view') }}</view> <view class="fui-cell-remark" style="font-size: 24rpx;">{{ lang == 'en-us' ? 'view' : '查看' }}</view>
</view> </view>
</view> </view>
</view> </view>

View File

@@ -71,7 +71,7 @@ export default {
uni.openLocation({ uni.openLocation({
latitude: parseFloat(item.lat), latitude: parseFloat(item.lat),
longitude: parseFloat(item.lng), longitude: parseFloat(item.lng),
name: this.$lang('map.oneClickNav'), name: "一键导航",
}) })
}, },
async handlerClick(item) { async handlerClick(item) {

View File

@@ -12,7 +12,7 @@
<!-- #ifdef MP --> <!-- #ifdef MP -->
<block <block
v-if="(memberInfo.nickname.indexOf('u_') != -1 && memberInfo.nickname == memberInfo.username) || memberInfo.nickname == memberInfo.mobile"> v-if="(memberInfo.nickname.indexOf('u_') != -1 && memberInfo.nickname == memberInfo.username) || memberInfo.nickname == memberInfo.mobile">
<view class="nickname"><text class="name" @tap.stop="getWxAuth">{{ $lang('member.authAvatarNickname') }}</text></view> <view class="nickname"><text class="name" @tap.stop="getWxAuth">点击授权头像昵称</text></view>
</block> </block>
<view class="nickname" v-else> <view class="nickname" v-else>
<text class="name" @tap.stop="getWxAuth">{{ memberInfo.nickname }}</text> <text class="name" @tap.stop="getWxAuth">{{ memberInfo.nickname }}</text>
@@ -36,7 +36,7 @@
<!-- #ifdef H5 --> <!-- #ifdef H5 -->
<block <block
v-if="$util.isWeiXin() && ((memberInfo.nickname.indexOf('u_') != -1 && memberInfo.nickname == memberInfo.username) || memberInfo.nickname == memberInfo.mobile)"> v-if="$util.isWeiXin() && ((memberInfo.nickname.indexOf('u_') != -1 && memberInfo.nickname == memberInfo.username) || memberInfo.nickname == memberInfo.mobile)">
<view class="nickname"><text class="name" @tap.stop="getWxAuth">{{ $lang('member.getWechatAvatar') }}</text></view> <view class="nickname"><text class="name" @tap.stop="getWxAuth">点击获取微信头像</text></view>
</block> </block>
<view class="nickname" v-else> <view class="nickname" v-else>
<text class="name" @tap.stop="redirect('/pages_tool/member/info')">{{ memberInfo.nickname <text class="name" @tap.stop="redirect('/pages_tool/member/info')">{{ memberInfo.nickname
@@ -107,22 +107,22 @@
<block v-if="value.style == 1 || value.style == 2"> <block v-if="value.style == 1 || value.style == 2">
<view class="super-info"> <view class="super-info">
<text class="icondiy icon-system-huangguan"></text> <text class="icondiy icon-system-huangguan"></text>
<text>{{ $lang('memberInfo.superMember') }}</text> <text>超级会员</text>
</view> </view>
<view class="super-text"> <view class="super-text">
<text class="see" v-if="memberInfo && memberInfo.member_level_type" @tap.stop="redirectBeforeAuth('/pages_tool/member/card')">{{ $lang('memberInfo.viewPrivilege') }}</text> <text class="see" v-if="memberInfo && memberInfo.member_level_type" @tap.stop="redirectBeforeAuth('/pages_tool/member/card')">查看特权</text>
<text class="see" v-else @tap.stop="redirectBeforeAuth('/pages_tool/member/card_buy')">{{ $lang('memberInfo.memberMoreBenefit') }}</text> <text class="see" v-else @tap.stop="redirectBeforeAuth('/pages_tool/member/card_buy')">会员可享更多权益</text>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
</view> </view>
</block> </block>
<block v-if="value.style == 3"> <block v-if="value.style == 3">
<view class="super-info"> <view class="super-info">
<image :src="$util.img('public/uniapp/member/open_member.png')" class="title" mode="heightFix" show-menu-by-longpress/> <image :src="$util.img('public/uniapp/member/open_member.png')" class="title" mode="heightFix" show-menu-by-longpress/>
<view class="desc">{{ $lang('memberInfo.openMoreBenefit') }}</view> <view class="desc">开通可享更多权益</view>
</view> </view>
<view class="super-text"> <view class="super-text">
<text class="see" v-if="memberInfo && memberInfo.member_level_type" @tap.stop="redirectBeforeAuth('/pages_tool/member/card')">{{ $lang('memberInfo.viewPrivilege') }}</text> <text class="see" v-if="memberInfo && memberInfo.member_level_type" @tap.stop="redirectBeforeAuth('/pages_tool/member/card')">查看特权</text>
<text class="see" v-else @tap.stop="redirectBeforeAuth('/pages_tool/member/card_buy')">{{ $lang('memberInfo.openNow') }}</text> <text class="see" v-else @tap.stop="redirectBeforeAuth('/pages_tool/member/card_buy')">立即开通</text>
</view> </view>
</block> </block>
</view> </view>
@@ -131,11 +131,11 @@
<view class="super-member" v-if="superMember" :style="superMemberStyle"> <view class="super-member" v-if="superMember" :style="superMemberStyle">
<view class="super-info"> <view class="super-info">
<image :src="$util.img('app/component/view/member_info/img/style_4_vip_huangguan.png')" class="title" mode="widthFix" show-menu-by-longpress/> <image :src="$util.img('app/component/view/member_info/img/style_4_vip_huangguan.png')" class="title" mode="widthFix" show-menu-by-longpress/>
<view class="desc">{{ $lang('memberInfo.openMoreBenefit') }}</view> <view class="desc">开通可享更多权益</view>
</view> </view>
<view class="super-text" :class="{ 'more' : memberInfo && memberInfo.member_level_type }"> <view class="super-text" :class="{ 'more' : memberInfo && memberInfo.member_level_type }">
<text class="see" v-if="memberInfo && memberInfo.member_level_type" @tap.stop="redirectBeforeAuth('/pages_tool/member/card')">{{ $lang('memberInfo.viewMoreBenefit') }}</text> <text class="see" v-if="memberInfo && memberInfo.member_level_type" @tap.stop="redirectBeforeAuth('/pages_tool/member/card')">查看更多权益</text>
<text class="see" v-else @tap.stop="redirectBeforeAuth('/pages_tool/member/card_buy')">{{ $lang('memberInfo.openNow') }}</text> <text class="see" v-else @tap.stop="redirectBeforeAuth('/pages_tool/member/card_buy')">立即开通</text>
</view> </view>
</view> </view>
<view class="account-info" :style="{ 'margin-left': parseInt(value.infoMargin) * 2 + 'rpx', 'margin-right': parseInt(value.infoMargin) * 2 + 'rpx' }"> <view class="account-info" :style="{ 'margin-left': parseInt(value.infoMargin) * 2 + 'rpx', 'margin-right': parseInt(value.infoMargin) * 2 + 'rpx' }">
@@ -143,25 +143,25 @@
<view class="value price-font"> <view class="value price-font">
{{ memberInfo ? (parseFloat(memberInfo.balance) + parseFloat(memberInfo.balance_money)).toFixed(2) : '--' }} {{ memberInfo ? (parseFloat(memberInfo.balance) + parseFloat(memberInfo.balance_money)).toFixed(2) : '--' }}
</view> </view>
<view class="title">{{ $lang('memberInfo.balance') }}</view> <view class="title">余额</view>
</view> </view>
<view class="solid"></view> <view class="solid"></view>
<view class="account-item" @tap.stop="redirect('/pages_tool/member/point_detail')"> <view class="account-item" @tap.stop="redirect('/pages_tool/member/point_detail')">
<view class="value price-font">{{ memberInfo ? parseFloat(memberInfo.point) : '--' }} <view class="value price-font">{{ memberInfo ? parseFloat(memberInfo.point) : '--' }}
</view> </view>
<view class="title">{{ $lang('invite.point') }}</view> <view class="title">积分</view>
</view> </view>
<view class="solid"></view> <view class="solid"></view>
<view class="account-item" @tap.stop="redirect('/pages_tool/member/coupon')"> <view class="account-item" @tap.stop="redirect('/pages_tool/member/coupon')">
<view class="value price-font"> <view class="value price-font">
{{ memberInfo && memberInfo.coupon_num != undefined ? memberInfo.coupon_num : '--' }} {{ memberInfo && memberInfo.coupon_num != undefined ? memberInfo.coupon_num : '--' }}
</view> </view>
<view class="title">{{ $lang('member.coupon') }}</view> <view class="title">优惠券</view>
</view> </view>
</view> </view>
<view class="style4-other"> <view class="style4-other">
<view class="style4-btn-wrap"> <view class="style4-btn-wrap">
<view @tap.stop="redirect('/pages_tool/recharge/list')" class="recharge-btn">{{ $lang('memberInfo.recharge') }}</view> <view @tap.stop="redirect('/pages_tool/recharge/list')" class="recharge-btn">余额充值</view>
</view> </view>
</view> </view>
</view> --> </view> -->
@@ -194,13 +194,13 @@
<uni-popup ref="completeInfoPopup" type="bottom" :maskClick="false"> <uni-popup ref="completeInfoPopup" type="bottom" :maskClick="false">
<view class="complete-info-wrap"> <view class="complete-info-wrap">
<view class="head"> <view class="head">
<text class="title">{{ $lang('memberInfo.getNicknameAvatar') }}</text> <text class="title">获取您的昵称、头像</text>
<text class="color-tip tips">{{ $lang('memberInfo.getAvatarTip') }}</text> <text class="color-tip tips">获取用户头像、昵称完善个人资料,主要用于向用户提供具有辨识度的用户中心界面</text>
<text class="iconfont icon-close color-tip" @tap.stop="cancelCompleteInfo"></text> <text class="iconfont icon-close color-tip" @tap.stop="cancelCompleteInfo"></text>
</view> </view>
<!-- #ifdef MP-WEIXIN --> <!-- #ifdef MP-WEIXIN -->
<view class="item-wrap"> <view class="item-wrap">
<text class="label">{{ $lang('memberInfo.avatar') }}</text> <text class="label">头像</text>
<button open-type="chooseAvatar" @chooseavatar="onChooseAvatar"> <button open-type="chooseAvatar" @chooseavatar="onChooseAvatar">
<image :src="avatarUrl ? avatarUrl : $util.getDefaultImage().head" <image :src="avatarUrl ? avatarUrl : $util.getDefaultImage().head"
@error="avatarUrl = $util.getDefaultImage().head" mode="aspectFill" show-menu-by-longpress/> @error="avatarUrl = $util.getDefaultImage().head" mode="aspectFill" show-menu-by-longpress/>
@@ -208,13 +208,13 @@
</button> </button>
</view> </view>
<view class="item-wrap"> <view class="item-wrap">
<text class="label">{{ $lang('memberInfo.nickname') }}</text> <text class="label">昵称</text>
<input type="nickname" :placeholder="$lang('form.inputNickname')" v-model="nickName" @blur="blurNickName" /> <input type="nickname" placeholder="请输入昵称" v-model="nickName" @blur="blurNickName" />
</view> </view>
<!-- #endif --> <!-- #endif -->
<!-- #ifdef MP-ALIPAY --> <!-- #ifdef MP-ALIPAY -->
<view class="item-wrap"> <view class="item-wrap">
<text class="label">{{ $lang('memberInfo.avatar') }}</text> <text class="label">头像</text>
<button open-type="getAuthorize" scope="userInfo" @getAuthorize="aliappGetUserinfo" <button open-type="getAuthorize" scope="userInfo" @getAuthorize="aliappGetUserinfo"
:plain="true" class="border-0"> :plain="true" class="border-0">
<image :src="avatarUrl ? avatarUrl : $util.getDefaultImage().head" <image :src="avatarUrl ? avatarUrl : $util.getDefaultImage().head"
@@ -223,11 +223,11 @@
</button> </button>
</view> </view>
<view class="item-wrap"> <view class="item-wrap">
<text class="label">{{ $lang('memberInfo.nickname') }}</text> <text class="label">昵称</text>
<input type="nickname" :placeholder="$lang('form.inputNickname')" v-model="nickName" @blur="blurNickName" /> <input type="nickname" placeholder="请输入昵称" v-model="nickName" @blur="blurNickName" />
</view> </view>
<!-- #endif --> <!-- #endif -->
<button type="default" class="save-btn" @tap.stop="saveCompleteInfo" :disabled="isDisabled">{{ $lang('form.save') }}</button> <button type="default" class="save-btn" @tap.stop="saveCompleteInfo" :disabled="isDisabled">保存</button>
</view> </view>
</uni-popup> </uni-popup>
</view> </view>
@@ -493,8 +493,8 @@ export default {
showMemberQrcode() { showMemberQrcode() {
if (!this.memberInfo.mobile && !this.memberInfo.member_code) { if (!this.memberInfo.mobile && !this.memberInfo.member_code) {
uni.showModal({ uni.showModal({
title: this.$lang('common.tip'), title: '提示',
content: this.$lang('member.bindMobileFirst'), content: '使用会员码需先绑定手机号,是否绑定手机号?',
success: res => { success: res => {
if (res.confirm) { if (res.confirm) {
// #ifdef MP-WEIXIN // #ifdef MP-WEIXIN
@@ -643,7 +643,7 @@ export default {
saveCompleteInfo() { saveCompleteInfo() {
if (this.nickName.length == 0) { if (this.nickName.length == 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('member.inputNickname') title: '请输入昵称'
}); });
return; return;
} }
@@ -682,7 +682,7 @@ export default {
}, },
fail: () => { fail: () => {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('member.uploadFailed') title: '上传失败'
}); });
} }
}) })
@@ -713,7 +713,7 @@ export default {
}, },
fail: () => { fail: () => {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('member.avatarFetchFailed') title: '头像拉取失败'
}); });
} }
}) })

View File

@@ -17,8 +17,8 @@
:key="labelIndex">{{ labelItem }}</text> :key="labelIndex">{{ labelItem }}</text>
</view> </view>
<view class="notes-intro"> <view class="notes-intro">
<text class="notes-label color-base-text">#{{ item.note_type == 'goods_item' ? $lang('note.goodsIntro') : <text class="notes-label color-base-text">#{{ item.note_type == 'goods_item' ? '单品介绍' :
$lang('note.shopkeeperNote') }}#</text> '掌柜说' }}#</text>
{{ item.note_abstract }} {{ item.note_abstract }}
</view> </view>
</view> </view>

View File

@@ -42,11 +42,11 @@
<uni-popup ref="noticePopup" type="center"> <uni-popup ref="noticePopup" type="center">
<view class="notice-popup"> <view class="notice-popup">
<view class="head-wrap" @tap.stop="closeNoticePopup"> <view class="head-wrap" @tap.stop="closeNoticePopup">
<text>{{ $lang('notice.title') }}</text> <text>公告</text>
<text class="iconfont icon-close"></text> <text class="iconfont icon-close"></text>
</view> </view>
<view class="content-wrap">{{ notice }}</view> <view class="content-wrap">{{ notice }}</view>
<button type="primary" @tap.stop="closeNoticePopup">{{ $lang('notice.iknow') }}</button> <button type="primary" @tap.stop="closeNoticePopup">我知道了</button>
</view> </view>
</uni-popup> </uni-popup>
</view> </view>

View File

@@ -21,11 +21,11 @@
:style="{ color: value.theme == 'diy' ? value.groupStyle.bgColor : '', borderColor: value.theme == 'diy' ? value.groupStyle.bgColor : '' }"> :style="{ color: value.theme == 'diy' ? value.groupStyle.bgColor : '', borderColor: value.theme == 'diy' ? value.groupStyle.bgColor : '' }">
<text class="iconfont icon-yonghu3" <text class="iconfont icon-yonghu3"
:style="{ backgroundColor: value.theme == 'diy' ? value.groupStyle.bgColor : '' }"></text> :style="{ backgroundColor: value.theme == 'diy' ? value.groupStyle.bgColor : '' }"></text>
<text>{{ item.pintuan_num }}{{ $lang('pinfan.group') }}</text> <text>{{ item.pintuan_num }}人团</text>
</view> </view>
<view v-if="value.saleStyle.control" <view v-if="value.saleStyle.control"
:style="{ color: value.theme == 'diy' ? value.saleStyle.color : '', borderColor: value.theme == 'diy' ? value.saleStyle.color : '' }"> :style="{ color: value.theme == 'diy' ? value.saleStyle.color : '', borderColor: value.theme == 'diy' ? value.saleStyle.color : '' }">
<text>{{ $lang('pinfan.soldCount', { count: item.order_num }) }}</text> <text>已拼{{ item.order_num }}件</text>
</view> </view>
</view> </view>
<view class="price-wrap"> <view class="price-wrap">
@@ -49,9 +49,10 @@
borderRadius: value.btnStyle.aroundRadius * 2 + 'rpx' borderRadius: value.btnStyle.aroundRadius * 2 + 'rpx'
}"> }">
<text class="text">{{ value.btnStyle.text }}</text> <text class="text">{{ value.btnStyle.text }}</text>
<text class="fan" v-if="item.reward_type == 4">{{ $lang('pinfan.rewardPoint', { count: item.reward_type_num }) }}</text> <text class="fan" v-if="item.reward_type == 4">返{{ item.reward_type_num }}积分</text>
<text class="fan" v-if="item.reward_type == 1 || item.reward_type == 2">{{ $lang('pinfan.rewardCash', { amount: item.reward_type_num }) }}</text> <text class="fan" v-if="item.reward_type == 1 || item.reward_type == 2">返¥{{
<text class="fan" v-if="item.reward_type == 3">{{ $lang('pinfan.rewardCoupon') }}</text> item.reward_type_num }}</text>
<text class="fan" v-if="item.reward_type == 3">返优惠券</text>
</button> </button>
</view> </view>
</view> </view>
@@ -82,16 +83,16 @@
<text class="content-tuan-price" <text class="content-tuan-price"
:style="{ color: value.theme == 'diy' ? value.groupStyle.bgColor : '' }" :style="{ color: value.theme == 'diy' ? value.groupStyle.bgColor : '' }"
v-if="item.reward_type == 4"> v-if="item.reward_type == 4">
{{ $lang('pinfan.rewardPoint', { count: item.reward_type_num }) }} 返{{ item.reward_type_num }}积分
</text> </text>
<text class="content-tuan-price" <text class="content-tuan-price"
:style="{ color: value.theme == 'diy' ? value.groupStyle.bgColor : '' }" :style="{ color: value.theme == 'diy' ? value.groupStyle.bgColor : '' }"
v-if="item.reward_type == 1 || item.reward_type == 2"> v-if="item.reward_type == 1 || item.reward_type == 2">
{{ $lang('pinfan.rewardCash', { amount: item.reward_type_num }) }} 返¥{{ item.reward_type_num }}
</text> </text>
<text class="content-tuan-price" <text class="content-tuan-price"
:style="{ color: value.theme == 'diy' ? value.groupStyle.bgColor : '' }" :style="{ color: value.theme == 'diy' ? value.groupStyle.bgColor : '' }"
v-if="item.reward_type == 3">{{ $lang('pinfan.rewardCoupon') }}</text> v-if="item.reward_type == 3">返优惠券</text>
</view> </view>
<view class="price-wrap" v-if="value.priceStyle.mainControl"> <view class="price-wrap" v-if="value.priceStyle.mainControl">
<text class="unit price-style small" <text class="unit price-style small"

View File

@@ -26,7 +26,7 @@
</view> </view>
<view :style="{ color: value.titleStyle.textColor }"> <view :style="{ color: value.titleStyle.textColor }">
<text>{{ value.titleStyle.virtualNum || headData.pintuan_count }}</text> <text>{{ value.titleStyle.virtualNum || headData.pintuan_count }}</text>
<text>{{ value.titleStyle.style == 'style-2' ? $lang('pintuan.participate') : $lang('pintuan.groupSuccess') }}</text> <text>{{ value.titleStyle.style == 'style-2' ? '人参与' : '人拼团成功' }}</text>
</view> </view>
</view> </view>
<view class="head-right" <view class="head-right"
@@ -59,11 +59,11 @@
}"> }">
<text class="iconfont icon-yonghu3" <text class="iconfont icon-yonghu3"
:style="{ backgroundColor: value.theme == 'diy' ? value.groupStyle.bgColorStart : '' }"></text> :style="{ backgroundColor: value.theme == 'diy' ? value.groupStyle.bgColorStart : '' }"></text>
<text>{{ item.pintuan_num }}{{ $lang('pintuan.group') }}</text> <text>{{ item.pintuan_num }}人团</text>
</view> </view>
<view v-if="value.saleStyle.control" <view v-if="value.saleStyle.control"
:style="{ color: value.theme == 'diy' ? value.saleStyle.color : '', borderColor: value.theme == 'diy' ? value.saleStyle.color : '' }"> :style="{ color: value.theme == 'diy' ? value.saleStyle.color : '', borderColor: value.theme == 'diy' ? value.saleStyle.color : '' }">
<text>{{ $lang('pintuan.soldCount', { count: item.order_num }) }}</text> <text>已拼{{ item.order_num }}件</text>
</view> </view>
</view> </view>
@@ -148,10 +148,10 @@
{{ '.' + item.pintuan_price.split('.')[1] }} {{ '.' + item.pintuan_price.split('.')[1] }}
</text> </text>
</view> </view>
<view class="sale-action">{{ $lang('pintuan.joinGroup') }}</view> <view class="sale-action">去参团</view>
</view> </view>
<view class="sale-num" v-if="value.style == 'style-2'">{{ $lang('pintuan.soldCount', { count: item.sale_num }) }}</view> <view class="sale-num" v-if="value.style == 'style-2'">已拼{{ item.sale_num }}件</view>
</view> </view>
</view> </view>
</scroll-view> </scroll-view>
@@ -170,7 +170,7 @@
color: value.theme == 'diy' ? value.groupStyle.color : '', color: value.theme == 'diy' ? value.groupStyle.color : '',
background: value.theme == 'diy' ? 'linear-gradient(to right,' + value.groupStyle.bgColorStart + ',' + value.groupStyle.bgColorEnd + ')' : '' background: value.theme == 'diy' ? 'linear-gradient(to right,' + value.groupStyle.bgColorStart + ',' + value.groupStyle.bgColorEnd + ')' : ''
}"> }">
{{ item.pintuan_num }}{{ $lang('pintuan.group') }} {{ item.pintuan_num }}人团
</view> </view>
</view> </view>
<view :class="['content', { 'multi-content': value.nameLineMode == 'multiple' }]" <view :class="['content', { 'multi-content': value.nameLineMode == 'multiple' }]"
@@ -192,7 +192,7 @@
{{ '.' + item.pintuan_price.split('.')[1] }} {{ '.' + item.pintuan_price.split('.')[1] }}
</text> </text>
</view> </view>
<view class="sale-num" v-if="value.style == 'style-2'">{{ $lang('pintuan.soldCount', { count: item.sale_num }) }}</view> <view class="sale-num" v-if="value.style == 'style-2'">已拼{{ item.sale_num }}件</view>
</view> </view>
</view> </view>
</swiper-item> </swiper-item>

View File

@@ -28,7 +28,7 @@
@tap.stop="handlerSearchClick" @tap.stop="handlerSearchClick"
:placeholderStyle="placeholderStyle" /> :placeholderStyle="placeholderStyle" />
<text class="search-content-btn" @tap.stop="handlerSearchClick" <text class="search-content-btn" @tap.stop="handlerSearchClick"
:style="{ 'backgroundColor': value.pageBgColor ? value.pageBgColor : 'rgba(0,0,0,0)' }">{{ $lang('form.search') }}</text> :style="{ 'backgroundColor': value.pageBgColor ? value.pageBgColor : 'rgba(0,0,0,0)' }">搜索</text>
</view> </view>
<view class="img" v-if="value.iconType == 'img'" <view class="img" v-if="value.iconType == 'img'"
@tap.stop="handlerRedirectToClick(value.searchLink)"> @tap.stop="handlerRedirectToClick(value.searchLink)">

View File

@@ -13,10 +13,10 @@
</view> </view>
<image v-else class="title-img" :src="$util.img(value.titleStyle.leftImg)" mode="heightFix" show-menu-by-longpress/> <image v-else class="title-img" :src="$util.img(value.titleStyle.leftImg)" mode="heightFix" show-menu-by-longpress/>
<text v-if="value.titleStyle.style == 'style-2' && isFuture" <text v-if="value.titleStyle.style == 'style-2' && isFuture"
:style="{ color: value.titleStyle.textColor }" class="seckill-style-name">{{ $lang('seckill.timeToStart') }}</text> :style="{ color: value.titleStyle.textColor }" class="seckill-style-name">距离开始</text>
<view class="time" :style="{ background: value.titleStyle.timeBgColor }"> <view class="time" :style="{ background: value.titleStyle.timeBgColor }">
<text :style="{ color: value.titleStyle.textColor }" class="seckill-title-name text">{{ isFuture ? <text :style="{ color: value.titleStyle.textColor }" class="seckill-title-name text">{{ isFuture ?
$lang('seckill.timeToStart') : $lang('seckill.timeToEnd') }}</text> '距离开始' : '距离结束' }}</text>
<text v-if="value.titleStyle.timeImageUrl" <text v-if="value.titleStyle.timeImageUrl"
:class="['seckill-title-name icon', value.titleStyle.timeImageUrl]"></text> :class="['seckill-title-name icon', value.titleStyle.timeImageUrl]"></text>
<text class="hour number" :style="titleTimeStyle">{{ seckillH ? seckillH : '00' }}</text> <text class="hour number" :style="titleTimeStyle">{{ seckillH ? seckillH : '00' }}</text>
@@ -87,7 +87,7 @@
</view> </view>
<view class="price-font" v-else> <view class="price-font" v-else>
<text <text
:style="{ color: value.theme == 'diy' ? value.priceStyle.lineColor : '' }">{{ $lang('seckill.originalPrice') }}</text> :style="{ color: value.theme == 'diy' ? value.priceStyle.lineColor : '' }">原价:</text>
<text :style="{ color: value.theme == 'diy' ? value.priceStyle.lineColor : '' }" <text :style="{ color: value.theme == 'diy' ? value.priceStyle.lineColor : '' }"
class="original-price">¥{{ item.price }}</text> class="original-price">¥{{ item.price }}</text>
</view> </view>
@@ -97,7 +97,7 @@
color: value.btnStyle.theme == 'diy' ? value.btnStyle.textColor : '', color: value.btnStyle.theme == 'diy' ? value.btnStyle.textColor : '',
borderRadius: value.btnStyle.aroundRadius * 2 + 'rpx' borderRadius: value.btnStyle.aroundRadius * 2 + 'rpx'
}"> }">
{{ isFuture ? $lang('seckill.startingSoon') : value.btnStyle.text }} {{ isFuture ? '即将开始' : value.btnStyle.text }}
</button> </button>
</view> </view>
</view> </view>
@@ -140,7 +140,7 @@
color: value.btnStyle.theme == 'diy' ? value.btnStyle.textColor : '', color: value.btnStyle.theme == 'diy' ? value.btnStyle.textColor : '',
borderRadius: value.btnStyle.aroundRadius * 2 + 'rpx' borderRadius: value.btnStyle.aroundRadius * 2 + 'rpx'
}"> }">
{{ isFuture ? $lang('seckill.startingSoon') : value.btnStyle.text }} {{ isFuture ? '即将开始' : value.btnStyle.text }}
</button> </button>
</view> </view>
</view> </view>
@@ -502,7 +502,7 @@ export default {
toDetail(id) { toDetail(id) {
if (this.isFuture) { if (this.isFuture) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('seckill.activityComingSoon') title: '秒杀活动即将开启,敬请期待!'
}); });
return false; return false;
} }

View File

@@ -7,17 +7,17 @@
<block v-if="globalStoreInfo && globalStoreInfo.store_id"> <block v-if="globalStoreInfo && globalStoreInfo.store_id">
<text class="title">{{ globalStoreInfo.store_name }}</text> <text class="title">{{ globalStoreInfo.store_name }}</text>
<text> <text>
<text class="change margin-left">{{ $lang('store.switch') }}</text> <text class="change margin-left">切换</text>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
</text> </text>
</block> </block>
<text class="title" v-else>{{ $lang('store.locating') }}</text> <text class="title" v-else>定位中...</text>
</view> </view>
<view class="address-wrap" :style="{ color: value.textColor }"> <view class="address-wrap" :style="{ color: value.textColor }">
<text class="iconfont icon-dizhi"></text> <text class="iconfont icon-dizhi"></text>
<text v-if="globalStoreInfo && globalStoreInfo.store_id" @tap.stop="mapRoute" class="address">{{ <text v-if="globalStoreInfo && globalStoreInfo.store_id" @tap.stop="mapRoute" class="address">{{
globalStoreInfo.show_address }}</text> globalStoreInfo.show_address }}</text>
<text v-else>{{ $lang('store.getCurrentLocation') }}</text> <text v-else>获取当前位置...</text>
</view> </view>
</view> </view>
<view class="store-image" @tap.stop="selectStore()"> <view class="store-image" @tap.stop="selectStore()">
@@ -40,11 +40,11 @@
<block v-if="globalStoreInfo && globalStoreInfo.store_id"> <block v-if="globalStoreInfo && globalStoreInfo.store_id">
<text class="title">{{ globalStoreInfo.store_name }}</text> <text class="title">{{ globalStoreInfo.store_name }}</text>
<text> <text>
<text class="change margin-left">{{ $lang('store.switch') }}</text> <text class="change margin-left">切换</text>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
</text> </text>
</block> </block>
<text class="title" v-else>{{ $lang('store.locating') }}</text> <text class="title" v-else>定位中...</text>
</view> </view>
</view> </view>
<view class="store-icon" @tap.stop="search()"><text class="iconfont icon-sousuo3" <view class="store-icon" @tap.stop="search()"><text class="iconfont icon-sousuo3"
@@ -60,10 +60,10 @@
<text class="title" :style="{ color: value.textColor }">{{ globalStoreInfo.store_name }}</text> <text class="title" :style="{ color: value.textColor }">{{ globalStoreInfo.store_name }}</text>
<text class="iconfont icon-unfold" :style="{ color: value.textColor }"></text> <text class="iconfont icon-unfold" :style="{ color: value.textColor }"></text>
</block> </block>
<text class="title" v-else>{{ $lang('store.locating') }}</text> <text class="title" v-else>定位中...</text>
</view> </view>
<view class="store-right-search"> <view class="store-right-search">
<input type="text" class="uni-input font-size-tag" disabled :placeholder="$lang('goods.searchGoods')" <input type="text" class="uni-input font-size-tag" disabled placeholder="商品搜索"
@tap.stop="search()" /> @tap.stop="search()" />
<text class="iconfont icon-sousuo3" @tap.stop="search()"></text> <text class="iconfont icon-sousuo3" @tap.stop="search()"></text>
</view> </view>

View File

@@ -208,7 +208,7 @@
{{ value.text }} {{ value.text }}
</text> </text>
<text class="zone" <text class="zone"
:style="{ fontSize: value.fontSize * 2 + 'rpx', fontWeight: value.fontWeight }">{{ $lang('diyText.zone') }}</text> :style="{ fontSize: value.fontSize * 2 + 'rpx', fontWeight: value.fontWeight }">专区</text>
</view> </view>
<text class="iconfont icon-danxuan-xuanzhong" <text class="iconfont icon-danxuan-xuanzhong"
:style="{ color: value.textColor, fontWeight: value.fontWeight }"></text> :style="{ color: value.textColor, fontWeight: value.fontWeight }"></text>

View File

@@ -57,10 +57,10 @@
<view v-else-if="message.contentType == 'order'"><ns-chat-order :isCanSend="false" :orderId="message.order_id"></ns-chat-order></view> <view v-else-if="message.contentType == 'order'"><ns-chat-order :isCanSend="false" :orderId="message.order_id"></ns-chat-order></view>
<view class="no-connect-box" v-if="message.contentType == 'noline'"> <view class="no-connect-box" v-if="message.contentType == 'noline'">
<view class="no-connect">{{ $lang('chat.customerOffline') }}</view> <view class="no-connect">客服不在线</view>
</view> </view>
<view class="no-connect-box" v-if="message.contentType == 'online'"> <view class="no-connect-box" v-if="message.contentType == 'online'">
<view class="no-connect">{{ $lang('chat.customerOnline') }}</view> <view class="no-connect">客服在线</view>
</view> </view>
<uni-popup ref="imgPopup" type="center"> <uni-popup ref="imgPopup" type="center">
<view class="imagePop"> <view class="imagePop">

View File

@@ -236,7 +236,7 @@ export default {
handleUnifiedKefuClick() { handleUnifiedKefuClick() {
this.customerService.handleUnifiedKefuClick({ this.customerService.handleUnifiedKefuClick({
sendMessageTitle: this.$lang('kefu.hoverNavConsult'), sendMessageTitle: '来自悬浮按钮的咨询',
sendMessagePath: '/pages/index/index' sendMessagePath: '/pages/index/index'
}); });
} }

View File

@@ -36,13 +36,8 @@ export default {
methods: { methods: {
getText() { getText() {
let self = this; let self = this;
let timeVal = _time_.getFormatTime(self.textVal, self.maxDate, { let timeVal = _time_.getFormatTime(self.textVal, self.maxDate);
justNow: self.$lang('time.justNow'), if (timeVal && (timeVal.endsWith('刚刚') || timeVal.endsWith('分钟前'))) {
minutesAgo: self.$lang('time.minutesAgo'),
hoursAgo: self.$lang('time.hoursAgo'),
daysAgo: self.$lang('time.daysAgo')
});
if (timeVal && (timeVal.endsWith(self.$lang('time.justNow')) || timeVal.endsWith(self.$lang('time.minutesAgo')))) {
setTimeout(() => { setTimeout(() => {
let temp = self.textVal; let temp = self.textVal;
self.textVal = ''; self.textVal = '';

View File

@@ -89,18 +89,17 @@ timeProto.getLastDate = function(constTime) {
return date.getFullYear() + '-' + month + '-' + day; return date.getFullYear() + '-' + month + '-' + day;
} }
const resDateStr = function(timer, constTime, i18n) { const resDateStr = function(timer, constTime) {
const t = i18n || { justNow: "刚刚", minutesAgo: "分钟前", hoursAgo: "小时前", daysAgo: "天前" }
let _just = function(timer) { let _just = function(timer) {
if (timer <= 0 || Math.floor(timer / 60) <= 0) { if (timer <= 0 || Math.floor(timer / 60) <= 0) {
return t.justNow return "刚刚"
} else return 'next'; } else return 'next';
} }
let _mm = function(timer) { let _mm = function(timer) {
if (timer < 3600) { if (timer < 3600) {
return Math.floor(timer / 60) + t.minutesAgo return Math.floor(timer / 60) + "分钟前"
} else return 'next'; } else return 'next';
} }
let _hh = function(timer, constTime) { let _hh = function(timer, constTime) {
@@ -108,7 +107,7 @@ const resDateStr = function(timer, constTime, i18n) {
if (timer >= 3600 && (constTime - today >= 0)) { if (timer >= 3600 && (constTime - today >= 0)) {
//可切换显示模式 //可切换显示模式
// return "今天 " + new Date(constTime).pattern("HH:mm"); // return "今天 " + new Date(constTime).pattern("HH:mm");
return Math.floor(timer / 60 / 60) + t.hoursAgo; return Math.floor(timer / 60 / 60) + "小时前";
} else { } else {
return 'next' return 'next'
}; };
@@ -117,7 +116,7 @@ const resDateStr = function(timer, constTime, i18n) {
let today = _time_.getTodayUnix(); let today = _time_.getTodayUnix();
timer = (today - constTime) / 1000; timer = (today - constTime) / 1000;
if (timer / 86400 <= 31) { if (timer / 86400 <= 31) {
return Math.ceil(timer / 86400) + t.daysAgo return Math.ceil(timer / 86400) + "天前"
} else return 'next'; } else return 'next';
} }
let _dlast = function(timer, constTime) { let _dlast = function(timer, constTime) {

View File

@@ -41,8 +41,8 @@ export default {
}, },
noMoreSize: 2, //如果列表已无数据,可设置列表的总数量要大于半页才显示无更多数据;避免列表数据过少(比如只有一条数据),显示无更多数据会不好看; 默认5 noMoreSize: 2, //如果列表已无数据,可设置列表的总数量要大于半页才显示无更多数据;避免列表数据过少(比如只有一条数据),显示无更多数据会不好看; 默认5
empty: { empty: {
tip: '~ ' + this.$lang('mescroll.emptyTip') + ' ~', // 提示 tip: '~ 空空如也 ~', // 提示
btnText: this.$lang('mescroll.goBrowse') btnText: '去看看'
}, },
onScroll: true onScroll: true
}, },

View File

@@ -9,7 +9,7 @@
<text class="goods-price-sign color-base-text">¥</text> <text class="goods-price-sign color-base-text">¥</text>
<text class="color-base-text">{{ goodsInfo.price }}</text> <text class="color-base-text">{{ goodsInfo.price }}</text>
</view> </view>
<view class="goods-option font-size-goods-tag disabled">{{ $lang('chat.sent') }}</view> <view class="goods-option font-size-goods-tag disabled">已发送</view>
</view> </view>
</view> </view>
</view> </view>
@@ -22,7 +22,7 @@
<text class="goods-price-sign color-base-text">¥</text> <text class="goods-price-sign color-base-text">¥</text>
<text class="color-base-text">{{ goodsDetail.price }}</text> <text class="color-base-text">{{ goodsDetail.price }}</text>
</view> </view>
<view class="goods-option font-size-goods-tag color-base-bg" @click="sendMsg('goods')">{{ $lang('chat.send') }}</view> <view class="goods-option font-size-goods-tag color-base-bg" @click="sendMsg('goods')">发送</view>
</view> </view>
</view> </view>
</view> </view>

View File

@@ -4,14 +4,14 @@
<image :src="$util.img(orderdetails.order_goods ? orderdetails.order_goods[0].sku_image : '')" mode="aspectFill" show-menu-by-longpress></image> <image :src="$util.img(orderdetails.order_goods ? orderdetails.order_goods[0].sku_image : '')" mode="aspectFill" show-menu-by-longpress></image>
<view class="goods-info"> <view class="goods-info">
<view class="goods-name">{{ orderdetails.order_goods ? orderdetails.order_goods[0].sku_name : '' }}</view> <view class="goods-name">{{ orderdetails.order_goods ? orderdetails.order_goods[0].sku_name : '' }}</view>
<view class="font-size-goods-tag">{{ $lang('chat.orderStatus') }}{{ orderdetails.order_status_name }}</view> <view class="font-size-goods-tag">订单状态:{{ orderdetails.order_status_name }}</view>
<view class="font-size-goods-tag">{{ $lang('chat.deliveryMethod') }}{{ orderdetails.delivery_type_name }}</view> <view class="font-size-goods-tag">配送方式:{{ orderdetails.delivery_type_name }}</view>
<view class="goods-bottom"> <view class="goods-bottom">
<view class="goods-price color-base-text"> <view class="goods-price color-base-text">
<text class="goods-price-sign">¥</text> <text class="goods-price-sign">¥</text>
<text>{{ orderdetails.order_goods ? orderdetails.order_goods[0].price : '' }}</text> <text>{{ orderdetails.order_goods ? orderdetails.order_goods[0].price : '' }}</text>
</view> </view>
<view class="goods-option font-size-goods-tag color-base-bg" @click="sendMsg('order')">{{ $lang('chat.send') }}</view> <view class="goods-option font-size-goods-tag color-base-bg" @click="sendMsg('order')">发送</view>
</view> </view>
</view> </view>
</view> </view>
@@ -19,14 +19,14 @@
<image :src="$util.img(orderInfo.order_goods ? orderInfo.order_goods[0].sku_image : '')" mode="aspectFill" show-menu-by-longpress></image> <image :src="$util.img(orderInfo.order_goods ? orderInfo.order_goods[0].sku_image : '')" mode="aspectFill" show-menu-by-longpress></image>
<view class="goods-info"> <view class="goods-info">
<view class="goods-name">{{ orderInfo.order_goods ? orderInfo.order_goods[0].sku_name : '' }}</view> <view class="goods-name">{{ orderInfo.order_goods ? orderInfo.order_goods[0].sku_name : '' }}</view>
<view class="font-size-goods-tag">{{ $lang('chat.orderStatus') }}{{ orderInfo.order_status_name }}</view> <view class="font-size-goods-tag">订单状态:{{ orderInfo.order_status_name }}</view>
<view class="font-size-goods-tag">{{ $lang('chat.deliveryMethod') }}{{ orderInfo.delivery_type_name }}</view> <view class="font-size-goods-tag">配送方式:{{ orderInfo.delivery_type_name }}</view>
<view class="goods-bottom"> <view class="goods-bottom">
<view class="goods-price color-base-text"> <view class="goods-price color-base-text">
<text class="goods-price-sign">¥</text> <text class="goods-price-sign">¥</text>
<text>{{ orderInfo.order_goods ? orderInfo.order_goods[0].price : '' }}</text> <text>{{ orderInfo.order_goods ? orderInfo.order_goods[0].price : '' }}</text>
</view> </view>
<view class="goods-option font-size-goods-tag disabled">{{ $lang('chat.sent') }}</view> <view class="goods-option font-size-goods-tag disabled">已发送</view>
</view> </view>
</view> </view>
</view> </view>

View File

@@ -5,8 +5,8 @@
<view class="goods-item"> <view class="goods-item">
<view class="title">{{ isEnEnv ? goodsInfo.en_goods_name : goodsInfo.goods_name }}</view> <view class="title">{{ isEnEnv ? goodsInfo.en_goods_name : goodsInfo.goods_name }}</view>
<view class="goods-sku"> <view class="goods-sku">
{{ $lang('sku.stock') }}{{ goodsInfo.stock }} 库存:{{ goodsInfo.stock }}
<text>{{ $lang('chat.sales') }}{{ goodsInfo.sale_num }}</text> <text>销量:{{ goodsInfo.sale_num }}</text>
</view> </view>
<view class="goods-price"> <view class="goods-price">
<view class="price color-base-text"> <view class="price color-base-text">
@@ -14,7 +14,7 @@
<text class="price-num">{{ goodsInfo.price }}</text> <text class="price-num">{{ goodsInfo.price }}</text>
</view> </view>
<view class="see-shop color-base-text" @click="go_shop()"> <view class="see-shop color-base-text" @click="go_shop()">
{{ $lang('chat.viewGoods') }} 查看商品
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
</view> </view>
</view> </view>

View File

@@ -29,10 +29,10 @@
<uni-popup ref="servicePopup" type="center"> <uni-popup ref="servicePopup" type="center">
<view class="service-popup-wrap"> <view class="service-popup-wrap">
<view class="head-wrap" @click="$refs.servicePopup.close()"> <view class="head-wrap" @click="$refs.servicePopup.close()">
<text>{{ $lang('chat.customerService') }}</text> <text>联系客服</text>
<text class="iconfont icon-close"></text> <text class="iconfont icon-close"></text>
</view> </view>
<view class="body-wrap">{{ siteInfo.site_tel ? $lang('chat.contactService') + siteInfo.site_tel : $lang('chat.noService') }} <view class="body-wrap">{{ siteInfo.site_tel ? '请联系客服,客服电话是' + siteInfo.site_tel : '抱歉,商家暂无客服,请线下联系' }}
</view> </view>
</view> </view>
</uni-popup> </uni-popup>

View File

@@ -15,7 +15,7 @@ export default {
props: { props: {
text: { text: {
type: String, type: String,
default: '' default: '暂无相关数据'
}, },
subText: { subText: {
type: String, type: String,
@@ -28,7 +28,7 @@ export default {
emptyBtn: { emptyBtn: {
type: Object, type: Object,
default: () => { default: () => {
return { text: '' }; return { text: '去逛逛' };
} }
}, },
fixed: { fixed: {

View File

@@ -34,7 +34,7 @@
</view> </view>
<view class="box"> <view class="box">
<text v-if="item.val != ''">{{ item.val }}</text> <text v-if="item.val != ''">{{ item.val }}</text>
<text v-else class="color-tip">{{ $lang('form.selectPlaceholder') }}</text> <text v-else class="color-tip">请选择</text>
</view> </view>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
</view> </view>
@@ -188,7 +188,7 @@
<view class="box"> <view class="box">
<pick-regions :default-regions="item.default_regions" :select-arr="item.select_arr" @getRegions="handleGetRegions($event, index)"> <pick-regions :default-regions="item.default_regions" :select-arr="item.select_arr" @getRegions="handleGetRegions($event, index)">
<view class="select-address " :class="{ empty: !item.val, 'color-tip': !item.val }"> <view class="select-address " :class="{ empty: !item.val, 'color-tip': !item.val }">
{{ item.val ? item.val : item.select_arr == '2' ? $lang('form.selectProvinceCity') : $lang('form.selectProvinceCityDistrict') }} {{ item.val ? item.val : item.select_arr == '2' ? '请选择省市' : '请选择省市区/县' }}
</view> </view>
</pick-regions> </pick-regions>
</view> </view>
@@ -365,7 +365,7 @@
if (item.value.required && !item.val) { if (item.value.required && !item.val) {
verify = false; verify = false;
this.$util.showToast({ this.$util.showToast({
title: this.$lang('form.inputRequired') + item.value.title title: '请输入' + item.value.title
}); });
break; break;
} }
@@ -375,13 +375,13 @@
verify = !item.value.required; verify = !item.value.required;
if (verify == false) { if (verify == false) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('form.idCardInvalid') title: '身份证输入不合法'
}); });
return false; return false;
} }
if (verify == true && item.val != '') { if (verify == true && item.val != '') {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('form.idCardInvalid') title: '身份证输入不合法'
}); });
return false; return false;
} }
@@ -392,13 +392,13 @@
verify = !item.value.required; verify = !item.value.required;
if (verify == false) { if (verify == false) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('form.phoneInvalid') title: '手机号输入不合法'
}); });
return false; return false;
} }
if (verify == true && item.val != '') { if (verify == true && item.val != '') {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('form.phoneInvalid') title: '手机号输入不合法'
}); });
return false; return false;
} }
@@ -409,7 +409,7 @@
if (item.value.required && !item.val) { if (item.value.required && !item.val) {
verify = false; verify = false;
this.$util.showToast({ this.$util.showToast({
title: this.$lang('form.inputRequired') + item.value.title title: '请输入' + item.value.title
}); });
break; break;
} }
@@ -419,7 +419,7 @@
if (item.value.required && !item.val) { if (item.value.required && !item.val) {
verify = false; verify = false;
this.$util.showToast({ this.$util.showToast({
title: this.$lang('form.selectRequired') + item.value.title title: '请选择' + item.value.title
}); });
break; break;
} }
@@ -429,7 +429,7 @@
if (item.value.required && !item.val) { if (item.value.required && !item.val) {
verify = false; verify = false;
this.$util.showToast({ this.$util.showToast({
title: this.$lang('form.selectAtLeastOne') + item.value.title title: '请至少选择一个' + item.value.title
}); });
break; break;
} }
@@ -439,7 +439,7 @@
if (item.value.required && !item.val) { if (item.value.required && !item.val) {
verify = false; verify = false;
this.$util.showToast({ this.$util.showToast({
title: this.$lang('form.uploadAtLeastOne') + item.value.title title: '请至少上传一张' + item.value.title
}); });
break; break;
} }
@@ -449,7 +449,7 @@
if (item.value.required && !item.val) { if (item.value.required && !item.val) {
verify = false; verify = false;
this.$util.showToast({ this.$util.showToast({
title: this.$lang('form.selectRequired') + item.value.title title: '请选择' + item.value.title
}); });
break; break;
} }
@@ -459,7 +459,7 @@
if (item.value.required && !item.val) { if (item.value.required && !item.val) {
verify = false; verify = false;
this.$util.showToast({ this.$util.showToast({
title: this.$lang('form.selectRequired') + item.value.title title: '请选择' + item.value.title
}); });
break; break;
} }
@@ -467,7 +467,7 @@
if (this.$util.timeTurnTimeStamp(item.start_date) > this.$util.timeTurnTimeStamp(item.end_date)) { if (this.$util.timeTurnTimeStamp(item.start_date) > this.$util.timeTurnTimeStamp(item.end_date)) {
verify = false; verify = false;
this.$util.showToast({ this.$util.showToast({
title: this.$lang('form.endDateBeforeStart') title: '结束日期不能小于开始日期'
}); });
break; break;
} }
@@ -477,7 +477,7 @@
if (item.value.required && !item.val) { if (item.value.required && !item.val) {
verify = false; verify = false;
this.$util.showToast({ this.$util.showToast({
title: this.$lang('form.selectRequired') + item.value.title title: '请选择' + item.value.title
}); });
break; break;
} }
@@ -487,7 +487,7 @@
if (item.value.required && !item.val) { if (item.value.required && !item.val) {
verify = false; verify = false;
this.$util.showToast({ this.$util.showToast({
title: this.$lang('form.selectRequired') + item.value.title title: '请选择' + item.value.title
}); });
break; break;
} }
@@ -495,7 +495,7 @@
if (item.start_time >= item.end_time) { if (item.start_time >= item.end_time) {
verify = false; verify = false;
this.$util.showToast({ this.$util.showToast({
title: this.$lang('form.endTimeBeforeStart') title: '结束时间必须大于开始时间'
}); });
break; break;
} }
@@ -505,7 +505,7 @@
if (item.value.required && !item.val) { if (item.value.required && !item.val) {
verify = false; verify = false;
this.$util.showToast({ this.$util.showToast({
title: this.$lang('form.selectRequired') + item.value.title title: '请选择' + item.value.title
}); });
break; break;
} }
@@ -542,7 +542,7 @@
res.forEach(v => { res.forEach(v => {
if (this.formData[index].img_lists.length >= Number(this.formData[index].value.max_count)) { if (this.formData[index].img_lists.length >= Number(this.formData[index].value.max_count)) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('form.maxUploadImages') + this.formData[index].value.max_count + this.$lang('form.images') title: '最多上传' + this.formData[index].value.max_count + '张图片'
}); });
return false; return false;
} else { } else {
@@ -560,7 +560,7 @@
addImg(index) { addImg(index) {
if (this.formData[index].img_lists.length >= Number(this.formData[index].value.max_count)) { if (this.formData[index].img_lists.length >= Number(this.formData[index].value.max_count)) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('form.maxUploadImages') + this.formData[index].value.max_count + this.$lang('form.images') title: '最多上传' + this.formData[index].value.max_count + '张图片'
}); });
return false; return false;
} }

View File

@@ -13,9 +13,9 @@
goodsDetail.en_goods_name : goodsDetail.goods_name) }}</view> goodsDetail.en_goods_name : goodsDetail.goods_name) }}</view>
<view class="other-info"> <view class="other-info">
<view class="stock color-tip" v-if="goodsDetail.stock_show"> <view class="stock color-tip" v-if="goodsDetail.stock_show">
{{ $lang('sku.stock') }}{{ goodsDetail.stock }}{{ goodsDetail.unit }}</view> 库存{{ goodsDetail.stock }}{{ goodsDetail.unit }}</view>
<view class="starting-num" v-if="parseFloat(goodsDetail.min_buy)"> <view class="starting-num" v-if="parseFloat(goodsDetail.min_buy)">
{{ $lang('sku.startSale') }}{{ goodsDetail.min_buy }}{{ $lang('sku.unit') }} 起售{{ goodsDetail.min_buy }}件
</view> </view>
</view> </view>
</view> </view>
@@ -43,10 +43,10 @@
<view class="footer"> <view class="footer">
<view class="sku-name font-size-goods-tag"> <view class="sku-name font-size-goods-tag">
<template v-if="goodsDetail.sku_spec_format" class="color-tip"> <template v-if="goodsDetail.sku_spec_format" class="color-tip">
{{ $lang('sku.selectedSpec') }} 已选择:
<text class="color-tip" v-for="(item, index) in goodsDetail.sku_spec_format" <text class="color-tip" v-for="(item, index) in goodsDetail.sku_spec_format"
:key="index">{{ item.spec_value_name }}</text> :key="index">{{ item.spec_value_name }}</text>
</template> </template>
</view> </view>
<view class="footer-bottom"> <view class="footer-bottom">
<view class="footer-left"> <view class="footer-left">
@@ -72,8 +72,8 @@
<view v-else-if="number == 0 && isLoad"> <view v-else-if="number == 0 && isLoad">
<view class="num-action"> <view class="num-action">
<button type="primary" v-if="goodsDetail.stock && goodsDetail.stock != 0" <button type="primary" v-if="goodsDetail.stock && goodsDetail.stock != 0"
@click="confirm($event)">{{ $lang('sku.addToCart') }}</button> @click="confirm($event)">加入购物车</button>
<button type="primary" disabled="true" v-else>{{ $lang('sku.confirm') }}</button> <button type="primary" disabled="true" v-else>确定</button>
<view class="click-event"></view> <view class="click-event"></view>
</view> </view>
</view> </view>
@@ -261,7 +261,7 @@ export default {
} else { } else {
if (this.number >= this.goodsDetail.stock) { if (this.number >= this.goodsDetail.stock) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.stockInsufficient') title: '库存不足'
}); });
return; return;
} }
@@ -269,13 +269,13 @@ export default {
if (this.goodsDetail.is_limit == 1 && this.maxBuy > 0) { if (this.goodsDetail.is_limit == 1 && this.maxBuy > 0) {
if (this.goodsDetail.limit_type == 1) { if (this.goodsDetail.limit_type == 1) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.maxBuyPerOrder') + this.maxBuy + this.goodsDetail.unit title: '该商品每次最多购买' + this.maxBuy + this.goodsDetail.unit
}); });
return; return;
} }
if (this.goodsDetail.limit_type == 2) { if (this.goodsDetail.limit_type == 2) {
let message = this.$lang('sku.maxBuyPerPerson') + this.maxBuy + this.goodsDetail.unit; let message = '该商品每人限购' + this.maxBuy + this.goodsDetail.unit;
message += this.goodsDetail.purchased_num > 0 ? ',您已购买了' + this.goodsDetail.purchased_num + this.goodsDetail.unit : ''; message += this.goodsDetail.purchased_num > 0 ? ',您已购买了' + this.goodsDetail.purchased_num + this.goodsDetail.unit : '';
this.$util.showToast({ this.$util.showToast({
title: message title: message
@@ -375,7 +375,7 @@ export default {
} }
if (this.goodsDetail.goods_state == 0) { if (this.goodsDetail.goods_state == 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.productRemoved') title: '商品已下架'
}); });
return; return;
} }
@@ -385,14 +385,14 @@ export default {
this.keyInput(true, () => { this.keyInput(true, () => {
if (this.goodsDetail.stock == 0) { if (this.goodsDetail.stock == 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.productSoldOut') title: '商品已售罄'
}); });
return; return;
} }
if (this.number > this.goodsDetail.stock) { if (this.number > this.goodsDetail.stock) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.stockInsufficient') title: '库存不足'
}); });
return; return;
} }
@@ -400,14 +400,14 @@ export default {
if (this.goodsDetail.is_limit == 1 && this.goodsDetail.limit_type == 1 && this.maxBuy > 0 && if (this.goodsDetail.is_limit == 1 && this.goodsDetail.limit_type == 1 && this.maxBuy > 0 &&
this.number > this.maxBuy) { this.number > this.maxBuy) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.maxBuyPerOrder') + this.maxBuy + this.goodsDetail.unit title: '该商品每次最多购买' + this.maxBuy + this.goodsDetail.unit
}); });
return; return;
} }
if (this.goodsDetail.is_limit == 1 && this.goodsDetail.limit_type == 2 && this.maxBuy > 0 && if (this.goodsDetail.is_limit == 1 && this.goodsDetail.limit_type == 2 && this.maxBuy > 0 &&
this.number + this.goodsDetail.purchased_num > this.maxBuy) { this.number + this.goodsDetail.purchased_num > this.maxBuy) {
let message = this.$lang('sku.maxBuyPerPerson') + this.maxBuy + this.goodsDetail.unit; let message = '该商品每人限购' + this.maxBuy + this.goodsDetail.unit;
message += this.goodsDetail.purchased_num > 0 ? ',您已购买了' + this.goodsDetail.purchased_num + this.goodsDetail.unit : ''; message += this.goodsDetail.purchased_num > 0 ? ',您已购买了' + this.goodsDetail.purchased_num + this.goodsDetail.unit : '';
this.$util.showToast({ this.$util.showToast({
title: message title: message
@@ -456,7 +456,7 @@ export default {
this.$store.dispatch('cartCalculate'); this.$store.dispatch('cartCalculate');
this.$emit('refresh'); this.$emit('refresh');
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.addToCartSuccess') title: '加入购物车成功'
}); });
} }
this.btnSwitch = false; this.btnSwitch = false;

View File

@@ -67,13 +67,13 @@ export default {
let cart_id = cart ? cart.cart_id : 0; let cart_id = cart ? cart.cart_id : 0;
if (_num > parseInt(data.stock)) { if (_num > parseInt(data.stock)) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.stockInsufficient') title: '商品库存不足'
}); });
return; return;
} }
if (data.is_limit && data.max_buy && _num > parseInt(data.max_buy)) { if (data.is_limit && data.max_buy && _num > parseInt(data.max_buy)) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.maxBuyPerPerson') + data.max_buy + (data.unit || this.$lang('sku.unit')) title: `该商品每人限购${data.max_buy}${data.unit || '件'}`
}); });
return; return;
} }
@@ -121,7 +121,7 @@ export default {
res.data; res.data;
} }
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.addToCartSuccess') title: "商品添加购物车成功"
}); });
this.$store.commit('setCartChange'); this.$store.commit('setCartChange');
this.$store.dispatch('cartCalculate'); this.$store.dispatch('cartCalculate');
@@ -147,7 +147,7 @@ export default {
success: res => { success: res => {
if (res.code >= 0) { if (res.code >= 0) {
let item = res.data; let item = res.data;
item.unit = item.unit || this.$lang('goods.piece'); item.unit = item.unit || '件';
if (item.sku_images) item.sku_images = item.sku_images.split(','); if (item.sku_images) item.sku_images = item.sku_images.split(',');
else item.sku_images = []; else item.sku_images = [];

View File

@@ -19,27 +19,27 @@
<block v-if="type == 'point'"> <block v-if="type == 'point'">
<block v-if="goodsDetail.type == 1"> <block v-if="goodsDetail.type == 1">
<view class="price-wrap"> <view class="price-wrap">
<text class="price price-color font-size-toolbar">{{ goodsDetail.point }}{{ $lang('sku.point') }}</text> <text class="price price-color font-size-toolbar">{{ goodsDetail.point }}积分</text>
<block v-if="goodsDetail.exchange_price != '0.00' && goodsDetail.pay_type > 0"> <block v-if="goodsDetail.exchange_price != '0.00' && goodsDetail.pay_type > 0">
<text class="unit price-color font-size-tag">+</text> <text class="unit price-color font-size-tag">+</text>
<text class="price price-color font-size-toolbar price-font">{{ $lang('common.currencySymbol') }}{{ goodsDetail.exchange_price }}</text> <text class="price price-color font-size-toolbar price-font">{{ $lang('common.currencySymbol') }}{{ goodsDetail.exchange_price }}</text>
</block> </block>
</view> </view>
<view class="stock" v-if="goodsDetail.stock_show"> <view class="stock" v-if="goodsDetail.stock_show">
{{ $lang('sku.stock') }}{{ goodsDetail.stock }}{{ goodsDetail.unit }}</view> 库存{{ goodsDetail.stock }}{{ goodsDetail.unit }}</view>
</block> </block>
<block v-else> <block v-else>
<view class="price-wrap"> <view class="price-wrap">
<view class="price font-size-toolbar">{{ goodsDetail.name }}</view> <view class="price font-size-toolbar">{{ goodsDetail.name }}</view>
</view> </view>
<view class="stock" style="height: auto;"> <view class="stock" style="height: auto;">
{{ $lang('sku.point') }}: 积分:
<text class="price-color">{{ goodsDetail.point }}</text> <text class="price-color">{{ goodsDetail.point }}</text>
</view> </view>
<view class="stock"> <view class="stock">
{{ $lang('sku.stock') }}: 库存:
<text class="color-base-text">{{ goodsDetail.stock }}{{ goodsDetail.unit }}</text> <text class="color-base-text">{{ goodsDetail.stock }}{{ goodsDetail.unit }}</text>
</view> </view>
</block> </block>
</block> </block>
<block v-else-if="type == 'presale'"> <block v-else-if="type == 'presale'">
@@ -48,14 +48,14 @@
<text class="price price-style large">{{ parseFloat(goodsDetail.presale_deposit).toFixed(2).split('.')[0] }}</text> <text class="price price-style large">{{ parseFloat(goodsDetail.presale_deposit).toFixed(2).split('.')[0] }}</text>
<text class="unit price-style small">.{{ parseFloat(goodsDetail.presale_deposit).toFixed(2).split('.')[1] }}</text> <text class="unit price-style small">.{{ parseFloat(goodsDetail.presale_deposit).toFixed(2).split('.')[1] }}</text>
<view class="balance" v-if="balance > 0"> <view class="balance" v-if="balance > 0">
<text>{{ $lang('sku.tailPayment') }}</text> <text>尾款</text>
<text class="unit price-color font-size-tag price-font">¥</text> <text class="unit price-color font-size-tag price-font">¥</text>
<text class="price-color price-font">{{ balance }}</text> <text class="price-color price-font">{{ balance }}</text>
</view> </view>
</view> </view>
<view class="stock presale-stock"> <view class="stock presale-stock">
<block v-if="goodsDetail.stock_show">{{ $lang('sku.stock') }}{{ goodsDetail.stock }}{{ goodsDetail.unit }} <block v-if="goodsDetail.stock_show">库存{{ goodsDetail.stock }}{{ goodsDetail.unit }}
</block> </block>
</view> </view>
</block> </block>
<block v-else> <block v-else>
@@ -117,11 +117,11 @@
<text class="unit price-style small" v-else>.{{ parseFloat(goodsDetail.price).toFixed(2).split('.')[1] }}</text> <text class="unit price-style small" v-else>.{{ parseFloat(goodsDetail.price).toFixed(2).split('.')[1] }}</text>
</block> </block>
</view> </view>
<view class="stock" v-if="goodsDetail.stock_show">{{ $lang('sku.stock') }}{{ goodsDetail.stock }}{{ goodsDetail.unit }}</view> <view class="stock" v-if="goodsDetail.stock_show">库存{{ goodsDetail.stock }}{{ goodsDetail.unit }}</view>
</block> </block>
<view class="sku-name font-size-tag" v-if="goodsDetail.sku_spec_format"> <view class="sku-name font-size-tag" v-if="goodsDetail.sku_spec_format">
<text class="color-tip">{{ $lang('sku.selectedSpec') }}</text> <text class="color-tip">已选规格:</text>
<text v-for="(item, index) in goodsDetail.sku_spec_format" :key="index" class="spec-value">{{ item.spec_value_name }}</text> <text v-for="(item, index) in goodsDetail.sku_spec_format" :key="index" class="spec-value">{{ item.spec_value_name }}</text>
</view> </view>
</view> </view>
@@ -135,13 +135,13 @@
<view class="sku-list-wrap" v-if="type == 'pintuan' && goodsDetail.pintuan_type == 'ladder' && !goodsDetail.group_id"> <view class="sku-list-wrap" v-if="type == 'pintuan' && goodsDetail.pintuan_type == 'ladder' && !goodsDetail.group_id">
<text class="title font-size-base">&nbsp;</text> <text class="title font-size-base">&nbsp;</text>
<view class="items" :class="{ selected: pintuan_num_field == 'pintuan_num' }" @click="pintuanChange('pintuan_num')"> <view class="items" :class="{ selected: pintuan_num_field == 'pintuan_num' }" @click="pintuanChange('pintuan_num')">
<text>{{ goodsDetail.pintuan_num }}{{ $lang('sku.personTeam') }}</text> <text>{{ goodsDetail.pintuan_num }}人团</text>
</view> </view>
<view class="items" v-if="goodsDetail.pintuan_num_2 > 0" :class="{ selected: pintuan_num_field == 'pintuan_num_2' }" @click="pintuanChange('pintuan_num_2')"> <view class="items" v-if="goodsDetail.pintuan_num_2 > 0" :class="{ selected: pintuan_num_field == 'pintuan_num_2' }" @click="pintuanChange('pintuan_num_2')">
<text>{{ goodsDetail.pintuan_num_2 }}{{ $lang('sku.personTeam') }}</text> <text>{{ goodsDetail.pintuan_num_2 }}人团</text>
</view> </view>
<view class="items" v-if="goodsDetail.pintuan_num_3 > 0" :class="{ selected: pintuan_num_field == 'pintuan_num_3' }" @click="pintuanChange('pintuan_num_3')"> <view class="items" v-if="goodsDetail.pintuan_num_3 > 0" :class="{ selected: pintuan_num_field == 'pintuan_num_3' }" @click="pintuanChange('pintuan_num_3')">
<text>{{ goodsDetail.pintuan_num_3 }}{{ $lang('sku.personTeam') }}</text> <text>{{ goodsDetail.pintuan_num_3 }}人团</text>
</view> </view>
</view> </view>
@@ -158,14 +158,14 @@
<view class="number-wrap"> <view class="number-wrap">
<view class="number-line"> <view class="number-line">
<text class="title font-size-base" v-if="type == 'point'">{{ $lang('sku.exchangeQuantity') }}</text> <text class="title font-size-base" v-if="type == 'point'">兑换数量</text>
<text class="title font-size-base" v-else>{{ $lang('sku.buyQuantity') }}</text> <text class="title font-size-base" v-else>购买数量</text>
<text class="limit-txt color-base-text" v-if="limitNumber > 0">({{ $lang('sku.perPersonLimit') }}{{ limitNumber }}{{ goodsDetail.unit }})</text> <text class="limit-txt color-base-text" v-if="limitNumber > 0">(每人限购{{ limitNumber }}{{ goodsDetail.unit }})</text>
<text v-if="maxBuy > 0 && minBuy > 1" class="limit-txt color-base-text"> <text v-if="maxBuy > 0 && minBuy > 1" class="limit-txt color-base-text">
({{ minBuy }}{{ goodsDetail.unit }}{{ $lang('sku.startSale') }},{{ $lang('sku.limit') }}{{ maxBuy }}{{ goodsDetail.unit }}) ({{ minBuy }}{{ goodsDetail.unit }}起售,限购{{ maxBuy }}{{ goodsDetail.unit }})
</text> </text>
<text v-else-if="maxBuy > 0" class="limit-txt color-base-text">({{ $lang('sku.limit') }}{{ maxBuy }}{{ goodsDetail.unit }})</text> <text v-else-if="maxBuy > 0" class="limit-txt color-base-text">(限购{{ maxBuy }}{{ goodsDetail.unit }})</text>
<text v-else-if="minBuy > 1" class="limit-txt color-base-text">({{ minBuy }}{{ goodsDetail.unit }}{{ $lang('sku.startSale') }})</text> <text v-else-if="minBuy > 1" class="limit-txt color-base-text">({{ minBuy }}{{ goodsDetail.unit }}起售)</text>
<view class="number"> <view class="number">
<button type="default" class="decrease color-line-border" :class="{ disabled: decreaseDisabled }" @click="changeNum('-')">-</button> <button type="default" class="decrease color-line-border" :class="{ disabled: decreaseDisabled }" @click="changeNum('-')">-</button>
<input type="number" class="uni-input color-line-border font-size-goods-tag" @blur="blur" v-model="number" placeholder="0" @input="keyInput(false)" /> <input type="number" class="uni-input color-line-border font-size-goods-tag" @blur="blur" v-model="number" placeholder="0" @input="keyInput(false)" />
@@ -178,34 +178,34 @@
</scroll-view> </scroll-view>
</view> </view>
<view class="footer" @click="confirm()"> <view class="footer" @click="confirm()">
<button type="primary" v-if="goodsDetail.stock && goodsDetail.stock != 0 && goodsDetail.is_virtual == 0 && type == 'buy_now'" :style="{ background: themeStyle.goods_detail.goods_btn_color_shallow, color : '#fff' }" @click.stop="confirm(true)">{{ $lang('sku.addToCart') }}</button> <button type="primary" v-if="goodsDetail.stock && goodsDetail.stock != 0 && goodsDetail.is_virtual == 0 && type == 'buy_now'" :style="{ background: themeStyle.goods_detail.goods_btn_color_shallow, color : '#fff' }" @click.stop="confirm(true)">加入购物车</button>
<block v-if="type == 'point'"> <block v-if="type == 'point'">
<block v-if="goodsDetail.type == 1"> <block v-if="goodsDetail.type == 1">
<!-- 兑换商品 --> <!-- 兑换商品 -->
<button v-if="goodsDetail.stock && goodsDetail.stock != 0" type="primary">{{ $lang('sku.exchange') }}</button> <button v-if="goodsDetail.stock && goodsDetail.stock != 0" type="primary">兑换</button>
<button type="primary" v-else disabled="true">{{ $lang('sku.stockInsufficient') }}</button> <button type="primary" v-else disabled="true">库存不足</button>
</block> </block>
<block v-else-if="goodsDetail.type == 2 || goodsDetail.type == 3"> <block v-else-if="goodsDetail.type == 2 || goodsDetail.type == 3">
<!-- 兑换优惠券、红包 --> <!-- 兑换优惠券、红包 -->
<button type="primary">{{ $lang('sku.exchange') }}</button> <button type="primary">兑换</button>
</block> </block>
</block> </block>
<block v-else-if="goodsDetail.goods_state == 1"> <block v-else-if="goodsDetail.goods_state == 1">
<button type="primary" v-if="goodsDetail.stock && goodsDetail.stock != 0 && type == 'join_cart'">{{ $lang('sku.addToCart') }}</button> <button type="primary" v-if="goodsDetail.stock && goodsDetail.stock != 0 && type == 'join_cart'">加入购物车</button>
<button type="primary" v-else-if="goodsDetail.stock && goodsDetail.stock != 0 && type == 'buy_now'">{{ $lang('sku.buyNow') }}</button> <button type="primary" v-else-if="goodsDetail.stock && goodsDetail.stock != 0 && type == 'buy_now'">立即购买</button>
<button type="primary" v-else-if="goodsDetail.stock && goodsDetail.stock != 0 && type == 'confirm'">{{ $lang('sku.confirm') }}</button> <button type="primary" v-else-if="goodsDetail.stock && goodsDetail.stock != 0 && type == 'confirm'">确认</button>
<template v-else-if="goodsDetail.stock && goodsDetail.stock != 0"> <template v-else-if="goodsDetail.stock && goodsDetail.stock != 0">
<template v-if="goodsDetail.buy_num"> <template v-if="goodsDetail.buy_num">
<button type="primary" v-if="goodsDetail.buy_num <= goodsDetail.stock">{{ $lang('sku.snatchNow') }}</button> <button type="primary" v-if="goodsDetail.buy_num <= goodsDetail.stock">立即抢购</button>
<button type="primary" v-else disabled="true">{{ $lang('sku.stockInsufficient') }}</button> <button type="primary" v-else disabled="true">库存不足</button>
</template> </template>
<template v-else> <template v-else>
<button type="primary">{{ $lang('sku.snatchNow') }}</button> <button type="primary">立即抢购</button>
</template> </template>
</template> </template>
<button type="primary" v-else disabled="true">{{ $lang('sku.stockInsufficient') }}</button> <button type="primary" v-else disabled="true">库存不足</button>
</block> </block>
<button type="primary" v-else disabled="true">{{ $lang('sku.productRemoved') }}</button> <button type="primary" v-else disabled="true">该商品已下架</button>
</view> </view>
</view> </view>
</uni-popup-sku> </uni-popup-sku>
@@ -707,7 +707,7 @@
if (this.$util.inArray(this.skuId + '', this.goodsDetail.activity_sku_ids) == -1) { if (this.$util.inArray(this.skuId + '', this.goodsDetail.activity_sku_ids) == -1) {
this.confirmDisabled = true; this.confirmDisabled = true;
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.specNotInCombo') title: '该规格未参与打包一口价活动'
}); });
} else { } else {
this.confirmDisabled = false; this.confirmDisabled = false;
@@ -771,7 +771,7 @@
if (this.$util.inArray(skuId + '', this.goodsDetail.activity_sku_ids) == -1) { if (this.$util.inArray(skuId + '', this.goodsDetail.activity_sku_ids) == -1) {
this.confirmDisabled = true; this.confirmDisabled = true;
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.specNotInCombo') title: '该规格未参与打包一口价活动'
}); });
} else { } else {
this.confirmDisabled = false; this.confirmDisabled = false;
@@ -850,7 +850,7 @@
} else { } else {
if (this.number >= this.goodsDetail.stock) { if (this.number >= this.goodsDetail.stock) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.stockInsufficient') title: '库存不足'
}); });
return; return;
} }
@@ -858,13 +858,13 @@
if (this.goodsDetail.is_limit == 1 && this.maxBuy > 0) { if (this.goodsDetail.is_limit == 1 && this.maxBuy > 0) {
if (this.goodsDetail.limit_type == 1) { if (this.goodsDetail.limit_type == 1) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.maxBuyPerOrder') + this.maxBuy + this.goodsDetail.unit title: '该商品每次最多购买' + this.maxBuy + this.goodsDetail.unit
}); });
return; return;
} }
if (this.goodsDetail.limit_type == 2) { if (this.goodsDetail.limit_type == 2) {
let message = this.$lang('sku.maxBuyPerPerson') + this.maxBuy + this.goodsDetail.unit; let message = '该商品每人限购' + this.maxBuy + this.goodsDetail.unit;
message += this.goodsDetail.purchased_num > 0 ? ',您已购买了' + this.goodsDetail.purchased_num + this.goodsDetail.unit : ''; message += this.goodsDetail.purchased_num > 0 ? ',您已购买了' + this.goodsDetail.purchased_num + this.goodsDetail.unit : '';
this.$util.showToast({ this.$util.showToast({
title: message title: message
@@ -875,14 +875,14 @@
if (this.type == 'seckill' && this.goodsDetail.seckill_id && this.goodsDetail.num > 0) { if (this.type == 'seckill' && this.goodsDetail.seckill_id && this.goodsDetail.num > 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.maxBuyPerPerson') + this.goodsDetail.num + this.goodsDetail.unit title: '该商品每人限购' + this.goodsDetail.num + this.goodsDetail.unit
}); });
return; return;
} }
if (this.type == 'presale' && this.goodsDetail.presale_id && this.goodsDetail.presale_num > 0) { if (this.type == 'presale' && this.goodsDetail.presale_id && this.goodsDetail.presale_num > 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.maxBuyPerPerson') + this.goodsDetail.presale_num + this.goodsDetail.unit title: '该商品每人限购' + this.goodsDetail.presale_num + this.goodsDetail.unit
}); });
return; return;
} }
@@ -894,7 +894,7 @@
} else { } else {
if (this.minBuy > 1) { if (this.minBuy > 1) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.minBuyStart') + this.minBuy + this.goodsDetail.unit + this.$lang('sku.startSale') title: '该商品' + this.minBuy + this.goodsDetail.unit + '起售'
}); });
} }
return; return;
@@ -982,7 +982,7 @@
uni.removeStorageSync('delivery'); uni.removeStorageSync('delivery');
if (this.preview) { if (this.preview) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.previewCannotBuy') title: '预览商品无法购买'
}); });
return; return;
} }
@@ -997,42 +997,42 @@
this.keyInput(true, () => { this.keyInput(true, () => {
if (this.goodsDetail.stock == 0) { if (this.goodsDetail.stock == 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.productSoldOut') title: '商品已售罄'
}); });
return; return;
} }
if (this.number.length == 0 || this.number <= 0) { if (this.number.length == 0 || this.number <= 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.quantityMustBePositive') title: '购买数量不能小于等于0'
}); });
return; return;
} }
if (this.goodsDetail.buy_num > this.goodsDetail.stock) { if (this.goodsDetail.buy_num > this.goodsDetail.stock) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.stockLessThanMin') title: '库存小于最低购买数量'
}); });
return; return;
} }
if (this.number > this.goodsDetail.stock) { if (this.number > this.goodsDetail.stock) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.stockInsufficient') title: '库存不足'
}); });
return; return;
} }
if (this.goodsDetail.is_limit == 1 && this.goodsDetail.limit_type == 1 && this.maxBuy > 0 && this.number > this.maxBuy) { if (this.goodsDetail.is_limit == 1 && this.goodsDetail.limit_type == 1 && this.maxBuy > 0 && this.number > this.maxBuy) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.maxBuyPerOrder') + this.maxBuy + this.goodsDetail.unit title: '该商品每次最多购买' + this.maxBuy + this.goodsDetail.unit
}); });
return; return;
} }
if (this.goodsDetail.is_limit == 1 && this.goodsDetail.limit_type == 2 && this.maxBuy > 0 && if (this.goodsDetail.is_limit == 1 && this.goodsDetail.limit_type == 2 && this.maxBuy > 0 &&
this.number + this.goodsDetail.purchased_num > this.maxBuy) { this.number + this.goodsDetail.purchased_num > this.maxBuy) {
let message = this.$lang('sku.maxBuyPerPerson') + this.maxBuy + this.goodsDetail.unit; let message = '该商品每人限购' + this.maxBuy + this.goodsDetail.unit;
message += this.goodsDetail.purchased_num > 0 ? ',您已购买了' + this.goodsDetail.purchased_num + this.goodsDetail.unit : ''; message += this.goodsDetail.purchased_num > 0 ? ',您已购买了' + this.goodsDetail.purchased_num + this.goodsDetail.unit : '';
this.$util.showToast({ this.$util.showToast({
title: message title: message
@@ -1042,7 +1042,7 @@
if ((this.type == 'join_cart' || isJoinCartBtn) && this.goodsDetail.is_limit == 1 && this.maxBuy > 0 && this.cartNum + this.number > this.maxBuy) { if ((this.type == 'join_cart' || isJoinCartBtn) && this.goodsDetail.is_limit == 1 && this.maxBuy > 0 && this.cartNum + this.number > this.maxBuy) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.maxBuyPerPerson') + this.maxBuy + this.goodsDetail.unit title: '该商品每人限购' + this.maxBuy + this.goodsDetail.unit
}); });
return; return;
} }
@@ -1070,7 +1070,7 @@
var data = res.data; var data = res.data;
if (data > 0) { if (data > 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.addToCartSuccess') title: '加入购物车成功'
}); });
this.cartNum += this.number; this.cartNum += this.number;

View File

@@ -7,34 +7,34 @@
<!-- #ifdef H5 --> <!-- #ifdef H5 -->
<template v-if="forceBindingMobileControl"> <template v-if="forceBindingMobileControl">
<view class="head"> <view class="head">
<text class="title">{{ $lang('loginPage.detectPhoneNotBound') }}</text> <text class="title">检测到您还未绑定手机号</text>
<text class="color-tip tips">{{ $lang('loginPage.bindPhoneForOrder') }}</text> <text class="color-tip tips">为了方便您接收订单等信息,需要绑定手机号</text>
<text class="iconfont icon-close color-tip" @click="cancelCompleteInfo"></text> <text class="iconfont icon-close color-tip" @click="cancelCompleteInfo"></text>
</view> </view>
<view class="item-wrap"> <view class="item-wrap">
<text class="label">{{ $lang('loginPage.phone') }}</text> <text class="label">手机号</text>
<input type="number" :placeholder="$lang('loginPage.phone')" v-model="formData.mobile" maxlength="11" /> <input type="number" placeholder="请输入手机号" v-model="formData.mobile" maxlength="11" />
</view> </view>
<view class="item-wrap" v-if="isOpenCaptcha"> <view class="item-wrap" v-if="isOpenCaptcha">
<text class="label">{{ $lang('loginPage.verificationCode') }}</text> <text class="label">验证码</text>
<input type="number" :placeholder="$lang('loginPage.verificationCode')" v-model="formData.vercode" maxlength="4" /> <input type="number" placeholder="请输入验证码" v-model="formData.vercode" maxlength="4" />
<image :src="captcha.img" class="captcha" @click="getCaptcha" show-menu-by-longpress></image> <image :src="captcha.img" class="captcha" @click="getCaptcha" show-menu-by-longpress></image>
</view> </view>
<view class="item-wrap"> <view class="item-wrap">
<text class="label">{{ $lang('loginPage.dynamicCode') }}</text> <text class="label">动态码</text>
<input type="number" :placeholder="$lang('loginPage.dynamicCode')" v-model="formData.dynacode" maxlength="4" /> <input type="number" placeholder="请输入动态码" v-model="formData.dynacode" maxlength="4" />
<view class="send color-base-text" @click="sendMobileCode">{{ dynacodeData.codeText }} <view class="send color-base-text" @click="sendMobileCode">{{ dynacodeData.codeText }}
</view> </view>
</view> </view>
</template> </template>
<button type="default" class="save-btn" @click="saveH5" :disabled="isDisabled">{{ $lang('loginPage.save') }}</button> <button type="default" class="save-btn" @click="saveH5" :disabled="isDisabled">保存</button>
<!-- #endif --> <!-- #endif -->
<!-- #ifdef MP --> <!-- #ifdef MP -->
<view class="head"> <view class="head">
<text class="title">{{ $lang('loginPage.welcomeTo') }} {{ site_name }}</text> <text class="title">欢迎来到 {{ site_name }}</text>
<text class="color-tip tips"> <text class="color-tip tips">
<template>{{ forceBindingMobileControl ? $lang('loginPage.usePhoneLogin') : $lang('loginPage.registerLogin') }}</template> <template>{{ forceBindingMobileControl ? '使用手机号登录,' : '注册登录,' }}</template>
获得订单、售后等服务。 获得订单、售后等服务。
</text> </text>
<text class="iconfont icon-close color-tip" @click="cancelCompleteInfo"></text> <text class="iconfont icon-close color-tip" @click="cancelCompleteInfo"></text>
@@ -48,9 +48,9 @@
<view style="text-align: left; margin-left: 10rpx; padding-top: 2rpx; font-size: 28rpx;"> <view style="text-align: left; margin-left: 10rpx; padding-top: 2rpx; font-size: 28rpx;">
我同意 我同意
<text style="color: #4395ff;" <text style="color: #4395ff;"
@click="tourl('/pages_tool/agreement/contenr?type=0')">{{ $lang('loginPage.privacyClause') }}</text> @click="tourl('/pages_tool/agreement/contenr?type=0')">《隐私条款》</text>
<text style="color: #4395ff;" <text style="color: #4395ff;"
@click="tourl('/pages_tool/agreement/contenr?type=1')">{{ $lang('loginPage.userAgreement') }}</text> @click="tourl('/pages_tool/agreement/contenr?type=1')">《用户服务协议》</text>
</view> </view>
</view> </view>
@@ -58,25 +58,25 @@
<block v-if="isAgree"> <block v-if="isAgree">
<button class="auth-login save-btn border-0" style="border: none;" open-type="getPhoneNumber" <button class="auth-login save-btn border-0" style="border: none;" open-type="getPhoneNumber"
@getphonenumber="getPhoneNumber"> @getphonenumber="getPhoneNumber">
<text style="color: #fff; font-size: 30rpx;">{{ $lang('loginPage.agreePrivacyAndAuth') }}</text> <text style="color: #fff; font-size: 30rpx;">同意隐私协议并授权手机号</text>
</button> </button>
</block> </block>
<block v-else> <block v-else>
<button class="auth-login save-btn border-0" style="border: none;" @click="authno"> <button class="auth-login save-btn border-0" style="border: none;" @click="authno">
<text style="color: #fff; font-size: 30rpx;">{{ $lang('loginPage.authPhoneNumber') }}</text> <text style="color: #fff; font-size: 30rpx;">授权手机号码</text>
</button> </button>
</block> </block>
<view @click="closeLogin" <view @click="closeLogin"
style="font-size: 30rpx; color: #888; text-align: center; padding-top: 10rpx;"> style="font-size: 30rpx; color: #888; text-align: center; padding-top: 10rpx;">
{{ $lang('loginPage.notNow') }} 暂不登录
</view> </view>
<!-- 昵称和头像模式 --> <!-- 昵称和头像模式 -->
<template v-if="enableNickAndAvatar"> <template v-if="enableNickAndAvatar">
<!-- #ifdef MP-WEIXIN --> <!-- #ifdef MP-WEIXIN -->
<view class="item-wrap"> <view class="item-wrap">
<text class="label">{{ $lang('loginPage.avatar') }}</text> <text class="label">头像</text>
<button open-type="chooseAvatar" @chooseavatar="onChooseAvatar"> <button open-type="chooseAvatar" @chooseavatar="onChooseAvatar">
<image :src="avatarUrl ? avatarUrl : $util.getDefaultImage().head" <image :src="avatarUrl ? avatarUrl : $util.getDefaultImage().head"
@error="avatarUrl = $util.getDefaultImage().head" mode="aspectFill" show-menu-by-longpress/> @error="avatarUrl = $util.getDefaultImage().head" mode="aspectFill" show-menu-by-longpress/>
@@ -84,15 +84,15 @@
</button> </button>
</view> </view>
<view class="item-wrap"> <view class="item-wrap">
<text class="label">{{ $lang('loginPage.nickname') }}</text> <text class="label">昵称</text>
<input type="nickname" :placeholder="$lang('loginPage.nickname')" v-model="nickName" @blur="blurNickName" <input type="nickname" placeholder="请输入昵称" v-model="nickName" @blur="blurNickName"
maxlength="50" /> maxlength="50" />
</view> </view>
<!-- #endif --> <!-- #endif -->
<!-- #ifdef MP-ALIPAY --> <!-- #ifdef MP-ALIPAY -->
<view class="item-wrap"> <view class="item-wrap">
<text class="label">{{ $lang('loginPage.avatar') }}</text> <text class="label">头像</text>
<button open-type="getAuthorize" scope="userInfo" @getAuthorize="aliappGetUserinfo" <button open-type="getAuthorize" scope="userInfo" @getAuthorize="aliappGetUserinfo"
:plain="true" class="border-0"> :plain="true" class="border-0">
<image :src="avatarUrl ? avatarUrl : $util.getDefaultImage().head" <image :src="avatarUrl ? avatarUrl : $util.getDefaultImage().head"
@@ -101,21 +101,21 @@
</button> </button>
</view> </view>
<view class="item-wrap"> <view class="item-wrap">
<text class="label">{{ $lang('loginPage.nickname') }}</text> <text class="label">昵称</text>
<input type="nickname" :placeholder="$lang('loginPage.nickname')" v-model="nickName" @blur="blurNickName" <input type="nickname" placeholder="请输入昵称" v-model="nickName" @blur="blurNickName"
maxlength="50" /> maxlength="50" />
</view> </view>
<!-- #endif --> <!-- #endif -->
<view class="item-wrap" v-if="forceBindingMobileControl"> <view class="item-wrap" v-if="forceBindingMobileControl">
<text class="label">{{ $lang('loginPage.phone') }}</text> <text class="label">手机号</text>
<button open-type="getPhoneNumber" :plain="true" class="auth-login border-0" <button open-type="getPhoneNumber" :plain="true" class="auth-login border-0"
@getphonenumber="getPhoneNumber"> @getphonenumber="getPhoneNumber">
<text class="mobile" v-if="formData.mobile">{{ formData.mobile }}</text> <text class="mobile" v-if="formData.mobile">{{ formData.mobile }}</text>
<text class="color-base-text" v-else>{{ $lang('loginPage.getPhone') }}</text> <text class="color-base-text" v-else>获取手机号</text>
</button> </button>
</view> </view>
<button type="default" class="save-btn" @click="saveMp" :disabled="isDisabled">{{ $lang('loginPage.save') }}</button> <button type="default" class="save-btn" @click="saveMp" :disabled="isDisabled">保存</button>
</template> </template>
<!-- #endif --> <!-- #endif -->
</view> </view>
@@ -166,7 +166,7 @@ export default {
dynacodeData: { dynacodeData: {
seconds: 120, seconds: 120,
timer: null, timer: null,
codeText: this.$lang('loginPage.dynamicCode'), codeText: '获取动态码',
isSend: false isSend: false
}, },
// 小程序获取手机号所需数据 // 小程序获取手机号所需数据
@@ -228,7 +228,7 @@ export default {
// 同意协议 // 同意协议
authno() { authno() {
if (!this.isAgree) { if (!this.isAgree) {
this.$util.showToast({ title: this.$lang('loginPage.confirmAgreement') }); this.$util.showToast({ title: '请确认相关协议' });
} }
}, },
@@ -324,7 +324,7 @@ export default {
}, },
fail: () => { fail: () => {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('loginPage.uploadFailed') title: '上传失败'
}); });
} }
}) })
@@ -386,17 +386,17 @@ export default {
var rule = [{ var rule = [{
name: 'mobile', name: 'mobile',
checkType: 'required', checkType: 'required',
errorMsg: this.$lang('loginPage.phoneRequired') errorMsg: '请输入手机号'
}, { }, {
name: 'mobile', name: 'mobile',
checkType: 'phoneno', checkType: 'phoneno',
errorMsg: this.$lang('loginPage.phoneInvalid') errorMsg: '请输入正确的手机号'
}]; }];
if (this.isOpenCaptcha == 1) { if (this.isOpenCaptcha == 1) {
rule.push({ rule.push({
name: 'captcha_code', name: 'captcha_code',
checkType: 'required', checkType: 'required',
errorMsg: this.$lang('loginPage.verificationCodeRequired') errorMsg: '请输入验证码'
}); });
} }
var checkRes = validate.check(data, rule); var checkRes = validate.check(data, rule);
@@ -444,7 +444,7 @@ export default {
this.dynacodeData = { this.dynacodeData = {
seconds: 120, seconds: 120,
timer: null, timer: null,
codeText: this.$lang('loginPage.dynamicCode'), codeText: '获取动态码',
isSend: false isSend: false
}; };
}, },
@@ -455,23 +455,23 @@ export default {
let rule = [{ let rule = [{
name: 'mobile', name: 'mobile',
checkType: 'required', checkType: 'required',
errorMsg: this.$lang('loginPage.phoneRequired') errorMsg: '请输入手机号'
}, { }, {
name: 'mobile', name: 'mobile',
checkType: 'phoneno', checkType: 'phoneno',
errorMsg: this.$lang('loginPage.phoneInvalid') errorMsg: '请输入正确的手机号'
}]; }];
if (this.isOpenCaptcha == 1) { if (this.isOpenCaptcha == 1) {
if (this.captcha.id != '') rule.push({ if (this.captcha.id != '') rule.push({
name: 'captcha_code', name: 'captcha_code',
checkType: 'required', checkType: 'required',
errorMsg: this.$lang('loginPage.verificationCodeRequired') errorMsg: '请输入验证码'
}); });
} }
rule.push({ rule.push({
name: 'code', name: 'code',
checkType: 'required', checkType: 'required',
errorMsg: this.$lang('loginPage.dynamicCodeRequired') errorMsg: '请输入动态码'
}); });
var checkRes = validate.check(data, rule); var checkRes = validate.check(data, rule);
@@ -603,7 +603,7 @@ export default {
// 授权登录 // 授权登录
authLogin(data, type = 'authLogin') { authLogin(data, type = 'authLogin') {
uni.showLoading({ uni.showLoading({
title: this.$lang('loginPage.loggingIn') title: '登录中'
}); });
uni.setStorageSync('authInfo', data); uni.setStorageSync('authInfo', data);
if (uni.getStorageSync('source_member')) data.source_member = uni.getStorageSync('source_member'); if (uni.getStorageSync('source_member')) data.source_member = uni.getStorageSync('source_member');
@@ -643,7 +643,7 @@ export default {
fail: () => { fail: () => {
uni.hideLoading(); uni.hideLoading();
this.$util.showToast({ this.$util.showToast({
title: this.$lang('loginPage.loginFailed') title: '登录失败'
}); });
} }
}); });
@@ -669,12 +669,12 @@ export default {
// 微信小程序保存数据 // 微信小程序保存数据
saveMp() { saveMp() {
if (this.formData.mobile === '') { if (this.formData.mobile === '') {
this.$util.showToast({ title: this.$lang('loginPage.phoneAuthRequired') }); this.$util.showToast({ title: '请授权您的手机号码' });
return; return;
} }
if (this.nickName.length == 0 && this.enableNickAndAvatar) { if (this.nickName.length == 0 && this.enableNickAndAvatar) {
this.$util.showToast({ title: this.$lang('loginPage.nicknameRequired') }); this.$util.showToast({ title: '请输入昵称' });
return; return;
} }
@@ -715,7 +715,7 @@ export default {
}, },
fail: () => { fail: () => {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('loginPage.avatarFetchFailed') title: '头像拉取失败'
}); });
} }
}) })

View File

@@ -28,7 +28,7 @@
</view> </view>
<view class="search" @click="$util.redirectTo('/pages_tool/goods/search')" :style="{ height: menuButtonInfo.height - 2 + 'px', lineHeight: menuButtonInfo.height - 2 + 'px' }"> <view class="search" @click="$util.redirectTo('/pages_tool/goods/search')" :style="{ height: menuButtonInfo.height - 2 + 'px', lineHeight: menuButtonInfo.height - 2 + 'px' }">
<text class="iconfont icon-sousuo3"></text> <text class="iconfont icon-sousuo3"></text>
<text>{{ $lang('goods.searchGoods') }}</text> <text>请输入商品名称</text>
</view> </view>
<view :style="{ 'width': capsuleWidth }"></view> <view :style="{ 'width': capsuleWidth }"></view>
</view> </view>
@@ -36,9 +36,9 @@
<view v-if="data.navStyle == 4" class="content-wrap" :class="{ 'have-back': isBack && isBackShow }" @click="chooseOtherStore()"> <view v-if="data.navStyle == 4" class="content-wrap" :class="{ 'have-back': isBack && isBackShow }" @click="chooseOtherStore()">
<text class="iconfont icon-dizhi" :style="{ color: data.textNavColor }"></text> <text class="iconfont icon-dizhi" :style="{ color: data.textNavColor }"></text>
<view v-if="globalStoreInfo && globalStoreInfo.store_id" class="title-wrap" :style="{ color: data.textNavColor }">{{ globalStoreInfo.store_name }}</view> <view v-if="globalStoreInfo && globalStoreInfo.store_id" class="title-wrap" :style="{ color: data.textNavColor }">{{ globalStoreInfo.store_name }}</view>
<view v-else class="title-wrap" :style="{ color: data.textNavColor }">{{ $lang('store.locating') }}</view> <view v-else class="title-wrap" :style="{ color: data.textNavColor }">定位中...</view>
<text class="iconfont icon-right" :style="{ color: data.textNavColor }"></text> <text class="iconfont icon-right" :style="{ color: data.textNavColor }"></text>
<view class="nearby-store-name" :style="{ color: data.textNavColor }">{{ $lang('store.nearbyStore') }}</view> <view class="nearby-store-name" :style="{ color: data.textNavColor }">附近门店</view>
</view> </view>
</view> </view>
</view> </view>

View File

@@ -11,7 +11,7 @@
<view :class="['box', 'align-left']" :style="item._boxAlignStyle"> <view :class="['box', 'align-left']" :style="item._boxAlignStyle">
<input <input
type="text" type="text"
:placeholder="item.value.placeholder || $lang('form.inputPlaceholder')" :placeholder="item.value.placeholder || '请输入提示语'"
placeholder-class="placeholder color-tip" placeholder-class="placeholder color-tip"
v-model="item.val" v-model="item.val"
/> />
@@ -28,7 +28,7 @@
</view> </view>
<view :class="['box', 'align-left']" :style="item._boxAlignStyle"> <view :class="['box', 'align-left']" :style="item._boxAlignStyle">
<textarea <textarea
:placeholder="item.value.placeholder || $lang('form.inputPlaceholder')" :placeholder="item.value.placeholder || '请输入提示语'"
placeholder-class="placeholder color-tip" placeholder-class="placeholder color-tip"
v-model="item.val" v-model="item.val"
></textarea> ></textarea>
@@ -50,7 +50,7 @@
</view> </view>
<view :class="['box', 'box-flex', 'align-right']"> <view :class="['box', 'box-flex', 'align-right']">
<text v-if="item.val != ''">{{ item.val }}</text> <text v-if="item.val != ''">{{ item.val }}</text>
<text v-else class="color-tip">{{ item.value.placeholder || $lang('form.selectPlaceholder') }}</text> <text v-else class="color-tip">{{ item.value.placeholder || '请选择' }}</text>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
</view> </view>
</view> </view>
@@ -146,7 +146,7 @@
@change="bindDateChange($event, index)" @change="bindDateChange($event, index)"
> >
<view :class="['uni-input', !item.val ? 'color-tip' : '']"> <view :class="['uni-input', !item.val ? 'color-tip' : '']">
{{ item.val ? item.val : (item.value.placeholder || $lang('form.selectDate')) }} {{ item.val ? item.val : (item.value.placeholder || '请选择日期') }}
</view> </view>
</picker> </picker>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
@@ -170,7 +170,7 @@
> >
<view class="picker-box"> <view class="picker-box">
<view :class="['uni-input', !item.start_date ? 'color-tip' : '']"> <view :class="['uni-input', !item.start_date ? 'color-tip' : '']">
{{ item.start_date ? item.start_date : (item.value.placeholder_start || $lang('form.startDate')) }} {{ item.start_date ? item.start_date : (item.value.placeholder_start || '开始日期') }}
</view> </view>
</view> </view>
</picker> </picker>
@@ -184,7 +184,7 @@
> >
<view class="picker-box"> <view class="picker-box">
<view :class="['uni-input', !item.end_date ? 'color-tip' : '']"> <view :class="['uni-input', !item.end_date ? 'color-tip' : '']">
{{ item.end_date ? item.end_date : (item.value.placeholder_end || $lang('form.endDate')) }} {{ item.end_date ? item.end_date : (item.value.placeholder_end || '结束日期') }}
</view> </view>
</view> </view>
</picker> </picker>
@@ -207,7 +207,7 @@
@change="bindTimeChange($event, index)" @change="bindTimeChange($event, index)"
> >
<view :class="['uni-input', !item.val ? 'color-tip' : '']"> <view :class="['uni-input', !item.val ? 'color-tip' : '']">
{{ item.val ? item.val : (item.value.placeholder || $lang('form.selectTime')) }} {{ item.val ? item.val : (item.value.placeholder || '请选择时间') }}
</view> </view>
</picker> </picker>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
@@ -231,7 +231,7 @@
> >
<view class="picker-box"> <view class="picker-box">
<view :class="['uni-input', !item.start_time ? 'color-tip' : '']"> <view :class="['uni-input', !item.start_time ? 'color-tip' : '']">
{{ item.start_time ? item.start_time : (item.value.placeholder_start || $lang('form.startTime')) }} {{ item.start_time ? item.start_time : (item.value.placeholder_start || '开始时间') }}
</view> </view>
</view> </view>
</picker> </picker>
@@ -245,7 +245,7 @@
> >
<view class="picker-box"> <view class="picker-box">
<view :class="['uni-input', !item.end_time ? 'color-tip' : '']"> <view :class="['uni-input', !item.end_time ? 'color-tip' : '']">
{{ item.end_time ? item.end_time : (item.value.placeholder_end || $lang('form.endTime')) }} {{ item.end_time ? item.end_time : (item.value.placeholder_end || '结束时间') }}
</view> </view>
</view> </view>
</picker> </picker>
@@ -268,7 +268,7 @@
@getRegions="handleGetRegions($event, index)" @getRegions="handleGetRegions($event, index)"
> >
<view :class="['select-address', !item.val ? 'empty' : '', !item.val ? 'color-tip' : '']"> <view :class="['select-address', !item.val ? 'empty' : '', !item.val ? 'color-tip' : '']">
{{ item.val ? item.val : (item.value.placeholder || (item.value.default_type == 1 ? $lang('form.selectProvinceCity') : $lang('form.selectProvinceCityDistrict'))) }} {{ item.val ? item.val : (item.value.placeholder || (item.value.default_type == 1 ? '请选择省市' : '请选择省市区')) }}
</view> </view>
</pick-regions> </pick-regions>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
@@ -788,89 +788,89 @@ export default {
if (item.controller == 'Text') { if (item.controller == 'Text') {
if (item.value.required && !item.val) { if (item.value.required && !item.val) {
this.$util.showToast({ title: this.$lang('form.inputRequired') + item.value.title }); this.$util.showToast({ title: '请输入' + item.value.title });
return false; return false;
} }
if (item.name == 'ID_CARD' && !/(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/.test(item.val)) { if (item.name == 'ID_CARD' && !/(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/.test(item.val)) {
if (!item.value.required) { if (!item.value.required) {
this.$util.showToast({ title: this.$lang('form.idCardInvalid') }); this.$util.showToast({ title: '身份证输入不合法' });
return false; return false;
} }
if (item.val != '') { if (item.val != '') {
this.$util.showToast({ title: this.$lang('form.idCardInvalid') }); this.$util.showToast({ title: '身份证输入不合法' });
return false; return false;
} }
} }
if (item.name == 'MOBILE' && !this.$util.verifyMobile(item.val)) { if (item.name == 'MOBILE' && !this.$util.verifyMobile(item.val)) {
if (!item.value.required) { if (!item.value.required) {
this.$util.showToast({ title: this.$lang('form.phoneInvalid') }); this.$util.showToast({ title: '手机号输入不合法' });
return false; return false;
} }
if (item.val != '') { if (item.val != '') {
this.$util.showToast({ title: this.$lang('form.phoneInvalid') }); this.$util.showToast({ title: '手机号输入不合法' });
return false; return false;
} }
} }
} }
if (item.controller == 'Textarea' && item.value.required && !item.val) { if (item.controller == 'Textarea' && item.value.required && !item.val) {
this.$util.showToast({ title: this.$lang('form.inputRequired') + item.value.title }); this.$util.showToast({ title: '请输入' + item.value.title });
return false; return false;
} }
if (item.controller == 'Select' && item.value.required && !item.val) { if (item.controller == 'Select' && item.value.required && !item.val) {
this.$util.showToast({ title: this.$lang('form.selectRequired') + item.value.title }); this.$util.showToast({ title: '请选择' + item.value.title });
return false; return false;
} }
if (item.controller == 'Checkbox' && item.value.required && !item.val) { if (item.controller == 'Checkbox' && item.value.required && !item.val) {
this.$util.showToast({ title: this.$lang('form.selectAtLeastOne') + item.value.title }); this.$util.showToast({ title: '请至少选择一个' + item.value.title });
return false; return false;
} }
if (item.controller == 'Img' && item.value.required && !item.val) { if (item.controller == 'Img' && item.value.required && !item.val) {
this.$util.showToast({ title: this.$lang('form.uploadAtLeastOne') + item.value.title }); this.$util.showToast({ title: '请至少上传一张' + item.value.title });
return false; return false;
} }
if (item.controller == 'Date' && item.value.required && !item.val) { if (item.controller == 'Date' && item.value.required && !item.val) {
this.$util.showToast({ title: this.$lang('form.selectRequired') + item.value.title }); this.$util.showToast({ title: '请选择' + item.value.title });
return false; return false;
} }
if (item.controller == 'Datelimit') { if (item.controller == 'Datelimit') {
if (item.value.required && !item.val) { if (item.value.required && !item.val) {
this.$util.showToast({ title: this.$lang('form.selectRequired') + item.value.title }); this.$util.showToast({ title: '请选择' + item.value.title });
return false; return false;
} }
if (this.$util.timeTurnTimeStamp(item.start_date) > this.$util.timeTurnTimeStamp(item.end_date)) { if (this.$util.timeTurnTimeStamp(item.start_date) > this.$util.timeTurnTimeStamp(item.end_date)) {
this.$util.showToast({ title: this.$lang('form.endDateBeforeStart') }); this.$util.showToast({ title: '结束日期不能小于开始日期' });
return false; return false;
} }
} }
if (item.controller == 'Time' && item.value.required && !item.val) { if (item.controller == 'Time' && item.value.required && !item.val) {
this.$util.showToast({ title: this.$lang('form.selectRequired') + item.value.title }); this.$util.showToast({ title: '请选择' + item.value.title });
return false; return false;
} }
if (item.controller == 'Timelimit') { if (item.controller == 'Timelimit') {
if (item.value.required && !item.val) { if (item.value.required && !item.val) {
this.$util.showToast({ title: this.$lang('form.selectRequired') + item.value.title }); this.$util.showToast({ title: '请选择' + item.value.title });
return false; return false;
} }
if (item.start_time >= item.end_time) { if (item.start_time >= item.end_time) {
this.$util.showToast({ title: this.$lang('form.endTimeBeforeStart') }); this.$util.showToast({ title: '结束时间必须大于开始时间' });
return false; return false;
} }
} }
if (item.controller == 'City' && item.value.required && !item.val) { if (item.controller == 'City' && item.value.required && !item.val) {
this.$util.showToast({ title: this.$lang('form.selectRequired') + item.value.title }); this.$util.showToast({ title: '请选择' + item.value.title });
return false; return false;
} }
} }
@@ -902,7 +902,7 @@ export default {
if (res.length > 0) { if (res.length > 0) {
res.forEach(function(img) { res.forEach(function(img) {
if (self.formData[index].img_lists.length >= Number(self.formData[index].value.max_count)) { if (self.formData[index].img_lists.length >= Number(self.formData[index].value.max_count)) {
self.$util.showToast({ title: this.$lang('form.maxUploadImages') + self.formData[index].value.max_count + this.$lang('form.images') }); self.$util.showToast({ title: '最多上传' + self.formData[index].value.max_count + '张图片' });
return false; return false;
} }
self.formData[index].img_lists.push(img); self.formData[index].img_lists.push(img);
@@ -916,7 +916,7 @@ export default {
addImg(index) { addImg(index) {
let self = this; let self = this;
if (this.formData[index].img_lists.length >= Number(this.formData[index].value.max_count)) { if (this.formData[index].img_lists.length >= Number(this.formData[index].value.max_count)) {
this.$util.showToast({ title: this.$lang('form.maxUploadImages') + this.formData[index].value.max_count + this.$lang('form.images') }); this.$util.showToast({ title: '最多上传' + this.formData[index].value.max_count + '张图片' });
return false; return false;
} }

View File

@@ -4,19 +4,19 @@
<uni-popup ref="choosePaymentPopup" type="center" :mask-click="false"> <uni-popup ref="choosePaymentPopup" type="center" :mask-click="false">
<view class="choose-payment-popup popup" @touchmove.prevent.stop> <view class="choose-payment-popup popup" @touchmove.prevent.stop>
<view class="popup-header"> <view class="popup-header">
<text class="tit">{{ $lang('payment.paymentMethod') }}</text> <text class="tit">支付方式</text>
<text class="iconfont icon-close" @click="close()"></text> <text class="iconfont icon-close" @click="close()"></text>
</view> </view>
<scroll-view scroll-y="true" class="popup-body" :class="{ 'safe-area': isIphoneX }"> <scroll-view scroll-y="true" class="popup-body" :class="{ 'safe-area': isIphoneX }">
<view class="pay-money"> <view class="pay-money">
<!-- <text class="unit">{{ $lang('common.currencySymbol') }}</text> --> <!-- <text class="unit">{{ $lang('common.currencySymbol') }}</text> -->
<text class="money">{{ $lang('payment.paymentAmount') }}{{ payMoney | moneyFormat }}{{ $lang('sku.unit') }}</text> <text class="money">支付金额{{ payMoney | moneyFormat }}元</text>
</view> </view>
<view class="payment-item" v-if="balanceDeduct > 0 && balanceConfig == 1 && sale"> <view class="payment-item" v-if="balanceDeduct > 0 && balanceConfig == 1 && sale">
<view class="iconfont icon-yue"></view> <view class="iconfont icon-yue"></view>
<view class="info-wrap"> <view class="info-wrap">
<text class="name">{{ $lang('payment.balanceDeduct') }}</text> <text class="name">余额抵扣</text>
<view class="money">{{ $lang('payment.available') }}¥{{ balanceDeduct }}</view> <view class="money">可用¥{{ balanceDeduct }}</view>
</view> </view>
<ns-switch class="balance-switch" @change="useBalance" :checked="isBalance == 1"></ns-switch> <ns-switch class="balance-switch" @change="useBalance" :checked="isBalance == 1"></ns-switch>
</view> </view>
@@ -31,12 +31,12 @@
</view> </view>
</block> </block>
<block v-else> <block v-else>
<view class="empty">{{ $lang('payment.noPaymentMethod') }}</view> <view class="empty">平台尚未配置支付方式!</view>
</block> </block>
</block> </block>
</scroll-view> </scroll-view>
<view class="popup-footer" :class="{ 'bottom-safe-area': isIphoneX }"> <view class="popup-footer" :class="{ 'bottom-safe-area': isIphoneX }">
<view class="confirm-btn color-base-bg" @click="confirm()">{{ $lang('payment.confirmPayment') }}</view> <view class="confirm-btn color-base-bg" @click="confirm()">确认支付</view>
</view> </view>
</view> </view>
</uni-popup> </uni-popup>
@@ -72,12 +72,12 @@ export default {
payIndex: 0, payIndex: 0,
// #ifdef H5 // #ifdef H5
payTypeList: [{ payTypeList: [{
name: this.$lang('payment.alipayPay'), name: '支付宝支付',
icon: 'icon-zhifubaozhifu-', icon: 'icon-zhifubaozhifu-',
type: 'alipay' type: 'alipay'
}, },
{ {
name: this.$lang('payment.wechatPay'), name: '微信支付',
icon: 'icon-weixin1', icon: 'icon-weixin1',
type: 'wechatpay' type: 'wechatpay'
} }
@@ -86,7 +86,7 @@ export default {
// #endif // #endif
// #ifdef MP-WEIXIN // #ifdef MP-WEIXIN
payTypeList: [{ payTypeList: [{
name: this.$lang('payment.wechatPay'), name: '微信支付',
provider: 'wxpay', provider: 'wxpay',
icon: 'icon-weixin1', icon: 'icon-weixin1',
type: 'wechatpay' type: 'wechatpay'
@@ -95,7 +95,7 @@ export default {
// #endif // #endif
// #ifdef MP-ALIPAY // #ifdef MP-ALIPAY
payTypeList: [{ payTypeList: [{
name: this.$lang('payment.alipayPay'), name: '支付宝支付',
icon: 'icon-zhifubaozhifu-', icon: 'icon-zhifubaozhifu-',
type: 'alipay', type: 'alipay',
provider: 'alipay' provider: 'alipay'
@@ -158,12 +158,12 @@ export default {
confirm() { confirm() {
if (this.payTypeList.length == 0 && this.payMoney > 0) { if (this.payTypeList.length == 0 && this.payMoney > 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.selectPaymentMethod') title: '请选择支付方式!'
}); });
return; return;
} }
uni.showLoading({ uni.showLoading({
title: this.$lang('payment.paying'), title: '支付中...',
mask: true mask: true
}); });
this.$refs.choosePaymentPopup.close(); this.$refs.choosePaymentPopup.close();
@@ -182,7 +182,7 @@ export default {
this.pay(); this.pay();
} else { } else {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.noPaymentInfo') title: '未获取到支付信息!'
}); });
setTimeout(() => { setTimeout(() => {
this.$util.redirectTo(this.$util.INDEX_PAGE_URL); this.$util.redirectTo(this.$util.INDEX_PAGE_URL);
@@ -295,7 +295,7 @@ export default {
}, },
res => { res => {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.cancelledPayment') title: '您已取消支付'
}); });
setTimeout(() => { setTimeout(() => {
this.$util.redirectTo('/pages_tool/pay/result', { this.$util.redirectTo('/pages_tool/pay/result', {
@@ -392,10 +392,10 @@ export default {
fail: res => { fail: res => {
this.flag = false; this.flag = false;
if (res.errMsg == 'requestOrderPayment:fail cancel') { if (res.errMsg == 'requestOrderPayment:fail cancel') {
this.$util.showToast({ title: this.$lang('payment.payCancel') }); this.$util.showToast({ title: '您已取消支付' });
} else { } else {
uni.showModal({ uni.showModal({
content: this.$lang('payment.payFail') + ', ' + this.$lang('payment.errorReason') + res.errMsg, content: '支付失败,失败原因: ' + res.errMsg,
showCancel: false showCancel: false
}); });
} }
@@ -428,10 +428,10 @@ export default {
fail: res => { fail: res => {
this.flag = false; this.flag = false;
if (res.errMsg == 'requestPayment:fail cancel') { if (res.errMsg == 'requestPayment:fail cancel') {
this.$util.showToast({ title: this.$lang('payment.payCancel') }); this.$util.showToast({ title: '您已取消支付' });
} else { } else {
uni.showModal({ uni.showModal({
content: this.$lang('payment.payFail') + ', ' + this.$lang('payment.errorReason') + res.errMsg, content: '支付失败,失败原因: ' + res.errMsg,
showCancel: false showCancel: false
}); });
} }

View File

@@ -3,8 +3,8 @@
<uni-popup type="bottom" ref="selectTime"> <uni-popup type="bottom" ref="selectTime">
<view class="box"> <view class="box">
<view class="title"> <view class="title">
<block v-if="obj.delivery && obj.delivery.delivery_type == 'local'">{{ $lang('appointment.selectDeliveryTime') }}</block> <block v-if="obj.delivery && obj.delivery.delivery_type == 'local'">选择送达时间</block>
<block v-if="obj.delivery && obj.delivery.delivery_type == 'store'">{{ $lang('appointment.selectPickupTime') }}</block> <block v-if="obj.delivery && obj.delivery.delivery_type == 'store'">选择自提时间</block>
<text class="iconfont icon-close" @click="close"></text> <text class="iconfont icon-close" @click="close"></text>
</view> </view>
<view class="body"> <view class="body">
@@ -145,7 +145,7 @@ export default {
let num = 1; //记录循环执行过的次数 let num = 1; //记录循环执行过的次数
let mostDay = this.obj.dataTime.most_day ? this.obj.dataTime.most_day + 1 : 1; // 最多可预约天数 let mostDay = this.obj.dataTime.most_day ? this.obj.dataTime.most_day + 1 : 1; // 最多可预约天数
let startTime = parseInt(today.getTime() / 1000); let startTime = parseInt(today.getTime() / 1000);
let week = [this.$lang('date.sunday'), this.$lang('date.monday'), this.$lang('date.tuesday'), this.$lang('date.wednesday'), this.$lang('date.thursday'), this.$lang('date.friday'), this.$lang('date.saturday')]; let week = ['周日', '周一', '周二', '周三', '周四', '周五', '周六'];
if (obj.time_week && obj.time_week.length == 7) { if (obj.time_week && obj.time_week.length == 7) {
//判断是否七天全有 //判断是否七天全有
judge = true; judge = true;
@@ -170,9 +170,9 @@ export default {
i = i - 1; i = i - 1;
} else { } else {
objects = { objects = {
title: this.obj.dataTime.advance_day == 0 ? this.$lang('date.today') : '', title: this.obj.dataTime.advance_day == 0 ? '今天' : '',
type: 'special', type: 'special',
month: nowMonth + this.$lang('date.month') + nowDate + this.$lang('date.day'), month: nowMonth + '月' + nowDate + '日',
Day: '(' + dayStr + ')' Day: '(' + dayStr + ')'
}; };
this.dayData.push(objects); //左侧日期数据处理 this.dayData.push(objects); //左侧日期数据处理
@@ -182,8 +182,8 @@ export default {
case 2: case 2:
if (i == 0 || i == 1) { if (i == 0 || i == 1) {
objects = { objects = {
title: this.obj.dataTime.advance_day == 0 ? this.$lang('date.tomorrow') : '', title: this.obj.dataTime.advance_day == 0 ? '明天' : '',
month: nowMonth + this.$lang('date.month') + nowDate + this.$lang('date.day'), month: nowMonth + '月' + nowDate + '日',
Day: '(' + dayStr + ')' Day: '(' + dayStr + ')'
}; };
this.dayData.push(objects); //左侧日期数据处理 this.dayData.push(objects); //左侧日期数据处理
@@ -192,7 +192,7 @@ export default {
default: default:
objects = { objects = {
title: '', title: '',
month: nowMonth + this.$lang('date.month') + nowDate + this.$lang('date.day'), month: nowMonth + '月' + nowDate + '日',
Day: '(' + dayStr + ')' Day: '(' + dayStr + ')'
}; };
this.dayData.push(objects); //左侧日期数据处理 this.dayData.push(objects); //左侧日期数据处理
@@ -267,7 +267,7 @@ export default {
if (time <= item.end_time) { if (time <= item.end_time) {
let text = ''; let text = '';
if (this.obj.delivery.delivery_type == 'local' && i == 0) { if (this.obj.delivery.delivery_type == 'local' && i == 0) {
text = this.$lang('delivery.immediate') + '('+ this.$util.getTimeStr(time) + '-' + this.$util.getTimeStr(time + timeInterval) + ')'; text = '立即配送('+ this.$util.getTimeStr(time) + '-' + this.$util.getTimeStr(time + timeInterval) + ')';
} else { } else {
text = this.$util.getTimeStr(time) + '-' + this.$util.getTimeStr(time + timeInterval); text = this.$util.getTimeStr(time) + '-' + this.$util.getTimeStr(time + timeInterval);
} }

View File

@@ -14,7 +14,7 @@
autoplay autoplay
class="video-player" class="video-player"
></video> ></video>
<view v-else class="video-error">{{ $lang('video.videoNotFound') }}</view> <view v-else class="video-error">视频地址不存在</view>
</view> </view>
</view> </view>
</uni-popup> </uni-popup>

View File

@@ -4,19 +4,19 @@
<uni-popup ref="choosePaymentPopup" type="center" v-if="payInfo" :mask-click="false"> <uni-popup ref="choosePaymentPopup" type="center" v-if="payInfo" :mask-click="false">
<view class="choose-payment-popup popup" @touchmove.prevent.stop> <view class="choose-payment-popup popup" @touchmove.prevent.stop>
<view class="popup-header"> <view class="popup-header">
<text class="tit">{{ $lang('payment.paymentMethod') }}</text> <text class="tit">支付方式</text>
<text class="iconfont icon-close" @click="close()"></text> <text class="iconfont icon-close" @click="close()"></text>
</view> </view>
<scroll-view scroll-y="true" class="popup-body"> <scroll-view scroll-y="true" class="popup-body">
<view class="pay-money"> <view class="pay-money">
<text class="money">{{ $lang('payment.paymentAmount') }}{{ payMoney|moneyFormat }}{{ $lang('sku.unit') }}</text> <text class="money">支付金额{{ payMoney|moneyFormat }}元</text>
</view> </view>
<view class="payment-item" v-if="balanceDeduct > 0 && balanceUsable && balanceConfig == 1"> <view class="payment-item" v-if="balanceDeduct > 0 && balanceUsable && balanceConfig == 1">
<view class="iconfont icon-yue"></view> <view class="iconfont icon-yue"></view>
<view class="info-wrap"> <view class="info-wrap">
<text class="name">{{ $lang('payment.balancePayment') }}</text> <text class="name">余额支付</text>
<view class="money">{{ $lang('payment.available') }}¥{{ balanceDeduct|moneyFormat }}</view> <view class="money">可用¥{{ balanceDeduct|moneyFormat }}</view>
</view> </view>
<ns-switch class="balance-switch" @change="useBalance" :checked="isBalance == 1"></ns-switch> <ns-switch class="balance-switch" @change="useBalance" :checked="isBalance == 1"></ns-switch>
</view> </view>
@@ -29,12 +29,12 @@
</view> </view>
</block> </block>
<block v-else> <block v-else>
<view class="empty">{{ $lang('payment.noPaymentMethod') }}</view> <view class="empty">平台尚未配置支付方式!</view>
</block> </block>
</block> </block>
</scroll-view> </scroll-view>
<view class="popup-footer"> <view class="popup-footer">
<view class="confirm-btn color-base-bg" @click="confirm()">{{ $lang('payment.confirmPayment') }}</view> <view class="confirm-btn color-base-bg" @click="confirm()">确认支付</view>
</view> </view>
</view> </view>
</uni-popup> </uni-popup>
@@ -63,12 +63,12 @@
payIndex: 0, payIndex: 0,
// #ifdef H5 // #ifdef H5
payTypeList: [{ payTypeList: [{
name: this.$lang('payment.alipayPay'), name: '支付宝支付',
icon: 'icon-zhifubaozhifu-', icon: 'icon-zhifubaozhifu-',
type: 'alipay' type: 'alipay'
}, },
{ {
name: this.$lang('payment.wechatPay'), name: '微信支付',
icon: 'icon-weixin1', icon: 'icon-weixin1',
type: 'wechatpay' type: 'wechatpay'
} }
@@ -77,7 +77,7 @@
// #endif // #endif
// #ifdef MP-WEIXIN // #ifdef MP-WEIXIN
payTypeList: [{ payTypeList: [{
name: this.$lang('payment.wechatPay'), name: '微信支付',
provider: 'wxpay', provider: 'wxpay',
icon: 'icon-weixin1', icon: 'icon-weixin1',
type: 'wechatpay' type: 'wechatpay'
@@ -85,7 +85,7 @@
// #endif // #endif
// #ifdef MP-ALIPAY // #ifdef MP-ALIPAY
payTypeList: [{ payTypeList: [{
name: this.$lang('payment.alipayPay'), name: '支付宝支付',
icon: 'icon-zhifubaozhifu-', icon: 'icon-zhifubaozhifu-',
type: 'alipay', type: 'alipay',
provider: 'alipay' provider: 'alipay'
@@ -135,12 +135,12 @@
confirm() { confirm() {
if (this.payTypeList.length == 0 && this.payMoney > 0) { if (this.payTypeList.length == 0 && this.payMoney > 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.selectPaymentMethod') title: '请选择支付方式!'
}); });
return; return;
} }
uni.showLoading({ uni.showLoading({
title: this.$lang('payment.paying'), title: '支付中...',
mask: true mask: true
}); });
this.pay(); this.pay();
@@ -161,7 +161,7 @@
}) })
} else { } else {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.noPaymentInfo') title: '未获取到支付信息!'
}); });
} }
} }
@@ -294,7 +294,7 @@
}, },
res => { res => {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.cancelledPayment') title: '您已取消支付'
}); });
this.resetpay(); this.resetpay();
} }
@@ -378,12 +378,12 @@
this.flag = false; this.flag = false;
if (res.errMsg == 'requestOrderPayment:fail cancel') { if (res.errMsg == 'requestOrderPayment:fail cancel') {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.payCancel') title: '您已取消支付'
}); });
this.resetpay(); this.resetpay();
} else { } else {
uni.showModal({ uni.showModal({
content: this.$lang('payment.payFail') + ', ' + this.$lang('payment.errorReason') + res.errMsg, content: '支付失败,失败原因: ' + res.errMsg,
showCancel: false showCancel: false
}); });
setTimeout(() => { setTimeout(() => {
@@ -406,12 +406,12 @@
this.flag = false; this.flag = false;
if (res.errMsg == 'requestPayment:fail cancel') { if (res.errMsg == 'requestPayment:fail cancel') {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.payCancel') title: '您已取消支付'
}); });
this.resetpay(); this.resetpay();
} else { } else {
uni.showModal({ uni.showModal({
content: this.$lang('payment.payFail') + ', ' + this.$lang('payment.errorReason') + res.errMsg, content: '支付失败,失败原因: ' + res.errMsg,
showCancel: false showCancel: false
}); });
setTimeout(() => { setTimeout(() => {

View File

@@ -14,8 +14,8 @@
<uni-popup type="bottom" ref="regionsRef"> <uni-popup type="bottom" ref="regionsRef">
<view class="regions-picker-container"> <view class="regions-picker-container">
<view class="picker-header"> <view class="picker-header">
<view class="picker-action cancel" @click="$refs.regionsRef.close()">{{ $lang('common.cancel') }}</view> <view class="picker-action cancel" @click="$refs.regionsRef.close()">取消</view>
<view class="picker-action confirm" @click="confirmRegions">{{ $lang('common.done') }}</view> <view class="picker-action confirm" @click="confirmRegions">完成</view>
</view> </view>
<picker-view :value="multiIndex" @change="pickerViewColumnChange" class="picker-view"> <picker-view :value="multiIndex" @change="pickerViewColumnChange" class="picker-view">
<picker-view-column v-if="multiArray[0]"> <picker-view-column v-if="multiArray[0]">

View File

@@ -2,23 +2,23 @@
<view> <view>
<view class="privacy-mask" v-if="showPop"> <view class="privacy-mask" v-if="showPop">
<view class="privacy-wrap"> <view class="privacy-wrap">
<view class="privacy-title">{{ $lang('privacy.title') }}</view> <view class="privacy-title">用户隐私保护提示</view>
<view class="privacy-desc"> <view class="privacy-desc">
{{ $lang('privacy.thanks') }}{{ appName }},{{ $lang('privacy.beforeUse') }} 感谢您使用{{ appName }},在使用前您应当阅读并同意
<text class="privacy-link" @tap="openPrivacyContract">{{ privacyContractName }}</text> <text class="privacy-link" @tap="openPrivacyContract">{{ privacyContractName }}</text>
<!-- #ifdef QUICKAPP-WEBVIEW || H5 --> <!-- #ifdef QUICKAPP-WEBVIEW || H5 -->
<text class="privacy-link" @tap="openPrivacyService">{{ privacyServiceName }}</text> <text class="privacy-link" @tap="openPrivacyService">{{ privacyServiceName }}</text>
<!-- #endif --> <!-- #endif -->
{{ $lang('privacy.agreeTip') }}{{ appName }}{{ $lang('privacy.functionTip') }} ,当点击同意并继续时,即表示您已理解并同意该条款内容,该条款将对您产生法律约束力;如您不同意,将无法继续使用{{ appName }}相关功能。
</view> </view>
<view class="privacy-button-flex"> <view class="privacy-button-flex">
<button class="privacy-button-btn bg-disagree" @tap="handleDisagree">{{ $lang('privacy.disagree') }}</button> <button class="privacy-button-btn bg-disagree" @tap="handleDisagree">不同意</button>
<!-- #ifdef QUICKAPP-WEBVIEW || MP-WEIXIN --> <!-- #ifdef QUICKAPP-WEBVIEW || MP-WEIXIN -->
<button id="agree-btn" class="privacy-button-btn bg-agree" open-type="agreePrivacyAuthorization" <button id="agree-btn" class="privacy-button-btn bg-agree" open-type="agreePrivacyAuthorization"
@agreeprivacyauthorization="handleAgree">{{ $lang('privacy.agreeAndContinue') }}</button> @agreeprivacyauthorization="handleAgree">同意并继续</button>
<!-- #endif --> <!-- #endif -->
<!-- #ifdef WEB || H5 --> <!-- #ifdef WEB || H5 -->
<button id="agree-btn" class="privacy-button-btn bg-agree" @tap="handleAgree" @click="handleAgree">{{ $lang('privacy.agreeAndContinue') }}</button> <button id="agree-btn" class="privacy-button-btn bg-agree" @tap="handleAgree" @click="handleAgree">同意并继续</button>
<!-- #endif --> <!-- #endif -->
</view> </view>
</view> </view>
@@ -43,12 +43,12 @@ export default {
showPop: false, showPop: false,
privacyAuthorization: null, privacyAuthorization: null,
privacyResolves: new Set(), privacyResolves: new Set(),
privacyContractName: this.$lang('privacy.contractName'), privacyContractName: '用户隐私保护指引',
appName: this.$lang('privacy.miniAppName'), appName: '本小程序',
// #ifdef WEB || H5 // #ifdef WEB || H5
appName: this.$lang('privacy.appName'), appName: '本应用',
privacyContractName: this.$lang('privacy.termsTitle'), privacyContractName: '《隐私条款》',
privacyServiceName: this.$lang('privacy.serviceTerms'), privacyServiceName: '《用户服务协议》',
// #endif // #endif
} }
}, },
@@ -250,7 +250,7 @@ export default {
uni.setStorageSync('privacyAgreed', true); uni.setStorageSync('privacyAgreed', true);
uni.showModal({ uni.showModal({
content: this.$lang('privacy.noAgreementTip'), content: '未同意隐私协议,无法使用相关功能',
success: () => { success: () => {
this.$emit('disagree') this.$emit('disagree')
} }

View File

@@ -11,59 +11,59 @@
<scroll-view scroll-y="true" class="register-box"> <scroll-view scroll-y="true" class="register-box">
<view class="reward-content"> <view class="reward-content">
<view class="reward-item" v-if="reward.point > 0"> <view class="reward-item" v-if="reward.point > 0">
<view class="head">{{ $lang('reward.pointReward') }}</view> <view class="head">积分奖励</view>
<view class="content"> <view class="content">
<view class="info"> <view class="info">
<view> <view>
<text class="num">{{ reward.point }}</text> <text class="num">{{ reward.point }}</text>
<text class="type">{{ $lang('reward.point') }}</text> <text class="type">积分</text>
</view> </view>
<view class="desc">{{ $lang('reward.pointDesc') }}</view> <view class="desc">用于下单时抵现或兑换商品等</view>
</view> </view>
<view class="tip" @click="closeRewardPopup('point')">{{ $lang('reward.viewNow') }}</view> <view class="tip" @click="closeRewardPopup('point')">立即查看</view>
</view> </view>
</view> </view>
<view class="reward-item" v-if="reward.growth > 0"> <view class="reward-item" v-if="reward.growth > 0">
<view class="head">{{ $lang('reward.growthReward') }}</view> <view class="head">成长值</view>
<view class="content"> <view class="content">
<view class="info"> <view class="info">
<view> <view>
<text class="num">{{ reward.growth }}</text> <text class="num">{{ reward.growth }}</text>
<text class="type">{{ $lang('reward.growth') }}</text> <text class="type">成长值</text>
</view> </view>
<view class="desc">{{ $lang('reward.growthDesc') }}</view> <view class="desc">用于提升会员等级</view>
</view> </view>
<view class="tip" @click="closeRewardPopup('growth')">{{ $lang('reward.viewNow') }}</view> <view class="tip" @click="closeRewardPopup('growth')">立即查看</view>
</view> </view>
</view> </view>
<view class="reward-item" v-if="reward.balance > 0"> <view class="reward-item" v-if="reward.balance > 0">
<view class="head">{{ $lang('reward.hongbaoReward') }}</view> <view class="head">红包奖励</view>
<view class="content"> <view class="content">
<view class="info"> <view class="info">
<view> <view>
<text class="num">{{ reward.balance }}</text> <text class="num">{{ reward.balance }}</text>
<text class="type">{{ $lang('reward.yuan') }}</text> <text class="type">元</text>
</view> </view>
<view class="desc">{{ $lang('reward.hongbaoDesc') }}</view> <view class="desc">不可提现下单时可用</view>
</view> </view>
<view class="tip" @click="closeRewardPopup('balance')">{{ $lang('reward.viewNow') }}</view> <view class="tip" @click="closeRewardPopup('balance')">立即查看</view>
</view> </view>
</view> </view>
<view class="reward-item" v-if="reward.coupon_list.length > 0"> <view class="reward-item" v-if="reward.coupon_list.length > 0">
<view class="head">{{ $lang('reward.couponReward') }}</view> <view class="head">优惠券奖励</view>
<view class="content" v-for="(item, index) in reward.coupon_list" :key="index"> <view class="content" v-for="(item, index) in reward.coupon_list" :key="index">
<view class="info"> <view class="info">
<view> <view>
<text class="num coupon-name">{{ item.coupon_name }}</text> <text class="num coupon-name">{{ item.coupon_name }}</text>
</view> </view>
<view class="desc" v-if="item.at_least > 0"> <view class="desc" v-if="item.at_least > 0">
{{ $lang('reward.full') }}{{ item.at_least }}{{ item.type == 'discount' ? $lang('reward.discount') + item.discount + $lang('reward.zhe') : $lang('reward.minus') + item.money }} 满{{ item.at_least }}{{ item.type == 'discount' ? '打' + item.discount + '折' : '减' + item.money }}
</view> </view>
<view class="desc" v-else> <view class="desc" v-else>
{{ $lang('reward.noThreshold') }},{{ item.type == 'discount' ? $lang('reward.discount') + item.discount + $lang('reward.zhe') : $lang('reward.minus') + item.money }} 无门槛,{{ item.type == 'discount' ? '打' + item.discount + '折' : '减' + item.money }}
</view> </view>
</view> </view>
<view class="tip" @click="closeRewardPopup('coupon')">{{ $lang('reward.viewNow') }}</view> <view class="tip" @click="closeRewardPopup('coupon')">立即查看</view>
</view> </view>
</view> </view>
</view> </view>

View File

@@ -13,14 +13,14 @@
<uni-popup ref="confirmPopup" type="center"> <uni-popup ref="confirmPopup" type="center">
<view class="confirm-popup"> <view class="confirm-popup">
<view class="popup-header"> <view class="popup-header">
<text>{{ $lang('chat.addEnterpriseWeChat') }}</text> <text>添加企业微信客服</text>
</view> </view>
<view class="popup-body"> <view class="popup-body">
<text>{{ $lang('chat.confirmAddWeChatTip') }}</text> <text>点击确定后将跳转至企业微信,添加专业客服为您服务</text>
</view> </view>
<view class="popup-footer"> <view class="popup-footer">
<button class="cancel-btn" @click="closePopup">{{ $lang('chat.cancel') }}</button> <button class="cancel-btn" @click="closePopup">取消</button>
<button class="confirm-btn" @click="confirmAdd">{{ $lang('chat.confirm') }}</button> <button class="confirm-btn" @click="confirmAdd">确定</button>
</view> </view>
</view> </view>
</uni-popup> </uni-popup>
@@ -142,7 +142,7 @@
// 方案2:使用SDK打开用户资料 // 方案2:使用SDK打开用户资料
this.openUserProfile(contactId); this.openUserProfile(contactId);
} else { } else {
this.showError(this.$lang('wxwork.notConfigured')); this.showError('未配置企业微信客服信息');
} }
// #endif // #endif
@@ -151,7 +151,7 @@
// H5环境直接跳转 // H5环境直接跳转
window.location.href = contactUrl; window.location.href = contactUrl;
} else { } else {
this.showError(this.$lang('wxwork.notConfigured')); this.showError('未配置企业微信客服信息');
} }
// #endif // #endif
}, },
@@ -165,13 +165,13 @@
path: `pages/contacts/externalContactDetail?url=${encodeURIComponent(contactUrl)}`, path: `pages/contacts/externalContactDetail?url=${encodeURIComponent(contactUrl)}`,
success: () => { success: () => {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('wxwork.jumpSuccess'), title: '跳转成功',
icon: 'success' icon: 'success'
}); });
}, },
fail: (err) => { fail: (err) => {
console.error('跳转企业微信失败:', err); console.error('跳转企业微信失败:', err);
this.showError(this.$lang('wxwork.jumpFailed')); this.showError('跳转失败,请检查企业微信配置');
} }
}); });
}, },
@@ -181,7 +181,7 @@
*/ */
openUserProfile(contactId) { openUserProfile(contactId) {
if (!this.wxWorkSDK) { if (!this.wxWorkSDK) {
this.showError(this.$lang('wxwork.sdkNotInit')); this.showError('企业微信SDK未初始化');
return; return;
} }
@@ -190,7 +190,7 @@
}, (res) => { }, (res) => {
}, (err) => { }, (err) => {
console.error('打开用户资料失败:', err); console.error('打开用户资料失败:', err);
this.showError(this.$lang('wxwork.openProfileFailed')); this.showError('打开用户资料失败');
}); });
}, },
@@ -199,7 +199,7 @@
*/ */
showError(message) { showError(message) {
uni.showModal({ uni.showModal({
title: this.$lang('common.tip'), title: '提示',
content: message, content: message,
showCancel: false showCancel: false
}); });

View File

@@ -23,7 +23,7 @@ export function currentTime() {
} }
//时间戳转日期 //时间戳转日期
export function timeStamp(time, dayNames) { export function timeStamp(time) {
const dates = new Date(time) const dates = new Date(time)
const year = dates.getFullYear() const year = dates.getFullYear()
const month = dates.getMonth() + 1 const month = dates.getMonth() + 1
@@ -31,33 +31,32 @@ export function timeStamp(time, dayNames) {
const day = dates.getDay() const day = dates.getDay()
const hour = dates.getHours() const hour = dates.getHours()
const min = dates.getMinutes() const min = dates.getMinutes()
const days = dayNames || ['日', '一', '二', '三', '四', '五', '六'] const days = ['日', '一', '二', '三', '四', '五', '六']
return { return {
allDate: `${year}/${strFormat(month)}/${strFormat(date)}`, allDate: `${year}/${strFormat(month)}/${strFormat(date)}`,
date: `${strFormat(month)}-${strFormat(date)}`, //返回的日期 07-01,${strFormat(year)}-${strFormat(month)}-${strFormat(date)} date: `${strFormat(month)}-${strFormat(date)}`, //返回的日期 07-01,${strFormat(year)}-${strFormat(month)}-${strFormat(date)}
day: `${days[day]}`, //返回的礼拜天数 星期一 day: `周${days[day]}`, //返回的礼拜天数 星期一
hour: strFormat(hour) + ':' + strFormat(min) // + ':00' //返回的时钟 08:00 hour: strFormat(hour) + ':' + strFormat(min) // + ':00' //返回的时钟 08:00
} }
} }
//获取最近7天的日期和礼拜天数 //获取最近7天的日期和礼拜天数
export function initData(appointedDay = '', dayNames) { export function initData(appointedDay = '') {
const time = [] const time = []
const date = appointedDay ? new Date(appointedDay) : new Date() const date = appointedDay ? new Date(appointedDay) : new Date()
const now = date.getTime() //获取当前日期的时间戳 const now = date.getTime() //获取当前日期的时间戳
let timeStr = 3600 * 24 * 1000 //一天的时间戳 let timeStr = 3600 * 24 * 1000 //一天的时间戳
const defaults = dayNames || { today: "今天", tomorrow: "明天", dayAfterTomorrow: "后天" }
let obj = { let obj = {
0: defaults.today, 0: "今天",
1: defaults.tomorrow, 1: "明天",
2: defaults.dayAfterTomorrow 2: "后天"
} }
for (let i = 0; i < 7; i++) { for (let i = 0; i < 7; i++) {
const timeObj = {} const timeObj = {}
timeObj.date = timeStamp(now + timeStr * i, dayNames).date //保存日期 timeObj.date = timeStamp(now + timeStr * i).date //保存日期
timeObj.timeStamp = now + timeStr * i //保存时间戳 timeObj.timeStamp = now + timeStr * i //保存时间戳
timeObj.week = appointedDay == '' ? (obj[i] ?? timeStamp(now + timeStr * i, dayNames).day) : timeStamp(now + timeStr * i, dayNames) timeObj.week = appointedDay == '' ? (obj[i] ?? timeStamp(now + timeStr * i).day) : timeStamp(now + timeStr * i)
.day .day
time.push(timeObj) time.push(timeObj)
} }

View File

@@ -20,7 +20,7 @@
</scroll-view> </scroll-view>
<div class="appointed-day"> <div class="appointed-day">
<uni-datetime-picker type="date" :start="pickerStartDay" :end="pickerEndDay" @change="change"> <uni-datetime-picker type="date" :start="pickerStartDay" :end="pickerEndDay" @change="change">
<text class="day-box">{{ $lang('yuyueDate.appointedDate') }}</text> <text class="day-box">指定日期</text>
<text class="iconfont iconyoujiantou"></text> <text class="iconfont iconyoujiantou"></text>
</uni-datetime-picker> </uni-datetime-picker>
</div> </div>
@@ -173,7 +173,7 @@
return { return {
pickerStartDay: '', // 指定开始日期 pickerStartDay: '', // 指定开始日期
pickerEndDay: '', // 指定结束日期 pickerEndDay: '', // 指定结束日期
orderDateTime: this.$lang('date.noSelection'), // 选中时间 orderDateTime: '暂无选择', // 选中时间
orderTimeArr: {}, //多选的时间 orderTimeArr: {}, //多选的时间
dateArr: [], //日期数据 dateArr: [], //日期数据
timeArr: [], //时间数据 timeArr: [], //时间数据
@@ -188,16 +188,14 @@
}; };
}, },
created(props) { created(props) {
const dayNames = [this.$lang('date.sunday'), this.$lang('date.monday'), this.$lang('date.tuesday'), this.$lang('date.wednesday'), this.$lang('date.thursday'), this.$lang('date.friday'), this.$lang('date.saturday')];
const dayLabels = { today: this.$lang('date.today'), tomorrow: this.$lang('date.tomorrow'), dayAfterTomorrow: this.$lang('date.dayAfterTomorrow') };
this.selectDate = this.nowDate = currentTime().date; this.selectDate = this.nowDate = currentTime().date;
this.pickerStartDay = currentTime().year + '-' + currentTime().date; this.pickerStartDay = currentTime().year + '-' + currentTime().date;
const now = new Date(this.pickerStartDay).getTime(); //获取当前日期的时间戳 const now = new Date(this.pickerStartDay).getTime(); //获取当前日期的时间戳
let timeStr = 3600 * 24 * 1000; //一天的时间戳 let timeStr = 3600 * 24 * 1000; //一天的时间戳
let day = 90; // 未来3个月 let day = 90; // 未来3个月
this.pickerEndDay = timeStamp(now + timeStr * day, dayNames).allDate; this.pickerEndDay = timeStamp(now + timeStr * day).allDate;
this.initOnload(); this.initOnload();
this.dateArr = initData('', dayLabels); // 日期栏初始化 this.dateArr = initData(); // 日期栏初始化
}, },
methods: { methods: {
open() { open() {
@@ -211,18 +209,18 @@
let date = e.split("-"); let date = e.split("-");
date = date[1] + "-" + date[2]; date = date[1] + "-" + date[2];
if (this.disableWeek.length && date >= weekDate()[0] && date <= weekDate()[1]) { if (this.disableWeek.length && date >= weekDate()[0] && date <= weekDate()[1]) {
let weekBox = [this.$lang('date.sunday'), this.$lang('date.monday'), this.$lang('date.tuesday'), this.$lang('date.wednesday'), this.$lang('date.thursday'), this.$lang('date.friday'), this.$lang('date.saturday')]; let weekBox = ['周日', '周一', '周二', '周三', '周四', '周五', '周六'];
let index = new Date(e).getDay(); let index = new Date(e).getDay();
if (this.disableWeek.indexOf(weekBox[index]) != -1) { if (this.disableWeek.indexOf(weekBox[index]) != -1) {
uni.showToast({ uni.showToast({
title: weekBox[index] + this.$lang('date.cannotReserve'), title: weekBox[index] + '不可以预约',
icon: 'none' icon: 'none'
}) })
return false; return false;
} }
} }
this.initOnload(e); this.initOnload(e);
this.dateArr = initData(e, { today: this.$lang('date.today'), tomorrow: this.$lang('date.tomorrow'), dayAfterTomorrow: this.$lang('date.dayAfterTomorrow') }); // 日期栏初始化 this.dateArr = initData(e); // 日期栏初始化
this.selectDateEvent(0, this.dateArr[0]); this.selectDateEvent(0, this.dateArr[0]);
}, },
initOnload(appointedDay) { initOnload(appointedDay) {
@@ -233,7 +231,7 @@
// 判断默认是不能选择的周,则都禁止选中 // 判断默认是不能选择的周,则都禁止选中
if (this.disableWeek.length && this.selectDate >= weekDate()[0] && this.selectDate <= if (this.disableWeek.length && this.selectDate >= weekDate()[0] && this.selectDate <=
weekDate()[1]) { weekDate()[1]) {
let weekBox = [this.$lang('date.sunday'), this.$lang('date.monday'), this.$lang('date.tuesday'), this.$lang('date.wednesday'), this.$lang('date.thursday'), this.$lang('date.friday'), this.$lang('date.saturday')]; let weekBox = ['周日', '周一', '周二', '周三', '周四', '周五', '周六'];
let date = currentTime().year + '-' + this.selectDate; let date = currentTime().year + '-' + this.selectDate;
let index = new Date(date).getDay(); let index = new Date(date).getDay();
if (this.disableWeek.indexOf(weekBox[index]) != -1) { if (this.disableWeek.indexOf(weekBox[index]) != -1) {
@@ -282,7 +280,7 @@
this.isSection && (item.isInclude = false); this.isSection && (item.isInclude = false);
}); });
this.orderDateTime = isFullTime ? this.$lang('date.noSelection') : this.selectDate; this.orderDateTime = isFullTime ? '暂无选择' : this.selectDate;
this.timeActive = -1; this.timeActive = -1;
for (let i = 0, len = this.timeArr.length; i < len; i++) { for (let i = 0, len = this.timeArr.length; i < len; i++) {
if (!this.timeArr[i].disable) { if (!this.timeArr[i].disable) {
@@ -299,11 +297,11 @@
// 日期选择事件 // 日期选择事件
selectDateEvent(index, item) { selectDateEvent(index, item) {
if (this.disableWeek.length && item.date >= weekDate()[0] && item.date <= weekDate()[1]) { if (this.disableWeek.length && item.date >= weekDate()[0] && item.date <= weekDate()[1]) {
let weekBox = [this.$lang('date.sunday'), this.$lang('date.monday'), this.$lang('date.tuesday'), this.$lang('date.wednesday'), this.$lang('date.thursday'), this.$lang('date.friday'), this.$lang('date.saturday')]; let weekBox = ['周日', '周一', '周二', '周三', '周四', '周五', '周六'];
let index = new Date(item.timeStamp).getDay(); let index = new Date(item.timeStamp).getDay();
if (this.disableWeek.indexOf(weekBox[index]) != -1) { if (this.disableWeek.indexOf(weekBox[index]) != -1) {
uni.showToast({ uni.showToast({
title: weekBox[index] + this.$lang('date.cannotReserve'), title: weekBox[index] + '不可以预约',
icon: 'none' icon: 'none'
}) })
return false; return false;

View File

@@ -0,0 +1 @@
export const lang = {}

File diff suppressed because it is too large Load Diff

View File

@@ -13,7 +13,7 @@
<text>{{ followOfficialAccount.welcomeMsg }}</text> <text>{{ followOfficialAccount.welcomeMsg }}</text>
</view> </view>
</view> </view>
<view class="dite-button" @click="officialAccountsOpen">{{ $lang('index.followOfficialAccount') <view class="dite-button" @click="officialAccountsOpen">{{ isEnEnv ? 'Follow Official Account' : '关注公众号'
}}</view> }}</view>
</view> </view>
@@ -44,7 +44,7 @@
<uni-popup ref="uniPopupWindow" type="center" class="wap-floating" :maskClick="false"> <uni-popup ref="uniPopupWindow" type="center" class="wap-floating" :maskClick="false">
<view class="small-bot"> <view class="small-bot">
<!-- <view class="adver-time" wx:if="{{startadv.params.style=='default'&&startadv.params.canclose==1}}"> <!-- <view class="adver-time" wx:if="{{startadv.params.style=='default'&&startadv.params.canclose==1}}">
<view bindtap="adverclose">{{ $lang('common.skip') }}</view> <view bindtap="adverclose">跳过</view>
<view class="time">{{clock}}s</view> <view class="time">{{clock}}s</view>
</view> </view>
<view class="adver-time" wx:if="{{startadv.params.style=='default'&&startadv.params.canclose==0}}"> <view class="adver-time" wx:if="{{startadv.params.style=='default'&&startadv.params.canclose==0}}">
@@ -86,7 +86,7 @@
<uni-popup ref="officialAccountsPopup" type="center"> <uni-popup ref="officialAccountsPopup" type="center">
<view class="official-accounts-wrap"> <view class="official-accounts-wrap">
<image class="content" :src="$util.img(wechatQrcode)" mode="aspectFit" show-menu-by-longpress></image> <image class="content" :src="$util.img(wechatQrcode)" mode="aspectFit" show-menu-by-longpress></image>
<text class="desc">{{ $lang('index.followToLearnMore') }}</text> <text class="desc">关注了解更多</text>
<text class="close iconfont icon-round-close" @click="officialAccountsClose"></text> <text class="close iconfont icon-round-close" @click="officialAccountsClose"></text>
</view> </view>
</uni-popup> </uni-popup>
@@ -97,7 +97,7 @@
<view v-if="showTip" class="collectPopupWindow" <view v-if="showTip" class="collectPopupWindow"
:style="{ marginTop: (collectTop + statusBarHeight) * 2 + 'rpx' }"> :style="{ marginTop: (collectTop + statusBarHeight) * 2 + 'rpx' }">
<image :src="$util.img('public/uniapp/index/collect2.png')" mode="aspectFit" show-menu-by-longpress/> <image :src="$util.img('public/uniapp/index/collect2.png')" mode="aspectFit" show-menu-by-longpress/>
<text @click="closeCollectPopupWindow">{{ $lang('index.iKnow') }}</text> <text @click="closeCollectPopupWindow">我知道了</text>
</view> </view>
</uni-popup> </uni-popup>
@@ -105,18 +105,18 @@
<view @touchmove.prevent.stop class="choose-store"> <view @touchmove.prevent.stop class="choose-store">
<uni-popup ref="chooseStorePopup" type="center" :maskClick="false" class="choose-store"> <uni-popup ref="chooseStorePopup" type="center" :maskClick="false" class="choose-store">
<view class="choose-store-popup"> <view class="choose-store-popup">
<view class="head-wrap" @click="closeChooseStorePopup">{{ $lang('index.confirmStore') }}</view> <view class="head-wrap" @click="closeChooseStorePopup">请确认门店</view>
<view class="position-wrap"> <view class="position-wrap">
<text class="iconfont icon-dizhi"></text> <text class="iconfont icon-dizhi"></text>
<text class="address">{{ currentPosition }}</text> <text class="address">{{ currentPosition }}</text>
<view class="reposition" @click="reposition" <view class="reposition" @click="reposition"
v-if="globalStoreConfig && globalStoreConfig.is_allow_change == 1"> v-if="globalStoreConfig && globalStoreConfig.is_allow_change == 1">
<text class="iconfont icon-dingwei"></text> <text class="iconfont icon-dingwei"></text>
<text>{{ $lang('index.reposition') }}</text> <text>重新定位</text>
</view> </view>
</view> </view>
<view class="store-wrap" v-if="nearestStore"> <view class="store-wrap" v-if="nearestStore">
<text class="tag">{{ $lang('index.currentStore') }}</text> <text class="tag">当前门店</text>
<view class="store-name">{{ nearestStore.store_name }}</view> <view class="store-name">{{ nearestStore.store_name }}</view>
<view class="address">{{ nearestStore.show_address }}</view> <view class="address">{{ nearestStore.show_address }}</view>
<view class="distance" v-if="nearestStore.distance"> <view class="distance" v-if="nearestStore.distance">
@@ -127,10 +127,10 @@
'm' }}</text> 'm' }}</text>
</view> </view>
</view> </view>
<button type="primary" @click="enterStore">{{ $lang('index.confirmEnter') }}</button> <button type="primary" @click="enterStore">确认进入</button>
<view class="other-store" @click="chooseOtherStore" <view class="other-store" @click="chooseOtherStore"
v-if="globalStoreConfig && globalStoreConfig.is_allow_change == 1"> v-if="globalStoreConfig && globalStoreConfig.is_allow_change == 1">
<text>{{ $lang('index.selectOtherStore') }}</text> <text>选择其他门店</text>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
</view> </view>
</view> </view>

View File

@@ -118,8 +118,8 @@ export default {
} catch (e) {} } catch (e) {}
if (v && v.commitId) { if (v && v.commitId) {
uni.showModal({ uni.showModal({
title: this.$lang('common.buildVersion'), title: '构建版本信息',
content: this.$lang('common.buildVersionDesc', { commitId: v.commitId, buildTime: v.buildTime }), content: `提交 ID: ${v.commitId}\n构建时间: ${v.buildTime}`,
showCancel: false showCancel: false
}); });
} else { } else {

View File

@@ -282,7 +282,7 @@ export default {
//生成海报 //生成海报
getGoodsPoster() { getGoodsPoster() {
uni.showLoading({ uni.showLoading({
'title': this.$lang('goods.posterGenerating') 'title': '海报生成中...'
}) })
//活动海报信息 //活动海报信息
if (this.memberInfo && this.memberInfo.member_id) this.posterParams.source_member = this.memberInfo.member_id; if (this.memberInfo && this.memberInfo.member_id) this.posterParams.source_member = this.memberInfo.member_id;
@@ -348,12 +348,12 @@ export default {
filePath: res.tempFilePath, filePath: res.tempFilePath,
success: () => { success: () => {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('common.saveSuccess') title: "保存成功"
}); });
}, },
fail: (err) => { fail: (err) => {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('common.saveFailed') title: "保存失败,请稍后重试"
}); });
} }
}); });
@@ -361,7 +361,7 @@ export default {
}, },
fail: (err) => { fail: (err) => {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('common.saveFailed') title: "保存失败,请稍后重试"
}); });
} }
}); });

View File

@@ -72,7 +72,7 @@
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
</block> </block>
<block v-else> <block v-else>
<view class="box">{{ $lang('goods.notConfigured') }}</view> <view class="box">未配置</view>
</block> </block>
</view> </view>

View File

@@ -3,45 +3,45 @@
<view class="ns-goods-promotion" v-if="goodsPromotion.length"> <view class="ns-goods-promotion" v-if="goodsPromotion.length">
<view v-for="(item, index) in goodsPromotion" v-if="promotion != item.promotion_type" :key="index"> <view v-for="(item, index) in goodsPromotion" v-if="promotion != item.promotion_type" :key="index">
<view v-if="item.promotion_type == 'discount'" class="item" @click="redirectTo('/pages_goods/detail', { goods_id: item.goods_id })"> <view v-if="item.promotion_type == 'discount'" class="item" @click="redirectTo('/pages_goods/detail', { goods_id: item.goods_id })">
<text class="promotion-mark ">{{ $lang('promotion.limitedTimeDiscount') }}</text> <text class="promotion-mark ">限时折扣</text>
<text class="title">{{ $lang('promotion.participating', { name: item.promotion_name }) }}</text> <text class="title">当前商品正在参加{{ item.promotion_name }}</text>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
<!-- <view class="img-wrap"><image :src="$util.img('public/uniapp/goods/detail_more.png')" mode="aspectFit" show-menu-by-longpress/></view> --> <!-- <view class="img-wrap"><image :src="$util.img('public/uniapp/goods/detail_more.png')" mode="aspectFit" show-menu-by-longpress/></view> -->
</view> </view>
<view v-else-if="item.promotion_type == 'groupbuy'" class="item" @click="redirectTo('/pages_promotion/groupbuy/detail', { groupbuy_id: item.groupbuy_id })"> <view v-else-if="item.promotion_type == 'groupbuy'" class="item" @click="redirectTo('/pages_promotion/groupbuy/detail', { groupbuy_id: item.groupbuy_id })">
<!-- <view v-else-if="item.promotion_type == 'groupbuy'" class="item" @click="redirectTo('/pages_promotion/groupbuy/detail', { id: item.groupbuy_id })"> --> <!-- <view v-else-if="item.promotion_type == 'groupbuy'" class="item" @click="redirectTo('/pages_promotion/groupbuy/detail', { id: item.groupbuy_id })"> -->
<text class="promotion-mark ">{{ $lang('promotion.groupbuy') }}</text> <text class="promotion-mark ">团购</text>
<text class="title">{{ $lang('promotion.participating', { name: item.promotion_name }) }}</text> <text class="title">当前商品正在参加{{ item.promotion_name }}</text>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
<!-- <view class="img-wrap"><image :src="$util.img('public/uniapp/goods/detail_more.png')" mode="aspectFit" show-menu-by-longpress/></view> --> <!-- <view class="img-wrap"><image :src="$util.img('public/uniapp/goods/detail_more.png')" mode="aspectFit" show-menu-by-longpress/></view> -->
</view> </view>
<view v-else-if="item.promotion_type == 'pintuan'" class="item" @click="redirectTo('/pages_promotion/pintuan/detail', { pintuan_id: item.pintuan_id })"> <view v-else-if="item.promotion_type == 'pintuan'" class="item" @click="redirectTo('/pages_promotion/pintuan/detail', { pintuan_id: item.pintuan_id })">
<text class="promotion-mark ">{{ $lang('promotion.pintuan') }}</text> <text class="promotion-mark ">拼团</text>
<text class="title">{{ $lang('promotion.participating', { name: item.promotion_name }) }}</text> <text class="title">当前商品正在参加{{ item.promotion_name }}</text>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
<!-- <view class="img-wrap"><image :src="$util.img('public/uniapp/goods/detail_more.png')" mode="aspectFit" show-menu-by-longpress/></view> --> <!-- <view class="img-wrap"><image :src="$util.img('public/uniapp/goods/detail_more.png')" mode="aspectFit" show-menu-by-longpress/></view> -->
</view> </view>
<view v-else-if="item.promotion_type == 'seckill'" class="item" @click="redirectTo('/pages_promotion/seckill/detail', { seckill_id: item.id })"> <view v-else-if="item.promotion_type == 'seckill'" class="item" @click="redirectTo('/pages_promotion/seckill/detail', { seckill_id: item.id })">
<text class="promotion-mark ">{{ $lang('promotion.seckill') }}</text> <text class="promotion-mark ">秒杀</text>
<text class="title">{{ $lang('promotion.participating', { name: item.promotion_name }) }}</text> <text class="title">当前商品正在参加{{ item.promotion_name }}</text>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
<!-- <view class="img-wrap"><image :src="$util.img('public/uniapp/goods/detail_more.png')" mode="aspectFit" show-menu-by-longpress/></view> --> <!-- <view class="img-wrap"><image :src="$util.img('public/uniapp/goods/detail_more.png')" mode="aspectFit" show-menu-by-longpress/></view> -->
</view> </view>
<view v-else-if="item.promotion_type == 'topic'" class="item" @click="redirectTo('/pages_promotion/topics/goods_detail', { id: item.id })"> <view v-else-if="item.promotion_type == 'topic'" class="item" @click="redirectTo('/pages_promotion/topics/goods_detail', { id: item.id })">
<text class="promotion-mark ">{{ $lang('promotion.topicActivity') }}</text> <text class="promotion-mark ">专题活动</text>
<text class="title">{{ $lang('promotion.participating', { name: item.promotion_name }) }}</text> <text class="title">当前商品正在参加{{ item.promotion_name }}</text>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
<!-- <view class="img-wrap"><image :src="$util.img('public/uniapp/goods/detail_more.png')" mode="aspectFit" show-menu-by-longpress/></view> --> <!-- <view class="img-wrap"><image :src="$util.img('public/uniapp/goods/detail_more.png')" mode="aspectFit" show-menu-by-longpress/></view> -->
</view> </view>
<view v-else-if="item.promotion_type == 'bargain'" class="item" @click="redirectTo('/pages_promotion/bargain/detail', { b_id: item.bargain_id })"> <view v-else-if="item.promotion_type == 'bargain'" class="item" @click="redirectTo('/pages_promotion/bargain/detail', { b_id: item.bargain_id })">
<text class="promotion-mark ">{{ $lang('promotion.bargain') }}</text> <text class="promotion-mark ">砍价</text>
<text class="title">{{ $lang('promotion.participating', { name: item.promotion_name }) }}</text> <text class="title">当前商品正在参加{{ item.promotion_name }}</text>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
<!-- <view class="img-wrap"><image :src="$util.img('public/uniapp/goods/detail_more.png')" mode="aspectFit" show-menu-by-longpress/></view> --> <!-- <view class="img-wrap"><image :src="$util.img('public/uniapp/goods/detail_more.png')" mode="aspectFit" show-menu-by-longpress/></view> -->
</view> </view>
<view v-else-if="item.promotion_type == 'pinfan'" class="item" @click="redirectTo('/pages_promotion/pinfan/detail', { pinfan_id: item.pintuan_id })"> <view v-else-if="item.promotion_type == 'pinfan'" class="item" @click="redirectTo('/pages_promotion/pinfan/detail', { pinfan_id: item.pintuan_id })">
<text class="promotion-mark ">{{ $lang('promotion.pinfan') }}</text> <text class="promotion-mark ">拼团返利</text>
<text class="title">{{ $lang('promotion.participating', { name: item.promotion_name }) }}</text> <text class="title">当前商品正在参加{{ item.promotion_name }}</text>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
</view> </view>
</view> </view>

View File

@@ -5,7 +5,7 @@
:refresher-triggered="refresherTriggered" @refresherrefresh="onRefresh"> :refresher-triggered="refresherTriggered" @refresherrefresh="onRefresh">
<block v-if="hasData"> <block v-if="hasData">
<view class="cart-header" v-if="cartData.length"> <view class="cart-header" v-if="cartData.length">
<view class="num-wrap">{{ $lang('cart.totalTypes') }}{{ cartData[0].cartList.length }}{{ $lang('cart.types') }}</view> <view class="num-wrap">共{{ cartData[0].cartList.length }}种商品</view>
<view class="cart-action" @click="changeAction"> <view class="cart-action" @click="changeAction">
{{ isAction ? $lang('complete') : $lang('edit') }} {{ isAction ? $lang('complete') : $lang('edit') }}
</view> </view>
@@ -13,11 +13,11 @@
<view class="cart-wrap" v-for="(siteItem, siteIndex) in cartData" :key="siteIndex"> <view class="cart-wrap" v-for="(siteItem, siteIndex) in cartData" :key="siteIndex">
<view class="coupon-use-tips" v-if="discount.coupon_info"> <view class="coupon-use-tips" v-if="discount.coupon_info">
<view> <view>
<text class="title color-base-text">{{ $lang('cart.coupon') }}</text> <text class="title color-base-text">优惠券</text>
<text class="desc">{{ $lang('cart.couponDesc') }}{{ discount.coupon_info.coupon_money | moneyFormat }}{{ $lang('sku.unit') }}</text> <text class="desc">领券结算最高可减{{ discount.coupon_info.coupon_money | moneyFormat }}元</text>
</view> </view>
<view class="color-base-text" @click="$refs.couponPopup.open()"> <view class="color-base-text" @click="$refs.couponPopup.open()">
{{ $lang('cart.click') }}{{ discount.coupon_info.receive_type == 'wait' ? $lang('goods.receive') : $lang('cart.view') }} 点击{{ discount.coupon_info.receive_type == 'wait' ? '领取' : '查看' }}
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
</view> </view>
</view> </view>
@@ -120,10 +120,10 @@
@limit="goodsLimit($event, { siteIndex, cartIndex })" /> @limit="goodsLimit($event, { siteIndex, cartIndex })" />
</view> </view>
<view class="discount-wrap" v-if="manjian && manjian['sku_' + item.sku_id]"> <view class="discount-wrap" v-if="manjian && manjian['sku_' + item.sku_id]">
<text class="discount-tag">{{ $lang('goods.fullReduce') }}</text> <text class="discount-tag">满减</text>
<scroll-view scroll-x="true" class="scroll-view"> <scroll-view scroll-x="true" class="scroll-view">
<block v-for="(mitem, key) in manjian['sku_' + item.sku_id]" :key="key"> <block v-for="(mitem, key) in manjian['sku_' + item.sku_id]" :key="key">
<text v-if="mitem.discount_money">{{ $lang('goods.full') }}{{ Number(mitem.limit) }}{{ $lang('goods.minus') }}{{ <text v-if="mitem.discount_money">{{ Number(mitem.limit) }}减{{
mitem.discount_money }}</text> mitem.discount_money }}</text>
<text class="interval" v-if="mitem.discount_money"></text> <text class="interval" v-if="mitem.discount_money"></text>
</block> </block>
@@ -140,9 +140,9 @@
<view class="cart-wrap invalid" v-if="invalidGoods.length"> <view class="cart-wrap invalid" v-if="invalidGoods.length">
<view class="cart-header"> <view class="cart-header">
<view class="num-wrap"> <view class="num-wrap">
<text class="font-size-base">{{ $lang('cart.invalidGoodsCount', { count: invalidGoods.length }) }}</text> <text class="font-size-base">失效商品{{ invalidGoods.length }}件</text>
</view> </view>
<view class="cart-action color-base-text" @click="clearInvalidGoods">{{ $lang('cart.clear') }}</view> <view class="cart-action color-base-text" @click="clearInvalidGoods">清空</view>
</view> </view>
<block v-for="(goodsItem, goodsIndex) in invalidGoods" :key="goodsIndex"> <block v-for="(goodsItem, goodsIndex) in invalidGoods" :key="goodsIndex">
<view class="cart-goods invalid-goods"> <view class="cart-goods invalid-goods">
@@ -189,7 +189,7 @@
</template> </template>
</text> </text>
</view> </view>
<text class="invalid-mark">{{ $lang('cart.invalid') }}</text> <text class="invalid-mark">已失效</text>
</view> </view>
</view> </view>
</view> </view>
@@ -199,7 +199,7 @@
</block> </block>
<block v-else> <block v-else>
<view class="cart-empty"> <view class="cart-empty">
<ns-empty :text="$lang('cart.emptyCart')" :subText="$lang('cart.emptyDesc')" :isIndex="Boolean(storeToken)" <ns-empty text="购物车为空" subText="赶紧去逛逛, 购买心仪的商品吧" :isIndex="Boolean(storeToken)"
:emptyBtn="{ text: $lang('toGoodsCategoryPage'), url: '/pages_goods/category' }"></ns-empty> :emptyBtn="{ text: $lang('toGoodsCategoryPage'), url: '/pages_goods/category' }"></ns-empty>
<button type="primary" size="mini" class="button mini" v-if="!storeToken" @click="toLogin">{{ <button type="primary" size="mini" class="button mini" v-if="!storeToken" @click="toLogin">{{
$lang('toLogin') $lang('toLogin')
@@ -218,26 +218,26 @@
<uni-popup ref="discountPopup" custom-class="uni-popup-discount" type="bottom"> <uni-popup ref="discountPopup" custom-class="uni-popup-discount" type="bottom">
<view class="discount-popup popup" v-if="Object.keys(discount).length"> <view class="discount-popup popup" v-if="Object.keys(discount).length">
<view class="popup-header"> <view class="popup-header">
<text class="tit">{{ $lang('cart.discountDetail') }}</text> <text class="tit">优惠明细</text>
<text class="iconfont icon-close" @click="toggleDiscountPopup"></text> <text class="iconfont icon-close" @click="toggleDiscountPopup"></text>
</view> </view>
<view class="popup-body" :class="{ 'safe-area': isIphoneX }" @click="toggleDiscountPopup"> <view class="popup-body" :class="{ 'safe-area': isIphoneX }" @click="toggleDiscountPopup">
<view class="detail-item"> <view class="detail-item">
<view class="title">{{ $lang('cart.goodsTotal') }}</view> <view class="title">商品总额</view>
<view class="money price-font">{{ $lang('common.currencySymbol') }}{{ discount.goods_money | moneyFormat }}</view> <view class="money price-font">¥{{ discount.goods_money | moneyFormat }}</view>
</view> </view>
<view class="detail-item" v-if="discount.coupon_money > 0"> <view class="detail-item" v-if="discount.coupon_money > 0">
<view class="title">{{ $lang('goods.coupon') }}</view> <view class="title">优惠券</view>
<view class="money price-font reduce">-{{ $lang('common.currencySymbol') }}{{ discount.coupon_money | moneyFormat }}</view> <view class="money price-font reduce">-¥{{ discount.coupon_money | moneyFormat }}</view>
</view> </view>
<view class="detail-item" v-if="discount.promotion_money > 0"> <view class="detail-item" v-if="discount.promotion_money > 0">
<view class="title">{{ $lang('goods.fullReduce') }}</view> <view class="title">满减</view>
<view class="money reduce price-font">-{{ $lang('common.currencySymbol') }}{{ discount.promotion_money | moneyFormat }} <view class="money reduce price-font">-¥{{ discount.promotion_money | moneyFormat }}
</view> </view>
</view> </view>
<view class="detail-item total"> <view class="detail-item total">
<view class="title">{{ $lang('cart.total') }}</view> <view class="title">合计</view>
<view class="money price-font ">{{ $lang('common.currencySymbol') }}{{ discount.order_money | moneyFormat }}</view> <view class="money price-font ">¥{{ discount.order_money | moneyFormat }}</view>
</view> </view>
</view> </view>
<view :style="{ height: tabBarHeight }"></view> <view :style="{ height: tabBarHeight }"></view>
@@ -247,7 +247,7 @@
<uni-popup ref="couponPopup" custom-class="uni-popup-discount" type="bottom" v-if="discount.coupon_info"> <uni-popup ref="couponPopup" custom-class="uni-popup-discount" type="bottom" v-if="discount.coupon_info">
<view class="coupon-popup popup"> <view class="coupon-popup popup">
<view class="popup-header"> <view class="popup-header">
<text class="tit">{{ $lang('goods.coupon') }}</text> <text class="tit">优惠券</text>
<text class="iconfont icon-close" @click="$refs.couponPopup.close()"></text> <text class="iconfont icon-close" @click="$refs.couponPopup.close()"></text>
</view> </view>
<view class="popup-body" :class="{ 'safe-area': isIphoneX }" @click="$refs.couponPopup.close()"> <view class="popup-body" :class="{ 'safe-area': isIphoneX }" @click="$refs.couponPopup.close()">
@@ -264,14 +264,14 @@
</template> </template>
<template v-else-if="discount.coupon_info.type == 'discount'"> <template v-else-if="discount.coupon_info.type == 'discount'">
<text class="money">{{ parseFloat(discount.coupon_info.discount) }}</text> <text class="money">{{ parseFloat(discount.coupon_info.discount) }}</text>
<text class="unit">{{ $lang('coupon.discountSuffix') }}</text> <text class="unit">折</text>
</template> </template>
<view class="at-least"> <view class="at-least">
<template v-if="discount.coupon_info.at_least > 0"> <template v-if="discount.coupon_info.at_least > 0">
{{ $lang('goods.full') }}{{ discount.coupon_info.at_least }}{{ $lang('goods.usable') }} 满{{ discount.coupon_info.at_least }}可用
</template> </template>
<template v-else> <template v-else>
{{ $lang('goods.noThreshold') }} 无门槛
</template> </template>
</view> </view>
</view> </view>
@@ -281,23 +281,23 @@
<view <view
v-if="discount.coupon_info.type == 'discount' && discount.coupon_info.discount_limit > 0" v-if="discount.coupon_info.type == 'discount' && discount.coupon_info.discount_limit > 0"
class="limit"> class="limit">
{{ $lang('cart.maxDeduct') }}{{ $lang('common.currencySymbol') }}{{ discount.coupon_info.discount_limit }} 最多可抵¥{{ discount.coupon_info.discount_limit }}
</view> </view>
<view class="time font-size-goods-tag" <view class="time font-size-goods-tag"
v-if="discount.coupon_info.validity_type == 0"> v-if="discount.coupon_info.validity_type == 0">
{{ $lang('form.validityPeriod') }}{{ $util.timeStampTurnTime(discount.coupon_info.end_time) }} 有效期:{{ $util.timeStampTurnTime(discount.coupon_info.end_time) }}
</view> </view>
<view class="time font-size-goods-tag" <view class="time font-size-goods-tag"
v-else-if="discount.coupon_info.validity_type == 1"> v-else-if="discount.coupon_info.validity_type == 1">
{{ $lang('cart.validFromReceive') }}{{ discount.coupon_info.fixed_term }}{{ $lang('cart.daysValid') }} 有效期:领取之日起{{ discount.coupon_info.fixed_term }}天内有效
</view> </view>
<view class="time font-size-goods-tag" v-else>{{ $lang('cart.longTermValid') }}</view> <view class="time font-size-goods-tag" v-else>有效期:长期有效</view>
</view> </view>
<button type="primary" v-if="discount.coupon_info.receive_type != 'wait'" <button type="primary" v-if="discount.coupon_info.receive_type != 'wait'"
disabled>{{ $lang('goods.received') }}</button> disabled>已领取</button>
<button type="primary" v-else <button type="primary" v-else
@click.stop="receiveCoupon(discount.coupon_info.coupon_type_id)">{{ $lang('goods.receive') }}</button> @click.stop="receiveCoupon(discount.coupon_info.coupon_type_id)">领取</button>
</view> </view>
</view> </view>
</view> </view>
@@ -329,7 +329,7 @@
</block> </block>
</view> </view>
<view class="detail" @click="toggleDiscountPopup" v-if="Object.keys(discount).length"> <view class="detail" @click="toggleDiscountPopup" v-if="Object.keys(discount).length">
{{ $lang('cart.discountDetail') }} 优惠明细
<text class="iconfont icon-unfold" :class="{ open: !discountPopupShow }"></text> <text class="iconfont icon-unfold" :class="{ open: !discountPopupShow }"></text>
</view> </view>
</view> </view>
@@ -338,7 +338,7 @@
</view> </view>
<view class="action-btn" v-else> <view class="action-btn" v-else>
<button type="primary" size="mini" class="mini" @click="settlement" v-if="totalCount != 0"> <button type="primary" size="mini" class="mini" @click="settlement" v-if="totalCount != 0">
{{ discount.coupon_info && discount.coupon_info.receive_type == 'wait' ? $lang('cart.receiveCouponSettle') : $lang('cart.settleNow') }}({{ {{ discount.coupon_info && discount.coupon_info.receive_type == 'wait' ? '领券' : '立即' }}结算({{
totalCount }}) totalCount }})
</button> </button>
<button type="primary" size="mini" class="mini" @click="settlement" disabled v-else>{{ <button type="primary" size="mini" class="mini" @click="settlement" disabled v-else>{{

View File

@@ -46,16 +46,16 @@ export default {
this.mpShareData = res; this.mpShareData = res;
}).catch(err => { }).catch(err => {
// 如果后台没配置,用默认值 // 如果后台没配置,用默认值
this.mpShareData = { this.mpShareData = {
appMessage: { appMessage: {
title: this.$lang('goods.shareTitle'), title: '发现超多好物,快来看看',
path: '/pages_goods/category' path: '/pages_goods/category'
}, },
timeLine: { timeLine: {
title: this.$lang('goods.shareTitle'), title: '发现超多好物,快来看看',
query: '/pages_goods/category' query: '/pages_goods/category'
} }
}; };
}); });
// #endif // #endif
}, },
@@ -92,19 +92,19 @@ export default {
}, },
onShareAppMessage() { onShareAppMessage() {
return this.mpShareData?.appMessage || { return this.mpShareData?.appMessage || {
title: this.$lang('goods.shareTitle'), title: '发现超多好物,快来看看',
path: '/pages_goods/category' path: '/pages_goods/category'
}; };
}, },
onShareTimeline() { onShareTimeline() {
return this.mpShareData?.timeLine || { return this.mpShareData?.timeLine || {
title: this.$lang('goods.shareTitle'), title: '发现超多好物,快来看看',
query: '/pages_goods/category' query: '/pages_goods/category'
}; };
}, },
onAddToFavorites() { onAddToFavorites() {
return { return {
title: this.$lang('goods.shareTitle'), title: '发现超多好物,快来看看',
path: '/pages_goods/category' path: '/pages_goods/category'
}; };
} }

View File

@@ -14,13 +14,13 @@
<view class="price-info"> <view class="price-info">
<view class="icon-box"><text class="iconfont icon-tutechan"></text></view> <view class="icon-box"><text class="iconfont icon-tutechan"></text></view>
<view class="price-box"> <view class="price-box">
<view class="promotion-text">{{ $lang('goods.limitedTimeDiscount') }}</view> <view class="promotion-text">限时折扣</view>
<view class="sale-num" v-if="goodsSkuDetail.sale_show">{{ $lang('goods.sold') }}{{ goodsSkuDetail.sale_num }}{{ goodsSkuDetail.unit }}</view> <view class="sale-num" v-if="goodsSkuDetail.sale_show">已售{{ goodsSkuDetail.sale_num }}{{ goodsSkuDetail.unit }}</view>
</view> </view>
</view> </view>
<view class="countdown"> <view class="countdown">
<view class="txt">{{ $lang('goods.endsIn') }}</view> <view class="txt">距结束仅剩</view>
<view class="clockrun"> <view class="clockrun">
<uni-count-down <uni-count-down
:day="goodsSkuDetail.discountTimeMachine.d" :day="goodsSkuDetail.discountTimeMachine.d"
@@ -52,7 +52,7 @@
<image :src="$util.img('public/uniapp/goods/member_vip.png')" mode="aspectFit" show-menu-by-longpress/> <image :src="$util.img('public/uniapp/goods/member_vip.png')" mode="aspectFit" show-menu-by-longpress/>
</view> </view>
<view class="member-price-wrap" v-if="!goodsSkuDetail.market_price_show"> <view class="member-price-wrap" v-if="!goodsSkuDetail.market_price_show">
<text class="unit price-font">{{ $lang('goods.originalPrice') }}</text> <text class="unit price-font">原价</text>
<text class="unit price-font">{{ $lang('common.currencySymbol') }}</text> <text class="unit price-font">{{ $lang('common.currencySymbol') }}</text>
<text class="money price-font">{{ goodsSkuDetail.price }}</text> <text class="money price-font">{{ goodsSkuDetail.price }}</text>
</view> </view>
@@ -128,10 +128,10 @@
<!-- <view class="group-wrap card-info" v-if="goodsSkuDetail.goods_class == 5 && goodsSkuDetail.card_info && goodsSkuDetail.card_info.relation_goods.length"> <!-- <view class="group-wrap card-info" v-if="goodsSkuDetail.goods_class == 5 && goodsSkuDetail.card_info && goodsSkuDetail.card_info.relation_goods.length">
<view class="card-title">- 套餐包含以下的服务及商品 -</view> <view class="card-title">- 套餐包含以下的服务及商品 -</view>
<view class="card-desc" v-if="goodsSkuDetail.card_info.card_type == 'timecard' || goodsSkuDetail.card_info.card_type == 'commoncard'"> <view class="card-desc" v-if="goodsSkuDetail.card_info.card_type == 'timecard' || goodsSkuDetail.card_info.card_type == 'commoncard'">
{{ goodsSkuDetail.card_info.card_type == 'commoncard' ? $lang('goods.cardTotalCount', { count: goodsSkuDetail.card_info.common_num }) + ' ,' : '' }} {{ goodsSkuDetail.card_info.card_type == 'commoncard' ? '卡项内项目/商品总的可用次数为' + goodsSkuDetail.card_info.common_num + ' ,' : '' }}
{{ goodsSkuDetail.card_info.card_type == 'timecard' ? $lang('goods.unlimitedCount') + ' ,' : '' }} {{ $lang('goods.validPeriod') }}{{ {{ goodsSkuDetail.card_info.card_type == 'timecard' ? '次数不限 ,' : '' }} 有效期为{{
(goodsSkuDetail.card_info.validity_type == 0 && $lang('goods.permanent')) || (goodsSkuDetail.card_info.validity_type == 0 && '永久') ||
(goodsSkuDetail.card_info.validity_type == 1 && goodsSkuDetail.card_info.validity_day + $lang('common.days')) || (goodsSkuDetail.card_info.validity_type == 1 && goodsSkuDetail.card_info.validity_day + '天') ||
(goodsSkuDetail.card_info.validity_type == 2 && $util.timeStampTurnTime(goodsSkuDetail.card_info.validity_time)) (goodsSkuDetail.card_info.validity_type == 2 && $util.timeStampTurnTime(goodsSkuDetail.card_info.validity_time))
}} }}
</view> </view>
@@ -149,7 +149,7 @@
</view> </view>
</view> </view>
<view class="card-off" @click="cardOff = !cardOff" v-if="goodsSkuDetail.card_info.relation_goods.length > 1"> <view class="card-off" @click="cardOff = !cardOff" v-if="goodsSkuDetail.card_info.relation_goods.length > 1">
<text>{{ cardOff ? $lang('common.collapse') : $lang('common.expand') }}</text> <text>{{ cardOff ? '收起' : '展开' }}</text>
<text class="icondiy" :class="[cardOff ? 'icon-system-jiantoushang' : 'icon-system-jiantouxia']"></text> <text class="icondiy" :class="[cardOff ? 'icon-system-jiantoushang' : 'icon-system-jiantouxia']"></text>
</view> </view>
</view> --> </view> -->
@@ -173,11 +173,11 @@
<view v-if="item.type == 'reward'"> <view v-if="item.type == 'reward'">
{{ {{
parseFloat(item.at_least) > 0 parseFloat(item.at_least) > 0
? $lang('goods.fullReduce', { atLeast: decimalPointFormat(item.at_least), money: decimalPointFormat(item.money) }) ? '满' + decimalPointFormat(item.at_least) + '减' + decimalPointFormat(item.money)
: $lang('goods.noThresholdUse', { money: decimalPointFormat(item.money) }) : '无门槛使用' + decimalPointFormat(item.money)
}} }}
</view> </view>
<view v-else-if="item.type == 'discount'">{{ $lang('goods.fullDiscount', { atLeast: decimalPointFormat(item.at_least), discount: parseFloat(item.discount) }) }}</view> <view v-else-if="item.type == 'discount'">{{ '满' + decimalPointFormat(item.at_least) + '打' + parseFloat(item.discount)+'折' }}</view>
</view> </view>
</view> </view>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
@@ -192,7 +192,7 @@
</view> </view>
<view class="item free" v-if="manjian.rule_json !== null && addonIsExist.manjian" @click="openManjianPopup()"> <view class="item free" v-if="manjian.rule_json !== null && addonIsExist.manjian" @click="openManjianPopup()">
<view class="label">促销</view> <view class="label">促销</view>
<text class="free-tip color-base-text">{{ $lang('goods.fullReduce') }}</text> <text class="free-tip color-base-text">满减</text>
<text class="font-size-base value">{{ manjian.manjian_name }}</text> <text class="font-size-base value">{{ manjian.manjian_name }}</text>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
</view> </view>
@@ -217,7 +217,7 @@
<view class="group-wrap" @click="openBundlingPopup()"> <view class="group-wrap" @click="openBundlingPopup()">
<view class="goods-cell" @click="openBundlingPopup()"> <view class="goods-cell" @click="openBundlingPopup()">
<view class="box"> <view class="box">
<text class="tit">{{ $lang('goods.comboMeal') }}</text> <text class="tit">组合套餐</text>
<text>{{ bundling[0].bl_name }}</text> <text>{{ bundling[0].bl_name }}</text>
</view> </view>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
@@ -257,7 +257,7 @@
<uni-popup ref="bundlingPopup" type="bottom"> <uni-popup ref="bundlingPopup" type="bottom">
<view class="bundling-popup-layer popup-layer"> <view class="bundling-popup-layer popup-layer">
<view class="head-wrap" @click="closeBundlingPopup()"> <view class="head-wrap" @click="closeBundlingPopup()">
<text>{{ $lang('goods.comboMeal') }}</text> <text>组合套餐</text>
<text class="iconfont icon-close"></text> <text class="iconfont icon-close"></text>
</view> </view>
<scroll-view scroll-y class="bundling-body"> <scroll-view scroll-y class="bundling-body">
@@ -297,10 +297,10 @@
</view> </view>
</scroll-view> </scroll-view>
<view class="bundling-price-wrap"> <view class="bundling-price-wrap">
<text class="label">{{ $lang('goods.comboPrice') }}</text> <text class="label">套餐价</text>
<text class="unit price-color">{{ $lang('common.currencySymbol') }}</text> <text class="unit price-color">{{ $lang('common.currencySymbol') }}</text>
<text class="price price-color">{{ item.bl_price }}</text> <text class="price price-color">{{ item.bl_price }}</text>
<button type="primary" size="mini" class="mini" @click="toComoDetail(item.bl_id)">{{ $lang('goods.buyNow') }}</button> <button type="primary" size="mini" class="mini" @click="toComoDetail(item.bl_id)">立即购买</button>
</view> </view>
</view> </view>
</block> </block>
@@ -316,7 +316,7 @@
<uni-popup ref="couponPopup" type="bottom"> <uni-popup ref="couponPopup" type="bottom">
<view class="goods-coupon-popup-layer popup-layer"> <view class="goods-coupon-popup-layer popup-layer">
<view class="head-wrap" @click="closeCouponPopup()"> <view class="head-wrap" @click="closeCouponPopup()">
<text>{{ $lang('goods.coupon') }}</text> <text>优惠券</text>
<text class="iconfont icon-close"></text> <text class="iconfont icon-close"></text>
</view> </view>
<scroll-view class="coupon-body" scroll-y> <scroll-view class="coupon-body" scroll-y>
@@ -331,33 +331,33 @@
</template> </template>
<template v-else-if="item.type == 'discount'"> <template v-else-if="item.type == 'discount'">
<text class="money">{{ parseFloat(item.discount) }}</text> <text class="money">{{ parseFloat(item.discount) }}</text>
<text class="unit">{{ $lang('coupon.discountSuffix') }}</text> <text class="unit">折</text>
</template> </template>
<view class="at-least"> <view class="at-least">
<template v-if="item.at_least > 0"> <template v-if="item.at_least > 0">
{{ $lang('goods.full') }}{{ item.at_least }}{{ $lang('goods.usable') }} 满{{ item.at_least }}可用
</template> </template>
<template v-else> <template v-else>
{{ $lang('goods.noThreshold') }} 无门槛
</template> </template>
</view> </view>
</view> </view>
</view> </view>
<view class="desc-wrap"> <view class="desc-wrap">
<view class="coupon-name">{{ item.coupon_name }}</view> <view class="coupon-name">{{ item.coupon_name }}</view>
<view v-if="item.type == 'discount' && item.discount_limit > 0" class="limit">{{ $lang('goods.maxDeduct', { amount: item.discount_limit }) }}</view> <view v-if="item.type == 'discount' && item.discount_limit > 0" class="limit">最多可抵¥{{ item.discount_limit }}</view>
<view class="time font-size-goods-tag" v-if="item.validity_type == 0">{{ $lang('goods.validity') }}:{{ $util.timeStampTurnTime(item.end_time) }}</view> <view class="time font-size-goods-tag" v-if="item.validity_type == 0">有效期:{{ $util.timeStampTurnTime(item.end_time) }}</view>
<view class="time font-size-goods-tag" v-else-if="item.validity_type == 1">{{ $lang('goods.validity') }}:{{ $lang('goods.validityFromReceive', { days: item.fixed_term }) }}</view> <view class="time font-size-goods-tag" v-else-if="item.validity_type == 1">有效期:领取之日起{{ item.fixed_term }}天内有效</view>
<view class="time font-size-goods-tag" v-else>{{ $lang('goods.validity') }}:{{ $lang('goods.validityLong') }}</view> <view class="time font-size-goods-tag" v-else>有效期:长期有效</view>
</view> </view>
<button type="primary" v-if="item.useState == 2" disabled>{{ $lang('goods.taken') }}</button> <button type="primary" v-if="item.useState == 2" disabled>已抢光</button>
<button type="primary" v-else-if="item.useState == 1" disabled>{{ $lang('goods.received') }}</button> <button type="primary" v-else-if="item.useState == 1" disabled>已领取</button>
<button type="primary" v-else @click="receiveCoupon(item)">{{ $lang('goods.receive') }}</button> <button type="primary" v-else @click="receiveCoupon(item)">领取</button>
</view> </view>
</view> </view>
</scroll-view> </scroll-view>
<view class="button-box"><button type="primary" @click="closeCouponPopup()">{{ $lang('common.confirm') }}</button></view> <view class="button-box"><button type="primary" @click="closeCouponPopup()">确定</button></view>
</view> </view>
</uni-popup> </uni-popup>
</view> </view>
@@ -367,24 +367,24 @@
<uni-popup ref="manjianPopup" type="bottom"> <uni-popup ref="manjianPopup" type="bottom">
<view class="manjian-popup-layer popup-layer"> <view class="manjian-popup-layer popup-layer">
<view class="head-wrap" @click="closeManjianPopup()"> <view class="head-wrap" @click="closeManjianPopup()">
<text>{{ $lang('goods.promotion') }}</text> <text>促销</text>
<text class="iconfont icon-close"></text> <text class="iconfont icon-close"></text>
</view> </view>
<scroll-view scroll-y class="manjian-body"> <scroll-view scroll-y class="manjian-body">
<view class="item" v-if="manjian.manjian != undefined" style="display: flex;"> <view class="item" v-if="manjian.manjian != undefined" style="display: flex;">
<view class="free-tip color-base-text color-base-border">{{ $lang('goods.fullReduce') }}</view> <view class="free-tip color-base-text color-base-border">满减</view>
<text class="font-size-base">{{ manjian.manjian }}</text> <text class="font-size-base">{{ manjian.manjian }}</text>
</view> </view>
<view class="item" v-if="manjian.mansong != undefined"> <view class="item" v-if="manjian.mansong != undefined">
<text class="free-tip color-base-text color-base-border">{{ $lang('goods.fullGift') }}</text> <text class="free-tip color-base-text color-base-border">满送</text>
<text class="font-size-base">{{ manjian.mansong }}</text> <text class="font-size-base">{{ manjian.mansong }}</text>
</view> </view>
<view class="item" v-if="manjian.free_shipping != undefined" style="display: flex;"> <view class="item" v-if="manjian.free_shipping != undefined" style="display: flex;">
<view class="free-tip color-base-text color-base-border">{{ $lang('goods.freeShipping') }}</view> <view class="free-tip color-base-text color-base-border">包邮</view>
<text class="font-size-base">{{ manjian.free_shipping }}</text> <text class="font-size-base">{{ manjian.free_shipping }}</text>
</view> </view>
</scroll-view> </scroll-view>
<view class="button-box"><button type="primary" @click="closeManjianPopup()">{{ $lang('common.confirm') }}</button></view> <view class="button-box"><button type="primary" @click="closeManjianPopup()">确定</button></view>
</view> </view>
</uni-popup> </uni-popup>
</view> </view>
@@ -393,7 +393,7 @@
<uni-popup ref="informationPopup" type="bottom"> <uni-popup ref="informationPopup" type="bottom">
<view class="manjian-popup-layer popup-layer" :style="{ height: FormHeight }"> <view class="manjian-popup-layer popup-layer" :style="{ height: FormHeight }">
<view class="head-wrap" @click="closeinformationPopup()"> <view class="head-wrap" @click="closeinformationPopup()">
<text>{{ $lang('goods.goodsMessage') }}</text> <text>商品留言</text>
<text class="iconfont icon-close"></text> <text class="iconfont icon-close"></text>
</view> </view>
<scroll-view scroll-y class="manjian-body" > <scroll-view scroll-y class="manjian-body" >
@@ -414,7 +414,7 @@
<ns-form :data="informationform" ref="form"></ns-form> <ns-form :data="informationform" ref="form"></ns-form>
</view> </view>
</scroll-view> </scroll-view>
<view class="button-box"><button type="primary" @click="saveubfirnation()">{{ $lang('common.confirm') }}</button></view> <view class="button-box"><button type="primary" @click="saveubfirnation()">确定</button></view>
</view> </view>
</uni-popup> </uni-popup>
<!-- <uni-popup ref="informationPopup" type="bottom" class="sku-layer" @change="popclose"> <!-- <uni-popup ref="informationPopup" type="bottom" class="sku-layer" @change="popclose">
@@ -463,7 +463,7 @@
<ns-goods-action-button v-if="goodsSkuDetail.isinformation == 1" class="goods-action-button active3" disabled-text="" backgroundColor="#54c952" @click="phoneClick(goodsSkuDetail.goods_mobile)" :text="$lang('make')" :disabled="false" /> <ns-goods-action-button v-if="goodsSkuDetail.isinformation == 1" class="goods-action-button active3" disabled-text="" backgroundColor="#54c952" @click="phoneClick(goodsSkuDetail.goods_mobile)" :text="$lang('make')" :disabled="false" />
<ns-goods-action-button v-if="goodsSkuDetail.isinformation == 2" class="goods-action-button active3" disabled-text="" backgroundColor="#54c952" @click="showinformation" :text="$lang('leave')" :disabled="false" /> <ns-goods-action-button v-if="goodsSkuDetail.isinformation == 2" class="goods-action-button active3" disabled-text="" backgroundColor="#54c952" @click="showinformation" :text="$lang('leave')" :disabled="false" />
<ns-goods-action-button v-if="goodsSkuDetail.isinformation == 3" class="goods-action-button active3" disabled-text="" backgroundColor="#54c952" @click="goToAIChat" :text="$lang('goods.aiService')" :disabled="false" /> <ns-goods-action-button v-if="goodsSkuDetail.isinformation == 3" class="goods-action-button active3" disabled-text="" backgroundColor="#54c952" @click="goToAIChat" text="智能客服" :disabled="false" />
<!-- <ns-goods-action-button v-if="goodsSkuDetail.isinformation == 2" class="goods-action-button active3" disabled-text="" backgroundColor="#54c952" @click="buyNow" text="商品留言" :disabled="false" /> --> <!-- <ns-goods-action-button v-if="goodsSkuDetail.isinformation == 2" class="goods-action-button active3" disabled-text="" backgroundColor="#54c952" @click="buyNow" text="商品留言" :disabled="false" /> -->
</block> </block>
@@ -520,11 +520,11 @@
<uni-popup ref="contactPopup" type="center"> <uni-popup ref="contactPopup" type="center">
<view class="contact-popup"> <view class="contact-popup">
<view class="contact-content"> <view class="contact-content">
<text class="contact-text">{{ $lang('goods.callOnMobile', { phone: '021-51815181' }) }}</text> <text class="contact-text">可在手机端拨打 021-51815181</text>
</view> </view>
<view class="contact-buttons"> <view class="contact-buttons">
<button class="contact-btn cancel-btn" @click="closeContactPopup">{{ $lang('common.cancel') }}</button> <button class="contact-btn cancel-btn" @click="closeContactPopup">取消</button>
<button class="contact-btn copy-btn" @click="copyPhoneNumber">{{ $lang('goods.copyToClipboard') }}</button> <button class="contact-btn copy-btn" @click="copyPhoneNumber">复制到剪切板</button>
</view> </view>
</view> </view>
</uni-popup> </uni-popup>
@@ -588,7 +588,7 @@ export default {
data: '021-51815181', data: '021-51815181',
success: () => { success: () => {
uni.showToast({ uni.showToast({
title: this.$lang('common.copySuccess'), title: '复制成功',
icon: 'success' icon: 'success'
}); });
this.closeContactPopup(); this.closeContactPopup();

View File

@@ -5,7 +5,7 @@
<view class="search-wrap uni-flex uni-row"> <view class="search-wrap uni-flex uni-row">
<view class="flex-item input-wrap"> <view class="flex-item input-wrap">
<input class="uni-input" maxlength="50" v-model="keyword" @confirm="search()" <input class="uni-input" maxlength="50" v-model="keyword" @confirm="search()"
:placeholder="langstatus ? $lang('Search') : $lang('goods.searchGoods')" /> :placeholder="langstatus ? $lang('Search') : '请输入您要搜索的商品'" />
<text class="iconfont icon-sousuo3" @click.stop="search()"></text> <text class="iconfont icon-sousuo3" @click.stop="search()"></text>
</view> </view>
<view class="iconfont" :class="{ 'icon-apps': isList, 'icon-list': !isList }" <view class="iconfont" :class="{ 'icon-apps': isList, 'icon-list': !isList }"
@@ -16,16 +16,16 @@
<view class="sort-wrap"> <view class="sort-wrap">
<view class="comprehensive-wrap" :class="{ 'color-base-text': orderType === '' }" <view class="comprehensive-wrap" :class="{ 'color-base-text': orderType === '' }"
@click="sortTabClick('')"> @click="sortTabClick('')">
<text :class="{ 'color-base-text': orderType === '' }">{{ langstatus ? $lang('Random') : $lang('goods.comprehensive') }}</text> <text :class="{ 'color-base-text': orderType === '' }">{{ langstatus ? $lang('Random') : '综合' }}</text>
</view> </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')">
{{ langstatus ? $lang('Sales') : $lang('chat.sales') }} {{ langstatus ? $lang('Sales') : '销量' }}
</view> </view>
<view class="price-wrap" @click="sortTabClick('discount_price')"> <view class="price-wrap" @click="sortTabClick('discount_price')">
<text <text
:class="{ 'color-base-text': orderType === 'discount_price' }">{{ langstatus ? $lang('Price') : $lang('goods.price') }}</text> :class="{ 'color-base-text': orderType === 'discount_price' }">{{ langstatus ? $lang('Price') : '价格' }}</text>
<view class="iconfont-wrap"> <view class="iconfont-wrap">
<view class="iconfont icon-iconangledown-copy asc" <view class="iconfont icon-iconangledown-copy asc"
:class="{ 'color-base-text': priceOrder === 'asc' && orderType === 'discount_price' }"> :class="{ 'color-base-text': priceOrder === 'asc' && orderType === 'discount_price' }">
@@ -37,7 +37,7 @@
</view> </view>
<view :class="{ 'color-base-text': orderType === 'screen' }" class="screen-wrap"> <view :class="{ 'color-base-text': orderType === 'screen' }" class="screen-wrap">
<text @click="sortTabClick('screen')">{{ langstatus ? $lang('Filter') : $lang('goods.filter') }}</text> <text @click="sortTabClick('screen')">{{ langstatus ? $lang('Filter') : '筛选' }}</text>
<view @click="sortTabClick('screen')" class="iconfont-wrap"> <view @click="sortTabClick('screen')" class="iconfont-wrap">
<view class="iconfont icon-shaixuan color-tip"></view> <view class="iconfont icon-shaixuan color-tip"></view>
</view> </view>
@@ -78,8 +78,8 @@
</view> </view>
<view class="pro-info" v-if="item.isinformation == 0"> <view class="pro-info" v-if="item.isinformation == 0">
<view class="block-wrap"> <view class="block-wrap">
<view class="sale" v-if="item.sale_show">{{ $lang('goods.sold') }}{{ item.sale_num }}{{ item.unit <view class="sale" v-if="item.sale_show">已售{{ item.sale_num }}{{ item.unit
? item.unit : $lang('sku.unit') }}</view> ? item.unit : '件' }}</view>
</view> </view>
<view class="cart-action-wrap" v-if="config.control && item.is_virtual == 0"> <view class="cart-action-wrap" v-if="config.control && item.is_virtual == 0">
<view class="cart buy-btn click-wrap" :id="'goods-' + item.id" <view class="cart buy-btn click-wrap" :id="'goods-' + item.id"
@@ -126,8 +126,8 @@
</view> </view>
<view class="pro-info" v-if="item.isinformation == 0"> <view class="pro-info" v-if="item.isinformation == 0">
<view class="block-wrap"> <view class="block-wrap">
<view class="sale" v-if="item.sale_show">{{ $lang('goods.sold') }}{{ item.sale_num }}{{ item.unit <view class="sale" v-if="item.sale_show">已售{{ item.sale_num }}{{ item.unit
? item.unit : $lang('sku.unit') }}</view> ? item.unit : '件' }}</view>
</view> </view>
<view class="cart-action-wrap" v-if="config.control && item.is_virtual == 0"> <view class="cart-action-wrap" v-if="config.control && item.is_virtual == 0">
<view class="cart buy-btn click-wrap" :id="'goods-' + item.id" <view class="cart buy-btn click-wrap" :id="'goods-' + item.id"
@@ -145,7 +145,7 @@
</view> </view>
</view> </view>
</view> </view>
<view v-if="goodsList.length == 0 && emptyShow"><ns-empty :text="$lang('goods.noGoods')"></ns-empty></view> <view v-if="goodsList.length == 0 && emptyShow"><ns-empty text="暂无商品"></ns-empty></view>
</block> </block>
</mescroll-uni> </mescroll-uni>
@@ -153,11 +153,11 @@
<!-- 筛选弹出框 --> <!-- 筛选弹出框 -->
<uni-drawer :visible="showScreen" mode="right" @close="showScreen = false" class="screen-wrap"> <uni-drawer :visible="showScreen" mode="right" @close="showScreen = false" class="screen-wrap">
<view class="title color-tip">{{ $lang('goodsList.filter') }}</view> <view class="title color-tip">筛选</view>
<scroll-view scroll-y> <scroll-view scroll-y>
<!-- 包邮 --> <!-- 包邮 -->
<!-- <view class="item-wrap"> <!-- <view class="item-wrap">
<view class="label"><text>{{ $lang('goodsList.freeShipping') }}</text></view> <view class="label"><text>是否包邮</text></view>
<view class="list"> <view class="list">
<uni-tag :inverted="true" text="包邮" :type="isFreeShipping ? 'primary' : 'default'" @click="isFreeShipping = !isFreeShipping" /> <uni-tag :inverted="true" text="包邮" :type="isFreeShipping ? 'primary' : 'default'" @click="isFreeShipping = !isFreeShipping" />
</view> </view>
@@ -165,7 +165,7 @@
<!-- 价格筛选项 --> <!-- 价格筛选项 -->
<!-- <view class="item-wrap"> <!-- <view class="item-wrap">
<view class="label"><text>{{ $lang('goodsList.priceRange') }}</text></view> <view class="label"><text>价格区间(元)</text></view>
<view class="price-wrap"> <view class="price-wrap">
<input class="uni-input" type="digit" v-model="minPrice" placeholder="最低价" /> <input class="uni-input" type="digit" v-model="minPrice" placeholder="最低价" />
<view class="h-line"></view> <view class="h-line"></view>
@@ -175,7 +175,7 @@
<!-- 品牌筛选项 --> <!-- 品牌筛选项 -->
<!-- <view class="item-wrap" v-if="brandList.length > 0"> <!-- <view class="item-wrap" v-if="brandList.length > 0">
<view class="label"><text>{{ $lang('goodsList.brand') }}</text></view> <view class="label"><text>品牌</text></view>
<view class="list"> <view class="list">
<view v-for="(item, index) in brandList" :key="index"> <view v-for="(item, index) in brandList" :key="index">
<uni-tag :inverted="true" :text="item.brand_name" :type="item.brand_id == brandId ? 'primary' : 'default'" @click="brandId == item.brand_id ? (brandId = 0) : (brandId = item.brand_id)" /> <uni-tag :inverted="true" :text="item.brand_name" :type="item.brand_id == brandId ? 'primary' : 'default'" @click="brandId == item.brand_id ? (brandId = 0) : (brandId = item.brand_id)" />
@@ -185,10 +185,10 @@
<!-- 分类筛选项 --> <!-- 分类筛选项 -->
<view class="category-list-wrap"> <view class="category-list-wrap">
<text class="first">{{ $lang('goodsList.allCategory') }}</text> <text class="first">全部分类</text>
<view class="class-box"> <view class="class-box">
<view @click="selectedCategory('')" class="list-wrap"> <view @click="selectedCategory('')" class="list-wrap">
<text :class="{ selected: !categoryId, 'color-base-text': !categoryId }">{{ $lang('goodsList.all') }}</text> <text :class="{ selected: !categoryId, 'color-base-text': !categoryId }">全部</text>
</view> </view>
<view @click="selectedCategory(item.category_id)" v-for="(item, index) in categoryList" <view @click="selectedCategory(item.category_id)" v-for="(item, index) in categoryList"
:key="index" class="list-wrap"> :key="index" class="list-wrap">
@@ -200,8 +200,8 @@
</view> </view>
</scroll-view> </scroll-view>
<view class="footer" :class="{ 'safe-area': isIphoneX }"> <view class="footer" :class="{ 'safe-area': isIphoneX }">
<button type="default" class="footer-box" @click="resetData">{{ $lang('goodsList.reset') }}</button> <button type="default" class="footer-box" @click="resetData">重置</button>
<button type="primary" class="footer-box1" @click="screenData">{{ $lang('goodsList.confirm') }}</button> <button type="primary" class="footer-box1" @click="screenData">确定</button>
</view> </view>
</uni-drawer> </uni-drawer>
<loading-cover ref="loadingCover"></loading-cover> <loading-cover ref="loadingCover"></loading-cover>

View File

@@ -233,14 +233,14 @@ export default {
} }
if (cart_id.length == 0) { if (cart_id.length == 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('cart.selectGoodsToDelete') title: '请选择要删除的商品'
}); });
return; return;
} }
uni.showModal({ uni.showModal({
title: this.$lang('common.tip'), title: '提示',
content: cart_id.length > 1 ? this.$lang('cart.confirmDeleteSelected') : this.$lang('cart.confirmDeleteOne'), content: cart_id.length > 1 ? '确定要删除这些商品吗?' : '确定要删除该商品吗?',
success: res => { success: res => {
if (res.confirm) { if (res.confirm) {
cart_id = cart_id.toString(); cart_id = cart_id.toString();
@@ -381,8 +381,8 @@ export default {
*/ */
clearInvalidGoods() { clearInvalidGoods() {
uni.showModal({ uni.showModal({
title: this.$lang('common.tip'), title: '提示',
content: this.$lang('cart.confirmClearInvalid'), content: '确定要清空这些商品吗?',
success: res => { success: res => {
if (res.confirm) { if (res.confirm) {
var cart_ids = []; var cart_ids = [];
@@ -432,11 +432,11 @@ export default {
if (event.type == 'plus') { if (event.type == 'plus') {
if (data.max_buy > 0 && data.max_buy < data.stock) { if (data.max_buy > 0 && data.max_buy < data.stock) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('cart.personLimit', { count: data.max_buy }) title: '该商品每人限购' + data.max_buy + '件'
}); });
} else { } else {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('sku.insufficientStock') title: '库存不足'
}); });
} }
} else { } else {

View File

@@ -318,9 +318,9 @@ export default {
let list = this.couponList; let list = this.couponList;
if (res.data.is_exist == 1 && res.code < 0) { if (res.data.is_exist == 1 && res.code < 0) {
msg = this.$lang('goods.couponAlreadyClaimed'); msg = '您已领取过该优惠券,快去使用吧';
} else if (res.code == 0) { } else if (res.code == 0) {
msg = this.$lang('goods.couponClaimSuccess'); msg = '领取成功,快去使用吧';
} else { } else {
msg = res.message; msg = res.message;
} }
@@ -362,7 +362,7 @@ export default {
//获取满减信息 //获取满减信息
getManjian(data) { getManjian(data) {
this.manjian = data; this.manjian = data;
let limit = data.type == 0 ? this.$lang('goods.yuan') : this.$lang('goods.piece'); let limit = data.type == 0 ? '元' : '件';
Object.keys(data.rule_json).forEach((key) => { Object.keys(data.rule_json).forEach((key) => {
var item = data.rule_json[key]; var item = data.rule_json[key];
if (item.coupon_data) { if (item.coupon_data) {
@@ -374,40 +374,40 @@ export default {
// 满减 // 满减
if (item.discount_money != undefined) { if (item.discount_money != undefined) {
if (this.manjian.manjian == undefined) { if (this.manjian.manjian == undefined) {
this.manjian.manjian = this.$lang('goods.spendLimitMinus', { limit: item.limit, unit: limit, money: item.discount_money }); this.manjian.manjian = '满' + item.limit + limit + '减' + item.discount_money + '元';
} else { } else {
this.manjian.manjian += this.$lang('goods.semicolonSpendLimitMinus', { limit: item.limit, unit: limit, money: item.discount_money }); this.manjian.manjian += ';满' + item.limit + limit + '减' + item.discount_money + '元';
} }
} }
// 满送 // 满送
if (item.point != undefined || item.coupon != undefined) { if (item.point != undefined || item.coupon != undefined) {
let text = ''; let text = '';
if (item.point != undefined) { if (item.point != undefined) {
text = this.$lang('goods.givePoints', { points: item.point }); text = '送' + item.point + '积分';
} }
if (item.coupon != undefined && item.coupon_data != undefined) { if (item.coupon != undefined && item.coupon_data != undefined) {
item.coupon_data.forEach((couponItem, couponIndex) => { item.coupon_data.forEach((couponItem, couponIndex) => {
if (couponItem.type == 'discount') { if (couponItem.type == 'discount') {
if (text == '') text = this.$lang('goods.giveDiscountCoupon', { num: item.coupon_num[couponIndex], discount: parseFloat(couponItem.discount) }); if (text == '') text = '送' + item.coupon_num[couponIndex] + '张' + parseFloat(couponItem.discount) + '折优惠券';
else text += this.$lang('goods.andGiveDiscountCoupon', { num: item.coupon_num[couponIndex], discount: parseFloat(couponItem.discount) }); else text += '、送' + item.coupon_num[couponIndex] + '张' + parseFloat(couponItem.discount) + '折优惠券';
} else { } else {
if (text == '') text = this.$lang('goods.giveMoneyCoupon', { num: item.coupon_num[couponIndex], money: parseFloat(couponItem.money) }); if (text == '') text = '送' + item.coupon_num[couponIndex] + '张' + parseFloat(couponItem.money) + '元优惠券';
else text += this.$lang('goods.andGiveMoneyCoupon', { num: item.coupon_num[couponIndex], money: parseFloat(couponItem.money) }); else text += '、送' + item.coupon_num[couponIndex] + '张' + parseFloat(couponItem.money) + '元优惠券';
} }
}) })
} }
if (this.manjian.mansong == undefined) { if (this.manjian.mansong == undefined) {
this.manjian.mansong = this.$lang('goods.spendLimit', { limit: item.limit, unit: limit }) + text; this.manjian.mansong = '满' + item.limit + limit + text;
} else { } else {
this.manjian.mansong += this.$lang('goods.semicolonSpend') + this.$lang('goods.spendLimit', { limit: item.limit, unit: limit }) + text; this.manjian.mansong += ';' + '满' + item.limit + limit + text;
} }
} }
// 包邮 // 包邮
if (item.free_shipping != undefined) { if (item.free_shipping != undefined) {
if (this.manjian.free_shipping == undefined) { if (this.manjian.free_shipping == undefined) {
this.manjian.free_shipping = this.$lang('goods.spendLimitFreeShipping', { limit: item.limit, unit: limit }); this.manjian.free_shipping = '满' + item.limit + limit + '包邮';
} else { } else {
this.manjian.free_shipping += this.$lang('goods.semicolonSpendLimitFreeShipping', { limit: item.limit, unit: limit }); this.manjian.free_shipping += ';满' + item.limit + limit + '包邮';
} }
} }
}); });

View File

@@ -37,7 +37,7 @@ export default {
fontWeight: false, fontWeight: false,
padding: 0, padding: 0,
cartEvent: "detail", cartEvent: "detail",
text: this.$lang('goods.buy'), text: "购买",
textColor: "#FFFFFF", textColor: "#FFFFFF",
theme: "default", theme: "default",
aroundRadius: 25, aroundRadius: 25,
@@ -75,7 +75,7 @@ export default {
if(this.langstatus == 1){ if(this.langstatus == 1){
// this.$langConfig.refresh(); // this.$langConfig.refresh();
uni.setNavigationBarTitle({ uni.setNavigationBarTitle({
title: this.$lang('goods.goodsList') title:uni.getStorageSync('lang') == 'en-us'?'Goods List':'商品列表'
}) })
} }
} }
@@ -123,7 +123,7 @@ export default {
* 转发分享 * 转发分享
*/ */
onShareAppMessage(res) { onShareAppMessage(res) {
var title = this.$lang('goods.searchResultCount', { count: this.count, keyword: this.keyword + this.category_title + this.coupon_name });'”相关的优质商品'; var title = '搜索到' + this.count + '件“' + this.keyword + this.category_title + this.coupon_name + '”相关的优质商品';
let route = this.$util.getCurrentShareRoute(this.memberInfo ? this.memberInfo.member_id : 0); let route = this.$util.getCurrentShareRoute(this.memberInfo ? this.memberInfo.member_id : 0);
var path = route.path; var path = route.path;
return { return {
@@ -137,7 +137,7 @@ export default {
}, },
// 分享到微信朋友圈 // 分享到微信朋友圈
onShareTimeline() { onShareTimeline() {
var title = this.$lang('goods.searchResultCount', { count: this.count, keyword: this.keyword + this.category_title + this.coupon_name });'”相关的优质商品'; var title = '搜索到' + this.count + '件“' + this.keyword + this.category_title + this.coupon_name + '”相关的优质商品';
let route = this.$util.getCurrentShareRoute(this.memberInfo ? this.memberInfo.member_id : 0); let route = this.$util.getCurrentShareRoute(this.memberInfo ? this.memberInfo.member_id : 0);
var query = route.query; var query = route.query;
return { return {
@@ -362,26 +362,26 @@ export default {
// } // }
if (!Number(this.maxPrice) && this.maxPrice) { if (!Number(this.maxPrice) && this.maxPrice) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('goods.inputMaxPrice') title: '请输入最高价'
}); });
return; return;
} }
if (Number(this.minPrice) < 0 || Number(this.maxPrice) < 0) { if (Number(this.minPrice) < 0 || Number(this.maxPrice) < 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('goods.priceNotNegative') title: '筛选价格不能小于0'
}); });
return; return;
} }
if (this.minPrice != '' && Number(this.minPrice) > Number(this.maxPrice) && this.maxPrice) { if (this.minPrice != '' && Number(this.minPrice) > Number(this.maxPrice) && this.maxPrice) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('goods.minNotGreaterMax') title: '最低价不能大于最高价'
}); });
return; return;
} }
if (this.maxPrice != '' && Number(this.maxPrice) < Number(this.minPrice)) { if (this.maxPrice != '' && Number(this.maxPrice) < Number(this.minPrice)) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('goods.maxNotLessMin') title: '最高价不能小于最低价'
}); });
return; return;
} }

View File

@@ -4,7 +4,7 @@
<view class="payment-navbar" :style="{ 'padding-top': menuButtonBounding.top + 'px', height: menuButtonBounding.height + 'px' }"> <view class="payment-navbar" :style="{ 'padding-top': menuButtonBounding.top + 'px', height: menuButtonBounding.height + 'px' }">
<view class="nav-wrap"> <view class="nav-wrap">
<text class="iconfont icon-back_light" @click="back"></text> <text class="iconfont icon-back_light" @click="back"></text>
<view class="navbar-title">{{ $lang('order.confirmOrder') }}</view> <view class="navbar-title">确认订单</view>
</view> </view>
</view> </view>
<view class="payment-navbar-block" :style="{ height: menuButtonBounding.bottom + 'px' }"></view> <view class="payment-navbar-block" :style="{ height: menuButtonBounding.bottom + 'px' }"></view>
@@ -18,14 +18,14 @@
<view class="mobile-wrap"> <view class="mobile-wrap">
<view class="tips color-base-text"> <view class="tips color-base-text">
<text class="iconfont icongantanhao"></text> <text class="iconfont icongantanhao"></text>
{{ $lang('order.virtualGoodsMobileTip') }} 购买虚拟类商品需填写手机号,方便商家与您联系
</view> </view>
<view class="form-group"> <view class="form-group">
<text class="icon"> <text class="icon">
<image :src="$util.img('public/uniapp/order/icon-mobile.png')" mode="widthFix"></image> <image :src="$util.img('public/uniapp/order/icon-mobile.png')" mode="widthFix"></image>
</text> </text>
<text class="text">{{ $lang('order.mobilePhone') }}</text> <text class="text">手机号码</text>
<input type="number" maxlength="11" :placeholder="$lang('order.inputMobile')" placeholder-class="color-tip placeholder" class="input" v-model="orderCreateData.member_address.mobile" /> <input type="number" maxlength="11" placeholder="请输入您的手机号码" placeholder-class="color-tip placeholder" class="input" v-model="orderCreateData.member_address.mobile" />
</view> </view>
</view> </view>
</template> </template>
@@ -54,7 +54,7 @@
<text class="cell-more iconfont icon-right"></text> <text class="cell-more iconfont icon-right"></text>
</view> </view>
<view class="empty-wrap" v-else @click="selectAddress"> <view class="empty-wrap" v-else @click="selectAddress">
<view class="info">{{ $lang('order.setAddress') }}</view> <view class="info">请设置收货地址</view>
<view class="cell-more"> <view class="cell-more">
<view class="iconfont icon-right"></view> <view class="iconfont icon-right"></view>
</view> </view>
@@ -67,18 +67,18 @@
<block v-if="storeList && Object.keys(storeList).length > 1"> <block v-if="storeList && Object.keys(storeList).length > 1">
<view class="local-delivery-store" v-if="storeInfo" @click="openPopup('deliveryPopup')"> <view class="local-delivery-store" v-if="storeInfo" @click="openPopup('deliveryPopup')">
<view class="info"> <view class="info">
{{ $lang('order.deliveredBy') }} 由
<text class="store-name">{{ storeInfo.store_name }}</text> <text class="store-name">{{ storeInfo.store_name }}</text>
{{ $lang('order.provideDelivery') }} 提供配送
</view> </view>
<view class="cell-more"> <view class="cell-more">
<text>{{ $lang('order.clickSwitch') }}</text> <text>点击切换</text>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
</view> </view>
</view> </view>
<view v-else class="local-delivery-store"> <view v-else class="local-delivery-store">
<view class="info"> <view class="info">
<text class="store-name">{{ $lang('order.noDeliveryStore') }}</text> <text class="store-name">您的附近没有可配送的门店,请选择其他配送方式</text>
</view> </view>
</view> </view>
</block> </block>
@@ -97,16 +97,16 @@
</view> </view>
<view class="local-box" v-if="calculateGoodsData.config.local && calculateGoodsData.delivery.local.info.time_is_open == 1"> <view class="local-box" v-if="calculateGoodsData.config.local && calculateGoodsData.delivery.local.info.time_is_open == 1">
<view class="pick-block" @click="localtime('')"> <view class="pick-block" @click="localtime('')">
<view class="title font-size-base">{{ $lang('order.deliverTime') }}</view> <view class="title font-size-base">送达时间</view>
<view class="time-picker"> <view class="time-picker">
<text :class="{ 'color-tip': !deliveryTime }">{{ deliveryTime ? deliveryTime : $lang('order.selectDeliverTime') }}</text> <text :class="{ 'color-tip': !deliveryTime }">{{ deliveryTime ? deliveryTime : '请选择送达时间' }}</text>
<text class="iconfont icon-right cell-more"></text> <text class="iconfont icon-right cell-more"></text>
</view> </view>
</view> </view>
</view> </view>
</view> </view>
<view class="empty-wrap" v-else @click="selectAddress"> <view class="empty-wrap" v-else @click="selectAddress">
<view class="info">{{ $lang('order.setAddress') }}</view> <view class="info">请设置收货地址</view>
<view class="cell-more"> <view class="cell-more">
<view class="iconfont icon-right"></view> <view class="iconfont icon-right"></view>
</view> </view>
@@ -125,8 +125,8 @@
<text>{{ storeInfo.store_name }}</text> <text>{{ storeInfo.store_name }}</text>
</view> </view>
<view class="store-detail"> <view class="store-detail">
<view v-if="storeInfo.open_date">{{ $lang('order.businessHours') }}:{{ storeInfo.open_date }}</view> <view v-if="storeInfo.open_date">营业时间:{{ storeInfo.open_date }}</view>
<view class="address">{{ $lang('order.address') }}:{{ storeInfo.full_address }} {{ storeInfo.address }} <view class="address">{{ storeInfo.full_address }} {{ storeInfo.address }}
</view> </view>
</view> </view>
</view> </view>
@@ -135,25 +135,25 @@
</view> </view>
<view class="mobile-wrap store-mobile" v-if="orderCreateData.member_address"> <view class="mobile-wrap store-mobile" v-if="orderCreateData.member_address">
<view class="form-group"> <view class="form-group">
<text class="text">{{ $lang('order.name') }}</text> <text class="text">姓名</text>
<input type="text" placeholder-class="color-tip placeholder" class="input" disabled v-model="orderCreateData.member_address.name" /> <input type="text" placeholder-class="color-tip placeholder" class="input" disabled v-model="orderCreateData.member_address.name" />
</view> </view>
</view> </view>
<view class="mobile-wrap store-mobile" v-if="orderCreateData.member_address"> <view class="mobile-wrap store-mobile" v-if="orderCreateData.member_address">
<view class="form-group"> <view class="form-group">
<text class="text">{{ $lang('order.phone') }}</text> <text class="text">预留手机</text>
<input type="number" maxlength="11" :placeholder="$lang('order.inputMobile')" placeholder-class="color-tip placeholder" class="input" v-model="orderCreateData.member_address.mobile" /> <input type="number" maxlength="11" placeholder="请输入您的手机号码" placeholder-class="color-tip placeholder" class="input" v-model="orderCreateData.member_address.mobile" />
</view> </view>
</view> </view>
<view class="store-time" @click="storetime('')"> <view class="store-time" @click="storetime('')">
<view class="left">{{ $lang('order.pickupTime') }}</view> <view class="left">提货时间</view>
<view class="right"> <view class="right">
{{ deliveryTime }} {{ deliveryTime }}
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
</view> </view>
</view> </view>
</block> </block>
<view v-else class="empty">{{ $lang('order.noPickupStoreForDelivery') }}</view> <view v-else class="empty">当前无自提门店,请选择其它配送方式</view>
<image class="address-line" :src="$util.img('public/uniapp/order/address-line.png')" show-menu-by-longpress></image> <image class="address-line" :src="$util.img('public/uniapp/order/address-line.png')" show-menu-by-longpress></image>
</view> </view>
</template> </template>
@@ -189,7 +189,7 @@
goodsItem.support_trade_type.indexOf(orderCreateData.delivery.delivery_type) == -1 goodsItem.support_trade_type.indexOf(orderCreateData.delivery.delivery_type) == -1
"> ">
<text class="iconfont icon-gantanhao"></text> <text class="iconfont icon-gantanhao"></text>
<text>{{ $lang('order.goodsNotSupportDelivery') }}{{ orderCreateData.delivery.delivery_type_name }}</text> <text>该商品不支持{{ orderCreateData.delivery.delivery_type_name }}</text>
</view> </view>
</block> </block>
<view class="error-tips" v-if="goodsItem.error && goodsItem.error.message"> <view class="error-tips" v-if="goodsItem.error && goodsItem.error.message">
@@ -224,22 +224,22 @@
<view class="order-money" style="margin: 0;"> <view class="order-money" style="margin: 0;">
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.buyerMessage') }}</text> <text class="tit">买家留言</text>
<view class="box text-overflow " @click="openPopup('buyerMessagePopup')"> <view class="box text-overflow " @click="openPopup('buyerMessagePopup')">
<text v-if="orderCreateData.buyer_message">{{ orderCreateData.buyer_message[calculateGoodsData.merch_id] }}</text> <text v-if="orderCreateData.buyer_message">{{ orderCreateData.buyer_message[calculateGoodsData.merch_id] }}</text>
<text class="color-sub" v-else>{{ $lang('order.noMessage') }}</text> <text class="color-sub" v-else>无留言</text>
</view> </view>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
</view> </view>
<view class="order-cell coupon" v-if="modules.indexOf('coupon') != -1"> <view class="order-cell coupon" v-if="modules.indexOf('coupon') != -1">
<text class="tit">{{ $lang('order.coupon') }}</text> <text class="tit">优惠券</text>
<view class="box text-overflow"@click="openSiteCoupon(calculateGoodsData.merch_id)"> <view class="box text-overflow"@click="openSiteCoupon(calculateGoodsData.merch_id)">
<template v-if="orderCreateData.coupon[calculateGoodsData.merch_id].coupon_id"> <template v-if="orderCreateData.coupon[calculateGoodsData.merch_id].coupon_id">
<text class="money price-font" style="max-width: 100%;">{{ $lang('order.couponSelected') }}</text> <text class="money price-font" style="max-width: 100%;">已选择1张优惠券</text>
<!-- <text class="unit price-font">优惠</text> <!-- <text class="unit price-font">优惠</text>
<text class="money price-font">{{ (calculateData && calculateData.coupon_money ? calculateData.coupon_money : 0) | moneyFormat }}</text> --> <text class="money price-font">{{ (calculateData && calculateData.coupon_money ? calculateData.coupon_money : 0) | moneyFormat }}</text> -->
</template> </template>
<text v-else>{{ $lang('order.noUseCoupon') }}</text> <text v-else>不使用优惠券</text>
</view> </view>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
</view> </view>
@@ -247,8 +247,8 @@
<view class="site-wrap buyer-message"> <view class="site-wrap buyer-message">
<view class="order-cell"> <view class="order-cell">
<view class="box shop-item"> <view class="box shop-item">
<text class="color-tip goods-num">{{ $lang('order.totalItems', { count: calculateGoodsData.goods_num }) }}</text> <text class="color-tip goods-num">共{{ calculateGoodsData.goods_num }}件</text>
<text class="font-size-base">{{ $lang('order.subtotal') }}</text> <text class="font-size-base">小计:</text>
<text class="color-base-text unit">{{ $lang('common.currencySymbol') }}</text> <text class="color-base-text unit">{{ $lang('common.currencySymbol') }}</text>
<text class="color-base-text money">{{ calculateGoodsData.goods_money | moneyFormat }}</text> <text class="color-base-text money">{{ calculateGoodsData.goods_money | moneyFormat }}</text>
</view> </view>
@@ -300,8 +300,8 @@
<view class="order-cell order-invoice-cell" v-if="goodsData.invoice.invoice_status == 1"> <view class="order-cell order-invoice-cell" v-if="goodsData.invoice.invoice_status == 1">
<text class="tit">发票</text> <text class="tit">发票</text>
<view class="box text-overflow" @click="openPopup('invoicePopup')"> <view class="box text-overflow" @click="openPopup('invoicePopup')">
<text v-if="orderCreateData.is_invoice == 1">{{ orderCreateData.invoice_type == 1 ? $lang('payment.paperInvoice') : $lang('payment.eInvoice') }}发票({{ orderCreateData.invoice_content }})</text> <text v-if="orderCreateData.is_invoice == 1">{{ orderCreateData.invoice_type == 1 ? '纸质' : '电子' }}发票({{ orderCreateData.invoice_content }})</text>
<text v-else>{{ $lang('payment.noInvoice') }}</text> <text v-else>无需发票</text>
</view> </view>
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
</view> </view>
@@ -312,10 +312,10 @@
<view class="head" @click="selectMemberCard"> <view class="head" @click="selectMemberCard">
<text class="iconfont icon-huiyuan"></text> <text class="iconfont icon-huiyuan"></text>
<view class="info"> <view class="info">
{{ $lang('order.openMemberCard', { name: paymentData.recommend_member_card.level_name }) }} 开通{{ paymentData.recommend_member_card.level_name }}
<text>{{ $lang('order.estimatedSavings') }}</text> <text>本单预计可省</text>
<text class="price-color">{{ paymentData.recommend_member_card.discount_money | moneyFormat }}</text> <text class="price-color">{{ paymentData.recommend_member_card.discount_money | moneyFormat }}</text>
<text>{{ $lang('common.yuan') }}</text> <text>元</text>
</view> </view>
<text class="iconfont" :class="orderCreateData.is_open_card == 1 ? 'icon-yuan_checked color-base-text' : 'icon-yuan_checkbox'"></text> <text class="iconfont" :class="orderCreateData.is_open_card == 1 ? 'icon-yuan_checked color-base-text' : 'icon-yuan_checkbox'"></text>
</view> </view>
@@ -332,14 +332,14 @@
<template v-if="calculateData"> <template v-if="calculateData">
<view class="order-money"> <view class="order-money">
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.goodsAmount') }}</text> <text class="tit">商品金额</text>
<view class="box"> <view class="box">
<text class="unit color-title price-font">{{ $lang('common.currencySymbol') }}</text> <text class="unit color-title price-font">{{ $lang('common.currencySymbol') }}</text>
<text class="money color-title price-font">{{ calculateData.goods_money | moneyFormat }}</text> <text class="money color-title price-font">{{ calculateData.goods_money | moneyFormat }}</text>
</view> </view>
</view> </view>
<view class="order-cell" v-if="calculateData.is_virtual == 0 && calculateData.delivery_money > 0"> <view class="order-cell" v-if="calculateData.is_virtual == 0 && calculateData.delivery_money > 0">
<text class="tit">{{ $lang('order.shippingFee') }}</text> <text class="tit">运费</text>
<view class="box color-base-text"> <view class="box color-base-text">
<text class="operator">+</text> <text class="operator">+</text>
<text class="unit price-font">{{ $lang('common.currencySymbol') }}</text> <text class="unit price-font">{{ $lang('common.currencySymbol') }}</text>
@@ -366,7 +366,7 @@
</view> </view>
</view> --> </view> -->
<view class="order-cell" v-if="calculateData.promotion_money > 0"> <view class="order-cell" v-if="calculateData.promotion_money > 0">
<text class="tit">{{ $lang('order.discount') }}</text> <text class="tit">优惠</text>
<view class="box color-base-text"> <view class="box color-base-text">
<text class="operator">-</text> <text class="operator">-</text>
<text class="unit price-font">{{ $lang('common.currencySymbol') }}</text> <text class="unit price-font">{{ $lang('common.currencySymbol') }}</text>
@@ -374,7 +374,7 @@
</view> </view>
</view> </view>
<view class="order-cell" v-if="calculateData.coupon_money"> <view class="order-cell" v-if="calculateData.coupon_money">
<text class="tit">{{ $lang('order.coupon') }}</text> <text class="tit">优惠券</text>
<view class="box color-base-text"> <view class="box color-base-text">
<text class="operator">-</text> <text class="operator">-</text>
<text class="unit price-font">{{ $lang('common.currencySymbol') }}</text> <text class="unit price-font">{{ $lang('common.currencySymbol') }}</text>
@@ -382,7 +382,7 @@
</view> </view>
</view> </view>
<view class="order-cell" v-if="calculateData.point_money > 0"> <view class="order-cell" v-if="calculateData.point_money > 0">
<text class="tit">{{ $lang('order.pointDeduct') }}</text> <text class="tit">积分抵扣</text>
<view class="box color-base-text"> <view class="box color-base-text">
<text class="operator">-</text> <text class="operator">-</text>
<text class="unit price-font">{{ $lang('common.currencySymbol') }}</text> <text class="unit price-font">{{ $lang('common.currencySymbol') }}</text>
@@ -400,18 +400,18 @@
</view> --> </view> -->
</view> </view>
<view v-if="transactionAgreement.title && transactionAgreement.content" class="agreement">{{ $lang('order.readAgreement') }}<text @click="$refs.agreementPopup.open()">《{{ transactionAgreement.title }}》</text>{{ $lang('order.agreeOnOrder') }}</view> <view v-if="transactionAgreement.title && transactionAgreement.content" class="agreement">购买前请先阅读<text @click="$refs.agreementPopup.open()">《{{ transactionAgreement.title }}》</text>,下单即代表同意该协议</view>
<view class="order-submit bottom-safe-area"> <view class="order-submit bottom-safe-area">
<view class="order-settlement-info"> <view class="order-settlement-info">
<text class="font-size-base color-tip margin-right">{{ $lang('order.totalItems', { count: calculateData.goods_num }) }}</text> <text class="font-size-base color-tip margin-right">共{{ calculateData.goods_num }}件</text>
<text class="font-size-base">{{ $lang('order.total') }}</text> <text class="font-size-base">合计:</text>
<text class=" unit price-font">{{ $lang('common.currencySymbol') }}</text> <text class=" unit price-font">{{ $lang('common.currencySymbol') }}</text>
<text class=" money price-font">{{ parseFloat(calculateData.pay_money).toFixed(2).split('.')[0] }}</text> <text class=" money price-font">{{ parseFloat(calculateData.pay_money).toFixed(2).split('.')[0] }}</text>
<text class=" unit price-font">.{{ parseFloat(calculateData.pay_money).toFixed(2).split('.')[1] }}</text> <text class=" unit price-font">.{{ parseFloat(calculateData.pay_money).toFixed(2).split('.')[1] }}</text>
</view> </view>
<view class="submit-btn"> <view class="submit-btn">
<button type="primary" class="mini" size="mini" @click="create()" v-if="!surplusStartMoney()">{{ $lang('order.submitOrder') }}</button> <button type="primary" class="mini" size="mini" @click="create()" v-if="!surplusStartMoney()">提交订单</button>
<!-- <button v-else class="no-submit mini" size="mini">差{{ surplusStartMoney() | moneyFormat }}起送</button> --> <!-- <button v-else class="no-submit mini" size="mini">差{{ surplusStartMoney() | moneyFormat }}起送</button> -->
</view> </view>
</view> </view>
@@ -425,7 +425,7 @@
<uni-popup ref="promotionPopup" type="bottom" v-if="promotionInfo"> <uni-popup ref="promotionPopup" type="bottom" v-if="promotionInfo">
<view class="promotion-popup popup"> <view class="promotion-popup popup">
<view class="popup-header"> <view class="popup-header">
<text class="tit">{{ $lang('order.promotionDiscount') }}</text> <text class="tit">活动优惠</text>
<text class="iconfont icon-close" @click="closePopup('promotionPopup')"></text> <text class="iconfont icon-close" @click="closePopup('promotionPopup')"></text>
</view> </view>
<scroll-view scroll-y="true" class="popup-body" :class="{ 'safe-area': isIphoneX }"> <scroll-view scroll-y="true" class="popup-body" :class="{ 'safe-area': isIphoneX }">
@@ -440,7 +440,7 @@
</view> </view>
</scroll-view> </scroll-view>
<view class="popup-footer" :class="{ 'bottom-safe-area': isIphoneX }"> <view class="popup-footer" :class="{ 'bottom-safe-area': isIphoneX }">
<view class="confirm-btn color-base-bg" @click="closePopup('promotionPopup')">{{ $lang('common.confirm') }}</view> <view class="confirm-btn color-base-bg" @click="closePopup('promotionPopup')">确定</view>
</view> </view>
</view> </view>
</uni-popup> </uni-popup>
@@ -449,7 +449,7 @@
<uni-popup ref="deliveryPopup" type="bottom"> <uni-popup ref="deliveryPopup" type="bottom">
<view class="delivery-popup popup"> <view class="delivery-popup popup">
<view class="popup-header"> <view class="popup-header">
<text class="tit">{{ $lang('order.nearbyStores') }}</text> <text class="tit">已为您甄选出附近所有相关门店</text>
<text class="iconfont icon-close" @click="closePopup('deliveryPopup')"></text> <text class="iconfont icon-close" @click="closePopup('deliveryPopup')"></text>
</view> </view>
<view class="popup-body store-popup" :class="{ 'safe-area': isIphoneX }"> <view class="popup-body store-popup" :class="{ 'safe-area': isIphoneX }">
@@ -465,8 +465,8 @@
<text v-if="item.distance">({{ item.distance }}km)</text> <text v-if="item.distance">({{ item.distance }}km)</text>
</view> </view>
<view class="info"> <view class="info">
<view :class="item.store_id == orderCreateData.delivery.store_id ? 'color-base-text' : ''" class="font-size-goods-tag">{{ $lang('order.businessHours') }}:{{ item.open_date }}</view> <view :class="item.store_id == orderCreateData.delivery.store_id ? 'color-base-text' : ''" class="font-size-goods-tag">营业时间:{{ item.open_date }}</view>
<view :class="item.store_id == orderCreateData.delivery.store_id ? 'color-base-text' : ''" class="font-size-goods-tag">{{ $lang('order.address') }}:{{ item.full_address }}{{ item.address }}</view> <view :class="item.store_id == orderCreateData.delivery.store_id ? 'color-base-text' : ''" class="font-size-goods-tag">地址:{{ item.full_address }}{{ item.address }}</view>
</view> </view>
</view> </view>
<view class="icon" v-if="item.store_id == orderCreateData.delivery.store_id"> <view class="icon" v-if="item.store_id == orderCreateData.delivery.store_id">
@@ -475,7 +475,7 @@
</view> </view>
</block> </block>
<view v-else class="empty-wrap"> <view v-else class="empty-wrap">
<ns-empty :text="$lang('order.noNearbyStore')" :isIndex="false"></ns-empty> <ns-empty text="所选择收货地址附近没有可以自提的门店" :isIndex="false"></ns-empty>
</view> </view>
</view> </view>
@@ -490,20 +490,20 @@
<uni-popup ref="buyerMessagePopup" type="bottom"> <uni-popup ref="buyerMessagePopup" type="bottom">
<view style="height: auto;" class="buyermessag-popup popup" @touchmove.prevent.stop> <view style="height: auto;" class="buyermessag-popup popup" @touchmove.prevent.stop>
<view class="popup-header"> <view class="popup-header">
<text class="tit">{{ $lang('order.buyerMessage') }}</text> <text class="tit">买家留言</text>
<text class="iconfont icon-close" @click="closePopup('buyerMessagePopup')"></text> <text class="iconfont icon-close" @click="closePopup('buyerMessagePopup')"></text>
</view> </view>
<scroll-view scroll-y="true" class="popup-body" :class="{ 'safe-area': isIphoneX }"> <scroll-view scroll-y="true" class="popup-body" :class="{ 'safe-area': isIphoneX }">
<view> <view>
<view class="buyermessag-cell"> <view class="buyermessag-cell">
<view class="buyermessag-form-group"> <view class="buyermessag-form-group">
<textarea type="text" maxlength="100" :placeholder="$lang('order.messagePlaceholder')" placeholder-class="color-tip" v-model="orderCreateData.buyer_message"/> <textarea type="text" maxlength="100" placeholder="留言前建议先与商家协调一致" placeholder-class="color-tip" v-model="orderCreateData.buyer_message"/>
</view> </view>
</view> </view>
</view> </view>
</scroll-view> </scroll-view>
<view class="popup-footer" @click="saveBuyerMessage" :class="{ 'bottom-safe-area': isIphoneX }"> <view class="popup-footer" @click="saveBuyerMessage" :class="{ 'bottom-safe-area': isIphoneX }">
<view class="confirm-btn color-base-bg">{{ $lang('common.confirm') }}</view> <view class="confirm-btn color-base-bg">确定</view>
</view> </view>
</view> </view>
</uni-popup> </uni-popup>
@@ -512,7 +512,7 @@
<uni-popup ref="couponPopup" type="bottom" :mask-click="false"> <uni-popup ref="couponPopup" type="bottom" :mask-click="false">
<view class="coupon-popup popup" @touchmove.prevent.stop> <view class="coupon-popup popup" @touchmove.prevent.stop>
<view class="popup-header"> <view class="popup-header">
<text class="tit">{{ $lang('order.coupon') }}</text> <text class="tit">优惠券</text>
<text class="iconfont icon-close" @click="closePopup('couponPopup')"></text> <text class="iconfont icon-close" @click="closePopup('couponPopup')"></text>
</view> </view>
@@ -533,32 +533,32 @@
</template> </template>
<template v-else-if="couponItem.type == 'discount'"> <template v-else-if="couponItem.type == 'discount'">
<text class="money">{{ parseFloat(couponItem.discount) }}</text> <text class="money">{{ parseFloat(couponItem.discount) }}</text>
<text class="unit">{{ $lang('common.discount') }}</text> <text class="unit">折</text>
</template> </template>
<view class="at-least"> <view class="at-least">
<template v-if="couponItem.at_least > 0"> <template v-if="couponItem.at_least > 0">
{{ $lang('coupon.spendXAvailable', { amount: couponItem.at_least }) }} 满{{ couponItem.at_least }}可用
</template> </template>
<template v-else> <template v-else>
{{ $lang('coupon.noThreshold') }} 无门槛
</template> </template>
</view> </view>
</view> </view>
</view> </view>
<view class="desc-wrap"> <view class="desc-wrap">
<view class="coupon-name">{{ couponItem.coupon_name }}</view> <view class="coupon-name">{{ couponItem.coupon_name }}</view>
<view v-if="couponItem.type == 'discount' && couponItem.discount_limit > 0" class="limit">{{ $lang('coupon.maxDeduct', { amount: couponItem.discount_limit }) }}</view> <view v-if="couponItem.type == 'discount' && couponItem.discount_limit > 0" class="limit">最多可抵¥{{ couponItem.discount_limit }}</view>
<view class="time font-size-goods-tag">{{ $lang('goods.validity') }}:{{ couponItem.end_time ? $util.timeStampTurnTime(couponItem.end_time) : $lang('coupon.permanentValid') }}</view> <view class="time font-size-goods-tag">有效期:{{ couponItem.end_time ? $util.timeStampTurnTime(couponItem.end_time) : '长期有效' }}</view>
</view> </view>
<view class="iconfont" :class="selectCouponId == couponItem.coupon_id ? 'icon-yuan_checked color-base-text' : 'icon-yuan_checkbox'"></view> <view class="iconfont" :class="selectCouponId == couponItem.coupon_id ? 'icon-yuan_checked color-base-text' : 'icon-yuan_checkbox'"></view>
</view> </view>
</view> </view>
</view> </view>
<view v-else class="coupon-empty">{{ $lang('coupon.noAvailable') }}</view> <view v-else class="coupon-empty">暂无可用的优惠券</view>
</scroll-view> </scroll-view>
<view class="popup-footer" :class="{ 'bottom-safe-area': isIphoneX }"> <view class="popup-footer" :class="{ 'bottom-safe-area': isIphoneX }">
<view class="confirm-btn color-base-bg" @click="useCpopon">{{ $lang('common.confirm') }}</view> <view class="confirm-btn color-base-bg" @click="useCpopon">确定</view>
</view> </view>
</view> </view>
</uni-popup> </uni-popup>
@@ -584,14 +584,14 @@
<uni-popup ref="editFormPopup" type="bottom"> <uni-popup ref="editFormPopup" type="bottom">
<view style="height: auto;" class="form-popup popup" @touchmove.prevent.stop> <view style="height: auto;" class="form-popup popup" @touchmove.prevent.stop>
<view class="popup-header"> <view class="popup-header">
<text class="tit">{{ $lang('order.buyerInfo') }}</text> <text class="tit">买家信息</text>
<text class="iconfont icon-close" @click="$refs.editFormPopup.close()"></text> <text class="iconfont icon-close" @click="$refs.editFormPopup.close()"></text>
</view> </view>
<scroll-view scroll-y="true" class="popup-body" :class="{ 'safe-area': isIphoneX }"> <scroll-view scroll-y="true" class="popup-body" :class="{ 'safe-area': isIphoneX }">
<ns-form v-if="tempFormData" :data="tempFormData.json_data" ref="tempForm"></ns-form> <ns-form v-if="tempFormData" :data="tempFormData.json_data" ref="tempForm"></ns-form>
</scroll-view> </scroll-view>
<view class="popup-footer" @click="saveForm" :class="{ 'bottom-safe-area': isIphoneX }"> <view class="popup-footer" @click="saveForm" :class="{ 'bottom-safe-area': isIphoneX }">
<view class="confirm-btn color-base-bg">{{ $lang('common.confirm') }}</view> <view class="confirm-btn color-base-bg">确定</view>
</view> </view>
</view> </view>
</uni-popup> </uni-popup>
@@ -599,7 +599,7 @@
<uni-popup ref="memberGoodsCardPopup" type="bottom"> <uni-popup ref="memberGoodsCardPopup" type="bottom">
<view class="member-card-popup popup" @touchmove.prevent.stop> <view class="member-card-popup popup" @touchmove.prevent.stop>
<view class="popup-header"> <view class="popup-header">
<text class="tit">{{ $lang('order.selectCard') }}</text> <text class="tit">选择次卡</text>
<text class="iconfont icon-close" @click="$refs.memberGoodsCardPopup.close()"></text> <text class="iconfont icon-close" @click="$refs.memberGoodsCardPopup.close()"></text>
</view> </view>
<scroll-view scroll-y="true" class="popup-body" :class="{ 'safe-area': isIphoneX }"> <scroll-view scroll-y="true" class="popup-body" :class="{ 'safe-area': isIphoneX }">
@@ -607,18 +607,18 @@
<view class="content"> <view class="content">
<view class="title">{{ isEnEnv ? item.en_goods_name : item.goods_name }}</view> <view class="title">{{ isEnEnv ? item.en_goods_name : item.goods_name }}</view>
<view class="info"> <view class="info">
<text v-if="item.card_type == 'timecard'">{{ $lang('card.unlimitedTimes') }}</text> <text v-if="item.card_type == 'timecard'">不限次数</text>
<text v-if="item.card_type == 'oncecard'">{{ $lang('card.remainingTimes', { remaining: item.num - item.use_num }) }}</text> <text v-if="item.card_type == 'oncecard'">剩余{{ item.num - item.use_num }}次</text>
<text v-if="item.card_type == 'commoncard'">{{ $lang('card.remainingTimes', { remaining: item.total_num - item.total_use_num }) }}</text> <text v-if="item.card_type == 'commoncard'">剩余{{ item.total_num - item.total_use_num }}次</text>
<text>|</text> <text>|</text>
<text>{{ item.end_time ? $util.timeStampTurnTime(item.end_time) : $lang('coupon.permanentValid') }}</text> <text>{{ item.end_time ? $util.timeStampTurnTime(item.end_time) : '长期有效' }}</text>
</view> </view>
</view> </view>
<view class="iconfont" :class="selectGoodsCard.itemId == item.item_id ? 'icon-yuan_checked color-base-text' : 'icon-yuan_checkbox'"></view> <view class="iconfont" :class="selectGoodsCard.itemId == item.item_id ? 'icon-yuan_checked color-base-text' : 'icon-yuan_checkbox'"></view>
</view> </view>
</scroll-view> </scroll-view>
<view class="popup-footer" @click="saveMemberGoodsCard" :class="{ 'bottom-safe-area': isIphoneX }"> <view class="popup-footer" @click="saveMemberGoodsCard" :class="{ 'bottom-safe-area': isIphoneX }">
<view class="confirm-btn color-base-bg">{{ $lang('common.confirm') }}</view> <view class="confirm-btn color-base-bg">确定</view>
</view> </view>
</view> </view>
</uni-popup> </uni-popup>

View File

@@ -131,32 +131,32 @@ export default {
charge_rule_arr.push({ charge_rule_arr.push({
'key': key, 'key': key,
'value': charge_rule[key], 'value': charge_rule[key],
'title': this.$lang('payment.weekCard'), 'title': '周卡',
unit: this.$lang('payment.week') unit: '周'
}); });
break; break;
case 'month': case 'month':
charge_rule_arr.push({ charge_rule_arr.push({
'key': key, 'key': key,
'value': charge_rule[key], 'value': charge_rule[key],
'title': this.$lang('payment.monthCard'), 'title': '月卡',
unit: this.$lang('payment.month') unit: '月'
}); });
break; break;
case 'quarter': case 'quarter':
charge_rule_arr.push({ charge_rule_arr.push({
'key': key, 'key': key,
'value': charge_rule[key], 'value': charge_rule[key],
'title': this.$lang('payment.quarterCard'), 'title': '季卡',
unit: this.$lang('payment.quarter') unit: '季'
}); });
break; break;
case 'year': case 'year':
charge_rule_arr.push({ charge_rule_arr.push({
'key': key, 'key': key,
'value': charge_rule[key], 'value': charge_rule[key],
'title': this.$lang('payment.yearCard'), 'title': '年卡',
unit: this.$lang('payment.year') unit: '年'
}); });
break; break;
} }
@@ -484,20 +484,20 @@ export default {
if (this.paymentData.is_virtual == 1) { if (this.paymentData.is_virtual == 1) {
if (!this.orderCreateData.member_address.mobile) { if (!this.orderCreateData.member_address.mobile) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.inputMobile') title: '请输入预留手机'
}); });
return false; return false;
} }
if (!this.$util.verifyMobile(this.orderCreateData.member_address.mobile)) { if (!this.$util.verifyMobile(this.orderCreateData.member_address.mobile)) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.inputCorrectMobile') title: '请输入正确的手机号'
}); });
return false; return false;
} }
} else { } else {
if (!this.orderCreateData.delivery || !this.orderCreateData.delivery.delivery_type) { if (!this.orderCreateData.delivery || !this.orderCreateData.delivery.delivery_type) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.noDeliveryMethod') title: '商家未设置配送方式'
}); });
return false; return false;
} }
@@ -506,7 +506,7 @@ export default {
(this.orderCreateData.delivery.delivery_type == 'local' && !this.localMemberAddress) (this.orderCreateData.delivery.delivery_type == 'local' && !this.localMemberAddress)
) { ) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.selectAddressFirst') title: '请先选择您的收货地址'
}); });
return false; return false;
} }
@@ -514,25 +514,25 @@ export default {
if (this.orderCreateData.delivery.delivery_type == 'store') { if (this.orderCreateData.delivery.delivery_type == 'store') {
if (!this.orderCreateData.delivery.store_id) { if (!this.orderCreateData.delivery.store_id) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.noPickupStore') title: '没有可提货的门店,请选择其他配送方式'
}); });
return false; return false;
} }
if (!this.orderCreateData.member_address.mobile) { if (!this.orderCreateData.member_address.mobile) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.inputMobile') title: '请输入预留手机'
}); });
return false; return false;
} }
if (!this.$util.verifyMobile(this.orderCreateData.member_address.mobile)) { if (!this.$util.verifyMobile(this.orderCreateData.member_address.mobile)) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.inputCorrectMobile') title: '请输入正确的手机号'
}); });
return false; return false;
} }
if (!this.deliveryTime) { if (!this.deliveryTime) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.selectPickupTime') title: '请选择提货时间'
}); });
return false; return false;
} }
@@ -541,13 +541,13 @@ export default {
if (this.orderCreateData.delivery.delivery_type == 'local') { if (this.orderCreateData.delivery.delivery_type == 'local') {
if (!this.orderCreateData.delivery.store_id) { if (!this.orderCreateData.delivery.store_id) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.noDeliveryStore') title: '没有可配送的门店,请选择其他配送方式'
}); });
return false; return false;
} }
if (this.calculateGoodsData.config.local.is_use && this.calculateGoodsData.delivery.local.info.time_is_open == 1 && !this.deliveryTime) { if (this.calculateGoodsData.config.local.is_use && this.calculateGoodsData.delivery.local.info.time_is_open == 1 && !this.deliveryTime) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.selectDeliveryTime') title: '请选择送达时间'
}); });
return false; return false;
} }
@@ -837,25 +837,25 @@ export default {
invoiceVerify() { invoiceVerify() {
if (!this.orderCreateData.invoice_title) { if (!this.orderCreateData.invoice_title) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.inputInvoiceTitle') title: '请填写发票抬头'
}); });
return false; return false;
} }
if (!this.orderCreateData.taxpayer_number && this.orderCreateData.invoice_title_type == 2) { if (!this.orderCreateData.taxpayer_number && this.orderCreateData.invoice_title_type == 2) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.inputTaxpayerNumber') title: '请填写纳税人识别号'
}); });
return false; return false;
} }
if (this.orderCreateData.invoice_type == 1 && !this.orderCreateData.invoice_full_address && this.paymentData.is_virtual == 1) { if (this.orderCreateData.invoice_type == 1 && !this.orderCreateData.invoice_full_address && this.paymentData.is_virtual == 1) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.inputInvoiceAddress') title: '请填写发票邮寄地址'
}); });
return false; return false;
} }
if (this.orderCreateData.invoice_type == 2 && !this.orderCreateData.invoice_email) { if (this.orderCreateData.invoice_type == 2 && !this.orderCreateData.invoice_email) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.inputEmail') title: '请填写邮箱'
}); });
return false; return false;
} }
@@ -863,14 +863,14 @@ export default {
var reg = /^([a-zA-Z]|[0-9])(\w|\-)+@[a-zA-Z0-9]+\.([a-zA-Z]{2,4})$/; var reg = /^([a-zA-Z]|[0-9])(\w|\-)+@[a-zA-Z0-9]+\.([a-zA-Z]{2,4})$/;
if (!reg.test(this.orderCreateData.invoice_email)) { if (!reg.test(this.orderCreateData.invoice_email)) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.inputCorrectEmail') title: '请填写正确的邮箱'
}); });
return false; return false;
} }
} }
if (!this.orderCreateData.invoice_content) { if (!this.orderCreateData.invoice_content) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('payment.selectInvoiceContent') title: '请选择发票内容'
}); });
return false; return false;
} }

View File

@@ -11,13 +11,13 @@
<text v-if="orderData.promotion_status_name">({{ orderData.promotion_status_name }})</text> <text v-if="orderData.promotion_status_name">({{ orderData.promotion_status_name }})</text>
</view> </view>
<view class="desc" v-if="orderData.promotion_type == 'presale' && orderData.order_status == 1"> <view class="desc" v-if="orderData.promotion_type == 'presale' && orderData.order_status == 1">
{{ $lang('order.estimatedShip') }}{{ $util.timeStampTurnTime(orderData.predict_delivery_time, true) }}{{ $lang('order.daysLater') }} 预计{{ $util.timeStampTurnTime(orderData.predict_delivery_time, true) }}日后发货
</view> </view>
<view class="desc" v-if="orderData.close_cause">{{ $lang('order.closeReason') }}{{ orderData.close_cause }}</view> <view class="desc" v-if="orderData.close_cause">订单关闭原因:{{ orderData.close_cause }}</view>
</view> </view>
</view> </view>
<view class="order-time" v-if="orderData.order_status == 0" id="action-date"> <view class="order-time" v-if="orderData.order_status == 0" id="action-date">
{{ $lang('order.remainingTime') }} 剩余时间:
<uni-count-down :day="orderData.closeTimeMachine.d" :hour="orderData.closeTimeMachine.h" <uni-count-down :day="orderData.closeTimeMachine.d" :hour="orderData.closeTimeMachine.h"
:minute="orderData.closeTimeMachine.i" :second="orderData.closeTimeMachine.s" color="#fff" :minute="orderData.closeTimeMachine.i" :second="orderData.closeTimeMachine.s" color="#fff"
splitorColor="#fff" /> splitorColor="#fff" />
@@ -34,21 +34,21 @@
<text class="font-size-base">{{ orderData.name }}&nbsp;{{ orderData.mobile }}</text> <text class="font-size-base">{{ orderData.name }}&nbsp;{{ orderData.mobile }}</text>
</view> </view>
<view class="detail"> <view class="detail">
<text class="font-size-base">{{ $lang('order.receiptAddress') }}:{{ orderData.full_address }} {{ orderData.address }}</text> <text class="font-size-base">收货地址:{{ orderData.full_address }} {{ orderData.address }}</text>
</view> </view>
</view> </view>
<template v-if="orderData.order_type == 3"> <template v-if="orderData.order_type == 3">
<view class="pick-block first-pick-block"> <view class="pick-block first-pick-block">
<view class="font-size-base">{{ $lang('order.deliverTime') }}:</view> <view class="font-size-base">送达时间:</view>
<view class="last-child">{{ orderData.buyer_ask_delivery_time }}</view> <view class="last-child">{{ orderData.buyer_ask_delivery_time }}</view>
</view> </view>
<block v-if="orderData.package_list"> <block v-if="orderData.package_list">
<view class="pick-block"> <view class="pick-block">
<view>{{ $lang('order.deliverer') }}:</view> <view>配送员:</view>
<view class="last-child">{{ orderData.package_list.deliverer }}</view> <view class="last-child">{{ orderData.package_list.deliverer }}</view>
</view> </view>
<view class="pick-block"> <view class="pick-block">
<view>{{ $lang('order.delivererPhone') }}:</view> <view>外卖电话:</view>
<view class="last-child">{{ orderData.package_list.deliverer_mobile }}</view> <view class="last-child">{{ orderData.package_list.deliverer_mobile }}</view>
</view> </view>
</block> </block>
@@ -74,27 +74,27 @@
</view> </view>
<view class="detail store-detail"> <view class="detail store-detail">
<view class="color-tip" v-if="orderData.delivery_store_info.open_date"> <view class="color-tip" v-if="orderData.delivery_store_info.open_date">
{{ $lang('order.businessHours') }}:{{ orderData.delivery_store_info.open_date }}</view> 营业时间:{{ orderData.delivery_store_info.open_date }}</view>
<view class="color-tip">{{ $lang('order.address') }}:{{ orderData.delivery_store_info.full_address }}</view> <view class="color-tip">地址:{{ orderData.delivery_store_info.full_address }}</view>
</view> </view>
</view> </view>
</view> </view>
<view v-else> <view v-else>
<view class="address-empty"> <view class="address-empty">
<view class="color-base-text">{{ $lang('order.noPickupStore') }}</view> <view class="color-base-text">当前无自提门店</view>
</view> </view>
</view> </view>
</view> </view>
<view class="pick-block first-pick-block"> <view class="pick-block first-pick-block">
<view class="font-size-base">{{ $lang('order.name') }}</view> <view class="font-size-base">姓名</view>
<input class="last-child" type="text" disabled :value="orderData.name" /> <input class="last-child" type="text" disabled :value="orderData.name" />
</view> </view>
<view class="pick-block first-pick-block"> <view class="pick-block first-pick-block">
<view class="font-size-base">{{ $lang('order.phone') }}</view> <view class="font-size-base">预留手机</view>
<input class="last-child" type="number" disabled :value="orderData.mobile" /> <input class="last-child" type="number" disabled :value="orderData.mobile" />
</view> </view>
<view class="pick-block first-pick-block"> <view class="pick-block first-pick-block">
<view class="font-size-base">{{ $lang('order.pickupTime') }}</view> <view class="font-size-base">提货时间</view>
<input class="last-child" disabled :value="orderData.buyer_ask_delivery_time" /> <input class="last-child" disabled :value="orderData.buyer_ask_delivery_time" />
</view> </view>
</view> </view>
@@ -103,10 +103,10 @@
<view class="pickup-code-info"> <view class="pickup-code-info">
<view class="info"> <view class="info">
<text class="font-size-base"> <text class="font-size-base">
<text class="color-tip font-size-base">{{ $lang('order.pickupCode') }}:</text> <text class="color-tip font-size-base">提货码:</text>
{{ orderData.delivery_code }} {{ orderData.delivery_code }}
</text> </text>
<text class="copy" @click="$util.copy(orderData.delivery_code)">{{ $lang('order.copy') }}</text> <text class="copy" @click="$util.copy(orderData.delivery_code)">复制</text>
</view> </view>
<view class="code"> <view class="code">
<image :src="$util.img(orderData.pickup_barcode)" <image :src="$util.img(orderData.pickup_barcode)"
@@ -179,7 +179,7 @@
</view> </view>
<view class="box" v-else> <view class="box" v-else>
<text class="color-title">{{ item.val }}</text> <text class="color-title">{{ item.val }}</text>
<text class="copy" @click="$util.copy(item.val)">{{ $lang('order.copy') }}</text> <text class="copy" @click="$util.copy(item.val)">复制</text>
</view> </view>
</view> </view>
</view> </view>
@@ -189,13 +189,13 @@
<view @click="goRefund(goodsItem.order_goods_id)" <view @click="goRefund(goodsItem.order_goods_id)"
v-if="orderData.order_scene == 'online' && (goodsItem.refund_status == 0 || goodsItem.refund_status == -1)"> v-if="orderData.order_scene == 'online' && (goodsItem.refund_status == 0 || goodsItem.refund_status == -1)">
<view class="order-box-btn" v-if="orderData.promotion_type != 'blindbox'"> <view class="order-box-btn" v-if="orderData.promotion_type != 'blindbox'">
{{ orderData.order_status == 10 ? $lang('order.applyAfterSale') : $lang('order.applyRefund') }} {{ orderData.order_status == 10 ? '申请售后' : '申请退款' }}
</view> </view>
</view> </view>
</block> </block>
<view @click="goRefundDetail(goodsItem.order_goods_id)" <view @click="goRefundDetail(goodsItem.order_goods_id)"
v-if="goodsItem.refund_status != 0 && goodsItem.refund_status != -1"> v-if="goodsItem.refund_status != 0 && goodsItem.refund_status != -1">
<view class="order-box-btn">{{ orderData.order_status == 10 ? $lang('order.viewAfterSale') : $lang('order.viewRefund') }}</view> <view class="order-box-btn">{{ orderData.order_status == 10 ? '查看售后' : '查看退款' }}</view>
</view> </view>
</view> </view>
</view> </view>
@@ -205,32 +205,32 @@
<!-- 订单概况 --> <!-- 订单概况 -->
<view class="order-summary"> <view class="order-summary">
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.orderType') }}:</text> <text class="tit">订单类型:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ orderData.order_type_name }}</text> <text class="color-title">{{ orderData.order_type_name }}</text>
</view> </view>
</view> </view>
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.orderNo') }}:</text> <text class="tit">订单编号:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ orderData.order_no }}</text> <text class="color-title">{{ orderData.order_no }}</text>
<view class="copy" @click="$util.copy(orderData.order_no)">{{ $lang('common.copy') }}</view> <view class="copy" @click="$util.copy(orderData.order_no)">复制</view>
</view> </view>
</view> </view>
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.tradeNo') }}:</text> <text class="tit">订单交易号:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ orderData.out_trade_no }}</text> <text class="color-title">{{ orderData.out_trade_no }}</text>
</view> </view>
</view> </view>
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.createTime') }}:</text> <text class="tit">创建时间:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ $util.timeStampTurnTime(orderData.create_time) }}</text> <text class="color-title">{{ $util.timeStampTurnTime(orderData.create_time) }}</text>
</view> </view>
</view> </view>
<view class="order-cell" v-if="orderData.close_time > 0"> <view class="order-cell" v-if="orderData.close_time > 0">
<text class="tit">{{ $lang('order.closeTime') }}:</text> <text class="tit">关闭时间:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ $util.timeStampTurnTime(orderData.close_time) }}</text> <text class="color-title">{{ $util.timeStampTurnTime(orderData.close_time) }}</text>
</view> </view>
@@ -238,32 +238,32 @@
<block v-if="orderData.pay_status > 0"> <block v-if="orderData.pay_status > 0">
<view class="hr"></view> <view class="hr"></view>
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.paymentMethod') }}:</text> <text class="tit">支付方式:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ orderData.pay_type_name }}</text> <text class="color-title">{{ orderData.pay_type_name }}</text>
</view> </view>
</view> </view>
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.paymentTime') }}:</text> <text class="tit">支付时间:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ $util.timeStampTurnTime(orderData.pay_time) }}</text> <text class="color-title">{{ $util.timeStampTurnTime(orderData.pay_time) }}</text>
</view> </view>
</view> </view>
</block> </block>
<view class="order-cell" v-if="orderData.delivery_type_name"> <view class="order-cell" v-if="orderData.delivery_type_name">
<text class="tit">{{ $lang('order.deliveryMethod') }}:</text> <text class="tit">配送方式:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ orderData.delivery_type_name }}</text> <text class="color-title">{{ orderData.delivery_type_name }}</text>
</view> </view>
</view> </view>
<view class="order-cell" v-if="orderData.buyer_message != ''"> <view class="order-cell" v-if="orderData.buyer_message != ''">
<text class="tit">{{ $lang('order.buyerMessage') }}:</text> <text class="tit">买家留言:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ orderData.buyer_message }}</text> <text class="color-title">{{ orderData.buyer_message }}</text>
</view> </view>
</view> </view>
<view class="order-cell" v-if="orderData.promotion_type_name != ''"> <view class="order-cell" v-if="orderData.promotion_type_name != ''">
<text class="tit">{{ $lang('order.promotion') }}:</text> <text class="tit">活动优惠:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ orderData.promotion_type_name }}</text> <text class="color-title">{{ orderData.promotion_type_name }}</text>
</view> </view>
@@ -271,38 +271,38 @@
<block v-if="orderData.is_invoice > 0"> <block v-if="orderData.is_invoice > 0">
<view class="hr"></view> <view class="hr"></view>
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.invoiceType') }}:</text> <text class="tit">发票类型:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ orderData.invoice_type == 1 ? $lang('order.paperInvoice') : $lang('order.eInvoice') }}</text> <text class="color-title">{{ orderData.invoice_type == 1 ? '纸质发票' : '电子发票' }}</text>
</view> </view>
</view> </view>
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.invoiceTitleType') }}:</text> <text class="tit">发票抬头类型:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ orderData.invoice_title_type == 1 ? $lang('order.personal') : $lang('order.enterprise') }}</text> <text class="color-title">{{ orderData.invoice_title_type == 1 ? '个人' : '企业' }}</text>
</view> </view>
</view> </view>
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.invoiceTitle') }}:</text> <text class="tit">发票抬头:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ orderData.invoice_title }}</text> <text class="color-title">{{ orderData.invoice_title }}</text>
</view> </view>
</view> </view>
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.invoiceContent') }}:</text> <text class="tit">发票内容:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ orderData.invoice_content }}</text> <text class="color-title">{{ orderData.invoice_content }}</text>
</view> </view>
</view> </view>
<view class="order-cell" v-if="orderData.invoice_type == 1"> <view class="order-cell" v-if="orderData.invoice_type == 1">
<text class="tit">{{ $lang('order.invoiceAddress') }}:</text> <text class="tit">发票邮寄地址:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ orderData.invoice_full_address }}</text> <text class="color-title">{{ orderData.invoice_full_address }}</text>
</view> </view>
</view> </view>
<view class="order-cell" v-else> <view class="order-cell" v-else>
<text class="tit">{{ $lang('order.invoiceEmail') }}:</text> <text class="tit">发票接收邮件:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ orderData.invoice_email }}</text> <text class="color-title">{{ orderData.invoice_email }}</text>
</view> </view>
@@ -319,16 +319,16 @@
</view> </view>
<view class="box" v-else> <view class="box" v-else>
<text class="color-title">{{ item.val }}</text> <text class="color-title">{{ item.val }}</text>
<text class="copy" @click="$util.copy(item.val)">{{ $lang('order.copy') }}</text> <text class="copy" @click="$util.copy(item.val)">复制</text>
</view> </view>
</view> </view>
</block> </block>
<block v-if="orderData.goods_class == 5"> <block v-if="orderData.goods_class == 5">
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.myCardPack') }}</text> <text class="tit">我的卡包:</text>
<view class="box"><text class="color-base-text" <view class="box"><text class="color-base-text"
@click="$util.redirectTo('/pages_promotion/cardservice/card/my_card')">{{ $lang('order.view') }}</text></view> @click="$util.redirectTo('/pages_promotion/cardservice/card/my_card')">查看</text></view>
</view> </view>
</block> </block>
<!-- 联系客服 --> <!-- 联系客服 -->
@@ -347,74 +347,76 @@
<view class="code"> <view class="code">
<image :src="$util.img(orderData.virtualgoods_barcode)" class="barcode" mode="widthFix" show-menu-by-longpress></image> <image :src="$util.img(orderData.virtualgoods_barcode)" class="barcode" mode="widthFix" show-menu-by-longpress></image>
<image :src="$util.img(orderData.virtualgoods)" class="qrcode" mode="widthFix" show-menu-by-longpress></image> <image :src="$util.img(orderData.virtualgoods)" class="qrcode" mode="widthFix" show-menu-by-longpress></image>
<text>{{ $lang('order.showCodeToVerifier') }}</text> <text>请将条形码或二维码出示给核销员</text>
</view> </view>
<view class="hr"></view> <view class="hr"></view>
<view class="wrap"> <view class="wrap">
<text class="font-size-base virtual-code">{{ orderData.virtual_code }}</text> <text class="font-size-base virtual-code">{{ orderData.virtual_code }}</text>
<view class="copy" @click="$util.copy(orderData.virtual_code)">{{ $lang('common.copy') }}</view> <view class="copy" @click="$util.copy(orderData.virtual_code)">复制</view>
</view> </view>
</view> </view>
<view class="verify-info-wrap"> <view class="verify-info-wrap">
<view class="head">{{ $lang('order.verifyInfo') }}</view> <view class="head">核销信息</view>
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.verifyTimes') }}</text> <text class="tit">核销次数</text>
<view class="box align-right"> <view class="box align-right">
<text class="color-title"> <text class="color-title">
{{ $lang('order.verifyRemaining', { remaining: orderData.virtual_goods.verify_total_count - orderData.virtual_goods.verify_use_num, total: orderData.virtual_goods.verify_total_count }) }} 剩余{{ orderData.virtual_goods.verify_total_count - orderData.virtual_goods.verify_use_num
}}次/共{{
orderData.virtual_goods.verify_total_count }}次
</text> </text>
</view> </view>
</view> </view>
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.validPeriod') }}</text> <text class="tit">有效期</text>
<view class="box align-right"> <view class="box align-right">
<text class="color-title" v-if="orderData.virtual_goods.expire_time > 0">{{ <text class="color-title" v-if="orderData.virtual_goods.expire_time > 0">{{
$util.timeStampTurnTime(orderData.virtual_goods.expire_time) }}</text> $util.timeStampTurnTime(orderData.virtual_goods.expire_time) }}</text>
<text v-else>{{ $lang('order.permanentValid') }}</text> <text v-else>永久有效</text>
</view> </view>
</view> </view>
</view> </view>
<view class="verify-info-wrap"> <view class="verify-info-wrap">
<view class="head">{{ $lang('order.verifyRecord') }}</view> <view class="head">核销记录</view>
<view v-if="orderData.virtual_goods.verify_record.length"> <view v-if="orderData.virtual_goods.verify_record.length">
<view v-for="(item, index) in orderData.virtual_goods.verify_record" :key="index" <view v-for="(item, index) in orderData.virtual_goods.verify_record" :key="index"
class="record-item"> class="record-item">
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.verifier') }}</text> <text class="tit">核销人</text>
<view class="box align-right"> <view class="box align-right">
<text class="color-title">{{ item.verifier_name }}</text> <text class="color-title">{{ item.verifier_name }}</text>
</view> </view>
</view> </view>
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.verifyTime') }}</text> <text class="tit">核销时间</text>
<view class="box align-right"> <view class="box align-right">
<text class="color-title">{{ $util.timeStampTurnTime(item.verify_time) }}</text> <text class="color-title">{{ $util.timeStampTurnTime(item.verify_time) }}</text>
</view> </view>
</view> </view>
</view> </view>
</view> </view>
<view class="record-empty" v-else>{{ $lang('order.noVerifyRecord') }}</view> <view class="record-empty" v-else>暂无核销记录</view>
</view> </view>
</block> </block>
<block v-if="orderData.virtual_goods && orderData.goods_class == 3"> <block v-if="orderData.virtual_goods && orderData.goods_class == 3">
<view class="verify-info-wrap carmichael"> <view class="verify-info-wrap carmichael">
<view class="head">{{ $lang('order.cardInfo') }}</view> <view class="head">卡密信息</view>
<view v-for="(item, index) in orderData.virtual_goods" :key="index" class="record-item"> <view v-for="(item, index) in orderData.virtual_goods" :key="index" class="record-item">
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.cardNo') }}</text> <text class="tit">卡号:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ item.card_info.cardno }}</text> <text class="color-title">{{ item.card_info.cardno }}</text>
<view class="copy" @click="$util.copy(item.card_info.cardno)">{{ $lang('order.copy') }}</view> <view class="copy" @click="$util.copy(item.card_info.cardno)">复制</view>
</view> </view>
</view> </view>
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.password') }}</text> <text class="tit">密码:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ item.card_info.password }}</text> <text class="color-title">{{ item.card_info.password }}</text>
<view class="copy" @click="$util.copy(item.card_info.password)">{{ $lang('order.copy') }}</view> <view class="copy" @click="$util.copy(item.card_info.password)">复制</view>
</view> </view>
</view> </view>
</view> </view>
@@ -426,61 +428,63 @@
<view class="code"> <view class="code">
<image :src="$util.img(orderData.virtualgoods_barcode)" class="barcode" mode="widthFix" show-menu-by-longpress></image> <image :src="$util.img(orderData.virtualgoods_barcode)" class="barcode" mode="widthFix" show-menu-by-longpress></image>
<image :src="$util.img(orderData.virtualgoods)" class="qrcode" mode="widthFix" show-menu-by-longpress></image> <image :src="$util.img(orderData.virtualgoods)" class="qrcode" mode="widthFix" show-menu-by-longpress></image>
<text>{{ $lang('order.showCodeToVerifier') }}</text> <text>请将条形码或二维码出示给核销员</text>
</view> </view>
<view class="hr"></view> <view class="hr"></view>
<view class="wrap"> <view class="wrap">
<text class="font-size-base virtual-code">{{ orderData.virtual_code }}</text> <text class="font-size-base virtual-code">{{ orderData.virtual_code }}</text>
<view class="copy" @click="$util.copy(orderData.virtual_code)">{{ $lang('common.copy') }}</view> <view class="copy" @click="$util.copy(orderData.virtual_code)">复制</view>
</view> </view>
</view> </view>
<view class="verify-info-wrap"> <view class="verify-info-wrap">
<view class="head">{{ $lang('order.verifyInfo') }}</view> <view class="head">核销信息</view>
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.verifyTimes') }}</text> <text class="tit">核销次数</text>
<view class="box align-right"> <view class="box align-right">
<text class="color-title"> <text class="color-title">
{{ $lang('order.verifyRemaining', { remaining: orderData.virtual_goods.verify_total_count - orderData.virtual_goods.verify_use_num, total: orderData.virtual_goods.verify_total_count }) }} 剩余{{ orderData.virtual_goods.verify_total_count - orderData.virtual_goods.verify_use_num
}}次/共{{
orderData.virtual_goods.verify_total_count }}次
</text> </text>
</view> </view>
</view> </view>
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.validPeriod') }}</text> <text class="tit">有效期</text>
<view class="box align-right"> <view class="box align-right">
<text class="color-title" v-if="orderData.virtual_goods.expire_time > 0">{{ <text class="color-title" v-if="orderData.virtual_goods.expire_time > 0">{{
$util.timeStampTurnTime(orderData.virtual_goods.expire_time) }}</text> $util.timeStampTurnTime(orderData.virtual_goods.expire_time) }}</text>
<text v-else>{{ $lang('order.permanentValid') }}</text> <text v-else>永久有效</text>
</view> </view>
</view> </view>
</view> </view>
<view class="verify-info-wrap"> <view class="verify-info-wrap">
<view class="head">{{ $lang('order.verifyRecord') }}</view> <view class="head">核销记录</view>
<view v-if="orderData.virtual_goods.verify_record.length"> <view v-if="orderData.virtual_goods.verify_record.length">
<view v-for="(item, index) in orderData.virtual_goods.verify_record" :key="index" <view v-for="(item, index) in orderData.virtual_goods.verify_record" :key="index"
class="record-item"> class="record-item">
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.verifier') }}</text> <text class="tit">核销人</text>
<view class="box align-right"> <view class="box align-right">
<text class="color-title">{{ item.verifier_name }}</text> <text class="color-title">{{ item.verifier_name }}</text>
</view> </view>
</view> </view>
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.verifyTime') }}</text> <text class="tit">核销时间</text>
<view class="box align-right"> <view class="box align-right">
<text class="color-title">{{ $util.timeStampTurnTime(item.verify_time) }}</text> <text class="color-title">{{ $util.timeStampTurnTime(item.verify_time) }}</text>
</view> </view>
</view> </view>
</view> </view>
</view> </view>
<view class="record-empty" v-else>{{ $lang('order.noVerifyRecord') }}</view> <view class="record-empty" v-else>暂无核销记录</view>
</view> </view>
</block> </block>
<!-- 订单金额 --> <!-- 订单金额 -->
<view class="order-money"> <view class="order-money">
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.goodsAmount') }}</text> <text class="tit">商品金额</text>
<view class="box align-right"> <view class="box align-right">
<text class="color-title price-font"> <text class="color-title price-font">
<text class="font-size-goods-tag">{{ $lang('common.currencySymbol') }}</text> <text class="font-size-goods-tag">{{ $lang('common.currencySymbol') }}</text>
@@ -489,7 +493,7 @@
</view> </view>
</view> </view>
<view class="order-cell" v-if="orderData.order_type != 4"> <view class="order-cell" v-if="orderData.order_type != 4">
<text class="tit">{{ $lang('order.shippingFee') }}</text> <text class="tit">运费</text>
<view class="box align-right"> <view class="box align-right">
<text class="color-base-text price-font"> <text class="color-base-text price-font">
<text class="font-size-goods-tag">{{ $lang('common.currencySymbol') }}</text> <text class="font-size-goods-tag">{{ $lang('common.currencySymbol') }}</text>
@@ -498,7 +502,7 @@
</view> </view>
</view> </view>
<view class="order-cell" v-if="orderData.member_card_money > 0"> <view class="order-cell" v-if="orderData.member_card_money > 0">
<text class="tit">{{ $lang('order.memberCard') }}</text> <text class="tit">会员卡</text>
<view class="box align-right"> <view class="box align-right">
<text class="color-base-text price-font"> <text class="color-base-text price-font">
<text class="font-size-goods-tag">{{ $lang('common.currencySymbol') }}</text> <text class="font-size-goods-tag">{{ $lang('common.currencySymbol') }}</text>
@@ -508,7 +512,7 @@
</view> </view>
<view class="order-cell" v-if="orderData.invoice_money > 0"> <view class="order-cell" v-if="orderData.invoice_money > 0">
<text class="tit"> <text class="tit">
{{ $lang('order.taxFee') }} 税费
<text class="color-base-text">({{ orderData.invoice_rate }}%)</text> <text class="color-base-text">({{ orderData.invoice_rate }}%)</text>
</text> </text>
<view class="box align-right"> <view class="box align-right">
@@ -520,7 +524,7 @@
</view> </view>
</view> </view>
<view class="order-cell" v-if="orderData.invoice_delivery_money > 0"> <view class="order-cell" v-if="orderData.invoice_delivery_money > 0">
<text class="tit">{{ $lang('order.invoiceDeliveryFee') }}</text> <text class="tit">发票邮寄费</text>
<view class="box align-right"> <view class="box align-right">
<text class="color-base-text price-font"> <text class="color-base-text price-font">
<text class="operator">+</text> <text class="operator">+</text>
@@ -530,7 +534,7 @@
</view> </view>
</view> </view>
<view class="order-cell" v-if="orderData.adjust_money != 0"> <view class="order-cell" v-if="orderData.adjust_money != 0">
<text class="tit">{{ $lang('order.orderAdjust') }}</text> <text class="tit">订单调整</text>
<view class="box align-right"> <view class="box align-right">
<text class="color-base-text price-font"> <text class="color-base-text price-font">
<text class="operator" v-if="orderData.adjust_money < 0">-</text> <text class="operator" v-if="orderData.adjust_money < 0">-</text>
@@ -541,7 +545,7 @@
</view> </view>
</view> </view>
<view class="order-cell" v-if="orderData.promotion_money > 0"> <view class="order-cell" v-if="orderData.promotion_money > 0">
<text class="tit">{{ $lang('order.discount') }}</text> <text class="tit">优惠</text>
<view class="box align-right"> <view class="box align-right">
<text class="color-base-text price-font"> <text class="color-base-text price-font">
<text class="operator">-</text> <text class="operator">-</text>
@@ -551,7 +555,7 @@
</view> </view>
</view> </view>
<view class="order-cell" v-if="orderData.coupon_money > 0"> <view class="order-cell" v-if="orderData.coupon_money > 0">
<text class="tit">{{ $lang('order.coupon') }}</text> <text class="tit">优惠券</text>
<view class="box align-right"> <view class="box align-right">
<text class="color-base-text price-font"> <text class="color-base-text price-font">
<text class="operator">-</text> <text class="operator">-</text>
@@ -561,7 +565,7 @@
</view> </view>
</view> </view>
<view class="order-cell" v-if="orderData.balance_money > 0"> <view class="order-cell" v-if="orderData.balance_money > 0">
<text class="tit">{{ $lang('order.useBalance') }}</text> <text class="tit">使用余额</text>
<view class="box align-right"> <view class="box align-right">
<text class="color-base-text price-font"> <text class="color-base-text price-font">
<text class="operator">-</text> <text class="operator">-</text>
@@ -571,7 +575,7 @@
</view> </view>
</view> </view>
<view class="order-cell" v-if="orderData.point_money > 0"> <view class="order-cell" v-if="orderData.point_money > 0">
<text class="tit">{{ $lang('order.pointDeduct') }}</text> <text class="tit">积分抵扣</text>
<view class="box align-right"> <view class="box align-right">
<text class="color-base-text price-font"> <text class="color-base-text price-font">
<text class="operator">-</text> <text class="operator">-</text>
@@ -582,7 +586,7 @@
</view> </view>
<view class="order-cell"> <view class="order-cell">
<view class="box align-right"> <view class="box align-right">
<text>{{ $lang('order.actualPayment') }}</text> <text>实付金额:</text>
<text class="color-base-text price-font"> <text class="color-base-text price-font">
<text class="font-size-goods-tag">{{ $lang('common.currencySymbol') }}</text> <text class="font-size-goods-tag">{{ $lang('common.currencySymbol') }}</text>
<text class="font-size-base">{{ orderData.order_money }}</text> <text class="font-size-base">{{ orderData.order_money }}</text>
@@ -594,8 +598,8 @@
<view class="order-box-btn white" <view class="order-box-btn white"
v-if="evaluateConfig.evaluate_status == 1 && orderData.is_evaluate == 1" v-if="evaluateConfig.evaluate_status == 1 && orderData.is_evaluate == 1"
@click="operation('memberOrderEvaluation')"> @click="operation('memberOrderEvaluation')">
<text v-if="orderData.evaluate_status == 0">{{ $lang('order.evaluate') }}</text> <text v-if="orderData.evaluate_status == 0">评价</text>
<text v-else-if="orderData.evaluate_status == 1">{{ $lang('order.additionalReview') }}</text> <text v-else-if="orderData.evaluate_status == 1">追评</text>
</view> </view>
<block v-if="orderData.order_scene == 'online'"> <block v-if="orderData.order_scene == 'online'">
<view class="order-box-btn" <view class="order-box-btn"
@@ -610,8 +614,8 @@
<view class="order-action fixed-bottom bottom-safe-area" <view class="order-action fixed-bottom bottom-safe-area"
v-else-if="orderData.action.length == 0 && orderData.is_evaluate == 1 && evaluateConfig.evaluate_status == 1"> v-else-if="orderData.action.length == 0 && orderData.is_evaluate == 1 && evaluateConfig.evaluate_status == 1">
<view class="order-box-btn white" @click="operation('memberOrderEvaluation')"> <view class="order-box-btn white" @click="operation('memberOrderEvaluation')">
<text v-if="orderData.evaluate_status == 0">{{ $lang('order.evaluate') }}</text> <text v-if="orderData.evaluate_status == 0">评价</text>
<text v-else-if="orderData.evaluate_status == 1">{{ $lang('order.additionalReview') }}</text> <text v-else-if="orderData.evaluate_status == 1">追评</text>
</view> </view>
</view> </view>
</view> </view>
@@ -730,7 +734,7 @@ export default {
if (this.$refs.loadingCover) this.$refs.loadingCover.hide(); if (this.$refs.loadingCover) this.$refs.loadingCover.hide();
} else { } else {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('order.noOrderInfo') title: '未获取到订单信息!'
}); });
setTimeout(() => { setTimeout(() => {
this.$util.redirectTo('/pages_order/list'); this.$util.redirectTo('/pages_order/list');

View File

@@ -11,8 +11,8 @@
:src="$util.img('public/uniapp/order/order-icon-close.png')" /> :src="$util.img('public/uniapp/order/order-icon-close.png')" />
<view class="status-name"> <view class="status-name">
<view class="status-name"> <view class="status-name">
{{ orderData.order_status == 0 ? $lang('order.waitPay') : orderData.order_status == 1 ? $lang('order.completed') : {{ orderData.order_status == 0 ? '待支付' : orderData.order_status == 1 ? '已完成' :
orderData.order_status == -1 ? $lang('order.closed') : '' }} orderData.order_status == -1 ? '已关闭' : '' }}
</view> </view>
</view> </view>
</view> </view>
@@ -32,7 +32,7 @@
<view> <view>
<text class="goods-price color-base-text"> <text class="goods-price color-base-text">
<text> <text>
<text>{{ $lang('order.pointCount', { count: orderData.point }) }}</text> <text>{{ orderData.point }}积分</text>
<text v-if="orderData.price > 0" class="price-color"> <text v-if="orderData.price > 0" class="price-color">
+ +
<text class="unit">{{ $lang('common.currencySymbol') }}</text> <text class="unit">{{ $lang('common.currencySymbol') }}</text>
@@ -58,26 +58,26 @@
<!-- 订单概况 --> <!-- 订单概况 -->
<view class="order-summary"> <view class="order-summary">
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.orderNo') }}</text> <text class="tit">订单编号:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ orderData.order_no }}</text> <text class="color-title">{{ orderData.order_no }}</text>
<view class="copy" @click="$util.copy(orderData.order_no)">{{ $lang('order.copy') }}</view> <view class="copy" @click="$util.copy(orderData.order_no)">复制</view>
</view> </view>
</view> </view>
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.tradeNo') }}</text> <text class="tit">订单交易号:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ orderData.out_trade_no }}</text> <text class="color-title">{{ orderData.out_trade_no }}</text>
</view> </view>
</view> </view>
<view class="order-cell"> <view class="order-cell">
<text class="tit">{{ $lang('order.createTime') }}</text> <text class="tit">创建时间:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ $util.timeStampTurnTime(orderData.create_time) }}</text> <text class="color-title">{{ $util.timeStampTurnTime(orderData.create_time) }}</text>
</view> </view>
</view> </view>
<view class="order-cell" v-if="orderData.close_time > 0"> <view class="order-cell" v-if="orderData.close_time > 0">
<text class="tit">{{ $lang('order.closeTime') }}</text> <text class="tit">关闭时间:</text>
<view class="box"> <view class="box">
<text class="color-title">{{ $util.timeStampTurnTime(orderData.close_time) }}</text> <text class="color-title">{{ $util.timeStampTurnTime(orderData.close_time) }}</text>
</view> </view>
@@ -87,7 +87,7 @@
<view class="kefu"> <view class="kefu">
<view> <view>
<text class="iconfont icon-ziyuan"></text> <text class="iconfont icon-ziyuan"></text>
<text>{{ $lang('order.contactCustomerService') }}</text> <text>联系客服</text>
</view> </view>
</view> </view>
</ns-contact> --> </ns-contact> -->
@@ -96,7 +96,7 @@
<!-- 订单金额 --> <!-- 订单金额 -->
<view class="order-money"> <view class="order-money">
<view class="order-cell" v-if="orderData.point > 0"> <view class="order-cell" v-if="orderData.point > 0">
<text class="tit">{{ $lang('order.usePoint') }}</text> <text class="tit">使用积分</text>
<view class="box align-right"> <view class="box align-right">
<text class="color-base-text price-font"> <text class="color-base-text price-font">
<text>{{ orderData.point }}</text> <text>{{ orderData.point }}</text>
@@ -104,7 +104,7 @@
</view> </view>
</view> </view>
<view class="order-cell" v-if="orderData.delivery_price > 0"> <view class="order-cell" v-if="orderData.delivery_price > 0">
<text class="tit">{{ $lang('order.shippingFee') }}</text> <text class="tit">运费</text>
<view class="box align-right"> <view class="box align-right">
<text class="color-base-text price-font"> <text class="color-base-text price-font">
<text class="unit font-size-tag">{{ $lang('common.currencySymbol') }}</text> <text class="unit font-size-tag">{{ $lang('common.currencySymbol') }}</text>
@@ -114,7 +114,7 @@
</view> </view>
<view class="order-cell" v-if="orderData.order_money > 0"> <view class="order-cell" v-if="orderData.order_money > 0">
<view class="box align-right"> <view class="box align-right">
<text>{{ $lang('order.actualPayment') }}</text> <text>实付金额:</text>
<text class="color-base-text price-font"> <text class="color-base-text price-font">
<text class="font-size-goods-tag">{{ $lang('common.currencySymbol') }}</text> <text class="font-size-goods-tag">{{ $lang('common.currencySymbol') }}</text>
<text class="font-size-base">{{ orderData.order_money }}</text> <text class="font-size-base">{{ orderData.order_money }}</text>
@@ -123,9 +123,9 @@
</view> </view>
<view class="order-action" v-if="orderData.order_status == 0 && orderData.type == 1"> <view class="order-action" v-if="orderData.order_status == 0 && orderData.type == 1">
<view class="order-box-btn" @click="orderClose()">{{ $lang('order.close') }}</view> <view class="order-box-btn" @click="orderClose()">关闭</view>
<view class="order-box-btn color-base-bg color-base-border color-text-white" <view class="order-box-btn color-base-bg color-base-border color-text-white"
@click="openChoosePayment()">{{ $lang('order.pay') }}</view> @click="openChoosePayment()">支付</view>
</view> </view>
</view> </view>
@@ -200,7 +200,7 @@ export default {
JSON.parse(this.orderData.delivery_store_info); JSON.parse(this.orderData.delivery_store_info);
} else { } else {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('order.noOrderInfo') title: '未获取到订单信息!'
}); });
setTimeout(() => { setTimeout(() => {
this.$util.redirectTo('/pages_order/list'); this.$util.redirectTo('/pages_order/list');
@@ -221,8 +221,8 @@ export default {
}, },
orderClose() { orderClose() {
uni.showModal({ uni.showModal({
title: this.$lang('common.tip'), title: '提示',
content: this.$lang('point.confirmClose'), content: '确定关闭此次兑换?',
success: res => { success: res => {
if (res.confirm) { if (res.confirm) {
this.$api.sendRequest({ this.$api.sendRequest({
@@ -233,7 +233,7 @@ export default {
success: res => { success: res => {
if (res.code >= 0) { if (res.code >= 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('point.closeSuccess') title: '关闭成功'
}); });
this.getOrderData(); this.getOrderData();
} }

View File

@@ -3,7 +3,7 @@
<view class="cate-search"> <view class="cate-search">
<view class="search-box"> <view class="search-box">
<input class="uni-input" maxlength="50" v-model="searchText" confirm-type="search" <input class="uni-input" maxlength="50" v-model="searchText" confirm-type="search"
:placeholder="$lang('order.searchPlaceholder')" @confirm="search()" @click.stop="search()" @tap.stop="search()" /> placeholder="请输入商品名称/订单编号" @confirm="search()" @click.stop="search()" @tap.stop="search()" />
<text class="iconfont icon-sousuo3" @click.stop="search()" @tap.stop="search()"></text> <text class="iconfont icon-sousuo3" @click.stop="search()" @tap.stop="search()"></text>
</view> </view>
</view> </view>
@@ -32,7 +32,7 @@
:class="$util.inArray(orderItem.order_id, mergePayOrder) == -1 ? 'icon-yuan_checkbox' : 'icon-yuan_checked color-base-text'" :class="$util.inArray(orderItem.order_id, mergePayOrder) == -1 ? 'icon-yuan_checkbox' : 'icon-yuan_checked color-base-text'"
@click="selectOrder(orderItem.order_id, orderItem.pay_money)" @click="selectOrder(orderItem.order_id, orderItem.pay_money)"
v-if="orderStatus == 'waitpay' && orderItem.order_status == 0"></view> --> v-if="orderStatus == 'waitpay' && orderItem.order_status == 0"></view> -->
<text class="order-no">{{ $lang('order.orderNo') }}{{ orderItem.order_no }}</text> <text class="order-no">订单号:{{ orderItem.order_no }}</text>
<text class="order-type-name">{{ orderItem.order_type_name }}</text> <text class="order-type-name">{{ orderItem.order_type_name }}</text>
<text class="status-name">{{ orderItem.order_status_name }}</text> <text class="status-name">{{ orderItem.order_status_name }}</text>
</view> </view>
@@ -98,18 +98,18 @@
<view class="order-footer"> <view class="order-footer">
<view class="order-base-info"> <view class="order-base-info">
<view class="total"> <view class="total">
<text class="font-size-sub">{{ $lang('order.totalGoods') }}{{ orderItem.goods_num }}{{ $lang('cart.types') }}</text> <text class="font-size-sub">共{{ orderItem.goods_num }}件商品</text>
<text class="align-right font-size-base"> <text class="align-right font-size-base">
{{ $lang('order.actualPayment') }} 实付款:
<text class="font-size-base price-font">{{ $lang('common.currencySymbol') <text class="font-size-base price-font">{{ $lang('common.currencySymbol')
}}{{ orderItem.order_money }}</text> }}{{ orderItem.order_money }}</text>
</text> </text>
</view> </view>
</view> </view>
<view class="order-action" v-if="orderItem.action.length > 0"> <view class="order-action" v-if="orderItem.action.length > 0">
<view class="order-time" v-if="orderItem.order_status == 0" id="action-date"> <view class="order-time" v-if="orderItem.order_status == 0" id="action-date">
<image :src="$util.img('public/uniapp/order/time.png')" show-menu-by-longpress></image> <image :src="$util.img('public/uniapp/order/time.png')" show-menu-by-longpress></image>
{{ $lang('order.remainingTime') }} 剩余时间:
<uni-count-down :day="orderItem.discountTimeMachine.d" <uni-count-down :day="orderItem.discountTimeMachine.d"
:hour="orderItem.discountTimeMachine.h" :hour="orderItem.discountTimeMachine.h"
:minute="orderItem.discountTimeMachine.i" :minute="orderItem.discountTimeMachine.i"
@@ -119,8 +119,8 @@
<view class="order-box-btn" <view class="order-box-btn"
v-if="evaluateConfig.evaluate_status == 1 && orderItem.is_evaluate == 1" v-if="evaluateConfig.evaluate_status == 1 && orderItem.is_evaluate == 1"
@click="operation('memberOrderEvaluation', orderItem)"> @click="operation('memberOrderEvaluation', orderItem)">
<text v-if="orderItem.evaluate_status == 0">{{ $lang('order.evaluate') }}</text> <text v-if="orderItem.evaluate_status == 0">评价</text>
<text v-else-if="orderItem.evaluate_status == 1">{{ $lang('order.additionalEvaluate') }}</text> <text v-else-if="orderItem.evaluate_status == 1">追评</text>
</view> </view>
<view class="order-box-btn" <view class="order-box-btn"
:class="{ 'color-base-border color-base-bg': operationItem.action == 'orderPay' }" :class="{ 'color-base-border color-base-bg': operationItem.action == 'orderPay' }"
@@ -133,12 +133,12 @@
v-else-if="orderItem.action.length == 0 && orderItem.is_evaluate == 1 && evaluateConfig.evaluate_status == 1"> v-else-if="orderItem.action.length == 0 && orderItem.is_evaluate == 1 && evaluateConfig.evaluate_status == 1">
<view class="order-box-btn" v-if="orderItem.is_evaluate == 1" <view class="order-box-btn" v-if="orderItem.is_evaluate == 1"
@click="operation('memberOrderEvaluation', orderItem)"> @click="operation('memberOrderEvaluation', orderItem)">
<text v-if="orderItem.evaluate_status == 0">{{ $lang('order.evaluate') }}</text> <text v-if="orderItem.evaluate_status == 0">评价</text>
<text v-else-if="orderItem.evaluate_status == 1">{{ $lang('order.additionalEvaluate') }}</text> <text v-else-if="orderItem.evaluate_status == 1">追评</text>
</view> </view>
</view> </view>
<view class="order-action" v-else> <view class="order-action" v-else>
<view class="order-box-btn" @click="orderDetail(orderItem)">{{ $lang('order.viewDetail') }}</view> <view class="order-box-btn" @click="orderDetail(orderItem)">查看详情</view>
</view> </view>
</view> </view>
</view> </view>
@@ -289,27 +289,27 @@ export default {
getOrderStatus() { getOrderStatus() {
this.statusList = [{ this.statusList = [{
status: 'all', status: 'all',
name: this.$lang('order.all'), name: '全部',
id: 'status_0' id: 'status_0'
}, },
{ {
status: 'waitpay', status: 'waitpay',
name: this.$lang('order.waitpay'), name: '待付款',
id: 'status_1' id: 'status_1'
}, },
{ {
status: 'waitsend', status: 'waitsend',
name: this.$lang('order.waitsend'), name: '待发货',
id: 'status_2' id: 'status_2'
}, },
{ {
status: 'waitconfirm', status: 'waitconfirm',
name: this.$lang('order.waitconfirm'), name: '待收货',
id: 'status_3' id: 'status_3'
}, },
{ {
status: 'waitrate', status: 'waitrate',
name: this.$lang('order.completed'), name: '已完成',
id: 'status_4' id: 'status_4'
}, },
/*{ /*{

View File

@@ -34,20 +34,20 @@ export default {
*/ */
promotion(data){ promotion(data){
if (data.promotion && data.promotion.manjian && data.promotion.manjian.length) { if (data.promotion && data.promotion.manjian && data.promotion.manjian.length) {
let promotionStr = {title: this.$lang('order.fullReduce'), content: ''} let promotionStr = {title: `满减送`, content: ''}
data.promotion.manjian.forEach((mItem,mIndex)=>{ data.promotion.manjian.forEach((mItem,mIndex)=>{
let promotion = ''; let promotion = '';
let content = {}; let content = {};
let limit = mItem.type == 0 ? this.$lang('common.yuan') : this.$lang('sku.unit'); let limit = mItem.type == 0 ? '元' : '件';
if(mItem.rule){ if(mItem.rule){
var item = mItem.discount_array.rule; var item = mItem.discount_array.rule;
item.limit = mItem.type == 0 ? parseFloat(item.limit).toFixed(2) : parseInt(item.limit); item.limit = mItem.type == 0 ? parseFloat(item.limit).toFixed(2) : parseInt(item.limit);
// 满减 // 满减
if (item.discount_money != undefined) { if (item.discount_money != undefined) {
if (content.manjian == undefined) { if (content.manjian == undefined) {
content.manjian = this.$lang('order.fullReduceDesc', { limit: item.limit, type: limit, money: item.discount_money }); content.manjian = '购买可享受满' + item.limit + limit + '减' + item.discount_money + '元';
} else { } else {
content.manjian += this.$lang('order.fullReduceDesc', { limit: item.limit, type: limit, money: item.discount_money }); content.manjian += ';满' + item.limit + limit + '减' + item.discount_money + '元';
} }
} }
// 满送优惠券 // 满送优惠券
@@ -55,32 +55,32 @@ export default {
let text = ''; let text = '';
item.coupon_list.forEach((couponItem, couponIndex) => { item.coupon_list.forEach((couponItem, couponIndex) => {
if (couponItem.type == 'discount') { if (couponItem.type == 'discount') {
if (text == '') text = this.$lang('order.fullSendCoupon', { num: couponItem.give_num, value: parseFloat(couponItem.discount) }); if (text == '') text = '送'+ couponItem.give_num +'张' + parseFloat(couponItem.discount) + '折优惠券';
else text += '、' + this.$lang('order.fullSendCoupon', { num: couponItem.give_num, value: parseFloat(couponItem.discount) }); else text += '、送'+ couponItem.give_num +'张' + parseFloat(couponItem.discount) + '折优惠券';
} else { } else {
if (text == '') text = this.$lang('order.fullSendCoupon', { num: couponItem.give_num, value: parseFloat(couponItem.money) }); if (text == '') text = '送'+ couponItem.give_num +'张' + parseFloat(couponItem.money) + '元优惠券';
else text += '、' + this.$lang('order.fullSendCoupon', { num: couponItem.give_num, value: parseFloat(couponItem.money) }); else text += '、送'+ couponItem.give_num +'张' + parseFloat(couponItem.money) + '元优惠券';
} }
}) })
if (content.mansong == undefined) { if (content.mansong == undefined) {
content.mansong = this.$lang('order.fullSend', { limit: item.limit, type: limit }) + text; content.mansong = '购物满' + item.limit + limit + text;
} else { } else {
content.mansong += ';' + this.$lang('order.fullSend', { limit: item.limit, type: limit }) + text; content.mansong += ';' + '满' + item.limit + limit + text;
} }
} }
// 满送积分 // 满送积分
if (item.point) { if (item.point) {
let point_text = this.$lang('order.fullSendPoint', { point: item.point }); let point_text = '可得' + item.point + '积分';
if(content.point_text == undefined) { if(content.point_text == undefined) {
content.point_text = this.$lang('order.fullSend', { limit: item.limit, type: limit }) + point_text content.point_text = '购物满' + item.limit + limit + point_text
}else { }else {
content.point_text += ';' + this.$lang('order.fullSend', { limit: item.limit, type: limit }) + point_text; content.point_text += ';' + '满' + item.limit + limit + point_text;
} }
} }
// 包邮 // 包邮
if (item.free_shipping != undefined) { if (item.free_shipping != undefined) {
if (content.free_shipping == undefined) { if (content.free_shipping == undefined) {
content.free_shipping = this.$lang('order.freeShipping', { limit: item.limit, type: limit }); content.free_shipping = '购物满' + item.limit + limit + '包邮';
} }
} }
} }

View File

@@ -9,8 +9,8 @@ export default {
this.pay(); this.pay();
} else { } else {
uni.showModal({ uni.showModal({
title: this.$lang('common.tip'), title: '提示',
content: this.$lang('order.payAmountAdjusted', { amount: orderData.pay_money }), content: '商家已将支付金额调整为' + orderData.pay_money + '元,是否继续支付?',
success: res => { success: res => {
if (res.confirm) { if (res.confirm) {
this.pay(); this.pay();
@@ -43,8 +43,8 @@ export default {
*/ */
orderClose(order_id, callback) { orderClose(order_id, callback) {
uni.showModal({ uni.showModal({
title: this.$lang('common.tip'), title: '提示',
content: this.$lang('order.confirmCloseOrder'), content: '您确定要关闭该订单吗?',
success: res => { success: res => {
if (res.confirm) { if (res.confirm) {
this.$api.sendRequest({ this.$api.sendRequest({
@@ -57,7 +57,8 @@ export default {
typeof callback == 'function' && callback(); typeof callback == 'function' && callback();
} else { } else {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('order.cannotCloseOrder', { message: res.message }), title: '当前订单可能存在拼团,维权等操作,' + res.message +
'不可以关闭哦!',
duration: 2000 duration: 2000
}) })
} }
@@ -76,8 +77,8 @@ export default {
// 如果不在微信小程序中 // 如果不在微信小程序中
// #ifndef MP-WEIXIN // #ifndef MP-WEIXIN
uni.showModal({ uni.showModal({
title: this.$lang('common.tip'), title: '提示',
content: this.$lang('order.confirmReceived'), content: '您确定已经收到货物了吗?',
success: res => { success: res => {
if (res.confirm) { if (res.confirm) {
this.$api.sendRequest({ this.$api.sendRequest({
@@ -140,8 +141,8 @@ export default {
}) })
} else { } else {
uni.showModal({ uni.showModal({
title: this.$lang('common.tip'), title: '提示',
content: this.$lang('order.confirmReceived'), content: '您确定已经收到货物了吗?',
success: res => { success: res => {
if (res.confirm) { if (res.confirm) {
this.$api.sendRequest({ this.$api.sendRequest({
@@ -171,8 +172,8 @@ export default {
// 如果不在微信小程序中 // 如果不在微信小程序中
// #ifndef MP-WEIXIN // #ifndef MP-WEIXIN
uni.showModal({ uni.showModal({
title: this.$lang('common.tip'), title: '提示',
content: this.$lang('order.confirmTakeDelivery'), content: '您确定要进行收货吗?',
success: res => { success: res => {
if (res.confirm) { if (res.confirm) {
this.$api.sendRequest({ this.$api.sendRequest({
@@ -234,8 +235,8 @@ export default {
}) })
} else { } else {
uni.showModal({ uni.showModal({
title: this.$lang('common.tip'), title: '提示',
content: this.$lang('order.confirmTakeDelivery'), content: '您确定要进行收货吗?',
success: res => { success: res => {
if (res.confirm) { if (res.confirm) {
this.$api.sendRequest({ this.$api.sendRequest({

View File

@@ -7,8 +7,8 @@ export default {
*/ */
cancleRefund(order_goods_id, callback) { cancleRefund(order_goods_id, callback) {
uni.showModal({ uni.showModal({
content: this.$lang('order.cancelRefundConfirm'), content: '撤销之后本次申请将会关闭,如后续仍有问题可再次发起申请。',
cancelText: this.$lang('order.notCancelYet'), cancelText: '暂不撤销',
cancelColor: '#898989', cancelColor: '#898989',
success: res => { success: res => {
if (res.confirm) { if (res.confirm) {

View File

@@ -13,7 +13,7 @@
<view class="image" :class="fenXiaoAgreement.agreement.img ? '' : 'color-base-bg'"> <view class="image" :class="fenXiaoAgreement.agreement.img ? '' : 'color-base-bg'">
<image v-if="fenXiaoAgreement.agreement.img" class="apply-adv" :src="$util.img(fenXiaoAgreement.agreement.img)" mode="widthFix" style="width: 100%;" show-menu-by-longpress/> <image v-if="fenXiaoAgreement.agreement.img" class="apply-adv" :src="$util.img(fenXiaoAgreement.agreement.img)" mode="widthFix" style="width: 100%;" show-menu-by-longpress/>
<view class="bg ns-gradient-otherpages-fenxiao-apply-apply-bg" v-else> <view class="bg ns-gradient-otherpages-fenxiao-apply-apply-bg" v-else>
<view class="bg-title"><text>{{ $lang('fenxiao.fillApplyInfo') }}</text></view> <view class="bg-title"><text>请填写申请信息</text></view>
<view class="bg-img"> <view class="bg-img">
<image :src="$util.img('public/uniapp/fenxiao/apply/edit.png')" mode="scaleToFill" show-menu-by-longpress></image> <image :src="$util.img('public/uniapp/fenxiao/apply/edit.png')" mode="scaleToFill" show-menu-by-longpress></image>
</view> </view>
@@ -24,44 +24,44 @@
<view class="app-info"> <view class="app-info">
<view class="info"> <view class="info">
<view class="apply-item"> <view class="apply-item">
<view class="title">{{ $lang('fenxiao.inviter') }}</view> <view class="title">邀请人</view>
<text class="shuru">{{ sourceMemberInfo.fenxiao_name || $lang('fenxiao.none') }}</text> <text class="shuru">{{ sourceMemberInfo.fenxiao_name }}</text>
</view> </view>
<view class="apply-item"> <view class="apply-item">
<view class="title">{{ fenxiaoWords.fenxiao_name }}{{ $lang('fenxiao.name') }}</view> <view class="title">{{ fenxiaoWords.fenxiao_name }}名称</view>
<input class="input" type="text" maxlength="30" :placeholder="$lang('fenxiao.inputFenxiaoName')" v-model="formData.fenXiaoName" placeholder-class="pla-cla" /> <input class="input" type="text" maxlength="30" :placeholder="'请输入' + fenxiaoWords.fenxiao_name + '名称'" v-model="formData.fenXiaoName" placeholder-class="pla-cla" />
</view> </view>
<view class="apply-item"> <view class="apply-item">
<view class="title">{{ $lang('member.mobile') }}</view> <view class="title">手机号</view>
<input class="input" type="number" :placeholder="$lang('form.inputMobile')" maxlength="11" v-model="formData.mobile" placeholder-class="pla-cla" /> <input class="input" type="number" placeholder="请输入手机号" maxlength="11" v-model="formData.mobile" placeholder-class="pla-cla" />
</view> </view>
<view class="apply-xy" v-if="isAgreement" @click="ckeckedRuler()"> <view class="apply-xy" v-if="isAgreement" @click="ckeckedRuler()">
<view class="iconfont" :class="isChecked ? 'icon-yuan_checked color-base-text' : 'icon-yuan_checkbox'"> <view class="iconfont" :class="isChecked ? 'icon-yuan_checked color-base-text' : 'icon-yuan_checkbox'">
</view> </view>
{{ $lang('fenxiao.readAndAgree') }} 我已阅读并了解
<text class="color-base-text" @click.stop="openPopup">【{{ fenxiaoWords.fenxiao_name }}{{ $lang('fenxiao.applyAgreement') }}】</text> <text class="color-base-text" @click.stop="openPopup">【{{ fenxiaoWords.fenxiao_name }}申请协议】</text>
</view> </view>
<view class="apply-btn"> <view class="apply-btn">
<button @click="applyFenXiao" class="color-base-bg">{{ $lang('fenxiao.applyToBecome') }}{{ fenxiaoWords.fenxiao_name }}</button> <button @click="applyFenXiao" class="color-base-bg">申请成为{{ fenxiaoWords.fenxiao_name }}</button>
</view> </view>
</view> </view>
</view> </view>
<view class="apply-message-wrap" v-if="fenxiaoConfig.fenxiao_condition == 2 || fenxiaoConfig.fenxiao_condition == 3"> <view class="apply-message-wrap" v-if="fenxiaoConfig.fenxiao_condition == 2 || fenxiaoConfig.fenxiao_condition == 3">
<view class="apply-message"> <view class="apply-message">
<view class="apply-message-title color-base-bg-before">{{ $lang('fenxiao.applyCondition') }}</view> <view class="apply-message-title color-base-bg-before">分销商申请条件</view>
<text class="apply-message-info font-size-goods-tag" v-if="fenxiaoConfig.fenxiao_condition == 2"> <text class="apply-message-info font-size-goods-tag" v-if="fenxiaoConfig.fenxiao_condition == 2">
{{ $lang('fenxiao.applyFenxiao') }},{{ $lang('fenxiao.consumeCountTip') }}{{ fenxiaoConfig.consume_count }}{{ $lang('fenxiao.times') }} 申请成为{{ fenxiaoWords.fenxiao_name }},需要您的消费次数需要达到{{ fenxiaoConfig.consume_count }}次
</text> </text>
<text class="apply-message-info font-size-goods-tag" v-if="fenxiaoConfig.fenxiao_condition == 3"> <text class="apply-message-info font-size-goods-tag" v-if="fenxiaoConfig.fenxiao_condition == 3">
{{ $lang('fenxiao.applyFenxiao') }},{{ $lang('fenxiao.consumeMoneyTip') }}{{ fenxiaoConfig.consume_money }}{{ $lang('fenxiao.yuan') }} 申请成为{{ fenxiaoWords.fenxiao_name }},需要您的消费金额需要达到{{ fenxiaoConfig.consume_money }}元
</text> </text>
</view> </view>
</view> </view>
<view class="app-info-list" v-if="fenxiaoConfig.fenxiao_condition == 4"> <view class="app-info-list" v-if="fenxiaoConfig.fenxiao_condition == 4">
<view class="apply-message"> <view class="apply-message">
<view class="apply-message-title color-base-bg-before">{{ $lang('fenxiao.applyCondition') }}</view> <view class="apply-message-title color-base-bg-before">分销商申请条件</view>
<text class="apply-message-info font-size-goods-tag">{{ $lang('fenxiao.applyFenxiao') }},{{ $lang('fenxiao.buyDesignatedGoods') }}</text> <text class="apply-message-info font-size-goods-tag">申请成为{{ fenxiaoWords.fenxiao_name }},需要购买以下指定商品(任选其一)</text>
</view> </view>
<view class="goods-list" v-for="(item, index) in goodsList" :key="index" @click="toDetail(item)"> <view class="goods-list" v-for="(item, index) in goodsList" :key="index" @click="toDetail(item)">
<view class="goods-img"> <view class="goods-img">
@@ -79,7 +79,7 @@
</view> </view>
</view> </view>
<view class="content-lists" v-if="isShow" @click="onOpen()"> <view class="content-lists" v-if="isShow" @click="onOpen()">
{{ isOpen ? $lang('fenxiao.expandMore') : $lang('fenxiao.collapse') }} {{ isOpen ? '展开更多' : '收起' }}
<text class="iconfont icon-unfold" style="font-weight: bold;" v-if="isOpen"></text> <text class="iconfont icon-unfold" style="font-weight: bold;" v-if="isOpen"></text>
<text class="iconfont icon-fold" v-else></text> <text class="iconfont icon-fold" v-else></text>
</view> </view>
@@ -89,16 +89,16 @@
<view class="empty" v-else-if="basicsConfig.is_apply == 0" style="margin-top:40rpx;"> <view class="empty" v-else-if="basicsConfig.is_apply == 0" style="margin-top:40rpx;">
<block v-if="fenxiaoConfig.fenxiao_condition == 2 || fenxiaoConfig.fenxiao_condition == 3"> <block v-if="fenxiaoConfig.fenxiao_condition == 2 || fenxiaoConfig.fenxiao_condition == 3">
<image :src="$util.img('public/uniapp/fenxiao/index/no-fenxiao.png')" mode="widthFix" show-menu-by-longpress></image> <image :src="$util.img('public/uniapp/fenxiao/index/no-fenxiao.png')" mode="widthFix" show-menu-by-longpress></image>
<text v-if="fenxiaoConfig.fenxiao_condition == 2">{{ $lang('fenxiao.applyFenxiao') }},{{ $lang('fenxiao.consumeCountTip') }}{{ fenxiaoConfig.consume_count }}{{ $lang('fenxiao.times') }}</text> <text v-if="fenxiaoConfig.fenxiao_condition == 2">申请成为{{ fenxiaoWords.fenxiao_name }},需要您的消费次数需要达到{{ fenxiaoConfig.consume_count }}次</text>
<text v-if="fenxiaoConfig.fenxiao_condition == 3"> <text v-if="fenxiaoConfig.fenxiao_condition == 3">
{{ $lang('fenxiao.applyFenxiao') }},{{ $lang('fenxiao.consumeMoneyTip') }}{{ fenxiaoConfig.consume_money | moneyFormat }}{{ $lang('fenxiao.yuan') }} 申请成为{{ fenxiaoWords.fenxiao_name }},需要您的消费金额需要达到{{ fenxiaoConfig.consume_money | moneyFormat }}元
</text> </text>
</block> </block>
<view class="apply-wrap" v-if="fenxiaoConfig.fenxiao_condition == 4"> <view class="apply-wrap" v-if="fenxiaoConfig.fenxiao_condition == 4">
<view class="app-info-list"> <view class="app-info-list">
<view class="apply-message"> <view class="apply-message">
<view class="apply-message-title color-base-bg-before">{{ $lang('fenxiao.becomeFenxiaoCondition') }}</view> <view class="apply-message-title color-base-bg-before">成为分销商的条件</view>
<text class="apply-message-info font-size-goods-tag">{{ $lang('fenxiao.becomeFenxiao') }},{{ $lang('fenxiao.buyDesignatedGoods') }}</text> <text class="apply-message-info font-size-goods-tag">成为{{ fenxiaoWords.fenxiao_name }},需要购买以下指定商品(任选其一)</text>
</view> </view>
<view class="goods-list" v-for="(item, index) in goodsList" :key="index" @click="toDetail(item)"> <view class="goods-list" v-for="(item, index) in goodsList" :key="index" @click="toDetail(item)">
<view class="goods-img"> <view class="goods-img">
@@ -114,7 +114,7 @@
</view> </view>
</view> </view>
<view class="content-lists" v-if="isShow" @click="onOpen()"> <view class="content-lists" v-if="isShow" @click="onOpen()">
{{ isOpen ? $lang('fenxiao.expandMore') : $lang('fenxiao.collapse') }} {{ isOpen ? '展开更多' : '收起' }}
<text class="iconfont icon-unfold" style="font-weight: bold;" v-if="isOpen"></text> <text class="iconfont icon-unfold" style="font-weight: bold;" v-if="isOpen"></text>
<text class="iconfont icon-fold" v-else></text> <text class="iconfont icon-fold" v-else></text>
</view> </view>
@@ -123,15 +123,15 @@
</view> </view>
<view class="empty" v-else> <view class="empty" v-else>
<image :src="$util.img('public/uniapp/fenxiao/index/no-fenxiao.png')" mode="widthFix" show-menu-by-longpress></image> <image :src="$util.img('public/uniapp/fenxiao/index/no-fenxiao.png')" mode="widthFix" show-menu-by-longpress></image>
<text>{{ $lang('fenxiao.notDistributor') }}</text> <text>您还不是分销商</text>
</view> </view>
</view> </view>
<view class="empty" v-else> <view class="empty" v-else>
<image :src="$util.img('public/uniapp/fenxiao/index/no-fenxiao.png')" mode="widthFix" show-menu-by-longpress></image> <image :src="$util.img('public/uniapp/fenxiao/index/no-fenxiao.png')" mode="widthFix" show-menu-by-longpress></image>
<text v-if="status == 1">{{ $lang('fenxiao.submittedWaitAudit', { fenxiao_name: fenxiaoWords.fenxiao_name }) }}</text> <text v-if="status == 1">您已提交{{ fenxiaoWords.fenxiao_name }}申请,等待平台审核</text>
<block v-else-if="status == -1"> <block v-else-if="status == -1">
<text>{{ $lang('fenxiao.applicationRejected', { fenxiao_name: fenxiaoWords.fenxiao_name }) }}</text> <text>您提交的{{ fenxiaoWords.fenxiao_name }}申请,已被拒绝,请再接再厉</text>
<view class="again-btn color-base-bg" @click="againApply">{{ $lang('fenxiao.reapply') }}</view> <view class="again-btn color-base-bg" @click="againApply">重新申请</view>
</block> </block>
</view> </view>
<view @touchmove.prevent v-if="fenXiaoAgreement.document"> <view @touchmove.prevent v-if="fenXiaoAgreement.document">
@@ -163,7 +163,7 @@
isIphoneX: false, isIphoneX: false,
// 推荐人信息 // 推荐人信息
sourceMemberInfo: { sourceMemberInfo: {
fenxiao_name: '' fenxiao_name: '无'
}, },
formData: { formData: {
fenXiaoName: '', fenXiaoName: '',
@@ -191,7 +191,7 @@
setTimeout( () => { setTimeout( () => {
if (!this.addonIsExist.fenxiao) { if (!this.addonIsExist.fenxiao) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.merchantNotOpenFenxiao'), title: '商家未开启分销',
mask: true, mask: true,
duration: 2000 duration: 2000
}); });
@@ -207,7 +207,7 @@
async onShow() { async onShow() {
this.isIphoneX = this.$util.uniappIsIPhoneX(); this.isIphoneX = this.$util.uniappIsIPhoneX();
if (this.fenxiaoWords && this.fenxiaoWords.fenxiao_name) this.$langConfig.title(this.fenxiaoWords.fenxiao_name + this.$lang('fenxiao.apply')); if (this.fenxiaoWords && this.fenxiaoWords.fenxiao_name) this.$langConfig.title(this.fenxiaoWords.fenxiao_name + '申请');
if (this.storeToken) { if (this.storeToken) {
this.applyStatus(); this.applyStatus();
@@ -275,7 +275,7 @@
if (!this.fenXiaoValidata()) return; if (!this.fenXiaoValidata()) return;
if (this.isAgreement && !this.isChecked) { if (this.isAgreement && !this.isChecked) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.pleaseReadAgreement') title: '请仔细阅读协议,并勾选'
}); });
return; return;
} }
@@ -330,17 +330,17 @@
let rule = [{ let rule = [{
name: 'fenXiaoName', name: 'fenXiaoName',
checkType: 'required', checkType: 'required',
errorMsg: this.$lang('fenxiao.inputFenxiaoName') errorMsg: '请输入' + this.fenxiaoWords.fenxiao_name + '名称'
}, },
{ {
name: 'mobile', name: 'mobile',
checkType: 'required', checkType: 'required',
errorMsg: this.$lang('fenxiao.inputPhone') errorMsg: '请输入手机号'
}, },
{ {
name: 'mobile', name: 'mobile',
checkType: 'phoneno', checkType: 'phoneno',
errorMsg: this.$lang('fenxiao.inputPhoneCorrect') errorMsg: '请输入正确的手机号'
} }
]; ];
var checkRes = validate.check(this.formData, rule); var checkRes = validate.check(this.formData, rule);

View File

@@ -8,7 +8,7 @@
<image v-else :src="$util.img('public/uniapp/fenxiao/bill/withdraw.png')" mode="widthFix" show-menu-by-longpress></image> <image v-else :src="$util.img('public/uniapp/fenxiao/bill/withdraw.png')" mode="widthFix" show-menu-by-longpress></image>
<view class="balances-info"> <view class="balances-info">
<text>{{ item.type_name }}</text> <text>{{ item.type_name }}</text>
<text>{{ $lang('fenxiao.orderNo') }}: {{ item.account_no }}</text> <text>账单编号: {{ item.account_no }}</text>
<text>{{ $util.timeStampTurnTime(item.create_time) }}</text> <text>{{ $util.timeStampTurnTime(item.create_time) }}</text>
</view> </view>
<view class="balances-num"> <view class="balances-num">
@@ -16,7 +16,7 @@
item.money }}</text> item.money }}</text>
</view> </view>
</view> </view>
<ns-empty v-if="!accountList.length && showEmpty" :text="$lang('fenxiao.emptyBill')" :isIndex="false"></ns-empty> <ns-empty v-if="!accountList.length && showEmpty" text="暂无账单信息" :isIndex="false"></ns-empty>
</block> </block>
<loading-cover ref="loadingCover"></loading-cover> <loading-cover ref="loadingCover"></loading-cover>
</mescroll-uni> </mescroll-uni>
@@ -35,7 +35,7 @@ export default {
setTimeout(() => { setTimeout(() => {
if (!this.addonIsExist.fenxiao) { if (!this.addonIsExist.fenxiao) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.merchantNotOpenFenxiao'), title: '商家未开启分销',
mask: true, mask: true,
duration: 2000 duration: 2000
}); });

View File

@@ -1,4 +1,4 @@
<template> <template>
<view :style="themeColor"> <view :style="themeColor">
<mescroll-uni ref="mescroll" @getData="getData" top="0" class="member-point" :size="8" v-if="storeToken"> <mescroll-uni ref="mescroll" @getData="getData" top="0" class="member-point" :size="8" v-if="storeToken">
<block slot="list"> <block slot="list">
@@ -16,20 +16,20 @@
<view v-if="item.level_name" class="title color-base-border color-base-text">{{ <view v-if="item.level_name" class="title color-base-border color-base-text">{{
item.level_name }}</view> item.level_name }}</view>
</view> </view>
<view class="color-tip font-size-goods-tag">{{ $lang('fenxiao.joinTime') }}:{{ <view class="color-tip font-size-goods-tag">加入时间:{{
$util.timeStampTurnTime(item.bind_fenxiao_time).substring(0, 10) }}</view> $util.timeStampTurnTime(item.bind_fenxiao_time).substring(0, 10) }}</view>
</view> </view>
<view class="consume-info"> <view class="consume-info">
<view><text>{{ item.one_child_fenxiao_num + item.one_child_num }}</text> {{ $lang('fenxiao.people') }}</view> <view><text>{{ item.one_child_fenxiao_num + item.one_child_num }}</text> 人</view>
<view><text>{{ item.order_num }}</text> {{ $lang('fenxiao.orders') }}</view> <view><text>{{ item.order_num }}</text> 单</view>
<view><text>{{ item.order_money | moneyFormat }}</text> {{ $lang('fenxiao.yuan') }}</view> <view><text>{{ item.order_money | moneyFormat }}</text> 元</view>
</view> </view>
</view> </view>
</view> </view>
</view> </view>
</view> </view>
<block v-if="teamList.length == 0 && emptyShow"> <block v-if="teamList.length == 0 && emptyShow">
<ns-empty :text="$lang('fenxiao.emptyData')" :isIndex="false"></ns-empty> <ns-empty text="暂无数据" :isIndex="false"></ns-empty>
</block> </block>
</block> </block>
</mescroll-uni> </mescroll-uni>
@@ -54,7 +54,7 @@ export default {
setTimeout(() => { setTimeout(() => {
if (!this.addonIsExist.fenxiao) { if (!this.addonIsExist.fenxiao) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.merchantNotOpenFenxiao'), title: '商家未开启分销',
mask: true, mask: true,
duration: 2000 duration: 2000
}); });

View File

@@ -9,7 +9,7 @@
<view class="uni-scroll-view-content"> <view class="uni-scroll-view-content">
<!-- #endif --> <!-- #endif -->
<view class="quick-nav-item" :class="{ selected: categoryId == 0 }" <view class="quick-nav-item" :class="{ selected: categoryId == 0 }"
@click="changeCategory(0)">{{ $lang('fenxiao.all') }}</view> @click="changeCategory(0)">全部</view>
<view class="quick-nav-item" v-for="item in categoryList" :key="item.category_id" <view class="quick-nav-item" v-for="item in categoryList" :key="item.category_id"
:class="{ selected: categoryId == item.category_id }" :class="{ selected: categoryId == item.category_id }"
@click="changeCategory(item.category_id)"> @click="changeCategory(item.category_id)">
@@ -39,24 +39,24 @@
</view> </view>
<view class="goods-share" @click.stop="shareFn('goods', index)"> <view class="goods-share" @click.stop="shareFn('goods', index)">
<text class="icondiy icon-system-share"></text> <text class="icondiy icon-system-share"></text>
<text class="txt" v-if="!is_fenxiao">{{ $lang('fenxiao.share') }}</text> <text class="txt" v-if="!is_fenxiao">分享</text>
<text class="txt" v-else>{{ $lang('fenxiao.earn') }}{{ item.commission_money }}{{ $lang('common.yuan') }}</text> <text class="txt" v-else>赚{{ item.commission_money }}元</text>
</view> </view>
</view> </view>
</view> </view>
</view> </view>
<view class="empty" v-if="goodsList.length == 0"> <view class="empty" v-if="goodsList.length == 0">
<ns-empty :isIndex="false" :text="$lang('fenxiao.emptyGoods')" textColor="#fff"></ns-empty> <ns-empty :isIndex="false" text="暂无分销商品" textColor="#fff"></ns-empty>
</view> </view>
</view> </view>
</block> </block>
</mescroll-uni> </mescroll-uni>
<view class="active-btn" v-if="goodsList.length"> <view class="active-btn" v-if="goodsList.length">
<!-- #ifdef MP --> <!-- #ifdef MP -->
<button class="share-btn" :plain="true" open-type="share">{{ $lang('fenxiao.shareFriend') }}</button> <button class="share-btn" :plain="true" open-type="share">分享好友</button>
<text class="tag">|</text> <text class="tag">|</text>
<!-- #endif --> <!-- #endif -->
<text class="btn" @click="shareFn('fenxiao')">{{ $lang('fenxiao.generatePoster') }}</text> <text class="btn" @click="shareFn('fenxiao')">生成海报</text>
</view> </view>
<loading-cover ref="loadingCover"></loading-cover> <loading-cover ref="loadingCover"></loading-cover>
@@ -64,13 +64,13 @@
<view @touchmove.prevent.stop> <view @touchmove.prevent.stop>
<uni-popup ref="sharePopup" type="bottom" class="share-popup"> <uni-popup ref="sharePopup" type="bottom" class="share-popup">
<view> <view>
<view class="share-title">{{ $lang('fenxiao.share') }}</view> <view class="share-title">分享</view>
<view class="share-content"> <view class="share-content">
<!-- #ifdef MP --> <!-- #ifdef MP -->
<view class="share-box"> <view class="share-box">
<button class="share-btn" :plain="true" open-type="share"> <button class="share-btn" :plain="true" open-type="share">
<view class="iconfont icon-share-friend"></view> <view class="iconfont icon-share-friend"></view>
<text>{{ $lang('fenxiao.shareToFriend') }}</text> <text>分享给好友</text>
</button> </button>
</view> </view>
<!-- #endif --> <!-- #endif -->
@@ -79,7 +79,7 @@
<view class="share-box" v-if="goodsCircle"> <view class="share-box" v-if="goodsCircle">
<button class="share-btn" :plain="true" @click="openBusinessView"> <button class="share-btn" :plain="true" @click="openBusinessView">
<view class="iconfont icon-haowuquan"></view> <view class="iconfont icon-haowuquan"></view>
<text>{{ $lang('fenxiao.shareToGoodsCircle') }}</text> <text>分享到好物圈</text>
</button> </button>
</view> </view>
<!-- #endif --> <!-- #endif -->
@@ -87,19 +87,19 @@
<view class="share-box" @click="openPosterPopup"> <view class="share-box" @click="openPosterPopup">
<button class="share-btn" :plain="true"> <button class="share-btn" :plain="true">
<view class="iconfont icon-pengyouquan"></view> <view class="iconfont icon-pengyouquan"></view>
<text>{{ $lang('fenxiao.generateSharePoster') }}</text> <text>生成分享海报</text>
</button> </button>
</view> </view>
<!-- #ifdef H5 --> <!-- #ifdef H5 -->
<view class="share-box" @click="copyUrl"> <view class="share-box" @click="copyUrl">
<button class="share-btn" :plain="true"> <button class="share-btn" :plain="true">
<view class="iconfont icon-fuzhilianjie"></view> <view class="iconfont icon-fuzhilianjie"></view>
<text>{{ $lang('fenxiao.copyLink') }}</text> <text>复制链接</text>
</button> </button>
</view> </view>
<!-- #endif --> <!-- #endif -->
</view> </view>
<view class="share-footer" @click="closeSharePopup"><text>{{ $lang('fenxiao.cancelShare') }}</text></view> <view class="share-footer" @click="closeSharePopup"><text>取消分享</text></view>
</view> </view>
</uni-popup> </uni-popup>
</view> </view>
@@ -112,10 +112,10 @@
<image :src="$util.img(poster)" show-menu-by-longpress /> <image :src="$util.img(poster)" show-menu-by-longpress />
</view> </view>
<!-- #ifdef MP || APP-PLUS --> <!-- #ifdef MP || APP-PLUS -->
<view class="save" @click="saveGoodsPoster()">{{ $lang('fenxiao.saveImage') }}</view> <view class="save" @click="saveGoodsPoster()">保存图片</view>
<!-- #endif --> <!-- #endif -->
<!-- #ifdef H5 --> <!-- #ifdef H5 -->
<view class="save">{{ $lang('fenxiao.longPressSave') }}</view> <view class="save">长按保存图片</view>
<!-- #endif --> <!-- #endif -->
</view> </view>
<view class="close iconfont icon-close" @click="closePosterPopup()"></view> <view class="close iconfont icon-close" @click="closePosterPopup()"></view>

View File

@@ -18,32 +18,32 @@
:src="$util.img('public/uniapp/fenxiao/index/commissionFission-level.png')" :src="$util.img('public/uniapp/fenxiao/index/commissionFission-level.png')"
alt="" class="level-icon">{{ info.level_name }}</p> alt="" class="level-icon">{{ info.level_name }}</p>
</view> </view>
<view class="recommend">{{ $lang('fenxiao.parentAgent') }}:{{ info.parent_name ? info.parent_name : $lang('fenxiao.mainStore') }}</view> <view class="recommend">上级代理商:{{ info.parent_name ? info.parent_name : '总店' }}</view>
<view class="recommend">{{ $lang('fenxiao.invitedSuccess') }}:{{ teamNum.num }}{{ $lang('fenxiao.people') }}<text class="iconfont icon-right" <view class="recommend">已邀请成功:{{ teamNum.num }}人<text class="iconfont icon-right"
style="font-size: 24rpx;"></text></view> style="font-size: 24rpx;"></text></view>
</view> </view>
<!-- <view class="promote-rules font-size-tag" @click="$util.redirectTo('/pages_promotion/fenxiao/promote')"> <!-- <view class="promote-rules font-size-tag" @click="$util.redirectTo('/pages_promotion/fenxiao/promote')">
<text class="iconfont icon-wenhao font-size-tag"></text> <text class="iconfont icon-wenhao font-size-tag"></text>
{{ $lang('fenxiao.promoteRule') }} 推广规则
</view> --> </view> -->
</view> </view>
<!-- <view class="fenxiao-level-wrap" v-if="levelList.length"> <!-- <view class="fenxiao-level-wrap" v-if="levelList.length">
<image :src="$util.img('public/uniapp/fenxiao/index/level_icon.png')" mode="widthFix" class="level-icon"/> <image :src="$util.img('public/uniapp/fenxiao/index/level_icon.png')" mode="widthFix" class="level-icon"/>
<view class="level-wrap" @click="$util.redirectTo('/pages_promotion/fenxiao/level')"> <view class="level-wrap" @click="$util.redirectTo('/pages_promotion/fenxiao/level')">
<view class="title">{{ info.level_num > 0 ? info.level_name : '{{ $lang('fenxiao.levelNotUnlock') }}' }}</view> <view class="title">{{ info.level_num > 0 ? info.level_name : '等级未解锁' }}</view>
<view class="desc">{{ $lang('fenxiao.placeOrder') }}、{{ $lang('fenxiao.inviteFriendUpgrade') }}</view> <view class="desc">下单、邀请好友均可提升等级</view>
</view> </view>
<view class="btn" @click="$refs.taskPopup.open()" v-if="info.condition.last_level">{{ $lang('fenxiao.doTask') }}</view> <view class="btn" @click="$refs.taskPopup.open()" v-if="info.condition.last_level">做任务</view>
</view> --> </view> -->
</view> </view>
<view class="fenxiao-index-allmoney"> <view class="fenxiao-index-allmoney">
<view class="allmoney-top-money"> <view class="allmoney-top-money">
<view class="allmoney-top"> <view class="allmoney-top">
<view class="font-size-sub">{{ $lang('fenxiao.can') }}{{ fenxiaoWords.withdraw }}({{ $lang('fenxiao.yuan') }})</view> <view class="font-size-sub">可{{ fenxiaoWords.withdraw }}(元)</view>
<view class="withdrawal-record" <view class="withdrawal-record"
@click="$util.redirectTo('/pages_promotion/fenxiao/withdraw_list')"> @click="$util.redirectTo('/pages_promotion/fenxiao/withdraw_list')">
{{ $lang('fenxiao.withdrawalDetail') }} 提现明细
<text class="iconfont icon-right"></text> <text class="iconfont icon-right"></text>
</view> </view>
</view> </view>
@@ -52,27 +52,27 @@
<view class="allmoney-bottom"> <view class="allmoney-bottom">
<!-- <view class="allmoney-all-wrap" @click="$util.redirectTo('/pages_promotion/fenxiao/bill')"> <!-- <view class="allmoney-all-wrap" @click="$util.redirectTo('/pages_promotion/fenxiao/bill')">
<view class="title">{{ $lang('fenxiao.total') }}{{ fenxiaoWords.account }}</view> <view class="title">总{{ fenxiaoWords.account }}</view>
<view class="money price-font">{{ info.total_commission | moneyFormat }}</view> <view class="money price-font">{{ info.total_commission | moneyFormat }}</view>
</view> </view>
<view class="allmoney-all-wrap" @click="$util.redirectTo('/pages_promotion/fenxiao/withdraw_list')"> <view class="allmoney-all-wrap" @click="$util.redirectTo('/pages_promotion/fenxiao/withdraw_list')">
<view class="title">{{ $lang('fenxiao.withdrawnAmount') }}{{ fenxiaoWords.account }}</view> <view class="title">已提现{{ fenxiaoWords.account }}</view>
<view class="money price-font">{{ info.account_withdraw | moneyFormat }}</view> <view class="money price-font">{{ info.account_withdraw | moneyFormat }}</view>
</view> --> </view> -->
<view class="allmoney-all-wrap" <view class="allmoney-all-wrap"
@click="$util.redirectTo('/pages_promotion/fenxiao/withdraw_list')"> @click="$util.redirectTo('/pages_promotion/fenxiao/withdraw_list')">
<view class="title">{{ $lang('fenxiao.withdrawing') }}({{ $lang('fenxiao.yuan') }})<text class="iconfont icon-right" <view class="title">提现中(元)<text class="iconfont icon-right"
style="font-size: 24rpx;"></text></view> style="font-size: 24rpx;"></text></view>
<view class="money price-font">{{ info.account_withdraw_apply | moneyFormat }}</view> <view class="money price-font">{{ info.account_withdraw_apply | moneyFormat }}</view>
</view> </view>
<view class="allmoney-all-wrap" <view class="allmoney-all-wrap"
@click="$util.redirectTo('/pages_promotion/fenxiao/order', { type: 1 })"> @click="$util.redirectTo('/pages_promotion/fenxiao/order', { type: 1 })">
<view class="title">{{ $lang('fenxiao.pendingEntry') }}({{ $lang('fenxiao.yuan') }})<text class="iconfont icon-right" <view class="title">待入账(元)<text class="iconfont icon-right"
style="font-size: 24rpx;"></text></view> style="font-size: 24rpx;"></text></view>
<view class="money price-font">{{ info.in_progress_money | moneyFormat }}</view> <view class="money price-font">{{ info.in_progress_money | moneyFormat }}</view>
</view> </view>
</view> </view>
<view class="withdraw-btn" @click="$util.redirectTo('/pages_promotion/fenxiao/withdraw_apply')">{{ $lang('fenxiao.withdraw') }} <view class="withdraw-btn" @click="$util.redirectTo('/pages_promotion/fenxiao/withdraw_apply')">提现
</view> </view>
</view> </view>
@@ -82,7 +82,7 @@
style="width: 100%;border-radius:24rpx" show-menu-by-longpress/> style="width: 100%;border-radius:24rpx" show-menu-by-longpress/>
</view> </view>
<!-- {{ $lang('fenxiao.functionList') }} --> <!-- 功能列表 -->
<view class="fenxiao-menu-list"> <view class="fenxiao-menu-list">
<view class="menu-item" @click="$util.redirectTo('/pages_promotion/fenxiao/team')"> <view class="menu-item" @click="$util.redirectTo('/pages_promotion/fenxiao/team')">
<view class="icon-wrap"> <view class="icon-wrap">
@@ -90,8 +90,8 @@
</image> </image>
</view> </view>
<view class="info"> <view class="info">
<view class="title">{{ $lang('fenxiao.myFans') }}</view> <view class="title">我的粉丝</view>
<view class="desc">{{ $lang('fenxiao.invitedUsers') }}</view> <view class="desc">邀请的用户</view>
</view> </view>
</view> </view>
<view class="menu-item" @click="$util.redirectTo('/pages_promotion/fenxiao/withdraw_list')"> <view class="menu-item" @click="$util.redirectTo('/pages_promotion/fenxiao/withdraw_list')">
@@ -100,8 +100,8 @@
</image> </image>
</view> </view>
<view class="info"> <view class="info">
<view class="title">{{ fenxiaoWords.withdraw }}{{ $lang('fenxiao.detail') }}</view> <view class="title">{{ fenxiaoWords.withdraw }}明细</view>
<view class="desc">{{ $lang('fenxiao.totalCommission') }}¥{{ info.total_commission | moneyFormat }} <view class="desc">累计{{ fenxiaoWords.account }}¥{{ info.total_commission | moneyFormat }}
</view> </view>
</view> </view>
</view> </view>
@@ -111,8 +111,8 @@
</image> </image>
</view> </view>
<view class="info"> <view class="info">
<view class="title">{{ fenxiaoWords.concept + $lang('fenxiao.order') }}</view> <view class="title">{{ fenxiaoWords.concept + '订单' }}</view>
<view class="desc">{{ fenxiaoWords.concept + $lang('fenxiao.order') }}{{ $lang('fenxiao.detail') }}</view> <view class="desc">{{ fenxiaoWords.concept + '订单' }}明细</view>
</view> </view>
</view> </view>
@@ -121,8 +121,8 @@
<image :src="$util.img('public/uniapp/fenxiao/index/friend.png')" mode="widthFix" show-menu-by-longpress></image> <image :src="$util.img('public/uniapp/fenxiao/index/friend.png')" mode="widthFix" show-menu-by-longpress></image>
</view> </view>
<view class="info"> <view class="info">
<view class="title">{{ $lang('fenxiao.myInviteCode') }}</view> <view class="title">我的邀请码</view>
<view class="desc">{{ $lang('fenxiao.inviteFriendsEarn') }}</view> <view class="desc">邀好友赚好礼</view>
</view> </view>
</view> </view>
<!-- <view class="menu-item" @click="$util.redirectTo('/pages_promotion/fenxiao/promote')"> <!-- <view class="menu-item" @click="$util.redirectTo('/pages_promotion/fenxiao/promote')">
@@ -130,8 +130,8 @@
<image :src="$util.img('public/uniapp/fenxiao/index/code.png')" mode="widthFix" show-menu-by-longpress></image> <image :src="$util.img('public/uniapp/fenxiao/index/code.png')" mode="widthFix" show-menu-by-longpress></image>
</view> </view>
<view class="info"> <view class="info">
<view class="title">{{ $lang('fenxiao.inviteFriends') }}</view> <view class="title">邀请好友</view>
<view class="desc">{{ $lang('fenxiao.inviteFriendsGift') }}</view> <view class="desc">邀好友赚好礼</view>
</view> </view>
</view> --> </view> -->
<!-- <view class="menu-item" @click="$util.redirectTo('/pages_promotion/fenxiao/bill')"> <!-- <view class="menu-item" @click="$util.redirectTo('/pages_promotion/fenxiao/bill')">
@@ -139,8 +139,8 @@
<image :src="$util.img('public/uniapp/fenxiao/index/bill.png')" mode="widthFix" show-menu-by-longpress></image> <image :src="$util.img('public/uniapp/fenxiao/index/bill.png')" mode="widthFix" show-menu-by-longpress></image>
</view> </view>
<view class="info"> <view class="info">
<view class="title">{{ $lang('fenxiao.billReport') }}</view> <view class="title">账单报表</view>
<view class="desc">{{ $lang('fenxiao.accountChange') }}</view> <view class="desc">{{ fenxiaoWords.account }}变更明细</view>
</view> </view>
</view> </view>
<view class="menu-item" @click="$util.redirectTo('/pages_promotion/fenxiao/goods_list', { templateId: templateId })"> <view class="menu-item" @click="$util.redirectTo('/pages_promotion/fenxiao/goods_list', { templateId: templateId })">
@@ -148,8 +148,8 @@
<image :src="$util.img('public/uniapp/fenxiao/index/market.png')" mode="widthFix" show-menu-by-longpress></image> <image :src="$util.img('public/uniapp/fenxiao/index/market.png')" mode="widthFix" show-menu-by-longpress></image>
</view> </view>
<view class="info"> <view class="info">
<view class="title">{{ fenxiaoWords.concept }}{{ $lang('fenxiao.goods') }}</view> <view class="title">{{ fenxiaoWords.concept }}商品</view>
<view class="desc">{{ fenxiaoWords.concept }}{{ $lang('fenxiao.goods') }}</view> <view class="desc">{{ fenxiaoWords.concept }}商品</view>
</view> </view>
</view> --> </view> -->
<!-- <view class="menu-item" @click="$util.redirectTo('/pages_promotion/fenxiao/ranking_list', { type: 'profit' })"> <!-- <view class="menu-item" @click="$util.redirectTo('/pages_promotion/fenxiao/ranking_list', { type: 'profit' })">
@@ -158,8 +158,8 @@
</image> </image>
</view> </view>
<view class="info"> <view class="info">
<view class="title">{{ fenxiaoWords.account }}{{ $lang('fenxiao.ranking') }}</view> <view class="title">{{ fenxiaoWords.account }}排行</view>
<view class="desc">{{ $lang('fenxiao.yourRank', { rank: profitRanking }) }}</view> <view class="desc">您的排名为第{{ profitRanking }}位</view>
</view> </view>
</view> --> </view> -->
<!-- <view class="menu-item" @click="$util.redirectTo('/pages_promotion/fenxiao/ranking_list', { type: 'invited_num' })"> <!-- <view class="menu-item" @click="$util.redirectTo('/pages_promotion/fenxiao/ranking_list', { type: 'invited_num' })">
@@ -168,8 +168,8 @@
</image> </image>
</view> </view>
<view class="info"> <view class="info">
<view class="title">{{ $lang('fenxiao.promoteRankTitle') }}</view> <view class="title">推广人排行</view>
<view class="desc">{{ $lang('fenxiao.yourRank', { rank: invitedNumRanking }) }}</view> <view class="desc">您的排名为{{ invitedNumRanking }}位</view>
</view> </view>
</view> --> </view> -->
<!-- <view class="menu-item" @click="$util.redirectTo('/pages_promotion/fenxiao/level')" v-if="levelList.length"> <!-- <view class="menu-item" @click="$util.redirectTo('/pages_promotion/fenxiao/level')" v-if="levelList.length">
@@ -177,8 +177,8 @@
<image :src="$util.img('public/uniapp/fenxiao/index/team_reward.png')" mode="widthFix" show-menu-by-longpress></image> <image :src="$util.img('public/uniapp/fenxiao/index/team_reward.png')" mode="widthFix" show-menu-by-longpress></image>
</view> </view>
<view class="info"> <view class="info">
<view class="title">{{ $lang('fenxiao.levelDesc') }}</view> <view class="title">等级说明</view>
<view class="desc">{{ fenxiaoWords.concept }}{{ $lang('fenxiao.levelDesc') }}</view> <view class="desc">{{ fenxiaoWords.concept }}等级说明</view>
</view> </view>
</view> --> </view> -->
</view> </view>
@@ -190,8 +190,8 @@
<image :src="$util.img('public/uniapp/fenxiao/index/down-line.png')" mode="aspectFill" show-menu-by-longpress></image> <image :src="$util.img('public/uniapp/fenxiao/index/down-line.png')" mode="aspectFill" show-menu-by-longpress></image>
</view> </view>
<view class="all-money-tit-wrap"> <view class="all-money-tit-wrap">
<text class="all-money-tit">{{ $lang('fenxiao.myFans') }}</text> <text class="all-money-tit">我的粉丝</text>
<text class="all-money-num">{{ teamNum.num }}{{ $lang('fenxiao.people') }}</text> <text class="all-money-num">{{ teamNum.num }}人</text>
</view> </view>
</view> </view>
</view> </view>
@@ -202,7 +202,7 @@
</view> </view>
<view class="all-money-tit-wrap"> <view class="all-money-tit-wrap">
<text class="all-money-tit">{{ fenxiaoWords.fenxiao_name }}</text> <text class="all-money-tit">{{ fenxiaoWords.fenxiao_name }}</text>
<text class="all-money-num">{{ teamNum.fenxiao_num }}{{ $lang('fenxiao.people') }}</text> <text class="all-money-num">{{ teamNum.fenxiao_num }}人</text>
</view> </view>
</view> </view>
</view> </view>
@@ -211,8 +211,8 @@
<ns-copyright></ns-copyright> <ns-copyright></ns-copyright>
<view class="empty" v-if="!info.fenxiao_id > 0 && showEmpty"> <view class="empty" v-if="!info.fenxiao_id > 0 && showEmpty">
<image :src="$util.img('public/uniapp/fenxiao/index/no-fenxiao.png')" mode="widthFix" show-menu-by-longpress></image> <image :src="$util.img('public/uniapp/fenxiao/index/no-fenxiao.png')" mode="widthFix" show-menu-by-longpress></image>
<text>{{ $lang('fenxiao.notFenxiao', { fenxiao_name: fenxiaoWords.fenxiao_name }) }},{{ $lang('fenxiao.applyNow') }}</text> <text>您还不是{{ fenxiaoWords.fenxiao_name }},请先提交申请</text>
<view @click="$util.redirectTo('/pages_promotion/fenxiao/apply')" class="color-base-bg">{{ $lang('fenxiao.joinNow') }}</view> <view @click="$util.redirectTo('/pages_promotion/fenxiao/apply')" class="color-base-bg">立即加入</view>
</view> </view>
<loading-cover ref="loadingCover"></loading-cover> <loading-cover ref="loadingCover"></loading-cover>
<ns-login ref="login"></ns-login> <ns-login ref="login"></ns-login>
@@ -220,7 +220,7 @@
<uni-popup ref="taskPopup" type="bottom"> <uni-popup ref="taskPopup" type="bottom">
<view class="task-popup popup-layer" v-if="levelInfo"> <view class="task-popup popup-layer" v-if="levelInfo">
<view class="head-wrap"> <view class="head-wrap">
<text>{{ $lang('fenxiao.quickUpgradeTip') }}</text> <text>快速升级技巧</text>
<text class="iconfont icon-close" @click="$refs.taskPopup.close()"></text> <text class="iconfont icon-close" @click="$refs.taskPopup.close()"></text>
</view> </view>
<view class="body-wrap"> <view class="body-wrap">
@@ -228,7 +228,7 @@
<text class="subordinate-consumption"> <text class="subordinate-consumption">
{{ item.title }} {{ item.title }}
<text class="iconfont icon-wenhao" @click="openTips(item)"></text> <text class="iconfont icon-wenhao" @click="openTips(item)"></text>
<text class="incomplete">{{ item.progress == 100 ? $lang('fenxiao.completed') : $lang('fenxiao.incomplete') }}</text> <text class="incomplete">{{ item.progress == 100 ? '已完成' : '未完成' }}</text>
</text> </text>
<view class="circle"> <view class="circle">
<progress :percent="item.progress" activeColor="#E7B667" stroke-width="4" /> <progress :percent="item.progress" activeColor="#E7B667" stroke-width="4" />
@@ -236,7 +236,7 @@
<text class="zero">{{ item.value }}</text> <text class="zero">{{ item.value }}</text>
<text>/{{ item.condition }}</text> <text>/{{ item.condition }}</text>
<text class="to-complete-box" @click="$util.redirectTo('/pages_promotion/fenxiao/promote')"> <text class="to-complete-box" @click="$util.redirectTo('/pages_promotion/fenxiao/promote')">
<text class="to-complete">{{ item.progress == 100 ? $lang('fenxiao.completed') : $lang('fenxiao.toComplete') }}</text> <text class="to-complete">{{ item.progress == 100 ? '已完成' : '去完成' }}</text>
</text> </text>
</view> </view>
</view> </view>
@@ -246,12 +246,12 @@
<uni-popup type="bottom" ref="tips"> <uni-popup type="bottom" ref="tips">
<view class="popup"> <view class="popup">
<view class="popup-header"> <view class="popup-header">
<text class="tit">{{ $lang('fenxiao.hint') }}</text> <text class="tit">提示</text>
<text class="iconfont icon-close" @click="$refs.tips.close()"></text> <text class="iconfont icon-close" @click="$refs.tips.close()"></text>
</view> </view>
<view class="popup-body"> <view class="popup-body">
<view>{{ tips }}</view> <view>{{ tips }}</view>
<view v-if="levelInfo">{{ levelInfo.upgrade_type == 1 ? $lang('fenxiao.upgradeConditionAny') : $lang('fenxiao.upgradeConditionAll') }}</view> <view v-if="levelInfo">{{ levelInfo.upgrade_type == 1 ? '满足任意一条件即可升级' : '满足全部条件才能进行升级' }}</view>
</view> </view>
</view> </view>
</uni-popup> </uni-popup>
@@ -290,7 +290,7 @@ export default {
}, },
mixins: [fenxiaoWords], mixins: [fenxiaoWords],
onShow() { onShow() {
if (this.fenxiaoWords && this.fenxiaoWords.concept) this.$langConfig.title(this.fenxiaoWords.concept + this.$lang('fenxiao.center')); if (this.fenxiaoWords && this.fenxiaoWords.concept) this.$langConfig.title(this.fenxiaoWords.concept + '中心');
if (this.storeToken) { if (this.storeToken) {
this.checkFenxiaoIsStart(); this.checkFenxiaoIsStart();
@@ -307,7 +307,7 @@ export default {
setTimeout(() => { setTimeout(() => {
if (!this.addonIsExist.fenxiao) { if (!this.addonIsExist.fenxiao) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.merchantNotOpenFenxiao'), title: '商家未开启分销',
mask: true, mask: true,
duration: 2000 duration: 2000
}); });
@@ -348,7 +348,7 @@ export default {
this.getFenxiaoDetail(); this.getFenxiaoDetail();
} else { } else {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.merchantNotOpenFenxiao'), title: '商家未开启分销',
mask: true, mask: true,
duration: 2000 duration: 2000
}); });
@@ -368,7 +368,7 @@ export default {
if (res.data) { if (res.data) {
if (res.data.status == -1) { if (res.data.status == -1) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.fenxiaoFrozen') title: '当前分销商已冻结'
}); });
setTimeout(() => { setTimeout(() => {
this.$util.redirectTo(this.$util.MEMBER_PAGE_URL); this.$util.redirectTo(this.$util.MEMBER_PAGE_URL);
@@ -480,9 +480,9 @@ export default {
if (level.one_fenxiao_order_num > 0) { if (level.one_fenxiao_order_num > 0) {
let task = { let task = {
title: this.$lang('fenxiao.subordinateConsume'), title: '下级消费',
desc: this.$lang('fenxiao.subordinateConsumeCount') + level.one_fenxiao_order_num + this.$lang('fenxiao.orders'), desc: '下级消费单数满' + level.one_fenxiao_order_num + '单',
tips: this.$lang('fenxiao.subordinateConsumeCountTip'), tips: '分销商自己购买和自己推荐的直属会员购买的订单次数',
condition: level.one_fenxiao_order_num, condition: level.one_fenxiao_order_num,
value: this.info.one_fenxiao_order_num, value: this.info.one_fenxiao_order_num,
progress: parseFloat(this.info.one_fenxiao_order_num) > parseFloat(level.one_fenxiao_order_num) ? progress: parseFloat(this.info.one_fenxiao_order_num) > parseFloat(level.one_fenxiao_order_num) ?
@@ -494,9 +494,9 @@ export default {
} }
if (level.one_fenxiao_total_order > 0) { if (level.one_fenxiao_total_order > 0) {
let task = { let task = {
title: this.$lang('fenxiao.subordinateConsume'), title: '下级消费',
desc: this.$lang('fenxiao.subordinateConsumeMoney') + this.moneyFormat(level.one_fenxiao_total_order) + this.$lang('fenxiao.yuan'), desc: '下级消费金额满' + this.moneyFormat(level.one_fenxiao_total_order) + '元',
tips: this.$lang('fenxiao.subordinateConsumeMoneyTip'), tips: '分销商自己购买和推荐的直属会员购买的订单的总额',
condition: this.moneyFormat(level.one_fenxiao_total_order), condition: this.moneyFormat(level.one_fenxiao_total_order),
value: this.info.one_fenxiao_total_order, value: this.info.one_fenxiao_total_order,
progress: parseFloat(this.info.one_fenxiao_total_order) > parseFloat(level.one_fenxiao_total_order) ? progress: parseFloat(this.info.one_fenxiao_total_order) > parseFloat(level.one_fenxiao_total_order) ?
@@ -508,10 +508,10 @@ export default {
} }
if (level.one_fenxiao_order_money > 0) { if (level.one_fenxiao_order_money > 0) {
let task = { let task = {
title: this.$lang('fenxiao.subordinateConsume'), title: '下级消费',
desc: this.$lang('fenxiao.subordinateConsumeCommission', { account: this.fenxiaoWords.account }) + this.moneyFormat(level desc: '下级消费产生' + this.fenxiaoWords.account + '总额满' + this.moneyFormat(level
.one_fenxiao_order_money) + this.$lang('fenxiao.yuan'), .one_fenxiao_order_money) + '元',
tips: this.$lang('fenxiao.subordinateConsumeCommissionTip', { account: this.fenxiaoWords.account }), tips: '分销商自己购买和自己推荐的直属会员购买的订单' + this.fenxiaoWords.account + '总额',
condition: this.moneyFormat(level.one_fenxiao_order_money), condition: this.moneyFormat(level.one_fenxiao_order_money),
value: this.info.one_fenxiao_order_money, value: this.info.one_fenxiao_order_money,
progress: parseFloat(this.info.one_fenxiao_order_money) > parseFloat(level.one_fenxiao_order_money) ? progress: parseFloat(this.info.one_fenxiao_order_money) > parseFloat(level.one_fenxiao_order_money) ?
@@ -523,9 +523,9 @@ export default {
} }
if (level.order_num > 0) { if (level.order_num > 0) {
let task = { let task = {
title: this.$lang('fenxiao.selfConsume'), title: '自身消费',
desc: this.$lang('fenxiao.selfConsumeCount') + level.order_num + this.$lang('fenxiao.orders'), desc: '自身消费单数满' + level.order_num + '单',
tips: this.$lang('fenxiao.selfConsumeCountTip'), tips: '分销商自己购买的订单次数',
condition: level.order_num, condition: level.order_num,
value: this.info.order_num, value: this.info.order_num,
progress: parseFloat(this.info.order_num) > parseFloat(level.order_num) ? 100 : ((parseFloat(this.info.order_num) / parseFloat(level.order_num)) * 100).toFixed(2) progress: parseFloat(this.info.order_num) > parseFloat(level.order_num) ? 100 : ((parseFloat(this.info.order_num) / parseFloat(level.order_num)) * 100).toFixed(2)
@@ -535,9 +535,9 @@ export default {
} }
if (level.order_money > 0) { if (level.order_money > 0) {
let task = { let task = {
title: this.$lang('fenxiao.selfConsume'), title: '自身消费',
desc: this.$lang('fenxiao.selfConsumeMoney') + this.moneyFormat(level.order_money) + this.$lang('fenxiao.yuan'), desc: '自身消费金额满' + this.moneyFormat(level.order_money) + '元',
tips: this.$lang('fenxiao.selfConsumeMoneyTip'), tips: '分销商自己购买的订单总额',
condition: this.moneyFormat(level.order_money), condition: this.moneyFormat(level.order_money),
value: this.info.order_money, value: this.info.order_money,
progress: parseFloat(this.info.order_money) > parseFloat(level.order_money) ? progress: parseFloat(this.info.order_money) > parseFloat(level.order_money) ?
@@ -549,9 +549,9 @@ export default {
} }
if (level.one_child_num > 0) { if (level.one_child_num > 0) {
let task = { let task = {
title: this.$lang('fenxiao.inviteFriend'), title: '邀请好友',
desc: this.$lang('fenxiao.inviteFriendCount') + level.one_child_num + this.$lang('fenxiao.people'), desc: '邀请好友人数达到' + level.one_child_num + '人',
tips: this.$lang('fenxiao.inviteFriendTip'), tips: '分销商的直属下级会员人数(包含已经申请成为分销商的)',
condition: level.one_child_num, condition: level.one_child_num,
value: this.info.one_child_num, value: this.info.one_child_num,
progress: parseFloat(this.info.one_child_num) > parseFloat(level.one_child_num) ? progress: parseFloat(this.info.one_child_num) > parseFloat(level.one_child_num) ?
@@ -563,9 +563,9 @@ export default {
} }
if (level.one_child_fenxiao_num > 0) { if (level.one_child_fenxiao_num > 0) {
let task = { let task = {
title: this.$lang('fenxiao.inviteFriend'), title: '邀请好友',
desc: this.$lang('fenxiao.inviteFenxiaoCount') + level.one_child_fenxiao_num + this.$lang('fenxiao.people'), desc: '邀请好友成为分销商人数达到' + level.one_child_fenxiao_num + '人',
tips: this.$lang('fenxiao.inviteFenxiaoTip'), tips: '分销商的直属下级分销商人数',
condition: level.one_child_fenxiao_num, condition: level.one_child_fenxiao_num,
value: this.info.one_child_fenxiao_num, value: this.info.one_child_fenxiao_num,
progress: parseFloat(this.info.one_child_fenxiao_num) > parseFloat(level.one_child_fenxiao_num) ? progress: parseFloat(this.info.one_child_fenxiao_num) > parseFloat(level.one_child_fenxiao_num) ?

View File

@@ -1,4 +1,4 @@
<template> <template>
<view class="container" :style="themeColor"> <view class="container" :style="themeColor">
<view class="level-top"> <view class="level-top">
<image :src="$util.img('public/uniapp/level/level-top-bg.png')"></image> <image :src="$util.img('public/uniapp/level/level-top-bg.png')"></image>
@@ -17,15 +17,15 @@
</view> </view>
<view class="level-rate"> <view class="level-rate">
<view class="rate-item" v-if="config.level > 0"> <view class="rate-item" v-if="config.level > 0">
<view class="title">{{ $lang('fenxiao.firstCommissionRate') }}</view> <view class="title">一级分佣比率</view>
<view class="rate">{{ item.one_rate }}<text class="percentage">%</text></view> <view class="rate">{{ item.one_rate }}<text class="percentage">%</text></view>
</view> </view>
<view class="rate-item" v-if="config.level > 1"> <view class="rate-item" v-if="config.level > 1">
<view class="title">{{ $lang('fenxiao.secondCommissionRate') }}</view> <view class="title">二级分佣比率</view>
<view class="rate">{{ item.two_rate }}<text class="percentage">%</text></view> <view class="rate">{{ item.two_rate }}<text class="percentage">%</text></view>
</view> </view>
<view class="rate-item" v-if="config.level > 2"> <view class="rate-item" v-if="config.level > 2">
<view class="title">{{ $lang('fenxiao.thirdCommissionRate') }}</view> <view class="title">三级分佣比率</view>
<view class="rate">{{ item.three_rate }}<text class="percentage">%</text></view> <view class="rate">{{ item.three_rate }}<text class="percentage">%</text></view>
</view> </view>
</view> </view>
@@ -40,7 +40,7 @@
<view class="level-condition" v-if="levelInfo"> <view class="level-condition" v-if="levelInfo">
<view class="condition-title"> <view class="condition-title">
<view class="title">{{ $lang('fenxiao.quickUpgradeTip') }}</view> <view class="title">快速升级技巧</view>
<view class="rate price-font"> <view class="rate price-font">
<text class="complete">{{ levelInfo.complete > levelInfo.task_num ? levelInfo.task_num : levelInfo.complete }}</text> <text class="complete">{{ levelInfo.complete > levelInfo.task_num ? levelInfo.task_num : levelInfo.complete }}</text>
<text class="num">/{{ levelInfo.task_num }}</text> <text class="num">/{{ levelInfo.task_num }}</text>
@@ -54,7 +54,7 @@
<text class="iconfont icon-wenxiao" @click="openTips(item)"></text> <text class="iconfont icon-wenxiao" @click="openTips(item)"></text>
</view> </view>
<view class="status" :class="{'complete': item.progress == 100}"> <view class="status" :class="{'complete': item.progress == 100}">
{{ item.progress == 100 ? $lang('fenxiao.completed') : $lang('fenxiao.incomplete') }}</view> {{ item.progress == 100 ? '已完成' : '未完成' }}</view>
</view> </view>
<view class="progress"> <view class="progress">
<progress :percent="item.progress" activeColor="#E7B667" stroke-width="4" /> <progress :percent="item.progress" activeColor="#E7B667" stroke-width="4" />
@@ -73,12 +73,12 @@
<uni-popup type="bottom" ref="tips"> <uni-popup type="bottom" ref="tips">
<view class="popup"> <view class="popup">
<view class="popup-header"> <view class="popup-header">
<text class="tit">{{ $lang('fenxiao.hint') }}</text> <text class="tit">提示</text>
<text class="iconfont icon-close" @click="$refs.tips.close()"></text> <text class="iconfont icon-close" @click="$refs.tips.close()"></text>
</view> </view>
<view class="popup-body"> <view class="popup-body">
<view>{{ tips }}</view> <view>{{ tips }}</view>
<view v-if="levelInfo">{{ levelInfo.upgrade_type == 1 ? $lang('fenxiao.upgradeConditionAny') : $lang('fenxiao.upgradeConditionAll') }}</view> <view v-if="levelInfo">{{ levelInfo.upgrade_type == 1 ? '满足任意一条件即可升级' : '满足全部条件才能进行升级' }}</view>
</view> </view>
</view> </view>
</uni-popup> </uni-popup>
@@ -114,9 +114,9 @@
if (level.one_fenxiao_order_num > 0) { if (level.one_fenxiao_order_num > 0) {
let task = { let task = {
title: this.$lang('fenxiao.subordinateConsume'), title: '下级消费',
desc: this.$lang('fenxiao.subordinateConsumeOrderNum', { num: level.one_fenxiao_order_num }), desc: '下级消费单数满' + level.one_fenxiao_order_num + '单',
tips: this.$lang('fenxiao.subordinateConsumeOrderNumTip', { num: level.one_fenxiao_order_num }), tips: '分销商自己购买和自己推荐的直属会员购买的订单次数达到'+ level.one_fenxiao_order_num + '单',
condition: level.one_fenxiao_order_num, condition: level.one_fenxiao_order_num,
value: this.fenxiaoInfo.one_fenxiao_order_num, value: this.fenxiaoInfo.one_fenxiao_order_num,
progress: parseFloat(this.fenxiaoInfo.one_fenxiao_order_num) > parseFloat(level.one_fenxiao_order_num) ? 100 : (parseFloat(this.fenxiaoInfo.one_fenxiao_order_num) / parseFloat(level.one_fenxiao_order_num) * 100).toFixed(2) progress: parseFloat(this.fenxiaoInfo.one_fenxiao_order_num) > parseFloat(level.one_fenxiao_order_num) ? 100 : (parseFloat(this.fenxiaoInfo.one_fenxiao_order_num) / parseFloat(level.one_fenxiao_order_num) * 100).toFixed(2)
@@ -126,9 +126,9 @@
} }
if (level.one_fenxiao_total_order > 0) { if (level.one_fenxiao_total_order > 0) {
let task = { let task = {
title: this.$lang('fenxiao.subordinateConsume'), title: '下级消费',
desc: this.$lang('fenxiao.subordinateConsumeAmount', { amount: this.moneyFormat(level.one_fenxiao_total_order) }), desc: '下级消费金额满' + this.moneyFormat(level.one_fenxiao_total_order) + '元',
tips: this.$lang('fenxiao.subordinateConsumeAmountTip', { amount: this.moneyFormat(level.one_fenxiao_total_order) }), tips: '分销商自己购买和推荐的直属会员购买的订单的总额达到'+ this.moneyFormat(level.one_fenxiao_total_order) + '元',
condition: this.moneyFormat(level.one_fenxiao_total_order), condition: this.moneyFormat(level.one_fenxiao_total_order),
value: this.fenxiaoInfo.one_fenxiao_total_order, value: this.fenxiaoInfo.one_fenxiao_total_order,
progress: parseFloat(this.fenxiaoInfo.one_fenxiao_total_order) > parseFloat(level.one_fenxiao_total_order) ? 100 : (parseFloat(this.fenxiaoInfo.one_fenxiao_total_order) / parseFloat(level.one_fenxiao_total_order) * 100) progress: parseFloat(this.fenxiaoInfo.one_fenxiao_total_order) > parseFloat(level.one_fenxiao_total_order) ? 100 : (parseFloat(this.fenxiaoInfo.one_fenxiao_total_order) / parseFloat(level.one_fenxiao_total_order) * 100)
@@ -139,9 +139,9 @@
} }
if (level.one_fenxiao_order_money > 0) { if (level.one_fenxiao_order_money > 0) {
let task = { let task = {
title: this.$lang('fenxiao.subordinateConsume'), title: '下级消费',
desc: this.$lang('fenxiao.subordinateConsumeCommission', { amount: this.moneyFormat(level.one_fenxiao_order_money) }), desc: '下级消费产生佣金总额满' + this.moneyFormat(level.one_fenxiao_order_money) + '元',
tips: this.$lang('fenxiao.subordinateConsumeCommissionTip', { amount: this.moneyFormat(level.one_fenxiao_order_money) }), tips: '分销商自己购买和自己推荐的直属会员购买的订单佣金总额达到'+ this.moneyFormat(level.one_fenxiao_order_money) + '元',
condition: this.moneyFormat(level.one_fenxiao_order_money), condition: this.moneyFormat(level.one_fenxiao_order_money),
value: this.fenxiaoInfo.one_fenxiao_order_money, value: this.fenxiaoInfo.one_fenxiao_order_money,
progress: parseFloat(this.fenxiaoInfo.one_fenxiao_order_money) > parseFloat(level.one_fenxiao_order_money) ? 100 : (parseFloat(this.fenxiaoInfo.one_fenxiao_order_money) / parseFloat(level.one_fenxiao_order_money) * 100) progress: parseFloat(this.fenxiaoInfo.one_fenxiao_order_money) > parseFloat(level.one_fenxiao_order_money) ? 100 : (parseFloat(this.fenxiaoInfo.one_fenxiao_order_money) / parseFloat(level.one_fenxiao_order_money) * 100)
@@ -152,9 +152,9 @@
} }
if (level.order_num > 0) { if (level.order_num > 0) {
let task = { let task = {
title: this.$lang('fenxiao.selfConsume'), title: '自身消费',
desc: this.$lang('fenxiao.selfConsumeOrderNum', { num: level.order_num }), desc: '自身消费单数满' + level.order_num + '单',
tips: this.$lang('fenxiao.selfConsumeOrderNumTip', { num: level.order_num }), tips: '分销商自己购买的订单次数达到'+ level.order_num + '单',
condition: level.order_num, condition: level.order_num,
value: this.fenxiaoInfo.order_num, value: this.fenxiaoInfo.order_num,
progress: parseFloat(this.fenxiaoInfo.order_num) > parseFloat(level.order_num) ? 100 : (parseFloat(this.fenxiaoInfo.order_num) / parseFloat(level.order_num) * 100).toFixed(2) progress: parseFloat(this.fenxiaoInfo.order_num) > parseFloat(level.order_num) ? 100 : (parseFloat(this.fenxiaoInfo.order_num) / parseFloat(level.order_num) * 100).toFixed(2)
@@ -164,9 +164,9 @@
} }
if (level.order_money > 0) { if (level.order_money > 0) {
let task = { let task = {
title: this.$lang('fenxiao.selfConsume'), title: '自身消费',
desc: this.$lang('fenxiao.selfConsumeAmount', { amount: this.moneyFormat(level.order_money) }), desc: '自身消费金额满' + this.moneyFormat(level.order_money) + '元',
tips: this.$lang('fenxiao.selfConsumeAmountTip', { amount: this.moneyFormat(level.order_money) }), tips: '分销商自己购买的订单总额满足'+ this.moneyFormat(level.order_money) + '元',
condition: this.moneyFormat(level.order_money), condition: this.moneyFormat(level.order_money),
value: this.fenxiaoInfo.order_money, value: this.fenxiaoInfo.order_money,
progress: parseFloat(this.fenxiaoInfo.order_money) > parseFloat(level.order_money) ? 100 : (parseFloat(this.fenxiaoInfo.order_money) / parseFloat(level.order_money) * 100).toFixed(2) progress: parseFloat(this.fenxiaoInfo.order_money) > parseFloat(level.order_money) ? 100 : (parseFloat(this.fenxiaoInfo.order_money) / parseFloat(level.order_money) * 100).toFixed(2)
@@ -176,9 +176,9 @@
} }
if (level.one_child_num > 0) { if (level.one_child_num > 0) {
let task = { let task = {
title: this.$lang('fenxiao.inviteFriend'), title: '邀请好友',
desc: this.$lang('fenxiao.inviteFriendCount', { num: level.one_child_num }), desc: '邀请好友人数达到' + level.one_child_num + '人',
tips: this.$lang('fenxiao.inviteFriendCountTip', { num: level.one_child_num }), tips: '分销商的直属下级会员人数达到'+level.one_child_num+'人(包含已经申请成为分销商的)',
condition: level.one_child_num, condition: level.one_child_num,
value: this.fenxiaoInfo.one_child_num, value: this.fenxiaoInfo.one_child_num,
progress: parseFloat(this.fenxiaoInfo.one_child_num) > parseFloat(level.one_child_num) ? 100 : (parseFloat(this.fenxiaoInfo.one_child_num) / parseFloat(level.one_child_num) * 100).toFixed(2) progress: parseFloat(this.fenxiaoInfo.one_child_num) > parseFloat(level.one_child_num) ? 100 : (parseFloat(this.fenxiaoInfo.one_child_num) / parseFloat(level.one_child_num) * 100).toFixed(2)
@@ -188,9 +188,9 @@
} }
if (level.one_child_fenxiao_num > 0) { if (level.one_child_fenxiao_num > 0) {
let task = { let task = {
title: this.$lang('fenxiao.inviteFriend'), title: '邀请好友',
desc: this.$lang('fenxiao.inviteFenxiaoCount', { num: level.one_child_fenxiao_num }), desc: '邀请好友成为分销商人数达到' + level.one_child_fenxiao_num + '人',
tips: this.$lang('fenxiao.inviteFenxiaoCountTip', { num: level.one_child_fenxiao_num }), tips: '分销商的直属下级分销商人数达到'+ level.one_child_fenxiao_num + '人',
condition: level.one_child_fenxiao_num, condition: level.one_child_fenxiao_num,
value: this.fenxiaoInfo.one_child_fenxiao_num, value: this.fenxiaoInfo.one_child_fenxiao_num,
progress: parseFloat(this.fenxiaoInfo.one_child_fenxiao_num) > parseFloat(level.one_child_fenxiao_num) ? 100 : (parseFloat(this.fenxiaoInfo.one_child_fenxiao_num) / parseFloat(level.one_child_fenxiao_num) * 100).toFixed(2) progress: parseFloat(this.fenxiaoInfo.one_child_fenxiao_num) > parseFloat(level.one_child_fenxiao_num) ? 100 : (parseFloat(this.fenxiaoInfo.one_child_fenxiao_num) / parseFloat(level.one_child_fenxiao_num) * 100).toFixed(2)
@@ -208,7 +208,7 @@
setTimeout( () => { setTimeout( () => {
if (!this.addonIsExist.fenxiao) { if (!this.addonIsExist.fenxiao) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.merchantNotOpenFenxiao'), title: '商家未开启分销',
mask: true, mask: true,
duration: 2000 duration: 2000
}); });
@@ -218,7 +218,7 @@
} }
},1000); },1000);
if (this.fenxiaoWords && this.fenxiaoWords.fenxiao_name) this.$langConfig.title(this.fenxiaoWords.fenxiao_name + this.$lang('fenxiao.level')); if (this.fenxiaoWords && this.fenxiaoWords.fenxiao_name) this.$langConfig.title(this.fenxiaoWords.fenxiao_name + '等级');
if (this.storeToken) { if (this.storeToken) {
this.getFenxiaoInfo(); this.getFenxiaoInfo();
@@ -231,7 +231,7 @@
}, },
methods: { methods: {
/** /**
* 获取分销{{ $lang('fenxiao.level') }}信息 * 获取分销等级信息
*/ */
getFenxiaoLevel() { getFenxiaoLevel() {
this.$api.sendRequest({ this.$api.sendRequest({

View File

@@ -14,10 +14,10 @@
@click="toDetail(orderItem.fenxiao_order_id)"> @click="toDetail(orderItem.fenxiao_order_id)">
<view class="order-header"> <view class="order-header">
<text class="site-name font-size-base">{{ orderItem.order_no }}</text> <text class="site-name font-size-base">{{ orderItem.order_no }}</text>
<text class="status-name color-base-text" v-if="orderItem.is_refund == 1">{{ $lang('fenxiao.refunded') }}</text> <text class="status-name color-base-text" v-if="orderItem.is_refund == 1">已退款</text>
<text class="status-name color-text-green" <text class="status-name color-text-green"
v-else-if="orderItem.is_settlement == 1">{{ $lang('fenxiao.settled') }}</text> v-else-if="orderItem.is_settlement == 1">已结算</text>
<text class="status-name color-text-orange" v-else>{{ $lang('fenxiao.pendingSettlement') }}</text> <text class="status-name color-text-orange" v-else>待结算</text>
</view> </view>
<view class="order-body"> <view class="order-body">
@@ -30,7 +30,7 @@
<view class="top-wrap"> <view class="top-wrap">
<view class="goods-name font-size-base">{{ orderItem.sku_name }}</view> <view class="goods-name font-size-base">{{ orderItem.sku_name }}</view>
<view> <view>
<text class="color-tip">{{ $lang('fenxiao.commission') }}</text> <text class="color-tip">返{{ fenxiaoWords.account }}</text>
<text class="price-color price-style small">{{ <text class="price-color price-style small">{{
$lang('common.currencySymbol') }}</text> $lang('common.currencySymbol') }}</text>
<text class="price-color price-style large">{{ <text class="price-color price-style large">{{
@@ -66,7 +66,7 @@
<text class="color-base-text">{{ $lang('common.currencySymbol') }}{{ orderItem.commission }}</text> --> <text class="color-base-text">{{ $lang('common.currencySymbol') }}{{ orderItem.commission }}</text> -->
</view> </view>
<view class="total"> <view class="total">
<text>{{ $lang('fenxiao.total') }}:</text> <text>合计:</text>
<text class="price-color">{{ $lang('common.currencySymbol') }}</text> <text class="price-color">{{ $lang('common.currencySymbol') }}</text>
<text class="price-color font-size-toolbar">{{ <text class="price-color font-size-toolbar">{{
parseFloat(orderItem.real_goods_money).toFixed(2).split(".")[0] }}</text> parseFloat(orderItem.real_goods_money).toFixed(2).split(".")[0] }}</text>
@@ -78,13 +78,13 @@
</view> </view>
</view> </view>
<view class="cart-empty"> <view class="cart-empty">
<ns-empty :text="$lang('fenxiao.emptyOrder')" :isIndex="false" <ns-empty text="暂无订单" :isIndex="false"
v-if="selectId == 0 && orderList.length == 0 && emptyShow"></ns-empty> v-if="selectId == 0 && orderList.length == 0 && emptyShow"></ns-empty>
<ns-empty :text="$lang('fenxiao.emptyPendingSettleOrder')" :isIndex="false" <ns-empty text="暂无待结算订单" :isIndex="false"
v-if="selectId == 1 && orderList.length == 0 && emptyShow"></ns-empty> v-if="selectId == 1 && orderList.length == 0 && emptyShow"></ns-empty>
<ns-empty :text="$lang('fenxiao.emptySettledOrder')" :isIndex="false" <ns-empty text="暂无已结算订单" :isIndex="false"
v-if="selectId == 2 && orderList.length == 0 && emptyShow"></ns-empty> v-if="selectId == 2 && orderList.length == 0 && emptyShow"></ns-empty>
<ns-empty :text="$lang('fenxiao.emptyRefundedOrder')" :isIndex="false" <ns-empty text="暂无已退款订单" :isIndex="false"
v-if="selectId == 3 && orderList.length == 0 && emptyShow"></ns-empty> v-if="selectId == 3 && orderList.length == 0 && emptyShow"></ns-empty>
</view> </view>
</view> </view>
@@ -108,22 +108,22 @@ export default {
category: [ category: [
{ {
id: 0, id: 0,
name: this.$lang('fenxiao.all'), name: '全部',
number: 2 number: 2
}, },
{ {
id: 1, id: 1,
name: this.$lang('fenxiao.pendingSettlement'), name: '待结算',
number: 0 number: 0
}, },
{ {
id: 2, id: 2,
name: this.$lang('fenxiao.settled'), name: '已结算',
number: 0 number: 0
}, },
{ {
id: 3, id: 3,
name: this.$lang('fenxiao.refunded'), name: '已退款',
number: 0 number: 0
} }
], ],
@@ -142,7 +142,7 @@ export default {
setTimeout(() => { setTimeout(() => {
if (!this.addonIsExist.fenxiao) { if (!this.addonIsExist.fenxiao) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.merchantNotOpenFenxiao'), title: '商家未开启分销',
mask: true, mask: true,
duration: 2000 duration: 2000
}); });
@@ -152,7 +152,7 @@ export default {
} }
}, 1000); }, 1000);
if (this.fenxiaoWords && this.fenxiaoWords.concept) this.$langConfig.title(this.fenxiaoWords.concept + this.$lang('fenxiao.order')); if (this.fenxiaoWords && this.fenxiaoWords.concept) this.$langConfig.title(this.fenxiaoWords.concept + '订单');
if (!this.storeToken) { if (!this.storeToken) {
this.$nextTick(() => { this.$nextTick(() => {

View File

@@ -1,14 +1,14 @@
<template> <template>
<view :style="themeColor"> <view :style="themeColor">
<view class="order-detail"> <view class="order-detail">
<view class="order-detail-box"> <view class="order-detail-box">
<view class="header"> <view class="header">
<view class="title"> <view class="title">
<text>{{ $lang('fenxiao.totalItems', { num: orderData.num }) }}</text> <text>共{{ orderData.num }}件商品</text>
</view> </view>
<text class="color-base-text font-size-tag" v-if="orderData.is_refund == 1">{{ $lang('fenxiao.refunded') }}</text> <text class="color-base-text font-size-tag" v-if="orderData.is_refund == 1">已退款</text>
<text class="color-base-text font-size-tag" v-else-if="orderData.is_settlement == 1">{{ $lang('fenxiao.settled') }}</text> <text class="color-base-text font-size-tag" v-else-if="orderData.is_settlement == 1">已结算</text>
<text class="color-base-text font-size-tag" v-else>{{ $lang('fenxiao.pendingSettlement') }}</text> <text class="color-base-text font-size-tag" v-else>待结算</text>
</view> </view>
<view class="detail-body"> <view class="detail-body">
<view class="detail-body-box"> <view class="detail-body-box">
@@ -37,27 +37,27 @@
<view class="detail-footer"> <view class="detail-footer">
<text></text> <text></text>
<text> <text>
<text>{{ $lang('fenxiao.total') }}:</text> <text>合计:</text>
<text class="price-color total">¥{{ orderData.real_goods_money }}</text> <text class="price-color total">¥{{ orderData.real_goods_money }}</text>
</text> </text>
</view> </view>
</view> </view>
<view class="order-detail-box commission"> <view class="order-detail-box commission">
<view class="header"> <view class="header">
<view class="title color-base-bg-before"><text>{{ $lang('fenxiao.commissionDetail') }}</text></view> <view class="title color-base-bg-before"><text>返佣详情</text></view>
<text class="color-base-text">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</text> <text class="color-base-text">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</text>
</view> </view>
<view class="detail-content"> <view class="detail-content">
<view class="order-info-item"> <view class="order-info-item">
<text class="tit">{{ $lang('fenxiao.orderNo') }}:</text> <text class="tit">订单编号:</text>
<text>{{ orderData.order_no }}</text> <text>{{ orderData.order_no }}</text>
</view> </view>
<view class="order-info-item"> <view class="order-info-item">
<text class="tit">{{ $lang('fenxiao.commissionLevel') }}:</text> <text class="tit">分佣层级:</text>
<text>{{ orderData.commission_level }}$lang('fenxiao.level')</text> <text>{{ orderData.commission_level }}级</text>
</view> </view>
<view class="order-info-item"> <view class="order-info-item">
<text class="tit">{{ $lang('fenxiao.commissionAmountDetail') }}:</text> <text class="tit">返佣金额:</text>
<text class="price-color font-size-toolbar"> <text class="price-color font-size-toolbar">
<text class="font-size-goods-tag">¥</text> <text class="font-size-goods-tag">¥</text>
{{ parseFloat(orderData.commission).toFixed(2).split(".")[0] }} {{ parseFloat(orderData.commission).toFixed(2).split(".")[0] }}
@@ -100,7 +100,7 @@ export default {
setTimeout( () => { setTimeout( () => {
if (!this.addonIsExist.fenxiao) { if (!this.addonIsExist.fenxiao) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.merchantNotOpenFenxiao'), title: '商家未开启分销',
mask: true, mask: true,
duration: 2000 duration: 2000
}); });
@@ -133,7 +133,7 @@ export default {
this.orderData = res.data; this.orderData = res.data;
} else { } else {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.noOrderInfo') title: '未获取到订单信息!'
}); });
setTimeout(() => { setTimeout(() => {
this.$util.redirectTo('/pages_promotion/fenxiao/order', {}, 'redirectTo'); this.$util.redirectTo('/pages_promotion/fenxiao/order', {}, 'redirectTo');

View File

@@ -10,16 +10,16 @@
<image class="money-bg" :src="$util.img('public/uniapp/fenxiao/promote/money.png')" <image class="money-bg" :src="$util.img('public/uniapp/fenxiao/promote/money.png')"
mode="aspectFill"></image> mode="aspectFill"></image>
<view class="content"> <view class="content">
{{ $lang('fenxiao.totalEarnings') }} 累计收益
<text class="money-text">{{ detailData.total_commission }}</text> <text class="money-text">{{ detailData.total_commission }}</text>
{{ $lang('fenxiao.yuan') }} 元
</view> </view>
</view> </view>
</view> </view>
<view class="earnings-body"> <view class="earnings-body">
<view class="earnings-tab"> <view class="earnings-tab">
<text :class="{ active: tabIndex == 0 }" @click="tabCut(0)">{{ $lang('fenxiao.invitedFriends') }}</text> <text :class="{ active: tabIndex == 0 }" @click="tabCut(0)">已邀请好友</text>
<text :class="{ active: tabIndex == 1 }" @click="tabCut(1)">{{ $lang('fenxiao.orderedFriends') }}</text> <text :class="{ active: tabIndex == 1 }" @click="tabCut(1)">已下单好友</text>
</view> </view>
<scroll-view scroll-y="true" class="earnings-content-wrap" @scrolltolower="getTeam()"> <scroll-view scroll-y="true" class="earnings-content-wrap" @scrolltolower="getTeam()">
<view class="earnings-list" v-if="promote.list.length"> <view class="earnings-list" v-if="promote.list.length">
@@ -32,7 +32,7 @@
</view> </view>
</view> </view>
</view> </view>
<view class="earnings-empty" v-else>{{ $lang('fenxiao.emptyInvite') }}</view> <view class="earnings-empty" v-else>暂无已邀请好友,快去邀请吧</view>
</scroll-view> </scroll-view>
</view> </view>
</view> </view>
@@ -41,9 +41,9 @@
mode="aspectFit" show-menu-by-longpress></image> mode="aspectFit" show-menu-by-longpress></image>
<view class="content" v-if="promoteContent.content"><rich-text <view class="content" v-if="promoteContent.content"><rich-text
:nodes="promoteContent.content"></rich-text></view> :nodes="promoteContent.content"></rich-text></view>
<view class="rules-empty" v-else>{{ $lang('fenxiao.emptyActivityRules') }}</view> <view class="rules-empty" v-else>暂无活动规则</view>
</view> </view>
<view class="active-btn"><button type="primary" @click="toPoster()">{{ $lang('fenxiao.inviteFriend') }}</button></view> <view class="active-btn"><button type="primary" @click="toPoster()">邀请好友</button></view>
<ns-copyright></ns-copyright> <ns-copyright></ns-copyright>
<ns-login ref="login"></ns-login> <ns-login ref="login"></ns-login>
<loading-cover ref="loadingCover"></loading-cover> <loading-cover ref="loadingCover"></loading-cover>
@@ -79,7 +79,7 @@ export default {
setTimeout(() => { setTimeout(() => {
if (!this.addonIsExist.fenxiao) { if (!this.addonIsExist.fenxiao) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.merchantNotOpenFenxiao'), title: '商家未开启分销',
mask: true, mask: true,
duration: 2000 duration: 2000
}); });
@@ -384,7 +384,7 @@ export default {
border-radius: 50rpx; border-radius: 50rpx;
color: #985400; color: #985400;
// P0: 推广页金色按钮 → var(--promote-grad-start/end) // P0: 推广页金色按钮 → var(--promote-grad-start/end)
// 兼容: 微信小程序 / 鸿蒙{{ $lang('fenxiao.yuan') }}服务 — linear-gradient 嵌套 var() 现代 runtime 支持 // 兼容: 微信小程序 / 鸿蒙元服务 — linear-gradient 嵌套 var() 现代 runtime 支持
background: #ffe2ac; // 兜底 background: #ffe2ac; // 兜底
background: linear-gradient(45deg, var(--promote-grad-start, #ffe2ac) 0%, var(--promote-grad-end, #fdc174) 100%); background: linear-gradient(45deg, var(--promote-grad-start, #ffe2ac) 0%, var(--promote-grad-end, #fdc174) 100%);
} }

View File

@@ -1,4 +1,4 @@
<template> <template>
<view class="container" :style="themeColor"> <view class="container" :style="themeColor">
<swiper class="swiper" @change="getIndex"> <swiper class="swiper" @change="getIndex">
<swiper-item v-for="(item, index) in poster" :key="index"> <swiper-item v-for="(item, index) in poster" :key="index">
@@ -11,22 +11,22 @@
</swiper> </swiper>
<!-- #ifdef H5 --> <!-- #ifdef H5 -->
<view class="tips">{{ $lang('fenxiao.longPressQrTip') }}</view> <view class="tips">长按识别图中二维码</view>
<!-- #endif --> <!-- #endif -->
<!-- #ifdef MP --> <!-- #ifdef MP -->
<view class="btn color-base-bg color-base-border" @click="save">{{ $lang('fenxiao.saveImage') }}</view> <view class="btn color-base-bg color-base-border" @click="save">保存海报</view>
<!-- #endif --> <!-- #endif -->
<uni-popup ref="popupDialog" :custom="true" :mask-click="false"> <uni-popup ref="popupDialog" :custom="true" :mask-click="false">
<view class="dialog-popup"> <view class="dialog-popup">
<view class="title">{{ $lang('fenxiao.hint') }}</view> <view class="title">提示</view>
<view class="message">{{ $lang('fenxiao.authDeniedTip') }}</view> <view class="message">您拒绝了保存图片到相册的授权请求,无法保存图片到相册,如需正常使用,请授权之后再进行操作。</view>
<view class="action-wrap"> <view class="action-wrap">
<view @click="closeDialog">{{ $lang('common.cancel') }}</view> <view @click="closeDialog">取消</view>
<view> <view>
<button type="default" open-type="openSetting" @opensetting="closeDialog" <button type="default" open-type="openSetting" @opensetting="closeDialog"
hover-class="none">{{ $lang('fenxiao.authorizeNow') }}</button> hover-class="none">立即授权</button>
</view> </view>
</view> </view>
</view> </view>
@@ -95,7 +95,7 @@ export default {
filePath: res.tempFilePath, filePath: res.tempFilePath,
success: () => { success: () => {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.saveSuccess') title: '保存成功'
}); });
}, },
fail: res => { fail: res => {
@@ -104,20 +104,20 @@ export default {
this.$refs.popupDialog.open(); this.$refs.popupDialog.open();
} else { } else {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.saveFailed') title: '保存失败,请稍后重试'
}); });
} }
} }
}); });
} else { } else {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.downloadFailed') title: '下载失败'
}); });
} }
}, },
fail: res => { fail: res => {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.downloadFailed') title: '下载失败'
}); });
} }
}); });
@@ -136,7 +136,7 @@ export default {
}); });
} catch { } catch {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.posterGenerateFailed') title: '海报生成失败'
}); });
} }
}, },
@@ -149,7 +149,7 @@ export default {
setTimeout(() => { setTimeout(() => {
if (!this.addonIsExist.fenxiao) { if (!this.addonIsExist.fenxiao) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.merchantNotOpenFenxiao'), title: '商家未开启分销',
mask: true, mask: true,
duration: 2000 duration: 2000
}); });

View File

@@ -22,7 +22,7 @@ export default {
setTimeout(() => { setTimeout(() => {
if (!this.addonIsExist.fenxiao) { if (!this.addonIsExist.fenxiao) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.merchantNotOpenFenxiao'), title: '商家未开启分销',
mask: true, mask: true,
duration: 2000 duration: 2000
}); });
@@ -48,7 +48,7 @@ export default {
return; return;
} }
if (this.fenxiaoWords && this.fenxiaoWords.concept) this.$langConfig.title(this.fenxiaoWords.concept + this.$lang('fenxiao.center')); if (this.fenxiaoWords && this.fenxiaoWords.concept) this.$langConfig.title(this.fenxiaoWords.concept + '中心');
this.is_fenxiao = Boolean(this.memberInfo.is_fenxiao); this.is_fenxiao = Boolean(this.memberInfo.is_fenxiao);
}, },
methods: { methods: {
@@ -157,7 +157,7 @@ export default {
//生成海报 //生成海报
getGoodsPoster() { getGoodsPoster() {
uni.showLoading({ uni.showLoading({
'title': this.$lang('fenxiao.posterGenerating') 'title': '海报生成中...'
}); });
let url = ""; let url = "";
let data = {}; let data = {};
@@ -204,12 +204,12 @@ export default {
filePath: res.tempFilePath, filePath: res.tempFilePath,
success: () => { success: () => {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.saveSuccess') title: "保存成功"
}); });
}, },
fail: () => { fail: () => {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.saveFailed') title: "保存失败,请稍后重试"
}); });
} }
}); });

View File

@@ -93,7 +93,7 @@
</view> </view>
</block> </block>
<block v-if="list.length == 0 && emptyShow"> <block v-if="list.length == 0 && emptyShow">
<ns-empty :text="$lang('fenxiao.emptyData')" :isIndex="false"></ns-empty> <ns-empty text="暂无数据" :isIndex="false"></ns-empty>
</block> </block>
</view> </view>
</mescroll-uni> </mescroll-uni>

View File

@@ -61,7 +61,7 @@
</view> </view>
</view> </view>
</view> </view>
<view class="cart-empty"><ns-empty :text="$lang('fenxiao.emptyOrder')" :isIndex="false" <view class="cart-empty"><ns-empty text="暂无订单" :isIndex="false"
v-if="orderList.length == 0 && emptyShow"></ns-empty></view> v-if="orderList.length == 0 && emptyShow"></ns-empty></view>
</view> </view>
</mescroll-uni> </mescroll-uni>

View File

@@ -72,7 +72,7 @@
</view> </view>
</view> </view>
</view> </view>
<block v-if="teamList.length == 0 && emptyShow"><ns-empty :text="$lang('fenxiao.emptyData')" :isIndex="false"></ns-empty> <block v-if="teamList.length == 0 && emptyShow"><ns-empty text="暂无数据" :isIndex="false"></ns-empty>
</block> </block>
</block> </block>
</mescroll-uni> </mescroll-uni>
@@ -89,11 +89,11 @@ export default {
return { return {
levelList: [ levelList: [
{ {
name: this.$lang('fenxiao.firstLevel'), name: '一级',
level: 1 level: 1
}, },
{ {
name: this.$lang('fenxiao.secondLevel'), name: '二级',
level: 2 level: 2
} }
], ],
@@ -108,7 +108,7 @@ export default {
setTimeout(() => { setTimeout(() => {
if (!this.addonIsExist.fenxiao) { if (!this.addonIsExist.fenxiao) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.merchantNotOpenFenxiao'), title: '商家未开启分销',
mask: true, mask: true,
duration: 2000 duration: 2000
}); });

View File

@@ -175,7 +175,7 @@
verify() { verify() {
if (this.withdrawMoney == '' || this.withdrawMoney < 0 || isNaN(parseFloat(this.withdrawMoney))) { if (this.withdrawMoney == '' || this.withdrawMoney < 0 || isNaN(parseFloat(this.withdrawMoney))) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.inputWithdrawAmount') title: '请输入提现金额'
}); });
return false; return false;
} }
@@ -186,14 +186,14 @@
} }
if (parseFloat(this.withdrawMoney) > 0 && (parseFloat(this.withdrawMoney) > parseFloat(money))) { if (parseFloat(this.withdrawMoney) > 0 && (parseFloat(this.withdrawMoney) > parseFloat(money))) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.withdrawAmountExceed') title: '提现金额超出可提现金额'
}); });
return false; return false;
} }
if (parseFloat(this.withdrawMoney) > 0 && (parseFloat(this.withdrawMoney) < parseFloat(this if (parseFloat(this.withdrawMoney) > 0 && (parseFloat(this.withdrawMoney) < parseFloat(this
.withdrawConfigInfo.withdraw))) { .withdrawConfigInfo.withdraw))) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.withdrawAmountBelowMin') title: '提现金额小于最低提现金额'
}); });
return false; return false;
} }
@@ -202,7 +202,7 @@
withdraw() { withdraw() {
if (!this.bankAccountInfo.withdraw_type && !this.isBalance) { if (!this.bankAccountInfo.withdraw_type && !this.isBalance) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.pleaseAddWithdrawMethod') title: '请先添加提现方式'
}); });
return; return;
} }
@@ -235,7 +235,7 @@
success: res => { success: res => {
if (res.code >= 0) { if (res.code >= 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.withdrawApplySuccess') title: '提现申请成功'
}); });
setTimeout(() => { setTimeout(() => {
this.$util.redirectTo('/pages_promotion/fenxiao/withdraw_list', {}, this.$util.redirectTo('/pages_promotion/fenxiao/withdraw_list', {},
@@ -270,7 +270,7 @@
success: res => { success: res => {
if (res.code >= 0) { if (res.code >= 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.withdrawApplySuccess') title: '提现申请成功'
}); });
setTimeout(() => { setTimeout(() => {
this.$util.redirectTo('/pages_promotion/fenxiao/withdraw_list', {}, this.$util.redirectTo('/pages_promotion/fenxiao/withdraw_list', {},

View File

@@ -8,9 +8,9 @@
<view class="detailed-item" v-for="(item, index) in withdrawList" :key="index" <view class="detailed-item" v-for="(item, index) in withdrawList" :key="index"
@click="toDetail(item.id)"> @click="toDetail(item.id)">
<view class="info"> <view class="info">
<view class="event">{{ item.transfer_type == 'balance' ? $lang('fenxiao.balance') : <view class="event">{{ item.transfer_type == 'balance' && '余额' ||
item.transfer_type == 'alipay' ? $lang('fenxiao.alipay') : item.transfer_type == 'bank' ? $lang('fenxiao.bankCard') : item.transfer_type == 'alipay' && '支付宝' || item.transfer_type == 'bank' && '银行卡' ||
item.transfer_type =='wechatpay' ? $lang('fenxiao.wechat') : '' }}</view> item.transfer_type =='wechatpay'&&'微信' }}</view>
<view> <view>
<text class="time">{{ $util.timeStampTurnTime(item.create_time) }}</text> <text class="time">{{ $util.timeStampTurnTime(item.create_time) }}</text>
</view> </view>
@@ -25,7 +25,7 @@
</view> </view>
</block> </block>
<block v-else> <block v-else>
<ns-empty :isIndex="false" :text="$lang('fenxiao.emptyWithdrawRecord')"></ns-empty> <ns-empty :isIndex="false" text="暂无提现记录"></ns-empty>
</block> </block>
</view> </view>
</mescroll-uni> </mescroll-uni>
@@ -42,19 +42,19 @@ export default {
withdrawState: { withdrawState: {
'3': { '3': {
color: 'color: rgb(255, 69, 68)', color: 'color: rgb(255, 69, 68)',
text: this.$lang('fenxiao.transferred') text: '已转账'
}, },
'1': { '1': {
color: 'color: rgb(255, 160, 68)', color: 'color: rgb(255, 160, 68)',
text: this.$lang('fenxiao.pendingAudit') text: '待审核'
}, },
'2': { '2': {
color: 'color: rgb(17, 189, 100)', color: 'color: rgb(17, 189, 100)',
text: this.$lang('fenxiao.audited') text: '已审核'
}, },
'-1': { '-1': {
color: 'color: rgb(255, 69, 68)', color: 'color: rgb(255, 69, 68)',
text: this.$lang('fenxiao.rejected') text: '已拒绝'
} }
}, },
withdrawList: [], withdrawList: [],
@@ -65,7 +65,7 @@ export default {
setTimeout(() => { setTimeout(() => {
if (!this.addonIsExist.fenxiao) { if (!this.addonIsExist.fenxiao) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('fenxiao.merchantNotOpenFenxiao'), title: '商家未开启分销',
mask: true, mask: true,
duration: 2000 duration: 2000
}); });

View File

@@ -4,7 +4,7 @@
<!-- 搜索区域 --> <!-- 搜索区域 -->
<view class="search-wrap uni-flex uni-row" style="margin-bottom: 20rpx;"> <view class="search-wrap uni-flex uni-row" style="margin-bottom: 20rpx;">
<view class="flex-item input-wrap"> <view class="flex-item input-wrap">
<input class="uni-input" maxlength="50" v-model="keyword" @confirm="search()" :placeholder="$lang('merch.searchGoodsPlaceholder')" /> <input class="uni-input" maxlength="50" v-model="keyword" @confirm="search()" placeholder="请输入您要搜索的商品" />
<text class="iconfont icon-sousuo3" @click.stop="search()"></text> <text class="iconfont icon-sousuo3" @click.stop="search()"></text>
</view> </view>
<view class="iconfont" :class="{ 'icon-apps': isList, 'icon-list': !isList }" @click="changeListStyle()"></view> <view class="iconfont" :class="{ 'icon-apps': isList, 'icon-list': !isList }" @click="changeListStyle()"></view>
@@ -99,7 +99,8 @@
parseFloat(showPrice(item)).toFixed(2).split('.')[1] }}</text> parseFloat(showPrice(item)).toFixed(2).split('.')[1] }}</text>
</view> </view>
<view class="discount-price" v-else> <view class="discount-price" v-else>
<text class="price price-style large">{{ $lang('merch.consultNow') }}</text> <text class="price price-style large">{{ $lang('Make') ? $lang('Make') : '立即咨询'
}}</text>
</view> </view>
@@ -192,7 +193,8 @@
parseFloat(showPrice(item)).toFixed(2).split('.')[1] }}</text> parseFloat(showPrice(item)).toFixed(2).split('.')[1] }}</text>
</view> </view>
<view class="discount-price" v-else> <view class="discount-price" v-else>
<text class="price price-style large">{{ $lang('merch.consultNow') }}</text> <text class="price price-style large">{{ $lang('Make') ? $lang('Make') : '立即咨询'
}}</text>
</view> </view>
<view class="member-price-tag" <view class="member-price-tag"
v-if="item.member_price && item.member_price == showPrice(item)"> v-if="item.member_price && item.member_price == showPrice(item)">
@@ -256,7 +258,7 @@
</view> </view>
</view> </view>
</view> </view>
<view v-if="goodsList.length == 0 && emptyShow"><ns-empty :text="$lang('merch.emptyGoods')"></ns-empty></view> <view v-if="goodsList.length == 0 && emptyShow"><ns-empty text="暂无商品"></ns-empty></view>
</block> </block>
</mescroll-uni> </mescroll-uni>

View File

@@ -53,54 +53,54 @@ export default {
begin_time:'',//团购开始时间 begin_time:'',//团购开始时间
end_time:''//团购结束时间 end_time:''//团购结束时间
}, },
groundingArray: [this.$lang('merch.grounding'), this.$lang('merch.listing')], groundingArray: ['下架', '上架'],
pickuptypeArray: [this.$lang('merch.sameDay'), this.$lang('merch.nextDay'), this.$lang('merch.dayAfter')],//, '自定义' pickuptypeArray: ['当日达', '次日达', '隔日达'],//, '自定义'
currCategory: 0, // 当前所设置的商品分类 currCategory: 0, // 当前所设置的商品分类
virtualDeliverArray: [{ virtualDeliverArray: [{
name: this.$lang('merch.autoDeliver'), name: '自动发货',
value: 'auto_deliver', value: 'auto_deliver',
}, },
{ {
name: this.$lang('merch.manualDeliver'), name: '手动发货',
value: 'artificial_deliver', value: 'artificial_deliver',
}, },
{ {
name: this.$lang('merch.storeVerify'), name: '到店核销',
value: 'verify', value: 'verify',
} }
], ],
virtualDeliverValue: { virtualDeliverValue: {
'auto_deliver': this.$lang('merch.autoDeliver'), 'auto_deliver': '自动发货',
'artificial_deliver': this.$lang('merch.manualDeliver'), 'artificial_deliver': '手动发货',
'verify': this.$lang('merch.storeVerify') 'verify': '到店核销'
}, },
virtualReceiveArray: [{ virtualReceiveArray: [{
name: this.$lang('merch.autoReceive'), name: '自动收货',
value: 'auto_receive', value: 'auto_receive',
}, },
{ {
name: this.$lang('merch.buyerConfirm'), name: '买家确认收货',
value: 'artificial_receive', value: 'artificial_receive',
}, },
], ],
virtualReceiveValue: { virtualReceiveValue: {
'auto_receive': this.$lang('merch.autoReceive'), 'auto_receive': '自动收货',
'artificial_receive': this.$lang('merch.buyerConfirm'), 'artificial_receive': '买家确认收货',
}, },
validityTypeArray: [this.$lang('merch.permanent'), this.$lang('merch.validDays'), this.$lang('merch.expireDate')], validityTypeArray: ['永久', '购买后几日有效', '指定过期日期'],
virtualIndate: 0, virtualIndate: 0,
minDate: '', minDate: '',
carmiLength: this.$lang('merch.addCarmi'), carmiLength: '添加卡密',
limitLength: [ //限购 limitLength: [ //限购
{ {
name: this.$lang('merch.singleLimit'), name: '单次限购',
value: '1' value: '1'
}, },
{ {
name: this.$lang('merch.longLimit'), name: '长期限购',
value: '2' value: '2'
} }
], ],
@@ -123,14 +123,14 @@ export default {
if (this.goodsData.id) { if (this.goodsData.id) {
this.isAWait = true; this.isAWait = true;
uni.setNavigationBarTitle({ uni.setNavigationBarTitle({
title: this.$lang('merch.editGoods') title: '编辑商品'
}); });
await this.editGetGoodsInfo(); await this.editGetGoodsInfo();
} else { } else {
this.isAWait = false; this.isAWait = false;
uni.setNavigationBarTitle({ uni.setNavigationBarTitle({
title: this.$lang('merch.addGoods') title: '添加商品'
}); });
} }
@@ -167,7 +167,7 @@ export default {
if(res.result.detail){ if(res.result.detail){
this.goodsData = res.result.detail this.goodsData = res.result.detail
this.$util.showToast({ this.$util.showToast({
title: this.$lang('merch.goodsNotExist'), title: '商品不存在',
}); });
setTimeout(() => { setTimeout(() => {
this.$util.redirectTo('/pages_goods/list', {}, 'redirectTo'); this.$util.redirectTo('/pages_goods/list', {}, 'redirectTo');
@@ -265,7 +265,7 @@ export default {
this.$forceUpdate(); this.$forceUpdate();
} else { } else {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('merch.goodsNotExist'), title: '商品不存在',
}); });
setTimeout(() => { setTimeout(() => {
this.$util.redirectTo('/pages_goods/list', {}, 'redirectTo'); this.$util.redirectTo('/pages_goods/list', {}, 'redirectTo');
@@ -493,7 +493,7 @@ export default {
addShopCategory() { addShopCategory() {
if (this.shopCategoryNumber == 10) { if (this.shopCategoryNumber == 10) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('merch.maxCategoryLimit') title: '商品可以属于多个分类,最多10个'
}); });
return; return;
} }
@@ -530,7 +530,7 @@ export default {
this.goodsData.carmichael = uni.getStorageSync('editGoodsCarmichael') ? JSON.parse(uni.getStorageSync('editGoodsCarmichael')) : []; this.goodsData.carmichael = uni.getStorageSync('editGoodsCarmichael') ? JSON.parse(uni.getStorageSync('editGoodsCarmichael')) : [];
if (this.goodsData.carmichael.length > 0) { if (this.goodsData.carmichael.length > 0) {
this.carmiLength = this.$lang('merch.addCarmiWithCount', { count: this.goodsData.carmichael.length }) this.carmiLength = '添加卡密【' + this.goodsData.carmichael.length + '】'
} }
} }
@@ -568,21 +568,21 @@ export default {
if (this.goodsData.goodsname.length == 0) { if (this.goodsData.goodsname.length == 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('merch.inputGoodsName') title: '请输入商品名称'
}); });
return false; return false;
} }
if (this.goodsData.subtitle.length > 100) { if (this.goodsData.subtitle.length > 100) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('merch.subtitleMaxLength') title: '商品简介不能超过100个字符'
}); });
return false; return false;
} }
if (this.goodsData.goods_image.length == 0) { if (this.goodsData.goods_image.length == 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('merch.uploadGoodsImage') title: '请上传商品图片'
}); });
return false; return false;
} }
@@ -632,7 +632,7 @@ export default {
if (this.goodsData.price == 0) { if (this.goodsData.price == 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('merch.inputPrice') title: '请输入销售价'
}); });
return false; return false;
} }
@@ -655,26 +655,26 @@ export default {
// 总库存 // 总库存
if (this.goodsData.total == 0) { if (this.goodsData.total == 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('merch.inputStock') title: '请输入库存'
}); });
return false; return false;
} }
if (isNaN(this.goodsData.total) || !this.$util.data().regExp.number.test(this.goodsData.total)) { if (isNaN(this.goodsData.total) || !this.$util.data().regExp.number.test(this.goodsData.total)) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('merch.stockFormatError') title: '[库存]格式输入错误'
}); });
return false; return false;
} }
if (isNaN(this.goodsData.goods_start_count) || !this.$util.data().regExp.number.test(this.goodsData.goods_start_count)) { if (isNaN(this.goodsData.goods_start_count) || !this.$util.data().regExp.number.test(this.goodsData.goods_start_count)) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('merch.startCountFormatError') title: '[起售]格式输入错误'
}); });
return false; return false;
} }
if (this.goodsData.goods_start_count < 0) { if (this.goodsData.goods_start_count < 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('merch.startCountNotNegative') title: '起售数量不能小于0'
}); });
return false; return false;
} }
@@ -905,7 +905,7 @@ export default {
getGoodsForm() { getGoodsForm() {
getOrderFormList().then(res=>{ getOrderFormList().then(res=>{
if (res.data) { if (res.data) {
let goodsForm = [this.$lang('merch.selectGoodsForm')]; let goodsForm = ['请选择商品表单'];
res.data.forEach((item, index) => { res.data.forEach((item, index) => {
goodsForm.push(item.form_name); goodsForm.push(item.form_name);
if (this.goodsData.form_id && this.goodsData.form_id == item.id) this.goodsData.goods_form_index = index + 1; if (this.goodsData.form_id && this.goodsData.form_id == item.id) this.goodsData.goods_form_index = index + 1;
@@ -926,7 +926,7 @@ export default {
getSupplyList() { getSupplyList() {
getSupplyList().then(res=>{ getSupplyList().then(res=>{
if (res.data) { if (res.data) {
let supplyForm = [this.$lang('merch.selectSupplier')]; let supplyForm = ['请选择供应商'];
res.data.forEach((item, index) => { res.data.forEach((item, index) => {
supplyForm.push(item.title); supplyForm.push(item.title);
if (this.goodsData.supplier_id && this.goodsData.supplier_id == item.supplier_id) this.goodsData.supply_index = index + 1; if (this.goodsData.supplier_id && this.goodsData.supplier_id == item.supplier_id) this.goodsData.supply_index = index + 1;

View File

@@ -39,7 +39,7 @@ export default {
fontWeight: false, fontWeight: false,
padding: 0, padding: 0,
cartEvent: "detail", cartEvent: "detail",
text: this.$lang('goods.buy'), text: "购买",
textColor: "#FFFFFF", textColor: "#FFFFFF",
theme: "default", theme: "default",
aroundRadius: 25, aroundRadius: 25,
@@ -76,8 +76,8 @@ export default {
this.getMerch() this.getMerch()
}else{ }else{
uni.showModal({ uni.showModal({
title: this.$lang('common.tip'), title:'提示',
content: this.$lang('merch.merchantNotExist'), content:'商家不存在',
showCancel:false, showCancel:false,
success(e){ success(e){
uni.navigateBack({}) uni.navigateBack({})
@@ -120,7 +120,7 @@ export default {
* 转发分享 * 转发分享
*/ */
onShareAppMessage(res) { onShareAppMessage(res) {
var title = this.$lang('merch.searchResultCount', { count: this.count, keyword: this.keyword + this.category_title + this.coupon_name });'”相关的优质商品'; var title = '搜索到' + this.count + '件“' + this.keyword + this.category_title + this.coupon_name + '”相关的优质商品';
let route = this.$util.getCurrentShareRoute(this.memberInfo ? this.memberInfo.member_id : 0); let route = this.$util.getCurrentShareRoute(this.memberInfo ? this.memberInfo.member_id : 0);
var path = route.path; var path = route.path;
return { return {
@@ -134,7 +134,7 @@ export default {
}, },
// 分享到微信朋友圈 // 分享到微信朋友圈
onShareTimeline() { onShareTimeline() {
var title = this.$lang('merch.searchResultCount', { count: this.count, keyword: this.keyword + this.category_title + this.coupon_name });'”相关的优质商品'; var title = '搜索到' + this.count + '件“' + this.keyword + this.category_title + this.coupon_name + '”相关的优质商品';
let route = this.$util.getCurrentShareRoute(this.memberInfo ? this.memberInfo.member_id : 0); let route = this.$util.getCurrentShareRoute(this.memberInfo ? this.memberInfo.member_id : 0);
var query = route.query; var query = route.query;
return { return {
@@ -144,18 +144,18 @@ export default {
}; };
}, },
methods: { methods: {
getMerch(){ getMerch(){
this.$api.sendRequest({ this.$api.sendRequest({
url: '/merch/api/merch/merchinfo', url: '/merch/api/merch/merchinfo',
data: { data: {
merch_id: this.merch_id merch_id: this.merch_id
}, },
success: res => { success: res => {
if (res.code >= 0 && res.data) { if (res.code >= 0 && res.data) {
this.merch = res.data; this.merch = res.data;
} }
} }
}); });
}, },
/** /**
* 获取优惠券数据 * 获取优惠券数据
@@ -336,26 +336,26 @@ export default {
// } // }
if (!Number(this.maxPrice) && this.maxPrice) { if (!Number(this.maxPrice) && this.maxPrice) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('merch.inputMaxPrice') title: '请输入最高价'
}); });
return; return;
} }
if (Number(this.minPrice) < 0 || Number(this.maxPrice) < 0) { if (Number(this.minPrice) < 0 || Number(this.maxPrice) < 0) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('merch.priceNotNegative') title: '筛选价格不能小于0'
}); });
return; return;
} }
if (this.minPrice != '' && Number(this.minPrice) > Number(this.maxPrice) && this.maxPrice) { if (this.minPrice != '' && Number(this.minPrice) > Number(this.maxPrice) && this.maxPrice) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('merch.minNotGreaterMax') title: '最低价不能大于最高价'
}); });
return; return;
} }
if (this.maxPrice != '' && Number(this.maxPrice) < Number(this.minPrice)) { if (this.maxPrice != '' && Number(this.maxPrice) < Number(this.minPrice)) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('merch.maxNotLessMin') title: '最高价不能小于最低价'
}); });
return; return;
} }

View File

@@ -35,7 +35,7 @@
</view> </view>
<view class="group-wrap padding-top"> <view class="group-wrap padding-top">
<view class="goods-module-wrap"> <view class="goods-module-wrap">
<text class="price-symbol ">{{ pointInfo.point }}{{ $lang('point.point') }}</text> <text class="price-symbol ">{{ pointInfo.point }}积分</text>
<template v-if="pointInfo.exchange_price != '0.00' && pointInfo.pay_type > 0"> <template v-if="pointInfo.exchange_price != '0.00' && pointInfo.pay_type > 0">
<text class="price-symbol ">+{{ $lang('common.currencySymbol') }}{{ pointInfo.exchange_price <text class="price-symbol ">+{{ $lang('common.currencySymbol') }}{{ pointInfo.exchange_price
}}</text> }}</text>
@@ -48,10 +48,10 @@
<view class="follow-and-share" <view class="follow-and-share"
v-if="pointInfo.stock_show == 1 || pointInfo.stock_show == undefined"> v-if="pointInfo.stock_show == 1 || pointInfo.stock_show == undefined">
<text class="color-tip" v-if="pointInfo.pointCoupon != 1">{{ $lang('point.stockLabel') }}:{{ pointInfo.stock }}{{ <text class="color-tip" v-if="pointInfo.pointCoupon != 1">库存:{{ pointInfo.stock }}{{
pointInfo.stock >= 0 ? pointInfo.stock >= 0 ?
pointInfo.unit : '' }}</text> pointInfo.unit : '' }}</text>
<text class="color-tip" v-else>{{ $lang('point.stockLabel') }}:{{ $lang('point.unlimitedStock') }}{{ pointInfo.stock >= 0 ? pointInfo.unit : '' }}</text> <text class="color-tip" v-else>库存:无限{{ pointInfo.stock >= 0 ? pointInfo.unit : '' }}</text>
</view> </view>
</view> </view>
<view class="goods-module-wrap info"> <view class="goods-module-wrap info">
@@ -61,21 +61,21 @@
<text class="sku-name-wrap" v-else>{{ pointInfo.name }}</text> <text class="sku-name-wrap" v-else>{{ pointInfo.name }}</text>
</view> </view>
<view class="coupon-desc"> <view class="coupon-desc">
<view v-if="pointInfo.balance && pointInfo.balance > 0" class="color-tip">{{ $lang('point.contains') }}{{ pointInfo.balance <view v-if="pointInfo.balance && pointInfo.balance > 0" class="color-tip">内含{{ pointInfo.balance
}}{{ $lang('common.yuan') }}</view> }}元</view>
<view v-if="pointInfo.coupon_type == 'random'" class="color-tip">{{ $lang('point.noThresholdCoupon') }}</view> <view v-if="pointInfo.coupon_type == 'random'" class="color-tip">无门槛优惠券</view>
<view v-if="pointInfo.coupon_type == 'reward'" class="color-tip">{{ $lang('form.full') + pointInfo.at_least + <view v-if="pointInfo.coupon_type == 'reward'" class="color-tip">{{ '满' + pointInfo.at_least +
$lang('common.yuan') + $lang('order.fullReduceDesc', { limit: pointInfo.at_least, type: '', money: pointInfo.money }) '减' + pointInfo.money
}}</view> }}</view>
<view v-if="pointInfo.coupon_type == 'discount'" class="color-tip"> <view v-if="pointInfo.coupon_type == 'discount'" class="color-tip">
{{ $lang('form.full') }}{{ pointInfo.at_least }}{{ $lang('common.yuan') }} 满{{ pointInfo.at_least }}元
<text>{{ pointInfo.discount }}{{ $lang('common.discount') }}</text> <text>{{ pointInfo.discount }}折</text>
</view> </view>
<view v-if="pointInfo.coupon_type == 'discount'" class="color-tip">{{ $lang('point.maxDiscount') }}{{ <view v-if="pointInfo.coupon_type == 'discount'" class="color-tip">最多优惠{{
pointInfo.discount_limit }}{{ $lang('common.yuan') }}</view> pointInfo.discount_limit }}元</view>
<view class="time color-tip" v-if="pointInfo.coupon_type"> <view class="time color-tip" v-if="pointInfo.coupon_type">
{{ pointInfo.validity_type == 1 ? $lang('point.fromReceive') + pointInfo.fixed_term + $lang('point.daysValid') : {{ pointInfo.validity_type == 1 ? '领取之日起' + pointInfo.fixed_term + '天内有效' :
$util.timeStampTurnTime(pointInfo.end_time) + $lang('point.expireAt') }} $util.timeStampTurnTime(pointInfo.end_time) + '到期' }}
</view> </view>
</view> </view>
</view> </view>
@@ -88,7 +88,7 @@
<view class="community-txt">{{ pointInfo.qr_data.community_describe }}</view> <view class="community-txt">{{ pointInfo.qr_data.community_describe }}</view>
</view> </view>
</view> </view>
<view class="community-btn" @click="onCommunity()">{{ $lang('point.add') }}</view> <view class="community-btn" @click="onCommunity()">添加</view>
</view> </view>
<!-- 促销 --> <!-- 促销 -->
@@ -96,7 +96,7 @@
v-show="isCommunity"> v-show="isCommunity">
<view class="community-model-content" @click.stop> <view class="community-model-content" @click.stop>
<view class="community-model-content-radius"> <view class="community-model-content-radius">
<view>{{ $lang('point.add') }}{{ $lang('point.community') }}</view> <view>添加社群</view>
</view> </view>
<view class="community-model-content-draw" v-if="pointInfo.qr_data && pointInfo.qr_data.qr_img"> <view class="community-model-content-draw" v-if="pointInfo.qr_data && pointInfo.qr_data.qr_img">
<image :src="pointInfo.qr_data.qr_img != '' && pointInfo.qr_data.qr_state == 1 <image :src="pointInfo.qr_data.qr_img != '' && pointInfo.qr_data.qr_state == 1
@@ -104,7 +104,7 @@
: $util.img('public/uniapp/goods/detail_erweiImage.png') : $util.img('public/uniapp/goods/detail_erweiImage.png')
" mode="aspectFill" show-menu-by-longpress /> " mode="aspectFill" show-menu-by-longpress />
</view> </view>
<view class="community-model-content-text">{{ $lang('point.longPressQrCode') }}</view> <view class="community-model-content-text">长按识别二维码,添加社群</view>
</view> </view>
<view class="community-model-close" @click.stop="onCloseCommunity()"><text <view class="community-model-close" @click.stop="onCloseCommunity()"><text
class="iconfont icon-close"></text> class="iconfont icon-close"></text>
@@ -115,7 +115,7 @@
<view class="newdetail margin-bottom"> <view class="newdetail margin-bottom">
<!-- 已选规格 --> <!-- 已选规格 -->
<view class="item selected-sku-spec" v-if="pointInfo.sku_spec_format" @click="exchange"> <view class="item selected-sku-spec" v-if="pointInfo.sku_spec_format" @click="exchange">
<view class="label">{{ $lang('point.select') }}</view> <view class="label">选择</view>
<view class="box"> <view class="box">
<text v-for="(item, index) in pointInfo.sku_spec_format" :key="index">{{ item.spec_name <text v-for="(item, index) in pointInfo.sku_spec_format" :key="index">{{ item.spec_name
}}/{{ }}/{{
@@ -126,7 +126,7 @@
<view class="item goods-attribute" @click="openAttributePopup()" <view class="item goods-attribute" @click="openAttributePopup()"
v-if="pointInfo.goods_attr_format && pointInfo.goods_attr_format.length > 0"> v-if="pointInfo.goods_attr_format && pointInfo.goods_attr_format.length > 0">
<view class="label">{{ $lang('point.attribute') }}</view> <view class="label">属性</view>
<view class="box"> <view class="box">
<text v-for="(item, index) in pointInfo.goods_attr_format" :key="index" <text v-for="(item, index) in pointInfo.goods_attr_format" :key="index"
v-if="index < 2">{{ v-if="index < 2">{{
@@ -141,7 +141,7 @@
<uni-popup ref="attributePopup" type="bottom"> <uni-popup ref="attributePopup" type="bottom">
<view class="goods-attribute-popup-layer popup-layer"> <view class="goods-attribute-popup-layer popup-layer">
<view class="head-wrap" @click="closeAttributePopup()"> <view class="head-wrap" @click="closeAttributePopup()">
<text>{{ $lang('point.goodsAttribute') }}</text> <text>商品属性</text>
<text class="iconfont icon-close"></text> <text class="iconfont icon-close"></text>
</view> </view>
<scroll-view scroll-y class="goods-attribute-body"> <scroll-view scroll-y class="goods-attribute-body">
@@ -152,7 +152,7 @@
</view> </view>
</scroll-view> </scroll-view>
<view class="button-box"><button type="primary" <view class="button-box"><button type="primary"
@click="closeAttributePopup()">{{ $lang('point.confirm') }}</button></view> @click="closeAttributePopup()">确定</button></view>
</view> </view>
</uni-popup> </uni-popup>
</view> </view>
@@ -161,7 +161,7 @@
<uni-popup ref="merchantsServicePopup" type="bottom"> <uni-popup ref="merchantsServicePopup" type="bottom">
<view class="goods-merchants-service-popup-layer popup-layer"> <view class="goods-merchants-service-popup-layer popup-layer">
<view class="head-wrap" @click="closeMerchantsServicePopup()"> <view class="head-wrap" @click="closeMerchantsServicePopup()">
<text>{{ $lang('point.goodsService') }}</text> <text>商品服务</text>
<text class="iconfont icon-close"></text> <text class="iconfont icon-close"></text>
</view> </view>
<scroll-view scroll-y> <scroll-view scroll-y>
@@ -175,7 +175,7 @@
</view> </view>
</scroll-view> </scroll-view>
<view class="button-box"><button type="primary" <view class="button-box"><button type="primary"
@click="closeMerchantsServicePopup()">{{ $lang('point.confirm') }}</button></view> @click="closeMerchantsServicePopup()">确定</button></view>
</view> </view>
</uni-popup> </uni-popup>
</view> </view>
@@ -184,7 +184,7 @@
<!-- 详情 --> <!-- 详情 -->
<view class="goods-detail-tab"> <view class="goods-detail-tab">
<view class="detail-tab"> <view class="detail-tab">
<view class="tab-item">{{ $lang('point.exchangeDetail') }}</view> <view class="tab-item">兑换详情</view>
</view> </view>
<view class="detail-content"> <view class="detail-content">
@@ -192,7 +192,7 @@
<view class="goods-details" v-if="pointInfo.content"><rich-text <view class="goods-details" v-if="pointInfo.content"><rich-text
:nodes="pointInfo.content"></rich-text> :nodes="pointInfo.content"></rich-text>
</view> </view>
<view class="goods-details active" v-else>{{ $lang('point.noExchangeDetail') }}</view> <view class="goods-details active" v-else>暂无兑换详情!</view>
</view> </view>
</view> </view>
</view> </view>
@@ -205,14 +205,14 @@
</view> </view>
<view class="detail-swap" @click="exchange()" :class="{ 'position-bottom': isIphoneX }" v-if="!isLogin"><button <view class="detail-swap" @click="exchange()" :class="{ 'position-bottom': isIphoneX }" v-if="!isLogin"><button
type="primary">{{ $lang('point.loginToExchange') }}</button></view> type="primary">登录之后方可兑换</button></view>
<block v-else> <block v-else>
<view class="detail-swap" :class="{ 'position-bottom': isIphoneX }" v-if="pointInfo.stock == 0"><button <view class="detail-swap" :class="{ 'position-bottom': isIphoneX }" v-if="pointInfo.stock == 0"><button
disabled>{{ $lang('point.insufficientStock') }}</button></view> disabled>库存不足</button></view>
<view class="detail-swap" :class="{ 'position-bottom': isIphoneX }" v-else-if="enough"><button <view class="detail-swap" :class="{ 'position-bottom': isIphoneX }" v-else-if="enough"><button
disabled>{{ $lang('point.insufficientPoint') }}</button></view> disabled>积分不足</button></view>
<view class="detail-swap" @click="exchange()" :class="{ 'position-bottom': isIphoneX }" v-else><button <view class="detail-swap" @click="exchange()" :class="{ 'position-bottom': isIphoneX }" v-else><button
type="primary" hover-class="none">{{ $lang('point.exchange') }}</button></view> type="primary" hover-class="none">兑换</button></view>
</block> </block>
<loading-cover ref="loadingCover"></loading-cover> <loading-cover ref="loadingCover"></loading-cover>
@@ -293,7 +293,7 @@ export default {
imageUrl = this.pointInfo.image; imageUrl = this.pointInfo.image;
break; break;
} }
title = this.$lang('point.exchangeWithPoints', { points: this.pointInfo.point }) + title; title = '仅需' + this.pointInfo.point + '积分即可兑换' + title;
imageUrl = this.$util.img(imageUrl); imageUrl = this.$util.img(imageUrl);
var route = this.$util.getCurrentShareRoute(this.memberInfo ? this.memberInfo.member_id : 0); var route = this.$util.getCurrentShareRoute(this.memberInfo ? this.memberInfo.member_id : 0);
var path = route.path; var path = route.path;
@@ -322,7 +322,7 @@ export default {
imageUrl = this.pointInfo.image; imageUrl = this.pointInfo.image;
break; break;
} }
title = this.$lang('point.exchangeWithPoints', { points: this.pointInfo.point }) + title; title = '仅需' + this.pointInfo.point + '积分即可兑换' + title;
imageUrl = this.$util.img(imageUrl); imageUrl = this.$util.img(imageUrl);
var route = this.$util.getCurrentShareRoute(this.memberInfo ? this.memberInfo.member_id : 0); var route = this.$util.getCurrentShareRoute(this.memberInfo ? this.memberInfo.member_id : 0);
var query = route.query; var query = route.query;

View File

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

View File

@@ -10,7 +10,7 @@
</view> </view>
<view class="search" @click="$util.redirectTo('/pages_tool/goods/search')"> <view class="search" @click="$util.redirectTo('/pages_tool/goods/search')">
<text class="iconfont icon-sousuo3"></text> <text class="iconfont icon-sousuo3"></text>
<text class="tips">{{ $lang('goods.searchGoods') }}</text> <text class="tips">搜索商品</text>
</view> </view>
<view class="sign" <view class="sign"
:style="{ width: menuButtonBounding.height + 'px', height: menuButtonBounding.height + 'px' }" :style="{ width: menuButtonBounding.height + 'px', height: menuButtonBounding.height + 'px' }"
@@ -28,17 +28,17 @@
<view class="account-content"> <view class="account-content">
<view class="left"> <view class="left">
<image :src="$util.img('public/uniapp/point/point-icon.png')" mode="widthFix"></image> <image :src="$util.img('public/uniapp/point/point-icon.png')" mode="widthFix"></image>
<view>{{ $lang('point.myPoint') }}</view> <view>我的积分</view>
</view> </view>
<view class="right"> <view class="right">
<text class="point price-font">{{ point }}</text> <text class="point price-font">{{ point }}</text>
<text class="text">{{ $lang('point.point') }}</text> <text class="text">积分</text>
<!-- <text class="iconfont icon-right"></text> --> <!-- <text class="iconfont icon-right"></text> -->
</view> </view>
</view> </view>
<view class="remark"> <view class="remark">
<view class="label">{{ $lang('point.reminder') }}</view> <view class="label">提醒</view>
<view class="text">{{ $lang('point.reminderDesc') }}</view> <view class="text">积分兑好礼,每日上新换不停!</view>
</view> </view>
</view> </view>
@@ -81,9 +81,9 @@
<view class="recharge-list-wrap" @click="redirect('/pages_tool/recharge/list')" <view class="recharge-list-wrap" @click="redirect('/pages_tool/recharge/list')"
v-if="rechargeList.length"> v-if="rechargeList.length">
<view class="item-wrap" v-for="(item, index) in rechargeList.slice(0, 4)" :key="index"> <view class="item-wrap" v-for="(item, index) in rechargeList.slice(0, 4)" :key="index">
<view class="recharge">{{ $lang('point.recharge') }}{{ parseFloat(item.buy_price) }}{{ $lang('common.yuan') }}</view> <view class="recharge">储值{{ parseFloat(item.buy_price) }}元</view>
<view class="point">{{ $lang('point.getPoint') }}{{ item.point }}{{ $lang('point.point') }}</view> <view class="point">可得{{ item.point }}积分</view>
<view class="btn">{{ $lang('point.goRecharge') }}</view> <view class="btn">去储值</view>
</view> </view>
</view> </view>
@@ -91,7 +91,7 @@
<view class="point-exchange-wrap exchange-coupon" v-if="couponList.length > 0"> <view class="point-exchange-wrap exchange-coupon" v-if="couponList.length > 0">
<view class="card-category-title"> <view class="card-category-title">
<text class="before-line"></text> <text class="before-line"></text>
<text>{{ $lang('point.exchangeCoupon') }}</text> <text>积分换券</text>
<text class="after-line"></text> <text class="after-line"></text>
</view> </view>
@@ -115,24 +115,25 @@
</block> </block>
<block v-if="couponItem.coupon_type == 'discount'"> <block v-if="couponItem.coupon_type == 'discount'">
<block v-if="couponItem.coupon_type == 'discount'"> <block v-if="couponItem.coupon_type == 'discount'">
{{ parseFloat(couponItem.discount) }}<text>{{ $lang('common.discount') }}</text> {{ parseFloat(couponItem.discount) }}<text>折</text>
</block> </block>
</block> </block>
</view> </view>
<view class="coupon-info"> <view class="coupon-info">
<view class="coupon_condition font-size-activity-tag"> <view class="coupon_condition font-size-activity-tag">
{{ couponItem.at_least == 0 ? $lang('point.noThresholdCoupon') : $lang('point.fullAvailable', { amount: parseFloat(couponItem.at_least).toFixed(0) }) }} {{ couponItem.at_least == 0 ? '无门槛优惠券' : '满' +
parseFloat(couponItem.at_least).toFixed(0) + '可用' }}
</view> </view>
<view class="coupon_type font-size-activity-tag" <view class="coupon_type font-size-activity-tag"
v-if="couponItem.goods_type == 1">{{ $lang('point.siteWideCoupon') }}</view> v-if="couponItem.goods_type == 1">全场券</view>
<view class="coupon_type font-size-activity-tag" <view class="coupon_type font-size-activity-tag"
v-else-if="couponItem.goods_type == 2 || couponItem.goods_type == 3"> v-else-if="couponItem.goods_type == 2 || couponItem.goods_type == 3">
{{ $lang('point.designatedCoupon') }}</view> 指定券</view>
</view> </view>
</view> </view>
<view class="coupon_right"> <view class="coupon_right">
<view class="coupon_num font-size-tag">{{ couponItem.point }}{{ $lang('point.point') }}</view> <view class="coupon_num font-size-tag">{{ couponItem.point }}积分</view>
<view class="coupon_btn">{{ $lang('point.exchange') }}</view> <view class="coupon_btn">兑换</view>
</view> </view>
</view> </view>
</view> </view>
@@ -144,7 +145,7 @@
<view class="point-exchange-wrap exchange-hongbao" v-if="hongbaoList.length > 0"> <view class="point-exchange-wrap exchange-hongbao" v-if="hongbaoList.length > 0">
<view class="card-category-title"> <view class="card-category-title">
<text class="before-line"></text> <text class="before-line"></text>
<text>{{ $lang('point.exchangeHongbao') }}</text> <text>积分换红包</text>
<text class="after-line"></text> <text class="after-line"></text>
</view> </view>
@@ -165,8 +166,8 @@
<!-- <view class="coupon_condition font-size-activity-tag">{{ hongbaoItem.name }}</view> --> <!-- <view class="coupon_condition font-size-activity-tag">{{ hongbaoItem.name }}</view> -->
</view> </view>
<view class="coupon_right"> <view class="coupon_right">
<view class="coupon_num font-size-tag">{{ hongbaoItem.point }}{{ $lang('point.point') }}</view> <view class="coupon_num font-size-tag">{{ hongbaoItem.point }}积分</view>
<view class="coupon_btn">{{ $lang('point.exchange') }}</view> <view class="coupon_btn">兑换</view>
</view> </view>
</view> </view>
</view> </view>
@@ -177,7 +178,7 @@
<view class="point-exchange-wrap" v-if="goodsList.length > 0"> <view class="point-exchange-wrap" v-if="goodsList.length > 0">
<view class="card-category-title"> <view class="card-category-title">
<text class="before-line"></text> <text class="before-line"></text>
<text>{{ $lang('point.exchangeGift') }}</text> <text>积分换礼品</text>
<text class="after-line"></text> <text class="after-line"></text>
</view> </view>
@@ -195,7 +196,7 @@
<view class="discount-price"> <view class="discount-price">
<view> <view>
<text class="unit price-font point">{{ item.point }}</text> <text class="unit price-font point">{{ item.point }}</text>
<text class="unit font-size-tag ">{{ $lang('point.point') }}</text> <text class="unit font-size-tag ">积分</text>
</view> </view>
<block v-if="item.price > 0 && item.pay_type > 0"> <block v-if="item.price > 0 && item.pay_type > 0">
<text class="unit font-size-tag">+</text> <text class="unit font-size-tag">+</text>
@@ -203,17 +204,17 @@
<text class="font-size-tag">{{ <text class="font-size-tag">{{
parseFloat(item.price).toFixed(2).split(".")[0] }}</text> parseFloat(item.price).toFixed(2).split(".")[0] }}</text>
<text class="unit font-size-tag">.{{ <text class="unit font-size-tag">.{{
parseFloat(item.price).toFixed(2).split(".")[1] }}{{ $lang('common.yuan') }}</text> parseFloat(item.price).toFixed(2).split(".")[1] }}元</text>
</view> </view>
</block> </block>
</view> </view>
<view class="btn" @click="toDetail(item)">{{ $lang('point.exchange') }}</view> <view class="btn" @click="toDetail(item)">兑换</view>
</view> </view>
<view class="pro-info" v-if="item.stock_show || item.sale_show"> <view class="pro-info" v-if="item.stock_show || item.sale_show">
<view class="font-size-activity-tag color-tip" v-if="item.stock_show"> <view class="font-size-activity-tag color-tip" v-if="item.stock_show">
{{ $lang('point.stock') }}:{{ isNaN(parseInt(item.stock)) ? 0 : parseInt(item.stock) }}</view> 库存:{{ isNaN(parseInt(item.stock)) ? 0 : parseInt(item.stock) }}</view>
<view class="font-size-activity-tag color-tip sale" v-if="item.sale_show"> <view class="font-size-activity-tag color-tip sale" v-if="item.sale_show">
{{ $lang('point.exchanged') }}:{{ isNaN(parseInt(item.sale_num)) ? 0 : parseInt(item.sale_num) }} 已兑:{{ isNaN(parseInt(item.sale_num)) ? 0 : parseInt(item.sale_num) }}
</view> </view>
</view> </view>
</view> </view>
@@ -230,20 +231,20 @@
<uni-popup ref="pointPopup" type="bottom"> <uni-popup ref="pointPopup" type="bottom">
<view class="tips-layer"> <view class="tips-layer">
<view class="head" @click="closePointPopup()"> <view class="head" @click="closePointPopup()">
<view class="title">{{ $lang('point.integralDescription') }}</view> <view class="title">{{ isEnEnv ? 'Integral Description' : '积分说明' }}</view>
<text class="iconfont icon-close"></text> <text class="iconfont icon-close"></text>
</view> </view>
<view class="body"> <view class="body">
<view class="detail margin-bottom"> <view class="detail margin-bottom">
<view class="tip">{{ $lang('point.integralAcquisition') }}</view> <view class="tip">{{ isEnEnv ? 'Integral Acquisition' : '积分的获取' }}</view>
<view class="font-size-base">1、{{ $lang('point.integralAcquisitionDesc1') }}</view> <view class="font-size-base">1、积分可在注册、签到、分享、消费、充值时获得。</view>
<view class="font-size-base">2、{{ $lang('point.integralAcquisitionDesc2') }}</view> <view class="font-size-base">2、在购买部分商品时可获得积分。</view>
<view class="tip">{{ $lang('point.integralUse') }}</view> <view class="tip">{{ isEnEnv ? 'Integral Use' : '积分的使用' }}</view>
<view class="font-size-base">1、{{ $lang('point.integralUseDesc1') }}</view> <view class="font-size-base">1、积分可用于兑换积分中心的商品。</view>
<view class="font-size-base">2、{{ $lang('point.integralUseDesc2') }}</view> <view class="font-size-base">2、积分可在参与某些活动时使用。</view>
<view class="font-size-base">3、{{ $lang('point.integralUseDesc3') }}</view> <view class="font-size-base">3、积分不得转让,出售,不设有效期。</view>
<view class="tip">{{ $lang('point.integralQuery') }}</view> <view class="tip">{{ isEnEnv ? 'Integral Query' : '积分的查询' }}</view>
<view class="font-size-base">1、{{ $lang('point.integralQueryDesc1') }}</view> <view class="font-size-base">1、积分可在会员中心中查询具体数额以及明细。</view>
</view> </view>
</view> </view>
</view> </view>
@@ -272,15 +273,15 @@ export default {
}, },
categoryList: [{ categoryList: [{
id: 1, id: 1,
name: this.$lang('point.exchangeGoods') name: '积分换好物'
}, },
{ {
id: 2, id: 2,
name: this.$lang('point.exchangeCoupon') name: '积分换券'
}, },
{ {
id: 3, id: 3,
name: this.$lang('point.exchangeHongbao') name: '积分换红包'
} }
], ],
isLogin: false, isLogin: false,
@@ -301,7 +302,7 @@ export default {
setTimeout(() => { setTimeout(() => {
if (!this.addonIsExist.pointexchange) { if (!this.addonIsExist.pointexchange) {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('point.notOpenPointMall'), title: '商家未开启积分商城',
mask: true, mask: true,
duration: 2000 duration: 2000
}); });
@@ -579,7 +580,7 @@ export default {
} }
} else { } else {
this.$util.showToast({ this.$util.showToast({
title: this.$lang('point.noActivity') title: '暂无相关活动'
}); });
} }
} }

Some files were not shown because too many files have changed in this diff Show More