use of cn.cerc.jpage.fields.ButtonField in project summer-mis by cn-cerc.
the class UIFormHorizontal method readAll.
public ButtonField readAll() {
if (readAll) {
return submit;
}
if (buttons == null) {
return submit;
}
submit = null;
// 取 form submit 按钮
for (AbstractField field : buttons.getFields()) {
if (field instanceof ButtonField) {
ButtonField button = (ButtonField) field;
String key = button.getField();
String val = request.getParameter(key);
if (val != null && val.equals(button.getData())) {
submit = button;
break;
}
}
}
// 将用户值或缓存值存入到dataSet中
for (AbstractField field : this.fields) field.updateField();
// 将可折叠字段的值存入到dataSet中
for (IField field : this.getExpender().getFields()) ((AbstractField) field).updateField();
readAll = true;
return submit;
}
Aggregations