Commit a488b907 authored by suntengda's avatar suntengda

update 发送用户订阅通知

parent f4f6ebfd
......@@ -31,6 +31,11 @@ class Pindan implements DaemonServiceInterface
$list = MarketingService::marketingList($params);
if(empty($list['result'])) {
DaemonLog::info(
'DaemonServiceInterface_pindan',
'no need to send at'.date('Y-m-d H:i:s')
);
sleep(60);
return false;
}
......@@ -47,11 +52,12 @@ class Pindan implements DaemonServiceInterface
$list['result'][0]['pindan_desc'] ?: self::DEFAULT_DESC
];
//发送消息
Msg::send(999, $app_id, $template_id, $page_url, $type, $params);
DaemonLog::info(
'DaemonServiceInterface_pindan',
'send at '.date('Y-m-d H:i:s').' params:'.json_encode($params)
);
Msg::send(999, $app_id, $template_id, $page_url, $type, $params);
sleep(60);//保证16:40只执行一次
}catch (Exception $e) {
DaemonLog::error(
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment