Authored by hf

do modify template name use _ to -

... ... @@ -2,7 +2,7 @@
<div class="my-page yoho-page">
<div class="my-header">
{{#isLogin}}
<a class="user-info" href="/home/personaldetails">
<a class="user-info" href="/home/mydetails">
<img class="user-avatar" src="{{head_ico}}">
<span class="username">{{profile_name}}</span>
{{#vip_info}}
... ... @@ -13,7 +13,7 @@
{{/isLogin}}
{{^isLogin}}
<div class="user-info">
<a class="login-btn" href="http://m.dev.yohobuy.com/signin.html">
<a class="login-btn" href="/signin.html">
登录/注册
</a>
</div>
... ... @@ -41,15 +41,15 @@
</a>
</div>
<div class="order-type clearfix">
<a class="type-item" href="/home/order">
<a class="type-item" href="/home/order?type=2">
<span class="iconfont">&#xe634;</span>
<br>待付款
</a>
<a class="type-item" href="/home/order">
<a class="type-item" href="/home/order?type=3">
<span class="iconfont">&#xe63b;</span>
<br>待发货
</a>
<a class="type-item" href="/home/order">
<a class="type-item" href="/home/order?type=4">
<span class="iconfont">&#xe633;</span>
<br>待收货
</a>
... ... @@ -94,7 +94,7 @@
</a>
</div>
<div class="group-list">
<a class="list-item" href="/home/">
<a class="list-item" href="/help.html">
<span class="iconfont icon">&#xe639;</span>
帮助
<span class="iconfont num">&#xe604;</span>
... ...
{{> layout/header}}
<div class="yoho-suggest-sub-page yoho-page">
{{# suggestSub}}
<div class="suggest-sub-form">
<textarea name="" id="suggest-textarea" placeholder="请输入意见反馈,我们会以消息形式回复您的建议或意见,改进产品体验,谢谢!"></textarea>
<div id="img-form" class="img-form">
<ul class="upload-img-list"></ul>
<span class="img-add">
<input id="upload-img" type="file" />
</span>
</div>
</div>
{{/ suggestSub}}
</div>
{{> layout/footer}}
\ No newline at end of file
... ... @@ -32,7 +32,7 @@ class HomeController extends AbstractAction
if (!$uid && $action !== 'index') {
$this->go(Helpers::url('/signin.html'));
}
parent::init();
}
... ... @@ -51,12 +51,12 @@ class HomeController extends AbstractAction
);
$uid = $this->getUid();
if ($uid) {
// 优选新品数据
$channel = Helpers::getChannelByCookie();
$data['isLogin'] = true;
$data += UserModel::getUserProfileData($uid);
$data += UserModel::getInfoNumData($uid);
// 优选新品数据
$channel = Helpers::getChannelByCookie();
$data['recommendForYou'] = UserModel::getPreferenceData($channel);
}
... ... @@ -84,9 +84,9 @@ class HomeController extends AbstractAction
'pageFooter' => true,
'favorite' => true,
'hasFavProduct' => $favProducts,
'productUrl' => '/product/new',
'productUrl' => '/product/new',
'hasFavBrand' => $favBrands,
'brandUrl' => '/product/new'
'brandUrl' => '/product/new'
);
// 判断是否为品牌收藏页
if ($tab === 'brand') {
... ... @@ -120,10 +120,10 @@ class HomeController extends AbstractAction
/**
* 个人信息
*/
public function personalDetailsAction()
public function mydetailsAction()
{
$this->setTitle('个人信息');
$this->setNavHeader('个人信息', true, SITE_MAIN);
$this->setNavHeader('个人信息');
$uid = $this->getUid();
$data = UserModel::getUserProfileData($uid);
... ... @@ -154,7 +154,7 @@ class HomeController extends AbstractAction
{
$this->setTitle('优惠券');
$this->setNavHeader('优惠券');
$uid = $this->getUid();
$coupons = array(
'couponsUrl' => UserModel::getCouponData($uid),
... ... @@ -165,16 +165,16 @@ class HomeController extends AbstractAction
/**
* 我的消息
*
* 暂时使用老的,因后面APP、PC、WAP会进行一次改版
*/
public function messageAction()
{
$uid = $this->getUid();
$page = $this->get('page', 0);
$size = $this->get('size', 10);
$messages = UserModel::getMessageData($uid, $page, $size);
print_r($messages);
// $uid = $this->getUid();
// $page = $this->get('page', 0);
// $size = $this->get('size', 10);
//
// $messages = UserModel::getMessageData($uid, $page, $size);
}
/**
... ... @@ -266,7 +266,9 @@ class HomeController extends AbstractAction
}
}
//在线客服
/**
* 在线客服
*/
public function onlineServiceAction()
{
// 设置网站标题
... ... @@ -282,7 +284,9 @@ class HomeController extends AbstractAction
));
}
//在线客服-具体详情
/**
* 在线客服-具体详情
*/
public function onlineServiceDetailAction()
{
$service = array();
... ... @@ -299,7 +303,7 @@ class HomeController extends AbstractAction
/**
* 我的逛
*/
public function myGuangAction()
public function myguangAction()
{
$page = $this->get('page', 1);
$limit = $this->get('limit', 10);
... ... @@ -308,7 +312,6 @@ class HomeController extends AbstractAction
$yh_channel = Helpers::getChannelByCookie();
$guangInfo = \Home\GuangModel::getMyGuang($uid, $page, $yh_channel, $gender, $limit);
$totalPage = $guangInfo['totalPage'];
unset($guangInfo['totalPage']);
if ($page == 1) {
$this->setTitle('我收藏的');
$this->setNavHeader('我收藏的', true, '');
... ... @@ -362,7 +365,7 @@ class HomeController extends AbstractAction
'pageFooter' => true
);
$this->_view->display('suggest_sub', $data);
$this->_view->display('suggest-sub', $data);
}
/**
... ... @@ -422,6 +425,7 @@ class HomeController extends AbstractAction
$uid = $this->getUid();
$data = GradeModel::getGrade($gender, $channel, $uid);
$data['pageFooter'] = true;
$this->_view->display('vip-grade', $data);
}
... ... @@ -439,7 +443,7 @@ class HomeController extends AbstractAction
$uid = $this->getUid();
$data = GradeModel::getPreferential($channel, $uid);
$data['pageFooter'] = true;
$this->_view->display('privilege', $data);
}
... ... @@ -466,7 +470,9 @@ class HomeController extends AbstractAction
));
}
//ajax请求订单页面
/**
* ajax请求订单页面
*/
public function getOrdersAction()
{
//判断是不是ajax请求
... ... @@ -504,10 +510,8 @@ class HomeController extends AbstractAction
/*
* 我的订单-取消订单
*/
public function cancelOrderAction()
{
//判断是不是ajax请求
if (!$this->isAjax()) {
$this->error();
... ... @@ -526,7 +530,6 @@ class HomeController extends AbstractAction
/*
* 我的订单-删除订单
*/
public function delOrderAction()
{
//判断是不是ajax请求
... ... @@ -547,7 +550,6 @@ class HomeController extends AbstractAction
/*
* 我的订单-支付链接获取
*/
private function paymentAction()
{
$gender = Helpers::getGenderByCookie();
... ... @@ -558,7 +560,6 @@ class HomeController extends AbstractAction
/*
* 我的订单-随便逛逛链接获取
*/
private function strollAction()
{
//获取性别、频道数据
... ...
... ... @@ -193,7 +193,7 @@ class DetailModel
if (is_numeric($productSkn)) {
// 调用服务
$sizeInfo = DetailData::sizeInfo($productSkn);
$sizeInfo = DetailData::sizeInfo($productSkn); var_dump($sizeInfo); exit;
// 商品信息
if (isset($sizeInfo['productDescBo']['erpProductId'])) {
... ...
... ... @@ -49,10 +49,11 @@ class DetailController extends AbstractAction
public function introAction()
{
$productSkn = $this->param('productSkn');
$productSkn = 50027715;
if (!is_numeric($productSkn)) {
$this->error();
}
$data = \Product\DetailModel::getSizeInfo($productSkn);
$data = \Product\DetailModel::getSizeInfo($productSkn); var_dump($data);
if (array() === $data) {
echo ' ';
exit();
... ...