Authored by xuqi

path nav

@@ -4,6 +4,21 @@ @@ -4,6 +4,21 @@
4 4
5 ### 商品 5 ### 商品
6 6
  7 +### 路径导航
  8 +
  9 + {
  10 + pathNav: [
  11 + //链接类型
  12 + {
  13 + href: '',
  14 + name: ''
  15 + },
  16 + //文字类型
  17 + {
  18 + name: ''
  19 + }
  20 + ]
  21 + }
7 22
8 ## 搜索页 23 ## 搜索页
9 24
1 {{> layout/header}} 1 {{> layout/header}}
2 <div class="products-page yoho-page"> 2 <div class="products-page yoho-page">
3 {{# products}} 3 {{# products}}
  4 + {{> layout/path-nav}}
4 <div class="filter-box"> 5 <div class="filter-box">
5 {{# filters}} 6 {{# filters}}
6 {{# checkedConditions}} 7 {{# checkedConditions}}
  1 +<p class="path-nav">
  2 + {{#each pathNav}}
  3 + {{#if href}}
  4 + <a href="{{href}}">
  5 + {{name}}
  6 +
  7 + {{#unless @last}}
  8 + <span class="iconfont">&#xe601;</span>
  9 + {{/unless}}
  10 + </a>
  11 + {{^}}
  12 + <span>
  13 + {{name}}
  14 +
  15 + {{#unless @last}}
  16 + <i class="iconfont">&#xe601;</i>
  17 + {{/unless}}
  18 + </span>
  19 + {{/if}}
  20 + {{/each}}
  21 +</p>
  1 +.path-nav {
  2 + font-size: 12px;
  3 + padding: 15px 0;
  4 + height: 18px;
  5 + line-height: 18px;
  6 + border-bottom: 1px solid #eaeceb;
  7 + margin-bottom: 15px;
  8 +
  9 + a {
  10 + color: #666;
  11 + }
  12 +
  13 + .iconfont {
  14 + font-size: 12px;
  15 + }
  16 +}
@@ -3,7 +3,8 @@ @@ -3,7 +3,8 @@
3 @import "compass", 3 @import "compass",
4 "compass/reset", 4 "compass/reset",
5 "header", 5 "header",
6 - "footer"; 6 + "footer",
  7 + "path-nav";
7 8
8 body { 9 body {
9 font-family: arial,"Microsoft YaHei"; 10 font-family: arial,"Microsoft YaHei";
@@ -14,6 +14,15 @@ class IndexController extends AbstractAction @@ -14,6 +14,15 @@ class IndexController extends AbstractAction
14 'searchListPage' => true, 14 'searchListPage' => true,
15 15
16 'products' => array( 16 'products' => array(
  17 + 'pathNav' => array(
  18 + array(
  19 + 'href' => 'm.yohobuy.com',
  20 + 'name' => '首页'
  21 + ),
  22 + array(
  23 + 'name' => '搜索“安德玛”共18个结果'
  24 + )
  25 + ),
17 'filters' => array( 26 'filters' => array(
18 'checkedConditions' => array( 27 'checkedConditions' => array(
19 'conditions' => array( 28 'conditions' => array(