Search in sources :

Example 16 with EditBoxModel

use of org.jaffa.presentation.portlet.widgets.model.EditBoxModel in project jaffa-framework by jaffa-projects.

the class EditBoxForm method setFieldWithKeyBoardWV.

public void setFieldWithKeyBoardWV(String value) {
    EditBoxModel m = (EditBoxModel) getFieldWithKeyBoardWM();
    EditBoxController.updateModel(value, m);
}
Also used : EditBoxModel(org.jaffa.presentation.portlet.widgets.model.EditBoxModel)

Example 17 with EditBoxModel

use of org.jaffa.presentation.portlet.widgets.model.EditBoxModel in project jaffa-framework by jaffa-projects.

the class EditBoxForm method getDataTypeDecimalWM.

public WidgetModel getDataTypeDecimalWM() {
    if (w_dataTypeDecimal == null) {
        w_dataTypeDecimal = new EditBoxModel(new DecimalFieldMetaData("DecimalVal", "DecimalVal", Boolean.FALSE, null, new Double("0"), new Double("20.50"), new Integer("4"), new Integer("2")));
        w_dataTypeDecimal.setValue(getDataTypeDecimal());
    }
    return w_dataTypeDecimal;
}
Also used : EditBoxModel(org.jaffa.presentation.portlet.widgets.model.EditBoxModel) DecimalFieldMetaData(org.jaffa.metadata.DecimalFieldMetaData)

Example 18 with EditBoxModel

use of org.jaffa.presentation.portlet.widgets.model.EditBoxModel in project jaffa-framework by jaffa-projects.

the class EditBoxForm method getDataTypeStringWM.

public WidgetModel getDataTypeStringWM() {
    if (w_dataTypeString == null) {
        w_dataTypeString = new EditBoxModel(new StringFieldMetaData("StringVal", "StringVal", Boolean.TRUE, "[0-9]+", new Integer("8"), FieldMetaData.UPPER_CASE, new Integer("4")));
        w_dataTypeString.setValue(getDataTypeString());
    }
    return w_dataTypeString;
}
Also used : EditBoxModel(org.jaffa.presentation.portlet.widgets.model.EditBoxModel) StringFieldMetaData(org.jaffa.metadata.StringFieldMetaData)

Example 19 with EditBoxModel

use of org.jaffa.presentation.portlet.widgets.model.EditBoxModel in project jaffa-framework by jaffa-projects.

the class EditBoxForm method getDataTypeDateTimeWM.

public WidgetModel getDataTypeDateTimeWM() {
    if (w_dataTypeDateTime == null) {
        w_dataTypeDateTime = new EditBoxModel(new DateTimeFieldMetaData());
        w_dataTypeDateTime.setValue(getDataTypeDateTime());
    }
    return w_dataTypeDateTime;
}
Also used : DateTimeFieldMetaData(org.jaffa.metadata.DateTimeFieldMetaData) EditBoxModel(org.jaffa.presentation.portlet.widgets.model.EditBoxModel)

Example 20 with EditBoxModel

use of org.jaffa.presentation.portlet.widgets.model.EditBoxModel in project jaffa-framework by jaffa-projects.

the class GridComponent method getGridChildren.

public void getGridChildren(String rowNo, String field, GridForm myForm) {
    GridModel w_model1 = (GridModel) myForm.getWidgetCache().getModel(field);
    GridModelRow row;
    System.out.println("The row number is " + rowNo);
    row = w_model1.getRowById(new Integer(rowNo).intValue());
    if ((row.getElement("isExpanded") != null) && (Boolean.TRUE.equals((Boolean) row.getElement("isExpanded")))) {
        return;
    }
    row.addElement("isExpanded", new Boolean(true));
    row.addElement("isDisplayed", new Boolean(true));
    w_model1.setTarget(row);
    row = w_model1.newRow(new Integer(rowNo).intValue() + 1);
    row.addElement("isDisplayed", new Boolean(true));
    row.addElement("isTarget", new Boolean(false));
    row.addElement("isParent", new Boolean(false));
    row.addElement("level", new Integer(4));
    row.addElement("field1", new EditBoxModel("Field91Value"));
    row.addElement("field2", new EditBoxModel("Field92Value"));
    row.addElement("field3", new DateTimeModel(DateTime.addMonth(new DateTime(), 1)));
    row.addElement("field4", new CheckBoxModel(true));
    row.addElement("field5", new ImageModel(ImageComponent.getImageBytes("C:\\Sandbox\\Jaffa\\source\\httpunittest\\html\\widgets\\tests\\testimage1_up.gif")));
    row.addElement("field6", new DropDownModel("Value3"));
}
Also used : GridModel(org.jaffa.presentation.portlet.widgets.model.GridModel) DateTimeModel(org.jaffa.presentation.portlet.widgets.model.DateTimeModel) DropDownModel(org.jaffa.presentation.portlet.widgets.model.DropDownModel) EditBoxModel(org.jaffa.presentation.portlet.widgets.model.EditBoxModel) GridModelRow(org.jaffa.presentation.portlet.widgets.model.GridModelRow) ImageModel(org.jaffa.presentation.portlet.widgets.model.ImageModel) DateTime(org.jaffa.datatypes.DateTime) CheckBoxModel(org.jaffa.presentation.portlet.widgets.model.CheckBoxModel)

Aggregations

EditBoxModel (org.jaffa.presentation.portlet.widgets.model.EditBoxModel)34 GridModelRow (org.jaffa.presentation.portlet.widgets.model.GridModelRow)8 CheckBoxModel (org.jaffa.presentation.portlet.widgets.model.CheckBoxModel)7 GridModel (org.jaffa.presentation.portlet.widgets.model.GridModel)6 FormSelectionMaintenanceOutRowDto (org.jaffa.modules.printing.components.formselectionmaintenance.dto.FormSelectionMaintenanceOutRowDto)4 Iterator (java.util.Iterator)3 DateTime (org.jaffa.datatypes.DateTime)3 ApplicationExceptions (org.jaffa.exceptions.ApplicationExceptions)3 DateOnlyFieldMetaData (org.jaffa.metadata.DateOnlyFieldMetaData)3 DateTimeFieldMetaData (org.jaffa.metadata.DateTimeFieldMetaData)3 DecimalFieldMetaData (org.jaffa.metadata.DecimalFieldMetaData)3 IntegerFieldMetaData (org.jaffa.metadata.IntegerFieldMetaData)3 StringFieldMetaData (org.jaffa.metadata.StringFieldMetaData)3 FormSelectionException (org.jaffa.modules.printing.components.formselectionmaintenance.FormSelectionException)3 DateTimeModel (org.jaffa.presentation.portlet.widgets.model.DateTimeModel)3 DropDownModel (org.jaffa.presentation.portlet.widgets.model.DropDownModel)3 IOException (java.io.IOException)2 InvocationTargetException (java.lang.reflect.InvocationTargetException)2 org.jaffa.components.maint (org.jaffa.components.maint)2 ApplicationException (org.jaffa.exceptions.ApplicationException)2