diff --git a/wiki/macro/AllPagesWithACL.py b/wiki/macro/AllPagesWithACL.py new file mode 100644 index 00000000..dd3c48f1 --- /dev/null +++ b/wiki/macro/AllPagesWithACL.py @@ -0,0 +1,53 @@ +# -*- coding: utf-8 -*- +""" + MoinMoin - AllPagesWithACL Macro + + @copyright: 2007 Alexander "Loki" Agibalov + @license: GNU GPL, see COPYING for details. + + changes: + 12.2007 - conversion to new syntax by Bolesław Kulbabiński +""" + +import os +import re +from MoinMoin.Page import Page +from MoinMoin import wikiutil + +def getAcl(request, pagename): + pg = Page(request, pagename) + pi = pg.get_pi() + ret = pi["acl"].getString() + if ret == '': + ret = "not defined" + return ret + + +def macro_AllPagesWithACL(macro, args): + html = "
All pages:
"
+ all = {}
+ pages = macro.request.rootpage.getPageList()
+# pages = macro.request.rootpage.getPageList(filter = re.compile("^WikiSandBox").match)
+ html += "Total: %s pages
%s | " % pg + html += "%s |