tp5数组转树状结构输出
1. 树状结构组装输出tree函数,从根节点0开始寻找 public function getlist() { $field = 'category_id,category_pid,category_name'; $order = [ ]; $map = [ 'status' => 1 ]; $cate = $this->field($field...