Merge branch 'dev' of 47.111.118.107:/srv/git/platform into dev

master
ELF 5 years ago
commit 01dfe50442

@ -3,10 +3,10 @@ namespace Admin\Event;
use Think\Controller;
/**
* 后台事件控制器
* @author 王贺
* @author 王贺
*/
class UserEvent extends BaseEvent {
public function lists($model=null,$p=1,$extends_map=array()){
parent::custom_list($model,$p,$extends_map);
}
@ -31,7 +31,7 @@ class UserEvent extends BaseEvent {
}
}
if(isset($_REQUEST['row'])) {$row = $_REQUEST['row'];}else{$row = 10;}
if(isset($_REQUEST['row'])) {$row = $_REQUEST['row'];}else{$row = 10;}
//读取模型数据列表
$name = $model['m_name'];
@ -56,22 +56,22 @@ class UserEvent extends BaseEvent {
->group('tab_user.id')
->where($map)
->select();
$count=count($count);
//分页
$page = set_pagination($count,$row);
if($page) {$this->assign('_page', $page);}
$count=count($count);
//分页
$page = set_pagination($count,$row);
if($page) {$this->assign('_page', $page);}
$this->assign('model', $model);
$this->assign('list_data', $data);
$this->assign('count', $count);
$this->meta_title = $model['title'].'列表';
$this->display($model['template_list']);
}
public function user_join_($model = null, $p = 0){
public function user_join_($model = null, $p = 0){
$model || $this->error('模型名标识必须!');
$page = intval($p);
$page = $page ? $page : 1; //默认显示第一页数据
@ -80,8 +80,8 @@ class UserEvent extends BaseEvent {
// 关键字搜索
if(isset($_REQUEST['row'])) {$row = $_REQUEST['row'];}else{$row = 10;}
if(isset($_REQUEST['row'])) {$row = $_REQUEST['row'];}else{$row = 10;}
// $row = 1;
//读取模型数据列表
$name = $model['m_name'];
@ -114,27 +114,27 @@ class UserEvent extends BaseEvent {
/* 数据分页 */
/* 执行查询 */
->count();
if($model['ranking']==1){
if($model['ranking']==1){
$i=($page-1)*$row;
foreach ($data as $key => $value) {
$ss[++$i]=$value;
$ss[++$i]=$value;
}
$this->assign('list_data', $ss);
}else{
$this->assign('list_data', $data);
}
//分页
$page = set_pagination($count,$row);
if($page) {$this->assign('_page', $page);}
$this->assign('list_data', $ss);
}else{
$this->assign('list_data', $data);
}
//分页
$page = set_pagination($count,$row);
if($page) {$this->assign('_page', $page);}
$this->assign('model', $model);
$this->meta_title = $model['title'].'列表';
$this->display($model['template_list']);
}
public function user_join_v1($model = null, $p = 0){
public function user_join_v1($model = null, $p = 0){
$model || $this->error('模型名标识必须!');
$page = intval($p);
$page = $page ? $page : 1; //默认显示第一页数据
@ -156,8 +156,8 @@ class UserEvent extends BaseEvent {
}
}
if(isset($_REQUEST['row'])) {$row = $_REQUEST['row'];}else{$row = 10;}
if(isset($_REQUEST['row'])) {$row = $_REQUEST['row'];}else{$row = 50;}
//读取模型数据列表
$name = $model['m_name'];
@ -175,12 +175,27 @@ class UserEvent extends BaseEvent {
->page($page, $row)
/* 执行查询 */
->select();
$count=count($data);
//分页
$page = set_pagination($count,$row);
if($page) {$this->assign('_page', $page);}
$count = M($name,"tab_")
->field($model['fields'])
->join($model['join'])
->join($model['joins'])
->join($model['joinss'])
// 查询条件
->where($model['map'])
/* 默认通过id逆序排列 */
->order($model['order'])
->group($model['group'])
/* 数据分页 */
/* 执行查询 */
->count();
//$count=count($data);
//分页
$page = set_pagination($count,$row);
if($page) {$this->assign('_page', $page);}
if($_REQUEST['data_order']!=''){
$data_order=reset(explode(',',$_REQUEST['data_order']));
$data_order_type=end(explode(',',$_REQUEST['data_order']));
@ -188,10 +203,10 @@ class UserEvent extends BaseEvent {
$this->assign('userarpu_order_type',$data_order_type);
}
$data=my_sort($data,$data_order_type,(int)$data_order);
$size=$row;//每页显示的记录数
$pnum = ceil(count($data) / $size); //总页数ceil()函数用于求大于数字的最小整数
//$size=$row;//每页显示的记录数
//$pnum = ceil(count($data) / $size); //总页数ceil()函数用于求大于数字的最小整数
//用array_slice(array,offset,length) 函数在数组中根据条件取出一段值;array(数组),offset(元素的开始位置),length(组的长度)
$data = array_slice($data, ($arraypage-1)*$size, $size);
//$data = array_slice($data, ($arraypage-1)*$size, $size);
$this->assign('model', $model);
$this->assign('list_data', $data);
$this->meta_title = $model['title'].'列表';
@ -220,8 +235,8 @@ class UserEvent extends BaseEvent {
}
}
if(isset($_REQUEST['row'])) {$row = $_REQUEST['row'];}else{$row = 10;}
if(isset($_REQUEST['row'])) {$row = $_REQUEST['row'];}else{$row = 10;}
//读取模型数据列表
$name = $model['m_name'];
@ -239,12 +254,12 @@ class UserEvent extends BaseEvent {
->page($page, $row)
/* 执行查询 */
->select();
$count=count($data);
//分页
$page = set_pagination($count,$row);
if($page) {$this->assign('_page', $page);}
$count=count($data);
//分页
$page = set_pagination($count,$row);
if($page) {$this->assign('_page', $page);}
if($_REQUEST['data_order']!=''){
$data_order=reset(explode(',',$_REQUEST['data_order']));
$data_order_type=end(explode(',',$_REQUEST['data_order']));
@ -266,19 +281,19 @@ class UserEvent extends BaseEvent {
/**
*获取用户实体
*@param int $id
*@return array
*@author 小纯洁
*/
*获取用户实体
*@param int $id
*@return array
*@author 小纯洁
*/
public function user_entity($id=0){
$user = M("user","tab_");
$map['id'] = $id;
$data = $user->where($map)->find();
$user = M("user","tab_");
$map['id'] = $id;
$data = $user->where($map)->find();
if(is_numeric($data['head_img'])){
$data['head_img'] = get_cover($data['head_img'],'path');
}
return $data;
return $data;
}
}

@ -34,14 +34,14 @@ class SpendRepository
$gameIds = $params['game_ids'] ?? [];
$conditions = [];
$conditions['pay_status'] = 1;
$conditions['promote_id'] = ['in', $ids];
$conditions['pay_time'] = ['between', [$beginTime, $endTime]];
$conditions['game_id'] = ['in', $gameIds];
$conditions['pay_way'] = $isBan ? ['neq', '-10'] : ['neq', '-1'];
if (!empty($params['server_id'])) {
$conditions['server_id'] = $params['server_id'];
}
$conditions['pay_way'] = $isBan ? ['neq', '-10'] : ['neq', '-1'];
$conditions['pay_status'] = 1;
$conditions['pay_time'] = ['between', [$beginTime, $endTime]];
return $conditions;
}
@ -56,7 +56,6 @@ class SpendRepository
$conditions = [];
$conditions['pay_status'] = 1;
$conditions['promote_id'] = ['in', $ids];
$conditions['pay_time'] = ['between', [$beginTime, $endTime]];
$conditions['game_id'] = ['in', $gameIds];
if (!empty($params['server_id'])) {
$conditions['server_id'] = $params['server_id'];
@ -64,6 +63,7 @@ class SpendRepository
if (isset($params['pay_way'])) {
$conditions['pay_way'] = $params['pay_way'];
}
$conditions['pay_time'] = ['between', [$beginTime, $endTime]];
return $conditions;
}

@ -65,13 +65,13 @@ class UserRepository
$conditions = [];
$conditions['promote_id'] = ['in', $ids];
$conditions[$params['time_column']] = ['between', [$beginTime, $endTime]];
if (!empty($gameIds)) {
$conditions['game_id'] = ['in', $gameIds];
if (!empty($params['server_id'])) {
$conditions['server_id'] = $params['server_id'];
}
}
$conditions[$params['time_column']] = ['between', [$beginTime, $endTime]];
return $conditions;
}
@ -107,11 +107,11 @@ class UserRepository
$conditions = [];
$conditions['promote_id'] = ['in', $ids];
$conditions[$params['time_column']] = ['between', [$beginTime, $endTime]];
$conditions['game_id'] = ['in', $gameIds];
if ($serverId > 0) {
$conditions['server_id'] = $serverId;
}
$conditions[$params['time_column']] = ['between', [$beginTime, $endTime]];
return $conditions;
}

@ -1316,10 +1316,7 @@ class QueryController extends BaseController
$allData['spend_voucher'] = 0;
if (!empty($data)) {
if (intval($endTime - $begTime) / (24 * 3600) <= 31) {
$gameIds = [];
foreach ($data as $list) {
$gameIds[] = $list['game_id'];
}
$gameIds = array_column($data, 'game_id');
$params['game_ids'] = $gameIds;
$userRepository = new UserRepository();
@ -1856,7 +1853,7 @@ class QueryController extends BaseController
$records = [];
foreach ($roles as $role) {
$records[] = [
'user_account' => $role['user_account'],
'user_account' => encryption($role['user_account']),
'game_name' => $role['game_name'],
'role_name' => $role['role_name'],
'role_id' => $role['role_id'],

@ -63,13 +63,12 @@
<div class="service_swiper">
<img src="__IMG__/lunbo3.png" alt="">
<a href="{:U('Index/index')}" style="z-index: 9999" id="back_to_index" class="back_to_index">
<img src="__IMG__/black.png" alt=""></a>
</div>
<a href="{:U('Index/index')}" style="z-index: 9999" id="back_to_index" class="back_to_index"><img src="__IMG__/black.png" alt=""></a>
<div class="service_info">
<div class="service_left">
<div class="list">
<li class="selected" >监护工程概述</li>
<li class="selected" onclick="javascript:void (alert('123'))">监护工程概述</li>
<li class="" >申请服务流程</li>
<li class="" >监护工程概述</li>
<li class="" >健康提示</li>
@ -253,83 +252,82 @@
<div class="foot_bom">抵制不良网页游戏拒绝盗版游戏。注意自我保护谨防受骗上当。适度游戏益脑沉迷游戏伤身。合理安排时间享受健康生活。适龄提示适合12周岁以上使用。</div>
</div>
</div>
<!----中间---->
<script type="text/javascript" src="__JS__/jquery-1.11.2.min.js"></script>
<script type="text/javascript" src="__JS__/jquery.SuperSlide.2.1.1.js"></script>
<!----中间---->
<script type="text/javascript" src="__JS__/jquery-1.11.2.min.js"></script>
<script type="text/javascript" src="__JS__/jquery.SuperSlide.2.1.1.js"></script>
<script src="__JS__/service.js"></script>
<script type="text/javascript">
<script type="text/javascript">
// jQuery("#header_1_p").slide({
// type:"menu",// 效果类型,针对菜单/导航而引入的参数(默认slide)
// titCell:".nLi", //鼠标触发对象
// targetCell:".sub", //titCell里面包含的要显示/消失的对象
// effect:"slideDown", //targetCell下拉效果
// delayTime:300 , //效果时间
// triggerTime:0, //鼠标延迟触发时间(默认150)
// returnDefault:true //鼠标移走后返回默认状态,例如默认频道是"预告片",鼠标移走后会返回"预告片"(默认false)
// });
// jQuery("#header_1_p").slide({
// type:"menu",// 效果类型,针对菜单/导航而引入的参数(默认slide)
// titCell:".nLi", //鼠标触发对象
// targetCell:".sub", //titCell里面包含的要显示/消失的对象
// effect:"slideDown", //targetCell下拉效果
// delayTime:300 , //效果时间
// triggerTime:0, //鼠标延迟触发时间(默认150)
// returnDefault:true //鼠标移走后返回默认状态,例如默认频道是"预告片",鼠标移走后会返回"预告片"(默认false)
// });
//添加收藏夹
function addBookmark(url,title){
url = url || window.location.href;;
title = title || document.title;
if (window.sidebar) {
window.sidebar.addPanel(title, url,"");
} else if( document.all ) {
window.external.AddFavorite( url, title);
} else {
alert('加入收藏失败,请使用 Ctrl+D 进行添加');
return true;
}
}
$(".collect").click(function(){addBookmark();})
$(function(){
setTimeout(function(){
jQuery(".sideMenu").slide({
titCell:"h3", //鼠标触发对象
targetCell:"ul", //与titCell一一对应第n个titCell控制第n个targetCell的显示隐藏
effect:"slideDown", //targetCell下拉效果
delayTime:200 , //效果时间
triggerTime:150, //鼠标延迟触发时间默认150
defaultPlay:true,//默认是否执行效果默认true
returnDefault:false //鼠标从.sideMen移走后返回默认状态默认false
});
},500);
//添加收藏夹
function addBookmark(url,title){
url = url || window.location.href;;
title = title || document.title;
if (window.sidebar) {
window.sidebar.addPanel(title, url,"");
} else if( document.all ) {
window.external.AddFavorite( url, title);
} else {
alert('加入收藏失败,请使用 Ctrl+D 进行添加');
return true;
}
}
$(".collect").click(function(){addBookmark();})
$(function(){
setTimeout(function(){
jQuery(".sideMenu").slide({
titCell:"h3", //鼠标触发对象
targetCell:"ul", //与titCell一一对应第n个titCell控制第n个targetCell的显示隐藏
effect:"slideDown", //targetCell下拉效果
delayTime:200 , //效果时间
triggerTime:150, //鼠标延迟触发时间默认150
defaultPlay:true,//默认是否执行效果默认true
returnDefault:false //鼠标从.sideMen移走后返回默认状态默认false
});
},500);
$('.float_contact_position').on('click','.top',function(){
$('body,html').animate({"scrollTop":0},500);
});
// var e = $('.newshot'),o = e.offset().top,s = e.siblings('.newcon').height();
var h = parseInt($('.aside1').height())+parseInt($('.aside2').height());
$(window).scroll(function() {
var c = $(this).scrollTop();
// var t = $('.jsfb').offset().top-c;
// if (h<s) {
// if (c>=o) {
// if (h>t) {
// e.css({'position':'absolute','top':'auto','bottom':'20px','background':'#FFFFFF','z-index':1000});
//
// } else {
// e.css({'position':'fixed','top':0,'background':'#FFFFFF','z-index':1000});
//
// }
// } else {
// e.removeAttr('style');
// }
// }
});
$('.float_contact_position').on('click','.top',function(){
$('body,html').animate({"scrollTop":0},500);
});
// var e = $('.newshot'),o = e.offset().top,s = e.siblings('.newcon').height();
var h = parseInt($('.aside1').height())+parseInt($('.aside2').height());
$(window).scroll(function() {
var c = $(this).scrollTop();
// var t = $('.jsfb').offset().top-c;
// if (h<s) {
// if (c>=o) {
// if (h>t) {
// e.css({'position':'absolute','top':'auto','bottom':'20px','background':'#FFFFFF','z-index':1000});
//
// } else {
// e.css({'position':'fixed','top':0,'background':'#FFFFFF','z-index':1000});
//
// }
// } else {
// e.removeAttr('style');
// }
// }
});
});
});
</script>
<script>
$('.tab_head ul li').click(function(){
var that = $(this);
that.siblings('li').removeClass('current');
var index= that.addClass('current').index();
$('.tab_content').find('.content_det').addClass('hidden').eq(index).removeClass('hidden');
});
</script>
</script>
<script>
$('.tab_head ul li').click(function(){
var that = $(this);
that.siblings('li').removeClass('current');
var index= that.addClass('current').index();
$('.tab_content').find('.content_det').addClass('hidden').eq(index).removeClass('hidden');
});
</script>
</block>

@ -90,7 +90,7 @@
<script type="text/javascript" src="__JS__/jquery.zclip.js"></script>
<script type="text/javascript" src="__JS__/get_cdk_index.js"></script>
<script type="text/javascript" src="__JS__/main.js"></script>
<!--<script type="text/javascript" src="__JS__/main.js"></script>-->
</head>
<body>

@ -19,6 +19,7 @@
}
.heard_tabbar ul{
display: flex;
align-items: center;
font-size: 0.24rem;
color: #5B5B5B;
margin-top: 0.54rem;

@ -2,6 +2,7 @@
width: 100%;
height: 8rem;
position: relative;
z-index: -1;
}
.service_swiper>img:first-child{
width: 100%;
@ -9,7 +10,7 @@
position: relative;
z-index: -1;
}
.service_swiper>a{
.back_to_index{
position: absolute;
width: 1.20rem;
height: 0.4rem;
@ -18,7 +19,7 @@
font-size: 0.2rem;
cursor: pointer;
}
.service_swiper> a img{
.back_to_index img{
width: 100%;
height: 100%;
}

@ -1,16 +1,17 @@
$(function(){
var img = $(".swiper-container .swiper-slide").length;
var swiper = new Swiper('.swiper-container', {
loop: true,
pagination: {
el: '.swiper-pagination',
clickable: true,
},
autoplay: {
/*autoplay: {
delay: 3000,
stopOnLastSlide: false,
disableOnInteraction: false,
},
},*/
autoplay: img > 1,
});
});
Loading…
Cancel
Save