Srinivas Krishnamoorthy

Greenhorn
+ Follow
since Jul 28, 2008
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Srinivas Krishnamoorthy

If you want to add another row in the table, you can use the getRowData method of HtmlDataTable to get the row which is cliked and insert a new row in the list of the datatable below the current row.

About iframe : HtmlDataTable doesn't allow any HTML content inside it, so try to enclose you HTML code in f:verbatim tag.
15 years ago
JSF
Write a normal JSF forward method to transfer data to the page bean of the pop-up page and return the mapping forward to the pop-up page (Till this point the code should be a complete one to open the page in the same window)

to open the popup use javascript function given below. Call the function in the onmousedown method of the link, popUpScreen('viewbase',this).

The first parameter is just a unique string.

function popUpScreen(targetScreenName,hyperlinkObject) {
newwindow = window.open('',targetScreenName, "height=450,width=650");
if (window.focus) {newwindow.focus()}
document.forms[0].target = targetScreenName;
hyperlinkObject.onclick();
document.forms[0].target = "";
}
15 years ago
JSF
The Best way to use the JSF tags like h:selectBooleanCheckbox, h:dataTable in the JSP to render the components.

You can also create components in the pagebean (like HtmlSelectBooleanCheckbox, HtmlDatatable) and add them as children of the view tag in the jsp and you will get the components without putting the tag in the jsp, but the data in the screen will not bind back to the bean because, the data binding functionality us written in the setProperty method of the respective TagHandler classes
15 years ago
JSF

Originally posted by seb petterson:
I guess there is not. Instead I will get a string for columnClasses from bean method that calculates which styleclasses should be used. I don't like to have stuff that I feel belongs in web content files (jsps etc.) in java code, but oh well.



Yes, the work around you suggested is the best way to do it. I have done in lot of pages (even it costs specifing the styleclass name in the java file)
15 years ago
JSF
No.

We can only add rows to the datatable from the pagebean.

You can add an empty item in the List (an empty map for example) to the list which is bound to the data table.

Regards,
Srinivas
15 years ago
JSF