Browse Source

完善商城模块的国际化

npzzwq99 2 weeks ago
parent
commit
c5aaf0cc20

+ 4 - 4
components/mall/mall-category-content.vue

@@ -10,17 +10,17 @@
       <view class="recommend-line"></view>
       <view class="recommend-text">
         <text class="recommend-icon">★</text>
-        <text class="recommend-label">分類推薦</text>
+        <text class="recommend-label">{{ $t('mall.category.recommend') }}</text>
       </view>
       <view class="recommend-line"></view>
     </view>
     <mall-product :dataList="goodsList" :dataStyle="dataStyle" />
     <view class="load-more" v-if="goodsList.length > 0">
-      <text v-if="loading">加載中...</text>
-      <text v-else-if="currentPage >= lastPage">没有更多了</text>
+      <text v-if="loading">{{ $t('common.loading') }}</text>
+      <text v-else-if="currentPage >= lastPage">{{ $t('common.noMore') }}</text>
     </view>
     <view class="empty" v-if="!goodsList.length && !loading">
-      <text>暫無商品</text>
+      <text>{{ $t('mall.category.empty') }}</text>
     </view>
   </scroll-view>
 </template>

+ 3 - 3
components/mall/mall-home-content.vue

@@ -40,8 +40,8 @@
           <mall-product :dataList="likesDataList"
             :dataStyle="'col-' + (item.params.colthree || 2) + '-' + (item.params.colmargin || 20)" />
           <view class="load-more" v-if="likesDataList.length > 0">
-            <text v-if="likesLoading">加載中...</text>
-            <text v-else-if="likesCurrentPage >= likesLastPage">没有更多了</text>
+            <text v-if="likesLoading">{{ $t('common.loading') }}</text>
+            <text v-else-if="likesCurrentPage >= likesLastPage">{{ $t('common.noMore') }}</text>
           </view>
         </view>
 
@@ -54,7 +54,7 @@
     </view>
 
     <view class="empty" v-if="(!homeModules || !homeModules.item || homeModules.item.length === 0) && !likesLoading">
-      <text>暫無內容</text>
+      <text>{{ $t('common.empty') }}</text>
     </view>
   </scroll-view>
 </template>

+ 1 - 1
components/mall/mall-navbar.vue

@@ -50,7 +50,7 @@ export default {
 		},
 		searchPlaceholder: {
 			type: String,
-			default: '搜索商品'
+			default: ''
 		},
 		searchTag: {
 			type: String,

+ 22 - 22
components/mall/mall-product.vue

@@ -13,25 +13,25 @@
 							<view class="content padding-bj">
 								<view class="text-cut-2">
 									<block v-if="item.shop && item.shop.isself == 1">
-										<view class="cu-tag radius sm bg-red">自營</view>
+										<view class="cu-tag radius sm bg-red">{{ $t('mall.product.selfOperated') }}</view>
 									</block>
 									<block v-else-if="item.shop">
-										<view class="cu-tag radius sm bg-gray" v-if="item.shop.state == 0">個人</view>
-										<view class="cu-tag radius sm wanl-bg-blue" v-else-if="item.shop.state == 1">企業</view>
-										<view class="cu-tag radius sm wanl-bg-orange" v-else-if="item.shop.state == 2">旗艦</view>
+										<view class="cu-tag radius sm bg-gray" v-if="item.shop.state == 0">{{ $t('mall.product.personal') }}</view>
+										<view class="cu-tag radius sm wanl-bg-blue" v-else-if="item.shop.state == 1">{{ $t('mall.product.enterprise') }}</view>
+										<view class="cu-tag radius sm wanl-bg-orange" v-else-if="item.shop.state == 2">{{ $t('mall.product.flagship') }}</view>
 									</block>
 									<text class="margin-left-xs">{{ item.title }}</text>
 								</view>
 								<view class="goods-tag">
-									<view class="cu-tag radius sm line-red" v-if="item.shop && item.shop.isself == 1">官方保障</view>
-									<view class="cu-tag radius sm line-gray" v-if="item.isLive">直播</view>
+									<view class="cu-tag radius sm line-red" v-if="item.shop && item.shop.isself == 1">{{ $t('mall.product.officialGuarantee') }}</view>
+									<view class="cu-tag radius sm line-gray" v-if="item.isLive">{{ $t('mall.product.live') }}</view>
 								</view>
 								<view class="flex align-center justify-between">
 									<view class="text-red text-bold text-lg">
 										<text class="text-price">{{ item.price }}</text>
 									</view>
 									<view class="text-sm wanl-gray">
-										<text>{{ formatCount(item.comment) }} 評論</text>
+										<text>{{ formatCount(item.comment) }} {{ $t('mall.product.comments') }}</text>
 									</view>
 								</view>
 							</view>
@@ -46,25 +46,25 @@
 							<view class="content padding-bj">
 								<view class="text-cut-2">
 									<block v-if="item.shop && item.shop.isself == 1">
-										<view class="cu-tag radius sm margin-right-xs bg-red">自營</view>
+										<view class="cu-tag radius sm margin-right-xs bg-red">{{ $t('mall.product.selfOperated') }}</view>
 									</block>
 									<block v-else-if="item.shop">
-										<view class="cu-tag radius sm margin-right-xs bg-gray" v-if="item.shop.state == 0">個人</view>
-										<view class="cu-tag radius sm margin-right-xs wanl-bg-blue" v-else-if="item.shop.state == 1">企業</view>
-										<view class="cu-tag radius sm margin-right-xs wanl-bg-orange" v-else-if="item.shop.state == 2">旗艦</view>
+										<view class="cu-tag radius sm margin-right-xs bg-gray" v-if="item.shop.state == 0">{{ $t('mall.product.personal') }}</view>
+										<view class="cu-tag radius sm margin-right-xs wanl-bg-blue" v-else-if="item.shop.state == 1">{{ $t('mall.product.enterprise') }}</view>
+										<view class="cu-tag radius sm margin-right-xs wanl-bg-orange" v-else-if="item.shop.state == 2">{{ $t('mall.product.flagship') }}</view>
 									</block>
 									<text>{{ item.title }}</text>
 								</view>
 								<view class="goods-tag">
-									<view class="cu-tag radius sm line-red" v-if="item.shop && item.shop.isself == 1">官方保障</view>
-									<view class="cu-tag radius sm line-gray" v-if="item.isLive">直播</view>
+									<view class="cu-tag radius sm line-red" v-if="item.shop && item.shop.isself == 1">{{ $t('mall.product.officialGuarantee') }}</view>
+									<view class="cu-tag radius sm line-gray" v-if="item.isLive">{{ $t('mall.product.live') }}</view>
 								</view>
 								<view class="flex align-center justify-between">
 									<view class="text-red text-bold text-lg">
 										<text class="text-price">{{ item.price }}</text>
 									</view>
 									<view class="text-sm wanl-gray">
-										<text>{{ formatCount(item.comment) }} 評論</text>
+										<text>{{ formatCount(item.comment) }} {{ $t('mall.product.comments') }}</text>
 									</view>
 								</view>
 							</view>
@@ -81,18 +81,18 @@
 						<view>
 							<view class="text-cut-2">
 								<block v-if="item.shop && item.shop.isself == 1">
-									<view class="cu-tag radius margin-right-xs sm bg-red">自营</view>
+									<view class="cu-tag radius margin-right-xs sm bg-red">{{ $t('mall.product.selfOperated') }}</view>
 								</block>
 								<block v-else-if="item.shop">
-									<view class="cu-tag radius sm margin-right-xs bg-gray" v-if="item.shop.state == 0">个人</view>
-									<view class="cu-tag radius sm margin-right-xs wanl-bg-blue" v-else-if="item.shop.state == 1">企业</view>
-									<view class="cu-tag radius sm margin-right-xs wanl-bg-orange" v-else-if="item.shop.state == 2">旗舰</view>
+									<view class="cu-tag radius sm margin-right-xs bg-gray" v-if="item.shop.state == 0">{{ $t('mall.product.personal') }}</view>
+									<view class="cu-tag radius sm margin-right-xs wanl-bg-blue" v-else-if="item.shop.state == 1">{{ $t('mall.product.enterprise') }}</view>
+									<view class="cu-tag radius sm margin-right-xs wanl-bg-orange" v-else-if="item.shop.state == 2">{{ $t('mall.product.flagship') }}</view>
 								</block>
 								<text>{{ item.title }}</text>
 							</view>
 							<view class="goods-tag">
-								<view class="cu-tag radius sm line-red" v-if="item.shop && item.shop.isself == 1">官方保障</view>
-								<view class="cu-tag radius sm line-gray" v-if="item.isLive">直播</view>
+								<view class="cu-tag radius sm line-red" v-if="item.shop && item.shop.isself == 1">{{ $t('mall.product.officialGuarantee') }}</view>
+								<view class="cu-tag radius sm line-gray" v-if="item.isLive">{{ $t('mall.product.live') }}</view>
 							</view>
 						</view>
 						<view class="flex align-center justify-between">
@@ -100,8 +100,8 @@
 								<text class="text-price">{{ item.price }}</text>
 							</view>
 							<view class="text-sm wanl-gray">
-								<text class="margin-right">{{ formatCount(item.comment) }} 评论</text>
-								<text>{{ item.comment > 0 ? parseInt((item.praise / item.comment) * 100) : 0 }}% 好評</text>
+								<text class="margin-right">{{ formatCount(item.comment) }} {{ $t('mall.product.comments') }}</text>
+								<text>{{ item.comment > 0 ? parseInt((item.praise / item.comment) * 100) : 0 }}% {{ $t('mall.product.positiveRate') }}</text>
 							</view>
 						</view>
 					</view>

+ 5 - 5
components/mall/mall-sort-bar.vue

@@ -1,23 +1,23 @@
 <template>
 	<view class="sort-bar">
 		<view class="sort-item" :class="{ active: currentIndex === 0 }" @tap="onSort(0)">
-			<text>綜合</text>
+			<text>{{ $t('mall.sort.comprehensive') }}</text>
 		</view>
 		<view class="sort-item" :class="{ active: currentIndex === 1 }" @tap="onSort(1)">
-			<text>銷量</text>
+			<text>{{ $t('mall.sort.sales') }}</text>
 		</view>
 		<view class="sort-item" :class="{ active: currentIndex === 2 }" @tap="onSort(2)">
-			<text>新品</text>
+			<text>{{ $t('mall.sort.new') }}</text>
 		</view>
 		<view class="sort-item" :class="{ active: currentIndex === 3 }" @tap="onSort(3)">
-			<text>價格</text>
+			<text>{{ $t('mall.sort.price') }}</text>
 			<view class="price-arrow">
 				<text class="arrow-up" :class="{ active: priceOrder === 1 && currentIndex === 3 }">▲</text>
 				<text class="arrow-down" :class="{ active: priceOrder === 2 && currentIndex === 3 }">▼</text>
 			</view>
 		</view>
 		<view class="sort-item" @tap="$emit('filter')">
-			<text>篩選</text>
+			<text>{{ $t('mall.sort.filter') }}</text>
 			<text class="filter-icon">⚡</text>
 		</view>
 	</view>

+ 3 - 3
components/shop/shop-find.vue

@@ -1,7 +1,7 @@
 <template>
   <scroll-view class="shop-find-container" :style="{ height: windowHeight + 'px' }" scroll-y enable-back-to-top @scrolltolower="handleLower">
     <view v-if="dataList.length === 0 && status !== 'loading'" class="empty-find">
-      <text class="wanl-gray">暫無動態</text>
+      <text class="wanl-gray">{{ $t('shop.noDynamics') }}</text>
     </view>
     <view v-if="dataList.length > 0" class="find-list">
       <view class="item margin-bj" v-for="item in dataList" :key="item.id">
@@ -21,8 +21,8 @@
       </view>
     </view>
     <view class="load-more" v-if="dataList.length > 0">
-      <text v-if="status === 'loading'">加載中...</text>
-      <text v-else-if="status === 'noMore'">沒有更多了</text>
+      <text v-if="status === 'loading'">{{ $t('common.loading') }}</text>
+      <text v-else-if="status === 'noMore'">{{ $t('common.noMore') }}</text>
     </view>
   </scroll-view>
 </template>

+ 10 - 10
components/shop/shop-head.vue

@@ -12,16 +12,16 @@
       <!-- 首頁導航 -->
       <view v-if="tabbarId === 'home'" class="home">
         <view :class="{ active: headTabbarId === 'page' }" @tap="$emit('headId', 'page')">
-          <text>推薦</text>
+          <text>{{ $t('mall.recommend') }}</text>
         </view>
         <view :class="{ active: headTabbarId === 'news' }" @tap="$emit('headId', 'news')">
-          <text>新品</text>
+          <text>{{ $t('mall.sort.new') }}</text>
         </view>
       </view>
       <!-- 搜索框 -->
       <view v-else class="search round" @tap="handleSearch">
         <text class="wlIcon wlIcon-sousuo1 text-bold margin-left-bj margin-right-xs"></text>
-        <text>搜索店內商品</text>
+        <text>{{ $t('mall.searchShopGoodsInternal') }}</text>
       </view>
     </view>
     <!-- 更多操作按鈕 -->
@@ -36,7 +36,7 @@
           <view class="wanl-direct">
             <!-- 功能直連標題 -->
             <view class="menu-header" :style="{ paddingTop: headTop + 'px' }">
-              <view>功能直連</view>
+              <view>{{ $t('mall.featureLink') }}</view>
               <view @tap="hideModal">
                 <text class="wlIcon-31guanbi"></text>
               </view>
@@ -51,14 +51,14 @@
                     v-if="statistics.notice.notice + statistics.notice.order + statistics.notice.chat > 0">{{
                       statistics.notice.notice + statistics.notice.order + statistics.notice.chat }}</view>
                 </view>
-                <view class="menu-text">消息</view>
+                <view class="menu-text">{{ $t('mall.message') }}</view>
               </view>
               <!-- 首頁 -->
               <view class="menu-item" hover-class="wanl-opcity" @tap="handleNav('/pages/mall/index')">
                 <view class="badge-box">
                   <text class="wlIcon-31shouye"></text>
                 </view>
-                <view class="menu-text">首頁</view>
+                <view class="menu-text">{{ $t('mall.home') }}</view>
               </view>
               <!-- 我的 -->
               <view class="menu-item" hover-class="wanl-opcity" @tap="handleSwitchTab('/pages/mine/index')">
@@ -69,7 +69,7 @@
                     {{ statistics.order.pay + statistics.order.delive + statistics.order.receiving +
                       statistics.order.evaluate }}</view>
                 </view>
-                <view class="menu-text">我的</view>
+                <view class="menu-text">{{ $t('mall.mine') }}</view>
               </view>
               <!-- 購物車 -->
               <view class="menu-item" hover-class="wanl-opcity" @tap="handleCart">
@@ -77,21 +77,21 @@
                   <text class="wlIcon-gouwuche"></text>
                   <view class="cu-tag badge" v-if="cart.cartnum > 0">{{ cart.cartnum }}</view>
                 </view>
-                <view class="menu-text">購物車</view>
+                <view class="menu-text">{{ $t('mall.cart') }}</view>
               </view>
               <!-- 服務 -->
               <view class="menu-item" hover-class="wanl-opcity" @tap="handleNav('/pages/user/service')">
                 <view class="badge-box">
                   <text class="wlIcon-unie737"></text>
                 </view>
-                <view class="menu-text">服務</view>
+                <view class="menu-text">{{ $t('mine.actionSmartAssistant') }}</view>
               </view>
               <!-- 反饋 -->
               <view class="menu-item" hover-class="wanl-opcity" @tap="handleNav('/pages/account/feedback')">
                 <view class="badge-box">
                   <text class="wlIcon-xiugaioryijian"></text>
                 </view>
-                <view class="menu-text">反饋</view>
+                <view class="menu-text">{{ $t('mall.feedback') }}</view>
               </view>
             </view>
           </view>

+ 9 - 9
components/shop/shop-page.vue

@@ -4,27 +4,27 @@
       <view class="info">
         <view class="name text-cut text-bold">
           <block v-if="shopData.isself === 1">
-            <view class="cu-tag radius sm bg-red">自營</view>
+            <view class="cu-tag radius sm bg-red">{{ $t('mall.product.selfOperated') }}</view>
           </block>
           <block v-else>
-            <view class="cu-tag radius sm wanl-bg-pink" v-if="shopData.state == 0">個人</view>
-            <view class="cu-tag radius sm wanl-bg-blue" v-else-if="shopData.state == 1">企業</view>
-            <view class="cu-tag radius sm wanl-bg-orange" v-else-if="shopData.state == 2">旗艦</view>
+            <view class="cu-tag radius sm wanl-bg-pink" v-if="shopData.state == 0">{{ $t('mall.product.personal') }}</view>
+            <view class="cu-tag radius sm wanl-bg-blue" v-else-if="shopData.state == 1">{{ $t('mall.product.enterprise') }}</view>
+            <view class="cu-tag radius sm wanl-bg-orange" v-else-if="shopData.state == 2">{{ $t('mall.product.flagship') }}</view>
           </block>
           <text class="margin-left-xs"> {{ shopData.shopname }} </text>
         </view>
         <view class="exponent text-min wanl-gray-dark">
           <view>
-            <text class="margin-right-xs">店鋪粉絲</text> {{ shopData.find_user && shopData.find_user.fans || 0 }}
+            <text class="margin-right-xs">{{ $t('mall.shop.fans') }}</text> {{ shopData.find_user && shopData.find_user.fans || 0 }}
           </view>
         </view>
       </view>
       <view class="menu">
         <button v-if="shopData.isFollow === 0" class="cu-btn radius-bock text-sm bg-white" @click.stop="$emit('handleFollow')">
-          <text class="wlIcon wlIcon-31xuanze text-bold margin-right-xs"></text> 關注
+          <text class="wlIcon wlIcon-31xuanze text-bold margin-right-xs"></text> {{ $t('mall.shop.follow') }}
         </button>
         <button v-else class="cu-btn radius-bock text-sm bg-white" @click.stop="$emit('handleFollow')">
-          <text class="wlIcon wlIcon-31guanbi text-bold margin-right-xs"></text> 取消關注
+          <text class="wlIcon wlIcon-31guanbi text-bold margin-right-xs"></text> {{ $t('mall.shop.unfollow') }}
         </button>
       </view>
     </view>
@@ -41,7 +41,7 @@
           <image v-for="(img, iindex) in item.data" :key="iindex" :src="img.image" mode="widthFix" style="width:100%;" />
         </view>
         <view v-if="item.type === 'goods'" class="padding-sm">
-          <view class="text-bold margin-bottom-sm">{{ item.title || '推薦商品' }}</view>
+          <view class="text-bold margin-bottom-sm">{{ item.title || $t('mall.shop.recommendGoods') }}</view>
         </view>
         <view v-if="item.type === 'division'" class="padding-sm">
           <view class="solid-bottom"></view>
@@ -50,7 +50,7 @@
       </view>
     </view>
     <view v-else class="empty-page">
-      <text class="wanl-gray">店鋪正在裝修中...</text>
+      <text class="wanl-gray">{{ $t('mall.shop.decorating') }}</text>
     </view>
   </scroll-view>
 </template>

+ 7 - 7
components/shop/shop-product.vue

@@ -2,11 +2,11 @@
   <view class="shop-product-container" :style="{ height: windowHeight + 'px' }">
     <view class="shop-product-container__bar">
       <view class="list">
-        <view class="item" :class="{ active: filterIndex === 0 }" @tap="handleBarTab(0)">綜合</view>
-        <view class="item" :class="{ active: filterIndex === 1 }" @tap="handleBarTab(1)">銷量</view>
-        <view class="item" :class="{ active: filterIndex === 2 }" @tap="handleBarTab(2)">新品</view>
+        <view class="item" :class="{ active: filterIndex === 0 }" @tap="handleBarTab(0)">{{ $t('mall.sort.comprehensive') }}</view>
+        <view class="item" :class="{ active: filterIndex === 1 }" @tap="handleBarTab(1)">{{ $t('mall.sort.sales') }}</view>
+        <view class="item" :class="{ active: filterIndex === 2 }" @tap="handleBarTab(2)">{{ $t('mall.sort.new') }}</view>
         <view class="item" :class="{ active: filterIndex === 3 }" @tap="handleBarTab(3)">
-          <view>價格</view>
+          <view>{{ $t('mall.sort.price') }}</view>
           <view class="box">
             <text :class="{ active: priceOrder === 1 && filterIndex === 3 }" class="wlIcon wlIcon-sheng" />
             <text :class="{ active: priceOrder === 2 && filterIndex === 3 }" class="wlIcon wlIcon-jiang" />
@@ -22,11 +22,11 @@
       @scrolltolower="handleLower">
       <mall-product v-if="dataList.length > 0" :dataList="dataList" :dataStyle="listStyle" />
       <view v-if="dataList.length === 0 && status !== 'loading'" class="empty-list">
-        <text class="wanl-gray">暫無商品</text>
+        <text class="wanl-gray">{{ $t('mall.category.empty') }}</text>
       </view>
       <view class="load-more" v-if="dataList.length > 0">
-        <text v-if="status === 'loading'">加載中...</text>
-        <text v-else-if="status === 'noMore'">沒有更多了</text>
+        <text v-if="status === 'loading'">{{ $t('common.loading') }}</text>
+        <text v-else-if="status === 'noMore'">{{ $t('common.noMore') }}</text>
       </view>
       <view :style="{ height: tabbarHeight + 'px' }" />
     </scroll-view>

+ 122 - 1
locale/en.json

@@ -1153,5 +1153,126 @@
   "orderConfirm.fillAddress": "Please fill in shipping address",
   "orderConfirm.loadFailed": "Load failed",
   "orderConfirm.freeShipping": "Free Shipping",
-  "orderConfirm.discount": "% off"
+  "orderConfirm.discount": "% off",
+  "mall.searchPlaceholder": "Search products",
+  "mall.recommend": "Recommend",
+  "mall.sort.comprehensive": "Comprehensive",
+  "mall.sort.sales": "Sales",
+  "mall.sort.new": "New",
+  "mall.sort.price": "Price",
+  "mall.sort.filter": "Filter",
+  "mall.product.selfOperated": "Self-operated",
+  "mall.product.personal": "Personal",
+  "mall.product.enterprise": "Enterprise",
+  "mall.product.flagship": "Flagship",
+  "mall.product.officialGuarantee": "Official Guarantee",
+  "mall.product.live": "Live",
+  "mall.product.comments": "Comments",
+  "mall.product.positiveRate": "Positive",
+  "mall.category.recommend": "Category Recommend",
+  "mall.category.empty": "No products yet",
+  "common.loading": "Loading...",
+  "common.noMore": "No more",
+  "common.empty": "No content yet",
+  "mall.category.label": "Category",
+  "product.noResults": "No results found",
+  "product.guessYouLike": "Guess You Like",
+  "product.brand": "Brand",
+  "product.priceRange": "Price Range",
+  "product.minPrice": "Min Price",
+  "product.maxPrice": "Max Price",
+  "common.reset": "Reset",
+  "common.confirm": "Confirm",
+  "mall.currentCategory": "Current Category",
+  "mall.searchShopGoods": "Search Shop Goods",
+  "mall.noGoodsInCategory": "No goods in this category",
+  "mall.noGoodsInShop": "No goods in this shop",
+  "mall.searchShopGoodsInternal": "Search Shop Goods",
+  "shop.noDynamics": "No dynamics yet",
+  "mall.shop.fans": "Shop Fans",
+  "mall.shop.follow": "Follow",
+  "mall.shop.unfollow": "Unfollow",
+  "mall.shop.recommendGoods": "Recommend Goods",
+  "mall.shop.decorating": "Shop is being decorated...",
+  "mall.featureLink": "Feature Link",
+  "mall.message": "Message",
+  "mall.home": "Home",
+  "mall.mine": "Mine",
+  "mall.cart": "Cart",
+  "mall.service": "Service",
+  "mall.feedback": "Feedback",
+  "mall.shop.home": "Home",
+  "mall.shop.allGoods": "All Goods",
+  "mall.shop.discover": "Discover",
+  "mall.shop.category": "Category",
+  "mall.shop.customerService": "Customer Service",
+  "mall.shop.loadFailed": "Failed to load shop",
+  "mall.shop.followFailed": "Failed to follow",
+  "mall.fans": "Fans",
+  "mall.shop.shopIntro": "Shop Introduction",
+  "mall.comment.goodRate": "Good Rate",
+  "mall.comment.all": "All",
+  "mall.comment.good": "Good",
+  "mall.comment.pertinent": "Neutral",
+  "mall.comment.poor": "Poor",
+  "mall.comment.withImage": "With Image",
+  "mall.comment.anonymous": "Anonymous",
+  "mall.comment.spec": "Spec",
+  "mall.moreSpecs": "More Specs Available",
+  "mall.brandSpec": "Brand, Specs, etc...",
+  "mall.viewAll": "View All",
+  "mall.selectAllGoods": "All Products",
+  "mall.selectCompleteSpec": "Please select complete specs",
+  "mall.selectProductSpec": "Please select product specs",
+  "mall.collected": "Collected",
+  "mall.collect": "Collect",
+  "mall.logistics": "Logistics",
+  "mall.shopRecommend": "Shop Recommend",
+  "mall.productDetail": "Product Detail",
+  "mall.addToCart": "Add to Cart",
+  "mall.buyNow": "Buy Now",
+  "mall.addedToCart": "Added to Cart",
+  "mall.collectFailed": "Failed to collect",
+  "mall.marketPrice": "Market Price",
+  "mall.monthlySales": "Monthly Sales",
+  "mall.coupon": "Coupon",
+  "mall.select": "Select",
+  "mall.selected": "Selected",
+  "mall.params": "Params",
+  "mall.evaluate": "Evaluate",
+  "mall.enterShop": "Enter Shop",
+  "mall.productDesc": "Product Description",
+  "mall.sellerService": "Seller Service",
+  "mall.productParams": "Product Params",
+  "mall.brand": "Brand",
+  "mall.basicService": "Basic Service Guarantee",
+  "mall.stock": "Stock",
+  "mall.quantity": "pcs",
+  "mall.buyQuantity": "Buy Quantity",
+  "mall.goodsSoldOut": "Sold Out",
+  "mall.low": "Low",
+  "mall.high": "High",
+  "mall.goods": "Goods",
+  "mall.detail": "Detail",
+  "mall.fullReduction": "Save {1} on {0}",
+  "mall.discount": "{0}% OFF",
+  "mall.fullDiscount": "{1}% OFF on {0}",
+  "mall.freeShipping": "Free Shipping",
+  "mall.freeShippingFull": "Free Shipping on {0}",
+  "mall.remain": "Remain",
+  "mall.limitPerPerson": "Limit per Person",
+  "mall.getNow": "Get Now",
+  "mall.maxStock": "Max {0} pcs",
+  "mall.discountSuffix": "% OFF",
+  "mall.receiveSuccess": "Received Successfully",
+  "mine.couponCenter": "Coupon Center",
+  "mine.receiveCoupon": "Receive Coupons",
+  "mine.myCoupon": "MyCoupons",
+  "mine.followShop": "Followed Shops",
+  "mine.footprint": "Footprint",
+  "order.pendingPayment": "PendingPayment",
+  "order.pendingShipment": "PendingShipment",
+  "order.pendingReceipt": "PendingReceipt",
+  "order.pendingReview": "PendingReview",
+  "order.refundAfterSales": "RefundAfterSales"
 }

+ 122 - 1
locale/zh-Hans.json

@@ -1126,5 +1126,126 @@
   "orderConfirm.fillAddress": "请填写收货地址",
   "orderConfirm.loadFailed": "加载失败",
   "orderConfirm.freeShipping": "包邮",
-  "orderConfirm.discount": "折"
+  "orderConfirm.discount": "折",
+  "mall.searchPlaceholder": "搜索商品",
+  "mall.recommend": "推荐",
+  "mall.sort.comprehensive": "综合",
+  "mall.sort.sales": "销量",
+  "mall.sort.new": "新品",
+  "mall.sort.price": "价格",
+  "mall.sort.filter": "筛选",
+  "mall.product.selfOperated": "自营",
+  "mall.product.personal": "个人",
+  "mall.product.enterprise": "企业",
+  "mall.product.flagship": "旗舰",
+  "mall.product.officialGuarantee": "官方保障",
+  "mall.product.live": "直播",
+  "mall.product.comments": "评论",
+  "mall.product.positiveRate": "好评",
+  "mall.category.recommend": "分类推荐",
+  "mall.category.empty": "暂无商品",
+  "common.loading": "加载中...",
+  "common.noMore": "没有更多了",
+  "common.empty": "暂无内容",
+  "mall.category.label": "分类",
+  "product.noResults": "没有找到相关商品",
+  "product.guessYouLike": "猜你喜欢",
+  "product.brand": "品牌",
+  "product.priceRange": "价格区间",
+  "product.minPrice": "最低价",
+  "product.maxPrice": "最高价",
+  "common.reset": "重置",
+  "common.confirm": "确认",
+  "mall.currentCategory": "当前分类",
+  "mall.searchShopGoods": "搜索店铺商品",
+  "mall.noGoodsInCategory": "该分类下暂无商品",
+  "mall.noGoodsInShop": "该店铺暂无商品",
+  "mall.searchShopGoodsInternal": "搜索店内商品",
+  "shop.noDynamics": "暂无动态",
+  "mall.shop.fans": "店铺粉丝",
+  "mall.shop.follow": "关注",
+  "mall.shop.unfollow": "取消关注",
+  "mall.shop.recommendGoods": "推荐商品",
+  "mall.shop.decorating": "店铺正在装修中...",
+  "mall.featureLink": "功能直连",
+  "mall.message": "消息",
+  "mall.home": "首页",
+  "mall.mine": "我的",
+  "mall.cart": "购物车",
+  "mall.feedback": "反馈",
+  "mall.shop.home": "主页",
+  "mall.shop.allGoods": "全部宝贝",
+  "mall.shop.discover": "发现",
+  "mall.shop.category": "分类",
+  "mall.shop.customerService": "客服",
+  "mall.shop.loadFailed": "加载店铺失败",
+  "mall.shop.followFailed": "关注操作失败",
+  "mall.fans": "粉丝",
+  "mall.shop.shopIntro": "店铺简介",
+  "mall.comment.goodRate": "好评率",
+  "mall.comment.all": "全部",
+  "mall.comment.good": "好评",
+  "mall.comment.pertinent": "中评",
+  "mall.comment.poor": "差评",
+  "mall.comment.withImage": "有图",
+  "mall.comment.anonymous": "匿名",
+  "mall.comment.spec": "规格",
+  "mall.moreSpecs": "更多规格可选",
+  "mall.brandSpec": "品牌、规格等...",
+  "mall.viewAll": "查看全部",
+  "mall.selectAllGoods": "全部商品",
+  "mall.selectCompleteSpec": "请选择完整规格",
+  "mall.selectProductSpec": "请选择商品规格",
+  "mall.collected": "已收藏",
+  "mall.collect": "收藏",
+  "mall.logistics": "物流服务",
+  "mall.shopRecommend": "店铺推荐",
+  "mall.productDetail": "商品详情",
+  "mall.addToCart": "加入购物车",
+  "mall.buyNow": "立即购买",
+  "mall.addedToCart": "已加入购物车",
+  "mall.collectFailed": "收藏操作失败",
+  "mall.marketPrice": "市场价",
+  "mall.monthlySales": "月销量",
+  "mall.coupon": "优惠券",
+  "mall.select": "选择",
+  "mall.selected": "已选",
+  "mall.params": "参数",
+  "mall.evaluate": "评价",
+  "mall.enterShop": "进店逛逛",
+  "mall.productDesc": "产品描述",
+  "mall.sellerService": "卖家服务",
+  "mall.productParams": "产品参数",
+  "mall.brand": "品牌",
+  "mall.basicService": "基础服务保障",
+  "mall.stock": "库存",
+  "mall.quantity": "件",
+  "mall.buyQuantity": "购买数量",
+  "mall.goodsSoldOut": "商品已售罄",
+  "mall.low": "低",
+  "mall.high": "高",
+  "mall.goods": "商品",
+  "mall.detail": "详情",
+  "mall.fullReduction": "满{0}减{1}",
+  "mall.discount": "{0}折",
+  "mall.fullDiscount": "满{0}打{1}折",
+  "mall.freeShipping": "包邮",
+  "mall.freeShippingFull": "满{0}包邮",
+  "mall.remain": "剩余",
+  "mall.limitPerPerson": "每人限领",
+  "mall.getNow": "立即领取",
+  "mall.service": "服务",
+  "mall.maxStock": "最多{0}件",
+  "mall.discountSuffix": "折",
+  "mall.receiveSuccess": "领取成功",
+  "mine.couponCenter": "领券中心",
+  "mine.receiveCoupon": "领取优惠券",
+  "mine.myCoupon": "我的优惠券",
+  "mine.followShop": "关注店铺",
+  "mine.footprint": "足迹",
+  "order.pendingPayment": "待付款",
+  "order.pendingShipment": "待发货",
+  "order.pendingReceipt": "待收货",
+  "order.pendingReview": "待评价",
+  "order.refundAfterSales": "退款/售后"
 }

+ 122 - 1
locale/zh-Hant.json

@@ -1179,5 +1179,126 @@
   "orderConfirm.fillAddress": "請填寫收貨地址",
   "orderConfirm.loadFailed": "加載失敗",
   "orderConfirm.freeShipping": "包郵",
-  "orderConfirm.discount": "折"
+  "orderConfirm.discount": "折",
+  "mall.searchPlaceholder": "搜索商品",
+  "mall.recommend": "推薦",
+  "mall.sort.comprehensive": "綜合",
+  "mall.sort.sales": "銷量",
+  "mall.sort.new": "新品",
+  "mall.sort.price": "價格",
+  "mall.sort.filter": "篩選",
+  "mall.product.selfOperated": "自營",
+  "mall.product.personal": "個人",
+  "mall.product.enterprise": "企業",
+  "mall.product.flagship": "旗艦",
+  "mall.product.officialGuarantee": "官方保障",
+  "mall.product.live": "直播",
+  "mall.product.comments": "評論",
+  "mall.product.positiveRate": "好評",
+  "mall.category.recommend": "分類推薦",
+  "mall.category.empty": "暫無商品",
+  "common.loading": "加載中...",
+  "common.noMore": "沒有更多了",
+  "common.empty": "暫無內容",
+  "mall.category.label": "分類",
+  "product.noResults": "沒有找到相關商品",
+  "product.guessYouLike": "猜你喜歡",
+  "product.brand": "品牌",
+  "product.priceRange": "價格區間",
+  "product.minPrice": "最低價",
+  "product.maxPrice": "最高價",
+  "common.reset": "重置",
+  "common.confirm": "確認",
+  "mall.currentCategory": "當前分類",
+  "mall.searchShopGoods": "搜索店鋪商品",
+  "mall.noGoodsInCategory": "該分類下暫無商品",
+  "mall.noGoodsInShop": "該店鋪暫無商品",
+  "mall.searchShopGoodsInternal": "搜索店內商品",
+  "shop.noDynamics": "暫無動態",
+  "mall.shop.fans": "店鋪粉絲",
+  "mall.shop.follow": "關注",
+  "mall.shop.unfollow": "取消關注",
+  "mall.shop.recommendGoods": "推薦商品",
+  "mall.shop.decorating": "店鋪正在裝修中...",
+  "mall.featureLink": "功能直連",
+  "mall.message": "消息",
+  "mall.home": "首頁",
+  "mall.mine": "我的",
+  "mall.cart": "購物車",
+  "mall.service": "服務",
+  "mall.feedback": "反饋",
+  "mall.shop.home": "主頁",
+  "mall.shop.allGoods": "全部寶貝",
+  "mall.shop.discover": "發現",
+  "mall.shop.category": "分類",
+  "mall.shop.customerService": "客服",
+  "mall.shop.loadFailed": "加載店鋪失敗",
+  "mall.shop.followFailed": "關注操作失敗",
+  "mall.fans": "粉絲",
+  "mall.shop.shopIntro": "店鋪簡介",
+  "mall.comment.goodRate": "好評率",
+  "mall.comment.all": "全部",
+  "mall.comment.good": "好評",
+  "mall.comment.pertinent": "中評",
+  "mall.comment.poor": "差評",
+  "mall.comment.withImage": "有圖",
+  "mall.comment.anonymous": "匿名",
+  "mall.comment.spec": "規格",
+  "mall.moreSpecs": "更多規格可選",
+  "mall.brandSpec": "品牌、規格等...",
+  "mall.viewAll": "查看全部",
+  "mall.selectAllGoods": "全部商品",
+  "mall.selectCompleteSpec": "請選擇完整規格",
+  "mall.selectProductSpec": "請選擇商品規格",
+  "mall.collected": "已收藏",
+  "mall.collect": "收藏",
+  "mall.logistics": "物流服務",
+  "mall.shopRecommend": "店鋪推薦",
+  "mall.productDetail": "商品詳情",
+  "mall.addToCart": "加入購物車",
+  "mall.buyNow": "立即購買",
+  "mall.addedToCart": "已加入購物車",
+  "mall.collectFailed": "收藏操作失敗",
+  "mall.marketPrice": "市場價",
+  "mall.monthlySales": "月銷量",
+  "mall.coupon": "優惠券",
+  "mall.select": "選擇",
+  "mall.selected": "已選",
+  "mall.params": "參數",
+  "mall.evaluate": "評價",
+  "mall.enterShop": "進店逛逛",
+  "mall.productDesc": "產品描述",
+  "mall.sellerService": "賣家服務",
+  "mall.productParams": "產品參數",
+  "mall.brand": "品牌",
+  "mall.basicService": "基礎服務保障",
+  "mall.stock": "庫存",
+  "mall.quantity": "件",
+  "mall.buyQuantity": "購買數量",
+  "mall.goodsSoldOut": "商品已售罄",
+  "mall.low": "低",
+  "mall.high": "高",
+  "mall.goods": "商品",
+  "mall.detail": "詳情",
+  "mall.fullReduction": "滿{0}減{1}",
+  "mall.discount": "{0}折",
+  "mall.fullDiscount": "滿{0}打{1}折",
+  "mall.freeShipping": "包郵",
+  "mall.freeShippingFull": "滿{0}包郵",
+  "mall.remain": "剩餘",
+  "mall.limitPerPerson": "每人限領",
+  "mall.getNow": "立即領取",
+  "mall.maxStock": "最多{0}件",
+  "mall.discountSuffix": "折",
+  "mall.receiveSuccess": "領取成功",
+  "mine.couponCenter": "領券中心",
+  "mine.receiveCoupon": "領取優惠券",
+  "mine.myCoupon": "我的優惠券",
+  "mine.followShop": "關注店鋪",
+  "mine.footprint": "足跡",
+  "order.pendingPayment": "待付款",
+  "order.pendingShipment": "待發貨",
+  "order.pendingReceipt": "待收貨",
+  "order.pendingReview": "待評價",
+  "order.refundAfterSales": "退款/售後"
 }

+ 3 - 3
pages/mall/index.vue

@@ -12,7 +12,7 @@
           <text class="wlIcon wlIcon-sousuo1 search-icon"></text>
           <swiper class="search-swiper" vertical autoplay circular interval="3000">
             <swiper-item>
-              <text class="search-text">搜索商品</text>
+              <text class="search-text">{{ $t('mall.searchPlaceholder') }}</text>
             </swiper-item>
             <swiper-item v-for="item in searchModules" :key="item.keywords">
               <text class="search-text">{{ item.keywords }}</text>
@@ -29,7 +29,7 @@
 
         <scroll-view class="tabs-scroll" scroll-x scroll-with-animation :scroll-left="scrollLeft">
           <view class="tab-item" :class="{ active: currentTabId === 'home' }" @tap="onTabSelect('home', 0)">
-            <text>推薦</text>
+            <text>{{ $t('mall.recommend') }}</text>
           </view>
 
           <view class="tab-item" v-for="(item, index) in categories" :key="item.id"
@@ -59,7 +59,7 @@
     <view class="category-modal" v-if="showCategoryPopup" :style="{ top: headHeight + 'px' }" @tap="showCategoryPopup = false">
       <view class="category-modal-content" @tap.stop="">
         <view class="category-modal-item" :class="{ active: currentTabId === 'home' }" @tap="onTabSelect('home', 0)">
-          <text>推荐</text>
+          <text>{{ $t('mall.recommend') }}</text>
         </view>
         <view class="category-modal-item" v-for="(item, index) in categories" :key="item.id"
           :class="{ active: currentTabId === item.id }" @tap="onTabSelect(item.id, index + 1)">

+ 13 - 13
pages/mine/index.vue

@@ -92,16 +92,16 @@
 							<view class="mine-assets-bar" v-if="signedIn && isSelf">
 								<view class="mine-assets-card" @tap="goCoupon">
 									<view class="mine-assets-info">
-										<text class="mine-assets-title">领券中心</text>
-										<text class="mine-assets-desc">领取优惠券 <text class="wlIcon-fanhui2 mine-assets-arrow"></text></text>
+										<text class="mine-assets-title">{{ $t('mine.couponCenter') }}</text>
+										<text class="mine-assets-desc">{{ $t('mine.receiveCoupon') }} <text class="wlIcon-fanhui2 mine-assets-arrow"></text></text>
 									</view>
 									<text class="wlIcon-31hongbao mine-assets-icon"></text>
 								</view>
 								<view class="mine-assets-divider"></view>
 								<view class="mine-assets-card" @tap="goMyCouponList">
 									<view class="mine-assets-info">
-										<text class="mine-assets-title">优惠卷</text>
-										<text class="mine-assets-desc">我的优惠卷<text class="wlIcon-fanhui2 mine-assets-arrow"></text> </text>
+										<text class="mine-assets-title">{{ $t('mall.coupon') }}</text>
+										<text class="mine-assets-desc">{{ $t('mine.myCoupon') }}<text class="wlIcon-fanhui2 mine-assets-arrow"></text> </text>
 									</view>
 									<text class="wlIcon-qianbao mine-assets-icon"></text>
 								</view>
@@ -110,19 +110,19 @@
 							<view class="mine-shortcut-bar" v-if="signedIn && isSelf">
 								<view class="mine-shortcut-item" @tap="goCart">
 									<text class="wlIcon-gouwuche mine-shortcut-icon"></text>
-									<text class="mine-shortcut-text">購物車</text>
+									<text class="mine-shortcut-text">{{ $t('mall.cart') }}</text>
 								</view>
 								<view class="mine-shortcut-item" @tap="goFavorite">
 									<text class="wlIcon-shoucang mine-shortcut-icon"></text>
-									<text class="mine-shortcut-text">收藏</text>
+									<text class="mine-shortcut-text">{{ $t('mall.collect') }}</text>
 								</view>
 								<view class="mine-shortcut-item" @tap="goFollowShop">
 									<text class="wlIcon-dianpu mine-shortcut-icon"></text>
-									<text class="mine-shortcut-text">關注店鋪</text>
+									<text class="mine-shortcut-text">{{ $t('mine.followShop') }}</text>
 								</view>
 								<view class="mine-shortcut-item" @tap="goFootprint">
 									<text class="wlIcon-zuji mine-shortcut-icon"></text>
-									<text class="mine-shortcut-text">足跡</text>
+									<text class="mine-shortcut-text">{{ $t('mine.footprint') }}</text>
 								</view>
 							</view>
 
@@ -130,31 +130,31 @@
 							<view class="mine-order-bar" v-if="signedIn && isSelf">
 								<view class="mine-order-bar-item" @tap="goOrderList(1)">
 									<text class="wlIcon-31daifukuan mine-order-bar-icon"></text>
-									<text class="mine-order-bar-text">待付款</text>
+									<text class="mine-order-bar-text">{{ $t('order.pendingPayment') }}</text>
 									<view class="cu-tag badge bg-orange mine-order-bar-badge" v-if="orderStats.pay > 0">{{ orderStats.pay
 										> 99 ? '99+' : orderStats.pay }}</view>
 								</view>
 								<view class="mine-order-bar-item" @tap="goOrderList(2)">
 									<text class="wlIcon-31daifahuo mine-order-bar-icon"></text>
-									<text class="mine-order-bar-text">待發貨</text>
+									<text class="mine-order-bar-text">{{ $t('order.pendingShipment') }}</text>
 									<view class="cu-tag badge bg-orange mine-order-bar-badge" v-if="orderStats.delive > 0">{{
 										orderStats.delive > 99 ? '99+' : orderStats.delive }}</view>
 								</view>
 								<view class="mine-order-bar-item" @tap="goOrderList(3)">
 									<text class="wlIcon-31daishouhuo mine-order-bar-icon"></text>
-									<text class="mine-order-bar-text">待收貨</text>
+									<text class="mine-order-bar-text">{{ $t('order.pendingReceipt') }}</text>
 									<view class="cu-tag badge bg-orange mine-order-bar-badge" v-if="orderStats.receiving > 0">{{
 										orderStats.receiving > 99 ? '99+' : orderStats.receiving }}</view>
 								</view>
 								<view class="mine-order-bar-item" @tap="goOrderList(4)">
 									<text class="wlIcon-31daipingjia mine-order-bar-icon"></text>
-									<text class="mine-order-bar-text">待評價</text>
+									<text class="mine-order-bar-text">{{ $t('order.pendingReview') }}</text>
 									<view class="cu-tag badge bg-orange mine-order-bar-badge" v-if="orderStats.evaluate > 0">{{
 										orderStats.evaluate > 99 ? '99+' : orderStats.evaluate }}</view>
 								</view>
 								<view class="mine-order-bar-item solid-left" @tap="goRefundList()">
 									<text class="wlIcon-31youhuiquan mine-order-bar-icon"></text>
-									<text class="mine-order-bar-text">退款/售後</text>
+									<text class="mine-order-bar-text">{{ $t('order.refundAfterSales') }}</text>
 									<view class="cu-tag badge bg-orange mine-order-bar-badge" v-if="orderStats.customer > 0">{{
 										orderStats.customer > 99 ? '99+' : orderStats.customer }}</view>
 								</view>

+ 10 - 10
pages/product/comment.vue

@@ -5,15 +5,15 @@
     <view class="wanl-goods-comment">
       <view class="padding-bj bg-white margin-bottom-bj head">
         <view class="padding-bottom-bj solid-bottom">
-          好評率
+          {{ $t('mall.comment.goodRate') }}
           <text class="margin-left-xs wanl-orange">{{ statisticsData.rate }}%</text>
         </view>
         <view>
-          <view @tap="onTag('')" class="cu-tag round" :class="{ active: tag === '' }">全部 ({{ statisticsData.total }})</view>
-          <view @tap="onTag('good')" class="cu-tag round" :class="{ active: tag === 'good' }">好評 ({{ statisticsData.good }})</view>
-          <view @tap="onTag('pertinent')" class="cu-tag round" :class="{ active: tag === 'pertinent' }">中評 ({{ statisticsData.pertinent }})</view>
-          <view @tap="onTag('poor')" class="cu-tag round" :class="{ active: tag === 'poor' }">差評 ({{ statisticsData.poor }})</view>
-          <view @tap="onTag('figure')" class="cu-tag round" :class="{ active: tag === 'figure' }">有圖 ({{ statisticsData.figure }})</view>
+          <view @tap="onTag('')" class="cu-tag round" :class="{ active: tag === '' }">{{ $t('mall.comment.all') }} ({{ statisticsData.total }})</view>
+          <view @tap="onTag('good')" class="cu-tag round" :class="{ active: tag === 'good' }">{{ $t('mall.comment.good') }} ({{ statisticsData.good }})</view>
+          <view @tap="onTag('pertinent')" class="cu-tag round" :class="{ active: tag === 'pertinent' }">{{ $t('mall.comment.pertinent') }} ({{ statisticsData.pertinent }})</view>
+          <view @tap="onTag('poor')" class="cu-tag round" :class="{ active: tag === 'poor' }">{{ $t('mall.comment.poor') }} ({{ statisticsData.poor }})</view>
+          <view @tap="onTag('figure')" class="cu-tag round" :class="{ active: tag === 'figure' }">{{ $t('mall.comment.withImage') }} ({{ statisticsData.figure }})</view>
         </view>
       </view>
       <view class="list padding-bj radius-bock" v-for="item in listData" :key="item.id">
@@ -22,7 +22,7 @@
             <view class="cu-avatar round margin-right-xs"
               :style="{ backgroundImage: 'url(' + (item.user && item.user.avatar || '') + ')' }"></view>
             <view class="text-sm">
-              <view>{{ (item.user && item.user.nickname) || '匿名' }}</view>
+              <view>{{ (item.user && item.user.nickname) || $t('mall.comment.anonymous') }}</view>
               <view class="text-gray">{{ item.createtime || '' }}</view>
             </view>
           </view>
@@ -33,7 +33,7 @@
         </view>
         <view class="details">
           <view class="margin-bottom-sm">{{ item.content }}</view>
-          <view class="text-gray text-sm">規格 {{ item.suk }}</view>
+          <view class="text-gray text-sm">{{ $t('mall.comment.spec') }} {{ item.suk }}</view>
         </view>
         <view class="grid flex-sub grid-square"
           :class="[item.images && item.images.length > 3 ? 'col-3' : 'col-' + (item.images ? item.images.length : 0)]"
@@ -44,8 +44,8 @@
         </view>
       </view>
       <view class="load-more" v-if="listData.length > 0">
-        <text v-if="status === 'loading'">加載中...</text>
-        <text v-else-if="status === 'noMore'">沒有更多了</text>
+        <text v-if="status === 'loading'">{{ $t('common.loading') }}</text>
+        <text v-else-if="status === 'noMore'">{{ $t('common.noMore') }}</text>
       </view>
     </view>
   </view>

+ 115 - 99
pages/product/goods.vue

@@ -16,7 +16,7 @@
         <view class="search-form round" @tap="goSearch">
           <text class="wlIcon wlIcon-sousuo1 text-bold"></text>
           <swiper class="search-swiper placeholder" vertical autoplay circular interval="3000">
-            <swiper-item>搜索商品</swiper-item>
+            <swiper-item>{{ $t('mall.searchPlaceholder') }}</swiper-item>
           </swiper>
         </view>
         <!-- 消息中心 -->
@@ -58,19 +58,19 @@
           </view>
           <!-- 市場價 -->
           <view class="text-sm wanl-gray text-dec">
-            市場價
+            {{ $t('mall.marketPrice') }}
             <text class="text-price margin-left-xs">{{ goodsData.market_price || '0.00' }}</text>
           </view>
         </view>
         <!-- 收藏 -->
         <view class="follow wanl-black" v-if="goodsData.follow" @tap="onFollow">
           <text class="wlIcon wlIcon-yiguanzhu1 text-red"></text>
-          <text class="text-xs">已收藏</text>
+          <text class="text-xs">{{ $t('mall.collected') }}</text>
         </view>
         <!-- 收藏商品 -->
         <view class="follow wanl-black" v-else @tap="onFollow">
           <text class="wlIcon wlIcon-gerenguanzhu"></text>
-          <text class="text-xs">收藏</text>
+          <text class="text-xs">{{ $t('mall.collect') }}</text>
         </view>
       </view>
       <!-- 信息行 -->
@@ -80,11 +80,11 @@
           {{ goodsData.views || 0 }}
         </view>
         <view class="wanl-gray">
-          運費
+          {{ $t('orderConfirm.freight') }}
           <text class="text-price">{{ (goodsData.freight && goodsData.freight.price) || '0.00' }}</text>
         </view>
         <view class="wanl-gray">
-          月銷量
+          {{ $t('mall.monthlySales') }}
           <text class="margin-left-xs">{{ goodsData.sales || 0 }}</text>
         </view>
       </view>
@@ -93,20 +93,21 @@
     <!-- 优惠券 -->
     <view class="promotion text-sm" v-if="goodsData.coupon && goodsData.coupon.length > 0">
       <view class="item" @tap="showModal('coupon')">
-        <view class="label wanl-gray">優惠券</view>
+        <view class="label wanl-gray">{{ $t('orderConfirm.coupon') }}</view>
         <view class="conten flex">
           <view class="wanl-ticket text-sm" v-for="(item, index) in goodsData.coupon" :key="index" v-if="index < 2">
             <block v-if="item.type === 'reduction' || (item.type === 'vip' && item.usertype === 'reduction')">
               <view class="ticket-price">HKD{{ Number(item.price) }}</view>
-              <view class="ticket-title">滿{{ Number(item.limit) }}減{{ Number(item.price) }}</view>
+              <view class="ticket-title">{{ $t('mall.fullReduction', [Number(item.limit), Number(item.price)]) }}</view>
             </block>
             <block v-if="item.type === 'discount' || (item.type === 'vip' && item.usertype === 'discount')">
-              <view class="ticket-price">{{ Number(item.discount) }}折</view>
-              <view class="ticket-title">滿{{ Number(item.limit) }}打{{ Number(item.discount) }}折</view>
+              <view class="ticket-price">{{ $t('mall.discount', [Number(item.discount)]) }}</view>
+              <view class="ticket-title">{{ $t('mall.fullDiscount', [Number(item.limit), Number(item.discount)]) }}
+              </view>
             </block>
             <block v-if="item.type === 'shipping'">
-              <view class="ticket-price">包郵</view>
-              <view class="ticket-title">滿{{ Number(item.limit) }}包郵</view>
+              <view class="ticket-price">{{ $t('orderConfirm.freeShipping') }}</view>
+              <view class="ticket-title">{{ $t('mall.freeShippingFull', [Number(item.limit)]) }}</view>
             </block>
           </view>
         </view>
@@ -120,22 +121,22 @@
     <view class="choice margin-bottom-bj padding-bj text-sm bg-white">
       <view class="commodity margin-bottom-bj" @tap="onSelectSku">
         <view class="opt">
-          <view class="title wanl-gray">選擇</view>
+          <view class="title wanl-gray">{{ $t('mall.select') }}</view>
           <view class="option">
             <view class="selected">
               <view v-if="canCount">
-                请選擇
+                {{ $t('orderConfirm.select') }}
                 <text class="margin-lr-xs" v-for="(item, index) in goodsData.spu" :key="item.id">{{ item.name }}</text>
               </view>
               <view v-else>
-                <text class="margin-right-bj">已選</text>
+                <text class="margin-right-bj">{{ $t('mall.selected') }}</text>
                 <text class="margin-right-xs" v-for="(name, key) in selectArr" :key="key">{{ name }}</text>
               </view>
             </view>
             <view class="option-list">
               <view v-for="(item, index) in goodsData.spu" :key="item.id">
                 <text class="cu-tag" v-if="index === 0" v-for="tag in item.item" :key="tag.name">{{ tag.name }}</text>
-                <text class="cu-tag" v-if="index === 0">更多規格可選</text>
+                <!-- <text class="cu-tag" v-if="index === 0">{{ $t('mall.moreSpecs') }}</text> -->
               </view>
             </view>
           </view>
@@ -145,7 +146,7 @@
       <view class="commodity" @tap="showModal('service')"
         v-if="goodsData.shop && goodsData.shop.service_ids && goodsData.shop.service_ids.length">
         <view class="opt">
-          <view class="title wanl-gray text-sm">智能小蜜</view>
+          <view class="title wanl-gray text-sm">{{ $t('mall.service') }}</view>
           <view class="option">
             <view class="selected">
               <block v-for="(item, index) in goodsData.shop.service_ids" :key="item.id" v-if="index <= 2">
@@ -163,9 +164,9 @@
     <view class="choice margin-bottom-bj padding-bj text-sm bg-white">
       <view class="commodity" @tap="showModal('attribute')">
         <view class="opt">
-          <view class="title wanl-gray text-sm">參數</view>
+          <view class="title wanl-gray text-sm">{{ $t('mall.params') }}</view>
           <view class="option">
-            <view class="selected"><text>品牌、規格等...</text></view>
+            <view class="selected"><text>{{ $t('mall.brandSpec') }}</text></view>
           </view>
         </view>
         <view class="text-min wanl-gray"><text class="wlIcon wlIcon-fanhui2"></text></view>
@@ -175,18 +176,23 @@
     <!-- 评论 -->
     <view class="comment margin-bottom-bj padding-bj bg-white" id="evaluate">
       <view class="head" @tap="goComment('good')">
-        <view>評價({{ goodsData.comment || 0 }})</view>
+        <view>{{ $t('mall.evaluate') }}({{ goodsData.comment || 0 }})</view>
         <view class="wanl-orange">
-          {{ goodsData.comment > 0 ? parseInt((goodsData.praise / goodsData.comment) * 100) : 0 }}%好評率
+          {{ goodsData.comment > 0 ? parseInt((goodsData.praise / goodsData.comment) * 100) : 0 }}%{{
+            $t('mall.comment.goodRate') }}
           <text class="wlIcon wlIcon-fanhui2 margin-left-xs"></text>
         </view>
       </view>
       <view class="label margin-bottom padding-bottom solid-bottom">
-        <view @tap="goComment('good')" class="cu-tag round">好評 ({{ goodsData.praise || 0 }})</view>
-        <view @tap="goComment('pertinent')" class="cu-tag round">中評({{ goodsData.moderate || 0 }})</view>
-        <view @tap="goComment('poor')" class="cu-tag round">差評 ({{ goodsData.negative || 0 }})</view>
-        <view @tap="goComment('figure')" class="cu-tag round">有圖 ({{ (goodsData.comment_list &&
-          goodsData.comment_list.figure) || 0 }})</view>
+        <view @tap="goComment('good')" class="cu-tag round">{{ $t('mall.comment.good') }} ({{ goodsData.praise || 0 }})
+        </view>
+        <view @tap="goComment('pertinent')" class="cu-tag round">{{ $t('mall.comment.pertinent') }} ( {{
+          goodsData.moderate || 0 }})</view>
+        <view @tap="goComment('poor')" class="cu-tag round">{{ $t('mall.comment.poor') }} ({{ goodsData.negative || 0
+          }})</view>
+        <view @tap="goComment('figure')" class="cu-tag round">{{ $t('mall.comment.withImage') }} ({{
+          (goodsData.comment_list &&
+            goodsData.comment_list.figure) || 0 }})</view>
       </view>
       <view class="user" v-for="(item, index) in (goodsData.comment_list && goodsData.comment_list.data || [])"
         :key="item.id" @tap="goComment('')">
@@ -194,12 +200,13 @@
           <view class="avatar">
             <view class="cu-avatar sm round margin-right-xs"
               :style="{ backgroundImage: 'url(' + (item.user && item.user.avatar || '') + ')' }"></view>
-            <view class="text-sm wanl-gray">{{ (item.user && item.user.nickname) || '匿名' }}</view>
+            <view class="text-sm wanl-gray">{{ (item.user && item.user.nickname) || $t('mall.comment.anonymous') }}
+            </view>
           </view>
         </view>
         <view class="details text-min">
           <view class="margin-bottom-sm">{{ item.content }}</view>
-          <view class="wanl-gray">規格:{{ item.suk }}</view>
+          <view class="wanl-gray">{{ $t('mall.comment.spec') }}:{{ item.suk }}</view>
         </view>
         <view class="grid flex-sub grid-square"
           :class="[item.images && item.images.length > 3 ? 'col-3' : 'col-' + (item.images ? item.images.length : 0)]"
@@ -209,7 +216,7 @@
         </view>
       </view>
       <view class="more" @tap="goComment('')">
-        <text class="wanl-gray text-sm">查看全部</text>
+        <text class="wanl-gray text-sm">{{ $t('mall.viewAll') }}</text>
         <text class="wlIcon wlIcon-fanhui4 margin-left-xs"></text>
       </view>
     </view>
@@ -221,32 +228,34 @@
           :style="{ backgroundImage: 'url(' + (goodsData.shop.avatar || '') + ')' }"></view>
         <view class="shopname">
           <view class="text-df text-cut" style="width: 300rpx;">{{ goodsData.shop.shopname }}</view>
-          <view class="wanl-gray text-min">{{ (goodsData.shop.find_user && goodsData.shop.find_user.fans) || 0 }} 粉絲
+          <view class="wanl-gray text-min">{{ (goodsData.shop.find_user && goodsData.shop.find_user.fans) || 0 }} {{
+            $t('mall.fans') }}
           </view>
         </view>
         <view class="bnt">
-          <button class="cu-btn round line-orange margin-right-sm" @tap="onShopGoods">全部商品</button>
-          <button class="cu-btn round bg-gradual-orange" @tap="onShop">進店逛逛</button>
+          <button class="cu-btn round line-orange margin-right-sm" @tap="onShopGoods">{{ $t('mall.selectAllGoods')
+            }}</button>
+          <button class="cu-btn round bg-gradual-orange" @tap="onShop">{{ $t('mall.enterShop') }}</button>
         </view>
       </view>
       <view class="quality wanl-gray text-min">
         <view>
-          產品描述
+          {{ $t('mall.productDesc') }}
           <text class="">{{ goodsData.shop.score_describe }}</text>
-          <view v-if="goodsData.shop.score_describe < 4.7" class="cu-tag round di"></view>
-          <view v-else class="cu-tag round gao"></view>
+          <view v-if="goodsData.shop.score_describe < 4.7" class="cu-tag round di">{{ $t('mall.low') }}</view>
+          <view v-else class="cu-tag round gao">{{ $t('mall.high') }}</view>
         </view>
         <view>
-          賣家服務
+          {{ $t('mall.sellerService') }}
           <text class="wanl-orange">{{ goodsData.shop.score_service }}</text>
-          <view v-if="goodsData.shop.score_service < 4.7" class="cu-tag round di"></view>
-          <view v-else class="cu-tag round gao"></view>
+          <view v-if="goodsData.shop.score_service < 4.7" class="cu-tag round di">{{ $t('mall.low') }}</view>
+          <view v-else class="cu-tag round gao">{{ $t('mall.high') }}</view>
         </view>
         <view>
-          物流服務
+          {{ $t('mall.logistics') }}
           <text class="wanl-orange">{{ goodsData.shop.score_logistics }}</text>
-          <view v-if="goodsData.shop.score_logistics < 4.7" class="cu-tag round di"></view>
-          <view v-else class="cu-tag round gao"></view>
+          <view v-if="goodsData.shop.score_logistics < 4.7" class="cu-tag round di">{{ $t('mall.low') }}</view>
+          <view v-else class="cu-tag round gao">{{ $t('mall.high') }}</view>
         </view>
       </view>
     </view>
@@ -254,9 +263,9 @@
     <!-- 店铺推荐 -->
     <view class="shop-recom padding-bj bg-white" v-if="goodsData.shop_recommend && goodsData.shop_recommend.length">
       <view class="head">
-        <view>店鋪推薦</view>
+        <view>{{ $t('mall.shopRecommend') }}</view>
         <view class="text-sm wanl-orange" @tap="onShop">
-          查看全部
+          {{ $t('mall.viewAll') }}
           <text class="wlIcon wlIcon-fanhui2 margin-left-xs"></text>
         </view>
       </view>
@@ -272,7 +281,7 @@
     <!-- 分隔符 -->
     <view class="wanl-divider">
       <view class="divider-line"></view>
-      <text class="divider-text">商品詳情</text>
+      <text class="divider-text">{{ $t('mall.productDetail') }}</text>
       <view class="divider-line"></view>
     </view>
 
@@ -284,7 +293,7 @@
     <!-- 分隔符 -->
     <view class="wanl-divider">
       <view class="divider-line"></view>
-      <text class="divider-text">推薦商品</text>
+      <text class="divider-text">{{ $t('mall.shop.recommendGoods') }}</text>
       <view class="divider-line"></view>
     </view>
 
@@ -294,8 +303,8 @@
     </view>
 
     <view class="load-more" v-if="likeData.length > 0">
-      <text v-if="likeLoading">加載中...</text>
-      <text v-else-if="likePage >= likeLastPage">没有更多了</text>
+      <text v-if="likeLoading">{{ $t('common.loading') }}</text>
+      <text v-else-if="likePage >= likeLastPage">{{ $t('common.noMore') }}</text>
     </view>
 
     <view class="safeAreaBottom"></view>
@@ -307,7 +316,7 @@
         <view class="wanl-modal-menu cu-dialog" @tap.stop="">
           <view class="wanl-direct">
             <view class="menu-header" :style="{ paddingTop: statusBarH + 'px' }">
-              <view>功能直連</view>
+              <view>{{ $t('mall.featureLink') }}</view>
               <view @tap="hideModal">
                 <text class="wlIcon-31guanbi"></text>
               </view>
@@ -321,14 +330,14 @@
                     v-if="statistics.notice.notice + statistics.notice.order + statistics.notice.chat > 0">{{
                       statistics.notice.notice + statistics.notice.order + statistics.notice.chat }}</view>
                 </view>
-                <view class="menu-text">消息</view>
+                <view class="menu-text">{{ $t('mall.message') }}</view>
               </view>
               <!-- 首頁 -->
               <view class="menu-item" hover-class="wanl-opcity" @tap="handleNav('/pages/mall/index')">
                 <view class="badge-box">
                   <text class="wlIcon-31shouye"></text>
                 </view>
-                <view class="menu-text">首頁</view>
+                <view class="menu-text">{{ $t('mall.home') }}</view>
               </view>
               <!-- 我的 -->
               <view class="menu-item" hover-class="wanl-opcity" @tap="handleSwitchTab('/pages/mine/index')">
@@ -339,7 +348,7 @@
                     {{ statistics.order.pay + statistics.order.delive + statistics.order.receiving +
                       statistics.order.evaluate }}</view>
                 </view>
-                <view class="menu-text">我的</view>
+                <view class="menu-text">{{ $t('mall.mine') }}</view>
               </view>
               <!-- 購物車 -->
               <view class="menu-item" hover-class="wanl-opcity" @tap="goCart">
@@ -347,21 +356,21 @@
                   <text class="wlIcon-gouwuche"></text>
                   <view class="cu-tag badge" v-if="cartNum > 0">{{ cartNum }}</view>
                 </view>
-                <view class="menu-text">購物車</view>
+                <view class="menu-text">{{ $t('mall.cart') }}</view>
               </view>
               <!-- 智能小蜜 -->
               <view class="menu-item" hover-class="wanl-opcity" @tap="handleNav('/pages/user/service')">
                 <view class="badge-box">
                   <text class="wlIcon-unie737"></text>
                 </view>
-                <view class="menu-text">智能小蜜</view>
+                <view class="menu-text">{{ $t('user.smartAssistant') }}</view>
               </view>
               <!-- 反饋 -->
               <view class="menu-item" hover-class="wanl-opcity" @tap="handleNav('/pages/account/feedback')">
                 <view class="badge-box">
                   <text class="wlIcon-xiugaioryijian"></text>
                 </view>
-                <view class="menu-text">反饋</view>
+                <view class="menu-text">{{ $t('mall.feedback') }}</view>
               </view>
             </view>
           </view>
@@ -374,7 +383,7 @@
           <view class="wanl-modal">
             <view class="head padding-bj">
               <view class="content">
-                <view class="text-lg">优惠券</view>
+                <view class="text-lg">{{ $t('mall.couponTitle') }}</view>
               </view>
               <view class="close wlIcon wlIcon-31guanbi" @tap="hideModal()"></view>
             </view>
@@ -389,24 +398,24 @@
                       <text class="prices">{{ Number(coupon.price) }}</text>
                     </view>
                     <view class="cu-tag wanl-gray-dark radius text-sm bg-white">
-                      滿{{ Number(coupon.limit) }}減{{ Number(coupon.price) }}
+                      {{ $t('mall.fullReduction', [Number(coupon.limit), Number(coupon.price)]) }}
                     </view>
                   </block>
                   <block v-if="coupon.type === 'discount' || (coupon.type === 'vip' && coupon.usertype === 'discount')">
                     <view class="colour">
                       <text class="prices">{{ Number(coupon.discount) }}</text>
-                      <text class="discount"></text>
+                      <text class="discount">{{ $t('mall.discountSuffix') }}</text>
                     </view>
                     <view class="cu-tag wanl-gray-dark radius text-sm bg-white">
-                      滿{{ Number(coupon.limit) }}打{{ Number(coupon.discount) }}折
+                      {{ $t('mall.fullDiscount', [Number(coupon.limit), Number(coupon.discount)]) }}
                     </view>
                   </block>
                   <block v-if="coupon.type === 'shipping'">
                     <view class="colour">
-                      <text class="prices">包郵</text>
+                      <text class="prices">{{ $t('orderConfirm.freeShipping') }}</text>
                     </view>
                     <view class="cu-tag wanl-gray-dark radius text-sm bg-white">
-                      滿{{ Number(coupon.limit) }}包郵
+                      {{ $t('mall.freeShippingFull', [Number(coupon.limit)]) }}
                     </view>
                   </block>
                 </view>
@@ -418,21 +427,22 @@
                   <view class="content text-min">
                     <view class="wanl-gray">
                       <view v-if="coupon.grant != '-1'">
-                        <text class="wlIcon wlIcon-dot"></text>剩餘 {{ coupon.surplus }}
+                        <text class="wlIcon wlIcon-dot"></text>{{ $t('mall.remain') }} {{ coupon.surplus }}
                       </view>
                       <view v-if="coupon.drawlimit != 0">
-                        <text class="wlIcon wlIcon-dot"></text>每人限領 {{ coupon.drawlimit }}
+                        <text class="wlIcon wlIcon-dot"></text>{{ $t('mall.limitPerPerson') }} {{ coupon.drawlimit }}
                       </view>
                     </view>
                     <view class="cu-btn sm round" @tap="onReceive(index)" v-if="!coupon.state">
-                      <text>立即領取</text>
+                      <text>{{ $t('mall.getNow') }}</text>
                     </view>
                   </view>
                 </view>
               </view>
             </scroll-view>
             <view class="foot padding-lr-bj">
-              <button class="cu-btn bg-gradual-orange round text-bold complete" @tap="hideModal()">完成</button>
+              <button class="cu-btn bg-gradual-orange round text-bold complete" @tap="hideModal()">{{
+                $t('cart.complete') }}</button>
             </view>
           </view>
         </view>
@@ -444,12 +454,12 @@
           <view class="wanl-modal">
             <view class="head padding-bj">
               <view class="content">
-                <view class="text-lg">產品參數</view>
+                <view class="text-lg">{{ $t('mall.productParams') }}</view>
               </view>
             </view>
             <scroll-view class="scroll-y" scroll-y="true">
               <view class="table solid-bottom" v-if="goodsData.brand">
-                <view class="name wanl-gray">品牌</view>
+                <view class="name wanl-gray">{{ $t('product.brand') }}</view>
                 <view class="value">{{ goodsData.brand.name || '' }}</view>
               </view>
               <view class="table solid-bottom" v-for="(item, index) in goodsData.category_attribute" :key="index">
@@ -458,7 +468,8 @@
               </view>
             </scroll-view>
             <view class="foot padding-lr-bj">
-              <button class="cu-btn bg-gradual-orange round text-bold complete" @tap="hideModal()">完成</button>
+              <button class="cu-btn bg-gradual-orange round text-bold complete" @tap="hideModal()">{{
+                $t('cart.complete') }}</button>
             </view>
           </view>
         </view>
@@ -470,7 +481,7 @@
           <view class="wanl-modal">
             <view class="head padding-bj">
               <view class="content">
-                <view class="text-lg">基礎服務保障</view>
+                <view class="text-lg">{{ $t('mall.basicService') }}</view>
               </view>
             </view>
             <view class="listbox padding-bj">
@@ -483,7 +494,8 @@
               </view>
             </view>
             <view class="foot padding-lr-bj">
-              <button class="cu-btn bg-gradual-orange round text-bold complete" @tap="hideModal()">完成</button>
+              <button class="cu-btn bg-gradual-orange round text-bold complete" @tap="hideModal()">{{
+                $t('cart.complete') }}</button>
             </view>
           </view>
         </view>
@@ -500,15 +512,16 @@
                 <view class="text-price wanl-orange text-xl margin-bottom-xs">{{ selectSku.price ||
                   goodsData.interval_price || '0.00' }}</view>
                 <view v-if="selectArr.join('')" class="wanl-gray margin-bottom-xs">
-                  庫存 <text class="margin-lr-xs">{{ selectSku.stock || 0 }}</text> 件
+                  {{ $t('mall.stock') }} <text class="margin-lr-xs">{{ selectSku.stock || 0 }}</text> {{
+                    $t('mall.quantity') }}
                 </view>
                 <view class="text-sm">
                   <view v-if="selectArr.join('')">
-                    <text class="margin-right-bj">已選</text>
+                    <text class="margin-right-bj">{{ $t('mall.selected') }}</text>
                     <text class="margin-right-xs" v-for="(name, key) in selectArr" :key="key">{{ name }}</text>
                   </view>
                   <view v-else>
-                    请選擇
+                    {{ $t('orderConfirm.select') }}
                     <text class="wanl-gray-light" v-for="(item, index) in goodsData.spu" :key="item.id">
                       <block v-if="index !== 0">-</block>
                       {{ item.name }}
@@ -531,7 +544,7 @@
                 </view>
               </view>
               <view class="number padding-bj">
-                <view class="text-df">購買數量</view>
+                <view class="text-df">{{ $t('mall.buyQuantity') }}</view>
                 <view class="num-ctrl">
                   <view class="num-btn" @tap="changeNum(-1)">-</view>
                   <text class="num-val">{{ selectNum }}</text>
@@ -541,13 +554,14 @@
             </scroll-view>
             <view class="foot padding-lr-bj">
               <view v-if="isChoice" class="foot-single">
-                <button class="cu-btn bg-gradual-orange round text-bold complete" @tap="completeSelection">完成</button>
+                <button class="cu-btn bg-gradual-orange round text-bold complete" @tap="completeSelection">{{
+                  $t('cart.complete') }}</button>
               </view>
               <block v-else>
-                <button class="cu-btn bg-gradual-yellow round-left text-bold"
-                  @tap="submitData('addToCart', 1)">加入購物車</button>
-                <button class="cu-btn bg-gradual-orange round-right text-bold"
-                  @tap="submitData('placeOrder', 1)">立即購買</button>
+                <button class="cu-btn bg-gradual-yellow round-left text-bold" @tap="submitData('addToCart', 1)">{{
+                  $t('mall.addToCart') }}</button>
+                <button class="cu-btn bg-gradual-orange round-right text-bold" @tap="submitData('placeOrder', 1)">{{
+                  $t('mall.buyNow') }}</button>
               </block>
             </view>
           </view>
@@ -560,25 +574,27 @@
       <!-- 店铺 -->
       <view class="action" @tap="onShop">
         <view class="wlIcon-dianpu1 wanl-orange"></view>
-        店鋪
+        {{ $t('complaint.types.shop') }}
       </view>
       <view class="action" @tap="goCart">
         <view class="wlIcon-gouwuche">
           <view class="cu-tag badge" v-if="cartNum > 0">{{ cartNum }}</view>
         </view>
-        購物車
+        {{ $t('mall.cart') }}
       </view>
       <view class="action"
         @tap="goChat(goodsData.shop_id, { id: goodsData.id, title: goodsData.title, image: goodsData.image, price: goodsData.price })">
         <view class="wlIcon-kefu">
           <view class="cu-tag badge"></view>
         </view>
-        客服
+        {{ $t('mall.shop.customerService') }}
       </view>
       <!-- 购买按钮 -->
       <view class="btn-group">
-        <button class="cu-btn bg-gradual-yellow round-left" @tap="submitData('addToCart')">加入購物車</button>
-        <button class="cu-btn bg-gradual-orange round-right" @tap="submitData('placeOrder')">立即購買</button>
+        <button class="cu-btn bg-gradual-yellow round-left" @tap="submitData('addToCart')">{{ $t('mall.addToCart')
+          }}</button>
+        <button class="cu-btn bg-gradual-orange round-right" @tap="submitData('placeOrder')">{{ $t('mall.buyNow')
+          }}</button>
       </view>
     </view>
   </view>
@@ -603,10 +619,10 @@ export default {
       currentSwiper: 0,
       selectAnchor: 0,
       anchorlist: [
-        { name: '商品', top: 0 },
-        { name: '評價', top: 0 },
-        { name: '詳情', top: 0 },
-        { name: '推薦', top: 0 }
+        { name: this.$t('mall.goods'), top: 0 },
+        { name: this.$t('mall.evaluate'), top: 0 },
+        { name: this.$t('mall.detail'), top: 0 },
+        { name: this.$t('mall.recommend'), top: 0 }
       ],
       modalName: null,
       isChoice: '',
@@ -673,7 +689,7 @@ export default {
       // 檢查是否所有 SKU 都售罄
       const allSoldOut = this.goodsData.sku && this.goodsData.sku.every(sku => sku.stock <= 0)
       if (allSoldOut) {
-        uni.showToast({ title: '商品已售罄', icon: 'none' })
+        uni.showToast({ title: this.$t('mall.goodsSoldOut'), icon: 'none' })
         return
       }
       this.showModal('option')
@@ -727,7 +743,7 @@ export default {
         const res = await pullMallCouponReceive({ id: coupon.id })
         coupon.id = res.id
         coupon.state = true
-        uni.showToast({ title: res.msg || '領取成功', icon: 'none' })
+        uni.showToast({ title: res.msg || this.$t('mall.receiveSuccess'), icon: 'none' })
       } catch (e) {
         console.error('领取优惠券失败:', e)
       }
@@ -738,7 +754,7 @@ export default {
         const res = await pullMallGoodsFollow({ id: this.goodsId })
         this.goodsData.follow = res
       } catch (e) {
-        console.error('收藏操作失败:', e)
+        console.error(this.$t('mall.collectFailed'), e)
       }
     },
     async loadStock(skuId) {
@@ -805,14 +821,14 @@ export default {
       var num = this.selectNum + delta
       if (num < 1) return
       if (this.selectSku.stock && num > this.selectSku.stock) {
-        uni.showToast({ title: '最多' + this.selectSku.stock + '件', icon: 'none' })
+        uni.showToast({ title: this.$t('mall.maxStock', [this.selectSku.stock]), icon: 'none' })
         return
       }
       this.selectNum = num
     },
     completeSelection() {
       if (this.canCount) {
-        uni.showToast({ title: '請選擇完整規格', icon: 'none' })
+        uni.showToast({ title: this.$t('mall.selectCompleteSpec'), icon: 'none' })
       } else {
         this.processingData()
       }
@@ -820,7 +836,7 @@ export default {
     submitData(name, type) {
       if (type == 1) {
         if (this.canCount) {
-          uni.showToast({ title: '請選擇完整規格', icon: 'none' })
+          uni.showToast({ title: this.$t('mall.selectCompleteSpec'), icon: 'none' })
         } else {
           this.isChoice = name
           this.processingData()
@@ -829,7 +845,7 @@ export default {
         // 新增:檢查是否所有 SKU 都售罄
         const allSoldOut = this.goodsData.sku && this.goodsData.sku.every(sku => sku.stock <= 0)
         if (allSoldOut) {
-          uni.showToast({ title: '商品已售罄', icon: 'none' })
+          uni.showToast({ title: this.$t('mall.goodsSoldOut'), icon: 'none' })
           return
         }
         this.showModal('option')
@@ -839,12 +855,12 @@ export default {
     async processingData() {
       if (this.isChoice === 'addToCart') {
         if (!this.selectSku || !this.selectSku.id) {
-          uni.showToast({ title: '請選擇商品規格', icon: 'none' })
+          uni.showToast({ title: this.$t('mall.selectProductSpec'), icon: 'none' })
           return
         }
         // 新增:檢查庫存
         if (this.selectSku.stock !== undefined && this.selectSku.stock <= 0) {
-          uni.showToast({ title: '商品已售罄', icon: 'none' })
+          uni.showToast({ title: this.$t('mall.goodsSoldOut'), icon: 'none' })
           return
         }
         await this.$store.dispatch('cart/add', {
@@ -858,16 +874,16 @@ export default {
           number: this.selectNum,
           sum: parseFloat(this.selectSku.price) * this.selectNum
         })
-        uni.showToast({ title: '已加入購物車', icon: 'success' })
+        uni.showToast({ title: this.$t('mall.addedToCart'), icon: 'success' })
       } else if (this.isChoice === 'placeOrder') {
         // 新增:檢查是否選擇了規格
         if (!this.selectSku || !this.selectSku.id) {
-          uni.showToast({ title: '請選擇商品規格', icon: 'none' })
+          uni.showToast({ title: this.$t('mall.selectProductSpec'), icon: 'none' })
           return
         }
         // 新增:檢查庫存
         if (this.selectSku.stock !== undefined && this.selectSku.stock <= 0) {
-          uni.showToast({ title: '商品已售罄', icon: 'none' })
+          uni.showToast({ title: this.$t('mall.goodsSoldOut'), icon: 'none' })
           return
         }
         let goodsData = [

+ 17 - 17
pages/product/list.vue

@@ -10,12 +10,12 @@
 				<view class="head-search" @tap="goSearch">
 					<text class="wlIcon wlIcon-sousuo1 search-icon"></text>
 					<view class="search-tag" v-if="category">
-						<text>分類:{{ category }}</text>
+						<text>{{ $t('mall.category.label') }}:{{ category }}</text>
 					</view>
 					<view class="search-tag" v-else-if="params.search">
 						<text>{{ params.search }}</text>
 					</view>
-					<text v-else class="search-placeholder">搜索商品</text>
+					<text v-else class="search-placeholder">{{ $t('mall.searchPlaceholder') }}</text>
 				</view>
 				<view class="head-right" @tap="toggleStyle">
 					<text v-if="listStyle === 'col-2-20'" class="wlIcon wlIcon-liebiao2 style-icon"></text>
@@ -27,17 +27,17 @@
 		<view class="list-head-placeholder" :style="{ height: (statusBarH + 44) + 'px' }"></view>
 
 		<view class="sort-bar">
-			<view class="sort-item" :class="{ active: filterIndex === 0 }" @tap="tabClick(0)"><text>綜合</text></view>
-			<view class="sort-item" :class="{ active: filterIndex === 1 }" @tap="tabClick(1)"><text>銷量</text></view>
-			<view class="sort-item" :class="{ active: filterIndex === 2 }" @tap="tabClick(2)"><text>新品</text></view>
+			<view class="sort-item" :class="{ active: filterIndex === 0 }" @tap="tabClick(0)"><text>{{ $t('mall.sort.comprehensive') }}</text></view>
+			<view class="sort-item" :class="{ active: filterIndex === 1 }" @tap="tabClick(1)"><text>{{ $t('mall.sort.sales') }}</text></view>
+			<view class="sort-item" :class="{ active: filterIndex === 2 }" @tap="tabClick(2)"><text>{{ $t('mall.sort.new') }}</text></view>
 			<view class="sort-item" :class="{ active: filterIndex === 3 }" @tap="tabClick(3)">
-				<text>價格</text>
+				<text>{{ $t('mall.sort.price') }}</text>
 				<view class="price-arrow">
 					<text class="arrow-up" :class="{ active: priceOrder === 1 && filterIndex === 3 }">▲</text>
 					<text class="arrow-down" :class="{ active: priceOrder === 2 && filterIndex === 3 }">▼</text>
 				</view>
 			</view>
-			<view class="sort-item" @tap="showDrawer"><text>篩選</text><text class="wlIcon wlIcon-shaixuan filter-icon"></text>
+			<view class="sort-item" @tap="showDrawer"><text>{{ $t('mall.sort.filter') }}</text><text class="wlIcon wlIcon-shaixuan filter-icon"></text>
 			</view>
 		</view>
 
@@ -45,37 +45,37 @@
 			<mall-product :dataList="goodsData" :dataStyle="listStyle" />
 		</view>
 		<view class="list-empty" v-if="goodsData.length === 0 && !loading">
-			<text>沒有找到相關商品</text>
+			<text>{{ $t('product.noResults') }}</text>
 		</view>
 		<view class="list-like" v-if="goodsData.length === 0 && likeData.length > 0">
 			<view class="like-divider">
 				<view class="divider-line"></view>
-				<text class="divider-text">猜你喜歡</text>
+				<text class="divider-text">{{ $t('product.guessYouLike') }}</text>
 				<view class="divider-line"></view>
 			</view>
 			<mall-product :dataList="likeData" dataStyle="col-2-20" />
 		</view>
 		<view class="load-more" v-if="goodsData.length > 0">
-			<text v-if="loading">加載中...</text>
-			<text v-else-if="params.page >= lastPage">没有更多了</text>
+			<text v-if="loading">{{ $t('common.loading') }}</text>
+			<text v-else-if="params.page >= lastPage">{{ $t('common.noMore') }}</text>
 		</view>
 		<!-- 筛选抽屉 -->
 		<view class="drawer-mask" v-if="showRight" @tap="closeDrawer"></view>
 		<view class="drawer" :class="{ show: showRight }">
 			<scroll-view scroll-y class="drawer-scroll" :style="{ height: drawerHeight + 'px', paddingTop: statusBarH + 'px' }">
 				<view class="drawer-section" v-if="drawerData.brand.length > 0">
-					<view class="drawer-title">品牌</view>
+					<view class="drawer-title">{{ $t('product.brand') }}</view>
 					<view class="drawer-tags">
 						<text v-for="(bd, index) in drawerData.brand" :key="bd.id" :class="{ active: bd.choice }"
 							@tap="onDrawerBrand(index)">{{ bd.name }}</text>
 					</view>
 				</view>
 				<view class="drawer-section">
-					<view class="drawer-title">價格區間</view>
+					<view class="drawer-title">{{ $t('product.priceRange') }}</view>
 					<view class="drawer-price">
-						<input type="number" placeholder="最低價" v-model="drawerData.price.low" />
+						<input type="number" :placeholder="$t('product.minPrice')" v-model="drawerData.price.low" />
 						<text>—</text>
-						<input type="number" placeholder="最高價" v-model="drawerData.price.high" />
+						<input type="number" :placeholder="$t('product.maxPrice')" v-model="drawerData.price.high" />
 					</view>
 				</view>
 				<view class="drawer-section" v-for="(att, index) in drawerData.attribute" :key="att.name">
@@ -90,8 +90,8 @@
 				</view>
 			</scroll-view>
 			<view class="drawer-foot">
-				<view class="drawer-btn reset" @tap="onDrawerReset">重置</view>
-				<view class="drawer-btn confirm" @tap="onDrawerTo">確認</view>
+				<view class="drawer-btn reset" @tap="onDrawerReset">{{ $t('common.reset') }}</view>
+				<view class="drawer-btn confirm" @tap="onDrawerTo">{{ $t('common.confirm') }}</view>
 			</view>
 		</view>
 	</view>

+ 5 - 5
pages/shop/index.vue

@@ -33,25 +33,25 @@
           </view>
           <view v-else>
             <view class="wlIcon wlIcon-dianpu text-bold"></view>
-            <view>主頁</view>
+            <view>{{ $t('mall.shop.home') }}</view>
           </view>
         </view>
         <view class="action" :class="{ active: handleActive('goods') }" @tap="handleTabbar('goods')">
           <view class="wlIcon wlIcon-baobei text-bold"></view>
-          <view>全部寶貝</view>
+          <view>{{ $t('mall.shop.allGoods') }}</view>
         </view>
         <view class="action" :class="{ active: handleActive('find') }" @tap="handleTabbar('find')">
           <view class="wlIcon wlIcon-guanzhu1 text-bold"></view>
-          <view>發現</view>
+          <view>{{ $t('mall.shop.discover') }}</view>
         </view>
         <view class="action" :class="{ active: handleActive('classify') }" @tap="handleTabbar('classify')">
           <view class="wlIcon wlIcon-fenlei1 text-bold"></view>
-          <view>分類</view>
+          <view>{{ $t('mall.shop.category') }}</view>
         </view>
         <view class="action">
           <view @tap="toChat">
             <view class="wlIcon wlIcon-kefu text-bold"></view>
-            <view>客服</view>
+            <view>{{ $t('mall.shop.customerService') }}</view>
           </view>
         </view>
       </view>

+ 5 - 5
pages/shop/info.vue

@@ -7,23 +7,23 @@
 				<view class="cu-avatar round margin-right-bj" :style="{backgroundImage: 'url(' + $appKit.oss(shopData.avatar, 52, 52) + ')'}"></view>
 				<view>
 					<view class="text-df text-cut" style="width: 320rpx;">
-						<text>{{ shopData.shopname || '加載中...' }}</text>
+						<text>{{ shopData.shopname || $t('common.loading') }}</text>
 					</view>
-					<view class="wanl-gray text-min">粉絲 {{ shopData.find_user.fans }}</view>
+					<view class="wanl-gray text-min">{{ $t('mall.fans') }} {{ shopData.find_user.fans }}</view>
 					<view class="wanl-gray text-min">{{ shopData.city }}</view>
 				</view>
 			</view>
 			<view class="margin-right-bj">
 				<button v-if="shopData.isFollow === 0" class="cu-btn radius-bock text-sm" @click.stop="handleFollow">
-					<text class="wlIcon-tianjia margin-right-xs text-bold"></text>關注
+					<text class="wlIcon-tianjia margin-right-xs text-bold"></text>{{ $t('mall.shop.follow') }}
 				</button>
 				<button v-else class="cu-btn radius-bock text-sm" @click.stop="handleFollow">
-					<text class="wlIcon-31xuanze margin-right-xs text-bold"></text>已關注
+					<text class="wlIcon-31xuanze margin-right-xs text-bold"></text>{{ $t('mine.followed') }}
 				</button>
 			</view>
 		</view>
 		<view class="shop_info bg-white margin-top-bj padding-lr-bj">
-			<view class="padding-tb-bj solid-bottom">店鋪簡介</view>
+			<view class="padding-tb-bj solid-bottom">{{ $t('mall.shop.shopIntro') }}</view>
 		</view>
 		<view class="bg-white padding-bj">
 			<rich-text :nodes="shopData.bio"></rich-text>

+ 17 - 12
pages/shop/product/list.vue

@@ -1,13 +1,14 @@
 <!-- 店鋪商品列表 -->
 <template>
 	<view class="wanl-list">
-		<view class="cu-custom" :style="{height: navHeight + 'px'}">
-			<view class="cu-bar bg-bgcolor fixed" :style="{height: navHeight + 'px', paddingTop: statusBarTop + 'px'}">
+		<view class="cu-custom" :style="{ height: navHeight + 'px' }">
+			<view class="cu-bar bg-bgcolor fixed" :style="{ height: navHeight + 'px', paddingTop: statusBarTop + 'px' }">
 				<view v-if="pagesNum > 1" class="action" @tap="goBack"><text class="wlIcon-fanhui1"></text></view>
 				<view v-else class="action" @tap="goHome"><text class="wlIcon-zhuye"></text></view>
 				<view class="search-form round">
 					<text class="wlIcon-sousuo1 text-bold"></text>
-					<input @confirm="confirm" :adjust-position="false" type="text" :placeholder="category" confirm-type="search" />
+					<input @confirm="confirm" :adjust-position="false" type="text" :placeholder="category"
+						confirm-type="search" />
 				</view>
 				<view class="action" @tap="editListstyle()">
 					<text class="wlIcon-listing-jf" v-if="liststyle == 'col-2-10'"></text>
@@ -18,11 +19,13 @@
 		<view class="head" :class="{ headtop: scrollStype }">
 			<view class="cue">
 				<view class="bar">
-					<view class="item" :class="{ current: filterIndex === 0 }" @tap="tabClick(0)">綜合</view>
-					<view class="item" :class="{ current: filterIndex === 1 }" @tap="tabClick(1)">銷量</view>
-					<view class="item" :class="{ current: filterIndex === 2 }" @tap="tabClick(2)">新品</view>
+					<view class="item" :class="{ current: filterIndex === 0 }" @tap="tabClick(0)">{{ $t('mall.sort.comprehensive')
+						}}</view>
+					<view class="item" :class="{ current: filterIndex === 1 }" @tap="tabClick(1)">{{ $t('mall.sort.sales') }}
+					</view>
+					<view class="item" :class="{ current: filterIndex === 2 }" @tap="tabClick(2)">{{ $t('mall.sort.new') }}</view>
 					<view class="item" :class="{ current: filterIndex === 3 }" @tap="tabClick(3)">
-						<text>價格</text>
+						<text>{{ $t('mall.sort.price') }}</text>
 						<view class="box">
 							<text :class="{ active: priceOrder === 1 && filterIndex === 3 }" class="wlIcon-sheng"></text>
 							<text :class="{ active: priceOrder === 2 && filterIndex === 3 }" class="wlIcon-jiang"></text>
@@ -78,16 +81,16 @@ export default {
 		if (option.category_id) {
 			this.params.filter.shop_category_id = option.category_id
 			this.params.op.shop_category_id = 'FIND_IN_SET'
-			this.category = option.category_name ? '當前分類:' + option.category_name : '搜索店鋪商品'
+			this.category = option.category_name ? this.$t('mall.currentCategory') + ':' + option.category_name : this.$t('mall.searchShopGoods')
 			this.loadData()
-			this.empty = '該分類下暫無商品'
+			this.empty = this.$t('mall.noGoodsInCategory')
 		} else {
 			this.params.filter.shop_id = option.shop_id
 			this.params.op.shop_id = 'in'
-			this.category = '搜索店鋪商品'
+			this.category = this.$t('mall.searchShopGoods') 
 			this.status = 'more'
 			this.loadData()
-			this.empty = '該店鋪暫無商品'
+			this.empty = this.$t('mall.noGoodsInShop')
 		}
 	},
 	onPullDownRefresh() {
@@ -167,5 +170,7 @@ export default {
 </script>
 
 <style scoped>
-.cu-bar .search-form { background-color: #ebebeb; }
+.cu-bar .search-form {
+	background-color: #ebebeb;
+}
 </style>