/**
  ** Performs the data validation with ability to specify which attributes should not be validated.
  *
  * @param array $attributeNames list of attribute names that should not be validated.
  * @param boolean $clearErrors whether to call [[clearErrors()]] before performing validation
  * @return boolean whether the validation is successful without any error.
  */
 public function validateExcept($attributeNames = [], $clearErrors = true)
 {
     $attributes = ArrayHelper::removeValues($this->activeAttributes(), $attributeNames);
     return $this->validate($attributes, $clearErrors);
 }
 /**
  * @return Pager
  */
 protected function getPagerInstance()
 {
     if ($this->_pagerInstance !== null) {
         return $this->_pagerInstance;
     }
     $pagination = $this->dataProvider->getPagination();
     if ($pagination === false || $this->dataProvider->getCount() <= 0) {
         return null;
     }
     /* @var $class Pager */
     $pager = $this->pager;
     $class = ArrayHelper::remove($pager, 'class', Pager::className());
     $pager['class'] = $class;
     $pager['pagination'] = $pagination;
     $pager['view'] = $this->getView();
     $this->_pagerInstance = \Yii::createObject($pager);
     return $this->_pagerInstance;
 }