Skip to content
Snippets Groups Projects
Select Git revision
  • b77360b80727121b6a367b47085f61620cdfd099
  • master default protected
  • test/accessibilita-backend
  • test/1.9.3/1
  • test/1.9.5/1
  • test/1.9.2/1
  • test/1.9.0/1
  • 1.10.0
  • 1.9.5
  • 1.9.4
  • 1.9.3
  • 1.9.2
  • 1.9.1
  • 1.9.0
14 results

SondaggiDomandePagineController.php

Blame
  • SondaggiDomandePagineController.php 8.38 KiB
    <?php
    
    /**
     * Art-ER Attrattività, ricerca e territorio dell’Emilia-Romagna
     * OPEN 2.0
     *
     *
     * @package    arter\amos\sondaggi\controllers
     * @category   CategoryName
     * @author     Elite Division S.r.l.
     */
    
    namespace arter\amos\sondaggi\controllers;
    
    use arter\amos\core\controllers\CrudController;
    use arter\amos\core\helpers\Html;
    use arter\amos\core\icons\AmosIcons;
    use arter\amos\sondaggi\AmosSondaggi;
    use arter\amos\sondaggi\models\search\SondaggiDomandePagineSearch;
    use arter\amos\sondaggi\models\Sondaggi;
    use arter\amos\sondaggi\models\SondaggiDomandePagine;
    use arter\amos\upload\models\FilemanagerMediafile;
    use Yii;
    use yii\helpers\Url;
    use yii\web\NotFoundHttpException;
    use yii\web\UploadedFile;
    
    /**
     * Class SondaggiDomandePagineController
     * SondaggiDomandePagineController implements the CRUD actions for SondaggiDomandePagine model.
     *
     * @property \arter\amos\sondaggi\models\SondaggiDomandePagine $model
     * @property \arter\amos\sondaggi\models\search\SondaggiDomandePagineSearch $modelSearch
     *
     * @package arter\amos\sondaggi\controllers
     */
    class SondaggiDomandePagineController extends CrudController
    {
        /**
         * @var string $layout
         */
        public $layout = 'main';
    
        /**
         * @inheritdoc
         */
        public function init()
        {
            $this->setModelObj(new SondaggiDomandePagine());
            $this->setModelSearch(new SondaggiDomandePagineSearch());
    
            $this->setAvailableViews([
                'grid' => [
                    'name' => 'grid',
                    'label' => AmosIcons::show('view-list-alt') . Html::tag('p', AmosSondaggi::tHtml('amossondaggi', 'Tabella')),
                    'url' => '?currentView=grid'
                ]
            ]);
    
            parent::init();
    
            $this->setUpLayout();
        }
    
        /**
         * Set a view param used in \arter\amos\core\forms\CreateNewButtonWidget
         */
        protected function setCreateNewBtnParams()
        {
            $get = Yii::$app->request->get();