|
@@ 160-164 (lines=5) @@
|
| 157 |
|
// Render each entity view in collection |
| 158 |
|
foreach ($collection as $row) { |
| 159 |
|
// Call external handler |
| 160 |
|
if (is_callable($this->itemView)) { |
| 161 |
|
$html .= call_user_func($this->itemView, $this->renderer, $this->query, $row); |
| 162 |
|
} else { // Call default renderer |
| 163 |
|
$html .= $this->renderItem($row); |
| 164 |
|
} |
| 165 |
|
} |
| 166 |
|
|
| 167 |
|
// Render collection main view with items |
|
@@ 168-172 (lines=5) @@
|
| 165 |
|
} |
| 166 |
|
|
| 167 |
|
// Render collection main view with items |
| 168 |
|
if (is_callable($this->indexView)) { |
| 169 |
|
$html .= call_user_func($this->indexView, $this->renderer, $this->query); |
| 170 |
|
} else { // Call default renderer |
| 171 |
|
$html = $this->renderIndex($html); |
| 172 |
|
} |
| 173 |
|
} else { // Render empty entity view |
| 174 |
|
if (is_callable($this->emptyView)) { |
| 175 |
|
$html .= call_user_func($this->emptyView, $this->renderer, $this->query); |
|
@@ 173-179 (lines=7) @@
|
| 170 |
|
} else { // Call default renderer |
| 171 |
|
$html = $this->renderIndex($html); |
| 172 |
|
} |
| 173 |
|
} else { // Render empty entity view |
| 174 |
|
if (is_callable($this->emptyView)) { |
| 175 |
|
$html .= call_user_func($this->emptyView, $this->renderer, $this->query); |
| 176 |
|
} else { |
| 177 |
|
$html .= $this->renderEmpty(); |
| 178 |
|
} |
| 179 |
|
} |
| 180 |
|
|
| 181 |
|
return $html; |
| 182 |
|
} |