Changeset 4808


Ignore:
Timestamp:
03/21/14 13:15:52 (10 years ago)
Author:
Twan Goosen
Message:

Link to resource identified with handle is prepended with handle proxy (showing handle)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • vlo/branches/vlo-3.0/vlo-web-app/src/main/java/eu/clarin/cmdi/vlo/wicket/panels/ResourceLinkDetailsPanel.java

    r4661 r4808  
    1818
    1919import eu.clarin.cmdi.vlo.pojo.ResourceInfo;
     20import eu.clarin.cmdi.vlo.wicket.model.HandleLinkModel;
    2021import org.apache.wicket.markup.html.basic.Label;
    2122import org.apache.wicket.markup.html.link.ExternalLink;
     
    4142        add(new Label("resourceType"));
    4243
    43         final ExternalLink link = new ExternalLink("link", new PropertyModel<String>(model, "href"));
     44        final ExternalLink link = new ExternalLink("link",
     45                // wrap href in model that transforms handle links
     46                new HandleLinkModel(new PropertyModel<String>(model, "href")));
     47        // the label gets the original link
    4448        link.add(new Label("href"));
    4549        add(link);
Note: See TracChangeset for help on using the changeset viewer.