Tree 4 viikkoa sitten
vanhempi
sitoutus
76a7a60a48

+ 1 - 1
app/Console/Commands/ExemptReview.php

@@ -136,7 +136,7 @@ class ExemptReview extends Command
 //                    $agent = 101;
                     rand(1,100)>60?$agent = 99:$agent = 101;
                 }else{
-                    if(($value->WithDraw/NumConfig::NUM_VALUE)<20){
+                    if(($value->WithDraw/NumConfig::NUM_VALUE)<40){
                         $agent = 99;
                     }else{
 //                        rand(1,100)>30?$agent = 99:$agent = 101;

+ 4 - 4
app/Game/GlobalUserInfo.php

@@ -111,11 +111,11 @@ class GlobalUserInfo extends Model
 
     // Fillable attributes for mass assignment
     protected $fillable = [
-        'GlobalUID', 'UserID', 'GameID','FPID','LastFPID','ShortHashID', 'Accounts', 'Email', 'Phone', 'NickName', 'FaceID', 'LogonPass',
+        'GlobalUID', 'UserID', 'GameID','FF','FPID','LastFPID','ShortHashID', 'Accounts', 'Email', 'Phone', 'NickName', 'FaceID', 'LogonPass',
         'InsurePass', 'Gender', 'RegisterDate', 'RegisterIP',
         'RegisterLocation', 'DefaultLanguage', 'ServerRegion',
         'ThemeColor', 'Level', 'Exp', 'UserRight',
-        'SpreaderID', 'LastLogonIP', 'LastLogonDate', 'ReferrType','Channel','GpsAdid','FavoriteGames','PwaInstalled','Registed'
+        'SpreaderID', 'LastLogonIP', 'LastLogonDate', 'ReferrType','Channel','RegionID','GpsAdid','FavoriteGames','PwaInstalled','Registed'
     ];
 
     // Attributes that should be cast to native types
@@ -135,8 +135,8 @@ class GlobalUserInfo extends Model
 
     public static function faceidToAvatar($faceID)
     {
-        return "https://cdn.moeda777.com/24680/assets/avatar/2/avatar_$faceID.png";
-//        return "https://24680.imgix.net/24680/assets/avatar/5/avatar_$faceID.webp?auto=format,compress&cs=srgb";
+//        return "https://cdn.moeda777.com/24680/assets/avatar/2/avatar_$faceID.png";
+        return "https://24680.imgix.net/24680/assets/avatar/5/avatar_$faceID.webp?auto=format,compress&cs=srgb";
     }
 
     /**

+ 84 - 44
app/Game/Services/AgentService.php

@@ -44,34 +44,34 @@ class AgentService
                 $higher1GUID = $link->GlobalUID;
                 $higher1ID = $link->UserID;
 
-                // 查询上级的上级
-                $Inviter = AgentUser::where('GlobalUID', $higher1GUID)->first();
-                if ($Inviter) {
-                    $higher2GUID = $Inviter->Higher1GUID;
-                    $higher2ID = $Inviter->Higher1ID;
-                    if($higher2GUID){
-                        AgentUser::query()->where("GlobalUID",$higher2GUID)->increment('downCount2',1);
-                    }
-
-                    $higher3GUID = $Inviter->Higher2GUID;
-                    $higher3ID = $Inviter->Higher2ID;
-
-                    if($higher3GUID){
-                        AgentUser::query()->where("GlobalUID",$higher3GUID)->increment('downCount3',1);
-                    }
-
-                    $higher4GUID = $Inviter->Higher3GUID;
-                    $higher4ID = $Inviter->Higher3ID;
-
-                    if($higher4GUID){
-                        AgentUser::query()->where("GlobalUID",$higher4GUID)->increment('downCount4',1);
-                    }
-                }else{
-                    $Inviter=AgentUser::create(['GlobalUID' => $higher1GUID,
-                                       'UserID' => $higher1ID]);
-                    $Inviter->increment('downCount1',1);
-
-                }
+//                // 查询上级的上级
+//                $Inviter = AgentUser::where('GlobalUID', $higher1GUID)->first();
+//                if ($Inviter) {
+//                    $higher2GUID = $Inviter->Higher1GUID;
+//                    $higher2ID = $Inviter->Higher1ID;
+//                    if($higher2GUID){
+//                        AgentUser::query()->where("GlobalUID",$higher2GUID)->increment('downCount2',1);
+//                    }
+//
+//                    $higher3GUID = $Inviter->Higher2GUID;
+//                    $higher3ID = $Inviter->Higher2ID;
+//
+//                    if($higher3GUID){
+//                        AgentUser::query()->where("GlobalUID",$higher3GUID)->increment('downCount3',1);
+//                    }
+//
+//                    $higher4GUID = $Inviter->Higher3GUID;
+//                    $higher4ID = $Inviter->Higher3ID;
+//
+//                    if($higher4GUID){
+//                        AgentUser::query()->where("GlobalUID",$higher4GUID)->increment('downCount4',1);
+//                    }
+//                }else{
+//                    $Inviter=AgentUser::create(['GlobalUID' => $higher1GUID,
+//                                       'UserID' => $higher1ID]);
+//                    $Inviter->increment('downCount1',1);
+//
+//                }
             }
         }
 
@@ -98,31 +98,71 @@ class AgentService
         AgentLinks::getDefaultCampaign($GlobalUID);
         return $agentUser;
     }
-    public static function recordPerformance($userId, $amount)
+    public static function recordPerformance($userId, $amount=0,$type=2)
     {
+        try {
+            // 获取用户的邀请链
+            $user = AgentUser::query()->where('UserID', $userId)->first();
 
-        // 获取用户的邀请链
-        $user = AgentUser::query()->where('UserID', $userId)->first();
 
+            if(!$user){
+                $guser=GlobalUserInfo::getGameUserInfo('UserID',$userId);
+                if(!$guser)return;
+                $user=self::SetUserAgent($guser->GlobalUID,$userId);
+            }
 
-        if(!$user){
-            $guser=GlobalUserInfo::getGameUserInfo('UserID',$userId);
-            if(!$guser)return;
-            $user=self::SetUserAgent($guser->GlobalUID,$userId);
-        }
+//        $invitationChain= [];
+//        if($user->Higher1ID)$invitationChain[]=[$user->Higher1GUID,$user->Higher1ID];
+//        if($user->Higher2ID)$invitationChain[]=[$user->Higher2GUID,$user->Higher2ID];
+//        if($user->Higher3ID)$invitationChain[]=[$user->Higher3GUID,$user->Higher3ID];
+//        if($user->Higher4ID)$invitationChain[]=[$user->Higher4GUID,$user->Higher4ID];
+//        $hasReward=$user->TotalReward;
 
-        $invitationChain= [];
-        if($user->Higher1ID)$invitationChain[]=[$user->Higher1GUID,$user->Higher1ID];
-        if($user->Higher2ID)$invitationChain[]=[$user->Higher2GUID,$user->Higher2ID];
-        if($user->Higher3ID)$invitationChain[]=[$user->Higher3GUID,$user->Higher3ID];
-        if($user->Higher4ID)$invitationChain[]=[$user->Higher4GUID,$user->Higher4ID];
-        $hasReward=$user->TotalReward;
+            // 更新 UserAgent 表
+            if($user->Higher1ID) {
+                $update = [];
+                $reward = 10;
+                $activity = DB::table('agent.dbo.ActivityTurnplate')
+                    ->where('UserID', $user->Higher1ID)
+                    ->first();
+                if(!$activity){
+                    return false;
+                }
+                if ($type == 1){
+                    if($activity->RegisterRewardLimit<200){
+                        $reward = rand(10,min(50,max(200-intval($activity->RegisterRewardLimit),10)));
+                        $update = ['Amount' => $activity->Amount+$reward,'RegisterRewardLimit' => $activity->RegisterRewardLimit+$reward];
+                    }else{
+                        return false;
+                    }
 
-        // 更新 UserAgent 表
-        if($user->Higher1GUID) {
+                }else{
+                    $reward = rand(20,100);
+                    $update = ['Amount' => $activity->Amount+$reward];
+                }
+                // BonusLog 入库
+                DB::connection('write')->table('agent.dbo.ShareBonusLog')->insert([
+                    'UserID'     => $userId,
+                    'Higher1ID'  => $user->Higher1ID,
+                    'Reward'     => $reward,
+                    'Type'       => $type,
+                    'ActivityID' => $activity->id,
+                    'CreateTime' => Carbon::now()->format('Y-m-d H:i:s'),
+                ]);
+
+                if ($update)
+                    DB::connection('write')->table('agent.dbo.ActivityTurnplate')->where('UserID', $user->Higher1ID)->update($update);
 //            $user->increment('TotalReward', $amount);
+            }
+
+            return true;
+
+        } catch (\Exception $exception){
+            return false;
         }
 
+
+
         // 遍历上级邀请者并更新业绩
 //        foreach ($invitationChain as $level => [$Guid,$Uid]) {
 //

+ 21 - 7
app/Game/WebChannelConfig.php

@@ -11,6 +11,8 @@ define('SPECIAL_MODE_PWA_BONUS', 8);//安装app送钱
 define('SPECIAL_MODE_SMS_BONUS', 16);//手机验证送钱
 define('SPECIAL_MODE_MAIL_BONUS', 32);//MAIL验证送钱
 define('SPECIAL_MODE_FIRSTPAY_OFF30', 64);//首冲打开30%bonus
+define('SPECIAL_MODE_DEBUG_EVENT', 128);//是否开启事件日志上保
+define('SPECIAL_MODE_REGION_UNIQUE', 256);//是否开启区域独立模式
 class WebChannelConfig extends Model
 {
     protected $table = 'webgame.WebChannelConfig';
@@ -19,7 +21,7 @@ class WebChannelConfig extends Model
     protected $keyType = 'int';
     protected $connection = 'mysql';
     protected $fillable = [
-        'Channel', 'PackageName', 'Remarks', 'StateNo','SpecialMode', 'PlatformName', 'PlatformID','LoginOpen','RegOpen','BonusArr','ShadowChannel','LightApk','FullApk'
+        'Channel', 'PackageName', 'RegionID', 'Remarks', 'StateNo','SpecialMode', 'PlatformName', 'PlatformID','LoginOpen','RegOpen','BonusArr','ShadowChannel','LightApk','FullApk'
     ];
 
     private static $key='web_channel_config:';
@@ -86,6 +88,18 @@ class WebChannelConfig extends Model
     {
         return ($this->SpecialMode&SPECIAL_MODE_PWA_BONUS)==SPECIAL_MODE_PWA_BONUS;
     }
+    public function isDebugEvent()
+    {
+        return ($this->SpecialMode&SPECIAL_MODE_DEBUG_EVENT)==SPECIAL_MODE_DEBUG_EVENT;
+    }
+    public function isRegionUnique()
+    {
+        if(($this->SpecialMode&SPECIAL_MODE_REGION_UNIQUE)==SPECIAL_MODE_REGION_UNIQUE&&!empty($this->RegionID)){
+            return $this->RegionID;
+        }else{
+            return "";
+        }
+    }
     public function isGuestOpen()
     {
         return ($this->SpecialMode&SPECIAL_MODE_GUEST)==SPECIAL_MODE_GUEST;
@@ -99,16 +113,16 @@ class WebChannelConfig extends Model
     {
         $cacheKey = self::$key . $channel;
 
-//        $cachedConfig = Redis::get($cacheKey);
-//
-//        if ($cachedConfig) {
-//            return new WebChannelConfig(json_decode($cachedConfig,true));
-//        }
+        $cachedConfig = Redis::get($cacheKey);
+
+        if ($cachedConfig) {
+            return new self(json_decode($cachedConfig,true));
+        }
 
         $config = self::where('Channel', $channel)->first();
 
         if ($config) {
-            Redis::setex($cacheKey, 60, $config->toJson());
+            Redis::setex($cacheKey, 300, $config->toJson());
         }
 
         return $config;

+ 21 - 0
app/Game/WebRegionConfig.php

@@ -0,0 +1,21 @@
+<?php
+
+namespace App\Game;
+
+use Illuminate\Database\Eloquent\Model;
+
+class WebRegionConfig extends Model
+{
+    protected $table = 'webgame.WebRegionConfig';
+    protected $primaryKey = 'id';
+    public $timestamps = false;
+    protected $connection = 'mysql';
+
+    protected $fillable = [
+        'RegionID', 'DomainUrl', 'LogoUrl', 'IconUrl', 'BindChannels', 'GroupID'
+    ];
+
+    protected $casts = [
+        'BindChannels' => 'json',
+    ];
+}

+ 270 - 0
app/Http/Controllers/Admin/WebChannelConfigController.php

@@ -0,0 +1,270 @@
+<?php
+
+namespace App\Http\Controllers\Admin;
+
+use App\Game\WebChannelConfig;
+use App\Game\WebRegionConfig;
+use Illuminate\Http\Request;
+use Illuminate\Support\Facades\DB;
+use Illuminate\Support\Facades\Validator;
+
+class WebChannelConfigController
+{
+    protected $groupColors = [
+        0 => '#007bff', // blue
+        1 => '#28a745', // green
+        2 => '#ffc107', // yellow/orange
+        3 => '#dc3545', // red
+        4 => '#6f42c1', // purple
+        5 => '#17a2b8', // cyan
+        6 => '#6c757d', // gray
+        7 => '#e83e8c', // pink
+    ];
+
+    protected $specialModes = [
+        1 => 'GUEST (自动游客登录模式)',
+        2 => 'ZERO_MONEY (注册不送钱)',
+        4 => 'DISABLE_PROMOTE_INSTALL (提示安装)',
+        8 => 'PWA_BONUS (安装app送钱)',
+        16 => 'SMS_BONUS (手机验证送钱)',
+        32 => 'MAIL_BONUS (MAIL验证送钱)',
+        64 => 'FIRSTPAY_OFF30 (首冲打开30%bonus)',
+        128 => 'DEBUG_EVENT (是否开启事件日志上报)',
+        256 => 'REGION_UNIQUE (是否开启区域独立模式)',
+    ];
+
+    public function index(Request $request)
+    {
+        $channel = $request->input('Channel');
+        $packageName = $request->input('PackageName');
+
+        $query = WebChannelConfig::query();
+
+        if ($channel) {
+            $query->where('Channel', $channel);
+        }
+        if ($packageName) {
+            $query->where('PackageName', 'like', '%' . $packageName . '%');
+        }
+
+        $list = $query->orderBy('Channel', 'asc')->paginate(40);
+
+        $regions = WebRegionConfig::all();
+        $regionMap = [];
+        foreach ($regions as $region) {
+            $regionMap[$region->RegionID] = [
+                'color' => $this->groupColors[$region->GroupID] ?? '#000000',
+                'logo' => $region->DomainUrl . $region->LogoUrl,
+                'has_logo' => !empty($region->LogoUrl)
+            ];
+        }
+
+        return view('admin.web_channel_config.index', [
+            'list' => $list,
+            'channel' => $channel,
+            'packageName' => $packageName,
+            'regionMap' => $regionMap,
+        ]);
+    }
+
+    public function create()
+    {
+        $regionList = WebRegionConfig::orderBy('GroupID', 'asc')->get();
+        return view('admin.web_channel_config.add', [
+            'regionList' => $regionList,
+            'groupColors' => $this->groupColors,
+            'specialModes' => $this->specialModes
+        ]);
+    }
+
+    public function store(Request $request)
+    {
+        $data = $request->all();
+        $validator = Validator::make($data, [
+            'Channel' => 'required|integer',
+            'PackageName' => 'required|string|max:200',
+        ]);
+
+        if ($validator->fails()) {
+            return apiReturnFail($validator->errors()->first());
+        }
+
+        // 处理 BonusArr
+        $bonusArr = [
+            $request->input('BonusArr_REG', 0),
+            $request->input('BonusArr_MOBILE', 0),
+            $request->input('BonusArr_EMAIL', 0),
+            $request->input('BonusArr_PWA', 0),
+        ];
+        $data['BonusArr'] = implode('|', $bonusArr);
+
+        // 处理 LoginOpen 和 RegOpen (多选框)
+        $data['LoginOpen'] = $request->has('LoginOpen') ? implode(',', $request->input('LoginOpen')) : '';
+        $data['RegOpen'] = $request->has('RegOpen') ? implode(',', $request->input('RegOpen')) : '';
+
+        // 处理 SpecialMode (多选框位运算)
+        $specialMode = 0;
+        if ($request->has('SpecialMode') && is_array($request->input('SpecialMode'))) {
+            foreach ($request->input('SpecialMode') as $val) {
+                $specialMode += (int)$val;
+            }
+        }
+        $data['SpecialMode'] = $specialMode;
+
+        // 防止 null 报错
+        $data['ShadowChannel'] = $data['ShadowChannel'] ?? '';
+        $data['LightApk'] = $data['LightApk'] ?? '';
+        $data['FullApk'] = $data['FullApk'] ?? '';
+        $data['PlatformID'] = $data['PlatformID'] ?? '';
+        $data['RegionID'] = $data['RegionID'] ?? '';
+
+        $config = WebChannelConfig::create($data);
+
+        // 同步更新 WebRegionConfig 的 BindChannels
+        if (!empty($config->RegionID)) {
+            $region = WebRegionConfig::where('RegionID', $config->RegionID)->first();
+            if ($region) {
+                $bindChannels = is_array($region->BindChannels) ? $region->BindChannels : [];
+                if (!in_array($config->Channel, $bindChannels)) {
+                    $bindChannels[] = (int)$config->Channel;
+                    sort($bindChannels);
+                    $region->BindChannels = $bindChannels;
+                    $region->save();
+                }
+            }
+        }
+
+        return apiReturnSuc();
+    }
+
+    public function edit($id)
+    {
+        $info = WebChannelConfig::findOrFail($id);
+        $regionList = WebRegionConfig::orderBy('GroupID', 'asc')->get();
+        return view('admin.web_channel_config.edit', [
+            'info' => $info,
+            'regionList' => $regionList,
+            'groupColors' => $this->groupColors,
+            'specialModes' => $this->specialModes
+        ]);
+    }
+
+    public function update(Request $request, $id)
+    {
+        $data = $request->all();
+        $info = WebChannelConfig::findOrFail($id);
+        
+        $validator = Validator::make($data, [
+            'PackageName' => 'required|string|max:200',
+        ]);
+
+        if ($validator->fails()) {
+            return apiReturnFail($validator->errors()->first());
+        }
+
+        // 确保 Channel 不被修改
+        unset($data['Channel']);
+
+        // 处理 BonusArr
+        $bonusArr = [
+            $request->input('BonusArr_REG', 0),
+            $request->input('BonusArr_MOBILE', 0),
+            $request->input('BonusArr_EMAIL', 0),
+            $request->input('BonusArr_PWA', 0),
+        ];
+        $data['BonusArr'] = implode('|', $bonusArr);
+
+        // 处理 LoginOpen 和 RegOpen (多选框)
+        $data['LoginOpen'] = $request->has('LoginOpen') ? implode(',', $request->input('LoginOpen')) : '';
+        $data['RegOpen'] = $request->has('RegOpen') ? implode(',', $request->input('RegOpen')) : '';
+
+        // 处理 SpecialMode (多选框位运算)
+        $specialMode = 0;
+        if ($request->has('SpecialMode') && is_array($request->input('SpecialMode'))) {
+            foreach ($request->input('SpecialMode') as $val) {
+                $specialMode += (int)$val;
+            }
+        }
+        $data['SpecialMode'] = $specialMode;
+
+        // 防止 null 报错
+        $data['ShadowChannel'] = $data['ShadowChannel'] ?? '';
+        $data['LightApk'] = $data['LightApk'] ?? '';
+        $data['FullApk'] = $data['FullApk'] ?? '';
+        $data['PlatformID'] = $data['PlatformID'] ?? '';
+        $data['RegionID'] = $data['RegionID'] ?? '';
+
+        $oldRegionID = $info->RegionID;
+        $oldChannel = $info->Channel;
+        $oldSpecialMode = $info->SpecialMode;
+
+        // 一旦启用 REGION_UNIQUE,RegionID 不可更换同时 REGION_UNIQUE 选项不可更改
+        if (($oldSpecialMode & 256) == 256) {
+            $data['RegionID'] = $oldRegionID;
+            if (!in_array(256, $request->input('SpecialMode', []))) {
+                $specialMode += 256;
+                $data['SpecialMode'] = $specialMode;
+            }
+        }
+
+        $info->update($data);
+
+        // 如果 RegionID 或 Channel 发生变化,需要同步更新 WebRegionConfig
+        if ($oldRegionID != $info->RegionID || $oldChannel != $info->Channel) {
+            // 1. 从旧的 RegionID 中移除旧的 Channel
+            if (!empty($oldRegionID)) {
+                $oldRegion = WebRegionConfig::where('RegionID', $oldRegionID)->first();
+                if ($oldRegion) {
+                    $bindChannels = is_array($oldRegion->BindChannels) ? $oldRegion->BindChannels : [];
+                    $key = array_search($oldChannel, $bindChannels);
+                    if ($key !== false) {
+                        unset($bindChannels[$key]);
+                        $oldRegion->BindChannels = array_values($bindChannels);
+                        $oldRegion->save();
+                    }
+                }
+            }
+
+            // 2. 向新的 RegionID 中添加新的 Channel
+            if (!empty($info->RegionID)) {
+                $newRegion = WebRegionConfig::where('RegionID', $info->RegionID)->first();
+                if ($newRegion) {
+                    $bindChannels = is_array($newRegion->BindChannels) ? $newRegion->BindChannels : [];
+                    if (!in_array($info->Channel, $bindChannels)) {
+                        $bindChannels[] = (int)$info->Channel;
+                        sort($bindChannels);
+                        $newRegion->BindChannels = $bindChannels;
+                        $newRegion->save();
+                    }
+                }
+            }
+        }
+
+        return apiReturnSuc();
+    }
+
+    public function destroy($id)
+    {
+        $info = WebChannelConfig::findOrFail($id);
+        $channel = $info->Channel;
+        $regionID = $info->RegionID;
+
+        $info->delete();
+
+        // 删除时,从 WebRegionConfig 的 BindChannels 中移除该 Channel
+        if (!empty($regionID)) {
+            $region = WebRegionConfig::where('RegionID', $regionID)->first();
+            if ($region) {
+                $bindChannels = is_array($region->BindChannels) ? $region->BindChannels : [];
+                $key = array_search($channel, $bindChannels);
+                if ($key !== false) {
+                    unset($bindChannels[$key]);
+                    $region->BindChannels = array_values($bindChannels);
+                    $region->save();
+                }
+            }
+        }
+
+        return apiReturnSuc();
+    }
+}

+ 18 - 0
app/Http/Controllers/Admin/WebRegionConfigController.php

@@ -0,0 +1,18 @@
+<?php
+
+namespace App\Http\Controllers\Admin;
+
+use App\Game\WebRegionConfig;
+use Illuminate\Http\Request;
+
+class WebRegionConfigController
+{
+    public function index(Request $request)
+    {
+        $list = WebRegionConfig::orderBy('GroupID', 'asc')->orderBy('id', 'asc')->paginate(40);
+        
+        return view('admin.web_region_config.index', [
+            'list' => $list,
+        ]);
+    }
+}

+ 9 - 33
app/Http/Controllers/Game/ExtensionsController.php

@@ -193,7 +193,7 @@ class ExtensionsController
         } else{
             $record = [];
             for($i=0;$i<50;$i++){
-                $record[] = ['phone' => rand(1234, 9876) . '' . rand(1234, 9876) . '' . rand(12, 98), 'name' => rand(1, 100) > 10 ? $dao->randUserName('') : 'U' . rand(1234, 9876), 'amount' => 40];
+                $record[] = ['phone' => rand(1234, 9876) . '' . rand(1234, 9876) . '' . rand(12, 98), 'name' => rand(1, 100) > 10 ? $dao->randUserName('') : 'U' . rand(1234, 9876), 'amount' => rand(40,2000)];
 
             }
 
@@ -203,31 +203,7 @@ class ExtensionsController
 
 
 
-        if (Redis::exists('turnplate_numbers_1_'.$FPID)) {
-            $numbers = Redis::get('turnplate_numbers_1_'.$FPID);
-            $numbers = json_decode($numbers,true);
-        } else{
-            $numbers = [];
-//            for($i=0;$i<50;$i++){
-//                array_push($numbers,'55'.rand(1234,9876).''.rand(1234,9876).''.rand(12,98));
-//            }
-            $result=DB::connection('write')->select("SELECT TOP 20 ap.PhoneNum
-    FROM
-        QPAccountsDB.dbo.AccountPhone ap
-    INNER JOIN
-        QPAccountsDB.dbo.AccountsInfo ai ON ap.UserID = ai.UserID
-    WHERE
-        DATEDIFF(day, ai.LastLogonDate, GETDATE()) > 7
-    ORDER BY
-        NEWID()");
-            $numbers=array_map(function($item){
-                return '1'.trim($item->PhoneNum);
-            },$result);
-            Redis::set('turnplate_numbers_1_'.$FPID,json_encode($numbers));
-            Redis::expire('turnplate_numbers_1_'.$FPID, 86400*3);
-        }
-//        $httpserver=$_SERVER['HTTP_ORIGIN']??(@$_SERVER['HTTP_REFERER']?trim($_SERVER['HTTP_REFERER'],"/"):"https://24680.com");
-//        $link = $httpserver .'/#/cashwheel?act='.self::encodeAct($GlobalUID,'WheelFree100');
+        $numbers = [];
         $link = AgentService::getShareLink($GlobalUID??"",'WheelFree100');
 
         SetNXLock::release($redisKey);
@@ -294,11 +270,11 @@ class ExtensionsController
         $end = 0;
         $activity = DB::table('agent.dbo.ActivityTurnplate')
             ->where('UserID',$UserID)->first();
-        if($activity->State != 1){
-
-            return apiReturnFail(['web.turnplate.invalid','Invalid state']);
-
-        }
+//        if($activity->State != 1){
+//
+//            return apiReturnFail(['web.turnplate.invalid','Invalid state']);
+//
+//        }
 
         $redisKey = 'turnplate_bonus_'.$UserID;
         $res = SetNXLock::getExclusiveLock($redisKey, 5);
@@ -344,7 +320,7 @@ class ExtensionsController
 
             $writeConn->table('agent.dbo.ActivityTurnplate')
                 ->where('UserID', $UserID)
-                ->update(['State' => 2, 'Amount' => 0]);
+                ->delete();
 
             $writeConn->table('agent.dbo.ActivityTurnplateHistory')->insert($insertData);
 
@@ -366,7 +342,7 @@ class ExtensionsController
                 'BranchBank' => $withdrawInfo->BranchBank ?? '',
                 'OrderId' => $activity->id,
                 'PixNum' => $withdrawInfo->PixNum ?? '',
-                'PixType' => $withdrawInfo->PixType ?? 0,
+                'PixType' => $withdrawInfo->PixType ?? 1,
                 'score_type' => 2
             ]);
 

+ 3 - 0
app/Http/Controllers/Game/LoginController.php

@@ -194,6 +194,9 @@ class LoginController extends Controller
         $RecordPlatformDataModel = new \App\Models\RecordPlatformData();
         $RecordPlatformDataModel->BindToday($Channel,$user->RegisterDate);
 
+        AgentService::recordPerformance($UserID, 0,1);
+
+
         SetNXLock::release($redisKey);
         return apiReturnSuc(GlobalUserInfo::getGameUserInfoToWeb('UserID', $UserID));
         /**

+ 161 - 0
resources/views/admin/web_channel_config/add.blade.php

@@ -0,0 +1,161 @@
+@extends('base.base')
+@section('base')
+    <!-- 内容区域 -->
+    <div class="main-panel">
+        <div class="content-wrapper">
+            <div class="row">
+                <div class="col-lg-12 grid-margin stretch-card">
+                    <div class="card">
+                        <div class="card-body">
+                            <h4 class="card-title">{{ __('auto.添加配置') }}</h4>
+                            <form class="forms-sample" id="form">
+                                <div class="form-group">
+                                    <label>{{ __('auto.渠道号') }}</label>
+                                    <input type="number" class="form-control" name="Channel" value="99">
+                                </div>
+                                <div class="form-group">
+                                    <label>{{ __('auto.包名') }}</label>
+                                    <input type="text" class="form-control" name="PackageName">
+                                </div>
+                                <div class="form-group">
+                                    <label>RegionID</label>
+                                    <select class="form-control" name="RegionID">
+                                        <option value="">None</option>
+                                        @php $currentGroup = null; @endphp
+                                        @foreach($regionList as $v)
+                                            @if($currentGroup !== null && $currentGroup !== $v->GroupID)
+                                                <option disabled>----------</option>
+                                            @endif
+                                            <option value="{{$v->RegionID}}" style="color: {{$groupColors[$v->GroupID] ?? '#000000'}};">{{$v->RegionID}}</option>
+                                            @php $currentGroup = $v->GroupID; @endphp
+                                        @endforeach
+                                    </select>
+                                </div>
+                                <div class="form-group">
+                                    <label>{{ __('auto.备注') }}</label>
+                                    <input type="text" class="form-control" name="Remarks">
+                                </div>
+                                <div class="form-group">
+                                    <label>StateNo</label>
+                                    <input type="number" class="form-control" name="StateNo" value="1">
+                                </div>
+                                <div class="form-group">
+                                    <label>SpecialMode(特殊功能选择)</label>
+                                    <div class="row">
+                                        @foreach($specialModes as $val => $label)
+                                            <div class="col-sm-6">
+                                                <div class="form-check">
+                                                    <label class="form-check-label">
+                                                        <input type="checkbox" class="form-check-input" name="SpecialMode[]" value="{{$val}}"> {{$label}} ({{$val}})
+                                                    </label>
+                                                </div>
+                                            </div>
+                                        @endforeach
+                                    </div>
+                                </div>
+                                <div class="form-group">
+                                    <label>RegOpen(注册方式)</label>
+                                    <div class="row">
+                                        @foreach(['id','phone','sms','mail','guest'] as $v)
+                                            <div class="col-sm-2">
+                                                <div class="form-check">
+                                                    <label class="form-check-label">
+                                                        <input type="checkbox" class="form-check-input" name="RegOpen[]" value="{{$v}}" @if($v == 'phone') checked @endif> {{$v}}
+                                                    </label>
+                                                </div>
+                                            </div>
+                                        @endforeach
+                                    </div>
+                                </div>
+                                <div class="form-group">
+                                    <label>LoginOpen (登录方式)</label>
+                                    <div class="row">
+                                        @foreach(['id','phone','sms','mail','guest'] as $v)
+                                            <div class="col-sm-2">
+                                                <div class="form-check">
+                                                    <label class="form-check-label">
+                                                        <input type="checkbox" class="form-check-input" name="LoginOpen[]" value="{{$v}}" checked> {{$v}}
+                                                    </label>
+                                                </div>
+                                            </div>
+                                        @endforeach
+                                    </div>
+                                </div>
+                                <div class="form-group">
+                                    <label>PlatformName</label>
+                                    <select class="form-control" name="PlatformName">
+                                        <option value="">None</option>
+                                        <option value="fb">Facebook (fb)</option>
+                                        <option value="kwai">海外快手 (kwai)</option>
+                                        <option value="tt">Tiktok (tt)</option>
+                                        <option value="gg">Google (gg)</option>
+                                        <option value="apk">Apk落地页 (apk)</option>
+                                    </select>
+                                </div>
+                                <div class="form-group">
+                                    <label>PlatformID (pixel id)</label>
+                                    <input type="text" class="form-control" name="PlatformID">
+                                </div>
+                                <div class="form-group">
+                                    <label>BonusArr (REG | MOBILE | EMAIL | PWA)</label>
+                                    <div class="row">
+                                        <div class="col-sm-3">
+                                            <input type="number" class="form-control" name="BonusArr_REG" placeholder="REG" value="0">
+                                        </div>
+                                        <div class="col-sm-3">
+                                            <input type="number" class="form-control" name="BonusArr_MOBILE" placeholder="MOBILE" value="0">
+                                        </div>
+                                        <div class="col-sm-3">
+                                            <input type="number" class="form-control" name="BonusArr_EMAIL" placeholder="EMAIL" value="0">
+                                        </div>
+                                        <div class="col-sm-3">
+                                            <input type="number" class="form-control" name="BonusArr_PWA" placeholder="PWA" value="0">
+                                        </div>
+                                    </div>
+                                </div>
+                                <div class="form-group" style="display: none">
+                                    <label>ShadowChannel (rate%12|rate%13) </label>
+                                    <input type="text" class="form-control" name="ShadowChannel">
+                                </div>
+                                <div class="form-group">
+                                    <label>LightApk (twa) 下载URL</label>
+                                    <input type="text" class="form-control" name="LightApk">
+                                </div>
+                                <div class="form-group">
+                                    <label>FullApk (apk) 下载URL</label>
+                                    <input type="text" class="form-control" name="FullApk">
+                                </div>
+
+                                <button type="button" onclick="commit()" class="btn btn-sm btn-gradient-primary btn-icon-text">
+                                    <i class="mdi mdi-file-check btn-icon-prepend"></i>
+                                    {{ __('auto.提交') }}
+                                </button>
+                                <button type="button" onclick="cancel()" class="btn btn-sm btn-gradient-warning btn-icon-text">
+                                    <i class="mdi mdi-reload btn-icon-prepend"></i>
+                                    {{ __('auto.取消') }}
+                                </button>
+                            </form>
+                        </div>
+                    </div>
+                </div>
+            </div>
+        </div>
+    </div>
+    <script>
+        function commit() {
+            var data = $("#form").serializeObject();
+            myRequest("/admin/web_channel_config/add", "post", data, function (res) {
+                layer.msg(res.msg)
+                if (res.code == 200) {
+                    setTimeout(function () {
+                        parent.location.reload();
+                    }, 1500)
+                }
+            });
+        }
+        function cancel() {
+            var index = parent.layer.getFrameIndex(window.name);
+            parent.layer.close(index);
+        }
+    </script>
+@endsection

+ 171 - 0
resources/views/admin/web_channel_config/edit.blade.php

@@ -0,0 +1,171 @@
+@extends('base.base')
+@section('base')
+    <!-- 内容区域 -->
+    <div class="main-panel">
+        <div class="content-wrapper">
+            <div class="row">
+                <div class="col-lg-12 grid-margin stretch-card">
+                    <div class="card">
+                        <div class="card-body">
+                            <h4 class="card-title">{{ __('auto.修改配置') }}</h4>
+                            <form class="forms-sample" id="form">
+                                <div class="form-group">
+                                    <label>{{ __('auto.渠道号') }}</label>
+                                    <input type="number" class="form-control" name="Channel" value="{{$info->Channel}}" readonly>
+                                </div>
+                                <div class="form-group">
+                                    <label>{{ __('auto.包名') }}</label>
+                                    <input type="text" class="form-control" name="PackageName" value="{{$info->PackageName}}">
+                                </div>
+                                <div class="form-group">
+                                    @php $isRegionUnique = ($info->SpecialMode & 256) == 256; @endphp
+                                    <label>RegionID{{__('auto.虚拟区域ID(账号隔离)')}}</label>
+                                    <select class="form-control" name="RegionID" @if($isRegionUnique) disabled @endif>
+                                        <option value="" @if($info->RegionID == '') selected @endif>None</option>
+                                        @php $currentGroup = null; @endphp
+                                        @foreach($regionList as $v)
+                                            @if($currentGroup !== null && $currentGroup !== $v->GroupID)
+                                                <option disabled>----------</option>
+                                            @endif
+                                            <option value="{{$v->RegionID}}" style="color: {{$groupColors[$v->GroupID] ?? '#000000'}};" @if($info->RegionID == $v->RegionID) selected @endif>{{$v->RegionID}}</option>
+                                            @php $currentGroup = $v->GroupID; @endphp
+                                        @endforeach
+                                    </select>
+                                    @if($isRegionUnique)
+                                        <input type="hidden" name="RegionID" value="{{$info->RegionID}}">
+                                    @endif
+                                </div>
+                                <div class="form-group">
+                                    <label>{{ __('auto.备注') }}</label>
+                                    <input type="text" class="form-control" name="Remarks" value="{{$info->Remarks}}">
+                                </div>
+                                <div class="form-group">
+                                    <label>StateNo --- {{__('auto.模版状态编号')}}</label>
+                                    <input type="number" class="form-control" name="StateNo" value="{{$info->StateNo}}">
+                                </div>
+                                <div class="form-group">
+                                    <label>SpecialMode --- {{__('auto.特殊模式')}}</label>
+                                    <div class="row">
+                                        @foreach($specialModes as $val => $label)
+                                            <div class="col-sm-6">
+                                                <div class="form-check">
+                                                    <label class="form-check-label">
+                                                        <input type="checkbox" class="form-check-input" name="SpecialMode[]" value="{{$val}}" @if(($info->SpecialMode & $val) == $val) checked @endif @if($isRegionUnique && $val == 256) disabled @endif> {{$label}} ({{$val}})
+                                                    </label>
+                                                </div>
+                                            </div>
+                                        @endforeach
+                                    </div>
+                                    @if($isRegionUnique)
+                                        <input type="hidden" name="SpecialMode[]" value="256">
+                                    @endif
+                                </div>
+                                <div class="form-group">
+                                    <label>RegOpen --- {{__('auto.开放注册方式')}}</label>
+                                    <div class="row">
+                                        @php $regOpen = explode(',', $info->RegOpen); @endphp
+                                        @foreach(['id','phone','sms','mail','guest'] as $v)
+                                            <div class="col-sm-2">
+                                                <div class="form-check">
+                                                    <label class="form-check-label">
+                                                        <input type="checkbox" class="form-check-input" name="RegOpen[]" value="{{$v}}" @if(in_array($v, $regOpen)) checked @endif> {{$v}}
+                                                    </label>
+                                                </div>
+                                            </div>
+                                        @endforeach
+                                    </div>
+                                </div>
+                                <div class="form-group">
+                                    <label>LoginOpen --- {{__('auto.开放登录方式')}}</label>
+                                    <div class="row">
+                                        @php $loginOpen = explode(',', $info->LoginOpen); @endphp
+                                        @foreach(['id','phone','sms','mail','guest'] as $v)
+                                            <div class="col-sm-2">
+                                                <div class="form-check">
+                                                    <label class="form-check-label">
+                                                        <input type="checkbox" class="form-check-input" name="LoginOpen[]" value="{{$v}}" @if(in_array($v, $loginOpen)) checked @endif> {{$v}}
+                                                    </label>
+                                                </div>
+                                            </div>
+                                        @endforeach
+                                    </div>
+                                </div>
+                                <div class="form-group">
+                                    <label>PlatformName --- {{__('auto.平台名称')}}</label>
+                                    <select class="form-control" name="PlatformName">
+                                        <option value="" @if($info->PlatformName == '') selected @endif>None</option>
+                                        <option value="fb" @if($info->PlatformName == 'fb') selected @endif>Facebook (fb)</option>
+                                        <option value="kwai" @if($info->PlatformName == 'kwai') selected @endif>海外快手 (kwai)</option>
+                                        <option value="tt" @if($info->PlatformName == 'tt') selected @endif>Tiktok (tt)</option>
+                                        <option value="gg" @if($info->PlatformName == 'gg') selected @endif>Google (gg)</option>
+                                        <option value="apk" @if($info->PlatformName == 'apk') selected @endif>Apk落地页 (apk)</option>
+                                    </select>
+                                </div>
+                                <div class="form-group">
+                                    <label>PlatformID (eg:pixelid)</label>
+                                    <input type="text" class="form-control" name="PlatformID" value="{{$info->PlatformID}}">
+                                </div>
+                                <div class="form-group">
+                                    <label>BonusArr --- {{__('auto.(奖励数量/分)')}} (REG | MOBILE | EMAIL | PWA)</label>
+                                    @php $bonusArr = explode('|', $info->BonusArr); @endphp
+                                    <div class="row">
+                                        <div class="col-sm-3">
+                                            REG注册奖励<input type="number" class="form-control" name="BonusArr_REG" placeholder="REG" value="{{$bonusArr[0] ?? 0}}">
+                                        </div>
+                                        <div class="col-sm-3">
+                                            MOBILE绑定手机奖励<input type="number" class="form-control" name="BonusArr_MOBILE" placeholder="MOBILE" value="{{$bonusArr[1] ?? 0}}">
+                                        </div>
+                                        <div class="col-sm-3">
+                                            EMAIL验证邮箱奖励<input type="number" class="form-control" name="BonusArr_EMAIL" placeholder="EMAIL" value="{{$bonusArr[2] ?? 0}}">
+                                        </div>
+                                        <div class="col-sm-3">
+                                            PWA安装奖励<input type="number" class="form-control" name="BonusArr_PWA" placeholder="PWA" value="{{$bonusArr[3] ?? 0}}">
+                                        </div>
+                                    </div>
+                                </div>
+                                <div class="form-group" style="display: none">
+                                    <label>ShadowChannel (rate%12|rate%13)</label>
+                                    <input type="text" class="form-control" name="ShadowChannel" value="{{$info->ShadowChannel}}">
+                                </div>
+                                <div class="form-group">
+                                    <label>LightApk (twa) --- {{__('auto.轻应用地址')}}</label>
+                                    <input type="text" class="form-control" name="LightApk" value="{{$info->LightApk}}">
+                                </div>
+                                <div class="form-group">
+                                    <label>FullApk (apk) --- {{__('auto.完整应用地址')}}</label>
+                                    <input type="text" class="form-control" name="FullApk" value="{{$info->FullApk}}">
+                                </div>
+
+                                <button type="button" onclick="commit()" class="btn btn-sm btn-gradient-primary btn-icon-text">
+                                    <i class="mdi mdi-file-check btn-icon-prepend"></i>
+                                    {{ __('auto.提交') }}
+                                </button>
+                                <button type="button" onclick="cancel()" class="btn btn-sm btn-gradient-warning btn-icon-text">
+                                    <i class="mdi mdi-reload btn-icon-prepend"></i>
+                                    {{ __('auto.取消') }}
+                                </button>
+                            </form>
+                        </div>
+                    </div>
+                </div>
+            </div>
+        </div>
+    </div>
+    <script>
+        function commit() {
+            var data = $("#form").serializeObject();
+            myRequest("/admin/web_channel_config/update/{{$info->ID}}", "post", data, function (res) {
+                layer.msg(res.msg)
+                if (res.code == 200) {
+                    setTimeout(function () {
+                        parent.location.reload();
+                    }, 1500)
+                }
+            });
+        }
+        function cancel() {
+            var index = parent.layer.getFrameIndex(window.name);
+            parent.layer.close(index);
+        }
+    </script>
+@endsection

+ 116 - 0
resources/views/admin/web_channel_config/index.blade.php

@@ -0,0 +1,116 @@
+@extends('base.base')
+@section('base')
+    <!-- 内容区域 -->
+    <div class="main-panel">
+        <div class="content-wrapper">
+            <div class="page-header">
+                <h3 class="page-title">
+                     <span class="page-title-icon bg-gradient-primary text-white mr-2">
+                        <i class="mdi mdi-settings"></i>
+                    </span>
+                    {{ __('auto.投放渠道管理') }}
+                </h3>
+                <nav aria-label="breadcrumb">
+                    <ol class="breadcrumb">
+                        <li class="breadcrumb-item"><a href="#">{{ __('auto.渠道管理') }}</a></li>
+                        <li class="breadcrumb-item active" aria-current="page">{{ __('auto.投放渠道管理') }}</li>
+                    </ol>
+                </nav>
+            </div>
+            <div class="row">
+                <div class="col-lg-12 grid-margin stretch-card">
+                    <div class="card">
+                        <div class="card-body">
+                            <h4 class="card-title">{{ __('auto.投放渠道管理') }}</h4>
+                            <form class="well form-inline margin-top-20" method="get" action='/admin/web_channel_config/list'>
+                                <span style="padding-left: 5px">{{ __('auto.渠道号:') }}</span>
+                                <input type="text" name="Channel" value="{{$channel}}" class="form-control">&nbsp;&nbsp;
+                                <span style="padding-left: 5px">{{ __('auto.包名:') }}</span>
+                                <input type="text" name="PackageName" value="{{$packageName}}" class="form-control">&nbsp;&nbsp;
+                                <input type="submit" class="btn btn-sm btn-gradient-dark btn-icon-text" value="{{ __('auto.搜索') }}"/>&nbsp;&nbsp;
+                                <a href="/admin/web_channel_config/list" class="btn btn-sm btn-gradient-warning btn-icon-text">{{ __('auto.清空') }}&{{ __('auto.刷新') }}</a>&nbsp;&nbsp;
+                            </form>
+                            <br>
+{{--                            <button type="button" class="btn btn-sm btn-gradient-success btn-icon-text" onclick="add()">--}}
+{{--                                <i class="mdi mdi-plus btn-icon-prepend"></i>--}}
+{{--                                {{ __('auto.添加配置') }}--}}
+{{--                            </button>--}}
+                            <table class="table table-bordered">
+                                <thead>
+                                <tr>
+                                    <th>ID</th>
+                                    <th>{{ __('auto.渠道号') }}</th>
+                                    <th>{{ __('auto.包名') }}</th>
+                                    <th>RegionID</th>
+                                    <th>{{ __('auto.备注') }}</th>
+                                    <th>StateNo</th>
+                                    <th>Platform</th>
+                                    <th>BonusArr</th>
+                                    <th>{{ __('auto.操作') }}</th>
+                                </tr>
+                                </thead>
+                                <tbody>
+                                @foreach($list as $k=>$v)
+                                    <tr>
+                                        <td>{{$v->ID}}</td>
+                                        <td>{{$v->Channel}}</td>
+                                        <td>{{$v->PackageName}}</td>
+                                        <td>
+                                            @php
+                                                $regionInfo = $regionMap[$v->RegionID] ?? null;
+                                            @endphp
+                                            @if($regionInfo && $regionInfo['has_logo'])
+                                                <div style="background-color: #000; display: inline-block; padding: 2px;">
+                                                    <img src="{{$regionInfo['logo']}}" style="max-height: 30px; width: auto;" alt="Logo" title="{{$v->RegionID}}">
+                                                </div>
+                                            @else
+                                                <span style="color: {{$regionInfo['color'] ?? ''}}">{{$v->RegionID}}</span>
+                                            @endif
+                                        </td>
+                                        <td>{{$v->Remarks}}</td>
+                                        <td>{{$v->StateNo}}</td>
+                                        <td>{{$v->PlatformName}} ({{$v->PlatformID}})</td>
+                                        <td>{{$v->BonusArr}}</td>
+                                        <td>
+                                            <button class="btn btn-sm btn-gradient-dark" onclick="edit({{$v->ID}})">
+                                                {{ __('auto.修改') }}
+                                            </button>
+                                        </td>
+                                    </tr>
+                                @endforeach
+                                </tbody>
+                            </table>
+                            <div class="box-footer clearfix" id="pages">
+                                {{ __('auto.总共') }} <b>{{ $list->total() }}</b> {{ __('auto.条,分为') }}<b>{{ $list->lastPage() }}</b>{{ __('auto.页') }}
+                                {!! $list->appends(['Channel' => $channel, 'PackageName' => $packageName])->links() !!}
+                            </div>
+                        </div>
+                    </div>
+                </div>
+            </div>
+        </div>
+    </div>
+    <script>
+        function add() {
+            layer.open({
+                type: 2,
+                title: '{{ __('auto.添加配置') }}',
+                shadeClose: true,
+                shade: 0.8,
+                area: ['70%', '80%'],
+                content: '/admin/web_channel_config/add'
+            });
+        }
+
+        function edit(id) {
+            layer.open({
+                type: 2,
+                title: '{{ __('auto.修改配置') }}',
+                shadeClose: true,
+                shade: 0.8,
+                area: ['70%', '80%'],
+                content: '/admin/web_channel_config/update/' + id
+            });
+        }
+    </script>
+@endsection

+ 75 - 0
resources/views/admin/web_region_config/index.blade.php

@@ -0,0 +1,75 @@
+@extends('base.base')
+@section('base')
+    <!-- 内容区域 -->
+    <div class="main-panel">
+        <div class="content-wrapper">
+            <div class="page-header">
+                <h3 class="page-title">
+                     <span class="page-title-icon bg-gradient-primary text-white mr-2">
+                        <i class="mdi mdi-earth"></i>
+                    </span>
+                    {{ __('auto.虚拟分区配置') }}
+                </h3>
+                <nav aria-label="breadcrumb">
+                    <ol class="breadcrumb">
+                        <li class="breadcrumb-item"><a href="#">{{ __('auto.渠道管理') }}</a></li>
+                        <li class="breadcrumb-item active" aria-current="page">{{ __('auto.虚拟分区配置') }}</li>
+                    </ol>
+                </nav>
+            </div>
+            <div class="row">
+                <div class="col-lg-12 grid-margin stretch-card">
+                    <div class="card">
+                        <div class="card-body">
+                            <h4 class="card-title">{{ __('auto.分区列表') }}</h4>
+                            <table class="table table-bordered">
+                                <thead>
+                                <tr>
+                                    <th>ID</th>
+                                    <th>RegionID</th>
+                                    <th>DomainUrl</th>
+                                    <th>Logo</th>
+                                    <th>Icon</th>
+                                    <th>GroupID</th>
+                                    <th>BindChannels</th>
+                                </tr>
+                                </thead>
+                                <tbody>
+                                @foreach($list as $v)
+                                    <tr>
+                                        <td>{{$v->id}}</td>
+                                        <td>{{$v->RegionID}}</td>
+                                        <td>{{$v->DomainUrl}}</td>
+                                        <td>
+                                            @if($v->LogoUrl)
+                                                <div style="background-color: #000; display: inline-block; padding: 5px;">
+                                                    <img src="{{$v->DomainUrl}}{{$v->LogoUrl}}" style="max-width: 150px; height: auto; border-radius: 0;" alt="Logo">
+                                                </div>
+                                            @endif
+                                        </td>
+                                        <td>
+                                            @if($v->IconUrl)
+                                                <img src="{{$v->DomainUrl}}{{$v->IconUrl}}" style="width: 192px; height: 192px; border-radius: 0;" alt="Icon">
+                                            @endif
+                                        </td>
+                                        <td>{{$v->GroupID}}</td>
+                                        <td style="word-break: break-all; max-width: 300px;">
+                                            @if($v->BindChannels)
+                                                {{ is_array($v->BindChannels) ? implode(',', $v->BindChannels) : $v->BindChannels }}
+                                            @endif
+                                        </td>
+                                    </tr>
+                                @endforeach
+                                </tbody>
+                            </table>
+                            <div class="box-footer clearfix" id="pages">
+                                {{ __('auto.总共') }} <b>{{ $list->total() }}</b> {{ __('auto.条,分为') }}<b>{{ $list->lastPage() }}</b>{{ __('auto.页') }}
+                                {!! $list->links() !!}
+                            </div>
+                        </div>
+                    </div>
+                </div>
+            </div>
+        </div>
+    </div>
+@endsection

+ 12 - 0
routes/web.php

@@ -320,6 +320,18 @@ Route::group([
         $route->any('/user/money_deviation', 'Admin\UserController@moneyDeviation');
 
 
+        // 投放渠道管理
+        $route->get('/web_channel_config/list', 'Admin\WebChannelConfigController@index');
+        $route->get('/web_channel_config/add', 'Admin\WebChannelConfigController@create');
+        $route->post('/web_channel_config/add', 'Admin\WebChannelConfigController@store');
+        $route->get('/web_channel_config/update/{id}', 'Admin\WebChannelConfigController@edit');
+        $route->post('/web_channel_config/update/{id}', 'Admin\WebChannelConfigController@update');
+        $route->post('/web_channel_config/del/{id}', 'Admin\WebChannelConfigController@destroy');
+
+        // 虚拟分区配置查看
+        $route->get('/web_region_config/list', 'Admin\WebRegionConfigController@index');
+
+
         //实时数据
         $route->get('/livedata/gameinfo', 'Admin\LiveDataController@gameInfo');
         $route->get('/livedata/goldinfo', 'Admin\LiveDataController@goldInfo');