Package com.googlecode.wicketwebbeans.fields

Examples of com.googlecode.wicketwebbeans.fields.AbstractField


      boolean errorsFound = false;
       
        public Object component(Component component)
        {
            AbstractField field = (AbstractField)component;
            if (field.isRequiredField() && Strings.isEmpty(field.getDefaultModelObjectAsString())) {
              FieldLabel fieldName = new FieldLabel(field.getElementMetaData().getLabel());
              StringResourceModel labelModel = new StringResourceModel("wicketwebbeans.BeanForm.fieldIsRequired", field.getElementMetaData().getBeanMetaData().getComponent(), new Model<FieldLabel>(fieldName), "${fieldLabel} is required");
              BeanForm.this.error(labelModel.getObject().toString());
                errorsFound = true;
            }
           
            return CONTINUE_TRAVERSAL;
View Full Code Here


                public boolean accept(FeedbackMessage message)
                {
                    // If the reporter is a field and this is refreshing because of a non-Ajax form submit, it's very likely that the field has been detached
                    // from its parent because it is in a list view. As a result, findParent doesn't return the BeanForm.
                    Component reporter = message.getReporter();
                    AbstractField reporterField = (AbstractField)(reporter instanceof AbstractField ? reporter : reporter.findParent(AbstractField.class));
                    if (reporterField != null) {
                        return reporterField.getBeanForm().getId().equals(BeanForm.this.getId());
                    }
                   
                    Component parent = (reporter instanceof BeanForm ? reporter : reporter.findParent(BeanForm.class));
                    return reporter == BeanForm.this || parent == null || parent == BeanForm.this;
                }
View Full Code Here

TOP

Related Classes of com.googlecode.wicketwebbeans.fields.AbstractField

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.