| 1234567891011121314151617181920212223242526272829303132333435 |
- <?php
- Doo::loadCore('db/DooModel');
- class itemStatistics extends DooModel {
- public $sid;
- public $itemCategory;
- public $date;
- public $cid;
- public $staff;
- public $price;
-
- public $_table = 'CLD_itemStatistics';
- public $_primarykey = 'sid';
-
- public $_fields = array('sid', 'staff', 'itemCategory', 'price', 'date', 'cid');
- function getClientByCid($cid){
- $sql = "select sum(price) from " . $this->_table . " where staff= '".$cid."' and " ;
-
- $query = Doo::db ()->query ( $sql );
-
- $result = $query->fetch ();
-
- return $result;
- }
- /*
- public function getProjectByIdList($projectid){
- return $this->find ( array ('where' => "pid= '".$projectid."'", 'asArray' => TRUE ) );
- }
- */
- }
- ?>
|