MCPcopy Create free account
hub / github.com/Rello/analytics / read

Method read

lib/Db/PanoramaMapper.php:126–142  ·  view source on GitHub ↗

* get single report * @param int $id * @return array * @throws Exception */

(int $id)

Source from the content-addressed store, hash-verified

124 * @throws Exception
125 */
126 public function read(int $id)
127 {
128 $sql = $this->db->getQueryBuilder();
129 $sql->from(self::TABLE_NAME)
130 ->select('*')
131 ->where($sql->expr()->eq('id', $sql->createNamedParameter($id)));
132 $statement = $sql->executeQuery();
133 $result = $statement->fetch();
134 $statement->closeCursor();
135
136 if ($result !== false) {
137 $result['type'] = (int) $result['type'];
138 $result['parent'] = (int) $result['parent'];
139 }
140
141 return $result;
142 }
143
144 /**
145 * update report

Callers

nothing calls this directly

Calls 2

eqMethod · 0.80
fetchMethod · 0.80

Tested by

no test coverage detected