标签:style blog io ar color os sp for on
1 /** 2 * 获取财务人员 3 * @author guosi <cc.guo@musikid.com> 4 * @return void 5 * @version 2014-11-11 6 **/ 7 8 function get_finance_members() 9 { 10 11 // $this->load->driver(‘cache‘, array(‘adapter‘ => ‘memcached‘, ‘backup‘ => ‘file‘)); 12 $bd_members = array(); 13 // if (! $bd_members = $this->cache->get(‘bd_members‘)) 14 if (true) 15 { 16 $this->db->select(‘userid,real_name‘); 17 $this->db->where(‘b.gid‘, 5); 18 $this->db->join(‘user AS a‘, ‘a.userid = b.uid‘, ‘left‘); 19 $this->db->group_by(‘a.userid‘); 20 $this->db->order_by(‘userid‘, ‘asc‘); 21 $query = $this->db->get(‘admin_apost AS b‘); 22 23 foreach ($query->result() as $row) 24 { 25 $bd_members[$row->userid] = $row->real_name; 26 } 27 28 // $this->cache->save(‘bd_members‘, $bd_members, 7*24*3600); 29 } 30 31 return $bd_members; 32 } 33 // --------------------------------------------------------------------
标签:style blog io ar color os sp for on
原文地址:http://www.cnblogs.com/codelife1988/p/4118765.html