use of com.evolveum.midpoint.web.page.admin.reports.dto.JasperReportFieldDto in project midpoint by Evolveum.
the class JasperReportConfigurationPanel method deleteFieldPerformed.
private void deleteFieldPerformed(AjaxRequestTarget target) {
Iterator<JasperReportFieldDto> iterator = getModelObject().getJasperReportDto().getFields().iterator();
while (iterator.hasNext()) {
JasperReportFieldDto item = iterator.next();
if (item.isSelected()) {
iterator.remove();
}
}
target.add(getFieldsTable());
}
use of com.evolveum.midpoint.web.page.admin.reports.dto.JasperReportFieldDto in project midpoint by Evolveum.
the class JasperReportConfigurationPanel method fieldEditPerformed.
private void fieldEditPerformed(AjaxRequestTarget target, IModel<JasperReportFieldDto> rowModel) {
JasperReportFieldDto parameter = rowModel.getObject();
parameter.setEditing(true);
target.add(getFieldsTable());
}
use of com.evolveum.midpoint.web.page.admin.reports.dto.JasperReportFieldDto in project midpoint by Evolveum.
the class JasperReportConfigurationPanel method initFiledsTable.
private void initFiledsTable() {
ISortableDataProvider<JasperReportFieldDto, String> provider = new ListDataProvider<JasperReportFieldDto>(this, new PropertyModel<List<JasperReportFieldDto>>(getModel(), "jasperReportDto.fields"));
BoxedTablePanel<JasperReportFieldDto> table = new BoxedTablePanel<JasperReportFieldDto>(ID_FIELDS_TABLE, provider, initFieldColumns(), null, 10);
// table.setShowPaging(false);
table.setOutputMarkupId(true);
add(table);
AjaxButton addParameter = new AjaxButton(ID_BUTTON_ADD_FIELD, createStringResource("JasperReportConfigurationPanel.addField")) {
private static final long serialVersionUID = 1L;
@Override
public void onClick(AjaxRequestTarget target) {
addFieldPerformed(target);
}
};
add(addParameter);
AjaxButton deleteParameter = new AjaxButton(ID_DELETE_FIELD, createStringResource("JasperReportConfigurationPanel.deleteField")) {
private static final long serialVersionUID = 1L;
@Override
public void onClick(AjaxRequestTarget target) {
deleteFieldPerformed(target);
}
};
add(deleteParameter);
}
use of com.evolveum.midpoint.web.page.admin.reports.dto.JasperReportFieldDto in project midpoint by Evolveum.
the class JasperReportConfigurationPanel method addFieldPerformed.
private void addFieldPerformed(AjaxRequestTarget target) {
ReportDto dto = getModel().getObject();
JasperReportFieldDto parameter = new JasperReportFieldDto();
parameter.setEditing(true);
dto.getJasperReportDto().getFields().add(parameter);
BoxedTablePanel<JasperReportFieldDto> fieldsTable = getFieldsTable();
adjustFieldsTablePage(fieldsTable, dto);
target.add(getFieldsTable());
}
Aggregations