webmain/system/group/groupAction.php
(开头部分) 2KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
<?php
class groupClassAction extends Action
{
public function groupusershow($table)
{
$s = 'and 1=2';
$gid = (int)$this->post('gid','0');
if($gid>0){
$s = " and ( id in( select `sid` from `[Q]sjoin` where `type`='gu' and `mid`='$gid') or id in( select `mid` from `[Q]sjoin` where `type`='ug' and `sid`='$gid') )";
}
return array(
'where' => $s,
'fields'=> 'id,user,name,deptname,ranking'
);
}
public function groupafter($table, $rows)
{
$nosq = 'select `id` from `[Q]admin` where `status`=1';
m('sjoin')->delete("`type`='gu' and `sid` not in($nosq)");
m('sjoin')->delete("`type`='ug' and `mid` not in($nosq)");
$carr = m('admin')->getcompanyinfo(0,5);
$dbs = m('company');
foreach($rows as $k=>$rs){
$gid = $rs['id'];
$s = "( id in( select `sid` from `[Q]sjoin` where `type`='gu' and `mid`='$gid') or id in( select `mid` from `[Q]sjoin` where `type`='ug' and `sid`='$gid') )";
$rows[$k]['utotal'] = $this->db->rows('[Q]admin', $s);
$companyname = '';
if($rs['companyid']>0 && getconfig('companymode'))$companyname = $dbs->getmou('name', $rs['companyid']);
$rows[$k]['companyname'] = $companyname;
}
return array(
'rows' => $rows,
'carr' => $carr,
);
}
public function saveuserAjax()
{
$gid = (int)$this->post('gid','0');
$sid = c('check')->onlynumber($this->post('sid','0'));
$dbs = m('sjoin');
$dbs->delete("`mid`='$gid' and `type`='gu' and `sid` in($sid)");
$this->db->insert('[Q]sjoin','`type`,`mid`,`sid`', "select 'gu','$gid',`id` from `[Q]admin` where `id` in($sid)", true);
m('admin')->updateinfo('and a.`id` in('.$sid.')');
echo 'success';
}
public function deluserAjax()
{
$gid = (int)$this->post('gid','0');
$sid = c('check')->onlynumber($this->post('sid','0'));
$dbs = m('sjoin');
$dbs->delete("`mid`='$gid' and `type`='gu' and `sid`='$sid'");
$dbs->delete("`sid`='$gid' and `type`='ug' and `mid`='$sid'");
后面还有 4 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。
