public function search() { $criteria = new DatetimeSearchCirteria(); $criteria->compare('LOWER(t.login_name)', strtolower($this->login_name), true); $criteria->compare('t.role_group_id', $this->role_group_id); $criteria->addDateCriteria('t.date_created', $this->date_created, true); $criteria->compare('t.is_visible', 1); $criteria->compare('LOWER(t.email)', strtolower($this->email), true); return new CActiveDataProvider($this, array('criteria' => $criteria)); }
public function search() { $criteria = new DatetimeSearchCirteria(); $criteria->compare('LOWER(t.client_name)', strtolower($this->client_name), true); $criteria->compare('LOWER(t.company_name)', strtolower($this->company_name), true); $criteria->compare('LOWER(t.login_name)', strtolower($this->login_name), true); $criteria->compare('LOWER(t.email)', strtolower($this->email), true); $criteria->compare('LOWER(t.address)', strtolower($this->address), true); $criteria->compare('country', $this->country, true); $criteria->compare('state', $this->state, true); $criteria->compare('LOWER(t.city)', strtolower($this->city), true); $criteria->compare('LOWER(t.zipcode)', strtolower($this->zipcode), true); $criteria->compare('LOWER(t.office_number)', strtolower($this->office_number), true); $criteria->compare('LOWER(t.cell_number)', strtolower($this->cell_number), true); $criteria->addDateCriteria('t.date_created', $this->date_created, true); return new CActiveDataProvider($this, array('criteria' => $criteria)); }