{literal}
<script>
    $('.calcCost').live('keyup', function () {
        var minCost = Number($(this).attr('data-minCost'));
        var noOfMin = Number($(this).val());

        var cost = noOfMin * minCost;

        var id = $(this).attr('data-id');

        $('#empCost' + id).html(cost);
    });

    $('#chooseEmp').live('change', function () {
        $('#search_Me').submit();
    });
</script>
{/literal}
<div class="row">
    <div class="container">
        <ol class="breadcrumb">
            <li><a href="#">اداره الموظفين</a></li>
            <li class="active">تقرير الموظفين </li>
        </ol>
        <div class="panel panel-default">
            <!-- Default panel contents -->
            <div class="panel-heading">
                <h3 class="panel-title">تقرير  الموظفين</h3>
                <a href="{$youtubes[173]->url}" target="_blank" class="hidden-print"><img src="../views/default/assets/img/youtube.png" class="pull-left" alt="Youtube" style="width: 2%;"></a>
            </div>
            <div class="panel-body">



                <form class="form-inline hidden-print" method="post" action="employeereport.php" id="search_Me">
                    <div class="form-group">
                        <label class="sr-only"> اسم الموظف</label>
                        <select class="select2" name="chooseEmp" id="chooseEmp">
                            <option value=""></option>
                            <option value="0">كل الموظفين</option>
                            {foreach $allemployee as $data}
                            <option value="{$data->employeeId}">{$data->employeeName}</option>
                            {/foreach}
                        </select>
                    </div>
                    <!--button type="submit" class="btn btn-primary">بحث</button-->
                </form>
                <hr/>



                <table class="table table-black">
                    <thead>
                        <tr bgcolor="">
                            <th>الرقم</th>
                            <th>اسم الموظف</th>
                            <th>السن</th>
                            <th>رقم الجوال</th>
                            <th>الراتب الاساسى</th>


                            <th >عدد دقائق التاخير </th>
                            <th>قيمة التاخير</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr>

                            {foreach $allData as $emp}
                        <tr>
                            <td>{$emp->employeeId}</td>
                            <td>{$emp->employeeName}</td>
                            <td>{$emp->employeeBOD}</td>
                            <td>{$emp->employeePhone}</td>
                            <td>{$emp->employeeSalary}</td>
                            <td>
                                <input id="emp{$emp->employeeId}" name="emp{$emp->employeeId}" class="form-control calcCost" data-minCost="{$emp->minuteLateCost}" data-id="{$emp->employeeId}" value=""/>
                            </td>
                            <td><span id="empCost{$emp->employeeId}"></span></td>
                        </tr>
                        {/foreach}
                        </tr>

                </table>

            </div></div>