예제 #1
0
 /**
  * @param Group $model
  */
 protected function preCreate(Group $model)
 {
     if (Text::create($model->getSlug())->isEmpty()) {
         $title = $model->getTitle();
         $slugifier = new Slugify();
         $model->setSlug($slugifier->slugify($title));
     }
 }