use of org.ovirt.engine.ui.common.widget.table.column.AuditLogSeverityColumn in project ovirt-engine by oVirt.
the class EventListModelTable method initTable.
@Override
public void initTable() {
getTable().enableColumnResizing();
AuditLogSeverityColumn severityColumn = new AuditLogSeverityColumn();
severityColumn.setContextMenuTitle(constants.severityEvent());
// $NON-NLS-1$
getTable().addColumn(severityColumn, constants.empty(), "20px");
AbstractTextColumn<AuditLog> logTimeColumn = new AbstractFullDateTimeColumn<AuditLog>() {
@Override
protected Date getRawValue(AuditLog object) {
return object.getLogTime();
}
};
logTimeColumn.makeSortable(AuditLogConditionFieldAutoCompleter.TIME);
// $NON-NLS-1$
getTable().addColumn(logTimeColumn, constants.timeEvent(), "170px");
AbstractTextColumn<AuditLog> messageColumn = new AbstractTextColumn<AuditLog>() {
@Override
public String getValue(AuditLog object) {
return object.getMessage();
}
};
messageColumn.makeSortable(AuditLogConditionFieldAutoCompleter.MESSAGE);
// $NON-NLS-1$
getTable().addColumn(messageColumn, constants.messageEvent(), "600px");
AbstractTextColumn<AuditLog> correlationIdColumn = new AbstractTextColumn<AuditLog>() {
@Override
public String getValue(AuditLog object) {
return object.getCorrelationId();
}
};
correlationIdColumn.makeSortable(AuditLogConditionFieldAutoCompleter.CORRELATION_ID);
// $NON-NLS-1$
getTable().addColumn(correlationIdColumn, constants.correltaionIdEvent(), "100px");
AbstractTextColumn<AuditLog> originColumn = new AbstractTextColumn<AuditLog>() {
@Override
public String getValue(AuditLog object) {
return object.getOrigin();
}
};
originColumn.makeSortable(AuditLogConditionFieldAutoCompleter.ORIGIN);
// $NON-NLS-1$
getTable().addColumn(originColumn, constants.originEvent(), "100px");
AbstractTextColumn<AuditLog> customEventIdColumn = new AbstractTextColumn<AuditLog>() {
@Override
public String getValue(AuditLog object) {
int id = object.getCustomEventId();
// $NON-NLS-1$
return id >= 0 ? String.valueOf(id) : "";
}
};
customEventIdColumn.makeSortable(AuditLogConditionFieldAutoCompleter.CUSTOM_EVENT_ID);
// $NON-NLS-1$
getTable().addColumn(customEventIdColumn, constants.customEventIdEvent(), "120px");
}
use of org.ovirt.engine.ui.common.widget.table.column.AuditLogSeverityColumn in project ovirt-engine by oVirt.
the class AdvancedViewColumns method initTable.
void initTable() {
getTable().enableColumnResizing();
AuditLogSeverityColumn severityColumn = new AuditLogSeverityColumn();
severityColumn.setContextMenuTitle(constants.severityEvent());
// $NON-NLS-1$
getTable().addColumn(severityColumn, constants.empty(), "30px");
AbstractTextColumn<AuditLog> logTimeColumn = new AbstractFullDateTimeColumn<AuditLog>() {
@Override
protected Date getRawValue(AuditLog object) {
return object.getLogTime();
}
};
logTimeColumn.makeSortable(AuditLogConditionFieldAutoCompleter.TIME);
// $NON-NLS-1$
getTable().addColumn(logTimeColumn, constants.timeEvent(), "175px");
messageColumn = new AbstractTextColumn<AuditLog>() {
@Override
public String getValue(AuditLog object) {
return object.getMessage();
}
};
messageColumn.makeSortable(AuditLogConditionFieldAutoCompleter.MESSAGE);
getTable().addColumn(messageColumn, constants.messageEvent(), BASIC_VIEW_MSG_COLUMN_WIDTH);
}
Aggregations