提交 92efc85e 编写于 作者: R root

添加中文翻译文件

上级 43ec6a20
......@@ -7,28 +7,237 @@
* @license http://www.fecshop.com/license/
*/
return [
'fecshop' => 'zh_CN app fecshop',
'Follow Us'=> '关注我们',
'Follow us in social media'=> '在社交平台关注我们',
'Sign up for newsletter'=> '订阅邮件',
'General Links'=> '文字条款',
'Enter your email adress'=>'输入您的邮箱',
'fecshop' => 'zh_CN app fecshop',
'Follow Us' => '关注我们',
'Follow us in social media' => '在社交平台关注我们',
'Sign up for newsletter' => '订阅邮件',
'General Links' => '文字条款',
'Enter your email adress' =>'输入您的邮箱',
'Contact Us'=> '联系我们',
'FAQ'=> '常见问题',
'Return Policy'=> '退款条约',
'Privacy Policy'=> '隐私条约',
'About Us'=> '关于我们',
'My Favorite'=> '我的收藏',
'My Reviews'=> '我的评论',
'My Order'=> '我的订单',
'My Account'=> '我的账户',
'Site Map'=> '网站地图',
'Follow'=> '关注我们',
'Follow'=> '关注我们',
'Follow'=> '关注我们',
'Follow'=> '关注我们',
'Follow'=> '关注我们',
'Contact Us' => '联系我们',
'FAQ' => '常见问题',
'Return Policy' => '退款条约',
'Privacy Policy' => '隐私条约',
'About Us' => '关于我们',
'My Favorite' => '我的收藏',
'My Reviews' => '我的评论',
'My Order' => '我的订单',
'My Account' => '我的账户',
'Site Map' => '网站地图',
'Follow' => '关注我们',
'Welcome!' => '欢迎您!',
'Logout' => '退出',
'Sign In / Join Free' => '登录账户',
'My Account' => '我的账户',
'My Orders' => '我的订单',
'My Favorites' => '我的收藏',
'Product Review' => '我的评论',
'Products keyword' => '搜索产品',
'custom menu' => '自定义菜单',
'my custom menu 2' => '我的自定义菜单2',
'my custom menu 3' => '我的自定义菜单3',
'Home' => '首页',
'best seller' => '热销产品',
'featured products' => '特色产品',
'more' => '更多',
'Sort By' => '排序',
'Hot' => '销量',
'Review' => '评论',
'Favorite' => '收藏',
'New' => '上架时间',
'$ Low to High' => '¥ 价格由低到高',
'$ High to Low' => '¥ 价格由高到低',
'Refine By' => '过滤选项',
'clear all' => '清空所有过滤',
'color' => '颜色',
'size' => '尺码',
'one-color' => '单色',
'red' => '红色',
'white' => '白色',
'black' => '黑色',
'blue' => '蓝色',
'green' => '绿色',
'yellow' => '黄色',
'gray' => '灰色',
'khaki' => '黄褐色',
'ivory' => '象牙色',
'beige' => '米色',
'orange' => '橙色',
'cyan' => '青色',
'leopard' => '豹纹',
'camouflage' => '伪装色',
'silver' => '银白色',
'pink' => '粉红色',
'purple' => '紫色',
'brown' => '棕色',
'golden' => '金色',
'multicolor' => '彩色',
'white & blue' => '白 & 蓝',
'white & black' => '白 & 黑',
'price' => '产品价格',
'Newsletter' => '订阅邮件',
'All rights reserved' => '保留所有权利',
'Copyright Notice' => '版权声明',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
'Follow' => '关注我们',
];
\ No newline at end of file
......@@ -30,8 +30,11 @@ class AjaxController extends AppfrontController
$result_arr['favorite'] = false;
$result_arr['favorite_product_count'] = 0;
$product_id = Yii::$app->request->get('product_id');
$customer_name = '';
if(!Yii::$app->user->isGuest){
$identity = Yii::$app->user->identity;
$customer_name = $identity['firstname'].' '.$identity['lastname'];
$result_arr['customer_name'] = $customer_name;
$result_arr['favorite_product_count'] = $identity['favorite_product_count'] ? $identity['favorite_product_count'] : 0;
$result_arr['loginStatus'] = true;
if($product_id){
......
......@@ -417,7 +417,6 @@ address, article, aside, audio, canvas, details, figcaption, figure, footer, hea
.pro-content {
height: 496px;
margin-top: 14px;
width: 100%;
}
......@@ -433,7 +432,7 @@ address, article, aside, audio, canvas, details, figcaption, figure, footer, hea
.scrollBox {
float: right;
height: 496px;
height: 572px;
position: relative;
width: 1200px;
}
......@@ -2702,9 +2701,9 @@ color:#cc0000;
font-size: 18px;
}
.sectionBox_h{text-transform:Uppercase}
.sectionBox_h.featured{margin-top:20px 0 0 }
......@@ -36,10 +36,12 @@ $(document).ready(function(){
url:loginInfoUrl,
success:function(data, textStatus){
welcome = $('.welcome_str').val();
logoutStr = $('.logoutStr').val();
if(data.loginStatus){
str = '<span id="welcome">'+welcome+'</span>';
customer_name = data.customer_name;
str = '<span id="welcome">'+welcome+' '+customer_name+',</span>';
str += '<span id="js_isNotLogin">';
str += '<a href="'+logoutUrl+'" rel="nofollow">Logout</a>';
str += '<a href="'+logoutUrl+'" rel="nofollow">'+logoutStr+'</a>';
str += '</span>';
$(".login-text").html(str);
}
......
......@@ -17,7 +17,7 @@ if(isset($parentThis['filters']) && !empty($parentThis['filters']) && is_array($
$attrUrlStr = Yii::$service->url->category->attrValConvertUrlStr($attr);
if(is_array($filter) && !empty($filter)){
echo '<div class="filter_attr">';
echo '<div class="filter_attr_title">'.$attr.'</div>';
echo '<div class="filter_attr_title">'.Yii::$service->page->translate->__($attr).'</div>';
echo '<div class="filter_attr_info">';
foreach($filter as $item){
$val = $item['_id'];
......@@ -26,7 +26,7 @@ if(isset($parentThis['filters']) && !empty($parentThis['filters']) && is_array($
$urlInfo = Yii::$service->url->category->getFilterChooseAttrUrl($attrUrlStr,$val,'p');
$url = $urlInfo['url'];
$selected = $urlInfo['selected'] ? 'class="checked"' : '';
echo '<a '.$selected.' href="'.$url.'">'.$val.'('.$count.')</a><br/>';
echo '<a '.$selected.' href="'.$url.'">'.Yii::$service->page->translate->__($val).'('.$count.')</a><br/>';
}
}
echo '</div>';
......
......@@ -18,7 +18,7 @@ if(isset($parentThis['filter_price']) && !empty($parentThis['filter_price']) &&
$attrUrlStr = Yii::$service->url->category->attrValConvertUrlStr($attr);
if(is_array($filter) && !empty($filter)){
echo '<div class="filter_attr">';
echo '<div class="filter_attr_title">'.$attr.'</div>';
echo '<div class="filter_attr_title">'.Yii::$service->page->translate->__($attr).'</div>';
echo '<div class="filter_attr_info">';
foreach($filter as $item){
$val = $item['val'];
......
<?php if(isset($parentThis['refine_by_info']) && is_array($parentThis['refine_by_info']) && !empty($parentThis['refine_by_info'])){ ?>
<div class="filter_refine_by">
<div class="filter_attr_title">Refine By</div>
<div class="filter_attr_title"><?= Yii::$service->page->translate->__('Refine By'); ?></div>
<div class="filter_refine_by_content">
<?php foreach($parentThis['refine_by_info'] as $one){ ?>
<?php $name = $one['name']; ?>
<?php $url = $one['url']; ?>
<div><a href="<?= $url ?>"><i class="closeBtn c_tagbg"></i><span><?= $name ?></span></a></div>
<div><a href="<?= $url ?>"><i class="closeBtn c_tagbg"></i><span><?= Yii::$service->page->translate->__($name); ?></span></a></div>
<?php } ?>
</div>
</div>
......
......@@ -7,12 +7,12 @@
<?php $frontSort = $query_item['frontSort']; ?>
<?php if(is_array($frontSort) && !empty($frontSort)){ ?>
<b>Sort By:</b>
<b><?= Yii::$service->page->translate->__('Sort By'); ?>:</b>
<select class="product_sort">
<?php foreach($frontSort as $np){ ?>
<?php $selected = $np['selected'] ? 'selected="selected"' : ''; ?>
<?php $url = $np['url']; ?>
<option <?= $selected; ?> url="<?= $url; ?>" value="<?= $np['value']; ?>"><?= $np['label']; ?></option>
<option <?= $selected; ?> url="<?= $url; ?>" value="<?= $np['value']; ?>"><?= Yii::$service->page->translate->__($np['label']); ?></option>
<?php } ?>
</select>
<?php } ?>
......
......@@ -10,7 +10,7 @@
<div class="main container">
<?= Yii::$service->cms->staticblock->getStoreContentByIdentify('home-big-img','appfront') ?>
<div class="mt10">
<h4 class="sectionBox_h"><span>BEST SELLER</span><em><a href="">MORE</a></em></h4>
<h4 class="sectionBox_h best_seller"><span><?= Yii::$service->page->translate->__('best seller'); ?></span><em><a href=""><?= Yii::$service->page->translate->__('more'); ?></a></em></h4>
<div class="pro-content">
<?php
$parentThis['products'] = $bestSellerProducts;
......@@ -23,8 +23,9 @@
</div>
</div>
<div class="clear"></div>
<div class="mt10" style="margin-top:34px;">
<h4 class="sectionBox_h"><span>FEATURED PRODUCTS</span><em><a href="">MORE</a></em></h4>
<h4 class="sectionBox_h featured"><span><?= Yii::$service->page->translate->__('featured products'); ?></span><em><a href=""><?= Yii::$service->page->translate->__('more'); ?></a></em></h4>
<div class="pro-content">
<?php
$parentThis['products'] = $bestFeaturedProducts;
......
......@@ -15,6 +15,7 @@
<?php foreach($items as $item){ $i++; ?>
<?php ($i == $count) ? ($str = '') : ($str = '>') ?>
<?php $name = isset($item['name']) ? $item['name'] : ''; ?>
<?php $name = Yii::$service->page->translate->__($name); ?>
<?php $url = isset($item['url']) ? $item['url'] : ''; ?>
<?php if($name){ ?>
<?php if($url){ ?>
......
......@@ -83,7 +83,7 @@
<img src="<?= Yii::$service->image->getImgUrl('images/pp.png','appfront'); ?>" />
</div>
<div class="container">
<div id="copy">Copyright Notice &copy;2016 FecShop.com All rights reserved .</div>
<div id="copy"><?= Yii::$service->page->translate->__('Copyright Notice') ?> &copy;2016 FecShop.com <?= Yii::$service->page->translate->__('All rights reserved') ?> .</div>
</div>
</div>
</footer>
......@@ -10,6 +10,8 @@
<div id="top_nav">
<input type="hidden" class="currentBaseUrl" value="<?= $currentBaseUrl ?>" />
<input type="hidden" class="logoutUrl" value="<?= $logoutUrl ?>" />
<input type="hidden" class="logoutStr" value="<?= Yii::$service->page->translate->__('Logout'); ?>" />
<input type="hidden" class="welcome_str" value="<?= Yii::$service->page->translate->__('Welcome!'); ?>" />
<div class="top_nav_inner">
<div class="top_nav_left">
......@@ -41,7 +43,7 @@
<div class="top_nav_right">
<div class="login-text t_r">
<span id="js_isNotLogin">
<a href="<?= Yii::$service->url->getUrl('customer/account/login') ?>" rel="nofollow">Sign In / Join Free</a>
<a href="<?= Yii::$service->url->getUrl('customer/account/login') ?>" rel="nofollow"><?= Yii::$service->page->translate->__('Sign In / Join Free'); ?></a>
</span>
</div>
......@@ -51,10 +53,10 @@
</dt>
<dd style="">
<ul>
<li><a href="<?= Yii::$service->url->getUrl('customer/account') ?>" rel="nofollow">My Account</a></li>
<li><a href="<?= Yii::$service->url->getUrl('customer/order') ?>" rel="nofollow">My Orders</a></li>
<li><a href="<?= Yii::$service->url->getUrl('customer/productfavorite') ?>" rel="nofollow">My Favorites</a></li>
<li><a href="<?= Yii::$service->url->getUrl('customer/productreview') ?>" rel="nofollow">Product Review</a></li>
<li><a href="<?= Yii::$service->url->getUrl('customer/account') ?>" rel="nofollow"><?= Yii::$service->page->translate->__('My Account'); ?></a></li>
<li><a href="<?= Yii::$service->url->getUrl('customer/order') ?>" rel="nofollow"><?= Yii::$service->page->translate->__('My Orders'); ?></a></li>
<li><a href="<?= Yii::$service->url->getUrl('customer/productfavorite') ?>" rel="nofollow"><?= Yii::$service->page->translate->__('My Favorites'); ?></a></li>
<li><a href="<?= Yii::$service->url->getUrl('customer/productreview') ?>" rel="nofollow"><?= Yii::$service->page->translate->__('Product Review'); ?></a></li>
</ul>
</dd>
</dl>
......
<form method="get" name="searchFrom" class="js_topSeachForm" action="<?= Yii::$service->url->getUrl('catalogsearch/index'); ?>">
<div class="top_seachBox">
<div class="searchInput fl">
<input type="text" value="<?= Yii::$app->request->get('q'); ?>" maxlength="150" placeholder="Products keyword" class="searchArea js_k2 ac_input" name="q">
<input type="text" value="<?= Yii::$app->request->get('q'); ?>" maxlength="150" placeholder="<?= Yii::$service->page->translate->__('Products keyword'); ?>" class="searchArea js_k2 ac_input" name="q">
</div>
<button class="fl js_topSearch seachBtn" type="submit"><span class="t_hidden">search</span></button>
<!-- <input type="hidden" class="category" value="0" name="category"> -->
......
......@@ -64,7 +64,7 @@ class Menu extends Service
$display = isset($displayHome['display']) ?$displayHome['display'] : '';
if($enable && $display){
$arr[] = [
'name' => $display,
'name' => Yii::$service->page->translate->__($display),
'url' => Yii::$service->url->homeUrl(),
];
}
......@@ -98,11 +98,14 @@ class Menu extends Service
$cMenu = [];
if(is_array($customMenu) && !empty($customMenu)){
foreach($customMenu as $k=>$menu){
$name = $menu['name'];
if(is_array($name)){
$name = Yii::$service->store->getStoreAttrVal($name,'name');
$menu['name'] = $name;
}
//echo $menu['name'];
$name = Yii::$service->page->translate->__($menu['name']);
$menu['name'] = $name;
//echo $name;
//if(is_array($name)){
//$name = Yii::$service->store->getStoreAttrVal($name,'name');
//}
$urlPath = $menu['urlPath'];
$menu['url'] = Yii::$service->url->getUrl($urlPath);
$cMenu[$k] = $menu;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册