| @@ 58-71 (lines=14) @@ | ||
| 55 | * @param $timerId |
|
| 56 | * @return string |
|
| 57 | */ |
|
| 58 | public function deleteTimer($timerId) |
|
| 59 | { |
|
| 60 | $message = ''; |
|
| 61 | ||
| 62 | foreach ($this->config->implementedServicesForFeature('delete') as $service) { |
|
| 63 | if ($this->deleteServiceTimer($service, $timerId) === true) { |
|
| 64 | $message .= '- ' . ucfirst($service) . ': deleted' . "\r\n"; |
|
| 65 | } else { |
|
| 66 | $message .= '- ' . ucfirst($service) . ': cannot delete' . "\r\n"; |
|
| 67 | } |
|
| 68 | } |
|
| 69 | ||
| 70 | return $message; |
|
| 71 | } |
|
| 72 | ||
| 73 | /** |
|
| 74 | * @param $projectId |
|
| @@ 327-340 (lines=14) @@ | ||
| 324 | * @param string $service |
|
| 325 | * @return string |
|
| 326 | */ |
|
| 327 | private function syncServiceOnlineDataToLocalCache($service) |
|
| 328 | { |
|
| 329 | $message = ''; |
|
| 330 | $data = $this->$service->getOnlineData(); |
|
| 331 | ||
| 332 | if (empty($data) === false) { |
|
| 333 | $this->saveServiceDataCache($service, $data); |
|
| 334 | $message .= '- ' . ucfirst($service) . ': data cached' . "\r\n"; |
|
| 335 | } else { |
|
| 336 | $message .= '- ' . ucfirst($service) . ': cannot cache data' . "\r\n"; |
|
| 337 | } |
|
| 338 | ||
| 339 | return $message; |
|
| 340 | } |
|
| 341 | } |
|
| 342 | ||