Skip to main content
aboutsummaryrefslogblamecommitdiffstats
blob: 59c4e87f1af960b7e7c2b776d0ce32ae7cd3eb86 (plain) (tree)






































                                                                                    
<!-- **************************************************************************
#
# Copyright (c) 2004-2010, CollabNet
#
# All rights reserved. This program and the accompanying materials
# are made available under the terms of the Eclipse Public License v1.0
# which accompanies this distribution, and is available at
# http://www.eclipse.org/legal/epl-v10.html
#
# Contributors: 
#
#   
#        
#
#************************************************************************** --> 

<?jelly escape-by-default='true'?>
<j:jelly xmlns:j="jelly:core" xmlns:st="jelly:stapler" xmlns:d="jelly:define"
 xmlns:l="/lib/layout" xmlns:t="/lib/hudson" xmlns:f="/lib/form">
  <st:documentation>
    Binds a boolean field to two radio buttons that say Yes/No OK/Cancel Top/Bottom.

    <st:attribute name="field">
      Databinding field.
    </st:attribute>
    <st:attribute name="true">
      Text to be displayed for the 'true' value. Defaults to 'Yes'.
    </st:attribute>
    <st:attribute name="false">
      Text to be displayed for the 'false' value. Defaults to 'No'.
    </st:attribute>
  </st:documentation>
  <f:prepareDatabinding />

  <f:radio name="_.${attrs.field}" value="true" checked="${instance[field]}" />
  <label class="attach-previous">${attrs['true']?:'%Yes'}</label>
  <f:radio name="_.${attrs.field}" value="false" checked="${!instance[field]}" />
  <label class="attach-previous">${attrs['false']?:'%No'}</label>
</j:jelly>

Back to the top