fixes bug to brand list not return brand id
Showing
1 changed file
with
5 additions
and
1 deletions
@@ -91,7 +91,7 @@ class IndexController extends AbstractAction | @@ -91,7 +91,7 @@ class IndexController extends AbstractAction | ||
91 | $brandId = 0; | 91 | $brandId = 0; |
92 | if (isset($brandIds[0])) { | 92 | if (isset($brandIds[0])) { |
93 | $brandId = $brandIds[0]; | 93 | $brandId = $brandIds[0]; |
94 | - } | 94 | + } |
95 | 95 | ||
96 | // 当前的登录用户UID | 96 | // 当前的登录用户UID |
97 | $uid = $this->getUid(); | 97 | $uid = $this->getUid(); |
@@ -114,6 +114,10 @@ class IndexController extends AbstractAction | @@ -114,6 +114,10 @@ class IndexController extends AbstractAction | ||
114 | 'gender' => FILTER_DEFAULT, | 114 | 'gender' => FILTER_DEFAULT, |
115 | 'p_d' => FILTER_DEFAULT,), false); | 115 | 'p_d' => FILTER_DEFAULT,), false); |
116 | $condition['brand'] = $brandId; | 116 | $condition['brand'] = $brandId; |
117 | + | ||
118 | + if ($brandId === 0) { | ||
119 | + $condition['query'] = $domain; | ||
120 | + } | ||
117 | 121 | ||
118 | if (isset($condition['gender'])) { | 122 | if (isset($condition['gender'])) { |
119 | $condition['gender'] = rawurldecode($condition['gender']); | 123 | $condition['gender'] = rawurldecode($condition['gender']); |
-
Please register or login to post a comment