hi!
i'm playing around a bit to implement my suggestions for a new workflow
menu. i figured the easiest thing to start with would be a per-user
"notify submitter" preference.
i read ChangeVisiblity.java and copied it's structure. in
pubs/default/config/menus/generic.xsp i added
<menu i18n:attr="name" name="Workflow">
<block>
...
</block>
<block>
<item
uc:usecase="site.changeNotification"><xsp:expr>notificationChar</xsp:expr><i18n:text>Notify
submitter</i18n:text></item>
</block>
</menu>
and declared a dummy notificationChar that is always "x" for a start.
then i created a file
src/java/org/apache/lenya/cms/site/usecases/ChangeNotification.java.
when i do "./build.sh --noconfig" it seems to be built along with the
rest. it does nothing so far but implements the same methods as
ChangeVisibility.
now when i restart lenya and look at the workflow menu, the new option
appears to be grayed out. do i need to register this new usecase
somewhere? i see that ChangeVisibility uses a patchfile, but i don't
quite understand what it does.
next q: i think the switch "notify submitter" should ultimately become a
user preference (which depends on the user having "reviewer" status).
i looked at the "user" interface, which uses statically implemented
get/set functions for each user setting. i wonder whether that's going
to become a little kludgy if more settings are to be added... wouldn't
it be nice to have some sort of dynamic preference list in the future?
that way, modifications don't have to be done in the interface and all
classes that implement it. we just would have a vector or whatever it's
called in java of preferences, and the base classes don't need to know
what the individual prefs mean.
anyway, that's a little out of scope for now. how should i proceed to
add a per-user two-state setting for notification? modify the user
interface and everything above? or is there a more idiomatic way to do it?
(btw, don't hold your breath for me to get this done. i haven't even got
eclipse running yet, so i'm wrestling with the code on the command line.)
regards,
jörn
--
"Open source takes the bullshit out of software."
- Charles Ferguson on TechnologyReview.com
--
Jörn Nettingsmeier, EDV-Administrator
Institut für Politikwissenschaft
Universität Duisburg-Essen, Standort Duisburg
Mail: [EMAIL PROTECTED], Telefon: 0203/379-2736
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]