<div class="page-content-wrapper">
    <div class="page-content all">
        <div class="row">
            <div class="col-md-12">
                <!-- BEGIN EXAMPLE TABLE PORTLET-->


                <div class="portlet box blue">
                    <div class="portlet-title">
                        <div class="caption">
                            <i class="fa fa-cogs"></i>Vacations
                        </div>
                        <div class="actions">
                            <a class="btn btn-default btn-sm" href="{$hosturl}/controllers/{$control_name}.php">
                                <i class="fa fa-plus"></i> Add </a>
                        </div>

                    </div>
                    <div class="portlet-body" style="padding: 15px;">
                        <input id="patientId" type="hidden" value="{$patientId}">
                        <table class="table table-striped table-bordered table-hover" id="sample_3">
                            <thead>
                            <tr>
                                <th style="width: 5%;">No</th>
                                <th>Name / Reason</th>
                                <th>Date</th>
                                <th style="width: 5%;">Edit</th>
                                <th style="width: 5%;">Delete</th>
                            </tr>
                            </thead>
                            <tbody>
                            {assign var=m value=1}
                            {foreach $vacations as $single}
                            <tr class="odd gradeX ">
                                <td>{$m}</td>
                                <td>{$single->vacation_reason}</td>
                                <td>{$single->vacation_date|date_format:'Y/m/d'}</td>
                                <td>
                                    <a class="btn green btn-block btn-xs" href="{$hosturl}/controllers/{$control_name}.php?ac=edit&id={$single.id}"><i class="fa fa-pencil"></i> Edit</a>
                                </td>
                                <td>
                                    <a class="btn grey-cascade btn-xs deletemsgEX" data-fn="del" data-id="{$single.id}" data-link="{$control_name}"><i class="fa fa-times"></i>Delete </a>
                                </td>
                            </tr>
                            {capture assign=m}{$m+1}{/capture}
                            {/foreach}
                            </tbody>

                        </table>
                    </div>
                </div>
            </div>
        </div>

    </div>
</div>

