Merge branch 'dev_lww' into dev_permission

# Conflicts:
#	Application/Admin/Common/extend.php
#	Application/Admin/Controller/MendController.class.php
#	Application/Admin/Controller/PromoteController.class.php
#	Application/Admin/Model/MemberModel.class.php
master
liuweiwen 5 years ago
commit 42ccd44de3

@ -1554,4 +1554,64 @@ function getAdminData ($uid) {
return $adminData;
}
/**
* 获取当前管理员有权限查看所有推广员id
* @return mixed|string 格式如;all-全部;1,2,3;为空表示都没有权限
*/
function getPowerPromoteIds()
{
//session已存在当前管理员可查看数据的推广员id,则直接返回权限有变化事删除此session
if (!empty(session('user_auth_promote_ids'))) {
return session('user_auth_promote_ids');
}
$userAuth = session('user_auth');
$promoteIds = 'all';
$userAuth['data_president']= trim($userAuth['data_president'], ",");
if (!empty($userAuth['data_empower_type'])) {//数据权限 1 全部 2 部分数据 3 自己底下的会长
//等于1默认全部数据不进行筛选
if (in_array($userAuth['data_empower_type'], [2, 3])) {
$promoteIds = '';
//自己创建的会长
$myPromote_ids = M('promote', 'tab_')
->field('GROUP_CONCAT(id) as promote_ids')
->where(['admin_id' => $userAuth['uid']])
->find();
$myPromote_ids = $myPromote_ids['promote_ids'];
if ($myPromote_ids) {
if ($userAuth['data_empower_type'] == 2) {//部分会长加上自己创建的会长
$userAuth['data_president'] .= "," . $myPromote_ids;
} elseif ($userAuth['data_empower_type'] == 3) {//自己创建的会长和底下推广员
$userAuth['data_president'] = $myPromote_ids;
}
}
if (!empty($userAuth['data_president'])) {//查询有权限查看的会长以及底下的推广员
$map = array();
//查询会长底下的推广员(首个斜杆之间的数字)
$where['SUBSTRING_INDEX(SUBSTRING_INDEX(`chain`,"/",2),"/",-1)'] = array('exp',"IN({$userAuth['data_president']})");
$where['id'] = array('in', $userAuth['data_president']);//会长本身
$where['_logic'] = 'or';
$map['_complex'] = $where;
$sqlResult = M('promote', 'tab_')
->field('GROUP_CONCAT(id) as promote_ids')
->where($map)
->find();
$promoteIds = $sqlResult['promote_ids'];
}
}
}
session('user_auth_promote_ids', $promoteIds);
return $promoteIds;
}
function setPowerPromoteIds(&$map, $column = 'promote_id') {
//为数据权限添加
$promoteIds = getPowerPromoteIds();
if (empty($promoteIds)) {
$map[$column] = 0;
} elseif ($promoteIds != 'all') {
$map[$column] = array('in', $promoteIds);
}
}
?>

@ -160,6 +160,8 @@ class ApplyController extends ThinkController
$fields = "tab_apply.*,tab_game.ratio as game_ratio,tab_game.money as game_money";
$join = "LEFT JOIN tab_game ON tab_apply.game_id = tab_game.id";
$order = "id desc";
//为数据权限添加
setPowerPromoteIds($map);
$data = $applyModel->joinList($fields, $join, $map, $order);
$this -> meta_title = '游戏分包列表';
$this -> assign('_page', $data['page']);

@ -0,0 +1,199 @@
<?php
namespace Admin\Controller;
use User\Api\UserApi as UserApi;
use OSS\OssClient;
use OSS\Core\OSsException;
use Think\Controller;
/**
* 后台首页控制器
* @author 麦当苗儿 <zuojiazi@vip.qq.com>
*/
class PromoteCompanyController extends ThinkController
{
private $modelName = 'PromoteCompany';
//列表
public function lists()
{
$model = M($this->modelName, 'tab_');
$map = [];
$id = intval(I('id', 0));
$company_name = trim(I('company_name'));
if (!empty($id)) {
$map['tab_promote_company.id'] = $id;
$parameter['id'] = $id;
}
if($company_name)
$map['tab_promote_company.company_name'] = array('like',"%{$company_name}%");
if (isset($_REQUEST['status']) && $_REQUEST['status'] !== '') {
$status = intval($_REQUEST['status']);
$map['tab_promote_company.status'] = $status;
$parameter['status'] = $status;
}
$page = intval(I('get.p', 0));
$page = $page ? $page : 1; //默认显示第一页数据
$row = intval(I('row', 0));
$row = empty($row) ? 10 : $row;//每页条数
$data = $model
->field('tab_promote_company.id,tab_promote_company.company_name,tab_promote_company.status,
tab_promote_company.create_time,sys_member.nickname')
->join('left join sys_member on sys_member.uid = tab_promote_company.uid')
->where($map)
->order('id desc')
->page($page, $row)
->select();
/* 查询记录总数 */
$count = $model
->where($map)
->count();
if (!empty($data)) {
foreach ($data as &$list) {
$list['status'] = ($list['status'] == 0) ? '已关闭' : '已开启';
$list['create_time'] = date('Y-m-d H:i:s', $list['create_time']);
}
}
//分页
$parameter['p'] = $page;
$parameter['row'] = $row;
$page = set_pagination($count, $row, $parameter);
if ($page) {
$this->assign('_page', $page);
}
$this->assign('listData', $data);
$this->assign('count', $count);
$this->assign('commonset', M('Kuaijieicon')->where(['url' => 'Partner/lists'])->find());
$this->meta_title = '推广公司';
$this->display();
}
//添加
public function add()
{
if ($_POST) {
$company_name = I('post.company_name', '');
$status = intval(I('post.status', 1));
if (empty($company_name)) {
$this->error('请输入推广公司名称');
}
if (!in_array($status, [0, 1])) {
$this->error('参数异常');
}
$model = M($this->modelName, 'tab_');
$map['company_name'] = $company_name;
$res = $model->where($map)->getField('id');
if ($res) {
$this->error('推广公司已存在');
}
$time = time();
$save['company_name'] = $company_name;
$save['status'] = $status;
$save['uid'] = UID;
$save['create_time'] = $time;
$save['last_up_time'] = $time;
$res = $model->add($save);
if ($res) {
\Think\Log::actionLog('PromoteCompany/add', 'partner', $res);
$this->success('保存成功', U('lists'));
} else {
$this->error('保存失败');
}
} else {
$this->assign('commonset', M('Kuaijieicon')->where(['url' => 'PromoteCompany/add'])->find());
$this->meta_title = '新增推广公司';
$this->display();
}
}
//编辑
public function edit()
{
$model = M($this->modelName, 'tab_');
if ($_POST) {
$company_name = I('post.company_name', '');
$status = intval(I('post.status', 1));
$id = intval(I('post.id', 0));
if (empty($company_name)) {
$this->error('请输入推广公司名称');
}
if (!in_array($status, [0, 1]) || $id == 0) {
$this->error('参数异常');
}
$data = $model->field('id,company_name')->find($id);
if (empty($data)) {
$this->error('数据异常');
}
$map['company_name'] = $company_name;
$res = $model->where($map)->getField('id');
if ($res && $res != $id) {
$this->error('推广公司已存在');
}
$time = time();
$save['id'] = $id;
$save['company_name'] = $company_name;
$save['status'] = $status;
$save['last_up_time'] = $time;
$res = $model->save($save);
if ($res === false) {
$this->error('保存失败');
} else {
\Think\Log::actionLog('PromoteCompany/edit', 'PromoteCompany', $id);
$this->success('保存成功', U('lists'));
}
} else {
$id = intval(I('get.id', 0));
$map['id'] = $id;
$data = $model->field('id,company_name,status')->find($id);
if (empty($data)) {
$this->error('数据异常', U('lists'));
}
$this->assign('data', $data);
$this->assign('commonset', M('Kuaijieicon')->where(['url' => 'PromoteCompany/edit'])->find());
$this->meta_title = '编辑推广公司';
$this->display();
}
}
//删除
public function del()
{
if (!empty($_POST['ids'])) {
if (!is_array($_POST['ids'])) {
$this->error('参数异常');
}
$id = implode(',', $_POST['ids']);
} else {
$id = intval(I('get.id', 0));
if ($id == 0) {
$this->error('参数异常');
}
}
$res = M($this->modelName, 'tab_')->delete($id);
if ($res === false) {
$this->error('删除失败');
}
$this->success('删除成功', U('lists'));
}
}

@ -229,81 +229,95 @@ class StatController extends ThinkController
$this->assign("json_data",json_encode($res));
$this->display();
}
//流失率分析
public function loss_pic($para){
if(isset($para['time_start'])&&isset($para['time_end'])&&$para['time_start']!==null&&$para['time_end']!==null){
$dd=prDates($para['time_start'],$para['time_end']);
$day=$dd;
$this->assign('tt',array_chunk($dd,1));
if (!empty($para['time_start']) && !empty($para['time_end'])) {
$days = prDates($para['time_start'],$para['time_end']);
$day = $days;
$this->assign('tt',array_chunk($days,1));
} else {
$defTimeE = date("Y-m-d",time());
$defTimeS = date("Y-m-d",time() - 24*60*60*6);
$day = every_day(7);
$dd=prDates($defTimeS,$defTimeE);
$days = prDates($defTimeS,$defTimeE);
}
if (isset($para['game_id'])) {
$map['r.fgame_id']=$para['game_id'];
$map1['r.fgame_id']=$para['game_id'];
}
if(isset($para['channel_id'])&&$para['channel_id']!=""){
if (!empty($para['channel_id'])) {
if ($para['channel_id'] == 2 ) {
$d=7;
$continueDay = 7;
} else {
$d=3;
$continueDay = 3;
}
}else{
$d=3;
$continueDay = 3;//3天不登录表示玩家已流失
}
$limitI=count($dd);
$usermodel = D('User');
for($i=0;$i<$limitI;$i++){
$start=$this->get_time($dd[$i],$d);
$end=$start+24*60*60-1;
$map['r.register_time']=array('between',array($start,$end));
if(isset($para['promote_id'])&&$para['promote_id']!=""){
$map['r.promote_id']=$para['promote_id'];
}
$logins=$usermodel->getPlayers($map);
if($logins==null){
$loss=null;
}else{
$loss=null;
foreach ($logins as $key => $value) {
$start=date("Y-m-d", $value['register_time']+24*60*60);
$start=$this->get_time($start,0);
$end=$start+24*60*60*$d;
$map1['r.login_time']=array('between',array($start,$end));
$map1['r.user_id']=$value['id'];
//获取这个时间段内注册的玩家
$start = $this->get_time(current($days), $continueDay);
$end = $this->get_time(end($days), $continueDay) + 86399;;
$map['register_time']=array('between',array($start, $end));
if (isset($para['promote_id']) && $para['promote_id']!="") {
$map1['promote_id']=$para['promote_id'];
}
$result1=$usermodel->findPlayer($map1);
if($result1==null){
$loss[]=$logins[$key];
}
}
}
if($loss!=null){
$loser[]=$loss;
}
$loss_count[]=count($loss);
$loss_rate[]=count($loss)/count($logins)*100?sprintf("%.2f",count($loss)/count($logins)*100):0;
}
foreach ($loser as $key => $value) {
foreach ($value as $k => $v) {
$losers[]=$v['user_id'];
}
$map['promote_id']=$para['promote_id'];
}
$players = $usermodel->getUserList($map, "GROUP_CONCAT(DISTINCT id) as user_ids,
FROM_UNIXTIME(register_time+{$continueDay}*86400, '%Y-%m-%d') as register_date", "register_date");
$players = array_column($players, 'user_ids', 'register_date');
$map1 = array();
$map1['lpuid'] = 0;
$map1['u.register_time'] = array('between',array($start, $end));
if (isset($para['promote_id'])&&$para['promote_id']!="") {
$map1['u.promote_id']=$para['promote_id'];
}
//获取这段时间内有登录(未流失)的玩家
$map1['r.login_time'] = array('exp', 'BETWEEN UNIX_TIMESTAMP(
FROM_UNIXTIME(
u.register_time + 86400,
"%Y-%m-%d"
)
)
AND UNIX_TIMESTAMP(
FROM_UNIXTIME(
u.register_time + 86400,
"%Y-%m-%d"
)
) + 86400 * ' . $continueDay);
$keepPlayers = $usermodel->getKeepPlayers($map1, $continueDay, count($days) > 7);// 3或7天内有登录的玩家
$keepPlayers = array_column($keepPlayers, 'user_ids', 'register_date');
$loss_count = array();//流失玩家数量
foreach ($days as $key => $date) {
$dateUserCount = isset($players[$date]) ? count(explode(",", $players[$date])) : 0;
$keepUserCount = isset($keepPlayers[$date]) ? count(explode(",", $keepPlayers[$date])) : 0;
$loss_count[$key] = $dateUserCount - $keepUserCount;//流失数量
if ($dateUserCount) {
$loss_rate[] = sprintf("%.2f",($loss_count[$key]/$dateUserCount) * 100);//流失率
} else {
$loss_rate[] = 0;
}
}
$losers = array_filter($players, function ($item) use ($keepPlayers) {
return !in_array($item, $keepPlayers);
});
$losers = array_values($losers);//流失玩家id集合
$data2 = $this->loss_pic2($losers);
$data3 = $this->loss_pic3($losers);
$result['day']=$day;
$result['loss_count']=$loss_count;
$result['loss_rate']=$loss_rate;
$result['loss_money']=$data2;
$result['loss_times']=$data3;
$result['day'] = $day;//日期
$result['loss_count'] = $loss_count;//流失数量
$result['loss_rate'] = $loss_rate;//流失率
$result['loss_money'] = $data2;//流失金额
$result['loss_times'] = $data3;//流失次数
return $result;
}
/**
* 流失用户消费金额分析,包括不同等级的人数和所占比例
* @param [type] $data [description]

@ -2073,6 +2073,38 @@ class UserModel extends Model{
return $data;
}
/**
* 获取用户列表
*/
public function getUserList($param, $field = "*", $group = "")
{
$result = $this->where($param)
->field($field)
->group($group)
->select();
return $result;
}
/**
* 获取未流失的玩家
* @param $day int 几天算玩家流失
*/
public function getKeepPlayers($map = '', $day, $falseIndex = false)
{
$join = "right join tab_user as u on r.user_id = u.id";
if ($falseIndex) {//日期范围大于5天使用强制索引
$join = "FORCE INDEX (PRIMARY) " . $join;
}
$data = $this->table("tab_user_login_record")
->alias("r")
->field("GROUP_CONCAT(DISTINCT u.id) as user_ids,FROM_UNIXTIME(u.register_time+{$day}*86400, '%Y-%m-%d') as register_date")
->join($join)
->group("register_date")
->where($map)
->select();
return $data;
}
}

@ -82,6 +82,20 @@
</td>
</tr>
<tr>
<td class="l">所属推广公司</td>
<td class="r">
<select name="company_id" id="company_id">
<option value="0">请选择推广公司</option>
<volist name="companys" id="vo">
<option value="{$vo.id}">{$vo.company_name}</option>
</volist>
</select>
<!-- <span class="notice-text">设置该推广员所属的推广公司</span>-->
</td>
</tr>
</tbody>
</table>
</div>

@ -0,0 +1,85 @@
<extend name="Public/base" />
<block name="css">
<link rel="stylesheet" type="text/css" href="__CSS__/admin_table.css" media="all">
<link rel="stylesheet" type="text/css" href="__STATIC__/webuploader/webuploader.css" media="all">
<style>
#form .txt_area.download_url {width:400px;}
.tabcon1711 .table_radio2 .table_btn {width:215px;}
</style>
</block>
<block name="body">
<script type="text/javascript" src="__STATIC__/uploadify/jquery.uploadify.min.js"></script>
<script src="__STATIC__/md5.js" type="text/javascript" charset="utf-8"></script>
<script type="text/javascript" src="__STATIC__/webuploader/webuploader.js"></script>
<script src="__STATIC__/layer/layer.js" type="text/javascript"></script>
<script type="text/javascript" src="__STATIC__/layer/extend/layer.ext.js"></script>
<!-- 标签页导航 -->
<div class="tab-wrap">
<div class="cf main-place top_nav_list navtab_list">
<h3 class="page_title">{$meta_title}</h3>
</div>
<div class="tab-content tabcon1711">
<!-- 表单 -->
<form id="form" action="{:U('add')}" method="post" class="form-horizontal">
<!-- 基础 -->
<div id="tab1" class="tab-pane in tab1 ">
<table border="0" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td class="l"><i class="mustmark" style="margin-left:-7px">*</i>推广公司名称:</td>
<td class="r" >
<input type="text" class="txt " name="company_name" value="" placeholder="请输入推广公司名称">
</td>
</tr>
<tr>
<td class="l noticeinfo"><i class="mustmark" style="margin-left:-7px">*</i>显示状态:</td>
<td class="r table_radio">
<span class="form_radio table_btn">
<label>
<input type="radio" class="inp_radio" value="1" name="status" checked> 开启
</label>
<label>
<input type="radio" class="inp_radio" value="0" name="status"> 关闭
</label>
</span>
<span class="notice-text"></span>
</td>
</tr>
</tbody>
</table>
</div>
<div class="form-item cf">
<button class="submit_btn ajax-post" id="submit" type="submit" target-form="form-horizontal" style="margin-left:210px;">
保存
</button>
<a class="submit_btn " alt="返回上一页" title="返回上一页" href="javascript:history.back(-1);" >
返回
</a>
</div>
</form>
</div>
</div>
<div class="common_settings">
<span class="plus_icon"><span><img src="__IMG__/zwmimages/icon_jia.png"></span></span>
<form class="addShortcutIcon">
<input type="hidden" name="title" value="{$meta_title}">
<input type="hidden" name="url" value="Partner/add">
</form>
<a class="ajax-post add-butn <notempty name='commonset'>addSIsetted</notempty>" href="javascript:;" target-form="addShortcutIcon" url="{:U('Think/addShortcutIcon')}"><img src="__IMG__/zwmimages/icon_jia.png"><span><notempty name='commonset'>已添加<else />添加至常用设置</notempty></span></a>
</div>
</block>
<block name="script">
<script type="text/javascript">
//导航高亮
highlight_subnav("{:U('PromoteCompany/lists')}");
$('#submit').click(function(){
$('#form').submit();
});
</script>
</block>

@ -0,0 +1,88 @@
<extend name="Public/base" />
<block name="css">
<link rel="stylesheet" type="text/css" href="__CSS__/admin_table.css" media="all">
<link rel="stylesheet" type="text/css" href="__STATIC__/webuploader/webuploader.css" media="all">
<style>
#form .txt_area.download_url {width:400px;}
.tabcon1711 .table_radio2 .table_btn {width:215px;}
</style>
</block>
<block name="body">
<script type="text/javascript" src="__STATIC__/uploadify/jquery.uploadify.min.js"></script>
<script src="__STATIC__/md5.js" type="text/javascript" charset="utf-8"></script>
<script type="text/javascript" src="__STATIC__/webuploader/webuploader.js"></script>
<script src="__STATIC__/layer/layer.js" type="text/javascript"></script>
<script type="text/javascript" src="__STATIC__/layer/extend/layer.ext.js"></script>
<!-- 标签页导航 -->
<div class="tab-wrap">
<div class="cf main-place top_nav_list navtab_list">
<h3 class="page_title">{$meta_title}</h3>
</div>
<div class="tab-content tabcon1711">
<!-- 表单 -->
<form id="form" action="{:U('edit')}" method="post" class="form-horizontal">
<!-- 基础 -->
<div id="tab1" class="tab-pane in tab1 ">
<table border="0" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td class="l"><i class="mustmark" style="margin-left:-7px">*</i>推广公司名称:</td>
<td class="r" >
<input type="text" class="txt " name="company_name" value="{$data.company_name}" placeholder="请输入推广公司名称">
</td>
</tr>
<tr>
<td class="l noticeinfo"><i class="mustmark" style="margin-left:-7px">*</i>显示状态:</td>
<td class="r table_radio">
<span class="form_radio table_btn">
<label>
<input type="radio" class="inp_radio" value="1" name="status"
<eq name="data.status" value="1"> checked </eq>> 开启
</label>
<label>
<input type="radio" class="inp_radio" value="0" name="status"
<eq name="data.status" value="0"> checked </eq>> 关闭
</label>
</span>
<span class="notice-text"></span>
</td>
</tr>
</tbody>
</table>
</div>
<div class="form-item cf">
<input type="hidden" name="id" value="{$data.id}">
<button class="submit_btn ajax-post" id="submit" type="submit" target-form="form-horizontal" style="margin-left:210px;">
保存
</button>
<a class="submit_btn " alt="返回上一页" title="返回上一页" href="{:U('Partner/lists')}" >
返回
</a>
</div>
</form>
</div>
</div>
<div class="common_settings">
<span class="plus_icon"><span><img src="__IMG__/zwmimages/icon_jia.png"></span></span>
<form class="addShortcutIcon">
<input type="hidden" name="title" value="{$meta_title}">
<input type="hidden" name="url" value="Partner/edit">
</form>
<a class="ajax-post add-butn <notempty name='commonset'>addSIsetted</notempty>" href="javascript:;" target-form="addShortcutIcon" url="{:U('Think/addShortcutIcon')}"><img src="__IMG__/zwmimages/icon_jia.png"><span><notempty name='commonset'>已添加<else />添加至常用设置</notempty></span></a>
</div>
</block>
<block name="script">
<script type="text/javascript">
//导航高亮
highlight_subnav("{:U('Partner/lists')}");
$('#submit').click(function(){
$('#form').submit();
});
</script>
</block>

@ -0,0 +1,163 @@
<extend name="Public/base"/>
<block name="body">
<link rel="stylesheet" href="__CSS__/select2.min.css" type="text/css" />
<script type="text/javascript" src="__JS__/bootstrap.min.js"></script>
<script type="text/javascript" src="__JS__/select2.min.js"></script>
<style>
.select2-container--default .select2-selection--single {
color: #000;
resize: none;
border-width: 1px;
border-style: solid;
border-color: #a7b5bc #ced9df #ced9df #a7b5bc;
box-shadow: 0px 3px 3px #F7F8F9 inset;height:35px;
height:28px;border-radius:3px;font-size:12px;
}
.select2-container--default .select2-selection--single .select2-selection__rendered {
line-height:35px;
line-height:28px;
}
.select2-container--default .select2-selection--single .select2-selection__arrow {
height:26px;
}
.select2-container--default .select2-search--dropdown .select2-search__field {
height:26px;line-height:26px;font-size:12px;
}
.select2-results__option[aria-selected] {font-size:12px;}
.data_list table td{
text-indent:0;
}
</style>
<div class="cf main-place top_nav_list navtab_list">
<h3 class="page_title">{$meta_title}</h3>
<p class="description_text">说明:该功能是用于录入工会所属的推广公司名称</p>
</div>
<div class="cf top_nav_list">
<div class="fl button_list">
<div class="tools">
<a class="" href="{:U('add')}"><span class="button_icon button_icon1"></span>新增</a>
<a class="ajax-post confirm " target-form="ids" url="{:U('del')}"><span class="button_icon button_icon2"></span>删除</a>
</div>
</div>
<!-- 高级搜索 -->
<div class="jssearch fl cf search_list">
<div class="input-list search-title-box">
<label>搜索:</label>
</div>
<div class="sleft">
<input type="text" name="company_name" class="search-input" value="{:I('company_name')}" placeholder="请输入公司名称搜索">
<a class="sch-btn" href="javascript:;" id="search" url="__SELF__">搜索</a>
</div>
</div>
</div>
<!-- 数据列表 -->
<div class="data_list data_game_list">
<div class="">
<table>
<!-- 表头 -->
<thead>
<tr>
<th>
<input class="check-all" type="checkbox">
</th>
<th>推广公司</th>
<th>显示状态</th>
<th>添加人</th>
<th>添加时间</th>
<th style="width:10%;min-width:150px;">操作</th>
</tr>
</thead>
<!-- 列表 -->
<tbody>
<empty name ="listData">
<td colspan="6" class="text-center">aOh! 暂时还没有内容!</td>
<else />
<volist name="listData" id="data">
<tr>
<td><input class="ids" type="checkbox" value="{$data['id']}" name="ids[]"></td>
<td>{$data.company_name}</td>
<td>{$data.status}</td>
<td>{$data.nickname}</td>
<td>{$data.create_time}</td>
<td>
<a href="{:U('edit',array('id'=>$data['id']))}">编辑</a>
<a href="{:U('del',array('id'=>$data['id']))}" class="confirm ajax-get">删除</a>
</td>
</tr>
</volist>
</empty>
</tbody>
</table>
</div>
</div>
<div class="page">
{$_page|default=''}
</div>
<div class="common_settings">
<span class="plus_icon"><span><img src="__IMG__/zwmimages/icon_jia.png"></span></span>
<form class="addShortcutIcon">
<input type="hidden" name="title" value="{$meta_title}">
<input type="hidden" name="url" value="Partner/lists">
</form>
<a class="ajax-post add-butn <notempty name='commonset'>addSIsetted</notempty>" href="javascript:;" target-form="addShortcutIcon" url="{:U('Think/addShortcutIcon')}"><img src="__IMG__/zwmimages/icon_jia.png"><span><notempty name='commonset'>已添加<else />添加至常用设置</notempty></span></a>
</div>
</block>
<block name="script">
<script src="__STATIC__/layer/layer.js"></script>
<script src="__STATIC__/layer/extend/layer.ext.js"></script>
<style>
.layui-layer-demo .layui-layer-title {background:#F0F5F7;font-weight:bold;}
.layui-layer-demo .layui-layer-content {}
.layui-layer-demo .layui-layer-content table{width:100%;border:0;border-spacing:0;padding:0;}
.layui-layer-demo .layui-layer-content td {height:42px;padding-left:20px;}
.layui-layer-demo .layui-layer-content tr:hover {background:#F0F5F7;}
.layui-layer-demo .layui-layer-content tr~tr {border-top:1px solid #ccc;}
.layui-layer-demo .layui-layer-content td~td {border-left:1px solid #ccc;}
.layui-layer-demo .layui-layer-content tr:last-child td {}
</style>
<script>
<volist name=":I('get.')" id="vo">
Think.setValue('{$key}',"{$vo}");
</volist>
$(".select_gallery").select2();
</script>
<script type="text/javascript">
//导航高亮
highlight_subnav("{:U('lists')}");
$(function(){
//搜索功能
$("#search").click(function(){
var url = $(this).attr('url');
var query = $('.jssearch').find('input').serialize();
query += "&"+$('.jssearch').find('select').serialize();
query = query.replace(/(&|^)(\w*?\d*?\-*?_*?)*?=?((?=&)|(?=$))/g,'');
query = query.replace(/^&/g,'');
if( url.indexOf('?')>0 ){
url += '&' + query;
}else{
url += '?' + query;
}
window.location.href = url;
});
//回车自动提交
$('.jssearch').find('input').keyup(function(event){
if(event.keyCode===13){
$("#search").click();
}
});
});
</script>
</block>

@ -949,10 +949,11 @@ class PromoteService {
'mobile_phone' => $params['mobile_phone'],
'bank_name' => $params['bank_name'] ?? '',
'bank_card' => $params['bank_card'],
'status' => 1,
// 'status' => 1,
'parent_id' => $parent ? $parent['id'] : 0,
'parent_name' => $parent ? $parent['account'] : '官方渠道',
'admin_id' => $params['admin_id'] ?? 0,
'company_id' => $params['company_id'] ?? 0,
'invite_code' => $params['invite_code'] ?? '',
'create_time' => time(),
];

@ -60,7 +60,6 @@
<link rel="stylesheet" type="text/css" href="__CSS__/heard.css" />
<link rel="stylesheet" type="text/css" href="__CSS__/foot.css" />
<link rel="stylesheet" type="text/css" href="__CSS__/supervise.css" />
<div class="service_swiper">
<img src="__IMG__/lunbo3.png" alt="">
</div>

@ -177,3 +177,6 @@
color: #00A3E1;
font-size: 0.14rem;
}
.list>li {
cursor: pointer;
}
Loading…
Cancel
Save