Ignore:
Timestamp:
Nov 12, 2014 9:28:43 AM (11 years ago)
Author:
quyenla
Message:

thong ke

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pro-violet-viettel/sourcecode/application/modules/admin/models/collabolator_model.php

    r464 r478  
    123123        if ($data['keyword']) {
    124124            if ($data['search_field'] == "cellphone") {
    125                 $where.=" WHERE (tblcollaborator.cellphone LIKE '%" . $data['keyword'] . "%')";
    126             } else {
    127                 $where.=" WHERE (full_name LIKE '%" . $data['keyword'] . "%' OR login_name LIKE '%" . $data['keyword'] . "%') ";
     125                $where.=" WHERE (tbluser.cellphone LIKE '%" . $data['keyword'] . "%')";
    128126            }
    129127        }
     
    153151        if ($data['keyword']) {
    154152            if ($data['search_field'] == "cellphone") {
    155                 $where.=" WHERE (tblcollaborator.cellphone LIKE '%" . $data['keyword'] . "%')";
    156             } else {
    157                 $where.=" WHERE (full_name LIKE '%" . $data['keyword'] . "%' OR login_name LIKE '%" . $data['keyword'] . "%') ";
    158             }
     153                $where.=" WHERE (tbluser.cellphone LIKE '%" . $data['keyword'] . "%')";
     154            }
    159155        }
    160156       // $from = date("Y-m-d 00:00:00",$from);
    161157        $sql="SELECT *,tblcollaborator.created_time as collaborator_created_time,tbluser.cellphone as user_cellphone,tblcollaborator.cellphone as collaborator_cellphone, tbluser.created_time as user_created_time  FROM ".$this->table_name." INNER JOIN tbluser ON tbluser.collaborator = tblcollaborator.id ".$where." AND tbluser.collaborator = ".$data['id']." ".$order." LIMIT " . $data['start'] . ", " . $data['perpage'] . " ";
    162    
    163158        $result = $this->db->query($sql)->result_array();
    164159        foreach ($result as $index=>$paidlog)
Note: See TracChangeset for help on using the changeset viewer.