Changeset 3532
- Timestamp:
- Oct 5, 2015, 4:23:47 PM (7 years ago)
- Location:
- extensions/net.sf.basedb.meludi/trunk
- Files:
-
- 1 added
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/net.sf.basedb.meludi/trunk/resources/reports/case_summary.js
r3526 r3532 248 248 { 249 249 var d = lib[i]; 250 var barcode Name= 'NA';251 if (d. barcode!= null)250 var barcodeInfo = 'NA'; 251 if (d.index1 != null && d.index2 != null) 252 252 { 253 barcode Name = d.barcode.name;253 barcodeInfo = cs.asLink('TAG', d.index2) + ',' + cs.asLink('TAG', d.index1); 254 254 } 255 255 cs.addColumn('lib.name', cs.asLink('EXTRACT', d)); … … 260 260 cs.addColumn('lib.remainingQuantity', cs.asQuantity(d.remainingQuantity, ' ng', 0.001)); 261 261 cs.addColumn('lib.originalQuantity', cs.asQuantity(d.originalQuantity, ' ng', 0.001)); 262 cs.addColumn('lib.barcode.name', barcode Name);262 cs.addColumn('lib.barcode.name', barcodeInfo); 263 263 cs.addColumn('lib.ca_size', cs.asQuantity(d.ca_size, '')); 264 264 cs.addColumn('lib.molarity', cs.asQuantity(d.library_molarity_est, ' nM')); -
extensions/net.sf.basedb.meludi/trunk/src/net/sf/basedb/meludi/servlet/CaseSummaryServlet.java
r3526 r3532 34 34 import net.sf.basedb.meludi.Site; 35 35 import net.sf.basedb.meludi.dao.Annotationtype; 36 import net.sf.basedb.meludi.dao.Barcode; 36 37 import net.sf.basedb.meludi.dao.BioplateType; 37 38 import net.sf.basedb.meludi.dao.Case; … … 248 249 JSONObject jsonDnaTmp = (JSONObject) d.asJSONObject(); 249 250 jsonWell = (JSONObject) jsonDnaTmp.get("bioWell"); 250 Integer row = null; 251 Integer col = null; 251 // Add barcode (Illumina index) info 252 252 if (jsonWell != null) 253 253 { 254 row = (Integer) jsonWell.get("row"); 255 col = (Integer) jsonWell.get("column"); 254 Integer row = (Integer) jsonWell.get("row"); 255 Integer col = (Integer) jsonWell.get("column"); 256 if (row != null) 257 { 258 String rowStr = "A50" + (row + 1); 259 Integer barcodeTagId = null; 260 Barcode barcode = Barcode.findByName(dc, rowStr); 261 if (barcode != null) 262 { 263 barcodeTagId = barcode.getTag().getId(); 264 } 265 JSONObject jsonIndex2 = new JSONObject(); 266 jsonIndex2.put("name", rowStr); 267 jsonIndex2.put("id", barcodeTagId); 268 // Add Illumina Index 2 (row) barcode info 269 jsonD.put("index2", jsonIndex2); 270 } 271 if (col != null) 272 { 273 String colStr = "A70" + (col + 1); 274 if (col > 8) 275 { 276 colStr = "A7" + (col + 1); 277 } 278 Integer barcodeTagId = null; 279 Barcode barcode = Barcode.findByName(dc, colStr); 280 if (barcode != null) 281 { 282 barcodeTagId = barcode.getTag().getId(); 283 } 284 JSONObject jsonIndex1 = new JSONObject(); 285 jsonIndex1.put("name", colStr); 286 jsonIndex1.put("id", barcodeTagId); 287 // Add Illumina Index 1 (column) barcode info 288 jsonD.put("index1", jsonIndex1); 289 } 256 290 } 257 // Add barcode name258 JSONObject jsonBarcode = new JSONObject();259 if (row != null && col != null)260 {261 String rowStr = "50" + (row + 1);262 String colStr = "70" + (col + 1);263 if (col > 8)264 {265 colStr = "7" + (col + 1);266 }267 jsonBarcode.put("name", rowStr + "," + colStr);268 }269 jsonD.put("barcode", jsonBarcode);270 291 jsonLib.add(jsonD); 271 292 }
Note: See TracChangeset
for help on using the changeset viewer.