Пример #1
0
                    <th>Synced</th>
                    <th>Actions</th>
                </tr>
                </thead>
                <tbody>
                    <?php 
/**
 * Created by PhpStorm.
 * User: evolutionarycoder
 * Date: 2/4/16
 * Time: 7:01 PM
 */
use Backend\Database\Tables\Promises;
use Backend\Helpers\TableBuilder;
$table = new Promises();
$data = $table->readAll();
$builder = new TableBuilder();
if ($data !== false) {
    for ($i = 0; $i < count($data); $i++) {
        $decoded = clone $data[$i];
        $table->stripAndDecode($decoded);
        $table->strip($data[$i]);
        $current = $data[$i];
        $builder->buildCell($decoded->getPromise())->buildCell($decoded->getSynced());
        $builder->addActionAttrs("promise", $current->getPromise())->addActionAttrs("id", $current->getId());
        $builder->addRowAttr("id", $current->getId());
        echo $builder->buildRow();
    }
}
?>
                </tbody>