$del_checkbox = $delete_permission ? '<input type="checkbox">' : '';
$table = array();
$table['head'] = array($del_checkbox, 'Admin Name', 'Role', 'Display Name', 'Status');
$table['body'] = isset($body) ? $body : '';
$table['td_attr'] = isset($td_attr) ? $td_attr : '';
$table['th_attr'] = array('class="check-column"');
$table['table_attr'] = array('class' => 'widefat');
$table['table'] = 'hrm_job_title_option';
$table['action'] = 'hrm_user_delete';
$table['table_attr'] = array('class' => 'widefat');
$table['tab'] = $tab;
$table['subtab'] = $subtab;
echo Hrm_settings::getInstance()->table($table);
$file_path = urlencode(__FILE__);
//pagination
echo Hrm_settings::getInstance()->pagination($total, $limit, $pagenum);
?>

<div id="hrm-create-user-wrap" title="<?php 
_e('Create a new user', 'hrm');
?>
">
    <div class="hrm-create-user-form-wrap">

        <div class="hrm-error"></div>

        <form action="" class="hrm-user-create-form">
            <?php 
wp_nonce_field('hrm_nonce', '_wpnonce');
?>
            <div class="hrm-field-wrap">
<div class="hrm-update-notification"></div>
<!-- default instance $instance = hrm_Admin::getInstance(); -->
<?php 
if (!hrm_user_can_access($tab, $subtab, 'view')) {
    printf('<h1>%s</h1>', __('You do no have permission to access this page', 'cpm'));
    return;
}
$country = Hrm_Settings::getInstance()->country_list();
$search['name'] = array('label' => __('Name', 'hrm'), 'type' => 'text', 'value' => isset($_POST['name']) ? $_POST['name'] : '', 'desc' => __('Location search by name', 'hrm'));
$search['city'] = array('label' => __('City', 'hrm'), 'type' => 'text', 'value' => isset($_POST['city']) ? $_POST['city'] : '', 'desc' => __('Location search by city', 'hrm'));
$search['country'] = array('label' => __('Country', 'hrm'), 'type' => 'select', 'option' => $country, 'selected' => isset($_GET['country']) ? $_GET['country'] : '', 'desc' => __('Location search by country', 'hrm'));
$search['phone'] = array('label' => __('Phone Number', 'hrm'), 'type' => 'text', 'value' => isset($_POST['phone']) ? $_POST['phone'] : '', 'desc' => __('Location search by phone number', 'hrm'));
$search['table_option'] = 'hrm_location_option';
$search['action'] = 'hrm_search';
$search['type'] = array('type' => 'hidden', 'value' => '_search');
echo Hrm_settings::getInstance()->get_serarch_form($search, __('Location', 'hrm'));
$pagenum = hrm_pagenum();
$limit = hrm_result_limit();
if (isset($_POST['type']) && $_POST['type'] == '_search') {
    $post = $_POST;
    $results = Hrm_Settings::getInstance()->search_query($post, $limit, $pagenum);
    $search_satus = true;
} else {
    $results = Hrm_Settings::getInstance()->hrm_query('hrm_location', $limit, $pagenum);
    $search_satus = false;
}
if (isset($results['total_row'])) {
    $total = $results['total_row'];
    unset($results['total_row']);
} else {
    $total = 0;