From 46ec78d291c69dac458103df6ead5b069fc9a8f4 Mon Sep 17 00:00:00 2001 From: heyuntao <heyuntao@LAPTOP-MP4HD5NS> Date: 星期二, 04 七月 2023 14:57:28 +0800 Subject: [PATCH] o元购记录增加平台字段 --- application/api/logic/UserBrowse.php | 4 ++-- application/api/controller/User.php | 4 +++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/application/api/controller/User.php b/application/api/controller/User.php index e2789af..edb6a6a 100644 --- a/application/api/controller/User.php +++ b/application/api/controller/User.php @@ -451,9 +451,11 @@ $new_goodsId = request()->param('new_goodsId',''); + $plateform= request()->param('plateform',''); + $LogicUserBrowse = new LogicUserBrowse(); - $res = $LogicUserBrowse->updatefirstfreelog(USERID,$ids,$new_goodsId); + $res = $LogicUserBrowse->updatefirstfreelog(USERID,$ids,$new_goodsId,$plateform); if($res === false) $this->error($LogicUserBrowse->getError()); diff --git a/application/api/logic/UserBrowse.php b/application/api/logic/UserBrowse.php index 87ecb61..d514a62 100644 --- a/application/api/logic/UserBrowse.php +++ b/application/api/logic/UserBrowse.php @@ -80,7 +80,7 @@ * @param [type] $ids * @return void */ - public function updatefirstfreelog($user_id,$ids,$new_goodsId) + public function updatefirstfreelog($user_id,$ids,$new_goodsId,$plateform) { if(empty($ids)||empty($new_goodsId)){ fault('瀹濊礉ID涓嶈兘涓虹┖'); @@ -91,7 +91,7 @@ if(!empty($res)){ return true; } - $res=Db::execute('INSERT INTO t_user_first_free_browse(user_id,goodsId,new_goodsId) VALUES (?,?,?)',[$user_id,$ids,$new_goodsId]); + $res=Db::execute('INSERT INTO t_user_first_free_browse(user_id,goodsId,new_goodsId,plateform) VALUES (?,?,?,?)',[$user_id,$ids,$new_goodsId,plateform]); return true; -- Gitblit v1.9.3