作者 lyh

gx

@@ -312,7 +312,7 @@ class TranslateLogic extends BaseLogic @@ -312,7 +312,7 @@ class TranslateLogic extends BaseLogic
312 * @time :2024/5/17 15:11 312 * @time :2024/5/17 15:11
313 */ 313 */
314 public function getRouteSource($route){ 314 public function getRouteSource($route){
315 - $data = ['source'=>0,'source_id'=>0,'is_list'=>0,'is_custom'=>0]; 315 + $data = ['source'=>0,'source_id'=>0,'is_list'=>0,'is_custom'=>0,'page'=>0];
316 if(strtolower($route) == 'all'){ 316 if(strtolower($route) == 'all'){
317 return $this->success($data); 317 return $this->success($data);
318 } 318 }
@@ -321,12 +321,20 @@ class TranslateLogic extends BaseLogic @@ -321,12 +321,20 @@ class TranslateLogic extends BaseLogic
321 return $this->success($data); 321 return $this->success($data);
322 } 322 }
323 $route = basename($route); 323 $route = basename($route);
  324 + $page = 0;
  325 + if (is_numeric($route)) {
  326 + $arr = explode('/',$route);
  327 + $page = $arr[1];
  328 + $route = $arr[1];
  329 + }
324 $routeModel = new RouteMap(); 330 $routeModel = new RouteMap();
325 $routeInfo = $routeModel->read(['route'=>$route]); 331 $routeInfo = $routeModel->read(['route'=>$route]);
326 if($routeInfo === false){ 332 if($routeInfo === false){
327 return $data; 333 return $data;
328 } 334 }
329 - return $this->resultData($routeInfo,$data); 335 + $data = $this->resultData($routeInfo,$data);
  336 + $data['page'] = $page;
  337 + return $data;
330 } 338 }
331 339
332 /** 340 /**