Proyectos de Subversion LeadersLinked - Services

Rev

Rev 304 | Rev 308 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 304 Rev 307
Línea 97... Línea 97...
97
        return $this->executeFetchOneObject($select, $prototype);
97
        return $this->executeFetchOneObject($select, $prototype);
98
    }
98
    }
Línea 99... Línea 99...
99
    
99
    
100
    /**
100
    /**
-
 
101
     * 
101
     * 
102
     * @param int $user_id
102
     * @return HabitSkill[]
103
     * @return HabitSkill[]
103
     */
104
     */
-
 
105
    public function fetchAllByUserId($user_id)
-
 
106
    {
-
 
107
 
-
 
108
        $prototype = new HabitSkill();
-
 
109
        
-
 
110
        
-
 
111
        $select = $this->sql->select(self::_TABLE);
-
 
112
        $select->where->equalTo('user_id', $user_id);
-
 
113
        $select->order('name');
-
 
114
        
-
 
115
        return $this->executeFetchAllObject($select, $prototype);
-
 
116
    }
-
 
117
    
-
 
118
    /**
-
 
119
     * 
-
 
120
     * @param int[] $company_ids
-
 
121
     * @return HabitSkill[]
-
 
122
     */
104
    public function fetchAll()
123
    public function fetchAllTemplateByCompayIds($company_ids)
105
    {
124
    {
-
 
125
        $prototype = new HabitSkill();
-
 
126
        
106
        $prototype = new HabitSkill();
127
        
-
 
128
        $select = $this->sql->select(self::_TABLE);
-
 
129
        $select->where->in('company_id', $company_ids);
-
 
130
        $select->where->equalTo('template', HabitSkill::TEMPLATE_YES);
Línea 107... Línea 131...
107
        $select = $this->sql->select(self::_TABLE);
131
        $select->order('name');
108
        
132