请教下 $model->where([‘type’=>1])->andWhere([‘like’, ‘content’, $keyword]) 还有个条件 create_time > $time 应该怎么写
Accountdoc::find() ->andFilterWhere([‘=’,’nShopID’,$this->nShopID])
可以类似这样写
where([‘>’,’create_time’,$time])
andWhere([‘>’,’create_time’,$time])
用数组啊,可以把数组放进where
最简单的是
where([‘type’=>1,array(‘like’,’content’,$keyword),array(‘>’,’create_time’ ,$time)])
不知道有没有写错额~~你可以试试!