...
|
...
|
@@ -1845,19 +1845,22 @@ class Algorithm extends Api |
|
|
//推荐清单
|
|
|
'On' => $this->RecommendedList($NewTestQuestionArray)
|
|
|
];
|
|
|
$new_return_arr = [];
|
|
|
foreach ($Return['On'] as $k => $v) {
|
|
|
if (!empty($v['GoodsArray'])) {
|
|
|
$Tuijian[] = $v['GoodsArray'];
|
|
|
}
|
|
|
}
|
|
|
foreach ($Tuijian as $value) {
|
|
|
foreach ($value as $v) {
|
|
|
$new_return_arr[] = $v;
|
|
|
if (!empty($Tuijian)) {
|
|
|
foreach ($Tuijian as $value) {
|
|
|
foreach ($value as $v) {
|
|
|
$new_return_arr[] = $v;
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
dump($new_return_arr);
|
|
|
dump($NewTestQuestionArray);
|
|
|
die;
|
|
|
Db::name('sleep')->where('id', $NewTestQuestionArray['id'])->update([
|
|
|
'goods_num' => count($new_return_arr)
|
|
|
]);
|
|
|
return $Return;
|
|
|
}
|
|
|
|
...
|
...
|
|