聚合下游公司列表添加

master
zhengyongxing 4 years ago
parent cacb1e4cf4
commit 1ff82cce20

@ -2820,5 +2820,27 @@ function getMerchant(){
->where(['status'=>1,'type'=>1])
->select();
return $data;
}
/**
* 聚合公司筛选项
* @param $type 1 渠道 2 包名获取
* @return mixed
*/
function getCpCompanySelect($type = 1){
$request['req'] = 1;
if ($type == 1) {
$url = M("kv")->field("value")->where(['key'=>"cp_company_channel_api"])->find();
$data = json_decode(curl_post($url['value'],$request),true);
} elseif($type == 2) {
$url = M("kv")->field("value")->where(['key'=>"cp_company_gamename_api"])->find();
$data = json_decode(curl_post($url['value'],$request),true);
} else {
return [];
}
return $data;
}

@ -0,0 +1,87 @@
<?php
/**
* 后台首页
*/
namespace Admin\Controller;
class CpJuheCompanyController extends ThinkController {
//聚合公司
public function index($p = 0) {
// dump(getCpCompanySelect(1));die();
$p = I('p');
$page = intval($p);
$page = $page ? $page : 1; //默认显示第一页数据
$arraypage = $page;
if (isset($_REQUEST['row'])) {
$row = $_REQUEST['row'];
} else {
$row = 10;
}
$request = [];
$request['p'] = $p;
$request['row'] = $row;
$request['remote'] = 1;
if($_REQUEST['export']) {
$request['export'] = 1;
}
$_REQUEST['origin_game_name']?($request['origin_game_name'] = $_REQUEST['origin_game_name']):'';
$_REQUEST['game_id'] ? ($request['game.id'] = $_REQUEST['game_id']):'';
$_REQUEST['channel_id'] ? ($request['channel_id'] = $_REQUEST['channel_id']):'';
($_REQUEST['company_properties']||$_REQUEST['company_properties']=='0') ? ($request['company_properties'] = $_REQUEST['company_properties']):'';
$url = M("kv")->field("value")->where(['key'=>"cp_company_api"])->find();
$data = json_decode(curl_post($url['value'],$request),true);
// dump($request);die();
if($_REQUEST['export']) {
$list_data = $data['data'];
foreach ($list_data as $key => $value) {
$list_data[$key]['agreement_time'] = json_decode($list_data[$key]['agreement_time'],true);
$list_data[$key]['balance_time'] = json_decode($list_data[$key]['balance_time'],true);
$list_data[$key]['agreement_time']['start_time'] = date("Y-m-d H:i:s",$list_data[$key]['agreement_time']['start_time']);
($list_data[$key]['agreement_time']['end_time']!=1)?($list_data[$key]['agreement_time']['end_time'] = date("Y-m-d H:i:s",$list_data[$key]['agreement_time']['end_time'])):($list_data[$key]['agreement_time']['end_time'] = "");
$list_data[$key]['balance_time']['start_time'] = date("Y-m-d H:i:s",$list_data[$key]['balance_time']['start_time']);
($list_data[$key]['balance_time']['end_time']!=1)?($list_data[$key]['balance_time']['end_time'] = date("Y-m-d H:i:s",$list_data[$key]['balance_time']['end_time'])):($list_data[$key]['balance_time']['end_time'] = "");
}
$this->assign("listdata",$list_data);
$this->display("export");die();
} else {
$page = set_pagination($data['count'], $row);
if ($page) {
$this->assign('_page', $page);
}
$this->assign("listdata",$data['data']);
$this->display();
}
}
public function detail() {
$_REQUEST['id']?($request['id'] = $_REQUEST['id']):'';
$data = json_decode(curl_post("http://10.0.1.161:8095/index.php?g=Api&m=CpJuheCompany&a=detail",$request),true);
$this->assign("data",$data);
$this->display();
}
}

@ -354,6 +354,35 @@ class PromoteController extends ThinkController
/*通过Model名称获取Model完整信息*/
parent::del($model["id"], $ids);
}
public function getWithdrawDone() {
$company_id = I('company_id');
$promote_id = I('promote_id');
$map = [];
if (!$company_id) {
$this->ajaxReturn(['status'=>0]);
} else {
$map['company_id'] = $company_id;
}
if ($promote_id){
$map['id'] = ['neq',$promote_id];
}
$withdraw_done = D('Promote')
->field("sum(withdraw_done) withdraw_done")
->where($map)
->find();
if ($withdraw_done['withdraw_done']>0) {
$this->ajaxReturn(['status'=>1]);
} else {
$this->ajaxReturn(['status'=>0]);
}
}
public function edit($id=0)
{
$id || $this->error('请选择要查看的用户!');
@ -423,6 +452,9 @@ class PromoteController extends ThinkController
if (!empty(I('settlement_type')) && in_array($settlementType, [1, 2])) {
$data['settlement_type'] = $settlementType;
}
M("promote", "tab_")->where(["company_id"=>$company_id])->save(['withdraw_done'=>0]);
// echo M("promote", "tab_")->_sql();die();
$res = M("promote", "tab_")->where(array("id"=>$_POST['id']))->save($data);
if ($res !== false) {
if ($promote['level'] == 1) {//修改会长底下推广员的推广公司

@ -0,0 +1,272 @@
<extend name="Public/base"/>
<block name="body">
<style>
.tabcon1711 .table_click,.tabcon1711 .table_click:hover {border:none;}
.tabcon1711 .table_click .table_click_text {border-bottom:1px solid transparent;}
.tabcon1711 .table_click:hover .table_click_text {border-bottom-color:#145CCD;}
</style>
<script src="__STATIC__/layer/layer.js" type="text/javascript"></script>
<link rel="stylesheet" type="text/css" href="__CSS__/admin_table.css" media="all">
<script type="text/javascript" src="__STATIC__/uploadify/jquery.uploadify.min.js"></script>
<!-- 标签页导航 -->
<div class="tab-wrap">
<div class="tab-content tabcon1711">
<!-- 表单 -->
<form id="form" action="{:U('edit?id='.$model['id'])}" method="post" class="form-horizontal">
<div class="cf main-place top_nav_list navtab_list">
<h3 class="page_title">聚合公司详情</h3>
<p class="description_text">说明:查看聚合公司详情信息</p>
</div>
<div class="tab-pane in tab1">
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="l">合作方</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['name']}</span>
</td>
</tr>
<tr>
<td class="l">登录账号</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['code']}</span>
</td>
</tr>
<tr>
<td class="l noticeinfo">联系邮箱</td>
<td class="r table_radio">
<span class="form-required" style="line-height: 30px;">{$data['user_email']}</span>
</td>
</tr>
<tr>
<td class="l noticeinfo">联系手机</td>
<td class="r table_radio">
<span class="form-required" style="line-height: 30px;">{$data['mobile']}</span>
</td>
</tr>
<tr>
<td class="l">状态</td>
<td class="r">
<span class="form-required" style="line-height: 30px;"><if condition="$data['user_status'] eq 1">正常<elseif condition="$data['user_status'] eq 0"/>禁用<else/>未验证</if></span>
</td>
</tr>
<tr>
<td class="l">备注</td>
<td class="r">
<textarea name="remark" rows="3" cols="80" style="width: 400px;" readonly>{$data['remark']}</textarea></td>
</td>
</tr>
<tr>
<td class="l">对应平台</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['platform']}</span>
</td>
</tr>
<tr>
<td class="l noticeinfo">合同期限</td>
<td class="r pr">
<span class="form-required" style="line-height: 30px;">{$data['agreement_time']['start_time']}</span>
<!-- <input type="text" class="J_lay_datetime" name="agreement_time[]" autocomplete="off" placeholder="开始时间" value="{$data['agreement_time']['start_time']}" readonly>-->
&nbsp;&nbsp;&nbsp;&nbsp;
<!-- <input type="text" class="J_lay_datetime" name="agreement_time[]" autocomplete="off" placeholder="结束时间" value="{$data['agreement_time']['end_time']}" readonly>-->
<span class="form-required" style="line-height: 30px;">{$data['agreement_time']['end_time']|default="永久"}</span>
&nbsp;&nbsp;说明:结束时间不填为永久时间
</td>
</tr>
<tr>
<td class="l">结算生效期限</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['balance_time']['start_time']}</span>
<!-- <input type="text" class="J_lay_datetime" name="balance_time[]" autocomplete="off" placeholder="开始时间" value="{$data['balance_time']['start_time']}" readonly>-->
&nbsp;&nbsp;&nbsp;&nbsp;
<span class="form-required" style="line-height: 30px;">{$data['balance_time']['end_time']|default="永久"}</span>
<!-- <input type="text" class="J_lay_datetime" name="balance_time[]" autocomplete="off" placeholder="结束时间" value="{$data['balance_time']['end_time']}" readonly>-->
&nbsp;&nbsp;说明:结束时间不填为永久时间
</td>
</tr>
<tr>
<td class="l">开票税点</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['tax_point']}</span>
&nbsp;&nbsp;%
</td>
</tr>
<tr>
<td class="l">公司性质</td>
<td class="r">
<span class="form-required" style="line-height: 30px;"><if condition="$data['company_properties'] eq 0">个人<else/>公司</if></span>
</td>
</tr>
<tr>
<td class="l">是否签署合同</td>
<td class="r">
<span class="form-required" style="line-height: 30px;"><if condition="$data['is_contract'] eq 0"><else/></if></span>
</td>
</tr>
<tr>
<td class="l">是否为收款方</td>
<td class="r">
<span class="form-required" style="line-height: 30px;"><if condition="$data['is_received'] eq 0"><else/></if></span>
</td>
</tr>
<tr>
<td class="l noticeinfo">联系人</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['connection_person']}</span>
</td>
</tr>
<tr>
<td class="l noticeinfo">联系电话</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['phone']}</span>
</td>
</tr>
<tr>
<td class="l noticeinfo">联系地址</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['connection_address']}</span>
</td>
</tr>
<tr>
<td class="l noticeinfo">注册地址</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['register_address']}%</span>
</td>
</tr>
<tr>
<td class="l noticeinfo">注册电话</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['register_phone']}</span>
</td>
</tr>
<tr>
<td class="l noticeinfo">邮寄地址</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['send_address']}</span>
</td>
</tr>
<tr>
<td class="l noticeinfo">账户名</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['bank_user']}</span>
</td>
</tr>
<tr>
<td class="l noticeinfo">银行卡号</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['bank_card']}</span>
</td>
</tr>
<tr>
<td class="l noticeinfo">收款银行</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['bank_name']}</span>
</td>
</tr>
<tr>
<td class="l noticeinfo">支付宝账户</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['alipay_user']}</span>
</td>
</tr>
<tr>
<td class="l noticeinfo">承担服务费</td>
<td class="r">
<span class="form-required" style="line-height: 30px;"><if condition="$data['is_service'] eq 0"><else/></if></span>
<!-- <input readonly type="radio" name="is_service" style="margin-top: -2px;" autocomplete="off" placeholder="开始时间" value="1" <if condition="$data['is_service'] eq 1">checked</if>><span style="margin-top: 7px;display: inline-block;">是</span>-->
<!-- <input readonly type="radio" name="is_service" style="margin-top: -2px;margin-left: 30px" autocomplete="off" placeholder="结束时间" value="0" <if condition="$data['is_service'] eq 0">checked</if>><span>否</span>-->
<span class="form-required" style="line-height: 30px;">{$data['service_cost']}</span>
<!-- <input readonly type="text" name="service_cost" value="{$data['service_cost']}" onkeyup ="value=value.replace(/[^\d]/g,'')" style="margin-left: 30px">-->
&nbsp;&nbsp;
</td>
</tr>
<tr>
<td class="l noticeinfo">税费费率</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['tax_ratio']|default=0}%</span>
</td>
</tr>
<tr>
<td class="l noticeinfo">渠道费率</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['channel_radio']|default=0}%</span>
</td>
</tr>
<tr>
<td class="l noticeinfo">发票类型</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['invoice_type']}</span>
</td>
</tr>
<tr>
<td class="l noticeinfo">开票内容</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['invoice_item']}</span>
</td>
</tr>
<tr>
<td class="l noticeinfo">纳税人识别号</td>
<td class="r">
<span class="form-required" style="line-height: 30px;">{$data['tax_identification_number']}</span>
</td>
</tr>
<tr>
<td class="l noticeinfo">合作状态</td>
<td class="r">
<span class="form-required" style="line-height: 30px;"><if condition="$data['is_cooperate'] eq 1">合作中<else/>停止合作</if></span>
</td>
</tr>
<tr>
<td class="l noticeinfo">显示状态</td>
<td class="r">
<span class="form-required" style="line-height: 30px;"><if condition="$data['is_show'] eq 1">开启<else/>关闭</if></span>
</td>
</tr>
<tr>
<td class="l noticeinfo"></td>
<td class="r">
<div class="new_submit">
<input type="hidden" id="selfid" name="id" value="{$data.id}">
<input type="hidden" id="url" name="urll" value="{$url}">
<a class="submit_btn " alt="返回上一页" title="返回上一页" href="javascript:window.history.back();" >
返回
</a>
</div>
</td>
</tr>
</table>
</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="{$m_title}">
<input type="hidden" name="url" value="Member/user_info">
</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">
<link href="__STATIC__/datetimepicker/css/datetimepicker.css" rel="stylesheet" type="text/css">
<php>if(C('COLOR_STYLE')=='blue_color') echo '
<link href="__STATIC__/datetimepicker/css/datetimepicker_blue.css" rel="stylesheet" type="text/css">
';
</php>
<link href="__STATIC__/datetimepicker/css/dropdown.css" rel="stylesheet" type="text/css">
<script type="text/javascript" src="__STATIC__/datetimepicker/js/bootstrap-datetimepicker.min.js"></script>
<script type="text/javascript" src="__STATIC__/layer/extend/layer.ext.js"></script>
<script type="text/javascript" src="__STATIC__/datetimepicker/js/locales/bootstrap-datetimepicker.zh-CN.js"
charset="UTF-8"></script>
<script type="text/javascript">
highlight_subnav('{:U('CpJuheCompany/index')}');
</script>
</block>

@ -0,0 +1,314 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta charset="UTF-8">
<title>游戏登陆列表|----软件管理平台</title>
<link href="http://admin.vlcms.com/Public/icon.ico" type="image/x-icon" rel="shortcut icon">
<link rel="stylesheet" type="text/css" href="__CSS__/base.css" media="all">
<link rel="stylesheet" type="text/css" href="__CSS__/common.css" media="all">
<link rel="stylesheet" type="text/css" href="__CSS__/module.css">
<link rel="stylesheet" type="text/css" href="__CSS__/style.css" media="all">
<link rel="stylesheet" type="text/css" href="__CSS__/default_color.css" media="all">
<script type="text/javascript" src="__STATIC__/jquery-2.0.3.min.js"></script>
<script src="__STATIC__/table2excel.js"></script>
</head>
<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;}
.tooltip {
position: relative;
display: inline-block;
color: #056dae;
}
.tooltip .tooltiptext {
visibility: hidden;
width: 250%;
background-color: #fff;
color: #fff;
text-align: center;
border-radius: 6px;
padding: 5px 0;
position: absolute;
z-index: 1;
bottom: 80%;
left: 0;
margin-left: -70%;
border: #000 solid 1px;
}
.tooltip .tooltiptext::after {
content: "";
position: absolute;
top: 100%;
left: 50%;
margin-left: -5px;
border-width: 5px;
border-style: solid;
border-color: black transparent transparent transparent;
}
.tooltip:hover .tooltiptext {
color: #000;
visibility: visible;
line-height: 20px;
}
</style>
<div style="margin:auto;font-size: 20px;color: red;line-height: 3;padding: 20px;">
导出进行中。。。<br/>
如果导出成功你也可以手动关闭此页面
</div>
<!-- 数据列表 -->
<div class="data_list" style="display: none">
<empty name="show_status">
<div class="">
<table id="exporttable">
<!-- 表头 -->
<thead>
<tr>
<th >合作方名称</th>
<th >对应平台</th>
<th >公司性质</th>
<!-- <th >支付渠道</th>-->
<th >原包名</th>
<th >现包名</th>
<th >聚合包名</th>
<th >产品类型</th>
<th >结算周期</th>
<th colspan="2">游戏分成比例</th>
<th >账户名</th>
<th >银行账号</th>
<th >开户行</th>
<th >支付宝账号</th>
<th >是否为收款方</th>
<th >是否有预付款</th>
<th >预付款金额</th>
<th >是否签署合同</th>
<th >合同期限</th>
<th >生效时间</th>
<th >开票税点</th>
<th >发票类型</th>
<th >税费费率</th>
<th >渠道类型</th>
<th >联系人</th>
<th >联系电话</th>
<th >联系地址</th>
</tr>
</thead>
<!-- 列表 -->
<tbody>
<style>
.data-table thead th, .data-table tbody td{text-align:center}
.data-table tbody td{border-right:1px solid #DDDDDD;}
.d_list .drop-down ul {z-index:999;}
</style>
<!-- <if condition = "empty($data)">-->
<!-- <tr>-->
<!-- <td colspan="14" class="text-center">aOh! 暂时还没有内容!</td>-->
<!-- </tr>-->
<!-- </if>-->
<notemtpy name = "listdata">
<volist name="listdata" id="vo">
<tr>
<td rowspan="{$vo.rowspan}">{$vo.name|default="------"}</td>
<td rowspan="{$vo.rowspan}">{$vo.platform|default="------"}</td>
<td rowspan="{$vo.rowspan}">{$vo.company_properties|default="------"}</td>
<td rowspan="{$vo['sec_rowspan'][0]}">{$vo['original_package_name'][0]|default="------"}</td>
<td rowspan="{$vo['sec_rowspan'][0]}">{$vo['game_name'][0]|default="------"}</td>
<td rowspan="{$vo['sec_rowspan'][0]}">{$vo['game_name'][0]|default="------"}</td>
<td rowspan="{$vo['sec_rowspan'][0]}">{$vo['game_type'][0]|default="------"}</td>
<td rowspan="{$vo['sec_rowspan'][0]}">{$vo['withdraw_type'][0]|default="------"}</td>
<td rowspan='1'>默认</td>
<td rowspan='1'>{$vo['rate_data'][0][0]['exploitation_rate']|default="0"}</td>
<td rowspan="{$vo.rowspan}">{$vo.bank_user|default="------"}</td>
<td rowspan="{$vo.rowspan}">{$vo.bank_card|default="------"}</td>
<td rowspan="{$vo.rowspan}">{$vo.bank_name|default="------"}</td>
<td rowspan="{$vo.rowspan}">{$vo.alipay_user|default="------"}</td>
<td rowspan="{$vo.rowspan}">{$vo.is_received|default="否"}</td>
<td rowspan="{$vo.rowspan}">{$vo.is_surplus|default="否"}</td>
<td rowspan="{$vo.rowspan}">{$vo.before_amount|default="0"}</td>
<td rowspan="{$vo.rowspan}">{$vo.is_contract|default="------"}</td>
<td rowspan="{$vo.rowspan}">
<span class="form-required" style="line-height: 30px;">{$vo['agreement_time']['start_time']}</span>&nbsp;&nbsp;&nbsp;&nbsp;
<span class="form-required" style="line-height: 30px;">{$vo['agreement_time']['end_time']|default="永久"}</span></td>
<td rowspan="{$vo.rowspan}">
<span class="form-required" style="line-height: 30px;">{$vo['balance_time']['start_time']}</span>&nbsp;&nbsp;&nbsp;&nbsp;
<span class="form-required" style="line-height: 30px;">{$vo['balance_time']['end_time']|default="永久"}</span>
</td>
<td rowspan="{$vo.rowspan}">{$vo['tax_point']}%</td>
<td rowspan="{$vo.rowspan}">{$vo.invoice_type|default="------"}</td>
<td rowspan="{$vo.rowspan}">{$vo.tax_ratio|default="------"}%</td>
<td rowspan="{$vo.rowspan}">{$vo.channel_radio|default="------"}%</td>
<td rowspan="{$vo.rowspan}">{$vo.connection_person|default="------"}</td>
<td rowspan="{$vo.rowspan}">{$vo.phone|default="------"}</td>
<td rowspan="{$vo.rowspan}">{$vo.connection_address|default="------"}</td>
</tr>
<volist name="vo.game_name" id="sec" key="index">
<if condition="$index gt 1">
<tr>
<td rowspan="{$vo['sec_rowspan'][$index-1]}">{$vo['original_package_name'][$index-1]|default="------"}</td>
<td rowspan="{$vo['sec_rowspan'][$index-1]}">{$vo['game_name'][$index-1]|default="------"}</td>
<td rowspan="{$vo['sec_rowspan'][$index-1]}">{$vo['game_name'][$index-1]|default="------"}</td>
<td rowspan="{$vo['sec_rowspan'][$index-1]}">{$vo['game_type'][$index-1]|default="------"}</td>
<td rowspan="{$vo['sec_rowspan'][$index-1]}">{$vo['withdraw_type'][$index-1]|default="------"}</td>
<td rowspan='1'>{$vo['rate_data'][$index-1][0]['exploitation_name']}</td>
<td rowspan='1'>{$vo['rate_data'][$index-1][0]['exploitation_rate']}</td>
</tr>
</if>
<volist name="vo['rate_data'][$index-1]" id="rate" key="rate_index">
<if condition="$rate['exploitation_name'] neq '默认'">
<tr>
<td rowspan='1'>{$rate.exploitation_name}</td>
<td rowspan='1'>{$rate.exploitation_rate}</td>
</tr>
</if>
</volist>
</volist>
</volist>
</notemtpy>
</tbody>
</table>
</div>
</empty>
</div>
</block>
<block name="script">
<script src="__STATIC__/layer/layer.js" type="text/javascript"></script>
<script type="text/javascript" src="__STATIC__/layer/extend/layer.ext.js" ></script>
<link href="__STATIC__/datetimepicker/css/datetimepicker.css" rel="stylesheet" type="text/css">
<php>if(C('COLOR_STYLE')=='blue_color') echo '<link href="__STATIC__/datetimepicker/css/datetimepicker_blue.css" rel="stylesheet" type="text/css">';</php>
<link href="__STATIC__/datetimepicker/css/dropdown.css" rel="stylesheet" type="text/css">
<script type="text/javascript" src="__STATIC__/datetimepicker/js/bootstrap-datetimepicker.min.js"></script>
<script type="text/javascript" src="__STATIC__/datetimepicker/js/locales/bootstrap-datetimepicker.zh-CN.js" charset="UTF-8"></script>
<script src="__STATIC__/table2excel.js"></script>
<script type="text/javascript">
$("#channel_id").select2();
$("#company_properties").select2();
$("#origin_game_name").select2();
$("#game_id").select2();
function showWindow() {
layer.open({
type: 2,
title: "游戏登录记录",
shadeClose: true,
shade: 0.8,
area: ['70%', '80%'],
content: ['admin.php?s=/Member/denglu/id/', 'no']
});
}
function get_game_list()
{
var game_name = "{:I('game_id')}";
$.ajax({
url:"{:U('PayChannel/getGameList')}",
type:"post",
data:{partner_id:$("#partner_id option:selected").val(), sdk_type:$("#sdk_version1 option:selected").val()},
dataType:'json',
success:function(data){
var str = "<option value=''>请选择游戏</option>";
for (var i in data){
str += "<option value='"+data[i].id+"'"+(game_name && data[i].id == game_name?'selected':'')+">"+data[i].game_name+"</option>"
}
// console.log(str);
$("#game_name").empty();
$("#game_name").append(str);
$("#game_name").select2();
}
})
}
get_game_list();
$(function(){
$("#exporttable").table2excel({
filename: "下游聚合公司导出.xls", // do include extension
preserveColors: false // set to true if you want background colors and font colors preserved
});
$('#timestart').datetimepicker({
format: 'yyyy-mm-dd',
language:"zh-CN",
minView:2,
autoclose:true
});
$('#datetimepicker').datetimepicker({
format: 'yyyy-mm-dd',
language:"zh-CN",
minView:2,
autoclose:true,
pickerPosition:'bottom-left'
})
//搜索功能
$("#search").click(function(){
var starttime = $.trim($('#time-start').val());
var endtime = $.trim($('#time-end').val());
if (starttime && endtime && starttime > endtime) {layer.msg('开始时间必须小于等于结束时间');return false;}
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>
</html>

@ -0,0 +1,359 @@
<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;}
.tooltip {
position: relative;
display: inline-block;
color: #056dae;
}
.tooltip .tooltiptext {
visibility: hidden;
width: 250%;
background-color: #fff;
color: #fff;
text-align: center;
border-radius: 6px;
padding: 5px 0;
position: absolute;
z-index: 1;
bottom: 80%;
left: 0;
margin-left: -70%;
border: #000 solid 1px;
}
.tooltip .tooltiptext::after {
content: "";
position: absolute;
top: 100%;
left: 50%;
margin-left: -5px;
border-width: 5px;
border-style: solid;
border-color: black transparent transparent transparent;
}
.tooltip:hover .tooltiptext {
color: #000;
visibility: visible;
line-height: 20px;
}
</style>
<div class="cf main-place top_nav_list navtab_list">
<h3 class="page_title">下游聚合公司列表</h3>
<!-- <p class="description_text">说明平台币直充金额2019.12.18以前sdk新包数据及sdk旧包数据无法对应相关游戏无法计入以上平台币列表中<span style="color:red">充值方式统计</span>一栏统计<span style="color:red">平台币直充总金额</span></p>-->
<!-- <div class="fr">-->
<!-- <a href="PayChannel/index">游戏充值统计</a>-->
<!-- <a class="" href="{:U('Finance/payTypeStatistics')}">充值方式统计</a>-->
<!-- <a class="tabchose">收款商户统计</a>-->
<!-- </div>-->
</div>
<div class="cf top_nav_list">
<!-- 高级搜索 -->
<div class="jssearch fl cf search_list">
<!--游戏类型搜索END-->
<div class="input-list input-list-game search_label_rehab">
<select id="channel_id" name="channel_id" class="select_gallery" >
<option value="">请选择合作公司</option>
<volist name=":getCpCompanySelect(1)" id="vo">
<option value="{$vo.id}" <if condition="$vo.id eq I('channel_id')">selected</if> >{$vo.name}</option>
</volist>
</select>
</div>
<div class="input-list input-list-spend search_label_rehab">
<select id="company_properties" name="company_properties" class="select_gallery" style="width:120px;">
<option value="">请选择公司性质</option>
<option value="0">个人</option>
<option value="1">公司</option>
</select>
</div>
<div class="input-list input-list-game search_label_rehab">
<select id="origin_game_name" name="origin_game_name" class="select_gallery" >
<option value="">请选择原包名</option>
<volist name=":getCpCompanySelect(2)" id="vo">
<if condition="$vo.original_package_name neq ''">
<option value="{$vo.original_package_name}" <if condition="$vo.original_package_name eq I('original_package_name')">selected</if> >{$vo.original_package_name}</option>
</if>
</volist>
</select>
</div>
<div class="input-list input-list-game search_label_rehab">
<select id="game_id" name="game_id" class="select_gallery" >
<option value="">请选择现包名</option>
<volist name=":getCpCompanySelect(2)" id="vo">
<option value="{$vo.id}" <if condition="$vo.id eq I('id')">selected</if> >{$vo.game_name}</option>
</volist>
</select>
</div>
<input type="hidden" name="" value="" class="sortBy">
<div class="input-list">
<a class="sch-btn" href="javascript:;" id="search" url="{:U('CpJuheCompany/index','model='.$model['name'].'&row='.I('row'),false)}"
style="width: 100px;border: #3C95C8 solid 1px;">搜索</a>
<a class="sch-btn" url="{:U('/CpJuheCompany/index',
array_merge(array('export'=>1),I('get.'))
,false)}" style="width: 100px;border: #3C95C8 solid 1px;" id="downloadexcel">导出</a>
</div>
</div>
</div>
<!-- 数据列表 -->
<div class="data_list">
<empty name="show_status">
<div class="">
<table>
<!-- 表头 -->
<thead>
<tr>
<th >合作方名称</th>
<th >对应平台</th>
<th >公司性质</th>
<!-- <th >支付渠道</th>-->
<th >原包名</th>
<th >现包名</th>
<th >聚合包名</th>
<th >产品类型</th>
<th >结算周期</th>
<th colspan="2">游戏分成比例</th>
<th >账户名</th>
<th >银行账号</th>
<th >开户行</th>
<th >支付宝账号</th>
<th >操作</th>
</tr>
</thead>
<!-- 列表 -->
<tbody>
<style>
.data-table thead th, .data-table tbody td{text-align:center}
.data-table tbody td{border-right:1px solid #DDDDDD;}
.d_list .drop-down ul {z-index:999;}
</style>
<!-- <if condition = "empty($data)">-->
<!-- <tr>-->
<!-- <td colspan="14" class="text-center">aOh! 暂时还没有内容!</td>-->
<!-- </tr>-->
<!-- </if>-->
<notemtpy name = "listdata">
<volist name="listdata" id="vo">
<tr>
<td rowspan="{$vo.rowspan}">{$vo.name|default="------"}</td>
<td rowspan="{$vo.rowspan}">{$vo.platform|default="------"}</td>
<td rowspan="{$vo.rowspan}">{$vo.company_properties|default="------"}</td>
<td rowspan="{$vo['sec_rowspan'][0]}">{$vo['original_package_name'][0]|default="------"}</td>
<td rowspan="{$vo['sec_rowspan'][0]}">{$vo['game_name'][0]|default="------"}</td>
<td rowspan="{$vo['sec_rowspan'][0]}">{$vo['game_name'][0]|default="------"}</td>
<td rowspan="{$vo['sec_rowspan'][0]}">{$vo['game_type'][0]|default="------"}</td>
<td rowspan="{$vo['sec_rowspan'][0]}">{$vo['withdraw_type'][0]|default="------"}</td>
<td rowspan='1'>默认</td>
<td rowspan='1'>{$vo['rate_data'][0][0]['exploitation_rate']|default="0"}</td>
<td rowspan="{$vo.rowspan}">{$vo.bank_user|default="------"}</td>
<td rowspan="{$vo.rowspan}">{$vo.bank_card|default="------"}</td>
<td rowspan="{$vo.rowspan}">{$vo.bank_name|default="------"}</td>
<td rowspan="{$vo.rowspan}">{$vo.alipay_user|default="------"}</td>
<td rowspan="{$vo.rowspan}">
<a href="{:U('CpJuheCompany/detail',array('id'=>$vo['id']))}">查看</a>
</td>
</tr>
<volist name="vo.game_name" id="sec" key="index">
<if condition="$index gt 1">
<tr>
<td rowspan="{$vo['sec_rowspan'][$index-1]}">{$vo['original_package_name'][$index-1]|default="------"}</td>
<td rowspan="{$vo['sec_rowspan'][$index-1]}">{$vo['game_name'][$index-1]|default="------"}</td>
<td rowspan="{$vo['sec_rowspan'][$index-1]}">{$vo['game_name'][$index-1]|default="------"}</td>
<td rowspan="{$vo['sec_rowspan'][$index-1]}">{$vo['game_type'][$index-1]|default="------"}</td>
<td rowspan="{$vo['sec_rowspan'][$index-1]}">{$vo['withdraw_type'][$index-1]|default="------"}</td>
<td rowspan='1'>{$vo['rate_data'][$index-1][0]['exploitation_name']}</td>
<td rowspan='1'>{$vo['rate_data'][$index-1][0]['exploitation_rate']}</td>
</tr>
</if>
<volist name="vo['rate_data'][$index-1]" id="rate" key="rate_index">
<if condition="$rate['exploitation_name'] neq '默认'">
<tr>
<td rowspan='1'>{$rate.exploitation_name}</td>
<td rowspan='1'>{$rate.exploitation_rate}</td>
</tr>
</if>
</volist>
</volist>
</volist>
</notemtpy>
</tbody>
</table>
</div>
</empty>
</div>
<div class="page">
{$_page|default=''}
</div>
</block>
<block name="script">
<script src="__STATIC__/layer/layer.js" type="text/javascript"></script>
<script type="text/javascript" src="__STATIC__/layer/extend/layer.ext.js" ></script>
<link href="__STATIC__/datetimepicker/css/datetimepicker.css" rel="stylesheet" type="text/css">
<php>if(C('COLOR_STYLE')=='blue_color') echo '<link href="__STATIC__/datetimepicker/css/datetimepicker_blue.css" rel="stylesheet" type="text/css">';</php>
<link href="__STATIC__/datetimepicker/css/dropdown.css" rel="stylesheet" type="text/css">
<script type="text/javascript" src="__STATIC__/datetimepicker/js/bootstrap-datetimepicker.min.js"></script>
<script type="text/javascript" src="__STATIC__/datetimepicker/js/locales/bootstrap-datetimepicker.zh-CN.js" charset="UTF-8"></script>
<script>
<volist name=":I('get.')" id="vo">
Think.setValue('{$key}',"{$vo}");
</volist>
</script>
<script type="text/javascript">
$("#channel_id").select2();
$("#company_properties").select2();
$("#origin_game_name").select2();
$("#game_id").select2();
//导航高亮
highlight_subnav('{:U('CpJuheCompany/index')}');
function showWindow() {
layer.open({
type: 2,
title: "游戏登录记录",
shadeClose: true,
shade: 0.8,
area: ['70%', '80%'],
content: ['admin.php?s=/Member/denglu/id/', 'no']
});
}
function get_game_list()
{
var game_name = "{:I('game_id')}";
$.ajax({
url:"{:U('PayChannel/getGameList')}",
type:"post",
data:{partner_id:$("#partner_id option:selected").val(), sdk_type:$("#sdk_version1 option:selected").val()},
dataType:'json',
success:function(data){
var str = "<option value=''>请选择游戏</option>";
for (var i in data){
str += "<option value='"+data[i].id+"'"+(game_name && data[i].id == game_name?'selected':'')+">"+data[i].game_name+"</option>"
}
// console.log(str);
$("#game_name").empty();
$("#game_name").append(str);
$("#game_name").select2();
}
})
}
get_game_list();
$(function(){
$("#downloadexcel").on("click",function(){
var url = $(this).attr("url");
var title = '下游聚合公司导出';
layer.open({
type: 2,
title: title,
shadeClose: true,
shade: 0.8,
area: ['40%', '60%'],
content: url
});
})
$('#timestart').datetimepicker({
format: 'yyyy-mm-dd',
language:"zh-CN",
minView:2,
autoclose:true
});
$('#datetimepicker').datetimepicker({
format: 'yyyy-mm-dd',
language:"zh-CN",
minView:2,
autoclose:true,
pickerPosition:'bottom-left'
})
//搜索功能
$("#search").click(function(){
var starttime = $.trim($('#time-start').val());
var endtime = $.trim($('#time-end').val());
if (starttime && endtime && starttime > endtime) {layer.msg('开始时间必须小于等于结束时间');return false;}
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>

@ -308,10 +308,10 @@
<td class="r table_radio">
<span class="form_radio table_btn">
<label >
<input type="radio" value="1" name="withdraw_done" <if condition="$data['withdraw_done'] eq 1">checked="checked"</if>> 开启
<input type="radio" value="1" name="withdraw_done" class="withdraw_done" <if condition="$data['withdraw_done'] eq 1">checked="checked"</if>> 开启
</label >
<label >
<input type="radio" value="0" name="withdraw_done" <if condition="$data['withdraw_done'] eq 0">checked="checked"</if>> 锁定
<input type="radio" value="0" name="withdraw_done" class="withdraw_done" <if condition="$data['withdraw_done'] eq 0">checked="checked"</if>> 锁定
</label>
</span>
</td>
@ -431,7 +431,7 @@
</table>
</div>
<input type="hidden" name="id" value="{$data['id']}" />
<input type="hidden" name="id" value="{$data['id']}" class="promote_id"/>
<div class="form-item cf">
<button class="submit_btn ajax-post mlspacing" id="submit" type="submit" target-form="form-horizontal">
@ -458,6 +458,8 @@
<block name="script">
<script type="text/javascript" src="__STATIC__/datetimepicker/js/bootstrap-datetimepicker.min.js"></script>
<script src="__STATIC__/layer/layer.js" type="text/javascript"></script>
<script type="text/javascript" src="__STATIC__/layer/extend/layer.ext.js" ></script>
<script type="text/javascript">
//导航高亮
highlight_subnav("{:U('Promote/lists')}");
@ -482,6 +484,25 @@ $(function(){
}
});
$(".withdraw_done").click(function () {
if($(this).val() == 1) {
$.ajax({
url:"{:U('Promote/getWithdrawDone')}",
type:"post",
data:{company_id:$("#company_id option:selected").val(),promote_id:$(".promote_id").val()},
dataType:'json',
success:function(data){
if (data.status==1) {
layer.alert('公司提现推广员只能设置一个,原先已设置提现推广员,保存后会将这个推广员设置成提现推广员');
}
}
})
}
});
});
// //得到地区码
// function getAreaID(){

@ -2175,4 +2175,13 @@ INSERT INTO `sj_game_channel`.`sj_cptogether_company`(`name`, `channel_id`) VALU
INSERT INTO `sj_game_channel`.`sj_cptogether_company`(`name`, `channel_id`) VALUES ('河南南北网络科技有限公司', 689);
INSERT INTO `sj_game_channel`.`sj_cptogether_company`(`name`, `channel_id`) VALUES ('福建君易道网络科技有限公司', 690);
INSERT INTO `sj_game_channel`.`sj_cptogether_company`(`name`, `channel_id`) VALUES ('泉州神战网络科技有限公司', 691);
INSERT INTO `sj_game_channel`.`sj_cptogether_company`(`name`, `channel_id`) VALUES ('北京浩游网讯科技有限公司', 692);
INSERT INTO `sj_game_channel`.`sj_cptogether_company`(`name`, `channel_id`) VALUES ('北京浩游网讯科技有限公司', 692);
ALTER TABLE `sj_game_channel`.`sj_cptogether_company`
ADD COLUMN `tax_ratio` varchar(10) NULL DEFAULT '' COMMENT '税费费率' AFTER `tax_identification_number`,
ADD COLUMN `channel_radio` varchar(10) NULL DEFAULT '' COMMENT '渠道费率' AFTER `tax_ratio`,
ADD COLUMN `connection_address` longtext NULL COMMENT '联系地址' AFTER `channel_radio`;
ALTER TABLE `sj_game_channel`.`sj_cptogether_company`
ADD COLUMN `is_received` tinyint(2) NULL DEFAULT 0 COMMENT '是否为收款方' AFTER `connection_address`;
INSERT INTO `sys_kv`(`id`, `key`, `value`, `type`, `remark`) VALUES (4, 'cp_company_api', 'http://10.0.1.161:8095/index.php?g=Api&m=CpJuheCompany&a=index', 'string', '聚合公司网址')
Loading…
Cancel
Save