Results 1 to 2 of 2
  1. #1
    Samurai Coder is offline Member
    Join Date
    Dec 2009
    Posts
    5
    Rep Power
    0

    Default SELECTED select menu??

    I am not sure how seam allows me to select if the selectedPaymentMethod has the defaultflag. I was just told the defaultflag holds the value. My job is to make it the first in the SelectList if it holds the true value.

    So I thought maybe a c:choose tree might work?

    Java Code:
    <c:choose>
    <c:when test="#{customerSession.selectedPaymentMethod.defaultFlag} == true">
    
    <s:selectItems id="billing01_payments" var="_var"
    	label="#{_var.formattedAddress}"
    	value="#{customerSession.payments}" />
    
    </c:when>
    <c:otherwise>
    
    <s:selectItems id="billing01_payments" var="_var"
    	label="#{_var.formattedAddress}" noSelectionLabel="New Card"
    	value="#{customerSession.payments}" />
    
    </c:otherwise>
    </c:choose>
    Does anyone know how to make this work? Sure not as easy as ASP classic. LOL

  2. #2
    Samurai Coder is offline Member
    Join Date
    Dec 2009
    Posts
    5
    Rep Power
    0

    Default Backing Bean?

    This wont work at all will it? :(

    Something has to be done in the backing bean correct?

Similar Threads

  1. How to retain value in struts 2 using <s:select></s:select> tag
    By SaiPrasad@Sella in forum Web Frameworks
    Replies: 0
    Last Post: 02-09-2009, 08:23 AM
  2. Fill a menu dynamically when menu is shown
    By Java Tip in forum SWT Tips
    Replies: 0
    Last Post: 07-07-2008, 05:47 PM
  3. How to use SWT menu and menu event
    By Java Tip in forum SWT Tips
    Replies: 0
    Last Post: 07-07-2008, 05:46 PM
  4. React to menu action and checkbox menu
    By Java Tip in forum javax.swing
    Replies: 0
    Last Post: 06-27-2008, 08:50 PM
  5. Replies: 7
    Last Post: 05-09-2008, 08:54 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •