attrhead.add(new Label("resource", propTO.getResource()));
attrhead.add(new Label("propagation", propTO.getStatus() == null
? "UNDEFINED" : propTO.getStatus().toString()));
final Image image;
final String alt, title;
final ModalWindow failureWindow = new ModalWindow("failureWindow");
final AjaxLink<?> failureWindowLink = new AjaxLink<Void>("showFailureWindow") {
private static final long serialVersionUID = -7978723352517770644L;
@Override
public void onClick(AjaxRequestTarget target) {
failureWindow.show(target);
}
};
switch (propTO.getStatus()) {
case SUCCESS:
case SUBMITTED:
case CREATED:
image = new Image("icon", IMG_STATUSES + StatusUtils.Status.ACTIVE.toString()
+ Constants.PNG_EXT);
alt = "success icon";
title = "success";
failureWindow.setVisible(false);
failureWindowLink.setEnabled(false);
break;
default:
image = new Image("icon", IMG_STATUSES + StatusUtils.Status.SUSPENDED.toString()
+ Constants.PNG_EXT);
alt = "failure icon";
title = "failure";
}
image.add(new Behavior() {
private static final long serialVersionUID = 1469628524240283489L;
@Override
public void onComponentTag(final Component component, final ComponentTag tag) {