| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869 |
- <?php
- namespace ThurData\Servers\KerioEmail\App\UI\Client\Home\Fields;
- use ThurData\Servers\KerioEmail\Core\Helper\BuildUrl;
- use ThurData\Servers\KerioEmail\Core\UI\Interfaces\ClientArea;
- use ThurData\Servers\KerioEmail\Core\UI\Widget\Forms\Fields\BaseField;
- /**
- *
- * Created by PhpStorm.
- * User: Tomasz Bielecki ( tomasz.bi@thurdata.com )
- * Date: 03.10.19
- * Time: 14:37
- * Class FeatureField
- */
- class FeatureField extends BaseField implements ClientArea
- {
- protected $id = 'featureField';
- protected $name = 'featureField';
- protected $url;
- protected $targetBlank = false;
- /**
- * @return mixed
- */
- public function getUrl()
- {
- return $this->url;
- }
- /**
- * @param $url
- * @return $this
- */
- public function setUrl($url)
- {
- $this->url = $url;
- return $this;
- }
- /**
- * @return bool|string|null
- */
- public function getIcon()
- {
- $asset = BuildUrl::getAppAssetsURL();
- return $asset.DIRECTORY_SEPARATOR.'icons'.DIRECTORY_SEPARATOR.$this->id.'.png';
- }
- /**
- * @return bool
- */
- public function isTargetBlank()
- {
- return $this->targetBlank;
- }
- /**
- * @param $targetBlank
- * @return $this
- */
- public function setTargetBlank($targetBlank)
- {
- $this->targetBlank = $targetBlank;
- return $this;
- }
- }
|