当前位置: 首页>>代码示例>>PHP>>正文


PHP _currentUser函数代码示例

本文整理汇总了PHP中_currentUser函数的典型用法代码示例。如果您正苦于以下问题:PHP _currentUser函数的具体用法?PHP _currentUser怎么用?PHP _currentUser使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了_currentUser函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: startExec

 public function startExec()
 {
     if (_currentUser()->isConnected()) {
         $userId = _currentUser()->getId();
         $userInfos = Kernel::getUserInfo('ID', $userId);
         $this->director = false;
         $this->animator = _currentUser()->hasAssistance();
         $this->idEn = isset($userInfos['id']) ? $userInfos['id'] : null;
         $this->id = $userId * 1;
         $this->type = isset($userInfos['type']) ? $userInfos['type'] : null;
         $this->root = false;
         $this->login = $userInfos['login'];
         $this->nom = $userInfos['nom'];
         $this->prenom = $userInfos['prenom'];
         $this->connected = true;
         $this->chartValid = isset($_SESSION['chartValid']) ? $_SESSION['chartValid'] : false;
     } else {
         $this->director = false;
         $this->animator = false;
         $this->id = 0;
         $this->type = 'USER_ANON';
         $this->root = false;
         $this->login = 'Anon';
         $this->nom = 'Anon';
         $this->prenom = 'Anon';
         $this->connected = false;
         $this->idEn = 0;
         $this->chartValid = true;
     }
 }
开发者ID:JVS-IS,项目名称:ICONITO-EcoleNumerique,代码行数:30,代码来源:enic.user.php

示例2: getModules

 public function getModules()
 {
     $my_modules = array();
     $nodes = Kernel::getMyNodes();
     if (sizeof($nodes)) {
         foreach ($nodes as $node_key => $node) {
             $modules = Kernel::getModEnabled($node->type, $node->id, _currentUser()->getExtra('type'), _currentUser()->getExtra('id'));
             foreach ($modules as $modules_key => $module) {
                 if ($module->module_type != "MOD_PREFS" && preg_match('#^MOD_(.+)$#', $module->module_type, $regs)) {
                     $mod_tmp = new CopixPPO();
                     $mod_tmp->type = $module->module_type;
                     $mod_tmp->nom = $module->module_nom;
                     $mod_tmp->rep = strtolower($regs[1]);
                     $my_modules[$module->module_type] = $mod_tmp;
                     unset($mod_tmp);
                 }
             }
         }
     }
     ksort($my_modules);
     $pref_module['MOD_PREFS'] = new CopixPPO();
     $pref_module['MOD_PREFS']->type = 'MOD_PREFS';
     $pref_module['MOD_PREFS']->nom = CopixI18N::get('prefs|prefs.string.generalprefs');
     $pref_module['MOD_PREFS']->rep = 'prefs';
     $all_modules = array_merge($pref_module, $my_modules);
     return $all_modules;
 }
开发者ID:JVS-IS,项目名称:ICONITO-EcoleNumerique,代码行数:27,代码来源:prefs.class.php

示例3: _createContent

 public function _createContent(&$toReturn)
 {
     $ppo = new CopixPPO();
     // Récupération des paramètres
     $ppo->nodeId = $this->getParam('nodeId');
     $ppo->nodeType = $this->getParam('nodeType');
     $ppo->cpt = $this->getParam('cpt');
     $ppo->studentId = $this->getParam('studentId', false);
     // Récupération des relations
     $parentLinkDAO = _ioDAO('kernel_bu_lien_parental');
     $parentLinks = $parentLinkDAO->findAll();
     $ppo->linkNames = array();
     $ppo->linkIds = array();
     foreach ($parentLinks as $parentLink) {
         $ppo->linkNames[] = $parentLink->parente;
         $ppo->linkIds[] = $parentLink->id_pa;
     }
     $ppo->genderNames = array('Homme', 'Femme');
     $ppo->genderIds = array('1', '2');
     // Récupération des responsables de l'élève
     if (false !== $ppo->studentId) {
         $personsInChargeDAO = _ioDAO('kernel|kernel_bu_res');
         $ppo->persons = $personsInChargeDAO->getByStudent($ppo->studentId);
     } else {
         // Récupération des responsables en session (devant être créés lors de la création de l'élève)
         $ppo->personsInSession = _sessionGet('modules|gestionautonome|tmpAccount');
     }
     $ppo->user = _currentUser();
     // Get vocabulary catalog to use
     $nodeVocabularyCatalogDAO = _ioDAO('kernel|kernel_i18n_node_vocabularycatalog');
     $ppo->vocabularyCatalog = $nodeVocabularyCatalogDAO->getCatalogForNode($ppo->nodeType, $ppo->nodeId);
     $toReturn = $this->_usePPO($ppo, '_create_person_in_charge.tpl');
 }
开发者ID:JVS-IS,项目名称:ICONITO-EcoleNumerique,代码行数:33,代码来源:createpersonincharge.zone.php

示例4: getZones

function getZones($position, $collapse = true, $dispmode = "STD")
{
    $module = CopixRequest::get('module');
    $user = _currentUser();
    $userstatus = $user->isConnected() ? 'connected' : 'visitor';
    $layout = getTheme("zones", $dispmode);
    $jzones_default = isset($layout->{$userstatus}->default->{$position}) ? $layout->{$userstatus}->default->{$position} : array();
    $jzones_module = isset($layout->{$userstatus}->{$module}->{$position}) ? $layout->{$userstatus}->{$module}->{$position} : array();
    $jzones = array_merge((array) $jzones_default, (array) $jzones_module);
    if (empty($jzones)) {
        if ($collapse) {
            echo '<div class="collapse"></div>';
        } else {
            echo '<div class="filler"></div>';
        }
    } else {
        foreach ($jzones as $zone) {
            if ($zone->params != "") {
                $params = $zone->params;
                $params = unserialize($params);
                $zoneContent = CopixZone::process($zone->supplier . '|' . $zone->zone, $params);
            } else {
                $zoneContent = CopixZone::process($zone->supplier . '|' . $zone->zone);
            }
            if (!$zoneContent) {
                continue;
            }
            $id = $position == 'popup' ? 'id="' . $module . '-' . $zone->zone . '" ' : '';
            echo '<div ' . $id . 'class="' . $module . ' ' . $zone->zone . '">';
            echo $zoneContent;
            echo '</div>';
        }
    }
}
开发者ID:JVS-IS,项目名称:ICONITO-EcoleNumerique,代码行数:34,代码来源:helper.php

示例5: processDefault

 public function processDefault()
 {
     $tpl = new CopixTpl();
     $tplModule = new CopixTpl();
     //if user is not connected :
     if (1) {
         // S'il y a un blog prevu a l'accueil
         $dispBlog = false;
         $getKernelLimitsIdBlog = Kernel::getKernelLimits('id_blog');
         if ($getKernelLimitsIdBlog) {
             _classInclude('blog|kernelblog');
             if ($blog = _ioDao('blog|blog')->getBlogById($getKernelLimitsIdBlog)) {
                 // On v�rifie qu'il y a au moins un article
                 $stats = KernelBlog::getStats($blog->id_blog);
                 if ($stats['nbArticles']['value'] > 0) {
                     $dispBlog = true;
                 }
             }
         }
         if ($dispBlog) {
             //return CopixActionGroup::process ('blog|frontblog::getListArticle', array ('blog'=>$blog->url_blog));
             return new CopixActionReturn(COPIX_AR_REDIRECT, CopixUrl::get('blog||', array('blog' => $blog->url_blog)));
         }
         if (!CopixConfig::exists('|can_public_rssfeed') || CopixConfig::get('|can_public_rssfeed')) {
             CopixHtmlHeader::addOthers('<link rel="alternate" href="' . CopixUrl::get('public||rss', array()) . '" type="application/rss+xml" title="' . htmlentities(CopixI18N::get('public|public.rss.flux.title')) . '" />');
         }
         CopixHTMLHeader::addCSSLink(_resource("styles/module_fichesecoles.css"));
         $tplModule->assign('user', _currentUser());
         $result = $tplModule->fetch('welcome|welcome_' . CopixI18N::getLang() . '.tpl');
         $tpl->assign('TITLE_PAGE', '' . CopixI18N::get('public|public.welcome.title'));
         $tpl->assign('MAIN', $result);
         return new CopixActionReturn(COPIX_AR_DISPLAY, $tpl);
     }
 }
开发者ID:JVS-IS,项目名称:ICONITO-EcoleNumerique,代码行数:34,代码来源:default.actiongroup.php

示例6: _createContent

 public function _createContent(&$toReturn)
 {
     $ppo = new CopixPPO();
     // Récupération des paramètres
     $ppo->cahierId = $this->getParam('cahierId');
     $ppo->jour = $this->getParam('date_jour');
     $ppo->mois = $this->getParam('date_mois');
     $ppo->annee = $this->getParam('date_annee');
     $ppo->eleve = $this->getParam('eleve');
     $time = mktime(0, 0, 0, $ppo->mois, $ppo->jour, $ppo->annee);
     $cahierInfos = Kernel::getModParent('MOD_CAHIERDETEXTES', $ppo->cahierId);
     $nodeId = isset($cahierInfos[0]) ? $cahierInfos[0]->node_id : null;
     $ppo->niveauUtilisateur = Kernel::getLevel('MOD_CAHIERDETEXTES', $ppo->cahierId);
     $estAdmin = $ppo->niveauUtilisateur >= PROFILE_CCV_PUBLISH ? true : false;
     // Récupération des mémos suivant les accès de l'utilisateur courant (élève / responsable / enseignant)
     $memoDAO = _ioDAO('cahierdetextes|cahierdetextesmemo');
     if ($estAdmin) {
         $ppo->memos = $memoDAO->findByClasse($nodeId, true);
     } elseif (Kernel::getLevel('MOD_CAHIERDETEXTES', $ppo->cahierId) == PROFILE_CCV_READ) {
         $ppo->memos = $memoDAO->findByEleve($ppo->eleve, true);
     } else {
         $ppo->memos = $memoDAO->findByEleve(_currentUser()->getExtra('id'), true);
     }
     $toReturn = $this->_usePPO($ppo, '_memos.tpl');
 }
开发者ID:JVS-IS,项目名称:ICONITO-EcoleNumerique,代码行数:25,代码来源:memos.zone.php

示例7: _createContent

 public function _createContent(&$toReturn)
 {
     $ppo = new CopixPPO();
     _classInclude('classeur|ClasseurService');
     // Récupération des paramètres
     $ppo->classeurId = $this->getParam('classeurId');
     $ppo->dossierId = $this->getParam('dossierId');
     // Gestion des droits
     $ppo->niveauUtilisateur = Kernel::getLevel('MOD_CLASSEUR', $ppo->classeurId);
     $ppo->typeUtilisateur = _currentUser()->getExtra('type');
     $ppo->idUtilisateur = _currentUser()->getExtra('id');
     // Récupération des paramètres d'affichages
     $ppo->tri = ClasseurService::getContentSort();
     // Récupération des dossiers & des fichiers / favoris
     $dossierDAO = _ioDAO('classeur|classeurdossier');
     if ($ppo->dossier = $dossierDAO->get($ppo->dossierId)) {
         if ($ppo->dossier->parent_id != 0) {
             $ppo->dossierParent = $dossierDAO->get($ppo->dossier->parent_id);
         } else {
             $classeurDAO = _ioDAO('classeur|classeur');
             $ppo->classeurParent = $classeurDAO->get($ppo->classeurId);
             $ppo->classeurParent->isPersonnel = ClasseurService::getClasseurPersonnelId() == $ppo->classeurParent->id;
         }
     }
     if (!$ppo->dossier->casier || $ppo->niveauUtilisateur >= PROFILE_CCV_MODERATE) {
         $ppo->contenus = $dossierDAO->getContenus($ppo->classeurId, $ppo->dossierId, $ppo->tri);
         foreach ($ppo->contenus as $contenu) {
             if ($ppo->dossier->casier) {
                 $user = Kernel::getUserInfo($contenu->user_type, $contenu->user_id);
                 $contenu->user = $user['prenom'] . ' ' . $user['nom'];
             }
         }
     }
     $toReturn = $this->_usePPO($ppo, '_vue_liste.tpl');
 }
开发者ID:JVS-IS,项目名称:ICONITO-EcoleNumerique,代码行数:35,代码来源:vueliste.zone.php

示例8: _createContent

 public function _createContent(&$toReturn)
 {
     $ppo = new CopixPPO();
     // Récupération des paramètres
     $ppo->cahierId = $this->getParam('cahierId');
     $ppo->jour = $this->getParam('date_jour');
     $ppo->mois = $this->getParam('date_mois');
     $ppo->annee = $this->getParam('date_annee');
     $ppo->vue = $this->getParam('vue');
     $ppo->eleve = $this->getParam('eleve');
     $time = mktime(0, 0, 0, $ppo->mois, $ppo->jour, $ppo->annee);
     $cahierInfos = Kernel::getModParent('MOD_CAHIERDETEXTES', $ppo->cahierId);
     $nodeId = isset($cahierInfos[0]) ? $cahierInfos[0]->node_id : null;
     $ppo->estAdmin = Kernel::getLevel('MOD_CAHIERDETEXTES', $ppo->cahierId) >= PROFILE_CCV_PUBLISH ? true : false;
     // Récupération des travaux suivant les accès de l'utilisateur courant (élève / responsable / enseignant)
     $travailDAO = _ioDAO('cahierdetextes|cahierdetextestravail');
     if ($ppo->estAdmin) {
         $ppo->travaux = $travailDAO->findByClasseEtTypeDeTravail($nodeId, DAOCahierDeTextesTravail::TYPE_EN_CLASSE, $time);
     } elseif (Kernel::getLevel('MOD_CAHIERDETEXTES', $ppo->cahierId) == PROFILE_CCV_READ) {
         $ppo->travaux = $travailDAO->findByEleveEtTypeDeTravail($ppo->eleve, DAOCahierDeTextesTravail::TYPE_EN_CLASSE, $time);
     } else {
         $ppo->travaux = $travailDAO->findByEleveEtTypeDeTravail(_currentUser()->getExtra('id'), DAOCahierDeTextesTravail::TYPE_EN_CLASSE, $time);
     }
     $toReturn = $this->_usePPO($ppo, '_travaux_en_classe.tpl');
 }
开发者ID:JVS-IS,项目名称:ICONITO-EcoleNumerique,代码行数:25,代码来源:travauxenclasse.zone.php

示例9: _createContent

 public function _createContent(&$toReturn)
 {
     $ppo = new CopixPPO();
     // Récupérations des filtres en session
     $ppo->selected = $this->getParam('selected', null);
     $ppo->withLabel = $this->getParam('with_label', true);
     $ppo->withEmpty = $this->getParam('with_empty', true);
     $ppo->labelEmpty = $this->getParam('label_empty', null);
     $ppo->name = $this->getParam('name', null);
     $ppo->all = $this->getParam('all', false);
     if (!is_null($schoolId = $this->getParam('school_id', null))) {
         // Récupération des niveaux de la classe sélectionnée pour liste déroulante
         $classroomLevelDAO = _ioDAO('kernel|kernel_bu_classe_niveau');
         $classroomId = $this->getParam('classroom_id', null);
         if (is_null($classroomId)) {
             if (_currentUser()->testCredential('module:school|' . $schoolId . '|classroom|create@gestionautonome') || $ppo->all) {
                 $niveaux = $classroomLevelDAO->findBySchoolId($schoolId, $this->getParam('grade', null));
             } else {
                 $groups = _currentUser()->getGroups();
                 $niveaux = $classroomLevelDAO->findBySchoolIdAndUserGroups($schoolId, $groups['gestionautonome|iconitogrouphandler'], $this->getParam('grade', null));
             }
         } else {
             $niveaux = $classroomLevelDAO->findByClassId($classroomId);
         }
         $ppo->niveauxIds = array();
         $ppo->niveauxNames = array();
         foreach ($niveaux as $niveau) {
             $ppo->niveauxIds[] = $niveau->id_n;
             $ppo->niveauxNames[] = $niveau->niveau_court;
         }
     }
     $toReturn = $this->_usePPO($ppo, '_filter_classlevel.tpl');
 }
开发者ID:JVS-IS,项目名称:ICONITO-EcoleNumerique,代码行数:33,代码来源:filterclasslevel.zone.php

示例10: _createContent

 public function _createContent(&$toReturn)
 {
     $ppo = new CopixPPO();
     $ppo->conf = new CopixPPO();
     $ppo->conf->directorGlobalAffectation = CopixConfig::get('gestionautonome|directorGlobalAffectation');
     // Récupérations des filtres en session
     $ppo->selected = $this->getParam('selected', null);
     $ppo->withLabel = $this->getParam('with_label', true);
     $ppo->withEmpty = $this->getParam('with_empty', true);
     $ppo->name = $this->getParam('name', null);
     if (!is_null($cityId = $this->getParam('city_id', null))) {
         // Récupération des écoles de la ville sélectionnée pour liste déroulante
         $schoolDAO = _dao('kernel|kernel_bu_ecole');
         if (_currentUser()->testCredential('module:city|' . $cityId . '|school|create@gestionautonome') || _currentUser()->isDirector && $ppo->conf->directorGlobalAffectation) {
             $schools = $schoolDAO->getByCity($cityId);
         } else {
             $groups = _currentUser()->getGroups();
             $schools = $schoolDAO->findByCityIdAndUserGroups($cityId, $groups['gestionautonome|iconitogrouphandler']);
         }
         $ppo->schoolsIds = array();
         $ppo->schoolsNames = array();
         foreach ($schools as $school) {
             $ppo->schoolsIds[] = $school->numero;
             $ppo->schoolsNames[] = $school->nom;
         }
     }
     $toReturn = $this->_usePPO($ppo, '_filter_school.tpl');
 }
开发者ID:JVS-IS,项目名称:ICONITO-EcoleNumerique,代码行数:28,代码来源:filterschool.zone.php

示例11: go

 /**
  * go
  *
  * Appel automatique, avec détection du noeud à afficher.
  * @author	Frédéric Mossmann
  * @since	10.03.2009
  *
  */
 public function go()
 {
     if (!Kernel::is_connected()) {
         return CopixActionGroup::process('genericTools|Messages::getError', array('message' => CopixI18N::get('kernel|kernel.error.nologin'), 'back' => CopixUrl::get('auth|default|login')));
     }
     CopixHtmlHeader::addJSLink(CopixUrl::get() . 'js/iconito/module_concerto.js');
     if (!_request("id") || !ereg('^[0-9]+$', _request("id"))) {
         return new CopixActionReturn(COPIX_AR_REDIRECT, CopixUrl::get('kernel||getNodes'));
     }
     $sql = 'SELECT login,password FROM kernel_bu_auth WHERE node_type=\'responsable\' AND node_id=' . _currentUser()->getExtra('id') . ' AND id=\'' . addslashes(_request("id")) . '\' AND service=\'concerto\'';
     $concerto = _doQuery($sql);
     if (!$concerto) {
         return new CopixActionReturn(COPIX_AR_REDIRECT, CopixUrl::get('kernel||getNodes'));
     }
     $tpl = new CopixTpl();
     $tpl->assign('TITLE_PAGE', CopixI18N::get('concerto|concerto.title'));
     // $tpl->assign ('MENU', '<a href="'.CopixUrl::get ('groupe||getListPublic').'">'.CopixI18N::get ('groupe|groupe.annuaire').'</a> :: <a href="'.CopixUrl::get ('groupe||getListMy').'">'.CopixI18N::get ('groupe|groupe.my').'</a>');
     $tplListe = new CopixTpl();
     $tplListe->assign('login', $concerto[0]->login);
     $tplListe->assign('password', $concerto[0]->password);
     $result = $tplListe->fetch("concerto-form.tpl");
     $tpl->assign("MAIN", $result);
     $tpl->assign('BODY_ON_LOAD', 'concerto_redirect();');
     return new CopixActionReturn(COPIX_AR_DISPLAY, $tpl);
 }
开发者ID:JVS-IS,项目名称:ICONITO-EcoleNumerique,代码行数:33,代码来源:concerto.actiongroup.php

示例12: _createContent

 public function _createContent(&$toReturn)
 {
     $ppo = new CopixPPO();
     // Récupération des paramètres
     $ppo->classeurId = $this->getParam('classeurId');
     $ppo->dossierId = $this->getParam('dossierId');
     $ppo->current = $this->getParam('current');
     // Gestion des droits
     $ppo->niveauUtilisateur = Kernel::getLevel('MOD_CLASSEUR', $ppo->classeurId);
     $ppo->typeUtilisateur = _currentUser()->getExtra('type');
     $ppo->vue = !is_null(_sessionGet('classeur|typeVue')) ? _sessionGet('classeur|typeVue') : 'liste';
     $ppo->conf_ModClasseur_options = CopixConfig::exists('default|conf_ModClasseur_options') ? CopixConfig::get('default|conf_ModClasseur_options') : 0;
     // L'album public est t-il publié ?
     $ppo->estPublic = false;
     if (!is_null($ppo->dossierId) && $ppo->dossierId != 0) {
         $dossierDAO = _ioDAO('classeur|classeurdossier');
         $ppo->dossier = $dossierDAO->get($ppo->dossierId);
         if ($ppo->dossier->public) {
             $ppo->estPublic = true;
         }
     } else {
         $classeurDAO = _ioDAO('classeur|classeur');
         $classeur = $classeurDAO->get($ppo->classeurId);
         if ($classeur->public) {
             $ppo->estPublic = true;
         }
     }
     $toReturn = $this->_usePPO($ppo, '_affichage_menu.tpl');
 }
开发者ID:JVS-IS,项目名称:ICONITO-EcoleNumerique,代码行数:29,代码来源:affichagemenu.zone.php

示例13: _createContent

 public function _createContent(&$toReturn)
 {
     $ppo = new CopixPPO();
     $ppo->conf = new CopixPPO();
     $ppo->conf->directorGlobalAffectation = CopixConfig::get('gestionautonome|directorGlobalAffectation');
     // Récupérations des filtres en session
     $ppo->selected = $this->getParam('selected', null);
     $ppo->withLabel = $this->getParam('with_label', true);
     $ppo->withEmpty = $this->getParam('with_empty', true);
     $ppo->labelEmpty = $this->getParam('label_empty', null);
     $ppo->name = $this->getParam('name', null);
     if (!is_null($cityGroupId = $this->getParam('city_group_id', null))) {
         $cityDAO = _dao('kernel|kernel_bu_ville');
         if (_currentUser()->testCredential('module:cities_group|' . $cityGroupId . '|city|create@gestionautonome') || _currentUser()->isDirector && $ppo->conf->directorGlobalAffectation) {
             $cities = $cityDAO->getByIdGrville($cityGroupId);
         } else {
             $groups = _currentUser()->getGroups();
             $cities = $cityDAO->findByCitiesGroupIdAndUserGroups($cityGroupId, $groups['gestionautonome|iconitogrouphandler']);
         }
         $ppo->citiesIds = array();
         $ppo->citiesNames = array();
         foreach ($cities as $city) {
             $ppo->citiesIds[] = $city->id_vi;
             $ppo->citiesNames[] = $city->nom;
         }
     }
     $toReturn = $this->_usePPO($ppo, '_filter_city.tpl');
 }
开发者ID:JVS-IS,项目名称:ICONITO-EcoleNumerique,代码行数:28,代码来源:filtercity.zone.php

示例14: _createContent

 public function _createContent(&$toReturn)
 {
     $ppo = new CopixPPO();
     // Récupérations des filtres en session
     $ppo->selected = $this->getParam('selected', null);
     $ppo->withLabel = $this->getParam('with_label', true);
     $ppo->withEmpty = $this->getParam('with_empty', true);
     $ppo->labelEmpty = $this->getParam('label_empty', null);
     $ppo->name = $this->getParam('name', null);
     $ppo->all = $this->getParam('all', false);
     $grade = $this->getParam('grade', _sessionGet('grade', Kernel::getAnneeScolaireCourante()->id_as));
     if (!is_null($schoolId = $this->getParam('school_id', null))) {
         // Récupération des écoles de la ville sélectionnée pour liste déroulante
         $classroomDAO = _ioDAO('kernel|kernel_bu_ecole_classe');
         if (_currentUser()->testCredential('module:school|' . $schoolId . '|classroom|create@gestionautonome') || $ppo->all) {
             $classes = $classroomDAO->getBySchool($schoolId, $grade);
         } else {
             $groups = _currentUser()->getGroups();
             $classes = $classroomDAO->findBySchoolIdAndUserGroups($schoolId, $groups['gestionautonome|iconitogrouphandler'], $grade);
         }
         $ppo->classesIds = array();
         $ppo->classesNames = array();
         foreach ($classes as $class) {
             $ppo->classesIds[] = $class->id;
             $ppo->classesNames[] = $class->nom;
         }
     }
     $toReturn = $this->_usePPO($ppo, '_filter_class.tpl');
 }
开发者ID:JVS-IS,项目名称:ICONITO-EcoleNumerique,代码行数:29,代码来源:filterclass.zone.php

示例15: _createContent

 public function _createContent(&$toReturn)
 {
     //load PPO
     $ppo = new CopixPPO();
     $ppo->user = _currentUser();
     //if user is connected : load personal informations
     if ($ppo->user->isConnected()) {
         $ppo->animateur = _sessionGet('user_animateur') ? 1 : 0;
         $ppo->ien = _sessionGet('prisedecontrole_ien') ? 1 : 0;
         $type = $ppo->user->getExtra('type');
         $sexe = $ppo->user->getExtra('sexe') == 2 ? 2 : '';
         $ppo->usertype = strtolower($type) . $sexe;
     }
     // Get vocabulary catalog to use
     if ($myNode = CopixSession::get('myNode')) {
         $nodeVocabularyCatalogDAO = _ioDAO('kernel|kernel_i18n_node_vocabularycatalog');
         $vocabularyCatalog = $nodeVocabularyCatalogDAO->getCatalogForNode($myNode['type'], $myNode['id']);
     }
     $ppo->vocabularyCatalogId = isset($vocabularyCatalog) ? $vocabularyCatalog->id_vc : CopixConfig::get('kernel|defaultVocabularyCatalog');
     $this->addJs('js/iconito/module_auth.js');
     $this->addCss('styles/module_auth.css');
     $ppo->conf_Cas_actif = CopixConfig::exists('default|conf_Cas_actif') ? CopixConfig::get('default|conf_Cas_actif') : 0;
     $ppo->conf_Saml_actif = CopixConfig::exists('default|conf_Saml_actif') ? CopixConfig::get('default|conf_Saml_actif') : 0;
     //load tpl
     $toReturn = $this->_usePPO($ppo, 'userlogged.tpl');
 }
开发者ID:JVS-IS,项目名称:ICONITO-EcoleNumerique,代码行数:26,代码来源:userlogged.zone.php


注:本文中的_currentUser函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。