master
yulingwei 4 years ago
parent 02f52412c1
commit bbb7cb23f6

@ -604,7 +604,7 @@ WHERE old_change_promote_id in ({$promoteData})";
} else {
if ($id) {
if ($delete) {
$useingService = M('promote_company')->where(['service_agreement_show'=>$id])->find();
$useingService = M('promote_company', 'tab_')->where(['service_agreement_show'=>$id])->find();
if (!empty($useingService)) return $this->error('有正在使用该服务协议的公司,无法删除');
$result = M('service_agreement', 'tab_')->where(['id'=>$id])->delete();
return $result ? $this->success('删除完成') : $this->error('删除失败');

Loading…
Cancel
Save