@@ 2191-2202 (lines=12) @@ | ||
2188 | PMF_Db::getTablePrefix(), |
|
2189 | $id_question); |
|
2190 | ||
2191 | if ($result = $this->_config->getDb()->query($query)) { |
|
2192 | if ($row = $this->_config->getDb()->fetchObject($result)) { |
|
2193 | $question = array( |
|
2194 | 'id' => $row->id, |
|
2195 | 'username' => $row->username, |
|
2196 | 'email' => $row->email, |
|
2197 | 'category_id' => $row->category_id, |
|
2198 | 'question' => $row->question, |
|
2199 | 'created' => $row->created, |
|
2200 | 'is_visible' => $row->is_visible); |
|
2201 | } |
|
2202 | } |
|
2203 | ||
2204 | return $question; |
|
2205 | } |
|
@@ 2228-2241 (lines=14) @@ | ||
2225 | PMF_Db::getTablePrefix(), |
|
2226 | ($all == false ? "WHERE is_visible = 'Y'" : '')); |
|
2227 | ||
2228 | if ($result = $this->_config->getDb()->query($query)) { |
|
2229 | while ($row = $this->_config->getDb()->fetchObject($result)) { |
|
2230 | $questions[] = array( |
|
2231 | 'id' => $row->id, |
|
2232 | 'username' => $row->username, |
|
2233 | 'email' => $row->email, |
|
2234 | 'category_id' => $row->category_id, |
|
2235 | 'question' => $row->question, |
|
2236 | 'created' => $row->created, |
|
2237 | 'answer_id' => $row->answer_id, |
|
2238 | 'is_visible' => $row->is_visible |
|
2239 | ); |
|
2240 | } |
|
2241 | } |
|
2242 | return $questions; |
|
2243 | } |
|
2244 |