Short description Similiar to the @ME extension of NewPage which does create on the users Homepage a new page this feature request is to create a page below the page where it is called from.
This could then easily used to create comment or discussion pages below a main page
1 # HG changeset patch
2 # User ReimarBauer <R.Bauer@fz-juelich.de>
3 # Node ID ee9495472b6eb1c9f9e4c65df1834f323beb98eb
4 # Parent 107ca03adb3cb596454dc8e44fdd996d94b26b30
5 added @SELF to NewPage to autocreate subpages of page where it is called from
6
7 diff -r 107ca03adb3c -r ee9495472b6e MoinMoin/macro/NewPage.py
8 --- a/MoinMoin/macro/NewPage.py Wed Aug 23 22:35:01 2006 +0200
9 +++ b/MoinMoin/macro/NewPage.py Wed Aug 23 23:19:21 2006 +0200
10 @@ -78,6 +78,8 @@ class NewPage:
11
12 if parent == '@ME' and self.request.user.valid:
13 parent = self.request.user.name
14 + if parent == '@SELF':
15 + parent = f.page.page_name
16
17 requires_input = '%s' in nametemplate
18
called: [[NewPage(template,Discussion,@SELF,Discussion)]]
- Applied in 1.6
How could this be localized (e.g. discussion in English, Diskussion in German, and so on), and integrated somewhere in the GUI (e.g. "more actions" menu)? -- MartinBayer 2006-08-24 15:03:25
localisation should work as far as I could see in the code
if label: # Try to get a translation, this will probably not work in # most case, but better than nothing. label = _(label)
it tries to get a translation, moment it needs to be added for nametemplate too.This is only the macro extension. I did this first because at this point it could be generic solved to get several pages created with one macro. I believe you are asking about an action macro. So we need a new action macro for each sub page type if we don't want parameters added by a form. These action macros could be added then to a theme. But I am not sure if it is wanted on the modern theme. Do you see this as an important feature for your wikis if it's provided as action macro or do you need it added to the theme? However the action macros have to be written before. What types are needed? Please less types and short names for them. -- ReimarBauer 2006-08-24 15:31:04
You are right, this shouldn't be discussed here, as your extension is generic, but on the feature request page linked below, sorry. -- MartinBayer 2006-08-24 18:16:40
I've added on that page an example for an action macro. Please verify if you can use it, cheers -- ReimarBauer 2006-08-25 14:26:19
I'm sorry I can't test it, because I'm not running my wiki by myself, I have a managed wiki hosting instead (guess where). But isn't there a MoinMoin wiki playground? -- MartinBayer 2006-08-26 16:04:50
You can do this easily with the DesktopEdition. -- ReimarBauer 2006-08-27 10:09:02
Related Issue: FeatureRequests/DiscussionAndOrCommentPages
CategoryFeatureImplemented in 1.6-dev still no backport to 1.5