/** * Clothes * @return string */ public function clothes() { $clothes = array(); foreach ($this->Activity->clothes()->asArray() as $id) { $clothes[] = ClothesFactory::NameFor($id); } return implode(', ', $clothes); }
/** * Remove data as weather/clothes, if sport is always inside */ protected function removeDataIfInside() { if ($this->Object->sportid() > 0) { $Factory = \Runalyze\Context::Factory(); if (!$Factory->sport($this->Object->sportid())->isOutside()) { $this->Object->weather()->condition()->set(\Runalyze\Data\Weather\Condition::UNKNOWN); $this->Object->weather()->temperature()->setTemperature(null); $this->Object->clothes()->clear(); $this->Object->synchronize(); } } }