- Fix duplicate map bug.

This commit is contained in:
Paulo Gustavo Veiga 2012-06-24 20:25:27 -03:00
parent c4ad5810da
commit ec41dafcf5
3 changed files with 9 additions and 10 deletions

View File

@ -413,7 +413,6 @@ public class MindmapController extends BaseController {
final MindMap clonedMap = mindMap.shallowClone();
clonedMap.setTitle(restMindmap.getTitle());
clonedMap.setDescription(restMindmap.getDescription());
clonedMap.setCreator(user);
// Add new mindmap ...
mindmapService.addMindmap(clonedMap, user);

View File

@ -65,7 +65,8 @@ FILE=File
FILE_URL=File URL
STATUS=Status
LAST_EDITOR=Last Edition
LAST_UPDATE=Last Update
LAST_UPDATE_BY=Last Update By
DELETE_SELECTED_CONFIRMATION=All selected Maps will be deleted. Do you want to continue?
DELETE_CONFIRMATION=Are you sure that you want to delete this map?
DELETE_SELECTED=Delete selected

View File

@ -425,35 +425,34 @@ $(function() {
$("#printBtn").click(function() {
var mapIds = $('#mindmapListTable').dataTableExt.getSelectedMapsIds();
if (mapIds.length > 0) {
window.open('c/maps/' + mapIds[0] + '/print');
window.open('/c/maps/' + mapIds[0] + '/print');
}
});
$("#infoBtn").click(function() {
showEmbeddedDialog("c/maps/{mapId}/details", 'info-dialog-modal');
showEmbeddedDialog("/c/maps/{mapId}/details", 'info-dialog-modal');
});
$("#historyBtn").click(function() {
showEmbeddedDialog("c/maps/{mapId}/history", 'history-dialog-modal');
showEmbeddedDialog("/c/maps/{mapId}/history", 'history-dialog-modal');
});
$("#publishBtn").click(function() {
showEmbeddedDialog("c/maps/{mapId}/publish", "publish-dialog-modal");
showEmbeddedDialog("/c/maps/{mapId}/publish", "publish-dialog-modal");
});
$("#exportBtn").click(function() {
showEmbeddedDialog("c/maps/{mapId}/export", 'export-dialog-modal');
showEmbeddedDialog("/c/maps/{mapId}/export", 'export-dialog-modal');
});
$("#importBtn").click(function() {
showEmbeddedDialog("c/maps/import", 'import-dialog-modal', true);
showEmbeddedDialog("/c/maps/import", 'import-dialog-modal', true);
});
$("#shareBtn").click(function() {
showEmbeddedDialog("c/maps/{mapId}/share", 'share-dialog-modal', true);
showEmbeddedDialog("/c/maps/{mapId}/share", 'share-dialog-modal', true);
});
var showEmbeddedDialog = function(urlTemplate, dialogElemId, ignore) {
var mapIds = $('#mindmapListTable').dataTableExt.getSelectedMapsIds();
if (mapIds.length > 0 || ignore) {