Source for file delete_group.act.php

Documentation is available at delete_group.act.php

  1. <?php
  2.  
  3. /**
  4. * delete_group.act.php
  5. * This action will delete the group as specified by add_delete_group.act.php
  6. * 11/29/04 Ryan Richards
  7. *
  8. * @package polyphony.agents
  9. *
  10. * @copyright Copyright &copy; 2005, Middlebury College
  11. * @license http://www.gnu.org/copyleft/gpl.html GNU General Public License (GPL)
  12. *
  13. * @version $Id: delete_group.act.php,v 1.11 2007/09/19 14:04:52 adamfranco Exp $
  14. */
  15.  
  16. $harmoni->request->startNamespace("polyphony-agents");
  17. $harmoni->request->passthrough("expandedGroups");
  18.  
  19. // Get services
  20. $agentManager = Services::getService("Agent");
  21. $authZ = Services::getService("AuthZ");
  22. $ids = Services::getService("Id");
  23.  
  24. // Get info passed to this action via the URL
  25. $idString = $harmoni->request->get("groupId");
  26.  
  27. // check our authorization
  28. if ($authZ->isUserAuthorized($ids->getId("edu.middlebury.authorization.delete"), $ids->getId($idString))) {
  29. $agentManager->deleteGroup($ids->getId($idString));
  30. }
  31.  
  32. // Send us back to where we were (add_delete_group.php)
  33.  
  34. $harmoni->request->endNamespace();
  35.  
  36. $harmoni->history->goBack("polyphony/agents/delete_group");
  37.  
  38. // Delete the given group
  39. //$shared->deleteGroup($groupId);

Documentation generated on Wed, 19 Sep 2007 10:22:43 -0400 by phpDocumentor 1.3.0RC3