Merge branch 'release-1.0.0' of 47.111.118.107:wmtx/platform into release_zyx

master
zhengyongxing 5 years ago
commit a7e747e639

@ -199,6 +199,16 @@ class PromoteController extends ThinkController
parent::lists('SiteApply', $p, $map);
}
private function accountExist($account, $id = null)
{
$res = M('promote', 'tab_')->where(['account' => $account])->field('id')->find();
if ($res) {
return $id != $res['id'];
} else {
return false;
}
}
public function add($account=null, $password=null, $second_pwd=null, $real_name=null, $email=null,
$mobile_phone=null, $bank_name=null, $bank_card=null, $admin=null, $status=null, $ba_id = null, $company_id = null)
{
@ -206,6 +216,9 @@ class PromoteController extends ThinkController
if (C('PROMOTE_AUTO_AUDIT') == 1) {
$status = 1;
}
if ($this->accountExist($account)) {
$this->error('该账号已存在');
}
$data = array('account'=>$account,'password'=>$password,'second_pwd'=>$second_pwd,'real_name'=>$real_name,
'email'=>$email,'mobile_phone'=>$mobile_phone,'bank_name'=>$bank_name,'bank_card'=>$bank_card,
'admin_id'=>session('user_auth')['uid'],'status'=>$status,'ba_id'=>$ba_id, 'company_id' => $company_id);
@ -264,7 +277,9 @@ class PromoteController extends ThinkController
$data['account'] = I('post.account');
$map1['id'] = array('neq',$_POST['id']);
$map1['account'] = $data['account'];
if ($this->accountExist($data['account'])) {
$this->error('该账号已存在');
}
$pdata = D('Promote')->where($map1)->find();
if ($pdata) {

@ -154,7 +154,12 @@
<td>{$data.register_time|date='Y-m-d H:i:s',###}</td>
<td>{$data.register_ip}</td>
<td>
<if condition="$is_admin eq true ">
{:get_promote_parent_acc($data['promote_id'])}
<else />
{:encryptStr(get_promote_parent_acc($data['promote_id']))}
</if>
</td>
<td>
{:get_business_affairs_account($data['ba_id'])}

@ -607,7 +607,8 @@
jsgameid();
}else{
alert('请求失败');
var tip_msg = res.info ? res.info : '操作失败';
layer.msg(tip_msg);
}
});
});

@ -186,7 +186,13 @@
{$data.promote_account|encryptStr}
</if>
</td>
<td>{:get_promote_parent_acc($data['promote_id'])}</td>
<td>
<if condition="$is_admin eq true ">
{:get_promote_parent_acc($data['promote_id'])}
<else />
{:encryptStr(get_promote_parent_acc($data['promote_id']))}
</if>
</td>
<td>
<if condition="$is_admin eq true ">
{$data.user_account}

@ -18,7 +18,7 @@
position: absolute;
top: 100%;
left: 0;
z-index: 1000;
z-index: 10;
display: none;
float: left;
min-width: 160px;

@ -17,7 +17,7 @@ body{
position: fixed;
top: 0;
left: 0;
z-index: 1000;
z-index: 9999;
width: 100%;
/* height: 50px;
line-height: 50px; */

Loading…
Cancel
Save