Grido\Components\Columns\Column::applyReplacement PHP Method

applyReplacement() protected method

protected applyReplacement ( mixed $value ) : mixed
$value mixed
return mixed
    protected function applyReplacement($value)
    {
        if ((is_scalar($value) || $value === NULL) && isset($this->replacements[$value])) {
            $replaced = $this->replacements[$value];
            if (is_scalar($replaced)) {
                $replaced = $this->translate($replaced);
            }
            $value = is_string($value) ? str_replace(static::VALUE_IDENTIFIER, $value, $replaced) : $replaced;
        }
        return $value;
    }