Disabled acl for dynamic cms pages
authorMarcel Werk <burntime@woltlab.com>
Fri, 24 Jun 2016 09:37:05 +0000 (11:37 +0200)
committerMarcel Werk <burntime@woltlab.com>
Fri, 24 Jun 2016 09:37:05 +0000 (11:37 +0200)
wcfsetup/install/files/acp/templates/pageAdd.tpl
wcfsetup/install/files/lib/acp/form/PageEditForm.class.php

index 5a132e68dfb53ecdc8e159f6fb09d2d20c13fbe9..6d2f12725a12b2a329d39626931591ecc4b39e92 100644 (file)
                                <li><a href="{@$__wcf->getAnchor('general')}">{lang}wcf.acp.page.general{/lang}</a></li>
                                <li><a href="{@$__wcf->getAnchor('contents')}">{lang}wcf.acp.page.contents{/lang}</a></li>
                                <li><a href="{@$__wcf->getAnchor('boxes')}">{lang}wcf.acp.page.boxes{/lang}</a></li>
-                               <li><a href="{@$__wcf->getAnchor('acl')}">{lang}wcf.acp.page.acl{/lang}</a></li>
+                               
+                               {if $action != 'edit' || $page->pageType != 'system'}
+                                       <li><a href="{@$__wcf->getAnchor('acl')}">{lang}wcf.acp.page.acl{/lang}</a></li>
+                               {/if}
                                
                                {event name='tabMenuTabs'}
                        </ul>
                        </div>
                </div>
                
-               <div id="acl" class="tabMenuContent">
-                       {include file='aclSimple'}
-               </div>
-       </div>  
+               {if $action != 'edit' || $page->pageType != 'system'}
+                       <div id="acl" class="tabMenuContent">
+                               {include file='aclSimple'}
+                       </div>
+               {/if}
+       </div>
        
        <div class="formSubmit">
                <input type="submit" value="{lang}wcf.global.button.submit{/lang}" accesskey="s">
index 94511417afa3b62abfbd8bc0d3236b3e62c78f0a..b067afbe208b54d575115bffb5928a20dffd86d4 100644 (file)
@@ -178,7 +178,9 @@ class PageEditForm extends PageAddForm {
                }
                
                // save acl
-               SimpleAclHandler::getInstance()->setValues('com.woltlab.wcf.page', $this->page->pageID, $this->aclValues);
+               if ($this->page->pageType != 'system') {
+                       SimpleAclHandler::getInstance()->setValues('com.woltlab.wcf.page', $this->page->pageID, $this->aclValues);
+               }
                
                // call saved event
                $this->saved();