예제 #1
0
파일: factory.php 프로젝트: ajb/rfpez
 public static function section()
 {
     $faker = Faker\Factory::create();
     $s = new ProjectSection(array('section_category' => 'Requirements', 'title' => implode(" ", $faker->words), 'body' => $faker->paragraph, 'public' => rand(0, 8) == 0 ? false : true, 'times_used' => rand(0, 20)));
     $s->save();
     $s->project_types()->sync(ProjectType::lists('id'));
 }