コード例 #1
0
 /**
  * function getListAccountPriviledgeAccess
  * <pre>
  * Returns a ListIterator for the list of accounts this viewer has access
  * to modify.
  * </pre>
  * @param $sortBy [STRING] the name of the field to sort by (can be a
  * comma seperated list).
  * @return [OBJECT]
  */
 function getListAccountPriviledgeAccess($sortBy)
 {
     $multiTable = new MultiTableManager();
     $genViewer = new RowManager_ViewerManager();
     $joinFieldA = $genViewer->getJoinOnViewerID();
     // if the current viewer is limited to the Group Access scope then
     // filter list based on current group.
     if ($this->hasGroupPriv()) {
         $viewerMgr = $this->getViewerManager();
         $genViewer->setAccountGroupID($viewerMgr->getAccountGroupID());
     }
     $multiTable->addRowManager($genViewer);
     $accessManager = new RowManager_AccountAdminAccessManager();
     $joinFieldB = $accessManager->getJoinOnViewerID();
     $joinPair = new JoinPair($joinFieldA, $joinFieldB);
     $multiTable->addRowManager($accessManager, $joinPair);
     $multiTable->constructSearchCondition('accountadminaccess_privilege', '<=', $this->getAccessPrivilege(), true);
     return $multiTable->getListIterator($sortBy);
 }