예제 #1
0
 /**
  * @see \C5TL\Parser\DynamicItem::parseManual()
  */
 public function parseManual(\Gettext\Translations $translations, $concrete5version)
 {
     if (class_exists('\\PermissionKeyCategory', true) && method_exists('\\PermissionKeyCategory', 'getList')) {
         foreach (\PermissionKeyCategory::getList() as $pkc) {
             $pkcHandle = $pkc->getPermissionKeyCategoryHandle();
             foreach (\PermissionKey::getList($pkcHandle) as $pk) {
                 $this->addTranslation($translations, $pk->getPermissionKeyName(), 'PermissionKeyName');
                 $this->addTranslation($translations, $pk->getPermissionKeyDescription(), 'PermissionKeyDescription');
             }
         }
     }
 }
예제 #2
0
파일: key.php 프로젝트: Zyqsempai/amanet
 public static function exportList($xml)
 {
     $categories = PermissionKeyCategory::getList();
     $pxml = $xml->addChild('permissionkeys');
     foreach ($categories as $cat) {
         $permissions = PermissionKey::getList($cat->getPermissionKeyCategoryHandle());
         foreach ($permissions as $p) {
             $p->export($pxml);
         }
     }
 }