Toggle navigation
Toggle navigation
This project
Loading...
Sign in
chenchao
/
YOHOBUYPC
·
Commits
Go to a project
GitLab
Go to dashboard
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
hf
2015-10-29 18:40:42 +0800
Commit
31fbcc3039a3cc0b9adff67a8a877daf36bf41cf
1 parent
4bddc76e
do fixes bug to category default choosed
Show whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
18 additions
and
191 deletions
framework
template/m.yohobuy.com/actions/index/index/index.phtml
template/m.yohobuy.com/actions/search/index/index.phtml
template/m.yohobuy.com/actions/search/index/list.phtml
template/m.yohobuy.com/partials/layout/header.phtml
yohobuy/m.yohobuy.com/application/controllers/Index.php
yohobuy/m.yohobuy.com/application/controllers/Search.php
yohobuy/m.yohobuy.com/application/models/Category/Class.php
yohobuy/m.yohobuy.com/application/modules/Category/controllers/Class.php
framework
@
75bbc3b0
Subproject commit
119c247f5cf929aa1e059e40609bb16dd6b58f05
Subproject commit
75bbc3b075de19f239532f60c5995d06c5f814e2
...
...
template/m.yohobuy.com/actions/index/index/index.phtml
View file @
31fbcc3
{
{>layout/header
}
}
<div
class=
"index-page yoho-page"
>
<div
class=
"index-container"
>
<div
class=
"index-header clearfix"
>
<div
class=
"iconfont index-logo"
>
60
e;</div>
<form
action=
"http://search.m.yohobuy.com
"
class=
"index-search"
>
<form
action=
"{{searchUrl}}
"
class=
"index-search"
>
<a
href=
"javascript:void(0);"
class=
"no-search"
>取消</a>
<div
class=
"search-box"
>
<input
type=
"text"
name=
"query"
placeholder=
"搜索"
>
...
...
@@ -21,11 +20,8 @@
<a
href=
"/boys"
><img
class=
"homestyle"
src=
"http://img10.static.yhbimg.com/adpic/2015/09/28/18/01bdbd27952eb5f780ac23641e70fd6e12.png"
></a>
<a
href=
"/girls"
><img
class=
"homestyle"
src=
"http://img13.static.yhbimg.com/adpic/2015/09/28/18/025a4056cad1c2b6704a5d7c83066a2d25.png"
></a>
</div>
</div>
</div>
</div>
{
{>layout/footer
}
}
{
{>
layout/download_app
}
}
\ No newline at end of file
...
...
template/m.yohobuy.com/actions/search/index/index.phtml
deleted
100644 → 0
View file @
4bddc76
{
{>
layout/header
}
}
<div
class=
"good-list-page yoho-page"
>
{
{#
goodList
}
}
{
{#
search
}
}
<div
id=
"search-input"
class=
"search-input"
>
<form
action=
"/product/list/index"
method=
"get"
>
<i
class=
"search-icon iconfont"
>
60
f;</i>
<input
type=
"text"
value=
{
{default
}
}
name=
"query"
>
<i
class=
"clear-input iconfont hide"
>
61
a;</i>
<button
id=
"search"
class=
"search"
type=
"submit"
>搜索</button>
</form>
</div>
{
{/
search
}
}
{
{#
brandWay
}
}
<div
class=
"brand-way"
>
<a
href=
{
{url
}
}>
<img
class=
"brand-thumb"
src=
{
{thumb
}
}>
<span>
{
{name
}
}</span>
<span
class=
"entry"
>
进入品牌
<i
class=
"iconfont"
>
614
;</i>
</span>
</a>
</div>
{
{/
brandWay
}
}
{
{#
brandHome
}
}
<div
id=
"brand-header"
class=
"brand-header"
data-id=
{
{id
}
}>
<img
class=
"lazy"
data-original=
{
{banner
}
}>
<a
class=
"btn-intro"
href=
"javascript:void(0);"
>
品牌介绍
</a>
<a
class=
"btn-col"
href=
"javascript:void(0);"
>
<span
class=
"iconfont"
>
622
;</span>
收藏
</a>
</div>
<div
id=
"intro-box"
class=
"brand-intro-box hide"
>
<div
id=
"brand-intro"
class=
"brand-intro"
>
<h
2
>品牌介绍</h
2
>
<div
class=
"con"
>
{
{{intro
}
}}
</div>
<p
class=
"fo"
>
<span></span>
100
%品牌授权正品
</p>
<span
class=
"iconfont close-intro"
>
623
;</span>
</div>
</div>
{
{/
brandHome
}
}
<ul
id=
"list-nav"
class=
"list-nav clearfix"
>
<li
class=
"new active"
>
<a
href=
"javascript:void(0);"
>
最新
<span
class=
"iconfont cur"
>
616
;</span>
</a>
</li>
<li
class=
"price"
>
<a
href=
"javascript:void(0);"
>
价格
<span
class=
"icon"
>
<i
class=
"iconfont up"
>
615
;</i>
<i
class=
"iconfont down cur"
>
616
;</i>
</span>
</a>
</li>
<li
class=
"discount"
>
<a
href=
"javascript:void(0);"
>
折扣
<span
class=
"icon"
>
<i
class=
"iconfont up"
>
615
;</i>
<i
class=
"iconfont down cur"
>
616
;</i>
</span>
</a>
</li>
<li
class=
"filter"
>
<a
href=
"javascript:void(0);"
>
筛选
<span
class=
"iconfont"
>
613
;</span>
</a>
</li>
</ul>
<div
id=
"goods-container"
class=
"goods-container"
>
<div
class=
"new-goods container"
>
{
{#
new
}
}
{
{>
good
}
}
{
{/
new
}
}
</div>
<div
class=
"price-goods container hide"
></div>
<div
class=
"discount-goods container hide"
></div>
{
{>
filter
}
}
</div>
{
{#if
brand
}
}
<input
id=
"brand"
type=
"hidden"
value=
{
{brand
}
}>
{
{/if
}
}
{
{#if
gender
}
}
<input
id=
"gender"
type=
"hidden"
value=
{
{gender
}
}>
{
{/if
}
}
{
{#if
sort
}
}
<input
id=
"sort"
type=
"hidden"
value=
{
{sort
}
}>
{
{/if
}
}
{
{#if
color
}
}
<input
id=
"color"
type=
"hidden"
value=
{
{color
}
}>
{
{/if
}
}
{
{#if
size
}
}
<input
id=
"size"
type=
"hidden"
value=
{
{size
}
}>
{
{/if
}
}
{
{#if
price
}
}
<input
id=
"price"
type=
"hidden"
value=
{
{price
}
}>
{
{/if
}
}
{
{#if
discount
}
}
<input
id=
"discount"
type=
"hidden"
value=
{
{discount
}
}>
{
{/if
}
}
{
{/
goodList
}
}
</div>
{
{>
layout/footer
}
}
\ No newline at end of file
template/m.yohobuy.com/actions/search/index/list.phtml
deleted
100644 → 0
View file @
4bddc76
{
{#
new
}
}
{
{>
good
}
}
{
{/
new
}
}
\ No newline at end of file
template/m.yohobuy.com/partials/layout/header.phtml
View file @
31fbcc3
...
...
@@ -2,7 +2,7 @@
<html>
<head>
<meta
charset=
"utf-8"
>
<title>
{{title}}Y
OHO!
有货
</title>
<title>
{{title}}Y
oho!Buy
有货
</title>
<meta
name=
"keywords"
content=
"{{keywords}}Yoho! 有货官网,潮流志,潮流男装,潮牌,美国潮牌,日本潮牌,香港潮牌,潮牌店,新品首发,欧美潮流,全球购,代购,时尚,流行,特卖,B2C,正品,购物网站,网上购物,货到付款"
>
<meta
name=
"description"
content=
"{{description}}YOHO! 有货,年轻人潮流购物中心,中国最大的潮流商品购物网站。100%品牌正品保证,支持货到付款。作为YOHO!旗下的购物平台,汇集了全球潮流时尚商品和中国最流行的商品,也是国内最大的原创文化商品平台,也是香港,台湾地区流行商品的集中地。同时包含日本、韩国等众多国外潮流品牌,带给您全新潮流购物体验。"
>
<meta
name=
"viewport"
content=
"width=device-width, initial-scale=1, maximum-scale=1, minimum-scale=1, user-scalable=no"
>
...
...
yohobuy/m.yohobuy.com/application/controllers/Index.php
View file @
31fbcc3
<?php
use
Action\AbstractAction
;
use
Plugin\Helpers
;
/**
* 频道选择
...
...
@@ -20,7 +21,8 @@ class IndexController extends AbstractAction
$this
->
_view
->
display
(
'index'
,
array
(
'background'
=>
Index\HomeModel
::
getBgImage
(),
'channelPage'
=>
true
,
'showDownloadApp'
=>
true
'showDownloadApp'
=>
true
,
'searchUrl'
=>
Helpers
::
url
(
''
,
null
,
'search'
),
));
}
...
...
yohobuy/m.yohobuy.com/application/controllers/Search.php
View file @
31fbcc3
...
...
@@ -16,40 +16,8 @@ class SearchController extends AbstractAction
*/
public
function
indexAction
()
{
$data
=
array
(
array
(
'hot'
=>
array
(
array
(
'name'
=>
'夹克'
,
'url'
=>
'm.yohobuy.com'
),
array
(
'name'
=>
'休闲运动鞋'
,
'url'
=>
'm.yohobuy.com'
),
array
(
'name'
=>
'Into the Rainbow'
,
'url'
=>
'm.yohobuy.com'
)
),
'history'
=>
array
(
array
(
'name'
=>
'what'
,
'url'
=>
'm.yohobuy.com'
),
array
(
'name'
=>
'the'
,
'url'
=>
'm.yohobuy.com'
),
array
(
'name'
=>
'fuck'
,
'url'
=>
'm.yohobuy.com'
)
)
)
);
$this
->
_view
->
display
(
'index'
,
array
(
'search'
=>
$data
,
'search'
=>
array
(
'url'
=>
Helpers
::
url
(
''
,
null
,
'search'
))
,
'searchPage'
=>
true
,
'pageFooter'
=>
true
));
...
...
yohobuy/m.yohobuy.com/application/models/Category/Class.php
View file @
31fbcc3
...
...
@@ -38,14 +38,8 @@ class ClassModel
}
do
{
$num
=
1
;
$data
=
ClassData
::
getClassesData
();
if
(
!
isset
(
$data
[
'code'
])
||
$data
[
'code'
]
!==
200
)
{
break
;
}
if
(
!
isset
(
$data
[
'data'
]))
{
if
(
empty
(
$data
[
'data'
]))
{
break
;
}
...
...
@@ -53,9 +47,6 @@ class ClassModel
$item
=
array
();
foreach
(
$data
[
'data'
]
as
$k
=>
$v
)
{
$oneClass
=
array
(
'name'
=>
$k
,
'ca'
=>
array
());
if
(
$num
===
1
)
{
$oneClass
[
'focus'
]
=
true
;
}
foreach
(
$v
as
$val
)
{
$item
=
array
();
...
...
@@ -69,14 +60,12 @@ class ClassModel
'sort'
=>
$value
[
'relation_parameter'
][
'sort'
],
'sort_name'
=>
$value
[
'category_name'
]
),
'list'
);
$item
[
'sub'
][]
=
$subitem
;
}
$oneClass
[
'ca'
][]
=
$item
;
}
$num
++
;
$result
[]
=
$oneClass
;
}
...
...
yohobuy/m.yohobuy.com/application/modules/Category/controllers/Class.php
View file @
31fbcc3
...
...
@@ -10,22 +10,24 @@ class ClassController extends AbstractAction
{
public
function
indexAction
()
{
$channel
=
Helpers
::
getChannelByCookie
();
$classes
=
ClassModel
::
getClassData
();
// 根据频道设置默认的焦点
if
(
!
empty
(
$classes
))
{
$classes
[
$channel
-
1
][
'focus'
]
=
true
;
}
$this
->
setTitle
(
'商品分类'
);
$this
->
setNavHeader
(
'商品分类'
);
$data
=
array
(
'categoryPage'
=>
true
,
'pageHeader'
=>
array
(
'navBack'
=>
true
,
'navHome'
=>
'/'
,
'navTitle'
=>
'商品分类'
),
'category'
=>
array
(
'class'
=>
$classes
'class'
=>
$classes
,
'searchUrl'
=>
Helpers
::
url
(
'/search.html'
,
null
,
'search'
),
)
);
$this
->
setTitle
(
'商品分类'
);
$this
->
_view
->
display
(
'index'
,
$data
);
}
}
\ No newline at end of file
...
...
Please
register
or
login
to post a comment