function print_user_access() { if ($this->ci->input->is_ajax_request()) { return; } return; $u = new User_m(); $u->get_by_username($this->ci->session->userdata('username')); $u->get(); $p = new Permission_m(); $permissions = $p->get_by_group_id($u->group_id); foreach ($this->permissions as $permission) { echo '<br>' . $permission->module; $methods = json_decode($permission->roles); $i = 0; if (is_array($methods)) { foreach ($methods as $method) { if ($i == 0) { echo '<br>----'; $i++; } echo $method . ', '; } } //print_r($methods); } //print_r( $this->user_access); }
</script> <div id="general" class="settings_tab"> <form action="" method="post"> <table width="100%" border="0" cellpadding="5" cellspacing="5" class="type-one"> <tr class="type-one-header"> <th width="21%">General</th> <th width="72%"> </th> <th width="7%"><input name="active_tabs" type="hidden" id="active_tabs" value="general" /></th> </tr> <tr> <td><input name="op" type="hidden" id="op" value="1" /></td> <td> <?php $u = new User_m(); $u->get_by_username(Session::get('username')); ?> <?php if ($u->group_id == '1000') { ?> <?php echo ' LGU Code: ' . form_input('lgu_code', $settings['lgu_code']); ?> <?php } ?> </td> <td> </td> </tr> <tr> <td align="right">Footer/Agency</td>
<th width="11%"><strong>Activity</strong></th> <th width="16%"><strong>Details</strong></th> <th width="16%"><strong>Employee Affected </strong></th> <th width="13%"><strong>Date</strong></th> <th width="15%"> </th> </tr> <?php $u = new User_m(); foreach ($logs as $log) { $id = $log['id']; $username = $log['username']; $employee_affected = $log['employee_id_affected']; $command = $log['command']; $details = $log['details']; $date = $log['date']; $u->get_by_username($username); $this->Employee->fields = array('lname', 'fname'); $lname = ''; $fname = ''; $employee_info = $this->Employee->get_employee_info($employee_affected); if (!empty($employee_info)) { $lname = $employee_info['lname']; $fname = $employee_info['fname']; } $bg = $this->Helps->set_line_colors(); ?> <tr bgcolor="<?php echo $bg; ?> " onmouseover="this.bgColor = '<?php echo $this->config->item('mouseover_linecolor');