We have a couple (about a hundred) of tables with the same structure (Code, Description, Create Date, Update Date). So I wanted to do something simple so that I did not have to create all these screens 1) EO I created the EO based on one of the tables I had that had the above columns. I then Added a transient attribute called table name to my EO based on a groovy expression. (the expression needs to change as I am reading web tier stuff from the model layer but I will fix this later) I then generated a java class for my EO. And added the following overriden method to my newly created java class. protected StringBuffer buildDMLStatement(int i, AttributeDefImpl[] attributeDefImpl, AttributeDefImpl[] attributeDefImpl2, AttributeDefImpl[] attributeDefImpl3, boolean b) { StringBuffer statement = super.buildDMLStatement( i, attributeDefImpl, attributeDefImpl2, attributeDefImpl3, b); return new StringBuffer(StringUtils.replace(statement.to...
Hi Could you please elaborate on the example.
ReplyDeletei have a similar requirement where i have to make the first row as default when the table is populated by the query panel.
i do not know where to place this code.
Please help
I usually do this on the queryListener in the af:query. Have you tried a displayRow="first" on you table it may be simpler depending on your requirement.
Deletecan i use:
ReplyDeleteObject rowKey = resultTable.getScrollTopRowKey();
instead of:
Object rowKey = resultTable.getAttributes().get("scrollTopRowKey");?
I want the first row in my manageBean
ReplyDelete