NIHVIVO-161 Add dialog box to the "delete" link for an image on the Individual page.
This commit is contained in:
parent
93ce1c2353
commit
83afb6c5f0
2 changed files with 13 additions and 2 deletions
|
@ -687,8 +687,15 @@ public class PropertyEditLinks extends TagSupport{
|
||||||
private LinkStruct getImageLink(String subjectUri, String contextPath,
|
private LinkStruct getImageLink(String subjectUri, String contextPath,
|
||||||
String action, String mouseOverText, String text) {
|
String action, String mouseOverText, String text) {
|
||||||
ImageLinkStruct ls = new ImageLinkStruct();
|
ImageLinkStruct ls = new ImageLinkStruct();
|
||||||
String url = makeRelativeHref(contextPath + "uploadImages",
|
String url;
|
||||||
"entityUri", subjectUri, "action", action);
|
if (action == "delete") {
|
||||||
|
url = "javascript:delete_photo('"
|
||||||
|
+ makeRelativeHref(contextPath + "uploadImages",
|
||||||
|
"entityUri", subjectUri, "action", action) + "')";
|
||||||
|
} else {
|
||||||
|
url = makeRelativeHref(contextPath + "uploadImages", "entityUri",
|
||||||
|
subjectUri, "action", action);
|
||||||
|
}
|
||||||
ls.setHref(url);
|
ls.setHref(url);
|
||||||
ls.setType(action);
|
ls.setType(action);
|
||||||
ls.setMouseoverText(mouseOverText);
|
ls.setMouseoverText(mouseOverText);
|
||||||
|
|
|
@ -306,3 +306,7 @@ if (VitroRequestPrep.isSelfEditing(request) || LoginFormBean.loggedIn(request, L
|
||||||
</div> <!-- contents -->
|
</div> <!-- contents -->
|
||||||
|
|
||||||
</div> <!-- content -->
|
</div> <!-- content -->
|
||||||
|
|
||||||
|
<script type="text/javascript" src="/vivo/js/imageUpload/confirmPhotoDeletion.js"></script>
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue