Op 18-jan-2007, om 11:35 heeft Johannes Verelst het volgende geschreven:
There are several issues in the framework project that are not yet
thought out; and to keep this project moving I have some suggestions
that I want to discuss.

It concerns the following problems:
- a component needs to retrieve a configuration setting
- a component needs to know if the current user may perform a specific
(function) action

[snip]

My proposal would be to extend the current Component and Framework
API's, to include the following methods:
Component:
 - getSettings() -> to return a list of property names that can be
set for this component (configured in XML probably)

Do you want to configure this in the current component configuration file, or do you need seperate files? Currently a believe that especially blocks - which are pieces of component functionality - need configuration in stead of the components themselves.

 - getActions() -> to return a list of actions that can be performed
within the component (configured in XML probably)

The same here. When you look for example at the core component you'll see a lot of blocks that need special configurations. But then again I understand your need for more configuring components, maybe we need to look into block configuration too.

Framework:
 - getSetting(Component, String, Parameters) -> return a string
containing the setting value for the given component, setting name and
framework-parameters.
 - may(Component, String, Parameters) -> return a boolean indicating
whether the current user may perform the given action in this
component (the current user can be retrieved from the framework
parameters)

+1

Taglib:
 - need a new <mm:may action="xyz" /> tag?
 - need a new <mm:setting name="xyz" /> tag?

These will live in the body of the mm:component tag?

The specific details need polishing probably since I just made them
up, but how do you all think of this idea?

I believe there are still issues with using the mm:url within component blocks that prevent me from further developing the core components for MMBase admin pages. Maybe you can look into these or suggest something that can help me fix them.

---André

--
André van Toly
MMBase development & Userfriendly webdesign

W: http://www.toly.nl
M: +31(0)627233562
------------------------------------------------------------------ ~~<<>>~~


_______________________________________________
Developers mailing list
[email protected]
http://lists.mmbase.org/mailman/listinfo/developers

Reply via email to