<?php
class groupModel extends model{
	public $base;
	public function __construct(&$base){
		parent::__construct($base);
		$this->base=$base;
		$this->table="group";
		
	}
	
	
	public function getGroupByIds($uids,$fields=""){
		if(!empty($uids)){
			$option['where']=" gid in("._implode($uids).")";
			$fields && $option['fields']=$fields;
			$data=parent::select($option);
			if($data){
				$grouplist=array();
				foreach($data as $k=>$v){
					$grouplist[$v['gid']]=$v;
				}
				return $grouplist;
			}
		}
		return false;
	}
}

?>