/** * 2016-07-18 * 2016-10-24 * Сообщение для покупателя функция возвращает, * а сообщение для администратора — логирует. * @param \Exception|Exception $e * @return string */ function message(\Exception $e) { /** @var bool $isSpecific */ $isSpecific = $e instanceof Exception; if (!$isSpecific) { $e = df_ef($e); } df_log($e); /** @var string $mc */ /** @var string $md */ list($mc, $md) = $isSpecific ? [$e->messageC(), df_tag_if($e->messageD(), $e->isMessageHtml(), 'pre')] : [dfp_error_message(), df_etsd($e)]; return !$this->ss()->test() ? $mc : df_cc_br($mc, __('Debug message:'), $md); }
/** * 2016-11-23 * @see \Dfe\FacebookLogin\Button::loggedOut() * @used-by _toHtml() * @return string */ protected function loggedOut() { $unified = UNL::isUnified($this->s()->type()); return df_tag('a', $this->attributes(), df_tag_if($this->s()->label(), $unified, 'span')) . (!$unified ? '' : df_fa_link()) . (!$this->isInHeader() || UNL::isLink($this->s()->type()) || self::$_inlineIncluded ? '' : (self::$_inlineIncluded = df_style_inline('.df-theme-luma .page-header .header.panel {padding-bottom: 0.4rem;}'))); }
/** * 2016-08-20 * @used-by \Df\Payment\Observer\FormatTransactionId::execute() * @param T $t * @return string */ public function formatTransactionId(T $t) { /** @var string|null $url */ $url = $this->transUrl($t); return df_tag_if($t->getTxnId(), $url, 'a', ['href' => $url, 'target' => '_blank', 'title' => __('View the transaction in the %1 interface', $this->getTitle())]); }