Пример #1
0
 public static function nightly()
 {
     echo "<h1> Nightly Update</h1>";
     $log = "Nightly Update\n--------------\n\n";
     $bytes_written = File::put(public_path('filebank/log/nightly/' . Carbon::now()->format('Ymd') . '.txt'), $log);
     if ($bytes_written === false) {
         die("Error writing to file");
     }
     CronController::nonattendees();
     CronController::roster();
     echo "<h1> ALL DONE </h1>";
     echo '<br>Logfile filebank/log/nightly/' . Carbon::now()->format('Ymd') . '.txt';
 }
Пример #2
0
 /**
  * Execute the console command.
  *
  * @return mixed
  */
 public function handle()
 {
     \Log::info('Nightly update of roster + non-compliance');
     //\App\Models\Site\SiteRoster::nightlyUpdate();
     \App\Http\Controllers\CronController::nightly();
 }