<?php $arrData = C2goActiveRecord::getDBRelation2Module($model, true); if (!is_null($arrData)) { $moduleObj = Yii::app()->getModule($arrData['module']); // !!! don't erase , its autoload data $modelName = $arrData['class']; $modelObj = $modelName::model()->findByPk($external_id); if (!is_null($modelObj)) { $strCart = C2goActiveRecord::getCartViewString($arrData); if (isset($arrData['asmod'])) { $modelNameToView = $arrData['asmod']; } else { $modelNameToView = $modelName; // !!! see getDBRelation2Module second parameter } echo $this->renderPartial($strCart, [$modelNameToView => $modelObj]); } else { echo $this->renderPartial('//site/elementnotavail', ['external_id' => $external_id, 'model' => $modelName]); } } ?> <div class="row"> <?php $dataProvider = new CArrayDataProvider($Response); $dataProvider->pagination = array('pageSize' => 25); $this->widget('booster.widgets.TbListView', ['dataProvider' => $dataProvider, 'template' => '{pager} <table class="result-table"> <thead> <tr> <th>' . Yii::t('default', 'Просмотрено') . '</th>