Re: Very Basic List and Crud -- how to link JSF forms

2009-03-11 Thread Andrew Robinson
For the question regarding using GET not POST, take a look at JBoss Seam,
they have solutions for this.

On Wed, Mar 11, 2009 at 9:42 PM,  wrote:

> Hello All,
>
> Probably the most basic web pattern is to list a series of objects
> (Employees, say) and then be able to click on one of them and edit it.
>
> Ie. Two forms, List and Update.  The List form contains a list of
> Employees, and a link for each employee.  When a user clicks on the link for
> employee Fred (say) the second Update form is called that just displays
> Fred's details and allows them to be edited.  No AJAX, just very basic HTML
> patterns.
>
> The first problem is how to set up the link in the List form to pass "Fred"
> to the update form.  This would be a get, not a post.  So then how to
> retrieve the value within the Update form.  Does one really need to poke at
> HtmlRequest?
>
> The second, more serious problem, is that the first time a form is
> displayed there is no way to run an action.  So when the Master form is
> called from the List form it cannot display Fred's details.
>
> I'm hoping not to have to use dirty tricks to do such a basic thing.  (One
> dirty trick would be to put most of the application into one huge form and
> somehow hide various bits at different stages.)
>
> None of the four JSF books that I have cover basic issues like this.
>  And Facelets cannot address the problem that JSF's seemingly broken event
> model was designed around JSPs.  Is JSF real, or does one need to go the
> whole ADF hog to do basic things?  ASP.Net seems much, much easier to
> use.
>
> All help much appreciated.  If someone has a canned example of basic List +
> Crud that would be most helpful.
>
> Anthony
>
>
>
>
> Dr Anthony Berglas, anth...@berglas.org   Mobile: +61 4 4838 8874
> Just because it is possible to push twigs along the ground with ones nose
> does not necessarily mean that is the best way to collect firewood.
>
>


Re: Tomahawk - t:schedule and t:inputCalendar cause js script error

2009-03-11 Thread Leonardo Uribe
Hi

Thanks a lot for your detailed description, it helps a lot to track it and
find a solution.

Really this is not an easy problem. It seems to be a problem not related to
the components, rather an incompatibility between javascript libraries.

I receive this error on Firebug:

*"Hash is not a constructor"*

on function:

function domLib_getEventPosition(in_eventObj){
   var eventPosition = new Hash('x', 0, 'y', 0, 'scrollX', 0, 'scrollY', 0);

It is possible that some object is overwritten by two different javascript
libraries.

 The javascript libraries of schedule component are:

schedule.HtmlSchedule/javascript/schedule.js
schedule.HtmlSchedule/javascript/alphaAPI.js
schedule.HtmlSchedule/javascript/domLib.js
schedule.HtmlSchedule/javascript/domTT.js
schedule.HtmlSchedule/javascript/fadomatic.js

and inputCalendar

prototype.PrototypeResourceLoader/prototype.js
calendar.HtmlCalendarRenderer/date.js
calendar.HtmlCalendarRenderer/popcalendar.js
inputTextHelp.HtmlTextHelpRenderer/inputTextHelp.js

In this case the problem is between domLib.js and prototype.js (both
javascript libraries use Hash name as variable).

The solution is change in my opinion domLib.js, domTT.js and domTT_drag.js
"Hash" name to DomHash or something more unique (since schedule component is
the only one that use these javascript files). I'll try it to see what
happens.

regards

Leonardo Uribe

On Wed, Mar 11, 2009 at 8:51 PM, j haley  wrote:

>  I never got a resolution to this problem.  I'm surprised that this has not
> been more of an issue.  Especially since the example I provided is only a
> small deviation from the sample project.
>
>
>
> > Date: Wed, 11 Mar 2009 11:46:23 -0700
> > From: munn...@gmail.com
> > To: users@myfaces.apache.org
> > Subject: Re: Tomahawk - t:schedule and t:inputCalendar cause js script
> error
> >
> >
> > Hi,
> > I am facing the exact problem.
> > could you please let me know if it is solved.
> >
> > Thanks in advance
> >
> >
> > j haley wrote:
> > >
> > >
> > > Having a problem that I can recreate on the with the tomahawk sample
> > > project. I was getting this with version 1.1.6, and I also get it with
> > > 1.1.8. On myfaces-example-simple-1.1.8/schedule1.jsf, make the
> following
> > > change.Add renderAsPopup="true" to the t:inputCalendar. The page
> renders
> > > fine, but when I mouse over the page I get a javascript error. This
> error
> > > prevents t:schedule’s tooltip from working. The combination that causes
> > > problems is t:inputCalendar or t:inputDate with a renderAsPopup=”true”
> > > attribute along with a t:schedule with a tooltip=”true” attribute. Bug
> > > numbers TOMAHAWK-929 and TOMAHAWK-193 look like they may be related to
> > > this issues. Is there a work around for this?
> > > _
> > > Color coding for safety: Windows Live Hotmail alerts you to suspicious
> > > email.
> > >
> http://windowslive.com/Explore/Hotmail?ocid=TXT_TAGLM_WL_hotmail_acq_safety_112008
> > >
> >
> > --
> > View this message in context:
> http://www.nabble.com/Tomahawk---t%3Aschedule-and-t%3AinputCalendar-cause-js-script-error-tp20661957p22461924.html
> > Sent from the MyFaces - Users mailing list archive at Nabble.com.
> >
>
> --
> Windows Live™ Contacts: Organize your contact list. Check it 
> out.
>


Very Basic List and Crud -- how to link JSF forms

2009-03-11 Thread anthony
Hello All,

Probably the most basic web pattern is to list a series of objects (Employees, 
say) and then be able to click on one of them and edit it.

Ie. Two forms, List and Update.  The List form contains a list of Employees, 
and a link for each employee.  When a user clicks on the link for employee Fred 
(say) the second Update form is called that just displays Fred's details and 
allows them to be edited.  No AJAX, just very basic HTML patterns.

The first problem is how to set up the link in the List form to pass "Fred" to 
the update form.  This would be a get, not a post.  So then how to retrieve the 
value within the Update form.  Does one really need to poke at HtmlRequest?

The second, more serious problem, is that the first time a form is displayed 
there is no way to run an action.  So when the Master form is called from the 
List form it cannot display Fred's details.

I'm hoping not to have to use dirty tricks to do such a basic thing.  (One 
dirty trick would be to put most of the application into one huge form and 
somehow hide various bits at different stages.)

None of the four JSF books that I have cover basic issues like this.  And 
Facelets cannot address the problem that JSF's seemingly broken event model was 
designed around JSPs.  Is JSF real, or does one need to go the whole ADF hog to 
do basic things?  ASP.Net seems much, much easier to use.

All help much appreciated.  If someone has a canned example of basic List + 
Crud that would be most helpful.

Anthony




Dr Anthony Berglas, anth...@berglas.org   Mobile: +61 4 4838 8874
Just because it is possible to push twigs along the ground with ones nose
does not necessarily mean that is the best way to collect firewood.



RE: Tomahawk - t:schedule and t:inputCalendar cause js script error

2009-03-11 Thread j haley

I never got a resolution to this problem.  I'm surprised that this has not been 
more of an issue.  Especially since the example I provided is only a small 
deviation from the sample project.

 

 

 
> Date: Wed, 11 Mar 2009 11:46:23 -0700
> From: munn...@gmail.com
> To: users@myfaces.apache.org
> Subject: Re: Tomahawk - t:schedule and t:inputCalendar cause js script error
> 
> 
> Hi,
> I am facing the exact problem.
> could you please let me know if it is solved.
> 
> Thanks in advance
> 
> 
> j haley wrote:
> > 
> > 
> > Having a problem that I can recreate on the with the tomahawk sample
> > project. I was getting this with version 1.1.6, and I also get it with
> > 1.1.8. On myfaces-example-simple-1.1.8/schedule1.jsf, make the following
> > change.Add renderAsPopup="true" to the t:inputCalendar. The page renders
> > fine, but when I mouse over the page I get a javascript error. This error
> > prevents t:schedule’s tooltip from working. The combination that causes
> > problems is t:inputCalendar or t:inputDate with a renderAsPopup=”true”
> > attribute along with a t:schedule with a tooltip=”true” attribute. Bug
> > numbers TOMAHAWK-929 and TOMAHAWK-193 look like they may be related to
> > this issues. Is there a work around for this?
> > _
> > Color coding for safety: Windows Live Hotmail alerts you to suspicious
> > email.
> > http://windowslive.com/Explore/Hotmail?ocid=TXT_TAGLM_WL_hotmail_acq_safety_112008
> >  
> > 
> 
> -- 
> View this message in context: 
> http://www.nabble.com/Tomahawk---t%3Aschedule-and-t%3AinputCalendar-cause-js-script-error-tp20661957p22461924.html
> Sent from the MyFaces - Users mailing list archive at Nabble.com.
> 

_
Windows Live™ Contacts: Organize your contact list. 
http://windowslive.com/connect/post/marcusatmicrosoft.spaces.live.com-Blog-cns!503D1D86EBB2B53C!2285.entry?ocid=TXT_TAGLM_WL_UGC_Contacts_032009

Re: Tomahawk - t:schedule and t:inputCalendar cause js script error

2009-03-11 Thread mun

Hi,
  I am facing the exact problem.
  could you please let me know if it is solved.

Thanks in advance


j haley wrote:
> 
> 
> Having a problem that I can recreate on the with the tomahawk sample
> project.  I was getting this with version 1.1.6, and I also get it with
> 1.1.8. On myfaces-example-simple-1.1.8/schedule1.jsf, make the following
> change.Add renderAsPopup="true" to the t:inputCalendar. The page renders
> fine, but when I mouse over the page I get a javascript error.  This error
> prevents t:schedule’s tooltip from working.  The combination that causes
> problems is t:inputCalendar or t:inputDate with a renderAsPopup=”true”
> attribute along with a t:schedule with a tooltip=”true” attribute. Bug
> numbers TOMAHAWK-929 and TOMAHAWK-193 look like they may be related to
> this issues. Is there a work around for this?
> _
> Color coding for safety: Windows Live Hotmail alerts you to suspicious
> email.
> http://windowslive.com/Explore/Hotmail?ocid=TXT_TAGLM_WL_hotmail_acq_safety_112008
>  
> 

-- 
View this message in context: 
http://www.nabble.com/Tomahawk---t%3Aschedule-and-t%3AinputCalendar-cause-js-script-error-tp20661957p22461924.html
Sent from the MyFaces - Users mailing list archive at Nabble.com.



Re: [myfaces] change selectonemenu value through setsubmitedvalue commandlink immediate=true

2009-03-11 Thread alvaro tovar
hello
i solve this whit

 setDealType(reoffer.getDealType());


getInputDealType().setSubmittedValue(reoffer.getDealType().getDealTypeId().toString());

getInputDealType().setValue(reoffer.getDealType().getDealTypeId().toString());


set the value id, not the object.

regards

2009/3/11 alvaro tovar :
> hello list
> i need help whit this, i need to change the submitedvalue for some
> input fields, a commandlink action change the value for this inputs,
> also the commandlink change the submitedvalue of this inputs, run ok
> for inputext and selectbooleancheckbox, but for selectonemenu not, the
> value not change. the selectonemenu use converter. i don't know what
> happend. the commandlink is immediate=true because i need that no
> validate.
> this is my code
>
>   required="true"  binding="#{editReofferBean.inputPrice}"
>
> styleClass="tablaRespuestaDer" size="6" onkeyup="calculatePriceM2()"
> immediate="false">
>
>  styleClass="tablaRespuesta"
>
> binding="#{editReofferBean.inputDealType}"           >
>                                                         value="#{constantManager.dealType}"/>
>                                                    
>
>
> the commandLink action
>
> 
>
> this.setPrice(formatter.toString());
>      inputPrice.setValue(this.getPrice());
>      inputPrice.setSubmittedValue(this.getPrice());
>
> setDealType(reoffer.getDealType());
>    getInputDealType().setSubmittedValue(reoffer.getDealType());
>    getInputDealType().setValue(reoffer.getDealType());
>
> ...
>
> thanks
> regards
>


Re: MyFaces 1.2.4 and WebLogic 10.3- strict servlet API: cannot call getWriter() after getOutputStream()

2009-03-11 Thread jribeiro

I did that long time ago- https://issues.apache.org/jira/browse/MYFACES-1955

Matthias Wessendorf-4 wrote:
> 
> Can you file an issue ?
> 
> -Matthias
> 
> On Mon, Mar 9, 2009 at 10:35 PM, jribeiro 
> wrote:
>>
>> No, sorry, we decided to use the Sun reference implementation. I was
>> expecting to see a fast reaction to this issue, which in my opinion is
>> very
>> serious, but nothing has happened since.
>>
>>
>> V. Svetoslavov wrote:
>>>
>>> Hello!
>>>
>>> Have you managed to work around this problem? Is there any solution?
>>>
>>> Thanks.
>>>
>>> Regards
>>> V. Svetoslavov
>>>
>>
>> --
>> View this message in context:
>> http://www.nabble.com/MyFaces-1.2.4-and-WebLogic-10.3--strict-servlet-API%3A-cannot-call-getWriter%28%29-after-getOutputStream%28%29-tp19352315p22422287.html
>> Sent from the MyFaces - Users mailing list archive at Nabble.com.
>>
>>
> 
> 
> 
> -- 
> Matthias Wessendorf
> 
> blog: http://matthiaswessendorf.wordpress.com/
> sessions: http://www.slideshare.net/mwessendorf
> twitter: http://twitter.com/mwessendorf
> 
> 

-- 
View this message in context: 
http://www.nabble.com/MyFaces-1.2.4-and-WebLogic-10.3--strict-servlet-API%3A-cannot-call-getWriter%28%29-after-getOutputStream%28%29-tp19352315p22460411.html
Sent from the MyFaces - Users mailing list archive at Nabble.com.



[myfaces] change selectonemenu value through setsubmitedvalue commandlink immediate=true

2009-03-11 Thread alvaro tovar
hello list
i need help whit this, i need to change the submitedvalue for some
input fields, a commandlink action change the value for this inputs,
also the commandlink change the submitedvalue of this inputs, run ok
for inputext and selectbooleancheckbox, but for selectonemenu not, the
value not change. the selectonemenu use converter. i don't know what
happend. the commandlink is immediate=true because i need that no
validate.
this is my code

 






the commandLink action



this.setPrice(formatter.toString());
  inputPrice.setValue(this.getPrice());
  inputPrice.setSubmittedValue(this.getPrice());

setDealType(reoffer.getDealType());
getInputDealType().setSubmittedValue(reoffer.getDealType());
getInputDealType().setValue(reoffer.getDealType());

...

thanks
regards


Re: [Trinidad] Chart Demo not working

2009-03-11 Thread Matthias Wessendorf
what version are you on ?

-Matthias

On Wed, Mar 11, 2009 at 4:13 PM, Lars Vogel  wrote:
> Hi Matthias,
> yes, my examples are working fine.
> Best regards, Lars
>
> 2009/3/11 Matthias Wessendorf 
>>
>> Interesting;
>>
>> the demo is using an older version of Trinidad, but I guess you
>> are already using a more recent one, e.g. 1.2.10 ?
>>
>> -Matthias
>>
>> On Wed, Mar 11, 2009 at 2:25 PM, Lars Vogel 
>> wrote:
>> > Hi,
>> > I'm not sure if this is the right place to report this but the live demo
>> > for
>> > the Trinidad Chart is not working.
>> > http://www.irian.at/trinidad-demo/faces/components/chart.jspx
>> > This side is linked from http://myfaces.apache.org/trinidad/
>> > -> Live Demos -> Component Guide -> chart
>> > Best regards, Lars
>> >
>> >
>>
>>
>>
>> --
>> Matthias Wessendorf
>>
>> blog: http://matthiaswessendorf.wordpress.com/
>> sessions: http://www.slideshare.net/mwessendorf
>> twitter: http://twitter.com/mwessendorf
>
>
>
> --
> Lars
> http://www.vogella.de - Tutorial about Java, Eclipse and Web programming
>



-- 
Matthias Wessendorf

blog: http://matthiaswessendorf.wordpress.com/
sessions: http://www.slideshare.net/mwessendorf
twitter: http://twitter.com/mwessendorf


Re: [Trinidad] Chart Demo not working

2009-03-11 Thread Lars Vogel
Hi Matthias,
yes, my examples are working fine.

Best regards, Lars

2009/3/11 Matthias Wessendorf 

> Interesting;
>
> the demo is using an older version of Trinidad, but I guess you
> are already using a more recent one, e.g. 1.2.10 ?
>
> -Matthias
>
> On Wed, Mar 11, 2009 at 2:25 PM, Lars Vogel 
> wrote:
> > Hi,
> > I'm not sure if this is the right place to report this but the live demo
> for
> > the Trinidad Chart is not working.
> > http://www.irian.at/trinidad-demo/faces/components/chart.jspx
> > This side is linked from http://myfaces.apache.org/trinidad/
> > -> Live Demos -> Component Guide -> chart
> > Best regards, Lars
> >
> >
>
>
>
> --
> Matthias Wessendorf
>
> blog: http://matthiaswessendorf.wordpress.com/
> sessions: http://www.slideshare.net/mwessendorf
> twitter: http://twitter.com/mwessendorf
>



-- 
Lars
http://www.vogella.de - Tutorial about Java, Eclipse and Web programming


Re: [Trinidad] Chart Demo not working

2009-03-11 Thread Matthias Wessendorf
Interesting;

the demo is using an older version of Trinidad, but I guess you
are already using a more recent one, e.g. 1.2.10 ?

-Matthias

On Wed, Mar 11, 2009 at 2:25 PM, Lars Vogel  wrote:
> Hi,
> I'm not sure if this is the right place to report this but the live demo for
> the Trinidad Chart is not working.
> http://www.irian.at/trinidad-demo/faces/components/chart.jspx
> This side is linked from http://myfaces.apache.org/trinidad/
> -> Live Demos -> Component Guide -> chart
> Best regards, Lars
>
>



-- 
Matthias Wessendorf

blog: http://matthiaswessendorf.wordpress.com/
sessions: http://www.slideshare.net/mwessendorf
twitter: http://twitter.com/mwessendorf


[Trinidad] Chart Demo not working

2009-03-11 Thread Lars Vogel
Hi,
I'm not sure if this is the right place to report this but the live demo for
the Trinidad Chart is not working.

http://www.irian.at/trinidad-demo/faces/components/chart.jspx

This side is linked from http://myfaces.apache.org/trinidad/

-> Live Demos -> Component Guide ->
chart

Best regards, Lars


Re: JSP page not getting rendered when using f:view tag

2009-03-11 Thread Matthias Wessendorf
> <
>
> f:view ">


why is there a " ?

-Matthias
-- 
Matthias Wessendorf

blog: http://matthiaswessendorf.wordpress.com/
sessions: http://www.slideshare.net/mwessendorf
twitter: http://twitter.com/mwessendorf


Re: JSP page not getting rendered when using f:view tag

2009-03-11 Thread Simon Kitching
krishna Gummadi schrieb:
> hi ,
>  
>  Iam new to using my faces and trinidad. Iam just building a samll login
> jsp and binding it to my backing bean .
> Surprisingly .. if my jsp has f:view tag , after running the jsp i see
> empty page with out any errors . If i change the f:view to f:subview i
> can see my page displayed after i run the jsp .
> Iam using 
> 
> <
> 
> default-render-kit-id>_org_._apache_._myfaces_._trinidad_.core
> 
> 
> in my faces config.xml ..
> 
>  
> 
> and my jsp is as follows :
> 
>  
> 
> <%@
> 
> taglib uri=/"http://java.sun.com/jsf/html"/ prefix=/"h"/%>
> 
> <%@
> 
> taglib uri=/"http://java.sun.com/jsf/core"; /prefix=/"f"/%>
> 
> <%@
> 
> taglib uri=/"http://myfaces.apache.org/trinidad"/ prefix=/"tr"/%>
> 
> <%@
> 
> page language=/"java"/%>
> 
> <
> 
> html>
> 
> <
> 
> body id=/"login"/>
> 
> <
> 
> f:view /"/>
> 
> 
> 
> 
> 
> 
> 
> 
> 
>  
> f:view>
> 
>  
> body>
> 
>  
> html>
> 
>  
> 
> Could any one please let me know why my page is not getting rendered
> when using f:view tag ?
> 
>  
> 
> PS: I do not have any JSF RI implementation jars in my library..
> 

(1)
What url are you using to access your page?

You should use
   http://somehost:someport/appname/login.jsf

Note the suffix: ".jsf", not ".jsp".

(2)
If you take the trinidad renderkit line out, what happens?

(3)
What version of Myfaces are you using?

(4)
Myfaces uses commons-logging as its logging library. Do you see anything
useful in the logfiles if you enable logging?

Regards,
Simon
-- 
-- Emails in "mixed" posting style will be ignored
-- (http://en.wikipedia.org/wiki/Posting_style)


JSP page not getting rendered when using f:view tag

2009-03-11 Thread krishna Gummadi
hi ,

 Iam new to using my faces and trinidad. Iam just building a samll login jsp
and binding it to my backing bean .
Surprisingly .. if my jsp has f:view tag , after running the jsp i see empty
page with out any errors . If i change the f:view to f:subview i can see my
page displayed after i run the jsp .
Iam using

*org*.*apache*.*myfaces*.*trinidad*.core

in my faces config.xml ..



and my jsp is as follows :



<%...@taglib uri=*"http://java.sun.com/jsf/html"* prefix=*"h"*%>

<%...@taglib uri=*"http://java.sun.com/jsf/core"; *prefix=*"f"*%>

<%...@taglib uri=*"http://myfaces.apache.org/trinidad"* prefix=*"tr"*%>

<%...@page language=*"java"*%>























Could any one please let me know why my page is not getting rendered when
using f:view tag ?



PS: I do not have any JSF RI implementation jars in my library..


Re: Trinidad: Font difference in line listing?

2009-03-11 Thread Marco Grimm-2

Please reinsert the rowBandingInterval and post the rendered html-Sourcecode
for the table (not the xhtml-sourcecode, which you already posted) from the
browser. Maybe try different rowBandingIntervals.

Marco


senore100 wrote:
> 
> Thanks for the reply. 
> I did remove rowBandingInterval="1" attribute and now it looks much
> better. At least the font is consistent (although I am losing the benefit
> of alternating background colors)! 
> Honestly I don't know anything about CSS. But I am attaching part of the
> CSS file here as well. Not sure if that's the reason or not.
> Hua
> 
> 
> 
> --- On Tue, 3/10/09, Marco Grimm-2 
> wrote:
> From: Marco Grimm-2 
> Subject: Re: Trinidad: Font difference in line listing?
> To: users@myfaces.apache.org
> Date: Tuesday, March 10, 2009, 2:29 AM
> 
> If the same behavior preserves if you remove the
> rowBandingInterval="1" then
> please post your skinning css/settings.
> 
> 
> senore100 wrote:
>> 
>> Hi everyone. I am developing a line listing using Trinidad. What
>> frustrates me is that the font alternates between lines in both IE and FF
>> (Please see the attached screenshot. I also have attached some xhtml
>> snippet).  I am really not doing anything fancy here. 
>> Can anyone give me any idea as to where this problem is coming from?
>> Thanks!
>> Regards,
>> Hua
>> 
> 
> -- 
> View this message in context:
> http://www.nabble.com/Trinidad%3A-Font-difference-in-line-listing--tp22425605p22429219.html
> Sent from the MyFaces - Users mailing list archive at Nabble.com.
> 

-- 
View this message in context: 
http://www.nabble.com/Trinidad%3A-Font-difference-in-line-listing--tp22425605p22450431.html
Sent from the MyFaces - Users mailing list archive at Nabble.com.



session logout not happening while clicking on tabs

2009-03-11 Thread Sabitha Gopal Pandit
 

Hi everyone,

 

We have a strange problem

 

Once Session expires proper logout doesn't not happen while clicking on
tabs created in jspx using  tags

 

This is very specifically for the tabs and everything works fine while
clicking on link or buttons etc

 

Any idea as to what is happening?

 

Any help is highly appreciated

 

Thanks,

Sabitha