多应用+插件架构,代码干净,二开方便,首家独创一键云编译技术,文档视频完善,免费商用码云13.8K 广告
>[danger] 根据关联条件查询 + 根据关联条件来查询当前模型对象数据 + 例如:在文章模型中查询评论大于3条数据的文章 ``` // 查询评论超过3个的文章 // has('关联方法名', '操作符', '值') $list = self::has('comments','>',3)->select(); ``` ``` // 查询评论状态正常的文章 // hasWhere('关联方法名', '操作符', '值') status 评论表字段 $list = self::hasWhere('comments', ['status' => 1])->select(); dump($list); ```