Changeset 375
- Timestamp:
- Nov 3, 2014 12:25:15 PM (11 years ago)
- Location:
- pro-violet-viettel/sourcecode
- Files:
-
- 9 added
- 3 deleted
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
pro-violet-viettel/sourcecode/application/config/routes.php
r360 r375 49 49 $route['admin/cong_tac_vien/trang/:any'] = 'admin/collaborator/getCollaborators/$1'; 50 50 $route['admin/cong_tac_vien/test'] = 'admin/collaborator/test'; 51 52 $route['admin/quan_tri_vien'] = 'admin/admin_acc'; 53 $route['admin/quan_tri_vien/trang'] = 'admin/admin_acc/get_admins/1'; 54 $route['admin/quan_tri_vien/trang/:any'] = 'admin/admin_acc/get_admins/$1'; 55 $route['admin/quan_tri_vien/them'] = 'admin/admin_acc/add_admin'; 56 $route['admin/quan_tri_vien/sua/:any'] = 'admin/admin_acc/edit_admin/$1'; 57 $route['admin/quan_tri_vien/xoa/:any'] = 'admin/admin_acc/delete_admin/$1'; 58 $route['admin/quan_tri_vien/id/:any'] = 'admin/admin_acc/get_admin_by_id/$1'; 59 60 $route['admin/nguoi_dung'] = 'admin/user'; 61 $route['admin/nguoi_dung/trang'] = 'admin/user/get_users/1'; 62 $route['admin/nguoi_dung/trang/:any'] = 'admin/user/get_users/$1'; 51 63 /* End of file routes.php */ 52 64 /* Location: ./application/config/routes.php */ -
pro-violet-viettel/sourcecode/application/core/MY_Model.php
r337 r375 30 30 { 31 31 $this->db->select('*')->from($this->table_name)->where($this->id_name, $id); 32 $query = $this-> get();32 $query = $this->db->get(); 33 33 if($query->num_rows() > 0) 34 34 { 35 35 $row = $query->row_array(); 36 return $row s;36 return $row; 37 37 } 38 38 } … … 43 43 return $query->result(); 44 44 } 45 46 function check_exist($data) 47 { 48 $sql="SELECT COUNT(".$this->id_name.") as total FROM ".$this->table_name." WHERE ".$data['field']." = '".$data['value']."' LIMIT 1"; 49 if ($this->db->query($sql)->row_array()['total']==1) 50 { 51 return true; 52 } 53 else 54 { 55 return false; 56 } 57 } 45 58 } -
pro-violet-viettel/sourcecode/application/modules/admin/models/admin_model.php
r369 r375 31 31 return $query->num_rows(); 32 32 } 33 34 function get_list_admins($data) 35 { 36 $sql="SELECT * FROM ".$this->table_name; 37 $data['keyword']=''; 38 if ($data['keyword']) 39 { 40 $sql.=" WHERE (login_name LIKE '%".$data['keyword']."%' OR full_name LIKE '%".$data['keyword']."%') "; 41 } 42 return $this->db->query($sql." ORDER BY admin_id DESC LIMIT ".$data['start'].", ".$data['perpage']." ")->result_array(); 43 } 44 45 function get_total_admins($data) 46 { 47 $sql="SELECT COUNT(".$this->id_name.") AS total FROM ".$this->table_name; 48 if (isset($data['keyword'])) 49 { 50 $sql.=" WHERE (login_name LIKE '%".$data['keyword']."%' OR full_name LIKE '%".$data['keyword']."%') "; 51 } 52 return $this->db->query($sql)->row_array()['total']; 53 } 33 54 } -
pro-violet-viettel/sourcecode/application/modules/admin/models/user_model.php
r369 r375 18 18 return $query->num_rows(); 19 19 } 20 21 function get_list_users($data) 22 { 23 $sql="SELECT * FROM ".$this->table_name; 24 $data['keyword']=''; 25 if ($data['keyword']) 26 { 27 $sql.=" WHERE (cellphone LIKE '%".$data['keyword']."%' OR collaborator LIKE '%".$data['keyword']."%' OR acc_balanced LIKE '%".$data['keyword']."%') "; 28 } 29 return $this->db->query($sql." ORDER BY us_id DESC LIMIT ".$data['start'].", ".$data['perpage']." ")->result_array(); 30 } 20 31 32 function get_total_users($data) 33 { 34 $sql="SELECT COUNT(".$this->id_name.") AS total FROM ".$this->table_name; 35 if (isset($data['keyword'])) 36 { 37 $sql.=" WHERE (cellphone LIKE '%".$data['keyword']."%' OR collaborator LIKE '%".$data['keyword']."%' OR acc_balanced LIKE '%".$data['keyword']."%') "; 38 } 39 return $this->db->query($sql)->row_array()['total']; 40 } 21 41 } -
pro-violet-viettel/sourcecode/application/modules/admin/views/collaborator/index.php
r371 r375 175 175 176 176 <div class="space-4"></div> 177 <div class="form-group errors" id="add_user"> 177 <div class="form-group errors" id="add_user"></div> 178 178 179 179 </div> -
pro-violet-viettel/sourcecode/application/modules/admin/views/index.php
r345 r375 183 183 </div><!-- /.main-container --> 184 184 <?php 185 $this->load->view('layout/admin/footer', array('base_url' => $base_url, 'adminjs' => array('a dmin/collaborator.js',)));185 $this->load->view('layout/admin/footer', array('base_url' => $base_url, 'adminjs' => array('assets/js/admin/collaborator.js',))); 186 186 ?> -
pro-violet-viettel/sourcecode/application/modules/frontend/views/lecture_editor.php
r323 r375 10 10 11 11 <div class="main-container-inner"> 12 13 <?php 14 $this->load->view('layout/frontend/sidebar'); 15 ?> 12 16 13 <div class="main-content"> 17 14 -
pro-violet-viettel/sourcecode/application/views/layout/admin/sidebar.php
r367 r375 46 46 <ul class="submenu"> 47 47 <li> 48 <a href="<?php echo $base_url; ?>admin/ admin_account">48 <a href="<?php echo $base_url; ?>admin/quan_tri_vien"> 49 49 <i class="icon-double-angle-right"></i> 50 50 Quản trá» viên … … 60 60 61 61 <ul class="submenu"> 62 <li> <a href="<?php echo $base_url; ?>admin/ user_account"> KÃch hoạt/ Tạm ngưng </a> </li>63 <li> <a href="<?php echo $base_url; ?>admin/ user_account"> Thá»ng kê tà i khoản </a> </li>62 <li> <a href="<?php echo $base_url; ?>admin/nguoi_dung"> KÃch hoạt/ Tạm ngưng </a> </li> 63 <li> <a href="<?php echo $base_url; ?>admin/nguoi_dung"> Thá»ng kê tà i khoản </a> </li> 64 64 </ul> 65 65 </li> -
pro-violet-viettel/sourcecode/application/views/layout/frontend/header.php
r313 r375 67 67 68 68 <li> 69 <a href=" frontend-index.html">69 <a href="/frontend/home/signout"> 70 70 <i class="icon-off"></i> 71 71 Thoát
Note: See TracChangeset
for help on using the changeset viewer.