<?php
/**
 * Class that operate on table 'assetscat'. Database Mysql.
 *
 * @author: http://phpdao.com
 * @date: 2013-04-07 10:32
 */
class AssetscatMySqlExtDAO extends AssetscatMySqlDAO{

	public function queryAlllimted($startpoint,$perpage){
		$sql = 'SELECT * FROM assetscat ORDER BY assetscatid DESC 
		limit '.$startpoint.','.$perpage.'';
		$sqlQuery = new SqlQuery($sql);
		return $this->getList($sqlQuery);
	}
	
	
	public function queryAllExt(){
		$sql = 'SELECT * FROM assetscat ORDER BY assetscatid DESC ';
		$sqlQuery = new SqlQuery($sql);
		return $this->getList($sqlQuery);
	}

		// updatedel
	public function updatedel($assetscat){
		$sql = 'UPDATE assetscat SET userid = ?, del = ? WHERE assetscatid = ?';
		$sqlQuery = new SqlQuery($sql);
		
		
		$sqlQuery->setNumber($assetscat->userid);
		
		$sqlQuery->setNumber($assetscat->del);

		$sqlQuery->setNumber($assetscat->assetscatid);
		return $this->executeUpdate($sqlQuery);
	}

}
?>