[TOBAGO] problem selecting current item in tx:selectOneChoice

2010-04-21 Thread Michael Kakuschky

Hello,

I have a strange problem selecting the correct item of 
tx:selectOneChoice boxes if the  itemValue of the tc:selectItem item is 
an Integer.


Storing the selected values works fine as aspected. I will find the 
correct values in mybackend database


What does not work is that after rerendering the correct value is 
selected. If in my example the MyController.active Integer attribute has 
a value of 1 "suspended" should be selected. But it's always the first 
value of the tc:selectItem elements selected.


I tried already to use a converter because  I guessed that  there is an 
conversion problem between Integer  and String but it does not help.


If the selectItem bind to a String  it works fine (sure without the 
integerConverter). With the tomahawk h:selectOneMenu component it works 
also with Integers.


Knows anybody how to solve this problem for tobago to use an Integer as 
value attribute?



converter="integerConverter">







public class MyController{
   private Integer active = 1;

   public Integer getActive() {
   return active;
   }
   public void setActive(Integer active) {
   this.active = active;
   }
}

public class IntegerConverter  implements Converter {

 public Object getAsObject(FacesContext context, UIComponent component, 
String value) throws ConverterException {

   return Integer.getInteger(value);
 }

public String getAsString(FacesContext context, UIComponent component, 
Object value) throws ConverterException {

   if (value instanceof Integer) {
 return ((Integer) value).toString();
   }
   return "";
 }
}

Thanks and best regards

Michael


Re: rendering problem in script section

2010-04-21 Thread Jakob Korherr
Hi Marcus,

I just created MYFACES-2668 and I will fix it asap.

Regards,
Jakob

2010/4/21 Marcus Büttner 

> Hi,
>
> the HtmlResponseWriter from MyFaces does not render the comment end in a
> script section if  other html elements are rendered in this script sections,
> like primefaces does in DataTable with columnFilter.
>
> The DataTable renders e.g. input tags in the javascript part and therefore
> it uses the startElement of the ResponseWriter. This overrides the current
> startElement. So the end element of the script section can't remember it was
> a script and doesn't render the end comment (-->) before script end tag.
>
> For me it looks like an issue or is it forbidden to render html tags in
> javascript section?
>
> Thx, regards
> Marcus
>
>
>


-- 
Jakob Korherr

blog: http://www.jakobk.com
twitter: http://twitter.com/jakobkorherr
work: http://www.irian.at


Re: Problem with MyFaces debug Utilities for dataTables with ValueExpression wich includes parameters

2010-04-21 Thread Jakob Korherr
Hi Marcus,

Thanks for pointing that out. I just created MYFACES-2667 and will fix it
asap!

Regards,
Jakob

2010/4/20 Marcus Büttner 

> Hi,
>
> I have a problem with ValueExpression which includes Parameters for
> DataTables.
>
> Example:
>
> 
>  
>  ...
>  
>  ...
> 
>
> Rendering works fine, but after rendering DebugUtils.traceView ist called.
> Than the method printComponent tries to write attributes of the inner
> dataTable. At "rowAvailable" attribute a new DataModel is created an
> myBean.getDetailList is called with master = null.
>
> But null is not really a valid value and I don't want to handle a null
> value because of MyFaces debugging Uitlities.
>
> Is there another way to solve the problem?
>
> Thx, regards
> Marcus
>



-- 
Jakob Korherr

blog: http://www.jakobk.com
twitter: http://twitter.com/jakobkorherr
work: http://www.irian.at


How to add new css to Tobago

2010-04-21 Thread tobagouser

Hi All,

I have tried to add tobago-box-footer to the style.css ,but it never
affected the pages.Please could you let me know how to add a new css to
tobago.

Thanks,
KSK


-- 
View this message in context: 
http://old.nabble.com/How-to-add-new-css-to-Tobago-tp28288029p28288029.html
Sent from the MyFaces - Users mailing list archive at Nabble.com.



rendering problem in script section

2010-04-21 Thread Marcus Büttner

Hi,

the HtmlResponseWriter from MyFaces does not render the comment end in a 
script section if  other html elements are rendered in this script 
sections, like primefaces does in DataTable with columnFilter.


The DataTable renders e.g. input tags in the javascript part and 
therefore it uses the startElement of the ResponseWriter. This overrides 
the current startElement. So the end element of the script section can't 
remember it was a script and doesn't render the end comment (-->) before 
script end tag.


For me it looks like an issue or is it forbidden to render html tags in 
javascript section?


Thx, regards
Marcus




[EXT-SCRIPTING] A little bit of community help needed

2010-04-21 Thread Werner Punz
Hello Everyone, this is not an official announcment but more a call for 
a little bit of community help.
I am close to releasing the first stable version of a new MyFaces 
subproject. Apache MyFaces Extension-Scripting (Ext-Scripting).


To sum it up, Ext-Scripting is a project which tries to integrate 
scripting languages into the JSF universe and also provides additionally 
to that JSP like recompilation of Java code within the domain of JSF 
(currently only MyFaces)


We are close to a 1.0 version which will be tagged within a few weeks 
timeframe, and I want the documentation to be as good as possible, since

due to my personal opinion, a project needs a good documentation to help
people getting started.

But now here is my problem, since I am the lead developer of the project 
and I am sort of blind regarding my own project, I would like
to have people looking over the documentation, which have a clear mind, 
to give me feedback and suggestions on improving the current state of 
the documentation.


Please have a look here on my private hosting of the current 
documentation snapshot and give me feedback if the information is enough 
to get someone who touches the project for the first time,
is enough to get him/her started (Hence I am posting this in the users 
list)!


http://people.apache.org/~werpu/ext-script-site/

Thanks in advance, for providing me the input to make the documentation 
first class.


Werner Punz