Add print action to mindmapList

This commit is contained in:
Paulo Gustavo Veiga 2012-04-14 18:52:24 -03:00
parent eb2efd2db0
commit 728ef7eb6b
2 changed files with 13 additions and 8 deletions

View File

@ -265,6 +265,16 @@
icons: { primary: "ui-icon-trash" }
});
$("#buttons .printMap").button({
icons: { primary: "ui-icon-trash" }
}).click(function() {
var mapIds = $('#mindmapListTable').dataTableExt.getSelectedMapsIds();
if (mapIds.length > 0) {
window.open('c/map/' + mapIds[0] + '/print.htm');
}
});
$("#buttons .moreActions").button({
icons: { primary: "ui-icon-triangle-1-s" }
});
@ -379,6 +389,7 @@
<button class="delete">Delete</button>
<button class="renameMap">Rename</button>
<button class="importMap">Import</button>
<button class="printMap">Print</button>
<button class="moreActions">More</button>
</div>

View File

@ -12,15 +12,9 @@
<%@ include file="/jsp/init.jsp" %>
<%
Calendar calendar = Calendar.getInstance(request.getLocale());
calendar.setTimeInMillis(System.currentTimeMillis());
DateFormat dateFormat = SimpleDateFormat.getDateTimeInstance(DateFormat.DEFAULT, DateFormat.DEFAULT, request.getLocale());
String todayString = dateFormat.format(calendar.getTime());
%>
<html>
<head>
<base href="../"/>
<base href="${pageContext.request.contextPath}/"/>
<title><spring:message code="SITE.TITLE"/> - ${mindmap.title} </title>
<meta http-equiv="Content-type" content="text/html; charset=UTF-8"/>
@ -112,7 +106,7 @@
<div id="mapContainer">
<%--<div id="infoPanel">--%>
<%--<div id="dragImageNode" style="cursor: move">--%>
<%--<div id="dragImageNode" style="cursor: move">--%>
<%--</div>--%>
<div id="mindplot"></div>
<div id="printLogo"></div>