|
...
|
...
|
@@ -62,6 +62,12 @@ class NavController extends BaseController |
|
|
|
$items = $item = (array)$item;
|
|
|
|
$id = $item['id'];
|
|
|
|
// 在给定的详情列表中查找匹配的id
|
|
|
|
foreach ($detailsList as $k => $v){
|
|
|
|
if($id == $v['id']){
|
|
|
|
$matchingDetail = $v;
|
|
|
|
unset($detailsList[$k]);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
$matchingDetail = array_filter($detailsList, function ($detail) use ($id) {
|
|
|
|
return $detail['id'] == $id;
|
|
|
|
});
|
|
...
|
...
|
@@ -73,6 +79,7 @@ class NavController extends BaseController |
|
|
|
}
|
|
|
|
$result[] = $items;
|
|
|
|
}
|
|
|
|
@file_put_contents(storage_path('logs/lyh_error.log'), var_export($detailsList, true) . PHP_EOL, FILE_APPEND);
|
|
|
|
return $result;
|
|
|
|
}
|
|
|
|
|
...
|
...
|
|