作者 lyh

ggx

@@ -96,4 +96,40 @@ class CNoticeController extends BaseController @@ -96,4 +96,40 @@ class CNoticeController extends BaseController
96 curl_close($curl); 96 curl_close($curl);
97 return $response; 97 return $response;
98 } 98 }
  99 +
  100 + /**
  101 + * @remark :生成一条更新记录
  102 + * @name :addProgress
  103 + * @author :lyh
  104 + * @method :post
  105 + * @time :2023/9/6 17:01
  106 + */
  107 + public function addProgress($count,$type){
  108 + $data = [
  109 + 'total_num'=>$count,
  110 + 'current_num'=>0,
  111 + 'type'=>$type,
  112 + 'project_id'=>$this->user['project_id'],
  113 + 'created_at'=>date('Y-m-d H;i:s')
  114 + ];
  115 + $updateProgressModel = new UpdateProgress();
  116 + return $updateProgressModel->insert($data);
  117 + }
  118 +
  119 + /**
  120 + * @remark :通知参数处理
  121 + * @name :getString
  122 + * @author :lyh
  123 + * @method :post
  124 + * @time :2023/9/6 17:03
  125 + */
  126 + public function getString($type,$page){
  127 + $param = [
  128 + 'project_id' => $this->user['project_id'],
  129 + 'type' => $type,
  130 + 'route' => $page
  131 + ];
  132 + $string = http_build_query($param);
  133 + return $this->user['domain'].'api/updateHtmlNotify/?' . $string;
  134 + }
99 } 135 }
@@ -61,39 +61,5 @@ class WebSettingLogic extends BaseLogic @@ -61,39 +61,5 @@ class WebSettingLogic extends BaseLogic
61 61
62 62
63 63
64 - /**  
65 - * @remark :生成一条更新记录  
66 - * @name :addProgress  
67 - * @author :lyh  
68 - * @method :post  
69 - * @time :2023/9/6 17:01  
70 - */  
71 - public function addProgress($count,$type){  
72 - $data = [  
73 - 'total_num'=>$count,  
74 - 'current_num'=>0,  
75 - 'type'=>$type,  
76 - 'project_id'=>$this->user['project_id'],  
77 - 'created_at'=>date('Y-m-d H;i:s')  
78 - ];  
79 - $updateProgressModel = new UpdateProgress();  
80 - return $updateProgressModel->insert($data);  
81 - }  
82 64
83 - /**  
84 - * @remark :通知参数处理  
85 - * @name :getString  
86 - * @author :lyh  
87 - * @method :post  
88 - * @time :2023/9/6 17:03  
89 - */  
90 - public function getString($type,$page){  
91 - $param = [  
92 - 'project_id' => $this->user['project_id'],  
93 - 'type' => $type,  
94 - 'route' => $page  
95 - ];  
96 - $string = http_build_query($param);  
97 - return $this->user['domain'].'api/updateHtmlNotify/?' . $string;  
98 - }  
99 } 65 }