Hi Mohammad,
I did something similar as I needed paging and most of the Grid
functionality without showing a grid. My approach was to extend the
Grid, GridRows and GridColumns components. Most java code did stay the
same, but the regarding templates got updated to my clients requirements.
A schematic example:
MyGrid extends Grid {
@Component(
parameters = {
"columnIndex=inherit:columnIndex",
"rowsPerPage=rowsPerPage",
"currentPage=currentPage",
"row=row",
"overrides=overrides" },
publishParameters = "rowIndex,rowClass,volatile,encoder,lean")
private MyGridRows rows;
}
MyGridRows extends GridRows {
// nothing overwritten here, magic is in the template
}
---
MyGridRows.tml
<div class="grid-content">
<ul class="${rowClass}" xml:space="default"
xmlns:t="http://tapestry.apache.org/schema/tapestry_5_1_0.xsd">
<t:loop source="propertyNames" value="propertyName" index="columnIndex"
formstate="none">
<li class="${cellClass}" t:type="any" t:mixins="NotEmpty">
<t:gridcell model="columnModel" object="row" overrides="overrides"/>
</li>
</t:loop>
</ul>
</div>
---
Now the details are shown in a list instead of a table and therefore
leave designers plenty of options.
Hope that helps, though I'm not sure it's the best solution to tackle
the issue (still worked for me).
Regards
Daniel
Am 01.11.2010 16:03, schrieb Muhammad Mohsen:
I have no considerable designing experience to argue with your statement.
It's just that sometimes a client would insist on having a table-less
application. Unless I can't override the Grid to render using tables, I
can't accept the job. That's all :)
I wish the mailing list is always active is its since the last hour or so :D
On Mon, Nov 1, 2010 at 4:31 PM, Juan E. Maya<maya.j...@gmail.com> wrote:
Muhammad, as the article points out, tableless design is: "...a
philosophy eschewing the use of HTML tables for page layout control
purposes."
Tables have a very good purpose in HTML they should be used to display
tabular data (A grid is exactly that). The problem is that 10 years
ago tables were used to create the layout of the page causing the
problems you point out.
if you keep reading the article they mention the following. "..while
others are now afraid to introduce a simple HTML table even where it
makes good sense,[3] some erring by the overuse of span and div
elements, perhaps even with table-like rules applied to them using
CSS.[4]"
On Mon, Nov 1, 2010 at 3:23 PM, Muhammad Mohsen<m.gelb...@gmail.com>
wrote:
It's a debate, whether to use tables or divs.
Check this page:http://en.wikipedia.org/wiki/Tableless_web_design
<http://en.wikipedia.org/wiki/Tableless_web_design>Search for: "This
causes
a number of problems"
Also it's sometimes a client request that the web application
becomes table-less and only DIVs are to be used. As I can't find a firm
evidence that either is better or if there is even a difference, I can't
convince my client other wise.
On Mon, Nov 1, 2010 at 4:01 PM, Thiago H. de Paula Figueiredo<
thiag...@gmail.com> wrote:
On Mon, 01 Nov 2010 11:54:17 -0200, Muhammad Mohsen<
m.gelb...@gmail.com>
wrote:
Hello everyone,
Hi!
Is there a way I can override the Grid component to use "div"s instead
of
tables ?
I don't think so. Why do you want that?
And to hide the header shown.
You can CSS to hide it from view or use DOM rewriting to remove it from
the
output.
--
Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer,
and instructor
Owner, Ars Machina Tecnologia da Informação Ltda.
http://www.arsmachina.com.br
---------------------------------------------------------------------
To unsubscribe, e-mail:users-unsubscr...@tapestry.apache.org
For additional commands, e-mail:users-h...@tapestry.apache.org
--
*Regards,*
*Muhammad Gelbana
Java Software Programmer*
---------------------------------------------------------------------
To unsubscribe, e-mail:users-unsubscr...@tapestry.apache.org
For additional commands, e-mail:users-h...@tapestry.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org