Authored by Rock Zhang

修复新品到着、折扣专区选择接口不能返回数据的bug

... ... @@ -206,7 +206,7 @@ class NewsaleModel
*/
public static function selectData($data)
{
$result = array('goods' => array());
$result = array();
if (isset($data['code']) && $data['code'] === 200) {
foreach ($data['data']['product_list'] as $val) {
... ...
... ... @@ -141,7 +141,14 @@ class NewsaleController extends AbstractAction
);
$result = \Product\NewsaleModel::selectData($data);
if(empty($result))
{
echo ' ';
}
else
{
$this->_view->display('product', $result);
}
} else {
echo ' ';
}
... ...