<?php
/* Smarty version 3.1.33, created on 2021-02-26 05:36:47
  from '/home/mycopjya/admin.mycodingassignment.com/content/themes/dashboard/users/employees.tpl' */

/* @var Smarty_Internal_Template $_smarty_tpl */
if ($_smarty_tpl->_decodeProperties($_smarty_tpl, array (
  'version' => '3.1.33',
  'unifunc' => 'content_603888ef7d1aa9_09429641',
  'has_nocache_code' => false,
  'file_dependency' => 
  array (
    '199db73937ec19fd7201fffeffb0f0d948eed570' => 
    array (
      0 => '/home/mycopjya/admin.mycodingassignment.com/content/themes/dashboard/users/employees.tpl',
      1 => 1596526785,
      2 => 'file',
    ),
  ),
  'includes' => 
  array (
  ),
),false)) {
function content_603888ef7d1aa9_09429641 (Smarty_Internal_Template $_smarty_tpl) {
$_smarty_tpl->_loadInheritance();
$_smarty_tpl->inheritance->init($_smarty_tpl, true);
?>
 

<?php 
$_smarty_tpl->inheritance->instanceBlock($_smarty_tpl, 'Block_2058973678603888ef79b9c3_67337750', 'content_wrapper');
$_smarty_tpl->inheritance->endChild($_smarty_tpl, 'dashboard/layout.tpl');
}
/* {block 'content_wrapper'} */
class Block_2058973678603888ef79b9c3_67337750 extends Smarty_Internal_Block
{
public $subBlocks = array (
  'content_wrapper' => 
  array (
    0 => 'Block_2058973678603888ef79b9c3_67337750',
  ),
);
public function callBlock(Smarty_Internal_Template $_smarty_tpl) {
$_smarty_tpl->_checkPlugins(array(0=>array('file'=>'/home/mycopjya/admin.mycodingassignment.com/vendor/smarty/smarty/libs/plugins/modifier.capitalize.php','function'=>'smarty_modifier_capitalize',),));
?>

    <div class="card">
        <div class="card-header with-icon">
            <i class="fa fa-users mr10"></i>
            
            <?php if ($_smarty_tpl->tpl_vars['sub_view']->value == "writers" || $_smarty_tpl->tpl_vars['sub_view']->value == "editors" || $_smarty_tpl->tpl_vars['sub_view']->value == "sub-admins" || $_smarty_tpl->tpl_vars['sub_view']->value == "administrators") {?>
                <div class="pull-right flip">
                    <a href="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['base_uri']->value, ENT_QUOTES, 'UTF-8');?>
/employees/add" class="btn btn-info">
                        <i class="fa fa-plus"></i> Add New Employee
                    </a>
                </div>
            <?php }?>

            <strong>Employees</strong> &rsaquo; <strong><?php echo htmlspecialchars(smarty_modifier_capitalize($_smarty_tpl->tpl_vars['sub_view']->value), ENT_QUOTES, 'UTF-8');?>
</strong>
            <?php if ($_smarty_tpl->tpl_vars['sub_view']->value == "writers" || $_smarty_tpl->tpl_vars['sub_view']->value == "editors" || $_smarty_tpl->tpl_vars['sub_view']->value == "sub-admins" || $_smarty_tpl->tpl_vars['sub_view']->value == "administrators") {?>
                &rsaquo; <strong><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['total_employees']->value, ENT_QUOTES, 'UTF-8');?>
</strong>
            <?php }?>

            <?php if ($_smarty_tpl->tpl_vars['sub_view']->value == "edit") {?>
                &rsaquo; <strong><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['id'], ENT_QUOTES, 'UTF-8');?>
</strong>
                <div class="pull-right flip">
                    <a target="_blank" href="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['base_uri']->value, ENT_QUOTES, 'UTF-8');?>
/authorize/<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['id'], ENT_QUOTES, 'UTF-8');?>
/<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['secure_key'], ENT_QUOTES, 'UTF-8');?>
" class="btn btn-warning">
                        <i class="fa fa-user"></i> Impersonate
                    </a>
                    <a href="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['base_uri']->value, ENT_QUOTES, 'UTF-8');?>
/orders/employee/<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['id'], ENT_QUOTES, 'UTF-8');?>
" class="btn btn-info">
                        <i class="fa fa-shopping-basket"></i> View Orders
                    </a>
                </div>
            <?php }?>
        </div>

        <?php if ($_smarty_tpl->tpl_vars['sub_view']->value == "writers" || $_smarty_tpl->tpl_vars['sub_view']->value == "editors" || $_smarty_tpl->tpl_vars['sub_view']->value == "sub-admins" || $_smarty_tpl->tpl_vars['sub_view']->value == "administrators") {?>

            <div class="card-body">
                <div class="mb20"> 
                    <form class="form-inline" method="get" id="filter_form" autocomplete="off"> 
                        <div class="form-group mb0"> 
                        <div class="input-group"> 
                            <input type="text" class="form-control" name="query" value="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['query']->value, ENT_QUOTES, 'UTF-8');?>
"> 
                            <div class="input-group-append"> 
                                <button type="submit" class="btn btn-sm btn-info">
                                    <i class="fas fa-search mr5"></i>Search</button> 
                                </div> 
                            </div> 
                        </div> 
                    </form> 
                    <div class="form-text small">
                        Search employee ID, name or email
                    </div> 
                </div>

                <?php if (count($_smarty_tpl->tpl_vars['employees']->value)) {?>
                    <div class="table-responsive">
                        <table class="table <?php if ($_smarty_tpl->tpl_vars['theme_mode_night']->value) {?>table-dark<?php }?> table-striped table-bordered table-hover js_dataTable">
                            <thead>
                                <tr>
                                    <td>ID</td>
                                    <td>Name</td>
                                    <td>Email</td>
                                    <td>Started</td>
                                    <?php if ($_smarty_tpl->tpl_vars['sub_view']->value == "writers" || $_smarty_tpl->tpl_vars['sub_view']->value == "editors") {?>
                                        <td>Total Earned</td>
                                    <?php }?>
                                    <td>Actions</td>
                                </tr>
                            </thead>
                            <tbody>
                                <?php
$_from = $_smarty_tpl->smarty->ext->_foreach->init($_smarty_tpl, $_smarty_tpl->tpl_vars['employees']->value, 'employee');
if ($_from !== null) {
foreach ($_from as $_smarty_tpl->tpl_vars['employee']->value) {
?>
                                    <tr>
                                        <td>
                                            <a href="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['base_uri']->value, ENT_QUOTES, 'UTF-8');?>
/employees/edit/<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['id'], ENT_QUOTES, 'UTF-8');?>
">#<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['id'], ENT_QUOTES, 'UTF-8');?>
</a>
                                        </td>
                                        <td><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['first_name'], ENT_QUOTES, 'UTF-8');?>
 <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['last_name'], ENT_QUOTES, 'UTF-8');?>
</td>
                                        <td><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['email'], ENT_QUOTES, 'UTF-8');?>
</td>
                                        <td>
                                            <?php if ($_smarty_tpl->tpl_vars['employee']->value['is_started']) {?>
                                                <span class="label label-success">Yes</span>
                                            <?php } else { ?>
                                                <span class="label label-danger">No</span>
                                            <?php }?>
                                        </td>
                                        <?php if ($_smarty_tpl->tpl_vars['sub_view']->value == "writers" || $_smarty_tpl->tpl_vars['sub_view']->value == "editors") {?>
                                            <td><?php echo htmlspecialchars(formatPrice($_smarty_tpl->tpl_vars['employee']->value['total_paid']), ENT_QUOTES, 'UTF-8');?>
</td>
                                        <?php }?>
                                        <td>
                                            <button data-toggle="tooltip" data-placement="top" title="Delete" class="btn btn-xs btn-danger js_admin-deleter" data-handle="employee" data-id="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['id'], ENT_QUOTES, 'UTF-8');?>
">
                                                <i class="fa fa-trash-alt"></i>
                                            </button>
                                            <a data-toggle="tooltip" data-placement="top" title="Edit" href="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['base_uri']->value, ENT_QUOTES, 'UTF-8');?>
/employees/edit/<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['id'], ENT_QUOTES, 'UTF-8');?>
" class="btn btn-xs btn-info">
                                                <i class="fa fa-pencil-alt"></i>
                                            </a>
                                        </td>
                                    </tr>
                                <?php
}
}
$_smarty_tpl->smarty->ext->_foreach->restore($_smarty_tpl, 1);?>
                            </tbody>
                        </table>

                        <?php echo $_smarty_tpl->tpl_vars['pager']->value;?>

                    </div>
                <?php } else { ?>
                    <div class="text-center x-muted"> <i class="fa fa-users fa-4x"></i>
                        <p class="mb10"><strong>No employees to show</strong></p>
                    </div>
                <?php }?>
            </div>
        
        <?php } elseif ($_smarty_tpl->tpl_vars['sub_view']->value == "add") {?>

            <form class="js_ajax-forms" method="POST" data-url="/employees/add" autocomplete="off">
                <div class="card-body">
                    <div class="form-group form-row">
                        <label class="col-sm-3 control-label">Employee Group</label>
                        <div class="col-sm-9">
                            <select class="form-control" name="employee_group">
                                <option value="3">Writer</option>
                                <option value="2">Editor</option>
                                <option value="4">Sub Admin</option>
                                <option value="1">Administrator</option>
                            </select>
                        </div>
                    </div>

                    <div class="form-group form-row">
                        <label class="col-sm-3 control-label">First name</label>
                        <div class="col-sm-9">
                            <input type="text" class="form-control" name="first_name">
                        </div>
                    </div>

                    <div class="form-group form-row">
                        <label class="col-sm-3 control-label">Last name</label>
                        <div class="col-sm-9">
                            <input type="text" class="form-control" name="last_name">
                        </div>
                    </div>

                    <div class="form-group form-row">
                        <label class="col-sm-3 control-label">Email Address</label>
                        <div class="col-sm-9">
                            <input type="email" class="form-control" name="email"> 
                        </div>
                    </div>

                    <div class="form-group form-row">
                        <label class="col-sm-3 control-label">Gender</label>
                        <div class="col-sm-9">
                            <div class="radio radio-primary"> 
                                <input type="radio" name="gender" value="male" id="gender_male"> 
                                <label for="gender_male">Male</label> 
                            </div>
                            <div class="radio radio-primary"> 
                                <input type="radio" name="gender" value="female" id="gender_female"> 
                                <label for="gender_female">Female</label> 
                            </div>
                        </div>
                    </div>

                    <div class="form-group form-row">
                        <label class="col-sm-3 control-label">Password</label>
                        <div class="col-sm-9">
                            <input type="text" class="form-control" name="password" autocomplete="off"> 
                        </div>
                    </div>

                    <div class="form-group form-row">
                        <div class="col-sm-9 offset-sm-3">
                            <!-- success -->
                            <div class="alert alert-success mt10 x-hidden" role="alert"></div>
                            <!-- success -->

                            <!-- error -->
                            <div class="alert alert-danger mt10 x-hidden" role="alert"></div>
                            <!-- error -->
                        </div>
                    </div>
                </div>
                <div class="card-footer clearfix">
                    <button type="submit" class="btn btn-success pull-right">Add new Employee</button>
                </div>
            </form>

        <?php } elseif ($_smarty_tpl->tpl_vars['sub_view']->value == "edit") {?>
            
            <div class="card-body">
                <div class="row">
                    <div class="col-xs-offset-3 col-xs-6 col-sm-offset-0 col-sm-2 mb10">
                        <img class="img-responsive img-thumbnail" src="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['user_picture'], ENT_QUOTES, 'UTF-8');?>
">
                    </div>
                    <div class="col-xs-12 col-sm-5 mb100">
                        <ul class="list-group">
                            <li class="list-group-item"> 
                                <span class="badge badge-primary"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['id'], ENT_QUOTES, 'UTF-8');?>
</span> <?php if ($_smarty_tpl->tpl_vars['employee']->value['is_admin']) {?>Administrator <?php } elseif ($_smarty_tpl->tpl_vars['employee']->value['is_editor']) {?>Editor <?php } elseif ($_smarty_tpl->tpl_vars['employee']->value['is_writer']) {?>Writer <?php }?> ID
                            </li>
                            <li class="list-group-item"> 
                                <span class="badge badge-primary"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['employee_status_title'], ENT_QUOTES, 'UTF-8');?>
</span> Status
                            </li>
                            <li class="list-group-item"> 
                                <span class="badge badge-primary js_moment" data-time="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['reg_date'], ENT_QUOTES, 'UTF-8');?>
"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['reg_date'], ENT_QUOTES, 'UTF-8');?>
</span> Joined
                            </li>
                            <li class="list-group-item"> 
                                <span class="badge badge-primary js_moment" data-time="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['last_activity'], ENT_QUOTES, 'UTF-8');?>
"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['last_activity'], ENT_QUOTES, 'UTF-8');?>
</span> Last Activity
                            </li>
                            <li class="list-group-item"> 
                                <span class="badge badge-primary js_moment" data-time="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['last_login'], ENT_QUOTES, 'UTF-8');?>
"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['last_login'], ENT_QUOTES, 'UTF-8');?>
</span> Last Login
                            </li>
                            <li class="list-group-item"> 
                                <span class="badge badge-primary"><?php if ($_smarty_tpl->tpl_vars['employee']->value['is_started']) {?>Yes<?php } else { ?>No<?php }?></span> Started
                            </li>
                            <li class="list-group-item"> 
                                <span class="badge badge-primary"><?php echo htmlspecialchars(formatPrice($_smarty_tpl->tpl_vars['outstanding_payment']->value), ENT_QUOTES, 'UTF-8');?>
</span> Outstanding Payment
                            </li>
                            <li class="list-group-item"> 
                                <span class="badge badge-primary"><?php echo htmlspecialchars(formatPrice($_smarty_tpl->tpl_vars['employee']->value['last_pay']), ENT_QUOTES, 'UTF-8');?>
</span> Last Pay
                            </li>
                            <li class="list-group-item"> 
                                <span class="badge badge-primary"><?php echo htmlspecialchars(formatPrice($_smarty_tpl->tpl_vars['employee']->value['total_paid']), ENT_QUOTES, 'UTF-8');?>
</span> Total Earned
                            </li>
                        </ul>
                    </div>

                    <?php if (!$_smarty_tpl->tpl_vars['employee']->value['is_admin'] && !$_smarty_tpl->tpl_vars['employee']->value['is_sub_admin']) {?>
                        <div class="col-xs-12 col-sm-5 mb10">
                            <ul class="list-group">
                                <li class="list-group-item"> 
                                    <span class="badge badge-primary"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['order_stats']['bids'], ENT_QUOTES, 'UTF-8');?>
</span> <a class="text-link" href="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['base_uri']->value, ENT_QUOTES, 'UTF-8');?>
/orders/employee/<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['id'], ENT_QUOTES, 'UTF-8');?>
?search&status_id=7">Bids</a>
                                </li>
                                <li class="list-group-item"> 
                                    <span class="badge badge-primary"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['order_stats']['progress'], ENT_QUOTES, 'UTF-8');?>
</span> <a href="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['base_uri']->value, ENT_QUOTES, 'UTF-8');?>
/orders/employee/<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['id'], ENT_QUOTES, 'UTF-8');?>
?search&status_id=6">In Progress</a> 
                                </li>
                                <li class="list-group-item"> 
                                    <span class="badge badge-primary"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['order_stats']['done'], ENT_QUOTES, 'UTF-8');?>
</span> <a href="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['base_uri']->value, ENT_QUOTES, 'UTF-8');?>
/orders/employee/<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['id'], ENT_QUOTES, 'UTF-8');?>
?search&status_id=8">Done</a> 
                                </li>
                                <li class="list-group-item"> 
                                    <span class="badge badge-primary"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['order_stats']['delivered'], ENT_QUOTES, 'UTF-8');?>
</span> <a href="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['base_uri']->value, ENT_QUOTES, 'UTF-8');?>
/orders/employee/<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['id'], ENT_QUOTES, 'UTF-8');?>
?search&status_id=11">Delivered</a> 
                                </li>
                                <li class="list-group-item"> 
                                    <span class="badge badge-primary"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['order_stats']['revision'], ENT_QUOTES, 'UTF-8');?>
</span> <a href="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['base_uri']->value, ENT_QUOTES, 'UTF-8');?>
/orders/employee/<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['id'], ENT_QUOTES, 'UTF-8');?>
?search&status_id=14">Revision</a> 
                                </li>
                                <li class="list-group-item"> 
                                    <span class="badge badge-primary"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['order_stats']['finished'], ENT_QUOTES, 'UTF-8');?>
</span> <a href="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['base_uri']->value, ENT_QUOTES, 'UTF-8');?>
/orders/employee/<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['id'], ENT_QUOTES, 'UTF-8');?>
?search&status_id=10">Finished</a> 
                                </li>
                                <li class="list-group-item"> 
                                    <span class="badge badge-primary"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['order_stats']['dispute'], ENT_QUOTES, 'UTF-8');?>
</span> <a href="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['base_uri']->value, ENT_QUOTES, 'UTF-8');?>
/orders/employee/<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['id'], ENT_QUOTES, 'UTF-8');?>
?search&status_id=1">Disputes</a> 
                                </li>
                                <li class="list-group-item"> 
                                    <span class="badge badge-primary"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['total_orders_revised'], ENT_QUOTES, 'UTF-8');?>
</span> Total Orders Revised
                                </li>
                                <li class="list-group-item"> 
                                    <span class="badge badge-primary"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['total_orders_rejected'], ENT_QUOTES, 'UTF-8');?>
</span> Total Orders Disputed
                                </li>
                            </ul>
                        </div>
                    <?php }?>
                </div>
 
                <ul class="nav nav-tabs mb20"> 
                    <li class="nav-item"> 
                        <a class="nav-link active" href="#account" data-toggle="tab"> 
                            <i class="fa fa-cogs fa-fw mr5"></i><strong class="pr5">Account</strong> 
                        </a> 
                    </li>
                    <li class="nav-item"> 
                        <a class="nav-link" href="#profile" data-toggle="tab"> 
                            <i class="fa fa-user fa-fw mr5"></i><strong class="pr5">Profile</strong> 
                        </a> 
                    </li>
                </ul>

                <div class="tab-content">

                    <div class="tab-pane active" id="account">
                        <div class="row">
                            <div class="col-md-8">
                                <form class="js_ajax-forms" method="POST" data-url="/employees/edit?edit=account" autocomplete="off">
                                    <input type="hidden" name="employee_id" value="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['id'], ENT_QUOTES, 'UTF-8');?>
"/>

                                    <div class="form-group form-row">
                                        <label class="col-sm-3 control-label">Started</label>
                                        <div class="col-sm-9">
                                            <label class="switch" for="started">
                                                <input type="checkbox" name="started" id="started" <?php if ($_smarty_tpl->tpl_vars['employee']->value['is_started'] == '1') {?>checked="checked"<?php }?>>
                                                <span class="slider round"></span>
                                            </label>
                                            <span class="help-block">Employee can view and access orders</span>
                                        </div>
                                    </div>

                                    <div class="form-group form-row">
                                        <label class="col-sm-3 control-label">Banned</label>
                                        <div class="col-sm-9">
                                            <label class="switch" for="banned">
                                                <input type="checkbox" name="banned" id="banned" <?php if ($_smarty_tpl->tpl_vars['employee']->value['is_banned'] == '1') {?>checked="checked"<?php }?>>
                                                <span class="slider round"></span>
                                            </label>
                                        </div>
                                    </div>

                                    <div class="form-group form-row">
                                        <label class="col-sm-3 control-label">Email Notifications</label>
                                        <div class="col-sm-9">
                                            <label class="switch" for="email_notifications">
                                                <input type="checkbox" name="email_notifications" id="email_notifications" <?php if ($_smarty_tpl->tpl_vars['employee']->value['email_notifications'] == '1') {?>checked="checked"<?php }?>>
                                                <span class="slider round"></span>
                                            </label>
                                        </div>
                                    </div>

                                    <div class="form-group form-row">
                                        <label class="col-sm-3 control-label">Employee Group</label>
                                        <div class="col-sm-9">
                                            <select class="form-control" name="employee_group">
                                                <option value="1" <?php if ($_smarty_tpl->tpl_vars['employee']->value['employee_group'] == "1") {?>selected="selected"<?php }?>>Administrator</option>
                                                <option value="4" <?php if ($_smarty_tpl->tpl_vars['employee']->value['employee_group'] == "4") {?>selected="selected"<?php }?>>Sub Admin</option>
                                                <option value="2" <?php if ($_smarty_tpl->tpl_vars['employee']->value['employee_group'] == "2") {?>selected="selected"<?php }?>>Editor</option>
                                                <option value="3" <?php if ($_smarty_tpl->tpl_vars['employee']->value['employee_group'] == "3") {?>selected="selected"<?php }?>>Writer</option>
                                            </select>
                                        </div>
                                    </div>

                                    <?php if ($_smarty_tpl->tpl_vars['employee']->value['is_editor'] || $_smarty_tpl->tpl_vars['employee']->value['is_writer']) {?>
                                        <div class="form-group form-row">
                                            <label class="col-sm-3 control-label">Status</label>
                                            <div class="col-sm-9">
                                                <select class="form-control" name="employee_status">
                                                    <option value="2" <?php if ($_smarty_tpl->tpl_vars['employee']->value['employee_status'] == "2") {?>selected="selected"<?php }?>>Looking for orders</option>
                                                    <option value="4" <?php if ($_smarty_tpl->tpl_vars['employee']->value['employee_status'] == "4") {?>selected="selected"<?php }?>>Cannot work for now</option>
                                                    <option value="5" <?php if ($_smarty_tpl->tpl_vars['employee']->value['employee_status'] == "5") {?>selected="selected"<?php }?>>Do not use your service</option>
                                                </select>
                                            </div>
                                        </div>

                                        <div class="form-group form-row">
                                            <label class="col-sm-3 control-label">Writer Category</label>
                                            <div class="col-sm-9">
                                                <select class="form-control" name="writer_category">
                                                    <option value="2" <?php if ($_smarty_tpl->tpl_vars['employee']->value['writer_category'] == "2") {?>selected="selected"<?php }?>>Best Available</option>
                                                    <option value="3" <?php if ($_smarty_tpl->tpl_vars['employee']->value['writer_category'] == "3") {?>selected="selected"<?php }?>>ESL (English Second Language)</option>
                                                    <option value="4" <?php if ($_smarty_tpl->tpl_vars['employee']->value['writer_category'] == "4") {?>selected="selected"<?php }?>>ENL (English Native Language)</option>
                                                </select>
                                            </div> 
                                        </div>

                                        <div class="form-group form-row">
                                            <label class="col-sm-3 control-label">Academic Level</label>
                                            <div class="col-sm-9">
                                                <select class="form-control" name="academic_level">
                                                    <option value="1" <?php if ($_smarty_tpl->tpl_vars['employee']->value['academic_level'] == "1") {?>selected="selected"<?php }?>>High school</option>
                                                    <option value="2" <?php if ($_smarty_tpl->tpl_vars['employee']->value['academic_level'] == "2") {?>selected="selected"<?php }?>>Undergrad. (yrs 1-2)</option>
                                                    <option value="3" <?php if ($_smarty_tpl->tpl_vars['employee']->value['academic_level'] == "3") {?>selected="selected"<?php }?>>Undergrad. (yrs 3-4)</option>
                                                    <option value="4" <?php if ($_smarty_tpl->tpl_vars['employee']->value['academic_level'] == "4") {?>selected="selected"<?php }?>>Master's</option>
                                                    <option value="5" <?php if ($_smarty_tpl->tpl_vars['employee']->value['academic_level'] == "5") {?>selected="selected"<?php }?>>Ph.D.</option>
                                                </select>
                                            </div> 
                                        </div>
                                    <?php }?>

                                    <div class="form-group form-row">
                                        <label class="col-sm-3 control-label">Email Address</label>
                                        <div class="col-sm-9">
                                            <input type="email" class="form-control" name="email" value="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['email'], ENT_QUOTES, 'UTF-8');?>
"> 
                                        </div>
                                    </div>

                                    <?php if ($_smarty_tpl->tpl_vars['employee']->value['is_editor'] || $_smarty_tpl->tpl_vars['employee']->value['is_writer']) {?>
                                        <div class="form-group form-row">
                                            <label class="col-sm-3 control-label text-left">CPP Type</label>
                                            <div class="col-sm-9">
                                                <select class="form-control" name="cpp_type" data-combo="cpp_type">
                                                    <option value="system" <?php if ($_smarty_tpl->tpl_vars['employee']->value['cpp_type'] == 'system') {?>selected=""<?php }?>>System CPP</option>
                                                    <option value="custom" <?php if ($_smarty_tpl->tpl_vars['employee']->value['cpp_type'] == 'custom') {?>selected=""<?php }?>>Custom CPP</option>
                                                </select>
                                            </div>
                                        </div>

                                        <div id="cpp_type">
                                            <div class="switch-combo <?php if ($_smarty_tpl->tpl_vars['employee']->value['cpp_type'] == 'system') {?>x-hidden<?php }?>" data-combo-value="custom">
                                                <div class="form-group form-row">
                                                    <label class="col-sm-3 control-label text-left">Cost per page</label>
                                                    <div class="col-sm-4">
                                                        <div class="input-group">
                                                            <div class="input-group-prepend"> 
                                                                <span class="input-group-text d-none d-sm-block">$</span> 
                                                            </div>
                                                            <input name="cpp_amount" type="text" class="form-control force-integer" value="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['cpp_amount'], ENT_QUOTES, 'UTF-8');?>
">
                                                        </div>
                                                        <span class="help-block">
                                                            The amount <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['first_name'], ENT_QUOTES, 'UTF-8');?>
 will earn per page
                                                        </span>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    <?php }?>

                                    <div class="form-group form-row">
                                        <label class="col-sm-3 control-label">Password</label>
                                        <div class="col-sm-9">
                                            <input type="text" class="form-control" name="password" autocomplete="off"> 
                                        </div>
                                    </div>

                                    <div class="form-group form-row">
                                        <div class="col-sm-9 offset-sm-3">
                                            <!-- success -->
                                            <div class="alert alert-success mt10 x-hidden" role="alert"></div>
                                            <!-- success -->

                                            <!-- error -->
                                            <div class="alert alert-danger mt10 x-hidden" role="alert"></div>
                                            <!-- error -->

                                            <button type="submit" class="btn btn-success">Save Changes</button>
                                            <button type="button" class="btn btn-info js_reset-password-link" data-id="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['id'], ENT_QUOTES, 'UTF-8');?>
" data-handle="employee">Password reset link</button>
                                        </div>
                                    </div>
                                </form>
                            </div>
                        </div>
                    </div>

                    <div class="tab-pane" id="profile">
                        <div class="row">
                            <div class="col-md-8">
                                <form class="js_ajax-forms" method="POST" data-url="/employees/edit?edit=profile" autocomplete="off">
                                    <input type="hidden" name="employee_id" value="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['id'], ENT_QUOTES, 'UTF-8');?>
"/>
                                    <div class="form-group form-row">
                                        <label class="col-sm-3 control-label">First name</label>
                                        <div class="col-sm-9">
                                            <input type="text" class="form-control" name="first_name" value="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['first_name'], ENT_QUOTES, 'UTF-8');?>
">
                                        </div>
                                    </div>

                                    <div class="form-group form-row">
                                        <label class="col-sm-3 control-label">Middle name</label>
                                        <div class="col-sm-9">
                                            <input type="text" class="form-control" name="middle_name" value="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['middle_name'], ENT_QUOTES, 'UTF-8');?>
">
                                        </div>
                                    </div>

                                    <div class="form-group form-row">
                                        <label class="col-sm-3 control-label">Last name</label>
                                        <div class="col-sm-9">
                                            <input type="text" class="form-control" name="last_name" value="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['last_name'], ENT_QUOTES, 'UTF-8');?>
">
                                        </div>
                                    </div>

                                    <div class="form-group form-row">
                                        <label class="col-sm-3 control-label">Gender</label>
                                        <div class="col-sm-9">
                                            <div class="radio radio-primary"> 
                                                <input type="radio" name="gender" value="male" id="gender_male" <?php if ($_smarty_tpl->tpl_vars['employee']->value['gender'] == 'male') {?>checked="checked"<?php }?>> 
                                                <label for="gender_male">Male</label> 
                                            </div>
                                            <div class="radio radio-primary"> 
                                                <input type="radio" name="gender" value="female" id="gender_female" <?php if ($_smarty_tpl->tpl_vars['employee']->value['gender'] == 'female') {?>checked="checked"<?php }?>> 
                                                <label for="gender_female">Female</label> 
                                            </div>
                                        </div>
                                    </div>

                                    <div class="form-group form-row">
                                        <label class="col-sm-3 control-label">Phone</label>
                                        <div class="col-sm-9">
                                            <input type="text" class="form-control" name="phone" <?php if ($_smarty_tpl->tpl_vars['employee']->value['phone']) {?>value="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['employee']->value['phone'], ENT_QUOTES, 'UTF-8');?>
"<?php }?>>
                                        </div>
                                    </div>

                                    <div class="form-group form-row">
                                        <div class="col-sm-9 offset-sm-3">
                                            <!-- success -->
                                            <div class="alert alert-success mt10 x-hidden" role="alert"></div>
                                            <!-- success -->

                                            <!-- error -->
                                            <div class="alert alert-danger mt10 x-hidden" role="alert"></div>
                                            <!-- error -->

                                            <button type="submit" class="btn btn-success">Save Changes</button>
                                        </div>
                                    </div>
                                </form>
                            </div>
                        </div>
                    </div>

                    <div class="tab-pane" id="samples">
                       
                    </div>
                </div>
               
            </div>
            
        <?php }?>
    </div>
<?php
}
}
/* {/block 'content_wrapper'} */
}
