Skip to content

Instantly share code, notes, and snippets.

@galvao
Created January 14, 2015 07:20
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save galvao/8d0cb458044fa5dc84de to your computer and use it in GitHub Desktop.
Save galvao/8d0cb458044fa5dc84de to your computer and use it in GitHub Desktop.
The problematic partial
<table class="datagrid">
<thead>
<tr>
<th>
Nome
<span class="sorter" direction="up">
<img class="clickable" src="/image/icon/blueTopArrow.png">
</span>
<span class="sorter" direction="down">
<img class="clickable" src="/image/icon/blueBottomArrow.png">
</span>
</th>
<th width="100">
Ações
</th>
</tr>
</thead>
<tbody>
<?php
if ($this->dataCount) {
foreach ($this->data as $record) {
echo '<tr class="datarow">';
echo '<td><a class="record" href="' . $this->url('activity-type-list', array(), array('force_canonical' => true), true) . '">' . $record->name . '</a><br>
<a class="record" href="' . $this->serverUrl() . '/tipo_atividade">' . $record->name . '<br>
<a class="record" href="http://www.foo.com/bar">Foo</a><br>
<a class="record" href="' . $this->serverUrl() . '/tipo_atividade">' . $record->name . '</a></td>';
echo '<td align="right" valign="middle" id="r' . $record->id . '"><img class="action clickable invisible" src="/image/icon/edit.png">&nbsp;&nbsp;<img class="action clickable invisible" src="/image/icon/delete.png"></td>';
echo '</tr>';
}
} else {
?>
<tr>
<td>Nenhum registro encontrado</td>
</tr>
<?php
}
?>
</tbody>
</table>
<script type="text/javascript" src="/js/datagrid.js"></script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment