时间:2021-07-01 10:21:17 帮助过:1人阅读
CONFIG
tablePrefix 设置表前缀
MODEL
设置与MODEL关联的表
public function tableName(){
return {{%table_name}} 表前缀加表名格式
}
分页: use yii\data\Pagination; $Page = new Pagination(['totalCount' => 总条数,'pageSize'=>每页显示数量]); 查询: 必须有与数据库名对应的model Model名::find()->where(条件['status'=>1]); $tombList
http://www.bkjia.com/PHPjc/981701.htmlwww.bkjia.comtruehttp://www.bkjia.com/PHPjc/981701.htmlTechArticleYII学习,yii CONFIG tablePrefix 设置表前缀 MODEL 设置与MODEL关联的表 public function tableName(){ return {{%table_name}} 表前缀加表名格式 } 分页:use yii\...