Exemple #1
0
 public function allStatus($client)
 {
     $allStatus = $client->api('issue_status')->all();
     try {
         $status = new Status();
         foreach ($allStatus['issue_statuses'] as $key => $value) {
             $status->exchangeArray($value);
             $this->getStatusTable()->saveStatus($status);
         }
     } catch (\Exception $ex) {
         //send mail if any error occur during CRON JOB
     }
 }
 public function allStatus()
 {
     $issueId = 54293;
     $client = new Client("https://portal.optimusinfo.com/redmine/", 'vikas.singhal', 'vzi950');
     $issueInfo = $client->api('issue')->show($issueId);
     //echo "<pre>";print_r($ issueInfo);die;
     $status = new Status();
     foreach ($issueInfo as $key => $value) {
         $status->exchangeArray($value);
         $this->getStatusTable()->saveStatus($status);
     }
     return true;
 }