|
|
@@ -5,6 +5,7 @@ namespace App\Http\Controllers\Game;
|
|
|
|
|
|
|
|
|
use App\Facade\TableName;
|
|
|
+use App\Game\GlobalUserInfo;
|
|
|
use App\Http\helper\NumConfig;
|
|
|
use App\Models\AccountsInfo;
|
|
|
use App\Models\Treasure\GameScoreLocker;
|
|
|
@@ -20,6 +21,32 @@ use Illuminate\Support\Facades\Validator;
|
|
|
class WithDrawInfoController
|
|
|
{
|
|
|
|
|
|
+
|
|
|
+
|
|
|
+ public function FreeWithDrawInfo(Request $request)
|
|
|
+ {
|
|
|
+ $user = $request->user();
|
|
|
+ $userScoreData = GlobalUserInfo::getScoreDataByUserID($user->UserID);
|
|
|
+ if(!$userScoreData['Recharge']){
|
|
|
+ $totalWithdraw = max($userScoreData['InsureScore'],40);
|
|
|
+ if($userScoreData['InsureScore']<40){
|
|
|
+ //第一种状态,我免费领了10块钱,但是金额不足40,点进去页面填信息后点击提现,提示我去玩游戏
|
|
|
+ return apiReturnSuc(['state' => 1, 'total' => $totalWithdraw,'InsureScore' => $userScoreData['InsureScore']]);
|
|
|
+ }else{
|
|
|
+ //第二种状态,我免费金额足够40,提现按钮会点亮,告知用户点击进去
|
|
|
+ return apiReturnSuc(['state' => 2, 'total' => $totalWithdraw,'InsureScore' => $userScoreData['InsureScore']]);
|
|
|
+ }
|
|
|
+ }else{
|
|
|
+ //第四种状态,VIP状态下,金额不足了,进度条颜色红色,按钮灰色(不可点击),次日整个消失
|
|
|
+ if($userScoreData['InsureScore']<10){
|
|
|
+ return apiReturnSuc(['state' => 4, 'total' => $userScoreData['InsureScore'],'InsureScore' => $userScoreData['InsureScore']]);
|
|
|
+ }else{
|
|
|
+ //第三种状态,进去完成了充值未提现,提现按钮会高光,引导用户完成提现
|
|
|
+ return apiReturnSuc(['state' => 3, 'total' => $userScoreData['InsureScore'],'InsureScore' => $userScoreData['InsureScore']]);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
public function WithDrawRecord(Request $request)
|
|
|
{
|
|
|
|