Ignore:
Timestamp:
Jan 19, 2015 2:01:13 PM (10 years ago)
Author:
namnd
Message:
 
File:
1 edited

Legend:

Unmodified
Added
Removed
  • pro-violet-viettel/sourcecode/application/modules/frontend/models/user_model.php

    r698 r700  
    414414                $this->db->where ( 'us_id', $us_id );
    415415                return $this->db->update ( 'tbluser', $data );
     416                //write_file('./log/test.log', $this->db->update('tbluser', $data), FOPEN_WRITE_CREATE);
    416417        }
    417418       
     
    572573                return $result['total'];
    573574        }
     575       
     576        public function getUserById($us_id) {
     577                $this->db->query ( 'UNLOCK TABLES' );
     578                $this->db->select ( '*' )->from ( 'tbluser' )->where ( 'tbluser.us_id', $us_id );
     579                $query = $this->db->get ();
     580                if ($query->num_rows () > 0) {
     581                        $row = $query->row_array ();
     582                        return $row;
     583                }
     584        }
    574585}
Note: See TracChangeset for help on using the changeset viewer.