master
yulingwei 5 years ago
parent 747bba16b0
commit 8b51a16730

@ -855,6 +855,9 @@ class GameController extends ThinkController
}
if ($id) {
if (!M('game', 'tab_')->where(['partner_id'=>$_POST['partner_id']])->count()) {
return $this->error('当前对象无关联游戏');
}
$_POST['upt_time'] = time();
$_POST['operater_id'] = is_login();
$upt = M('partner_divide_warn', 'tab_')->where(['id'=>$id])->save($_POST);
@ -863,6 +866,9 @@ class GameController extends ThinkController
if (M('partner_divide_warn', 'tab_')->where(['partner_id'=>$_POST['partner_id'], 'status'=>1])->find()) {
return $this->error('已有当前合作伙伴的预警设置');
}
if (!M('game', 'tab_')->where(['partner_id'=>$_POST['partner_id']])->count()) {
return $this->error('当前对象无关联游戏');
}
$_POST['upt_time'] = $_POST['create_time'] = time();
$_POST['operater_id'] = is_login();
$ins = M('partner_divide_warn', 'tab_')->add($_POST);

Loading…
Cancel
Save