ClientValidateDecimal

Version 6 by Ken Fyten
on Jan 06, 2016 11:06.


compared with
Current by Ken Fyten
on Sep 29, 2016 10:52.


 
Key
These lines were removed. This word was removed.
These lines were added. This word was added.

View page history


There are 1 changes. View first change.

 h2. Overview
 _Since 4.1_
  
 The _ace:clientValidateDecimal_ component validates the input of the enclosing component by allowing only decimal values to be submitted.
  
 {tip}See the ICEfaces Showcase [Live Demo|http://icefaces-showcase.icesoft.org/showcase.jsf?grp=ace:clientValidateDecimal] of this component, complete with source code.{tip}
  
  
 h2. Getting Started
 {panel}
 {code:xml|borderStyle=dashed}
 <html ... xmlns:ace="http://www.icefaces.org/icefaces/components">
 <h:body>
  <h:form>
  <ace:textEntry id="textEntry1" value="#{clientValidateDecimalBean.value1}"
  label="Amount" labelPosition="left" size="8">
  <ace:clientValidateDecimal />
  </ace:textEntry>
  ...
  </h:form>
  ...
 </h:body>
 </html>
 {code}
 {panel}
 h2. Attributes
  
 {tip:title=TagLib Documentation}This section covers attributes involved in the typical use-cases for this component. For reference, the complete taglib documentation for this component is available [here|http://www.icefaces.org/docs/v4_latest/ace/tld/ace/clientValidateDecimal.html].{tip}
 {panel}
 *enabled* can enable or disable the validation. By default validation is enabled (value is _true_).
 {panel}
  
 h2. Validation Behaviour
  
 * Client validation occurs initially when the component value is attempted to be submitted to the server, either via an ace:ajax partial-submit or a full form submit. If the client validation fails the submit to the server is aborted and the appropriate error message is displayed in an associated ace:message, ace:messages, or ace:growlMessages component (without requiring a server-roundtrip). Thus, a form submit with multiple components is processed atomically and will be completely aborted if any of the components within it fail client validation.
 * Before submitting an entered component value the first time (either via full form submit, or an ace:ajax partial-submit), the user can tab through components in the form without triggering annoying validation messages - they won't get bugged before having the chance to actually enter a correct value.
 * However, once a component is marked invalid by a previous validation failure, it is eagerly validated: As soon as the user has entered the necessary value, the error message is removed, without requiring a form submit.
 * Client validation supports the "immediate='true'" attribute on ace:pushButton and ace:linkButton. When "immediate='true'" the button submit will occur regardless of whether one or more components in the form are failing client validation.
  
 h2. Event Listeners
  
 No direct event listener is associated with this component.
  
 h2. Client Behavior Events
  
 No direct client behavior is associated with this component.
  
 h2. JavaScript API
  
 Not applicable.
  
 h2. Keyboard and ARIA Support
  
 Not applicable.
  
 h2. CSS Classes
  
 Not applicable.
  
 h2. Known Issues
  
  None.
  * Client Validation is not supported with the ace:maskedEntry component.
  
 h2. Additional Resources
  
 None.

© Copyright 2018 ICEsoft Technologies Canada Corp.