[Zope-CMF] Function Removal if Item is locked.
Tres Seaver
tseaver@zope.com
11 Mar 2003 18:46:06 -0500
On Tue, 2003-03-11 at 15:25, Dieter Maurer wrote:
> Tres Seaver wrote at 2003-3-10 18:45 -0500:
> > ... TypeInformation as ActionProviderBase ...
> > It is scheduled to be in 1.4; I have done a good bit of the work to
> > land it today:
> >
> > - Merged the branch and fixed up all conflicts; all tests pass.
> >
> > - Updated all the 'factory_type_information' structures to make the
> > 'action' key a TALES expression (e.g., "document_view" ->
> > "string:document_view").
> >
> > Remaining TODOs:
> >
> > - Write an external method for converting existing type info objects
> > (they all have dictionaries, instead of ActionInformation objects,
> > stored in the ZODB).
> >
> > - Test it.
> >
> > I am going to land this on a new branch against today's head, if anybody
> > would like to help test:
>
> Nice to hear.
>
> My colleagues dearly wanted me to implement an additional feature:
>
> Provide an additional "target" field for actions. This
> field is meant to control the "target" attribute of the "a"
> tag and allows to present actions is a specific frame
> or a separate window.
>
> It was very easy to implement.
Should be a straightforward extension to ActionInformation, no? An
alternative would be to extend the actions tool to allow mapping of
actions more abstractly (i.e., just by 'category'+'name') to UI elements
like icons, javascript, target, etc. It makes some sense to do this at
a higher level for consistency (e.g. so that all "object/Edit" actions
get the same icon, target, etc.)
> > Anyone game to play? I have build and lightly tested a new CMFSite with
> > this code, but am certain that sites built previously die horribly.
>
> Your original code (the one I use since months) did some automatic
> conversion. At least, I am not aware that I had to run a conversion
> script.
*Sheepishly* I'd forgotten that the '_convertActions' method was there
until you and Yuppie reminded me. :)
Tres.
--
===============================================================
Tres Seaver tseaver@zope.com
Zope Corporation "Zope Dealers" http://www.zope.com