Changeset 5075 for trunk/www/common/annotations/index.jsp
- Timestamp:
- Aug 24, 2009, 1:05:40 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/www/common/annotations/index.jsp
r5060 r5075 29 29 import="net.sf.basedb.core.ItemContext" 30 30 import="net.sf.basedb.core.BasicItem" 31 import="net.sf.basedb.core.Annotation" 32 import="net.sf.basedb.core.AnnotationType" 31 33 import="net.sf.basedb.core.Annotatable" 32 34 import="net.sf.basedb.core.BaseException" … … 44 46 final String ID = sc.getId(); 45 47 final String cmd = request.getParameter("cmd"); 46 final Item itemType = Item.valueOf(request.getParameter("item_type"));47 48 final int itemId = Values.getInt(request.getParameter("item_id")); 48 49 … … 54 55 try 55 56 { 56 if (" SaveAnnotations".equals(cmd))57 if ("EditItem".equals(cmd)) 57 58 { 59 newDc = sc.newDbControl(); 60 Annotation a = Annotation.getById(newDc, itemId); 61 AnnotationType at = a.getAnnotationType(); 62 Annotatable item = a.getAnnotationSet().getItem(); 63 64 redirect = "annotate.jsp?ID=" + ID + "&item_id=" + item.getId() + 65 "&item_type=" + item.getType().name() + 66 "&annotationtype_id=" + at.getId() + "&standalone=1"; 67 newDc.close(); 68 } 69 else if ("SaveAnnotations".equals(cmd)) 70 { 71 final Item itemType = Item.valueOf(request.getParameter("item_type")); 58 72 newDc = sc.newDbControl(); 59 73 oldDc = sc.newDbControl();
Note: See TracChangeset
for help on using the changeset viewer.