You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by "Kelvin Wong (JIRA)" <de...@myfaces.apache.org> on 2006/06/08 03:53:29 UTC

[jira] Created: (TOBAGO-79) Date Picker resets other field values

Date Picker resets other field values
-------------------------------------

         Key: TOBAGO-79
         URL: http://issues.apache.org/jira/browse/TOBAGO-79
     Project: MyFaces Tobago
        Type: Bug

  Components: Core  
    Versions: 1.0.7    
 Environment: Windows XP + Tomcat 5.5
    Reporter: Kelvin Wong
    Priority: Minor


When pressing the calendar icon of a date picker, it will reset the selected value of <tc:selectOneChoice> to first option.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Resolved: (TOBAGO-79) Date Picker resets other field values

Posted by "Bernd Bohmann (JIRA)" <de...@myfaces.apache.org>.
     [ http://issues.apache.org/jira/browse/TOBAGO-79?page=all ]
     
Bernd Bohmann resolved TOBAGO-79:
---------------------------------

    Resolution: Fixed

> Date Picker resets other field values
> -------------------------------------
>
>          Key: TOBAGO-79
>          URL: http://issues.apache.org/jira/browse/TOBAGO-79
>      Project: MyFaces Tobago
>         Type: Bug

>   Components: Core
>     Versions: 1.0.7
>  Environment: Windows XP + Tomcat 5.5
>     Reporter: Kelvin Wong
>     Assignee: Bernd Bohmann
>     Priority: Minor
>      Fix For: 1.0.8
>  Attachments: tc_date.zip
>
> When pressing the calendar icon of a date picker, it will reset the selected value of <tc:selectOneChoice> to first option.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Commented: (TOBAGO-79) Date Picker resets other field values

Posted by "Bernd Bohmann (JIRA)" <de...@myfaces.apache.org>.
    [ http://issues.apache.org/jira/browse/TOBAGO-79?page=comments#action_12417088 ] 

Bernd Bohmann commented on TOBAGO-79:
-------------------------------------

The datePicker needs a valid Pattern from a DateTimeConverter. If you register a Converter to java.util.Calendar the converter should be an instance of DateTimeConverter and should return a valid pattern from the method getPattern.

> Date Picker resets other field values
> -------------------------------------
>
>          Key: TOBAGO-79
>          URL: http://issues.apache.org/jira/browse/TOBAGO-79
>      Project: MyFaces Tobago
>         Type: Bug

>   Components: Core
>     Versions: 1.0.7
>  Environment: Windows XP + Tomcat 5.5
>     Reporter: Kelvin Wong
>     Assignee: Bernd Bohmann
>     Priority: Minor
>  Attachments: tc_date.zip
>
> When pressing the calendar icon of a date picker, it will reset the selected value of <tc:selectOneChoice> to first option.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Commented: (TOBAGO-79) Date Picker resets other field values

Posted by "Bernd Bohmann (JIRA)" <de...@myfaces.apache.org>.
    [ http://issues.apache.org/jira/browse/TOBAGO-79?page=comments#action_12416777 ] 

Bernd Bohmann commented on TOBAGO-79:
-------------------------------------

Sorry, the datepicker is an own component now.

Please try this with the latest SNAPSHOT 

<tc:panel> 
   <f:facet name="layout" > 
       <tc:gridLayout columns="1*;15px"/> 
   </f:facet> 
   <tc:date value="#{XXXX}" /> 
   <tc:datePicker for="@auto" /> 
</tc:panel> 

tx:date includes a label and the picker without any extra configuration. 

> Date Picker resets other field values
> -------------------------------------
>
>          Key: TOBAGO-79
>          URL: http://issues.apache.org/jira/browse/TOBAGO-79
>      Project: MyFaces Tobago
>         Type: Bug

>   Components: Core
>     Versions: 1.0.7
>  Environment: Windows XP + Tomcat 5.5
>     Reporter: Kelvin Wong
>     Assignee: Bernd Bohmann
>     Priority: Minor
>  Attachments: tc_date.zip
>
> When pressing the calendar icon of a date picker, it will reset the selected value of <tc:selectOneChoice> to first option.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Commented: (TOBAGO-79) Date Picker resets other field values

Posted by "Kelvin Wong (JIRA)" <de...@myfaces.apache.org>.
    [ http://issues.apache.org/jira/browse/TOBAGO-79?page=comments#action_12416769 ] 

Kelvin Wong commented on TOBAGO-79:
-----------------------------------

myfaces-api.jar and myfaces-impl.jar are upgraded to 1.1.4 also

> Date Picker resets other field values
> -------------------------------------
>
>          Key: TOBAGO-79
>          URL: http://issues.apache.org/jira/browse/TOBAGO-79
>      Project: MyFaces Tobago
>         Type: Bug

>   Components: Core
>     Versions: 1.0.7
>  Environment: Windows XP + Tomcat 5.5
>     Reporter: Kelvin Wong
>     Assignee: Bernd Bohmann
>     Priority: Minor
>  Attachments: tc_date.zip
>
> When pressing the calendar icon of a date picker, it will reset the selected value of <tc:selectOneChoice> to first option.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Commented: (TOBAGO-79) Date Picker resets other field values

Posted by "Bernd Bohmann (JIRA)" <de...@myfaces.apache.org>.
    [ http://issues.apache.org/jira/browse/TOBAGO-79?page=comments#action_12416675 ] 

Bernd Bohmann commented on TOBAGO-79:
-------------------------------------

Can you test it with the latest SNAPSHOT, please.

> Date Picker resets other field values
> -------------------------------------
>
>          Key: TOBAGO-79
>          URL: http://issues.apache.org/jira/browse/TOBAGO-79
>      Project: MyFaces Tobago
>         Type: Bug

>   Components: Core
>     Versions: 1.0.7
>  Environment: Windows XP + Tomcat 5.5
>     Reporter: Kelvin Wong
>     Assignee: Bernd Bohmann
>     Priority: Minor

>
> When pressing the calendar icon of a date picker, it will reset the selected value of <tc:selectOneChoice> to first option.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Commented: (TOBAGO-79) Date Picker resets other field values

Posted by "Kelvin Wong (JIRA)" <de...@myfaces.apache.org>.
    [ http://issues.apache.org/jira/browse/TOBAGO-79?page=comments#action_12416791 ] 

Kelvin Wong commented on TOBAGO-79:
-----------------------------------

I've updated the source code from the svn repository, rebuild the tobago-example-demo but still find the same problem (the date picker resets the selectOneChoice as soon as the calendar pops-up).

Next I try to test my own application using <tx:date> with the latest snapshot, and find that the selectOneChoice is not reset when the calendar pops-up.  However, when I press the ok or cancel button in the date picker, there is javascript error and I cannot proceed.  

BTW, I have two more questions :
1. Is there any reason to make the date picker a seperated component ?  In my application I use tc:date instead of tx:date because sometimes I 
    need the label spans more than 1 cell, so tc:date is more flexible for me.  With the latest snapshot I'll need to redefine the gridlayout for a lot of
    pages, which is quite a painful task.
2. Is there any plan to provide client side date picker ?

> Date Picker resets other field values
> -------------------------------------
>
>          Key: TOBAGO-79
>          URL: http://issues.apache.org/jira/browse/TOBAGO-79
>      Project: MyFaces Tobago
>         Type: Bug

>   Components: Core
>     Versions: 1.0.7
>  Environment: Windows XP + Tomcat 5.5
>     Reporter: Kelvin Wong
>     Assignee: Bernd Bohmann
>     Priority: Minor
>  Attachments: tc_date.zip
>
> When pressing the calendar icon of a date picker, it will reset the selected value of <tc:selectOneChoice> to first option.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Commented: (TOBAGO-79) Date Picker resets other field values

Posted by "Kelvin Wong (JIRA)" <de...@myfaces.apache.org>.
    [ http://issues.apache.org/jira/browse/TOBAGO-79?page=comments#action_12416767 ] 

Kelvin Wong commented on TOBAGO-79:
-----------------------------------

I just tested with the 1.0.8 snapshot on 19/06 but found that the calendar icon has disappeared for <tc:date>.

I have copied all jar files from snapshot zip file to my web app, any other procedure is required ?

> Date Picker resets other field values
> -------------------------------------
>
>          Key: TOBAGO-79
>          URL: http://issues.apache.org/jira/browse/TOBAGO-79
>      Project: MyFaces Tobago
>         Type: Bug

>   Components: Core
>     Versions: 1.0.7
>  Environment: Windows XP + Tomcat 5.5
>     Reporter: Kelvin Wong
>     Assignee: Bernd Bohmann
>     Priority: Minor

>
> When pressing the calendar icon of a date picker, it will reset the selected value of <tc:selectOneChoice> to first option.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Commented: (TOBAGO-79) Date Picker resets other field values

Posted by "Kelvin Wong (JIRA)" <de...@myfaces.apache.org>.
    [ http://issues.apache.org/jira/browse/TOBAGO-79?page=comments#action_12416957 ] 

Kelvin Wong commented on TOBAGO-79:
-----------------------------------

I try the latest tobago-example-demo from the link and find that the value for selectOneChoice is not reset anyymore.

The javascript error of my application is solved after updating all js files under org\apache\myfaces\tobago\renderkit\html.  However, another problem is found :

If there is no <f:convertDateTime> nested in <tx:date>, I will get the following exception : (There is no such problem in tobago-example-demo, and I use java.util.Calendar instead of java.util.Date for all date properties in the backing bean)

java.lang.NullPointerException
	at org.apache.myfaces.tobago.renderkit.html.scarborough.standard.tag.DatePickerRenderer.applyConverterPattern(DatePickerRenderer.java:105)
	at org.apache.myfaces.tobago.renderkit.html.scarborough.standard.tag.DatePickerRenderer.encodeBeginTobago(DatePickerRenderer.java:91)
	at org.apache.myfaces.tobago.renderkit.RendererBase.encodeBegin(RendererBase.java:64)
	at javax.faces.component.UIComponentBase.encodeBegin(UIComponentBase.java:512)
	at org.apache.myfaces.tobago.renderkit.RenderUtil.encode(RenderUtil.java:80)


Also, can I suggest to add an attribute showPicker to control whether the date picker should be rendered or not ?

> Date Picker resets other field values
> -------------------------------------
>
>          Key: TOBAGO-79
>          URL: http://issues.apache.org/jira/browse/TOBAGO-79
>      Project: MyFaces Tobago
>         Type: Bug

>   Components: Core
>     Versions: 1.0.7
>  Environment: Windows XP + Tomcat 5.5
>     Reporter: Kelvin Wong
>     Assignee: Bernd Bohmann
>     Priority: Minor
>  Attachments: tc_date.zip
>
> When pressing the calendar icon of a date picker, it will reset the selected value of <tc:selectOneChoice> to first option.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Commented: (TOBAGO-79) Date Picker resets other field values

Posted by "Bernd Bohmann (JIRA)" <de...@myfaces.apache.org>.
    [ http://issues.apache.org/jira/browse/TOBAGO-79?page=comments#action_12416802 ] 

Bernd Bohmann commented on TOBAGO-79:
-------------------------------------

I can't reproduce your problem with the current SNAPSHOT.
I can reproduce your problem with the demo on tobago.atanion.net.

Can you describe you envionment IE?
Can you send me your javascript error. please?

Can you try the tobago-example-demo from 

http://people.apache.org/maven-snapshot-repository/org/apache/myfaces/tobago/tobago-example-demo/1.0.8-SNAPSHOT/

Question 1
May be we will provide a tx alternative of tc:date without a label but with a datepicker.
tx:date contains a tc:label, a tc:date and a tc:datePicker. 
Can you tell me a good name for tx:date without a label and with a datepicker?

Question 2

With the growing ajax support I don't see any need for a client side picker.
It would be great if you submit a patch for a client side date picker.



> Date Picker resets other field values
> -------------------------------------
>
>          Key: TOBAGO-79
>          URL: http://issues.apache.org/jira/browse/TOBAGO-79
>      Project: MyFaces Tobago
>         Type: Bug

>   Components: Core
>     Versions: 1.0.7
>  Environment: Windows XP + Tomcat 5.5
>     Reporter: Kelvin Wong
>     Assignee: Bernd Bohmann
>     Priority: Minor
>  Attachments: tc_date.zip
>
> When pressing the calendar icon of a date picker, it will reset the selected value of <tc:selectOneChoice> to first option.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira