01 /*--------------------------02 //取消审核文档03 function checkArchives1() { }04 ---------------------------*/05 else if($dopost=="checkArchives1")06 {07 CheckPurview('a_Check,a_AccCheck,sys_ArcBatch');08 require_once(DEDEADMIN."/inc/inc_archives_functions.php");09 if( !empty($aid) && empty($qstr) )10 {11 $qstr = $aid;12 }13 if($qstr=='')14 {15 ShowMsg("参数无效!",$ENV_GOBACK_URL);16 exit();17 }18 $arcids = ereg_replace('[^0-9,]','',ereg_replace('`',',',$qstr));19 $query = "Select arc.id,arc.typeid,ch.issystem,ch.maintable,ch.addtable From `dede_arctiny` arc20 left join `dede_arctype` tp on tp.id=arc.typeid21 left join `dede_channeltype` ch on ch.id=tp.channeltype22 where arc.id in($arcids) ";23 $dsql->SetQuery($query);24 $dsql->Execute('ckall');25 while($row = $dsql->GetArray('ckall'))26 {27 $aid = $row['id'];28 //print_r($row);29 $maintable = ( trim($row['maintable'])=='' ? 'dede_archives' : trim($row['maintable']) );30 $dsql->ExecuteNoneQuery("Update `dede_arctiny` set arcrank='-1' where id='$aid' ");31 if($row['issystem']==-1)32 {33 $dsql->ExecuteNoneQuery("Update `".trim($row['addtable'])."` set arcrank='-1' where aid='$aid' ");34 }35 else36 {37 $dsql->ExecuteNoneQuery("Update `$maintable` set arcrank='-1' where id='$aid' ");38 }39 $pageurl = MakeArt($aid,false);40 }41 ShowMsg("成功审核指定的文档!",$ENV_GOBACK_URL);42 exit();43 }
1 function checkArc(aid){2 var qstr=getCheckboxItem();3 if(aid==0) aid = getOneItem();4 location="archives_do.php?aid="+aid+"&dopost=checkArchives&qstr="+qstr;5 }在下面添加代码:1 function checkArc1(aid){2 var qstr=getCheckboxItem();3 if(aid==0) aid = getOneItem();4 location="archives_do.php?aid="+aid+"&dopost=checkArchives1&qstr="+qstr;5 }
1 <a href="javascript:checkArc(0)" class="coolbg"> 审核 </a>2 <a href="javascript:checkArc1(0)" class="coolbg"> 取消审核 </a>
新闻热点
疑难解答