Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
YOHOBUYPC
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
2
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
yangyang
9 years ago
Commit
e7d746018114c0e11d0c64342282c97a8ab17143
1 parent
862ce8a4
修改注释
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
9 additions
and
7 deletions
library/WebPlugin/HelperSearch.php
yohobuy/www.yohobuy.com/application/Bootstrap.php
yohobuy/www.yohobuy.com/application/models/Product/Brands.php
yohobuy/www.yohobuy.com/application/models/Product/Sale.php
yohobuy/www.yohobuy.com/application/modules/Product/controllers/Sale.php
library/WebPlugin/HelperSearch.php
View file @
e7d7460
...
...
@@ -1085,7 +1085,7 @@ class HelperSearch
}
//组织静态资源数据格式
public static function
forma
tNodeContent(
$code
)
public static function
ge
tNodeContent(
$code
)
{
$nodeContent
= BrandData::getByNodeContent(
$code
);
if (isset(
$nodeContent['code']
) &&
$nodeContent['code']
=== 200) {
...
...
@@ -1102,6 +1102,7 @@ class HelperSearch
$result
[
$key
][
'href'
]
=
$vo
;
$result
[
$key
][
'src'
]
=
$img
[
1
][
$key
];
}
return
$result
;
}
}
...
...
yohobuy/www.yohobuy.com/application/Bootstrap.php
View file @
e7d7460
...
...
@@ -71,7 +71,7 @@ class Bootstrap extends Bootstrap_Abstract
$controller
=
'Index'
;
$action
=
'Index'
;
// 二级域名
if
(
2
===
$level
)
{
if
(
3
===
$level
)
{
$url
=
strtolower
(
$dispatcher
->
getRequest
()
->
getRequestUri
());
if
(
empty
(
$url
)
||
$url
==
'/index'
||
$url
==
'/'
)
{
$urlAction
=
'/index'
;
...
...
yohobuy/www.yohobuy.com/application/models/Product/Brands.php
View file @
e7d7460
...
...
@@ -40,7 +40,7 @@ class BrandsModel
//获取静态内容
if
(
$options
[
'node'
])
{
$nodeContent
=
HelperSearch
::
forma
tNodeContent
(
$options
[
'node'
]);
$nodeContent
=
HelperSearch
::
ge
tNodeContent
(
$options
[
'node'
]);
$data
[
'leftContent'
][][
'picLink'
][
'list'
]
=
$nodeContent
;
}
...
...
yohobuy/www.yohobuy.com/application/models/Product/Sale.php
View file @
e7d7460
...
...
@@ -35,14 +35,16 @@ class SaleModel
$data
=
HelperSearch
::
getList
(
$result
,
$searchCondition
[
'options'
]);
//组织sale数据
$special
=
array
();
if
(
isset
(
$specialInfo
[
'data'
])
&&
!
empty
(
$specialInfo
[
'data'
][
'banner_img'
]))
{
$banner
=
json_decode
(
$specialInfo
[
'data'
][
'banner_img'
],
true
);
foreach
(
$banner
as
$k
=>
$v
)
{
$v
[
'img'
]
=
Images
::
getSourceUrl
(
$v
[
'img'
],
'couponImg'
);
$specialInfo
[
'data'
][
'banner'
][]
=
$v
;
}
$special
=
$specialInfo
[
'data'
];
$special
=
$specialInfo
[
'data'
];
}
//Sale首页 banner数据
$data
[
'saleBanner'
][
'bannerHeight'
]
=
$special
[
'banner'
][
0
][
'height'
];
$data
[
'saleBanner'
][
'img'
]
=
$special
[
'banner'
][
0
][
'img'
];
...
...
@@ -51,7 +53,7 @@ class SaleModel
//获取广告位数据
if
(
isset
(
$special
[
'left_ad_code'
]))
{
$nodeContent
=
HelperSearch
::
forma
tNodeContent
(
$special
[
'left_ad_code'
]);
$nodeContent
=
HelperSearch
::
ge
tNodeContent
(
$special
[
'left_ad_code'
]);
$data
[
'leftContent'
][][
'picLink'
][
'list'
]
=
$nodeContent
;
}
...
...
yohobuy/www.yohobuy.com/application/modules/Product/controllers/Sale.php
View file @
e7d7460
...
...
@@ -32,7 +32,7 @@ class SaleController extends WebAction
if
(
!
empty
(
$special
[
'brand_id'
])){
$condition
[
'brand'
]
=
$special
[
'brand_id'
];
}
//传促销id
//传促销id
,促销id为空时传专区id
if
(
!
empty
(
$special
[
'ispromotion'
])){
$condition
[
'promotion'
]
=
$special
[
'ispromotion'
];
}
else
{
...
...
@@ -40,7 +40,6 @@ class SaleController extends WebAction
}
$options
=
array
(
'specialsale_id'
=>
'Y'
,
'controller'
=>
$this
->
_request
->
controller
,
'reviewNum'
=>
6
);
...
...
Please
register
or
login
to post a comment