Copied! Copy Stacktrace Search Stackoverflow Search Google Error

PHP Notice亚博体育 登录_亚博官网在线_亚博app下载官网下载

Undefined index: menuid

  • 1. in /var/www/admin/yulinnew/controllers/SiteController.php at line 207
    198199200201202203204205206207208209210211212213214215216
        }
     
        public function actionChannel()
        {
     
            $this->layout='@app/views/layouts/column1.php';
     
            $dataProvider = new ActiveDataProvider([
                'query' => Content::find()
                ->where(['status'=>'ContentWorkflow/fabu','menu'=>$_GET['menuid']])
                ->orderBy('id ASC')->limit(1),
                'pagination' => [
                    'pageSize' => 1,
                ],
            ]);
            if(isset($dataProvider->getModels()[0]['id'])){
                $id=$dataProvider->getModels()[0]['id'];
                if(isset($id)){
                    $this->counts($id);
    
  • 2. in /var/www/admin/yulinnew/controllers/SiteController.php at line 207 yii\base\ErrorHandler::handleError(8, 'Undefined index: menuid', '/var/www/admin/yulinnew/controll...', 207, ...)
    201202203204205206207208209210211212213
        {
     
            $this->layout='@app/views/layouts/column1.php';
     
            $dataProvider = new ActiveDataProvider([
                'query' => Content::find()
                ->where(['status'=>'ContentWorkflow/fabu','menu'=>$_GET['menuid']])
                ->orderBy('id ASC')->limit(1),
                'pagination' => [
                    'pageSize' => 1,
                ],
            ]);
            if(isset($dataProvider->getModels()[0]['id'])){
    
  • 3. app\controllers\SiteController::actionChannel()
  • 4. in /var/www/admin/yulinnew/vendor/yiisoft/yii2/base/InlineAction.php at line 57 – call_user_func_array([app\controllers\SiteController, 'actionChannel'], [])
    515253545556575859
            $args = $this->controller->bindActionParams($this, $params);
            Yii::debug('Running action: ' . get_class($this->controller) . '::' . $this->actionMethod . '()', __METHOD__);
            if (Yii::$app->requestedParams === null) {
                Yii::$app->requestedParams = $args;
            }
     
            return call_user_func_array([$this->controller, $this->actionMethod], $args);
        }
    }
    
  • 5. in /var/www/admin/yulinnew/vendor/yiisoft/yii2/base/Controller.php at line 180 yii\base\InlineAction::runWithParams(['r' => 'site/channel', 'amp;menuid' => '202'])
    174175176177178179180181182183184185186
            }
     
            $result = null;
     
            if ($runAction && $this->beforeAction($action)) {
                // run the action
                $result = $action->runWithParams($params);
     
                $result = $this->afterAction($action, $result);
     
                // call afterAction on modules
                foreach ($modules as $module) {
                    /* @var $module Module */
    
  • 6. in /var/www/admin/yulinnew/vendor/yiisoft/yii2/base/Module.php at line 528 yii\base\Controller::runAction('channel', ['r' => 'site/channel', 'amp;menuid' => '202'])
    522523524525526527528529530531532533534
            $parts = $this->createController($route);
            if (is_array($parts)) {
                /* @var $controller Controller */
                list($controller, $actionID) = $parts;
                $oldController = Yii::$app->controller;
                Yii::$app->controller = $controller;
                $result = $controller->runAction($actionID, $params);
                if ($oldController !== null) {
                    Yii::$app->controller = $oldController;
                }
     
                return $result;
            }
    
  • 7. in /var/www/admin/yulinnew/vendor/yiisoft/yii2/web/Application.php at line 103 yii\base\Module::runAction('site/channel', ['r' => 'site/channel', 'amp;menuid' => '202'])
    979899100101102103104105106107108109
                $params = $this->catchAll;
                unset($params[0]);
            }
            try {
                Yii::debug("Route requested: '$route'", __METHOD__);
                $this->requestedRoute = $route;
                $result = $this->runAction($route, $params);
                if ($result instanceof Response) {
                    return $result;
                }
     
                $response = $this->getResponse();
                if ($result !== null) {
    
  • 8. in /var/www/admin/yulinnew/vendor/yiisoft/yii2/base/Application.php at line 386 yii\web\Application::handleRequest(yii\web\Request)
    380381382383384385386387388389390391392
        {
            try {
                $this->state = self::STATE_BEFORE_REQUEST;
                $this->trigger(self::EVENT_BEFORE_REQUEST);
     
                $this->state = self::STATE_HANDLING_REQUEST;
                $response = $this->handleRequest($this->getRequest());
     
                $this->state = self::STATE_AFTER_REQUEST;
                $this->trigger(self::EVENT_AFTER_REQUEST);
     
                $this->state = self::STATE_SENDING_RESPONSE;
                $response->send();
    
  • 9. in /var/www/admin/yulinnew/web/index.php at line 12 yii\base\Application::run()
    6789101112
     
    require __DIR__ . '/../vendor/autoload.php';
    require __DIR__ . '/../vendor/yiisoft/yii2/Yii.php';
     
    $config = require __DIR__ . '/../config/web.php';
     
    (new yii\web\Application($config))->run();
    
  • $_GET = [
        'r' => 'site/channel',
        'amp;menuid' => '202',
    ];