/** * Return the currency symbol. * * @return string|null */ public function symbol() { if (($key = $this->object->getValue()) === null) { return null; } return config('streams::currencies.supported.' . $key . '.symbol'); }
/** * Return the selection value. * * @return string|null */ public function value() { $options = $this->object->getOptions(); if (!($key = $this->object->getValue())) { return null; } return trans(array_get($options, $key)); }