Changeset 2062
- Timestamp:
- Oct 14, 2013, 8:54:18 AM (10 years ago)
- Location:
- extensions/net.sf.basedb.reggie/trunk
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/net.sf.basedb.reggie/trunk/resources/libprep/flowcell_protocol2.jsp
r2061 r2062 134 134 setInnerHTML('flowCellName.'+flowCellNo, flowCellName); 135 135 setInnerHTML('flowCellDescription.'+flowCellNo, flowCellDescription); 136 setInnerHTML('readString.'+flowCellNo, readString); 136 setInnerHTML('readString.'+flowCellNo, readString); 137 setInnerHTML('flowCellId.'+flowCellNo, flowCell.externalId); 137 138 var flowCellLanes = flowCell['lanes']; 138 139 for (laneKey in flowCellLanes) … … 339 340 <tr valign="top" style="border-top: 1px solid #000000;"> 340 341 <th style="border-right: 1px solid #000000;">Flow cell ID</th> 341 <td colspan="2" style="border-right: 1px solid #000000;">< /td>342 <td colspan="2" style="border-right: 1px solid #000000;"><div id="flowCellId.<%=c%>" ></div></td> 342 343 </tr> 343 344 <tr valign="top" style="border-top: 1px solid #000000;"> -
extensions/net.sf.basedb.reggie/trunk/resources/libprep/flowcell_registration.jsp
r2060 r2062 232 232 frm[prefix+'.comments'].value = fc.comments; 233 233 commentsOnChange(prefix+'.comments'); 234 frm[prefix+'.id'].value = fc.externalId; 235 flowCellIdOnBlur(prefix+'.id'); 234 236 index++; 235 237 } -
extensions/net.sf.basedb.reggie/trunk/src/net/sf/basedb/reggie/servlet/FlowCellServlet.java
r2060 r2062 25 25 import net.sf.basedb.core.Hardware; 26 26 import net.sf.basedb.core.ItemQuery; 27 import net.sf.basedb.core.ItemResultList;28 27 import net.sf.basedb.core.ItemSubtype; 29 28 import net.sf.basedb.core.PhysicalBioAssay; … … 143 142 { 144 143 fc.loadAnnotations(dc, "ReadString", Annotationtype.READ_STRING, null); 144 fc.loadAnnotations(dc, "externalId", Annotationtype.FLOWCELL_ID, null); 145 145 fc.setAnnotation("comments", fc.getPhysicalBioAssay().getDescription()); 146 146 jsonFlowCells.add(fc.asJSONObject()); … … 170 170 for (FlowCell fc: flowCellList) 171 171 { 172 JSONObject jsonFlowCell = new JSONObject();173 jsonFlowCell.put("name", fc.getName());174 // Get ReadString annotation175 172 PhysicalBioAssay physBA = fc.getPhysicalBioAssay(); 176 jsonFlowCell.put("description", physBA.getDescription()); 177 int numLanes = physBA.getSize(); 178 String readString = (String) Annotationtype.READ_STRING.getAnnotationValue(dc, manager, physBA); 179 jsonFlowCell.put("readString", readString); 173 fc.setAnnotation("description", physBA.getDescription()); 174 fc.setAnnotation("numLanes", physBA.getSize()); 175 fc.loadAnnotations(dc, "readString", Annotationtype.READ_STRING, null); 176 fc.loadAnnotations(dc, "externalId", Annotationtype.FLOWCELL_ID, null); 177 180 178 // Get flow cell lane info 181 179 JSONObject jsonFlowCellLanes = new JSONObject(); 182 // Note: Lane positions start with 1, not 0 183 for (int pos = 1; pos <= numLanes; pos++) 180 for (BioMaterialEventSource eventSource : physBA.getCreationEvent().getEventSources().list(dc)) 184 181 { 185 ItemResultList<Extract> fcExtractList = fc.getPhysicalBioAssay().getExtracts(pos).list(dc); 186 for (Extract extract: fcExtractList) 187 { 188 jsonFlowCellLanes.put(pos, extract.getName()); 189 } 182 Extract pool = (Extract)eventSource.getBioMaterial(); 183 jsonFlowCellLanes.put(eventSource.getPosition(), pool.getName()); 190 184 } 191 jsonFlowCell.put("numLanes", numLanes); 192 jsonFlowCell.put("lanes", jsonFlowCellLanes); 193 // 194 jsonFlowCellInfo.add(jsonFlowCell); 185 fc.setAnnotation("lanes", jsonFlowCellLanes); 186 jsonFlowCellInfo.add(fc.asJSONObject()); 195 187 } 196 188 json.put("flowCellInfo", jsonFlowCellInfo);
Note: See TracChangeset
for help on using the changeset viewer.