[Zope] Macros in the ZMI perhaps?

Peter Bengtsson mail@peterbe.com
Thu, 21 Jun 2001 15:49:16 +0200


Community and DC techdecisionmakers,

I know this thought might complicate the ZMI for beginners which is bad, but
there is still hope for skinning the ZMI for advanced and novice users isn't
it.

It would be nice to be able to write common macros for objects, such as
renaming or print len(objectValues('Photo')) or backup or whatever!

In the list of objects you currently have:
- Type
- Name
- Size
- Las Modified

Added to this I would like to see "Macro".
In the macro field, there is a little drop down list where you select the
macro (from the available ones) you want to apply to the object. By default
it's None.
You can select only one macro per object and you can chose different macros
for different objects.
 - Obj1 do None
 - Obj2 do Rename à la carte
 - Obj3 do Rename à la carte
 - Obj3 do Backup on floppy
 - Obj4 do None

Then you click "Commit Macros on these objects" and it applies the methods
one the objects, one at a time.

The macros are Python Script, DTML Document, DTML Method or External Method.
They all have a title (used in the list of objects) and the usual binding.
The folder object gets a new Tab. "Macros".
In Macros you keep all the macro scripts (likely a bunch of different
scripts). These macros are inherited the usual way of course, so that
commonly used macros are preferably written in the root folder.

The macros must be babysimple to create and maintain. The script in the
macro itself can be advanced but it should be done elsewhere if it's too
advanced and content sensitive.


This is a quick thought and I had to scribble it down quick.
I'm not sure that I have the Zen enough to build a prototyp myself yet, but
there is interest I can at least put together a couple of static screens of
what I was thinking of.

What d'yo say?


Peter