framework/data/DataFilter.php
protected function parseErrorMessage($messageKey, $params = [])
    {
        $messages = $this->getErrorMessages();
        if (isset($messages[$messageKey])) {
            $message = $messages[$messageKey];
        } else {
            $message = Yii::t('yii', 'The format of {filter} is invalid.');
        }

        $params = array_merge(
            [
                'filter' => $this->getAttributeLabel($this->filterAttributeName),
            ],
            $params
        );

        return Yii::$app->getI18n()->format($message, $params, Yii::$app->language);
    }
protected function parseErrorMessage($messageKey, $params = [])
    {
        $messages = $this->getErrorMessages();
        if (isset($messages[$messageKey])) {
            $message = $messages[$messageKey];
        } else {
            $message = Yii::t('yii', 'The format of {filter} is invalid.');
        }

        $params = array_merge(
            [
                'filter' => $this->getAttributeLabel($this->filterAttributeName),
            ],
            $params
        );

        return Yii::$app->getI18n()->format($message, $params, Yii::$app->language);
    }
protected function parseErrorMessage ( $ messageKey , $ params = [ ] ) { $ messages = $ this -> getErrorMessages ( ) ; if ( isset ( $ messages [ $ messageKey ] ) ) { $ message = $ messages [ $ messageKey ] ; } else { $ message = Yii :: t ( 'yii' , 'The format of {filter} is invalid.' ) ; } $ params = array_merge ( [ 'filter' => $ this -> getAttributeLabel ( $ this -> filterAttributeName ) , ] , $ params ) ; return Yii :: $ app -> getI18n ( ) -> format ( $ message , $ params , Yii :: $ app -> language ) ; }
Parses content of the message from [[errorMessages]], specified by message key.
@param string $messageKey message key.
@param array $params params to be parsed into the message.
@return string composed message string.
Parses content of the message from [[ errorMessages ]] specified by message key .