From dc4ef313abbaadb77a290c11cf01b63492010309 Mon Sep 17 00:00:00 2001 From: ELF <360197197@qq.com> Date: Thu, 26 Sep 2019 15:05:55 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9oa=E6=8E=A5=E5=8F=A3=E6=97=A5?= =?UTF-8?q?=E5=BF=97=E8=AE=B0=E5=BD=95=E6=96=B9=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Sdk/Controller/FengHuoApiController.class.php | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/Application/Sdk/Controller/FengHuoApiController.class.php b/Application/Sdk/Controller/FengHuoApiController.class.php index 248f86e3c..4fd168f79 100644 --- a/Application/Sdk/Controller/FengHuoApiController.class.php +++ b/Application/Sdk/Controller/FengHuoApiController.class.php @@ -7,6 +7,7 @@ */ namespace SDK\Controller; use Think\Controller; +use Think\Log; class FengHuoApiController extends Controller{ // protected function _initialize(){ @@ -104,7 +105,7 @@ class FengHuoApiController extends Controller{ ]; } - file_put_contents(dirname(__FILE__).'/'.date('Ymd').'registerDetail.log', date('Y-m-d H:i:s') . ' ---- ' . json_encode($result) . PHP_EOL, FILE_APPEND); + Log::write('registerDetail:' . date('Y-m-d H:i:s') . ' ---- ' . json_encode($result), 'INFO'); return $this->ajaxReturn($result); } @@ -154,7 +155,7 @@ class FengHuoApiController extends Controller{ ]; } - file_put_contents(dirname(__FILE__).'/'.date('Ymd').'payDetail.log', date('Y-m-d H:i:s') . ' ---- ' . json_encode($result) . PHP_EOL, FILE_APPEND); + Log::write('payDetail:' . date('Y-m-d H:i:s') . ' ---- ' . json_encode($result), 'INFO'); return $this->ajaxReturn($result); @@ -202,7 +203,7 @@ class FengHuoApiController extends Controller{ ]; } - file_put_contents(dirname(__FILE__).'/'.date('Ymd').'roleInfo.log', date('Y-m-d H:i:s') . ' ---- ' . json_encode($result) . PHP_EOL, FILE_APPEND); + Log::write('roleInfo:' . date('Y-m-d H:i:s') . ' ---- ' . json_encode($result), 'INFO'); return $this->ajaxReturn($result); @@ -266,7 +267,7 @@ class FengHuoApiController extends Controller{ ]; } - file_put_contents(dirname(__FILE__).'/'.date('Ymd').'loginInfo.log', date('Y-m-d H:i:s') . ' ---- ' . json_encode($result) . PHP_EOL, FILE_APPEND); + Log::write('loginInfo:' . date('Y-m-d H:i:s') . ' ---- ' . json_encode($result), 'INFO'); return $this->ajaxReturn($result); @@ -325,7 +326,7 @@ class FengHuoApiController extends Controller{ ]; } - file_put_contents(dirname(__FILE__).'/'.date('Ymd').'bindHistory.log', date('Y-m-d H:i:s') . ' ---- ' . json_encode($result) . PHP_EOL, FILE_APPEND); + Log::write('bindHistory:' . date('Y-m-d H:i:s') . ' ---- ' . json_encode($result), 'INFO'); return $this->ajaxReturn($result); }