Re: wysiwyg editor

2006-12-03 Thread Cyrille37

Karthik N a écrit :

http://lombok.demon.co.uk/tapestry4Demo/TestFCKeditor2.html
http://lombok.demon.co.uk/tapestry4Demo/TestFCKeditor1.html


There is FCKeditorTA on Tassel, which I didn't try yet.
http://equalitylearning.org/Tassel/app?service=external/ViewComponentsp=SFCKeditorTA

Cyrille.


On 12/1/06, Peter Schröder [EMAIL PROTECTED] wrote:



http://tapestryjava.blogspot.com/2006/10/ezing-builder-wysiwyg-builder-for.html 



-Ursprüngliche Nachricht-
Von: Cyrille37 [mailto:[EMAIL PROTECTED]
Gesendet: Freitag, 1. Dezember 2006 10:51
An: Tapestry users
Betreff: wysiwyg editor

Hello,

Has someone integrated some Wysiwyg editors with Tapestry like FCKEditor
(www.fckeditor.net/), xstandard (www.xstandard.com), RTE
(www.kevinroth.com/rte/), TinuMCE (tinymce.moxiecode.com/) ?
Any experience and comment are wellcome.

Have a nice day,
cyrille



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Popup window with parameter

2006-12-03 Thread Cyrille37

Istvan Szucs a écrit :

The question is wrong.
The problem is solved.
I found this: http://lombok.demon.co.uk/tapestry4Demo/TestPopupSource.html
  

Hi,

I don't know it it can help, but there are some components on Tassel :

http://equalitylearning.org/Tassel/app?service=external/ViewComponentsp=SNewWindowLink
http://equalitylearning.org/Tassel/app?service=external/ViewComponentsp=SNewWindowLink_Tap4

Cyrille.


Stef

  

Hello!

I have a page, with a javascript:
function openPopup(startValue){
var win2=window.open(./app/ListValuesstartValue=+startValue,Listed
Values,width=600px, height=600px, resizable=yes, center=yes,
menubar=no, scrollbars=yes, status=yes, minimize=no, maximize=no,
help=no)
win2.creator=self
}
In the page, i tell the javascript: input type=button
onClick=javascript:openPopup(1) value=LOV

How can I add parameters to the ListValues.page in javascript?
I want to add a parameter like this: app/ListValuesstartValue=1

Stef



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


  




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tapestry HiveDoc generation

2006-12-03 Thread Norbert Sándor
There is a non-official maven plugin as well: 
http://issues.apache.org/jira/browse/HIVEMIND-164

Although I haven't tried it yet...

BR:
Norbi

Jesse Kuhnert írta:

I did sit down and figure this out finally. Hivemind has an ant task
you can use to read in registry files and output them into one main
registry.xml file. From there it can be transformed with xsl into
whatever you want. I added it into the build process for tap 4.1 today
(using maven2) so you should be able to go from there.(i made a few
enhancements but it should still basically be the same)

The docs are of course generated and available for viewing from each
specific module page:

http://tapestry.apache.org/tapestry4.1/tapestry-framework/index.html
http://tapestry.apache.org/tapestry4.1/tapestry-framework/hivedoc/index.html 




On 11/25/06, fdegrassi [EMAIL PROTECTED] wrote:

First of all, I'm just starting to dig into Tapestry and HiveMind.
I want to generate the HiveDoc for Tapestry and (eventually) for my own
project, but haven't found any documentation on how to do that. I've
never tried to build tapestry from source, so i don't know if the build
process would give me any hint regarding this issue.
Anyone could please give me an hint on where to look ? Any help is
appreciated.

Francesco Degrassi

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]







-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Re: Number translator message in 4.1

2006-12-03 Thread Sam Gendler

I disagree with your points regarding validation errors targeting a
developer audience rather than end user.  First, validation errors are
not likely to be the result of a programmer error, although yes, if
you do supply the wrong mask, it might prove useful.  More
importantly, previous versions of Tapestry messages were end-user
friendly enough to be used as-is AND they were already
internationalized into a number of useful languages. It is pretty
unlikely that there aren't large numbers of users using the default
messages, precisely because they used to be more than up to the task.
Again, the issue is an UNNECESSARY change in behaviour on a point
release without any kind of backwards compatibility mode. And on that
point, most commerical and many open source frameworks most certainly
do go out of their way to provide such stability across releases.
Traditionally, version numbering itself was intended to be used to
indicate this.  API changes generally are reserved for major version
changes.  The importance of adhering to this is that even the
non-technical members of a development team understand this point, so
it is always surprising to them that there is as much work involved in
upgrading from 4.0 to 4.1 as there is.

Incidentally, no one is asking open source to be free.  I've been
building software based on open and closed software packages for 15+
years (soft. architect or senior developer at Cisco, Akamai,
Software.com/Openwave, Dreamworks, Valueclick, the UN, developer at
various others), and I am well aware of what open source offers
compared to commercial packages.  In fact, when I was choosing
Tapestry over various and sundry other frameworks, one of the things
that drove me to Tapestry was the maturity and stability of the
codebase.  I went out of my way to look at the differences between 3
and 4 specifically so I could see what I could expect during a major
version upgrade, and I liked what I saw.  The API remained largely
consistent, the changes in the API were well documented and, more
importantly, well-justified.  And perhaps most importantly, it seemed
to have a supportive _community_ of developers who use it, which, as
we all know, is usually the single most important factor in the
usability of an open source package since the documentation is almost
always greviously deficient in open source projects (although tap is
better than most in that regard).

As a member of that community, I think it is our responsibility to
express our opinion of the direction the product is taking.  HLS and
other developers don't have to pay us the slightest bit of attention,
of course, but if the community doesn't express a preference, what we
wind up with is a framework that caters only to the unique needs of
the developers which can often be fairly out of sync with what a more
'average' user requires, specifically because the developers have such
deep familiarity with the API.  The 'feature' in question is a nice
example. It benefits a small number of users at the expense of what I
imagine is the majority.  So yes, I see Tap 4.1 as something of a
'Jesse special' which provides some of the changes he most wants to
see, potentially at the expense of general usability of the framework
for others.  That's his perogative, of course, so long as the other
developers agree, and I don't read the developer list often enough to
be even slightly aware of what the developer process is like on Tap.
Unfortunately, I don't have the cycles right now to jump in and start
hacking on the tapestry source myself right now, especially 4.1, since
I'm not using it. However, as a potential user, I certainly want to
speak up and attempt to be heard so that 4.1 can be the best possible
upgrade for Tapestry users of all stripes.

Open source may not promise a no-cost platform for users, but the
concept of an application development framework should promise a
certain amount of stability, since its entire reason for being is to
ease the development process.  When was the last time the gnu C
library released an API that wasn't source compatible with previous
versions? What about the JDK? I actually think that a framework like
Tapestry benefits by not adhering to old api in every case.  The
benefits of the change often outweigh the cost.  But this isn't one of
those cases.  Not only are the benefits questionable for many users,
but it shouldn't be difficult to provide support for users the old api
as well.

Trading application complexity for an unstable framework isn't a
useful tradeoff for anyone, unless you are able to abandon development
of projects built on older versions.  Forking the framework source is
just as inefficient as building your own framework and simply living
within its limits isn't often a viable solution for long term
devlopment.   Listing projects that got stuck on old platforms due to
platform instability doesn't support your argument. It reinforces
mine. I'm sure the folks at the companies you listed would prefer 

Re: Custom validator not called when value is empty?

2006-12-03 Thread Sam Gendler

Why not just build the set of validators for the field dynamically?
Assuming you can determine whether the field should be required by the
time the field rewinds (rather than being dependant on something not
yet rewound), then you can include the required validator in the list
only if it is actually required.  However, since the 'required'
validator is obviously called whether the field has a value or not, I
would suggest taking a look at the source for that validator to
determine where you have gone wrong with yours.  It is clearly
possible. Without seeing your source, that's about the best I can
suggest.

--sam


On 12/2/06, Malin Ljungh [EMAIL PROTECTED] wrote:

Good evening!

I have written my own validator which works excellent - as long as a value
is submitted in the field to be validated. Have I missed something here?
What should I do?

To add a required validator may seem to be the obvious solution but the
thing is that the field is not always required - it depends.

Cheers
Malin




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Re: Popup window with parameter

2006-12-03 Thread Sam Gendler

In general, if you want to construct a URL in Tapestry, it is best to
create an instance of ILink and then get the URL from that.  Assuming
the service for which you have instantiated the iLink takes
parameters, it should be fairly self explanatory how to get the Link
to include those parameters in the URL. The classic case of creating a
redirect which will pass parameters to the external service for a page
looks like the following:

   ExternalServiceParameter param =
   new ExternalServiceParameter(getPageName(),
redirectExternalParams(params));
   ILink link = getExternalService().getLink(false, param);
   _log.debug(redirecting to:  + link.getURL());
   throw new RedirectException(link.getURL());

Every instance of ILink takes some parameter object which encapsulates
the entire set of parameters that can be passed.  In my example,
redirectExternalParams just returns an array of Objects which will be
passed to the activateExternalPage() method when the page is loaded
via the URL created.

--sam


On 12/3/06, Cyrille37 [EMAIL PROTECTED] wrote:

Istvan Szucs a écrit :
 The question is wrong.
 The problem is solved.
 I found this: http://lombok.demon.co.uk/tapestry4Demo/TestPopupSource.html

Hi,

I don't know it it can help, but there are some components on Tassel :

http://equalitylearning.org/Tassel/app?service=external/ViewComponentsp=SNewWindowLink
http://equalitylearning.org/Tassel/app?service=external/ViewComponentsp=SNewWindowLink_Tap4

Cyrille.

 Stef


 Hello!

 I have a page, with a javascript:
 function openPopup(startValue){
 var win2=window.open(./app/ListValuesstartValue=+startValue,Listed
 Values,width=600px, height=600px, resizable=yes, center=yes,
 menubar=no, scrollbars=yes, status=yes, minimize=no, maximize=no,
 help=no)
 win2.creator=self
 }
 In the page, i tell the javascript: input type=button
 onClick=javascript:openPopup(1) value=LOV

 How can I add parameters to the ListValues.page in javascript?
 I want to add a parameter like this: app/ListValuesstartValue=1

 Stef


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]






-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: replace @InjectPage by a page specification

2006-12-03 Thread Sam Gendler

I don't know for sure, but I'd try using 'IPage' as the type, which
would hopefully tell hivemind to resolve the object as a page name.

You might also try looking at the source for the InjectPage
annotation, see how it resolves the page, presumably via a hivemind
service of some kind, and then  inject it via the hivemind binding, if
that's possible. There is also a list of bindings at
http://tapestry.apache.org/tapestry4/UsersGuide/bindings.html but I
have no idea if that is the canonical list.  You might try looking at
the tapestry.bindings.BindingFactories configuration point. You could
always contribute your own 'page' binding which would do the same
thing as the InjectPage annotation does in order to load a page
instance.

When you figure it out, please post it back here.  I don't know that
I'll ever use it, but I'm sure someone will search for it at some
point.

--sam


On 12/2/06, Cyrille37 [EMAIL PROTECTED] wrote:

Hello,
It's me again ...

I'm searching how to replace an @InjectPage annotation by a page
specification like

The java code is :
@InjectPage(Login)
public abstract Login getLoginPage();

And I would like to remove the annotation and replace it by a page
specification like :
inject property=loginPage type=page object=Login/

But it does not works.

Is it possible ? What is the right syntax ?
Thanks
Cyrille

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: replace @InjectPage by a page specification

2006-12-03 Thread Cyrille37

Sam Gendler a écrit :

I don't know for sure, but I'd try using 'IPage' as the type, which
would hopefully tell hivemind to resolve the object as a page name.

You might also try looking at the source for the InjectPage
annotation, see how it resolves the page, presumably via a hivemind
service of some kind, and then  inject it via the hivemind binding, if
that's possible. There is also a list of bindings at
http://tapestry.apache.org/tapestry4/UsersGuide/bindings.html but I
have no idea if that is the canonical list.  You might try looking at
the tapestry.bindings.BindingFactories configuration point. You could
always contribute your own 'page' binding which would do the same
thing as the InjectPage annotation does in order to load a page
instance.

When you figure it out, please post it back here.  I don't know that
I'll ever use it, but I'm sure someone will search for it at some
point.


Hello Sam,
And thanks a lot for your detailed explanation.

By the way, I should got another error somewhere else because now the 
syntax:


   inject property=loginPage type=page object=Login/

works fine !
It replace the @InjectPage annotation :

   @InjectPage(Login)
   public abstract Login getLoginPage();

I prefer to get page association made into a specification page than in 
the java source code to avoid to mush specialized code.
And it's much easyer and faster to change the page specification than to 
change and compile the java source.


Regards,
cyrille.



--sam


On 12/2/06, Cyrille37 [EMAIL PROTECTED] wrote:

Hello,
It's me again ...

I'm searching how to replace an @InjectPage annotation by a page
specification like

The java code is :
@InjectPage(Login)
public abstract Login getLoginPage();

And I would like to remove the annotation and replace it by a page
specification like :
inject property=loginPage type=page object=Login/

But it does not works.

Is it possible ? What is the right syntax ?
Thanks
Cyrille






-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Tapestry 4. Class ExternalService Javadoc mistake

2006-12-03 Thread Cyrille37

Hi,

I think there is a mistake in the Tapestry 4's JavaDoc for 
org.apache.tapestry.engine.ExternalService.


The example:
http://localhost/myapp?service=externalcontext=ViewCustomersp=5056sp=302
is not working.

To works I've to replace context by page like :
http://localhost/myapp?service=externalpage=ViewCustomersp=5056sp=302

Have a nice Sunday,
Cyrille.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



information about trapping exception

2006-12-03 Thread Cyrille37

Hello,
I'm still learning Tapestry, and generally Java Web Application ...
Now I can understand a beat about Tapestry and create little working 
project.
Here is the time for me to learn how to manage errors, like trapping an 
underground exception in the view layer.


The following example is from the Kent Tong 's book source code: the 
shop example.
There is a page to view shop's products details: 
ProductDetails(.html,.page,.java).


In ProductDetails.java there are accessors for a product details like :
   public String getName() {
   return lookup().getName();
   }
   public String getDesc() {
   return lookup().getDesc();
   }
   public double getPrice() {
   return lookup().getPrice();
   }
The lookup method to get a Product is :
   private Product lookup() {
   return Catalog.getGlobalCatalog().lookup(getProductId());
   }

In ProductDetails.page there are components like :
   component id=name type=Insert
   binding name=value value=name/
   /component
   component id=desc type=Insert
   binding name=value value=desc/
   /component
   component id=price type=Insert
   binding name=value value=price/
   /component

How can I catch an exception throwed by 
Catalog.getGlobalCatalog().lookup(getProductId()) when a ProductId is 
not valid (does not exists) ?
I would like to display a nicer page than the default Tapestry's 
Exception page.
The problem is that the exception occurs while parsing the 
ProductDetails's specification page (ProductDetails.page) where 
components are binded.


Have you got any idea or method on how to manage that kind of problems ?

thanks a lot for your experience share.
Cyrille.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Re: Number translator message in 4.1

2006-12-03 Thread Jesse Kuhnert

There certainly is a lot of discussion going on for what my naive mind
sees as only 2-3 validation strings. (which I'd be happy to revert
back to the old way)

If there are other more specific grievances people have I'd love to
hear them. More so than the typical unsocial nerd I have an
especially hard time interpreting hints/feelings/etc so to help me
better understand I just need people to be very specific about any
problems they encounter.

An added bonus would be a few submissions in JIRA to help me remember.
(as I'm not currently aware of any such issues filed yet)

On 12/3/06, Sam Gendler [EMAIL PROTECTED] wrote:
snipped

--
Jesse Kuhnert
Tapestry/Dojo/(and a dash of TestNG), team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



uncaught exception: [object Object] when using EventListener

2006-12-03 Thread kit

I encountered a problem with the new snapshot, well it was working previously
in the older snapshots. I am trying to use this EventListener annotation...
I am pretty sure it work very well in the 2 snapshots back code snippet
as follow 

   
@EventListener(targets=chapterChooser,events=onchange,submitForm=f1,async=true)
public void getDistricts(IRequestCycle cycle){
String a = this.getFormA().getChapter();
ArrayList t = new ArrayList();
t = c.getDistricts(a);
districtModel = new ValueLabelPropertySelectionModel(t);
setDistrictModel(districtModel);
cycle.getResponseBuilder().updateComponent(districtChooser);
}


I am using firefox browser and I found in the js console 

Error received in IO response. : None of the loaded transports for
dojo.io.bind() can handle the request.


can any1 please help ? :( 
it work I am sure it work. b4 I think 3 snapshots back... was kinda
bz to catch up wit the new snapshots b4 this :) 

regards,
waikit
-- 
View this message in context: 
http://www.nabble.com/uncaught-exception%3A--object-Object--when-using-EventListener-tf2747079.html#a7664240
Sent from the Tapestry - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Number translator message in 4.1

2006-12-03 Thread Kevin Menard

Thanks for the reply, Jesse.

 I think my original intention was to change some of the default error
 messages to give more specific information about the format that we
 want the input to be in. Rather than just saying your input sucks,
 try again and having them randomly type stuff in until they get it
 right.

I haven't looked at the messages for the other validators, but I think
the old message here was pretty clear.  ... must be a numeric value
doesn't seem to leave much to the imagination.  Perhaps ... must be a
number is a little clearer.  Format is #. doesn't really enhance
anything, to me.  If I didn't know what a numeric value was, I sure as
hell am not going to know what Format is # means ;-)

 Perhaps the messages need to be looked at a little more closely on an
 individual basis, or ideally find some way to translate # type
 number format patterns into a more human friendly message ?

Well, while I'm all for improving the user experience, I never really
saw a problem with the old validator messages.  Given that the new
message breaks a bunch of integration tests I have, I'm even against the
change ;-)  Having said that, if there really was a usability issue with
the old ones, I think there is merit in investigating better messages.
But, keep in mind that most people will not override these strings, so
I'd leave developer help messages out (or have a debug mode toggle).

-- 
Kevin Menard
Servprise International
WebReboot -- Remote Reboot Without Pulling the Plug
800.832.3823

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Number translator message in 4.1

2006-12-03 Thread Jesse Kuhnert

Sure, I can see the validity in the particular case of a simple number
format for numeric values. (except of course what will happen when
they input 3.14 ?)

As I've run out of time to really properly play with these for 4.1.1 I
may have to just revert to the old messages for now, but this is
definitely not the last you've heard of these kinds of changes. ;)

We have a sort of skunkworks project taking hold in the confines of
the dojo foundation to help attack usability (for end users of
applications) in general, so it's something I'll be attempting to
incorporate into Tapestry when possible. I know very little about the
area comparatively, but the others involved in the project are really
the best the industry has to offer - so it'll be an exciting time in
the next few releases.

On 12/3/06, Kevin Menard [EMAIL PROTECTED] wrote:


Thanks for the reply, Jesse.

 I think my original intention was to change some of the default error
 messages to give more specific information about the format that we
 want the input to be in. Rather than just saying your input sucks,
 try again and having them randomly type stuff in until they get it
 right.

I haven't looked at the messages for the other validators, but I think
the old message here was pretty clear.  ... must be a numeric value
doesn't seem to leave much to the imagination.  Perhaps ... must be a
number is a little clearer.  Format is #. doesn't really enhance
anything, to me.  If I didn't know what a numeric value was, I sure as
hell am not going to know what Format is # means ;-)

 Perhaps the messages need to be looked at a little more closely on an
 individual basis, or ideally find some way to translate # type
 number format patterns into a more human friendly message ?

Well, while I'm all for improving the user experience, I never really
saw a problem with the old validator messages.  Given that the new
message breaks a bunch of integration tests I have, I'm even against the
change ;-)  Having said that, if there really was a usability issue with
the old ones, I think there is merit in investigating better messages.
But, keep in mind that most people will not override these strings, so
I'd leave developer help messages out (or have a debug mode toggle).

--
Kevin Menard
Servprise International
WebReboot -- Remote Reboot Without Pulling the Plug
800.832.3823

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Jesse Kuhnert
Tapestry/Dojo/(and a dash of TestNG), team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



a component to set language (setLocale)

2006-12-03 Thread Cyrille37

Hello,

Before trying to write one, I come here to ask if some one has done a 
component which give the web user the possibility to choice his language 
(locale) in a list of available language (ex: fr,en,de,pt...).
I've had a look at Tassel and google but found only explanation, no 
ready to use component.


If I've to write it, is that page :
http://wiki.apache.org/tapestry/UsingCustomResourceSource
Is the right way when using Tapestry 4.0.2 ?

If you know some other explanation, please tell me.


Thanks, cyrille.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: a component to set language (setLocale)

2006-12-03 Thread Jesse Kuhnert

Not sure if it helps, but there is always ye old workbench demo :

http://opencomponentry.com:8080/workbench/Home,$Border.pageLink.sdirect?sp=Slocalization%2FLocalization

On 12/3/06, Cyrille37 [EMAIL PROTECTED] wrote:

Hello,

Before trying to write one, I come here to ask if some one has done a
component which give the web user the possibility to choice his language
(locale) in a list of available language (ex: fr,en,de,pt...).
I've had a look at Tassel and google but found only explanation, no
ready to use component.

If I've to write it, is that page :
http://wiki.apache.org/tapestry/UsingCustomResourceSource
Is the right way when using Tapestry 4.0.2 ?

If you know some other explanation, please tell me.


Thanks, cyrille.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Jesse Kuhnert
Tapestry/Dojo/(and a dash of TestNG), team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Re: Re: Number translator message in 4.1

2006-12-03 Thread Sam Gendler

The discussion isn't really about the message changes.  It was just
sparked by them.  The discussion is about the general philosophy of
framework design, developer vs end-user support, versioning and
backwards compatibility, documentation, and the direction of tapestry
development into the future.  The validation message change was just
one small example that happened to touch on all of those areas.

--sam


On 12/3/06, Jesse Kuhnert [EMAIL PROTECTED] wrote:

There certainly is a lot of discussion going on for what my naive mind
sees as only 2-3 validation strings. (which I'd be happy to revert
back to the old way)

If there are other more specific grievances people have I'd love to
hear them. More so than the typical unsocial nerd I have an
especially hard time interpreting hints/feelings/etc so to help me
better understand I just need people to be very specific about any
problems they encounter.

An added bonus would be a few submissions in JIRA to help me remember.
(as I'm not currently aware of any such issues filed yet)

On 12/3/06, Sam Gendler [EMAIL PROTECTED] wrote:
snipped

--
Jesse Kuhnert
Tapestry/Dojo/(and a dash of TestNG), team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Why propertys were not updated, when Form hasErrors??

2006-12-03 Thread Sam Gendler

I've never had this problem.  When a form fails validation in my apps,
I always see the content that was posted displayed back in the fields.
Is it possible that the class which backs your page is initializing
the bean back to default values after the rewind cycle completes with
an error?

--sam


On 12/3/06, Skorpien126 [EMAIL PROTECTED] wrote:


Ok... maybe I start nerving but I can´t belive that´s it not possible.

The Situation: I have maybe 20 Textareas in a form... each one using the
required validator. The textareas are BOUND to a bean which has
lifecycle=Page. Reading and writing still works... but when I fill data in
first 19 Textareas und I submit I get an ValidationError because the last
textarea has no text... so far so good, Validation is working.. but why the
Hell it´s not possible to update the values. I can´t expire that my users
Refill all the textareas... Is there a workaround or so??? I read some posts
refering this topic... but no REAL solution. Please help...

--
View this message in context: 
http://www.nabble.com/Why-propertys-were-not-updated%2C-when-Form-%22hasErrors%22---tf2747592.html#a7665535
Sent from the Tapestry - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: information about trapping exception

2006-12-03 Thread Sam Gendler

In hivmind.xml:

   contribution configuration-id=tapestry.InfrastructureOverrides
   property name=exceptionPageName value=CustomExceptionPage/
   /contribution

In your template for the custom exception:

span jwcid=exception/

will render the exception if you have the following in your .page file:

 component id=exception type=ExceptionDisplay
   binding name=exceptions value=ognl:exceptions/
 /component

You can also use the following to render the request

  component id=request type=RequestDisplay /

My class looks like this:

public abstract class CustomExceptionPage extends StaticBasePage
implements PageDetachListener {

   public abstract void setExceptions(ExceptionDescription[] exceptions);

   private static Logger log = Logger.getLogger(CustomExceptionPage.class);

   public void setException(Throwable value)
   {
   log.error(value, value);
   ExceptionAnalyzer analyzer = new ExceptionAnalyzer();
   ExceptionDescription[] exceptions = analyzer.analyze(value);
   setExceptions(exceptions);

   }
}

I don't remember where I got all that from, but it was either Kent
Tong's book or the user guide on the Tapestry website.  There is a
small chance I found it in Tapestry in Action which is the Tap 3
book.

--sam


On 12/3/06, Cyrille37 [EMAIL PROTECTED] wrote:

Hello,
I'm still learning Tapestry, and generally Java Web Application ...
Now I can understand a beat about Tapestry and create little working
project.
Here is the time for me to learn how to manage errors, like trapping an
underground exception in the view layer.

The following example is from the Kent Tong 's book source code: the
shop example.
There is a page to view shop's products details:
ProductDetails(.html,.page,.java).

In ProductDetails.java there are accessors for a product details like :
public String getName() {
return lookup().getName();
}
public String getDesc() {
return lookup().getDesc();
}
public double getPrice() {
return lookup().getPrice();
}
The lookup method to get a Product is :
private Product lookup() {
return Catalog.getGlobalCatalog().lookup(getProductId());
}

In ProductDetails.page there are components like :
component id=name type=Insert
binding name=value value=name/
/component
component id=desc type=Insert
binding name=value value=desc/
/component
component id=price type=Insert
binding name=value value=price/
/component

How can I catch an exception throwed by
Catalog.getGlobalCatalog().lookup(getProductId()) when a ProductId is
not valid (does not exists) ?
I would like to display a nicer page than the default Tapestry's
Exception page.
The problem is that the exception occurs while parsing the
ProductDetails's specification page (ProductDetails.page) where
components are binded.

Have you got any idea or method on how to manage that kind of problems ?

thanks a lot for your experience share.
Cyrille.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: information about trapping exception

2006-12-03 Thread Jesse Kuhnert

I believe that also gets covered on the website:

http://tapestry.apache.org/tapestry4.1/developmentguide/exceptionpages.html

On 12/3/06, Sam Gendler [EMAIL PROTECTED] wrote:

In hivmind.xml:

contribution configuration-id=tapestry.InfrastructureOverrides
property name=exceptionPageName value=CustomExceptionPage/
/contribution

In your template for the custom exception:

 span jwcid=exception/

will render the exception if you have the following in your .page file:

  component id=exception type=ExceptionDisplay
binding name=exceptions value=ognl:exceptions/
  /component

You can also use the following to render the request

   component id=request type=RequestDisplay /

My class looks like this:

public abstract class CustomExceptionPage extends StaticBasePage
implements PageDetachListener {

public abstract void setExceptions(ExceptionDescription[] exceptions);

private static Logger log = Logger.getLogger(CustomExceptionPage.class);

public void setException(Throwable value)
{
log.error(value, value);
ExceptionAnalyzer analyzer = new ExceptionAnalyzer();
ExceptionDescription[] exceptions = analyzer.analyze(value);
setExceptions(exceptions);

}
}

I don't remember where I got all that from, but it was either Kent
Tong's book or the user guide on the Tapestry website.  There is a
small chance I found it in Tapestry in Action which is the Tap 3
book.

--sam


On 12/3/06, Cyrille37 [EMAIL PROTECTED] wrote:
 Hello,
 I'm still learning Tapestry, and generally Java Web Application ...
 Now I can understand a beat about Tapestry and create little working
 project.
 Here is the time for me to learn how to manage errors, like trapping an
 underground exception in the view layer.

 The following example is from the Kent Tong 's book source code: the
 shop example.
 There is a page to view shop's products details:
 ProductDetails(.html,.page,.java).

 In ProductDetails.java there are accessors for a product details like :
 public String getName() {
 return lookup().getName();
 }
 public String getDesc() {
 return lookup().getDesc();
 }
 public double getPrice() {
 return lookup().getPrice();
 }
 The lookup method to get a Product is :
 private Product lookup() {
 return Catalog.getGlobalCatalog().lookup(getProductId());
 }

 In ProductDetails.page there are components like :
 component id=name type=Insert
 binding name=value value=name/
 /component
 component id=desc type=Insert
 binding name=value value=desc/
 /component
 component id=price type=Insert
 binding name=value value=price/
 /component

 How can I catch an exception throwed by
 Catalog.getGlobalCatalog().lookup(getProductId()) when a ProductId is
 not valid (does not exists) ?
 I would like to display a nicer page than the default Tapestry's
 Exception page.
 The problem is that the exception occurs while parsing the
 ProductDetails's specification page (ProductDetails.page) where
 components are binded.

 Have you got any idea or method on how to manage that kind of problems ?

 thanks a lot for your experience share.
 Cyrille.



 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Jesse Kuhnert
Tapestry/Dojo/(and a dash of TestNG), team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]