correct instructions for adding a use case?

View: New views
2 Messages — Rating Filter:   Alert me  

correct instructions for adding a use case?

by Jonathan Bregler :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi all,

Here's what we're trying to do, then why we can't do it.

As a proof of concept, we want to take a little javascript, pretend it is an editor, and then add that as an editor to Lenya. We think the way to do that is in two steps: (1) create a .jx view and add all our javascript to it, then (2) create a usecase that uses that view.

What we would like: instructions for how to do this (from anywhere).

Why we can't do it at the moment: the instructions for creating a usecase in the official documentation appear to be out of date, and we are a little stumped.

In particular: At http://lenya.apache.org/docs/2_0_x/reference/usecase-framework/index.html#Implementing+a+Custom+Usecase, in a number of places the instructions refer to directories and files that no longer exist:

1) There is no $LENYA_WEBAPP/lenya/usecases, as listed below. There many directories named "usecases," and none of them have the above sub-directories, so we don't know which one to use.

The Lenya Core

$LENYA_WEBAPP
  /lenya/usecases                     usecase-related files
                 /usecase.xmap        usecase dispatching sitemap
                 /usecases.js         flowscript for usecase control flow
                 /admin               Lenya admin usecases
                       /addUser.jx    JX templates for usecase views
                 ...                  more Lenya core usecases

2) The following directories and file do not exist. Questions: (i) where are they now? (ii) is this how a usecase is registered?
4. Add the usecase handler class declaration to an XPatch file, e.g. $PUB_HOME/config/cocoon-xconf/usecases.xconf ...

Thanks in advance for any help/advice,
jb/rb

Re: correct instructions for adding a use case?

by Andreas Hartmann :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Jonathan Bregler schrieb:

> Hi all,
>
> Here's what we're trying to do, then why we can't do it.
>
> As a proof of concept, we want to take a little javascript, pretend it
> is an editor, and then add that as an editor to Lenya. We think the way
> to do that is in two steps: (1) create a .jx view and add all our
> javascript to it, then (2) create a usecase that uses that view.
>
> What we would like: instructions for how to do this (from anywhere).
>
> Why we can't do it at the moment: the instructions for creating a
> usecase in the official documentation appear to be out of date, and we
> are a little stumped.

You're right, the documentation is outdated. Here's an updated version:

https://lenya.zones.apache.org/cms/docu/live/docu20/reference/usecase-framework/usecase-framework-overview.html

Maybe there still are some mistakes in it, please complain if you find them.

-- Andreas


--
Andreas Hartmann, CTO
BeCompany GmbH
http://www.becompany.ch
Tel.: +41 (0) 43 818 57 01


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@...
For additional commands, e-mail: user-help@...

LightInTheBox - Buy quality products at wholesale price!