Commit e1c42c72 authored by 冯超鹏's avatar 冯超鹏

短息发送添加log

parent 2570627a
Pipeline #243 canceled with stages
......@@ -11,6 +11,7 @@ use App\Http\Controllers\DevicesController;
use Illuminate\Support\Facades\Config;
use App\Http\Controllers\Auth\SwooleCommandMeTcpController;
use App\Http\Controllers\SmsailiyunController;
use Illuminate\Support\Facades\Log;
class ZehongTcpController extends Controller
{
......@@ -122,6 +123,7 @@ class ZehongTcpController extends Controller
$code = json_encode($sms->sendSms(), true);
if ($code['Message'] == 'OK' && $code['Code'] == 'OK') {
Redis::set($data['id'], $code);
Log::channel('slack')->info('短信发送 =>' . $code . '设备号=>' . $data['id']);
}
}
}
......
......@@ -566,7 +566,7 @@ class UserController extends Controller
public function textcountuser(Request $request)
{
// https://dysmsapi.aliyuncs.com?
// $sms = new SmsailiyunController();
// print_r(json_encode($sms->sendSms(),true));
$sms = new SmsailiyunController();
print_r(json_encode($sms->sendSms(),true));
}
}
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