Authored by xuqi

Merge branch 'develop' of http://git.dev.yoho.cn/web/yohobuy into develop

framework @ 119c247f
Subproject commit 75bbc3b075de19f239532f60c5995d06c5f814e2
Subproject commit 119c247f5cf929aa1e059e40609bb16dd6b58f05
... ...
0 info it worked if it ends with ok
1 verbose cli [ 'node',
1 verbose cli 'c:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\cnpm\\node_modules\\npm\\bin\\npm-cli.js',
1 verbose cli '--userconfig=C:\\Users\\Administrator\\.cnpmrc',
1 verbose cli '--disturl=https://npm.taobao.org/mirrors/node',
1 verbose cli '--cache=C:\\Users\\Administrator\\.cnpm',
1 verbose cli '--registry=https://registry.npm.taobao.org',
1 verbose cli '--node-gyp=c:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\cnpm\\node_modules\\pangyp\\bin\\node-gyp.js',
1 verbose cli 'install',
1 verbose cli '-d' ]
2 info using npm@2.13.5
3 info using node@v0.12.0
4 verbose readDependencies loading dependencies from d:\YOHO\yohobuy\package.json
5 error install Couldn't read dependencies
6 verbose stack Error: ENOENT, open 'd:\YOHO\yohobuy\package.json'
6 verbose stack at Error (native)
7 verbose cwd d:\YOHO\yohobuy
8 error Windows_NT 6.1.7601
9 error argv "node" "c:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\cnpm\\node_modules\\npm\\bin\\npm-cli.js" "--userconfig=C:\\Users\\Administrator\\.cnpmrc" "--disturl=https://npm.taobao.org/mirrors/node" "--cache=C:\\Users\\Administrator\\.cnpm" "--registry=https://registry.npm.taobao.org" "--node-gyp=c:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\cnpm\\node_modules\\pangyp\\bin\\node-gyp.js" "install" "-d"
10 error node v0.12.0
11 error npm v2.13.5
12 error path d:\YOHO\yohobuy\package.json
13 error code ENOPACKAGEJSON
14 error errno -4058
15 error package.json ENOENT, open 'd:\YOHO\yohobuy\package.json'
15 error package.json This is most likely not a problem with npm itself.
15 error package.json npm can't find a package.json file in your current directory.
16 verbose exit [ -4058, true ]
... ...
This diff could not be displayed because it is too large.
/**
* 产品打包入口
* @author: liangzhifeng<zhifeng.liang@yoho.cn>
* @date: 2015/10/20
*/
var $ = require('yoho.zepto'),
Swiper = require('yoho.iswiper'),
lazyLoad = require('yoho.zeptolazyload'),
goodsSwiper;
lazyLoad($('img.lazy'));
goodsSwiper = new Swiper('.banner-swiper', {
loop: true,
pagination: '.banner-top .pagination-inner',
slideElement: 'li',
nextButton: '.swiper-button-next',
prevButton: '.swiper-button-prev'
});
\ No newline at end of file
... ...
... ... @@ -6,4 +6,5 @@
require('./newsale/newarrival');
require('./newsale/discount');
require('./list');
\ No newline at end of file
require('./list');
require('./detail/detail');
\ No newline at end of file
... ...
.brand-page {
.newbrand-search {
width: 93.75%;
height: 30px;
... ...
@import "brand";
.category-page {
font-size: 30rem / $pxConvertRem;
... ...
... ... @@ -43,6 +43,10 @@
white-space: nowrap;
}
}
.brand:nth-child(5n) {
border-right: none;
}
.more {
float: left;
... ...
.good-detail-page {
.banner-top {
position: relative;
.swiper-pagination {
position: absolute;
left: 0;
right: 0;
bottom: 20rem / $pxConvertRem;
text-align: center;
.pagination-inner {
display: inline-block;
span {
display: inline-block;
width: 14rem / $pxConvertRem;
height: 14rem / $pxConvertRem;
background: #fff;
opacity: 0.5;
margin: 0 (9rem / $pxConvertRem);
border-radius: 50%;
}
span.swiper-active-switch {
opacity: 1;
}
}
}
.good-banner-swiper {
height: 598rem / $pxConvertRem;
overflow: hidden;
ul {
position: relative;
height: 100%;
li {
float: left;
height: 100%;
img {
width: 448rem / $pxConvertRem;
height: 100%;
}
}
}
}
}
}
... ...
@import "new-arrival", "discount", "list";
\ No newline at end of file
@import "new-arrival", "discount", "list", "detail";
\ No newline at end of file
... ...
<?php
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
{{> layout/header}}
<div class="good-detail-page yoho-page">
{{# bannerTop}}
{{> product/banner_swiper_arrow}}
{{/ bannerTop}}
</div>
{{> layout/footer}}
\ No newline at end of file
... ...
... ... @@ -119,6 +119,12 @@
seajs.use('js/product/list');
</script>
{{/if}}
{{!-- 商品详情 --}}
{{#if goodDetail}}
<script>
seajs.use('js/product/detail/detail');
</script>
{{/if}}
{{!-- 品类 --}}
{{#if categoryPage}}
<script>
... ...
<div class="banner-top">
<div class="good-banner-swiper swiper-container">
<ul class="swiper-wrapper">
{{# list}}
<li class="swiper-slide">
<a href="{{url}}">
<img src="{{img}}" alt="">
</a>
</li>
{{/ list}}
</ul>
</div>
<div class="swiper-pagination">
<div class="pagination-inner">
</div>
</div>
<!-- 如果需要导航按钮 -->
<div class="swiper-button-prev"></div>
<div class="swiper-button-next"></div>
</div>
\ No newline at end of file
... ...
{{# header}}
<div id="header" class="header clearfix" {{# bgColor}}style="background:{{.}}"{{/ bgColor}}>
<a class="icon-back iconfont" href="javascript:history.go(-1)"></a>
{{title}}
<a class="icon-home iconfont" href="{{homeUrl}}"></a>
</div>
{{/ header}}
<?php
use Action\AbstractAction;
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
/**
* 商品详情的控制器
*/
class DetailController extends AbstractAction
{
/**
* 商品详情
*
* @param
*/
public function indexAction()
{
$data = array (
'goodDetail' => true,
'bannerTop' => array (
'list' => array (
array (
'url' => '',
'img' => 'http://img10.static.yhbimg.com/adpic/2015/10/15/10/01c161398d3baec2868abe85e26ba1a71d.jpg?imageMogr2/thumbnail/640x300/extent/640x300/background/d2hpdGU=/position/center/quality/90'
),
array (
'url' => '',
'img' => 'http://img13.static.yhbimg.com/adpic/2015/10/15/10/027c45cdc03e23c367ec0ff3d29b7c3f79.jpg?imageMogr2/thumbnail/640x300/extent/640x300/background/d2hpdGU=/position/center/quality/90'
),
array (
'url' => '',
'img' => 'http://img13.static.yhbimg.com/adpic/2015/10/15/10/022e2ac6daa33fc3cb8a0f04025a35994f.jpg?imageMogr2/thumbnail/640x300/extent/640x300/background/d2hpdGU=/position/center/quality/90'
)
)
)
);
$this->_view->assign('title', '商品详情');
//$this->_view->display('brand', compact('brands'));
// 渲染模板
$this->_view->display('index', $data);
}
}
\ No newline at end of file
... ...