/media/shnoulle/data/webdev/master/application/core/SurveyCommonAction.php(420)
408 */ 409 protected function updatenotification() 410 { 411 // Never use Notification model for database update. 412 // TODO: Real fix: No database queries while doing database update, meaning 413 // don't call renderWrappedTemplate. 414 if (get_class($this) == 'databaseupdate') { 415 return; 416 } 417 418 if (!Yii::app()->user->isGuest && Yii::app()->getConfig('updatable')) { 419 $updateModel = new UpdateForm(); 420 $updateNotification = $updateModel->updateNotification; 421 422 if ($updateNotification->result) { 423 $scriptToRegister = App()->getConfig('packages') . DIRECTORY_SEPARATOR . 'comfort_update' . DIRECTORY_SEPARATOR. 'comfort_update.js'; 424 App()->getClientScript()->registerScriptFile($scriptToRegister); 425 return $this->getController()->renderPartial("/admin/update/_update_notification", array('security_update_available' => $updateNotification->security_update)); 426 } 427 } 428 } 429 430 /** 431 * Display notifications 432 *
| #0 |
+
–
/media/shnoulle/data/webdev/master/vendor/yiisoft/yii/framework/db/ar/CActiveRecord.php(413): CActiveRecordMetaData->__construct() 408 { 409 $className=get_class($this); 410 if(!array_key_exists($className,self::$_md)) 411 { 412 self::$_md[$className]=null; // preventing recursive invokes of {@link getMetaData()} via {@link __get()} 413 self::$_md[$className]=new CActiveRecordMetaData($this); 414 } 415 return self::$_md[$className]; 416 } 417 418 /** |
| #1 |
+
–
/media/shnoulle/data/webdev/master/vendor/yiisoft/yii/framework/db/ar/CActiveRecord.php(663): CActiveRecord->getMetaData() 658 * Returns the metadata of the table that this AR belongs to 659 * @return CDbTableSchema the metadata of the table that this AR belongs to 660 */ 661 public function getTableSchema() 662 { 663 return $this->getMetaData()->tableSchema; 664 } 665 666 /** 667 * Returns the command builder used by this AR. 668 * @return CDbCommandBuilder the command builder used by this AR |
| #2 |
+
–
/media/shnoulle/data/webdev/master/vendor/yiisoft/yii/framework/db/ar/CActiveRecord.php(1543): CActiveRecord->getTableSchema() 1538 */ 1539 public function findAllByAttributes($attributes,$condition='',$params=array()) 1540 { 1541 Yii::trace(get_class($this).'.findAllByAttributes()','system.db.ar.CActiveRecord'); 1542 $prefix=$this->getTableAlias(true).'.'; 1543 $criteria=$this->getCommandBuilder()->createColumnCriteria($this->getTableSchema(),$attributes,$condition,$params,$prefix); 1544 return $this->query($criteria,true); 1545 } 1546 1547 /** 1548 * Finds a single active record with the specified SQL statement. |
| #3 |
+
–
/media/shnoulle/data/webdev/master/application/models/UserInPermissionrole.php(64): CActiveRecord->findAllByAttributes() 59 ); 60 } 61 62 public function getRoleForUser($userId, $single = false) 63 { 64 $aRoles = self::model()->findAllByAttributes(['uid' => $userId]); 65 if ($single) { 66 return $aRoles[0]; 67 } 68 return $aRoles; 69 } |
| #4 |
+
–
/media/shnoulle/data/webdev/master/application/models/Permission.php(801): UserInPermissionrole->getRoleForUser() 796 * @return int roleId 797 * @throws Exception 798 */ 799 public static function getUserRole($iUserID) 800 { 801 return UserInPermissionrole::model()->getRoleForUser($iUserID); 802 } 803 804 /** 805 * get permission by user roles 806 * @param integer[] $rolesIds array of roles id |
| #5 |
+
–
/media/shnoulle/data/webdev/master/application/models/Permission.php(591): Permission::getUserRole() 586 'export_p' => false, 587 ), 588 $bPermission 589 ); 590 /* get it by roles if exist */ 591 $aRolesList = CHtml::listData(self::getUserRole($iUserID), 'ptid', 'ptid'); 592 if ($aRolesList) { 593 /* Do it only for read and create : roles can remove permission */ 594 $aPermissionStatic[0]['global'][$iUserID]['superadmin']['read_p'] = self::getPermissionByRoles($aRolesList, 'superadmin', 'read'); 595 $aPermissionStatic[0]['global'][$iUserID]['superadmin']['create_p'] = self::getPermissionByRoles($aRolesList, 'superadmin', 'create'); 596 } |
| #6 |
+
–
/media/shnoulle/data/webdev/master/application/models/Permission.php(653): Permission->hasPermission() 648 * @param $iUserID integer User ID - if not given the one of the current user is used 649 * @return bool True if user has the permission 650 */ 651 public function hasGlobalPermission($sPermission, $sCRUD = 'read', $iUserID = null) 652 { 653 return $this->hasPermission(0, 'global', $sPermission, $sCRUD, $iUserID); 654 } 655 656 public function getButtons(): string 657 { 658 $setPermissionsUrl = App()->getController()->createUrl( |
| #7 |
+
–
/media/shnoulle/data/webdev/master/application/models/UpdateForm.php(564): Permission->hasGlobalPermission() 559 * @return object 560 */ 561 public function getUpdateNotification() 562 { 563 $this->checkAssets(); 564 if (Yii::app()->getConfig('updatable') && Permission::model()->hasGlobalPermission('superadmin')) { 565 $today = new DateTime("now"); 566 $next_update_check = Yii::app()->session['next_update_check']; 567 568 if (is_null($next_update_check) || ($next_update_check < $today) || is_null(Yii::app()->session['update_result'])) { 569 // Turn on the alert notification |
| #8 |
+
–
/media/shnoulle/data/webdev/master/vendor/yiisoft/yii/framework/base/CComponent.php(111): UpdateForm->getUpdateNotification() 106 */ 107 public function __get($name) 108 { 109 $getter='get'.$name; 110 if(method_exists($this,$getter)) 111 return $this->$getter(); 112 elseif(strncasecmp($name,'on',2)===0 && method_exists($this,$name)) 113 { 114 // duplicating getEventHandlers() here for performance 115 $name=strtolower($name); 116 if(!isset($this->_e[$name])) |
| #9 |
+
–
/media/shnoulle/data/webdev/master/application/core/SurveyCommonAction.php(420): CComponent->__get() 415 return; 416 } 417 418 if (!Yii::app()->user->isGuest && Yii::app()->getConfig('updatable')) { 419 $updateModel = new UpdateForm(); 420 $updateNotification = $updateModel->updateNotification; 421 422 if ($updateNotification->result) { 423 $scriptToRegister = App()->getConfig('packages') . DIRECTORY_SEPARATOR . 'comfort_update' . DIRECTORY_SEPARATOR. 'comfort_update.js'; 424 App()->getClientScript()->registerScriptFile($scriptToRegister); 425 return $this->getController()->renderPartial("/admin/update/_update_notification", array('security_update_available' => $updateNotification->security_update)); |
| #10 |
+
–
/media/shnoulle/data/webdev/master/application/views/admin/super/layout_minimal.php(12): SurveyCommonAction->updatenotification() 07 08 //The adminmenu bar will be generated from /admin/super/adminmenu.php 09 10 echo "<!-- BEGIN LAYOUT_MAIN -->"; 11 // Generated through /admin/super/fullpagebar_view 12 $this->updatenotification(); 13 $this->notifications(); 14 15 //The load indicator for pjax 16 echo ' <div id="pjax-file-load-container" class="ls-flex-row col-12"><div style="height:2px;width:0px;"></div></div>'; 17 |
| #11 |
+
–
/media/shnoulle/data/webdev/master/application/core/SurveyCommonAction.php(241): require("/media/shnoulle/data/webdev/master/application/views/admin/super...") 236 } 237 238 if ($_return_) { 239 ob_start(); 240 ob_implicit_flush(0); 241 require($_viewFile_); 242 return ob_get_clean(); 243 } else { 244 require($_viewFile_); 245 } 246 } |
| #12 |
+
–
/media/shnoulle/data/webdev/master/application/core/SurveyCommonAction.php(396): SurveyCommonAction->renderInternal() 391 } 392 } else { 393 $renderFile = $basePath . '/' . $sRenderFile; 394 } 395 $content = $this->renderCentralContents($sAction, $aViewUrls, $aData); 396 $out = $this->renderInternal($renderFile, ['content' => $content, 'aData' => $aData], true); 397 398 App()->getClientScript()->render($out); 399 echo $out; 400 } 401 |
| #13 |
+
–
/media/shnoulle/data/webdev/master/application/controllers/admin/DatabaseUpdate.php(45): SurveyCommonAction->renderWrappedTemplate() 40 } 41 42 43 $aData['updatedbaction'] = true; 44 45 $this->renderWrappedTemplate('update', $aViewUrls, $aData, 'layout_minimal.php'); 46 } 47 } |
| #14 |
unknown(0): DatabaseUpdate->db()
|
| #15 |
+
–
/media/shnoulle/data/webdev/master/vendor/yiisoft/yii/framework/web/actions/CAction.php(114): ReflectionMethod->invokeArgs() 109 elseif($param->isDefaultValueAvailable()) 110 $ps[]=$param->getDefaultValue(); 111 else 112 return false; 113 } 114 $method->invokeArgs($object,$ps); 115 return true; 116 } 117 } |
| #16 |
+
–
/media/shnoulle/data/webdev/master/application/core/SurveyCommonAction.php(83): CAction->runWithParamsInternal() 78 $oMethod = new ReflectionMethod($this, $sDefault); 79 } 80 81 // We're all good to go, let's execute it 82 // runWithParamsInternal would automatically get the parameters of the method and populate them as required with the params 83 return parent::runWithParamsInternal($this, $oMethod, $params); 84 } 85 86 /** 87 * Some functions have different parameters, which are just an alias of the 88 * usual parameters we're getting in the url. This function just populates |
| #17 |
+
–
/media/shnoulle/data/webdev/master/vendor/yiisoft/yii/framework/web/CController.php(308): SurveyCommonAction->runWithParams() 303 { 304 $priorAction=$this->_action; 305 $this->_action=$action; 306 if($this->beforeAction($action)) 307 { 308 if($action->runWithParams($this->getActionParams())===false) 309 $this->invalidActionParams($action); 310 else 311 $this->afterAction($action); 312 } 313 $this->_action=$priorAction; |
| #18 |
+
–
/media/shnoulle/data/webdev/master/vendor/yiisoft/yii/framework/web/CController.php(286): CController->runAction() 281 * @see runAction 282 */ 283 public function runActionWithFilters($action,$filters) 284 { 285 if(empty($filters)) 286 $this->runAction($action); 287 else 288 { 289 $priorAction=$this->_action; 290 $this->_action=$action; 291 CFilterChain::create($this,$action,$filters)->run(); |
| #19 |
+
–
/media/shnoulle/data/webdev/master/vendor/yiisoft/yii/framework/web/CController.php(265): CController->runActionWithFilters() 260 { 261 if(($parent=$this->getModule())===null) 262 $parent=Yii::app(); 263 if($parent->beforeControllerAction($this,$action)) 264 { 265 $this->runActionWithFilters($action,$this->filters()); 266 $parent->afterControllerAction($this,$action); 267 } 268 } 269 else 270 $this->missingAction($actionID); |
| #20 |
+
–
/media/shnoulle/data/webdev/master/application/controllers/AdminController.php(204): CController->run() 199 $this->runModuleController($action); 200 // this will redirect the default action to the new controller previously "admin/index" or "admin" to "dashboard/view" 201 if (empty($action) || $action === 'index') { 202 $this->redirect($this->createUrl('dashboard/view')); 203 } 204 return parent::run($action); 205 } 206 207 /** 208 * Starting with LS4, 3rd party developer can extends any of the LimeSurve controllers. 209 * |
| #21 |
+
–
/media/shnoulle/data/webdev/master/vendor/yiisoft/yii/framework/web/CWebApplication.php(282): AdminController->run() 277 { 278 list($controller,$actionID)=$ca; 279 $oldController=$this->_controller; 280 $this->_controller=$controller; 281 $controller->init(); 282 $controller->run($actionID); 283 $this->_controller=$oldController; 284 } 285 else 286 throw new CHttpException(404,Yii::t('yii','Unable to resolve the request "{route}".', 287 array('{route}'=>$route===''?$this->defaultController:$route))); |
| #22 |
+
–
/media/shnoulle/data/webdev/master/vendor/yiisoft/yii/framework/web/CWebApplication.php(141): CWebApplication->runController() 136 foreach(array_splice($this->catchAllRequest,1) as $name=>$value) 137 $_GET[$name]=$value; 138 } 139 else 140 $route=$this->getUrlManager()->parseUrl($this->getRequest()); 141 $this->runController($route); 142 } 143 144 /** 145 * Registers the core application components. 146 * This method overrides the parent implementation by registering additional core components. |
| #23 |
+
–
/media/shnoulle/data/webdev/master/vendor/yiisoft/yii/framework/base/CApplication.php(185): CWebApplication->processRequest() 180 public function run() 181 { 182 if($this->hasEventHandler('onBeginRequest')) 183 $this->onBeginRequest(new CEvent($this)); 184 register_shutdown_function(array($this,'end'),0,false); 185 $this->processRequest(); 186 if($this->hasEventHandler('onEndRequest')) 187 $this->onEndRequest(new CEvent($this)); 188 } 189 190 /** |
| #24 |
+
–
/media/shnoulle/data/webdev/master/index.php(161): CApplication->run() 156 require_once APPPATH . 'core/LSYii_Application' . EXT; 157 158 $config = require_once(APPPATH . 'config/internal' . EXT); 159 160 Yii::$enableIncludePath = false; 161 Yii::createApplication('LSYii_Application', $config)->run(); 162 163 /* End of file index.php */ 164 /* Location: ./index.php */ |