コード例 #1
0
ファイル: Project.php プロジェクト: jaggy/work-scripts
 /**
  * List out all the projects.
  *
  * @return \Illuminate\Support\Collection
  */
 public function all()
 {
     if ($projects = Cache::get('projects')) {
         return $projects;
     }
     $projects = $this->objectify($this->request('GET', '/projects.xml')['project']);
     Cache::put('projects', $projects);
     return $projects;
 }
コード例 #2
0
ファイル: TimeOutCommand.php プロジェクト: jaggy/work-scripts
 /**
  * Cache the farewell log for today.
  *
  * @return void
  */
 private function cacheTimeOut()
 {
     Cache::put('time:out', true);
 }
コード例 #3
0
ファイル: TimeInCommand.php プロジェクト: jaggy/work-scripts
 /**
  * Cache the greeting log for today.
  *
  * @return void
  */
 private function cacheTimeIn()
 {
     Cache::put("time:in", true);
 }