diff options
| author | Bharat Mediratta <bharat@menalto.com> | 2008-12-31 09:04:18 +0000 | 
|---|---|---|
| committer | Bharat Mediratta <bharat@menalto.com> | 2008-12-31 09:04:18 +0000 | 
| commit | 48e91e71e50fcf750ecd3d04deee488944c8e25a (patch) | |
| tree | d676aac20314d99dbbfe8e535666ae8d467a57cf /core/views/permissions_edit.html.php | |
| parent | 610494296b7cb52e52ebcc99246bb48da9252546 (diff) | |
Rename permission_xxx to permissions_xxx for consistency
Diffstat (limited to 'core/views/permissions_edit.html.php')
| -rw-r--r-- | core/views/permissions_edit.html.php | 38 | 
1 files changed, 38 insertions, 0 deletions
| diff --git a/core/views/permissions_edit.html.php b/core/views/permissions_edit.html.php new file mode 100644 index 00000000..ee561091 --- /dev/null +++ b/core/views/permissions_edit.html.php @@ -0,0 +1,38 @@ +<?php defined("SYSPATH") or die("No direct script access.") ?> +<script src="<?= url::file("lib/jquery.js") ?>" type="text/javascript"></script> +<script type="text/javascript"> +  show = function(id, form_url) { +    $.ajax({ +      url: form_url, +      success: function(data) { +        $("div.form").slideUp(); +        var el = $("div#edit-" + id); +        el.html(data).slideDown(); +      } +    }); +  } +</script> +<div id="gPermissions"> +  <ul> +    <? foreach ($parents as $parent): ?> +    <li> +      <a href="javascript:show(<?= $parent->id ?>,'<?= url::site("permissions/form/$parent->id") ?>')"> +        <?= $parent->title ?> +      </a> +      <div class="form" id="edit-<?= $parent->id ?>"></div> +      <ul> +        <? endforeach ?> +        <li> +          <a href="javascript:show(<?= $item->id ?>,'<?= url::site("permissions/form/$item->id") ?>')"> +            <?= $item->title ?> +          </a> +          <div class="form" id="edit-<?= $item->id ?>"> +            <?= $form ?> +          </div> +        </li> +        <? foreach ($parents as $parent): ?> +      </ul> +    </li> +  </ul> +  <? endforeach ?> +</div> | 
