changeset 38:217a7b059553 draft

implemented get inspect
author Nobuyasu Oshiro <dimolto@cr.ie.u-ryukyu.ac.jp>
date Sat, 23 Mar 2013 09:29:01 +0900
parents 4b3fd472120b
children 3b597b795ea8
files show.html
diffstat 1 files changed, 12 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/show.html	Sat Mar 23 09:00:46 2013 +0900
+++ b/show.html	Sat Mar 23 09:29:01 2013 +0900
@@ -63,7 +63,7 @@
 	</div>
     </div>
     <div class='menu' id='' style=''>
-	<div class='menuTitleCss' id='accesDocument'>AccesDocument</div>
+	<div class='menuTitleCss' onclick="getInspect(CURRENT_DATA.nodeId);" id='accesDocument'>Read Document Now!!</div>
   </div>
 </div>
 
@@ -212,10 +212,10 @@
 	} else {
 	    setEdgeInfoClickFunction(node.property.id, edgeInfo, edgeInfo.view);
 	}
-	console.log("appendmenuBody");
 	appendMenuBody(tMenuBody, edgeInfo.view);
     }
     updateMenuDisplayHeight();
+    $('#accesDocument').click(function(){  });
 }
 
 function calcChildrenHeight(childArray) {
@@ -333,7 +333,7 @@
 	var height = 0;
 	for (var i=0; i<childArray.length; i++) {
 	    childArray[i].style.top = height + 'px';
-	    height = height + childArray[i].offsetHeight; + MARGIN;
+	    height = height + childArray[i].offsetHeight + MARGIN;
 	}
     }
     var menuD =  $('#menuDisplay');
@@ -370,7 +370,6 @@
 	top: rootTop + 'px'
     });
     var heightStr = $('#miniDisplay').css('height').split('px')[0];
-    console.log(heightStr);
     var height = parseInt(heightStr);
     $('#menuDisplay').css({
 	left: rootLeft + 'px',
@@ -436,6 +435,15 @@
     showAllEdge(graphData);
 }
 
+function getInspect(id) {
+    $.ajax({
+	url:"/aat/aaevidencesiftingmodel.userdesktops/inspect?id="+id,
+	success:function(o) { console.log(o); document.location = o; },
+	type:"GET", cache:true,
+	error:function(o) { console.log("getEvidence error : ", o); }
+    });
+}
+
 function getEvidence(nodeId, edgeInfo) {
     $.ajax({
 	url:"/aat/aaevidencesiftingmodel.userdesktops/get?desktopid="+desktopid() +"&id="+nodeId+"&edgeinfoid="+edgeInfo.id,