type2.inc.php 579 B

1234567891011121314
  1. <?php
  2. global $_GPC, $_W;
  3. $GLOBALS['frames'] = $this->getMainMenu();
  4. $sql="select a.* ,b.type_name from " . tablename("zhtc_type2") . " a" . " left join " . tablename("zhtc_type") . " b on b.id=a.type_id where a.uniacid=:uniacid order by num asc";
  5. $list=pdo_fetchall($sql,array(':uniacid'=>$_W['uniacid']));
  6. if($_GPC['id']){
  7. $res=pdo_delete('zhtc_type2',array('id'=>$_GPC['id']));
  8. if($res){
  9. message('删除成功',$this->createWebUrl('type2',array()),'success');
  10. }else{
  11. message('删除失败','','error');
  12. }
  13. }
  14. include $this->template('web/type2');