From 34ad3d40fc6327c3868555e652663a3e412f3c3a Mon Sep 17 00:00:00 2001 From: wlx Date: Fri, 16 Sep 2011 05:45:22 +0000 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8DSQL=E9=87=8D=E5=A4=8D?= =?UTF-8?q?=E8=AE=B0=E5=BD=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- application/admin/controllers/DownController.php | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/application/admin/controllers/DownController.php b/application/admin/controllers/DownController.php index 66ddb57d..884cf9ca 100644 --- a/application/admin/controllers/DownController.php +++ b/application/admin/controllers/DownController.php @@ -147,7 +147,6 @@ class Admin_DownController extends Zend_Controller_Action } else if($reset > 0) { - $search="select * from offlineapp where"; $sql="update dataorder set status='1' where status='3' and offlineappid='$reset'"; if($this->db->exec($sql)>0) { @@ -161,16 +160,8 @@ class Admin_DownController extends Zend_Controller_Action }//elseif //if }//reset - /*$select=$this->db->select(); - $select ->from('offlineapp as o') - ->join('dataorder as d','o.id = d.offlineappid') - ->where('o.ts_approved is null') - ->where('o.pdflink is not null') - ->where('d.status=3') - //->where('d.offlineappid>0') - ->order('o.ts_created desc');*/ - $select="select o.*,d.status,d.offlineappid from offlineapp o + $select="select distinct(o.*) from offlineapp o left join dataorder d on o.id=d.offlineappid where o.ts_approved is null and o.pdflink is not null