MCPcopy Create free account
hub / github.com/Rello/analytics / setFavorite

Method setFavorite

lib/Service/PanoramaService.php:238–245  ·  view source on GitHub ↗

* set/remove the favorite flag for a report * * @param int $panoramaId * @param string $favorite * @return bool */

(int $panoramaId, string $favorite)

Source from the content-addressed store, hash-verified

236 * @return bool
237 */
238 public function setFavorite(int $panoramaId, string $favorite) {
239 if ($favorite === 'true') {
240 $return = $this->addFavoriteTag('analyticsPanorama', $panoramaId);
241 } else {
242 $return = $this->removeFavoriteTag('analyticsPanorama', $panoramaId);
243 }
244 return $return;
245 }
246
247 private function addFavoriteTag(string $scope, int $objectId): bool {
248 try {

Callers 1

deleteByUserMethod · 0.95

Calls 2

addFavoriteTagMethod · 0.95
removeFavoriteTagMethod · 0.95

Tested by

no test coverage detected