作者 lyh

Merge branch 'develop' into dev

@@ -43,9 +43,9 @@ class AyrReleaseController extends BaseController @@ -43,9 +43,9 @@ class AyrReleaseController extends BaseController
43 $this->request->validate([ 43 $this->request->validate([
44 'share_id'=>['required'] 44 'share_id'=>['required']
45 ],[ 45 ],[
46 - 'share_id.required' => 'SHARE_ID不能为空' 46 + 'share_id.required' => 'share_id不能为空'
47 ]); 47 ]);
48 - $info = $ayrShareLogic->ayr_share_info(); 48 + $info = $ayrShareLogic->ayr_share_info($this->param['share_id']);
49 $this->response('success',Code::SUCCESS,$info); 49 $this->response('success',Code::SUCCESS,$info);
50 } 50 }
51 /** 51 /**
@@ -58,7 +58,7 @@ class AyrReleaseController extends BaseController @@ -58,7 +58,7 @@ class AyrReleaseController extends BaseController
58 AyrShareLogic $ayrShareLogic,AyrShareHelper $ayrShare){ 58 AyrShareLogic $ayrShareLogic,AyrShareHelper $ayrShare){
59 $ayrReleaseRequest->validated(); 59 $ayrReleaseRequest->validated();
60 //获取发送账号详情 60 //获取发送账号详情
61 - $share_info = $ayrShareLogic->ayr_share_info(); 61 + $share_info = $ayrShareLogic->ayr_share_info($this->param['share_id']);
62 //验证发送平台 62 //验证发送平台
63 $ayrShareLogic->verify_param($share_info); 63 $ayrShareLogic->verify_param($share_info);
64 $data = [ 64 $data = [
@@ -52,9 +52,9 @@ class AyrShareController extends BaseController @@ -52,9 +52,9 @@ class AyrShareController extends BaseController
52 */ 52 */
53 public function save_account(AyrShareLogic $ayrShareLogic){ 53 public function save_account(AyrShareLogic $ayrShareLogic){
54 $this->request->validate([ 54 $this->request->validate([
55 - 'share_id'=>['required'], 55 + 'id'=>['required'],
56 ],[ 56 ],[
57 - 'share_id.required' => 'SHARE_ID不能为空', 57 + 'id.required' => 'SHARE_ID不能为空',
58 ]); 58 ]);
59 $info = $ayrShareLogic->ayr_share_info(); 59 $info = $ayrShareLogic->ayr_share_info();
60 $ayrShareHelper = new AyrShareHelper(); 60 $ayrShareHelper = new AyrShareHelper();
@@ -69,8 +69,11 @@ class AyrShareLogic extends BaseLogic @@ -69,8 +69,11 @@ class AyrShareLogic extends BaseLogic
69 * @method :post 69 * @method :post
70 * @time :2023/5/6 10:16 70 * @time :2023/5/6 10:16
71 */ 71 */
72 - public function ayr_share_info(){  
73 - $info = $this->model->read(['id'=>$this->param['share_id']]); 72 + public function ayr_share_info($share_id = ''){
  73 + if(isset($this->param['id'])){
  74 + $share_id = $this->param['id'];
  75 + }
  76 + $info = $this->model->read(['id'=>$share_id]);
74 if($info === false){ 77 if($info === false){
75 $this->fail('当前数据不存在或已被删除'); 78 $this->fail('当前数据不存在或已被删除');
76 } 79 }
@@ -30,13 +30,13 @@ class NavLogic extends BaseLogic @@ -30,13 +30,13 @@ class NavLogic extends BaseLogic
30 */ 30 */
31 public function list(){ 31 public function list(){
32 $where = []; 32 $where = [];
33 - if(!empty($this->param['location'])){  
34 - $where[] = ['location','=',$this->param['location']]; 33 + if(!empty($this->requestAll['location'])){
  34 + $where[] = ['location','=',$this->requestAll['location']];
35 } 35 }
36 36
37 $lists = $this->getList($where,['sort'=>'asc'],['*'],false); 37 $lists = $this->getList($where,['sort'=>'asc'],['*'],false);
38 38
39 - $isTree = $this->param['tree']??false; 39 + $isTree = $this->requestAll['tree']??false;
40 40
41 if($isTree){ 41 if($isTree){
42 $lists = list_to_tree($lists); 42 $lists = list_to_tree($lists);