Пример #1
0
                                        <th>Idade</th>
                                        <th>Ação</th>
                                    </tr>
                                    </thead>
                                    <tbody>
                                    <?php 
if (Resident::getResidents() != '') {
    foreach (Resident::getResidents() as $res) {
        echo '<tr>';
        echo '<td>' . $res->getId() . '</td>';
        echo '<td>' . '<a class="modalResident" data-id="' . $res->getId() . '" >' . $res->getName() . '</a>' . '</td>';
        echo '<td>' . $res->getEmail() . '</td>';
        echo '<td>' . $res->getReligion()->getName() . '</td>';
        echo '<td>' . $res->getAge() . '</td>';
        echo '<td>' . '<a href="forms.php?p=altMorador&cod=' . $res->getId() . '"><i class="icon-pencil"></i>Editar</a>' . '  |  ';
        if (Research::existResearch($res->getId())) {
            echo '<i class="icon icon-check" style="color: green"></i> Pesquisa Realizada';
        } else {
            echo '<a href="forms.php?p=cadPesquisa&cod=' . $res->getId() . '"><i class="icon-edit" style="color: red"></i>Realizar Pesquisa</a>';
        }
        echo '</td>';
        echo '</tr>';
    }
}
?>
                                    </tbody>
                                </table>
                            </div>
                        </div>
                    </div>
                </div>