finish feature #26
This commit is contained in:
@@ -105,7 +105,6 @@ class UserController extends Controller
|
|||||||
*/
|
*/
|
||||||
public function actionDelete($id)
|
public function actionDelete($id)
|
||||||
{
|
{
|
||||||
// $this->findModel($id)->delete();
|
|
||||||
|
|
||||||
$user = $this->findModel($id);
|
$user = $this->findModel($id);
|
||||||
|
|
||||||
|
|||||||
@@ -46,6 +46,8 @@ class UserSearch extends User
|
|||||||
$dataProvider = new ActiveDataProvider([
|
$dataProvider = new ActiveDataProvider([
|
||||||
'query' => $query,
|
'query' => $query,
|
||||||
]);
|
]);
|
||||||
|
|
||||||
|
$query->andWhere(['status' => User::STATUS_ACTIVE]);
|
||||||
|
|
||||||
$this->load($params);
|
$this->load($params);
|
||||||
|
|
||||||
@@ -54,6 +56,8 @@ class UserSearch extends User
|
|||||||
// $query->where('0=1');
|
// $query->where('0=1');
|
||||||
return $dataProvider;
|
return $dataProvider;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
$query->andFilterWhere([
|
$query->andFilterWhere([
|
||||||
'id' => $this->id,
|
'id' => $this->id,
|
||||||
|
|||||||
@@ -201,4 +201,12 @@ class User extends ActiveRecord implements IdentityInterface
|
|||||||
}
|
}
|
||||||
return $result;
|
return $result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public function attributeLabels(){
|
||||||
|
return [
|
||||||
|
|
||||||
|
];
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user