protected function configureClientOptions()
    {
        $assetBundle = StarRatingAsset::register($this->view);

        if (!isset($this->clientOptions['score'])) {
            $this->clientOptions['score'] = $this->hasModel() ? Html::getAttributeValue($this->model, $this->attribute) : $this->value;
        }

        if (!isset($this->clientOptions['path'])) {
            $this->clientOptions['path'] = $assetBundle->baseUrl . $this->assetBundleImagePath;
        }

        if (!isset($this->clientOptions['scoreName']) && $this->hasModel()) {
            $this->clientOptions['scoreName'] = Html::getInputName($this->model, $this->attribute);
        }
    }
protected function configureClientOptions()
    {
        $assetBundle = StarRatingAsset::register($this->view);

        if (!isset($this->clientOptions['score'])) {
            $this->clientOptions['score'] = $this->hasModel() ? Html::getAttributeValue($this->model, $this->attribute) : $this->value;
        }

        if (!isset($this->clientOptions['path'])) {
            $this->clientOptions['path'] = $assetBundle->baseUrl . $this->assetBundleImagePath;
        }

        if (!isset($this->clientOptions['scoreName']) && $this->hasModel()) {
            $this->clientOptions['scoreName'] = Html::getInputName($this->model, $this->attribute);
        }
    }
protected function configureClientOptions ( ) { $ assetBundle = StarRatingAsset :: register ( $ this -> view ) ; if ( ! isset ( $ this -> clientOptions [ 'score' ] ) ) { $ this -> clientOptions [ 'score' ] = $ this -> hasModel ( ) ? Html :: getAttributeValue ( $ this -> model , $ this -> attribute ) : $ this -> value ; } if ( ! isset ( $ this -> clientOptions [ 'path' ] ) ) { $ this -> clientOptions [ 'path' ] = $ assetBundle -> baseUrl . $ this -> assetBundleImagePath ; } if ( ! isset ( $ this -> clientOptions [ 'scoreName' ] ) && $ this -> hasModel ( ) ) { $ this -> clientOptions [ 'scoreName' ] = Html :: getInputName ( $ this -> model , $ this -> attribute ) ; } }
Configure client options
Configure client options