From 85a74c3aca51b02c0fb257e4ded874a3970915b3 Mon Sep 17 00:00:00 2001
From: liuweiwen <“529520975@qq.com>
Date: Fri, 29 Nov 2019 18:16:49 +0800
Subject: [PATCH 01/17] =?UTF-8?q?=E6=89=8B=E6=9C=BA=E5=AE=98=E7=BD=91?=
=?UTF-8?q?=E5=8F=91=E9=80=81=E9=AA=8C=E8=AF=81=E7=A0=81=E5=AD=97=E4=BD=93?=
=?UTF-8?q?=E5=A4=A7=E5=B0=8F?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
Public/Mobile/css/remove.css | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Public/Mobile/css/remove.css b/Public/Mobile/css/remove.css
index 08e5de8c5..127d48c3d 100644
--- a/Public/Mobile/css/remove.css
+++ b/Public/Mobile/css/remove.css
@@ -37,7 +37,7 @@
height:0.6rem;
background:rgba(33,177,235,1);
border-radius:0.3rem;
- font-size:0.15rem;
+ font-size:0.28rem;
font-family:PingFang SC;
font-weight:400;
color:rgba(255,255,255,1);
From 3754e5504a1e48ffecd9b96dd932b3f5e7b7c385 Mon Sep 17 00:00:00 2001
From: chenxiaojun <956334972@qq.com>
Date: Fri, 29 Nov 2019 18:18:33 +0800
Subject: [PATCH 02/17] =?UTF-8?q?=E6=89=8B=E6=9C=BA=E6=B3=A8=E5=86=8C?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
Application/Mobile/View/User/login.html | 2 +-
Application/Mobile/View/User/register.html | 10 +++++++++-
2 files changed, 10 insertions(+), 2 deletions(-)
diff --git a/Application/Mobile/View/User/login.html b/Application/Mobile/View/User/login.html
index d25a26c11..f92c2dc7d 100644
--- a/Application/Mobile/View/User/login.html
+++ b/Application/Mobile/View/User/login.html
@@ -29,7 +29,7 @@
-
+
diff --git a/Application/Mobile/View/User/register.html b/Application/Mobile/View/User/register.html
index 87ca0f859..70db4d9d5 100644
--- a/Application/Mobile/View/User/register.html
+++ b/Application/Mobile/View/User/register.html
@@ -59,12 +59,20 @@
var tis = this,that = $(tis);
if (that.hasClass('disabled')) {return false;}
var mobile = $.trim($('#mobile').val());
+ var promoteId = parseInt("{:I('get.pid',0)}");
+ var gameId = parseInt("{:I('get.gid',0)}");
+ var data = {};
+ if (promoteId > 0 && gameId > 0) {
+ data = {'phone':mobile,'promote_id':promoteId,'game_id':gameId};
+ } else {
+ data = {'phone':mobile};
+ }
if (mobile) {
if (/^1[0-9]{10}$/.test(mobile)) {
$.ajax({
type:'POST',
url:'{:U("sendsafecode")}',
- data:{'phone':mobile},
+ data:data,
async: false,
dataType:"Json",
success:function(data){
From c384a88c484e889a149d29a9881700da27c2f4c5 Mon Sep 17 00:00:00 2001
From: chenxiaojun <956334972@qq.com>
Date: Fri, 29 Nov 2019 18:27:19 +0800
Subject: [PATCH 03/17] =?UTF-8?q?=E6=89=8B=E6=9C=BA=E6=B3=A8=E5=86=8C?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
Application/Mobile/View/User/login.html | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Application/Mobile/View/User/login.html b/Application/Mobile/View/User/login.html
index f92c2dc7d..4248344a8 100644
--- a/Application/Mobile/View/User/login.html
+++ b/Application/Mobile/View/User/login.html
@@ -77,8 +77,8 @@
$('.submit').click(function(event) {
var mobile = $.trim($('#mobile').val());
var password = $.trim($('#password').val());
- var promoteId = parseInt("{:I('get.pid')}") ? parseInt("{:I('get.pid')}") : 0;
- var gameId = parseInt("{:I('get.gid')}") ? parseInt("{:I('get.gid')}") : 0;
+ var promoteId = parseInt("{:I('request.pid')}") ? parseInt("{:I('request.pid')}") : 0;
+ var gameId = parseInt("{:I('request.gid')}") ? parseInt("{:I('request.gid')}") : 0;
if (mobile) {
if (password) {
$.ajax({
From 676ab5dcd2d045622f48a5dca7f4a18ef8c3dbaa Mon Sep 17 00:00:00 2001
From: chenxiaojun <956334972@qq.com>
Date: Fri, 29 Nov 2019 18:57:37 +0800
Subject: [PATCH 04/17] =?UTF-8?q?=E6=89=8B=E6=9C=BA=E6=B3=A8=E5=86=8C?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
Application/Mobile/View/User/login.html | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/Application/Mobile/View/User/login.html b/Application/Mobile/View/User/login.html
index 4248344a8..02f345fb3 100644
--- a/Application/Mobile/View/User/login.html
+++ b/Application/Mobile/View/User/login.html
@@ -71,9 +71,9 @@
$(this).siblings("input").attr('type','password');
}
});
-
-
- var pmsg = $('.popmsg').pop();
+
+
+ var pmsg = $('.popmsg').pop();
$('.submit').click(function(event) {
var mobile = $.trim($('#mobile').val());
var password = $.trim($('#password').val());
From 28cd4aeeda8ac83d3f9b1389862527578f939a97 Mon Sep 17 00:00:00 2001
From: chenxiaojun <956334972@qq.com>
Date: Fri, 29 Nov 2019 18:58:04 +0800
Subject: [PATCH 05/17] =?UTF-8?q?=E6=97=A5=E5=BF=97?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
Application/Mobile/Controller/UserController.class.php | 1 +
1 file changed, 1 insertion(+)
diff --git a/Application/Mobile/Controller/UserController.class.php b/Application/Mobile/Controller/UserController.class.php
index e967dbe33..3d2064129 100644
--- a/Application/Mobile/Controller/UserController.class.php
+++ b/Application/Mobile/Controller/UserController.class.php
@@ -219,6 +219,7 @@ class UserController extends BaseController
public function bindingPromote($promoteId, $account)
{
+ Log::write('cxj_login:' . date('Y-m-d H:i:s') . ' ---- ' . $promoteId.'INFO');
if ($promoteId > 0) {
$wherePromote['id'] = $promoteId;
$promoteData = M('Promote', 'tab_')->field('id,account')->where($wherePromote)->find();
From f9b9694a4a5f2d5f549318ef5ad8cab332aa77c3 Mon Sep 17 00:00:00 2001
From: chenxiaojun <956334972@qq.com>
Date: Fri, 29 Nov 2019 19:07:09 +0800
Subject: [PATCH 06/17] =?UTF-8?q?=E6=97=A5=E5=BF=97?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
Application/Mobile/Controller/UserController.class.php | 1 +
1 file changed, 1 insertion(+)
diff --git a/Application/Mobile/Controller/UserController.class.php b/Application/Mobile/Controller/UserController.class.php
index 3d2064129..d685b2ba5 100644
--- a/Application/Mobile/Controller/UserController.class.php
+++ b/Application/Mobile/Controller/UserController.class.php
@@ -230,6 +230,7 @@ class UserController extends BaseController
$whereUser['mobile_phone'] = $account;
$userData = M('User', 'tab_')->where($whereUser)->find();
+ Log::write('cxj_login:' . date('Y-m-d H:i:s') . ' ---- userData' . json($userData) .'INFO');
if (!empty($userData)) {
if (empty($userData['promote_id'])) {
$saveData['promote_id'] = $promoteId;
From ce01823c6bbf3f8ad2a8dd378b00d98147c882b7 Mon Sep 17 00:00:00 2001
From: chenxiaojun <956334972@qq.com>
Date: Fri, 29 Nov 2019 19:10:26 +0800
Subject: [PATCH 07/17] =?UTF-8?q?=E6=97=A5=E5=BF=97?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
Application/Mobile/Controller/UserController.class.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Application/Mobile/Controller/UserController.class.php b/Application/Mobile/Controller/UserController.class.php
index d685b2ba5..abc338ad7 100644
--- a/Application/Mobile/Controller/UserController.class.php
+++ b/Application/Mobile/Controller/UserController.class.php
@@ -230,7 +230,7 @@ class UserController extends BaseController
$whereUser['mobile_phone'] = $account;
$userData = M('User', 'tab_')->where($whereUser)->find();
- Log::write('cxj_login:' . date('Y-m-d H:i:s') . ' ---- userData' . json($userData) .'INFO');
+ Log::write('cxj_login:' . date('Y-m-d H:i:s') . ' ---- userData' . json_encode($userData) .'INFO');
if (!empty($userData)) {
if (empty($userData['promote_id'])) {
$saveData['promote_id'] = $promoteId;
From fe6dd1ddff20283fcc0dc6e6fbf5be4aae788e88 Mon Sep 17 00:00:00 2001
From: liaojinling <360197197@qq.com>
Date: Sat, 30 Nov 2019 09:37:48 +0800
Subject: [PATCH 08/17] =?UTF-8?q?=E6=94=B9=E6=88=90=E6=97=A7=E7=9A=84?=
=?UTF-8?q?=E6=89=93=E5=8C=85=E6=96=B9=E5=BC=8F?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
Application/Base/Service/GameSourceService.class.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Application/Base/Service/GameSourceService.class.php b/Application/Base/Service/GameSourceService.class.php
index 86aa33018..137d68e82 100644
--- a/Application/Base/Service/GameSourceService.class.php
+++ b/Application/Base/Service/GameSourceService.class.php
@@ -9,7 +9,7 @@ use GuzzleHttp\Client;
class GameSourceService {
- const IS_FIXED_IOS13 = true;
+ const IS_FIXED_IOS13 = false;
const DEBUG = true;
public function __construct()
From 9a25fd0a04f8c94c258b0070063f8fad4932c7fa Mon Sep 17 00:00:00 2001
From: liaojinling <360197197@qq.com>
Date: Sat, 30 Nov 2019 10:28:17 +0800
Subject: [PATCH 09/17] =?UTF-8?q?=E4=BF=AE=E6=94=B9bug?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../Home/Controller/ApplyController.class.php | 12 ++++++++++--
Application/Home/View/default/Apply/my_game.html | 3 ++-
2 files changed, 12 insertions(+), 3 deletions(-)
diff --git a/Application/Home/Controller/ApplyController.class.php b/Application/Home/Controller/ApplyController.class.php
index 374ae8d03..18b02e1b3 100644
--- a/Application/Home/Controller/ApplyController.class.php
+++ b/Application/Home/Controller/ApplyController.class.php
@@ -1756,8 +1756,12 @@ class ApplyController extends BaseController
public function getDownloadUrl()
{
$gameId = I('game_id', 0);
+ $promoteId = I('promote_id', 0);
$promote = $this->getLoginPromote();
- $apply = M('apply', 'tab_')->where(['promote_id' => $promote['id'], 'game_id' => $gameId])->find();
+ if ($promoteId == 0) {
+ $promoteId = $promote['id'];
+ }
+ $apply = M('apply', 'tab_')->where(['promote_id' => $promoteId, 'game_id' => $gameId])->find();
$game = M('game', 'tab_')->field(['icon'])->where(['id' => $gameId])->find();
if ($apply == null) {
$this->ajaxReturn([
@@ -1793,8 +1797,12 @@ class ApplyController extends BaseController
public function getLandingPageUrl()
{
$gameId = I('game_id', 0);
+ $promoteId = I('promote_id', 0);
$promote = $this->getLoginPromote();
- $apply = M('apply', 'tab_')->where(['promote_id' => $promote['id'], 'game_id' => $gameId])->find();
+ if ($promoteId == 0) {
+ $promoteId = $promote['id'];
+ }
+ $apply = M('apply', 'tab_')->where(['promote_id' => $promoteId, 'game_id' => $gameId])->find();
$game = M('game', 'tab_')->field(['icon'])->where(['id' => $gameId])->find();
if ($apply == null) {
$this->ajaxReturn([
diff --git a/Application/Home/View/default/Apply/my_game.html b/Application/Home/View/default/Apply/my_game.html
index 33dff8572..36764e55b 100644
--- a/Application/Home/View/default/Apply/my_game.html
+++ b/Application/Home/View/default/Apply/my_game.html
@@ -837,6 +837,7 @@
var linkTag = this
var gameId = parseInt($(this).attr('data-game-id'))
var type = $(this).attr('data-type')
+ var promoteId = "{:I('promote_id', 0)}";
var url = ''
if (type == 'download') {
url = "__URL__/getDownloadUrl"
@@ -847,7 +848,7 @@
url: url,
type: 'post',
dataType: "json",
- data: {game_id: gameId},
+ data: {game_id: gameId, promote_id: promoteId},
success: function (response) {
if (response.status == 1) {
var qrcodeWidth = 200
From 5b743b545519297e0258de4cd92291a8bfb9633e Mon Sep 17 00:00:00 2001
From: liaojinling <360197197@qq.com>
Date: Sat, 30 Nov 2019 10:58:17 +0800
Subject: [PATCH 10/17] =?UTF-8?q?=E4=BF=AE=E6=94=B9?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
Application/Home/Controller/HomeController.class.php | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Application/Home/Controller/HomeController.class.php b/Application/Home/Controller/HomeController.class.php
index 97d6a27b6..dc41372b5 100644
--- a/Application/Home/Controller/HomeController.class.php
+++ b/Application/Home/Controller/HomeController.class.php
@@ -206,9 +206,9 @@ class HomeController extends Controller
$game['flooring_page_imgs'] = $imageUrls;
$isNewIos = false;
- if ($gameSource['create_time'] > strtotime(date('2019-11-27 00:00:00'))) {
+ /* if ($gameSource['create_time'] > strtotime(date('2019-11-27 00:00:00'))) {
$isNewIos = true;
- }
+ } */
$downloadUrl = '';
if (!$isNewIos && $isIOS13) {
From 3cfce8675e3d2ad9b3794596adc1a9a0c80ca1ba Mon Sep 17 00:00:00 2001
From: liaojinling <360197197@qq.com>
Date: Sat, 30 Nov 2019 11:07:41 +0800
Subject: [PATCH 11/17] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=AF=8F=E5=88=86?=
=?UTF-8?q?=E9=92=9F=E6=89=93=E5=8C=85=E6=95=B0=E9=87=8F?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
Application/Admin/Controller/AutoPackController.class.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Application/Admin/Controller/AutoPackController.class.php b/Application/Admin/Controller/AutoPackController.class.php
index 713f67a4f..622619e61 100644
--- a/Application/Admin/Controller/AutoPackController.class.php
+++ b/Application/Admin/Controller/AutoPackController.class.php
@@ -301,7 +301,7 @@ class AutoPackController extends Think
$applys = M('apply', 'tab_')->field('id,game_id,game_name,promote_id,promote_account,sdk_version')
->where($map)
->order('bale_sort desc,id desc')
- ->limit(12)
+ ->limit(15)
->select();
if (count($applys) == 0) {
From 1204b1a0e89928254ffbe100bdaa39f26b57d913 Mon Sep 17 00:00:00 2001
From: liaojinling <360197197@qq.com>
Date: Sat, 30 Nov 2019 12:25:24 +0800
Subject: [PATCH 12/17] =?UTF-8?q?=E4=BF=AE=E6=94=B9?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
Application/Base/Service/GameSourceService.class.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Application/Base/Service/GameSourceService.class.php b/Application/Base/Service/GameSourceService.class.php
index 137d68e82..86aa33018 100644
--- a/Application/Base/Service/GameSourceService.class.php
+++ b/Application/Base/Service/GameSourceService.class.php
@@ -9,7 +9,7 @@ use GuzzleHttp\Client;
class GameSourceService {
- const IS_FIXED_IOS13 = false;
+ const IS_FIXED_IOS13 = true;
const DEBUG = true;
public function __construct()
From ca4f1954e47f778775391307a4ac31e944d47253 Mon Sep 17 00:00:00 2001
From: liaojinling <360197197@qq.com>
Date: Sat, 30 Nov 2019 14:55:17 +0800
Subject: [PATCH 13/17] =?UTF-8?q?=E4=BF=AE=E6=94=B9bug?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
Application/Base/Service/GameSourceService.class.php | 1 +
1 file changed, 1 insertion(+)
diff --git a/Application/Base/Service/GameSourceService.class.php b/Application/Base/Service/GameSourceService.class.php
index 86aa33018..4b29cf111 100644
--- a/Application/Base/Service/GameSourceService.class.php
+++ b/Application/Base/Service/GameSourceService.class.php
@@ -194,6 +194,7 @@ class GameSourceService {
];
}
+ $params['packageUrl'] = C('DOMAIN_DOWNLOAD') . ltrim($originalUrl, '.');
$params['type'] = 'org';
$result = $this->createPlist($params);
if ($result['status']) {
From d5dc2396f235d41cf9a4af01c1a7445dba7dfa31 Mon Sep 17 00:00:00 2001
From: liaojinling <360197197@qq.com>
Date: Sat, 30 Nov 2019 23:54:14 +0800
Subject: [PATCH 14/17] =?UTF-8?q?=E4=BF=AE=E6=94=B9?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
Application/Base/Tool/Request.class.php | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Application/Base/Tool/Request.class.php b/Application/Base/Tool/Request.class.php
index c7fe8b38e..283a670ee 100644
--- a/Application/Base/Tool/Request.class.php
+++ b/Application/Base/Tool/Request.class.php
@@ -33,7 +33,7 @@ class Request {
{
$isMobile = false;
$userAgent = $this->getUserAgent();
- $mobileAgents = ['Android', 'iPhone', 'SymbianOS', 'Windows Phone', 'iPad','iPod'];
+ $mobileAgents = ['Android', 'iPhone', 'SymbianOS', 'Windows Phone', 'iPad', 'iPod'];
foreach ($mobileAgents as $mobileAgent) {
if (stripos($userAgent, $mobileAgent) !== false) {
$isMobile = true;
@@ -45,7 +45,7 @@ class Request {
public function isIOS()
{
$userAgent = $this->getUserAgent();
- if(stripos($userAgent, 'iphone') !== false || strpos($userAgent, 'ipad') !== false) {
+ if(stripos($userAgent, 'iphone') !== false || stripos($userAgent, 'ipad') !== false || stripos($userAgent, 'ipod') !== false) {
return true;
}
return false;
From acf2ff131016f1f7e68a6a0cd46d2a9b96077324 Mon Sep 17 00:00:00 2001
From: chenxiaojun <956334972@qq.com>
Date: Mon, 2 Dec 2019 10:47:52 +0800
Subject: [PATCH 15/17] ios13.1
---
Application/Mobile/Controller/UserController.class.php | 8 +++++---
Application/Mobile/View/User/register.html | 9 +--------
2 files changed, 6 insertions(+), 11 deletions(-)
diff --git a/Application/Mobile/Controller/UserController.class.php b/Application/Mobile/Controller/UserController.class.php
index abc338ad7..4a9c24b41 100644
--- a/Application/Mobile/Controller/UserController.class.php
+++ b/Application/Mobile/Controller/UserController.class.php
@@ -219,7 +219,6 @@ class UserController extends BaseController
public function bindingPromote($promoteId, $account)
{
- Log::write('cxj_login:' . date('Y-m-d H:i:s') . ' ---- ' . $promoteId.'INFO');
if ($promoteId > 0) {
$wherePromote['id'] = $promoteId;
$promoteData = M('Promote', 'tab_')->field('id,account')->where($wherePromote)->find();
@@ -230,7 +229,6 @@ class UserController extends BaseController
$whereUser['mobile_phone'] = $account;
$userData = M('User', 'tab_')->where($whereUser)->find();
- Log::write('cxj_login:' . date('Y-m-d H:i:s') . ' ---- userData' . json_encode($userData) .'INFO');
if (!empty($userData)) {
if (empty($userData['promote_id'])) {
$saveData['promote_id'] = $promoteId;
@@ -405,7 +403,11 @@ class UserController extends BaseController
$pgInfo = strval(cookie('pgInfo'));
Log::write('register:' . date('Y-m-d H:i:s') . ' ---- ' . json_encode($_POST) . ' --- ' . $pgInfo, 'INFO');
if (isset($_POST['promote_id']) && !empty($_POST['promote_id'])) {
- $pid = $this->suser->register($phone, $password, $phone, $register_way, $register_type, $_POST['promote_id'], $_POST['promote_account'], $sex, $nickname, $head_img);
+ Log::write('cxj_register:' . date('Y-m-d H:i:s') . ' ---- post' . json_encode($_POST) .' --- INFO');
+ $thisPromoteAccount = M('promote', 'tab_')->where(array('id' => $_POST['promote_id']))->getField('account');
+ $thisPromoteAccount = !empty($thisPromoteAccount) ? $thisPromoteAccount : '自然注册';
+ $promoteAccount = isset($_POST['promote_account']) ? $_POST['promote_account'] : $thisPromoteAccount;
+ $pid = $this->suser->register($phone, $password, $phone, $register_way, $register_type, $_POST['promote_id'], $promoteAccount, $sex, $nickname, $head_img);
} else {
$pid = $this->suser->register($phone, $password, $phone, $register_way, $register_type, '', '', $sex, $nickname, $head_img);
}
diff --git a/Application/Mobile/View/User/register.html b/Application/Mobile/View/User/register.html
index 70db4d9d5..3dab79e91 100644
--- a/Application/Mobile/View/User/register.html
+++ b/Application/Mobile/View/User/register.html
@@ -59,14 +59,7 @@
var tis = this,that = $(tis);
if (that.hasClass('disabled')) {return false;}
var mobile = $.trim($('#mobile').val());
- var promoteId = parseInt("{:I('get.pid',0)}");
- var gameId = parseInt("{:I('get.gid',0)}");
- var data = {};
- if (promoteId > 0 && gameId > 0) {
- data = {'phone':mobile,'promote_id':promoteId,'game_id':gameId};
- } else {
- data = {'phone':mobile};
- }
+ var data = {'phone':mobile};
if (mobile) {
if (/^1[0-9]{10}$/.test(mobile)) {
$.ajax({
From fa9d40f87acbb0ee30cacc04d4b2235cdf6fa006 Mon Sep 17 00:00:00 2001
From: yulingwei <2436953959@qq.com>
Date: Mon, 2 Dec 2019 11:26:45 +0800
Subject: [PATCH 16/17] =?UTF-8?q?=E6=96=B0=E5=A2=9E=E9=A3=8E=E6=8E=A7?=
=?UTF-8?q?=E6=A0=87=E8=AF=86?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../Controller/MemberController.class.php | 24 +++++++++++++++++++
.../Admin/View/Member/device_bans_edit.html | 5 +++-
.../Admin/View/Member/device_bans_list.html | 4 +++-
Data/update.sql | 6 ++++-
4 files changed, 36 insertions(+), 3 deletions(-)
diff --git a/Application/Admin/Controller/MemberController.class.php b/Application/Admin/Controller/MemberController.class.php
index afde5599c..c57b0849f 100644
--- a/Application/Admin/Controller/MemberController.class.php
+++ b/Application/Admin/Controller/MemberController.class.php
@@ -1231,6 +1231,24 @@ class MemberController extends ThinkController
}
$list = M('device_bans', 'tab_')->where($map)->page($p, $row)->select();
$count = M('device_bans', 'tab_')->where($map)->count();
+ if (!empty($list)) {
+ foreach ($list as &$item) {
+ switch ($item['type']) {
+ case '1':
+ $item['type_name'] = '设备号';
+ break;
+ case '2':
+ $item['type_name'] = 'IP';
+ break;
+ case '3':
+ $item['type_name'] = '落地页链接';
+ break;
+ case '4':
+ $item['type_name'] = '下载链接';
+ break;
+ }
+ }
+ }
$page = set_pagination($count, $row);
if ($page) {
$this->assign('_page', $page);
@@ -1249,9 +1267,15 @@ class MemberController extends ThinkController
if (empty($type) || empty($tag)) {
return $this->error("请填写完整信息");
}
+ if (\in_array($type, [3,4]) && !preg_match("/^((https|http|ftp|rtsp|mms)?:\/\/)[^\s]+/i", $tag)) {
+ return $this->error("请填写正确的url地址");
+ }
if ($type == 2 && !preg_match("/(\.((2(5[0-5]|[0-4]\d))|[0-1]?\d{1,2})){3}/i", $tag)) {
return $this->error("请填写正确的ip信息,如127.0.0.1");
}
+ if ($type == 1 && (preg_match("/(\.((2(5[0-5]|[0-4]\d))|[0-1]?\d{1,2})){3}/i", $tag) || preg_match("/^((https|http|ftp|rtsp|mms)?:\/\/)[^\s]+/i", $tag))) {
+ return $this->error("请填写正确的设备信息");
+ }
$map['type'] = $type;
$map['tag'] = $tag;
$item = M('device_bans', 'tab_')->where($map)->find();
diff --git a/Application/Admin/View/Member/device_bans_edit.html b/Application/Admin/View/Member/device_bans_edit.html
index 275ac0adc..5d1ba903d 100644
--- a/Application/Admin/View/Member/device_bans_edit.html
+++ b/Application/Admin/View/Member/device_bans_edit.html
@@ -11,10 +11,13 @@
-
+
+
diff --git a/Application/Admin/View/Member/device_bans_list.html b/Application/Admin/View/Member/device_bans_list.html
index e3549e2bf..9eb370005 100644
--- a/Application/Admin/View/Member/device_bans_list.html
+++ b/Application/Admin/View/Member/device_bans_list.html
@@ -48,6 +48,8 @@
+
+
@@ -95,7 +97,7 @@
{$data.id} |
- |
+ {$data.type_name} |
{$data.tag} |
{:get_admin_nickname($data['operator_id'])} |
{$data.create_time|date='Y-m-d H:i:s',###} |
diff --git a/Data/update.sql b/Data/update.sql
index 924ff99c5..1490c7dbf 100644
--- a/Data/update.sql
+++ b/Data/update.sql
@@ -608,4 +608,8 @@ promote_account_to:修改后账号
remark:备注
create_time:时间
op_account:操作人账号
-order_time:切分时间' WHERE `id` = 29;
\ No newline at end of file
+order_time:切分时间' WHERE `id` = 29;
+
+--新增风控类型
+ALTER TABLE `tab_device_bans`
+MODIFY COLUMN `type` tinyint(1) UNSIGNED NOT NULL DEFAULT 0 COMMENT '类型 0未知 1设备号 2IP 3落地页链接 4下载链接' AFTER `tag`;
From bd46fd325b146cf31fa81242c59a3efc6100522b Mon Sep 17 00:00:00 2001
From: ELF <360197197@qq.com>
Date: Mon, 2 Dec 2019 11:42:26 +0800
Subject: [PATCH 17/17] =?UTF-8?q?=E5=90=8E=E5=8F=B0=E6=B7=BB=E5=8A=A0?=
=?UTF-8?q?=E7=A6=81=E7=94=A8=E8=90=BD=E5=9C=B0=E9=A1=B5=E4=B8=8B=E8=BD=BD?=
=?UTF-8?q?=E9=A1=B5=E5=9C=B0=E5=9D=80?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
Application/Home/Controller/HomeController.class.php | 3 ++-
Application/Home/Controller/PackageController.class.php | 4 ++--
2 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/Application/Home/Controller/HomeController.class.php b/Application/Home/Controller/HomeController.class.php
index dc41372b5..9254e4332 100644
--- a/Application/Home/Controller/HomeController.class.php
+++ b/Application/Home/Controller/HomeController.class.php
@@ -141,7 +141,8 @@ class HomeController extends Controller
if ($code == '' && ($gameId == 0 || $promoteId == 0)) {
$this->error('访问错误');
}
- $blackList = [];
+
+ $blackList = M('device_bans', 'tab_')->where(['type' => 3])->getField('tag', true);
if (in_array($code, $blackList) || in_array('gid/' . $gameId . '/pid/' . $promoteId, $blackList)) {
$this->error('该链接已被禁');
}
diff --git a/Application/Home/Controller/PackageController.class.php b/Application/Home/Controller/PackageController.class.php
index ebd8279c8..580cc849d 100644
--- a/Application/Home/Controller/PackageController.class.php
+++ b/Application/Home/Controller/PackageController.class.php
@@ -30,12 +30,12 @@ class PackageController extends Controller
$code = I('code', '');
$gameId = I('game_id', 0);
$promoteId = I('promote_id', 0);
-// var_dump($gameId, $promoteId);die();
+
if ($code == '' && ($gameId == 0 || $promoteId == 0)) {
$this->redirect("package/downloadError", ['message' => '访问错误']);
}
- $blackList = [];
+ $blackList = M('device_bans', 'tab_')->where(['type' => 4])->getField('tag', true);
if (in_array($code, $blackList) || in_array('game_id/' . $gameId . '/promote_id/' . $promoteId, $blackList)) {
$this->redirect("package/downloadError", ['message' => '该链接已被禁']);
}