Пример #1
0
 /**
  * Run the database seeds.
  *
  * @return void
  */
 public function run()
 {
     Setting::truncate();
     $settings = $this->settings();
     foreach ($settings as $setting) {
         Setting::create($setting);
     }
 }
Пример #2
0
 /**
  * Settings constructor.
  *
  * @param Setting $setting
  *
  * @todo Needs to be cached forever. On update, it must update the cache too.
  */
 public function __construct(Setting $setting)
 {
     $this->items = $setting->all();
 }