private function formatValue($value)
    {
        $attribute = $this->getAttributeModel();

        if ((int) $attribute->getDisplayPrecision() > 0) {
            $locale = $this->localeResolver->getLocale();
            $options = ['locale' => $locale, 'precision' => (int) $attribute->getDisplayPrecision()];
            $valueFormatter = new \Zend_Filter_NormalizedToLocalized($options);
            $value = $valueFormatter->filter($value);
        }

        if ((string) $attribute->getDisplayPattern() != "") {
            $value = sprintf((string) $attribute->getDisplayPattern(), $value);
        }

        return $value;
    }
private function formatValue($value)
    {
        $attribute = $this->getAttributeModel();

        if ((int) $attribute->getDisplayPrecision() > 0) {
            $locale = $this->localeResolver->getLocale();
            $options = ['locale' => $locale, 'precision' => (int) $attribute->getDisplayPrecision()];
            $valueFormatter = new \Zend_Filter_NormalizedToLocalized($options);
            $value = $valueFormatter->filter($value);
        }

        if ((string) $attribute->getDisplayPattern() != "") {
            $value = sprintf((string) $attribute->getDisplayPattern(), $value);
        }

        return $value;
    }
private function formatValue ( $ value ) { $ attribute = $ this -> getAttributeModel ( ) ; if ( ( int ) $ attribute -> getDisplayPrecision ( ) > 0 ) { $ locale = $ this -> localeResolver -> getLocale ( ) ; $ options = [ 'locale' => $ locale , 'precision' => ( int ) $ attribute -> getDisplayPrecision ( ) ] ; $ valueFormatter = new \ Zend_Filter_NormalizedToLocalized ( $ options ) ; $ value = $ valueFormatter -> filter ( $ value ) ; } if ( ( string ) $ attribute -> getDisplayPattern ( ) != "" ) { $ value = sprintf ( ( string ) $ attribute -> getDisplayPattern ( ) , $ value ) ; } return $ value ; }
Format value according to attribute display options

@param mixed $value The value to format

@return string
Format value according to attribute display options