ActionHandler/Alumni.php

Go to the documentation of this file.
00001 <?php
00003 // {{{ license
00004 
00005 // +----------------------------------------------------------------------+
00006 // | FastFrame Application Framework                                      |
00007 // +----------------------------------------------------------------------+
00008 // | Copyright (c) 2002-2006 The Codejanitor Group                        |
00009 // +----------------------------------------------------------------------+
00010 // | This source file is subject to the GNU Lesser Public License (LGPL), |
00011 // | that is bundled with this package in the file LICENSE, and is        |
00012 // | available at through the world-wide-web at                           |
00013 // | http://www.fsf.org/copyleft/lesser.html                              |
00014 // | If you did not receive a copy of the LGPL and are unable to          |
00015 // | obtain it through the world-wide-web, you can get it by writing the  |
00016 // | Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, |
00017 // | MA 02111-1307, USA.                                                  |
00018 // +----------------------------------------------------------------------+
00019 // | Authors: Jason Rust <jrust@codejanitor.com>                          |
00020 // | Authors: Greg Gilbert <ggilbert@codejanitor.com>                          |
00021 // +----------------------------------------------------------------------+
00022 
00023 // }}}
00024 // {{{ requires
00025 
00026 require_once FASTFRAME_ROOT . 'lib/FastFrame/ActionHandlerConfig.php';
00027 require_once dirname(__FILE__) . '/../Model/Alumni.php';
00028 require_once dirname(__FILE__) . '/actions.php';
00029 
00030 // }}}
00031 // {{{ class FF_ActionHandlerConfig_Alumni
00032 
00044 // }}}
00045 class FF_ActionHandlerConfig_Alumni extends FF_ActionHandlerConfig {
00046     // {{{ loadConfig()
00047 
00054     function loadConfig()
00055     {
00056         $appName = $this->actionHandler->o_registry->getCurrentApp();
00057         if ($this->actionHandler->getActionId() == ACTION_DISPLAY_LINKS) {
00058             $s_imgName = 't_links.gif';
00059         }
00060         elseif ($this->actionHandler->getActionId() == ACTION_LIST_EMAILS) {
00061             $s_imgName = 't_email.gif';
00062         }
00063         else {
00064             $s_imgName = 't_search.gif';
00065         }
00066 
00067         $o_output =& FF_Output::factory();
00068         $o_output->o_tpl->assign('I_title', $o_output->imgTag(
00069                     $s_imgName, 'title', array('app' => $appName)));
00070         $this->actionHandler->setDefaultActionId(ACTION_LIST);
00071         $this->actionHandler->addAction(
00072             ACTION_LIST, 
00073             $this->actionHandler->o_registry->getAppFile('Action/AlumniList.php', $appName, 'libs'), 
00074             'FF_Action_List_Alumni'
00075         );
00076         $this->actionHandler->addAction(
00077             ACTION_DISPLAY_LINKS, 
00078             $this->actionHandler->o_registry->getAppFile('Action/AlumniLinks.php', $appName, 'libs'), 
00079             'FF_Action_Display_Links'
00080         );
00081         $this->actionHandler->addAction(
00082             ACTION_CONTACT, 
00083             $this->actionHandler->o_registry->getAppFile('Action/Contact.php', $appName, 'libs'), 
00084             'FF_Action_AlumContact'
00085         );
00086         $this->actionHandler->addAction(
00087             ACTION_CONTACT_SUBMIT, 
00088             $this->actionHandler->o_registry->getAppFile('Action/ContactSubmit.php', $appName, 'libs'), 
00089             'FF_Action_AlumContactSubmit'
00090         );
00091         $this->actionHandler->o_model =& new FF_Model_Alumni();
00092     }
00093 
00094     // }}}
00095     // {{{ hasCheckAuth
00096 
00103     function hasCheckAuth() 
00104     {
00105         return true;
00106     }
00107 
00108     // }}}
00109     // {{{ checkAuth()
00110 
00118     function checkAuth() 
00119     {
00120         if ($this->actionHandler->getActionId() != ACTION_DISPLAY_LINKS) {
00121             $this->actionHandler->checkAuth(true);
00122         }
00123     }
00124 
00125     // }}}
00126 }
00127 ?>

Generated on Fri Jun 23 11:38:14 2006 for FastFrame by  doxygen 1.4.4