|
...
|
...
|
@@ -62,9 +62,13 @@ class NavController extends BaseController |
|
|
|
$items = $item = (array)$item;
|
|
|
|
$id = $item['id'];
|
|
|
|
// 在给定的详情列表中查找匹配的id
|
|
|
|
$matchingDetail = array_filter($detailsList, function ($detail) use ($id) {
|
|
|
|
return $detail['id'] == $id;
|
|
|
|
});
|
|
|
|
$matchingDetail = [];
|
|
|
|
foreach ($detailsList as $k => $v){
|
|
|
|
if($id == $v['id']){
|
|
|
|
$matchingDetail = $v;
|
|
|
|
unset($detailsList[$k]);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (!empty($matchingDetail)) {
|
|
|
|
$items = reset($matchingDetail);
|
|
|
|
}
|
|
...
|
...
|
@@ -76,6 +80,7 @@ class NavController extends BaseController |
|
|
|
return $result;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @remark :获取当前id下的所有子集
|
|
|
|
* @name :getSubList
|
...
|
...
|
|