Feature Proposal: Add a mechanism to make bulk updates directly from the browser
Many advanced users/sys admins often need to perform some kind of update in several topics at once: URL updates, form field updates, etc. It's possible to use sed, vi or any other text editor to perform this on
files. It would be very nice if users could perform this kind of task direct from the browser:
- No shell access to the server
- Version control is in place to undo the change and to keep audit trails
files will be possible as long as the flat storage mechanism is in place. Database backends will not have this flexibility that easily. This is also where this feature takes place: it is usefull with any sotorage mechanism in use.
Description and Documentation
Foswiki would support the action:
UPDATE <set-of-topics> WITH
<set-of-topics> is a list of topic names or a formatted
SEARCH that procduces a list of topic names.
is the operation to perform: search&replace, form updates, etc.
The user interface could be a wizard topic that lists the topics that will change and previews with the change before the commit. This topic could also be used to undo the action if its proved wrong...
Maybe this feature can be implemented as an extension (I'm not sure if
give extensions enough power). Let's mature the idea befre coding it
-- Contributors: GilmarSantosJr
- 15 Apr 2010
Have you had a look at Kenneth's MultiTopicSavePlugin
Seems to do some/most of what you want.
- 15 Apr 2010
At the moment it can only edit form fields.
But I have ideas to extend it with also doing the text content as a giant textarea field.
- 19 Apr 2010
does some of this, although it desperately needs some TLC.
As for coming up with something other than regex in the
part, it seems to me we should use the new ResultSets
stuff a bit more and explore some best practices to separate formatting from search. It's difficult to do complex "piping" of one macro to another isn't hopelessly confined to parameter "$quot$dollarstrings$quot".
"<action>" I suppose could do some sed-like operations with the new VarENCODE
proposal); I suppose I'm having trouble imagining what the action would really look like. Perhaps a version of VarQUERY
proposal) that will set instead of get?
Or are we expecting to simply implement regex actions? In which case this idea is much easier to implement, but not necessarily user friendly.
Personally I would like to see a nice interactive way of selecting topics to perform actions upon (these actions might be to set ACLs, rename, move, etc). I'm not sure how many of you used an Amiga in a previous life, but it had this thing called Directory Opus - a slightly different paradigm to the current windows explorer shell way of doing things: you sort of "tagged" (selected) stuff in the left pane, and the right pane was similar: depending on the semantics of the action you specified...
... I won't flesh out my UI ideas here, maybe VarURLPARAM
is enough to implement an interactive way of selecting topics.
Let's work on what these
will look like.
- 19 Apr 2010