I think I've mentioned this before, but export functionality will not work correctly.

Dennis



Andrew Close <[EMAIL PROTECTED]>
Sent by: [EMAIL PROTECTED]

07/20/2004 05:03 PM

Please respond to
[EMAIL PROTECTED]

To
DisplayTag <[EMAIL PROTECTED]>
cc
Subject
[displaytag-user] Re: My complicated table...





Ok, i somewhat figured this out.  you can't use Struts tags (at least
'i' can't) inside of display tag.  so instead i just use the html tags
<input type=checkbox, type=text, etc.  so the table looks like:

<display:table name="items" id="parent">
     <display:column property="specialCode" title="SC"/>
     <display:column title="SEL">
             <input type="checkbox"
id="check_<%=((SLItem)parent).getItemId()%>">
     </display:column>
     <display:column title="LINE">
             <input type="text" size="5" maxlength="4"
id="text_<%=new Long(((SLItem)parent).getItemId()).toString()%>"
value="<%=((SLItem)parent).getItemSeqNbr()%>" >
     </display:column>
     <display:column property="desc" title="DESCRIPTION"/>
     <display:column property="brand" title="BRAND"/>
     <display:column property="packSize" title="PACK"/>
     <display:column property="casePrice" title="PRICE"/>
     <display:column property="groupName" title="GROUP"/>
     <display:column property="refNum" title="REFERENCE"/>
</display:table>

now i just need to clean up the beans so they contain Strings and will
work nicely with Struts and DisplayTag.

andy

On Tue, 20 Jul 2004 13:18:40 -0500, Andrew Close <[EMAIL PROTECTED]> wrote:
> Ok, i've got a couple fairly simple tables working and now i'd like to
> try something a bit more real world, but i've hit a snag. :)
> in my table i would like to have a couple editable fields in each row.
> one is a checkbox so a user can delete or pick specific items. and
> the other is a comment tag.  it's these editable fields that are
> giving me problems.  displaytag does a wonderful job of iterating
> through a list of data and displaying it.  but i'm still an ignorant
> newbie and haven't quite figured out how to get it to play nice with
> embedded objects.
> here is the table that i have set up so far:
>
> <display:table name="items" id="parent">
>        <display:column property="specialCode" title="SC"/>
>        <display:column title="SEL">
>                <html:checkbox property="items.itemId" />
>        </display:column>
>        <display:column title="LINE">
>                <html:text property="lineNbr" value=""/>
>        </display:column>
>        <display:column property="desc" title="DESCRIPTION"/>
>        <display:column property="brand" title="BRAND"/>
>        <display:column property="packSize" title="PACK"/>
>        <display:column property="casePrice" title="PRICE"/>
>        <display:column property="groupName" title="GROUP"/>
>        <display:column property="refNum" title="REFERENCE"/>
> </display:table>
>
> i would like to give the checkbox the unique id of each object being
> displayed and do the same for the textfield.  the textfield will also
> have to display any previously saved value.
> the way i have this coded now i end up getting an error that there is
> no getter method for property for items.itemId of bean...  this is
> correct since items is the collection i'm passing in.  any suggestions
> on how to handle this type of situation?
>
> Thank you
> andy
>


-------------------------------------------------------
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=4721&alloc_id=10040&op=click
_______________________________________________
displaytag-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/displaytag-user

Reply via email to