Browse Source

钱包迁移,api

lizhen_gitee 2 years ago
parent
commit
5453ac3267

+ 4 - 4
application/api/controller/Live.php

@@ -641,15 +641,15 @@ class Live extends Common
             // 扣除当前用户钻石余额
             $where = [];
             $where["id"] = $this->auth->id;
-            $res1 = $userModel->where($where)->setDec("jewel",$giftValue);
+//            $res1 = $userModel->where($where)->setDec("jewel",$giftValue);
             // 添加当前用户钻石流水记录
-            $res2 = $userjewellogModel->addUserJewelLog($this->auth->id, $giftValue, "-", $userInfo["jewel"], "赠送礼物:'" . $giftInfo["name"] . "',扣除" . $giftValue . "钻石!", 3);
+//            $res2 = $userjewellogModel->addUserJewelLog($this->auth->id, $giftValue, "-", $userInfo["jewel"], "赠送礼物:'" . $giftInfo["name"] . "',扣除" . $giftValue . "钻石!", 3);
             // 添加赠送用户钻石余额
             $where = [];
             $where["id"] = $user_id;
-            $res3 = $userModel->where($where)->setInc("jewel",$giftValue);
+//            $res3 = $userModel->where($where)->setInc("jewel",$giftValue);
             // 添加赠送用户钻石流水记录
-            $res4 = $userjewellogModel->addUserJewelLog($user_id,$giftValue,"+",$touserInfo["jewel"],"获赠礼物:'".$giftInfo["name"]."',增加".$giftValue."钻石!",9);
+//            $res4 = $userjewellogModel->addUserJewelLog($user_id,$giftValue,"+",$touserInfo["jewel"],"获赠礼物:'".$giftInfo["name"]."',增加".$giftValue."钻石!",9);
             // 添加礼物赠送记录表
             $data = [];
             $data["user_id"] = $this->auth->id;

+ 1 - 1
application/api/controller/Money.php

@@ -994,7 +994,7 @@ class Money extends Common
             $exchangelogModel = new \app\common\model\UserExchangeLog();
             $detail = "余额兑换钻石";
             // 添加资金流水记录
-            $res1 = $moneylogModel->addRecord($userId, $exchangeMoney, "-", $userInfo["money"], $detail,14);
+            $res1 = $moneylogModel->addRecord($userId, $exchangeMoney, "-", $userInfo["money"], $detail,114);
             // 添加兑换记录
             $res2 = $exchangelogModel->addExchangeLog($userId, $scoin, $exchangeMoney);
             // 添加钻石流水记录

+ 7 - 5
application/extra/wallet.php

@@ -7,14 +7,14 @@ return [
         //jewel, 从原有代码里找出来的
         0  => '下单',   //减少
         1  => '充值',  //增加
-        2  => '购买锤子',  //减少
+        2  => '购买锤子',  //减少  用不到了
         3  => '赠送礼物',   //减少
-        4  => '声币兑换钻石',  //增加
+        4  => '声币兑换钻石',  //增加  用不到了
         5  => '开通贵族',    //减少
         15 => '开通贵族赠送', //增加
         6  => '购买装扮',    //减少
         7  => '拒绝订单返还',    //增加
-        8  => '完成用户订单获得收益',    //增加
+        8  => '完成用户订单获得收益',    //增加                          需要测试
         9  => '获赠礼物', //增加     api/Live.php大概率废弃了
         11 => '私聊转账',  //减少
         12 => '私聊到账',  //增加
@@ -23,7 +23,7 @@ return [
         //15已被占用
         16 => '签到得钻石',//增加
         17 => '平台充值',//增加
-        18 => '充值退款',//减少
+        18 => '充值退款',//减少                              需要测试
 
         //money
         101 => '获赠礼物', //增加
@@ -32,7 +32,9 @@ return [
         104 => '申请提现', //减少
         105 => '申请提现驳回', //增加
         106 => '接单收益', //增加
-        107 => '平台充值', //增加
+        107 => '平台充值', //增加     没有用到
+        114 => '余额兑换钻石', //减少
+        //堤防3,15的出现
     ],
     'moneyname' => [
         'jewel'    => '钻石',