<nav class="large-3 medium-4 columns" id="actions-sidebar">
      <?= $this->element('admin_sidebar') ?>
</nav>
<div class="regionalmanagers index large-9 medium-8 columns content">
<div class="col-md-6">
    <h3><?= __('Regional Manager') ?></h3></div>
	<div class="search-wrapper">  
<div class="col-md-6">
    <div class="btn-link"><?= $this->Html->link(__('Add RM'), ['action' => 'add'],['class'=>'green-btn', 'title' => 'Add New Regional Manager', 'type' => 'button']) ?></div></div>
	</div>
    <table cellpadding="0" cellspacing="0">
        <thead>
            <tr>
                <th scope="col"><?= $this->Paginator->sort('Sr No.') ?></th>
                <!--<th scope="col"><?= $this->Paginator->sort('id') ?></th>-->
                <th scope="col"><?= $this->Paginator->sort('manager') ?></th>
                <th scope="col"><?= $this->Paginator->sort('Branch Name') ?></th>
                <th scope="col" class="actions"><?= __('Actions') ?></th>
            </tr>
        </thead>
        <tbody>
            
            <?php $srno ="";
            foreach ($regionalmanagers as $regionalmanager): $srno++ ?>
            <tr>
                <td><?= $srno ?></td>
                <!--<td><?= $this->Number->format($regionalmanager->id) ?></td>-->
                <td><?= h($regionalmanager->manager) ?></td>
                <td>
					<?php if(isset($regionalmanager->branch->branchname)){?>
					<?= $regionalmanager->branch->branchname; }?>
				</td>
                <td class="actions">
                                      <?= $this->Html->link(__('View'), ['action' => 'view', $regionalmanager->id],['class' => 'view','title'=>__('View')]) ?>
                    <?= $this->Html->link(__('Edit'), ['action' => 'edit', $regionalmanager->id],['class' => 'edit','title'=>__('Edit')]) ?>
                    <?= $this->Form->postLink(__('Delete'), ['action' => 'delete', $regionalmanager->id], ['class' => 'delete','title'=>__('Delete'),'confirm' => __('Are you sure you want to delete # {0}?', $regionalmanager->id)]) ?>                </td>
                </td>
            </tr>
            <?php endforeach; ?>
        </tbody>
    </table>
    <div class="paginator">
        <ul class="pagination">
            <?= $this->Paginator->prev('< ' . __('previous')) ?>
            <?= $this->Paginator->numbers() ?>
            <?= $this->Paginator->next(__('next') . ' >') ?>
        </ul>
        <p><?= $this->Paginator->counter() ?></p>
    </div>
</div>
