CakeAccounting/templates/DeAccountStatements/index.php

47 lines
2.4 KiB
PHP

<?php
/**
* @var \App\View\AppView $this
* @var iterable<\Cake\Datasource\EntityInterface> $deAccountStatements
*/
?>
<div class="deAccountStatements index content">
<?= $this->Html->link(__('New De Account Statement'), ['action' => 'add'], ['class' => 'button float-right']) ?>
<h3><?= __('De Account Statements') ?></h3>
<div class="table-responsive">
<table>
<thead>
<tr>
<th><?= $this->Paginator->sort('account_number') ?></th>
<th><?= $this->Paginator->sort('statement_date') ?></th>
<th><?= $this->Paginator->sort('closing_balance') ?></th>
<th class="actions"><?= __('Actions') ?></th>
</tr>
</thead>
<tbody>
<?php foreach ($deAccountStatements as $deAccountStatement): ?>
<tr>
<td><?= $deAccountStatement->hasValue('de_account') ? $this->Html->link($deAccountStatement->de_account->name, ['controller' => 'DeAccounts', 'action' => 'view', $deAccountStatement->de_account->id]) : '' ?></td>
<td><?= h($deAccountStatement->statement_date) ?></td>
<td><?= $this->Number->format($deAccountStatement->closing_balance) ?></td>
<td class="actions">
<?= $this->Html->link(__('View'), ['action' => 'view', $deAccountStatement->account_number]) ?>
<?= $this->Html->link(__('Edit'), ['action' => 'edit', $deAccountStatement->account_number]) ?>
<?= $this->Form->postLink(__('Delete'), ['action' => 'delete', $deAccountStatement->account_number], ['confirm' => __('Are you sure you want to delete # {0}?', $deAccountStatement->account_number)]) ?>
</td>
</tr>
<?php endforeach; ?>
</tbody>
</table>
</div>
<div class="paginator">
<ul class="pagination">
<?= $this->Paginator->first('<< ' . __('first')) ?>
<?= $this->Paginator->prev('< ' . __('previous')) ?>
<?= $this->Paginator->numbers() ?>
<?= $this->Paginator->next(__('next') . ' >') ?>
<?= $this->Paginator->last(__('last') . ' >>') ?>
</ul>
<p><?= $this->Paginator->counter(__('Page {{page}} of {{pages}}, showing {{current}} record(s) out of {{count}} total')) ?></p>
</div>
</div>