请教下 关联模型 如何批量修改子表单个或多个字段的值 ?
请教下 关联模型 如何批量修改一个字段的值 ?
$post = App\Post::find(1); $post->comments()->saveMany(‘name’=> 'xiaoming');
推荐文章: