示例#1
0
 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);
 }
示例#2
0
</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%">&nbsp;</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 
    }
    ?>
&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td align="right">Footer/Agency</td>
示例#3
0
    <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%">&nbsp;</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');