6
0
Fork 0

修复微信支付回调

release
李静 2022-02-25 15:23:34 +08:00
parent 991a0ad281
commit cecbe3970b
1 changed files with 16 additions and 0 deletions

View File

@ -11,6 +11,7 @@ use App\Services\PayService;
use Illuminate\Database\Eloquent\ModelNotFoundException;
use Illuminate\Support\Carbon;
use Illuminate\Support\Facades\DB;
use Illuminate\Support\Facades\Log;
use Throwable;
class WxpayController extends Controller
@ -93,4 +94,19 @@ class WxpayController extends Controller
return true;
});
}
/**
* 微信回调日志
*
* @param string $message
* @param array $context
* @return void
*/
protected function log(string $message, array $context = [])
{
return Log::build([
'driver' => 'daily',
'path' => storage_path('logs/wxpay-notify.log'),
])->info($message, $context);
}
}