Record's BooleanField has broken tabindex #1239

Merged
merged 1 commit into from May 14, 2012
@@ -40,7 +40,7 @@ trait BooleanTypedField extends TypedField[Boolean] {
def setFromString(s: String): Box[Boolean] = setBox(tryo(toBoolean(s)))
private def elem(attrs: SHtml.ElemAttr*) =
- SHtml.checkbox(valueBox openOr false, (b: Boolean) => this.setBox(Full(b)), (("tabIndex" -> tabIndex.toString): SHtml.ElemAttr) :: attrs.toList: _*)
+ SHtml.checkbox(valueBox openOr false, (b: Boolean) => this.setBox(Full(b)), (("tabindex" -> tabIndex.toString): SHtml.ElemAttr) :: attrs.toList: _*)
def toForm: Box[NodeSeq] =
// FIXME? no support for optional_?
@@ -189,7 +189,6 @@ object FieldSpec extends Specification("Record Field Specification") {
case _ => false
}) andThen "* [value]" #> ".*"))(fprime)
val ret: Boolean = Helpers.compareXml(f, fp)
-
ret must_== true
}
}
@@ -217,7 +216,7 @@ object FieldSpec extends Specification("Record Field Specification") {
rec.mandatoryBooleanField,
JsTrue,
JBool(bool),
- Full(<input checked="checked" tabIndex="1" value="true" type="checkbox" name=".*" id="mandatoryBooleanField_id"></input><input value="false" type="hidden" name=".*"></input>)
+ Full(<input checked="checked" tabindex="1" value="true" type="checkbox" name=".*" id="mandatoryBooleanField_id"></input><input value="false" type="hidden" name=".*"></input>)
)
"support java.lang.Boolean" in {
rec.mandatoryBooleanField.setFromAny(java.lang.Boolean.TRUE)