}
});
statusField.addRecordClickHandler(new RecordClickHandler() {
@Override
public void onRecordClick(RecordClickEvent event) {
Record record = event.getRecord();
String statusStr = record.getAttribute(AbstractOperationHistoryDataSource.Field.STATUS);
OperationRequestStatus status = OperationRequestStatus.valueOf(statusStr);
if (status == OperationRequestStatus.FAILURE) {
final Window winModal = new Window();
winModal.setTitle(MSG.common_title_details());
winModal.setOverflow(Overflow.VISIBLE);
winModal.setShowMinimizeButton(false);
winModal.setShowMaximizeButton(true);
winModal.setIsModal(true);
winModal.setShowModalMask(true);
winModal.setAutoSize(true);
winModal.setAutoCenter(true);
winModal.setShowResizer(true);
winModal.setCanDragResize(true);
winModal.centerInPage();
winModal.addCloseClickHandler(new CloseClickHandler() {
@Override
public void onCloseClick(CloseClickEvent event) {
winModal.markForDestroy();
}
});
HTMLPane htmlPane = new HTMLPane();
htmlPane.setMargin(10);
htmlPane.setDefaultWidth(500);
htmlPane.setDefaultHeight(400);
String errorMsg = record.getAttribute(AbstractOperationHistoryDataSource.Field.ERROR_MESSAGE);
if (errorMsg == null) {
errorMsg = MSG.common_status_failed();
}
htmlPane.setContents("<pre>" + errorMsg + "</pre>");
winModal.addItem(htmlPane);