Esempio n. 1
0
 public function setnevAction()
 {
     $clubid = $this->user->getId();
     $nvd = new Application_Model_Nevdata();
     $nev = $nvd->nevsetSelect($clubid);
     $nevlocations = $nvd->getNevlocations($clubid);
     if ($this->user->nev) {
         $continent = $nvd->getContinent($clubid);
         if ($continent == 1) {
             $nevtype = "Ufc";
         } elseif ($continent == 2) {
             $nevtype = "Snf";
         } elseif ($continent == 3) {
             $nevtype = "Jv";
         } elseif ($continent == 0) {
             $nevtype = "show";
         }
     }
     if ($this->user->nev) {
         $autotype = "Nev";
     }
     if ($this->user->abc) {
         $autotype = "Abc";
         $nevtype = "hide";
     }
     if (count($nevlocations) != 0) {
         $bloc = TRUE;
     }
     if ($bloc) {
         reset($nevlocations);
         $key = key($nevlocations);
         $nevsetup = $nvd->nevsetSelect($key);
     } else {
         $nevsetup = $nev;
     }
     //     echo $autotype;
     $this->view->nevsetup = $nevsetup;
     $this->view->locations = $nevlocations;
     $this->view->bloc = $bloc;
     $this->view->autotype = $autotype;
     $this->view->nevtype = $nevtype;
     $this->view->continent = $continent;
 }