作者 lyh

gx

@@ -95,11 +95,10 @@ class BlogCategoryLogic extends BaseLogic @@ -95,11 +95,10 @@ class BlogCategoryLogic extends BaseLogic
95 public function getLastId($id){ 95 public function getLastId($id){
96 $info = $this->model->read(['pid'=>$id],['id']); 96 $info = $this->model->read(['pid'=>$id],['id']);
97 if($info !== false){ 97 if($info !== false){
98 - return $this->getLastId($id); 98 + return $this->getLastId($info['id']);
99 }else{ 99 }else{
100 return $id; 100 return $id;
101 } 101 }
102 -  
103 } 102 }
104 103
105 /** 104 /**
@@ -102,7 +102,7 @@ class NewsCategoryLogic extends BaseLogic @@ -102,7 +102,7 @@ class NewsCategoryLogic extends BaseLogic
102 public function getLastId($id){ 102 public function getLastId($id){
103 $info = $this->model->read(['pid'=>$id],['id']); 103 $info = $this->model->read(['pid'=>$id],['id']);
104 if($info !== false){ 104 if($info !== false){
105 - return $this->getLastId($id); 105 + return $this->getLastId($info['id']);
106 }else{ 106 }else{
107 return $id; 107 return $id;
108 } 108 }