Changeset 1726
- Timestamp:
- Oct 4, 2012, 3:49:43 PM (11 years ago)
- Location:
- extensions/net.sf.basedb.reggie/trunk/resources
- Files:
-
- 13 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/net.sf.basedb.reggie/trunk/resources/bloodform.jsp
r1720 r1726 195 195 if (!isValidDate) 196 196 { 197 var dayInMonth = parseInt(datePart.substring(-2) ); // Last two characters197 var dayInMonth = parseInt(datePart.substring(-2), 10); // Last two characters 198 198 if (dayInMonth > 60) 199 199 { … … 348 348 if (pnr.length == 10 && pnrIsValid) 349 349 { 350 var year = fullYear(parseInt(pnr.substr(0, 2) ));350 var year = fullYear(parseInt(pnr.substr(0, 2), 10)); 351 351 pnr = year + pnr.substr(2); 352 352 } … … 483 483 if (frm.copyConsent.checked && frm.copyConsent.value) 484 484 { 485 bloodInfo.copyConsent = parseInt(frm.copyConsent.value );485 bloodInfo.copyConsent = parseInt(frm.copyConsent.value, 10); 486 486 } 487 487 -
extensions/net.sf.basedb.reggie/trunk/resources/edit_dnarna_details.jsp
r1648 r1726 62 62 var frm = document.forms['details']; 63 63 64 lysate.qiacubePosition = parseInt(frm.qiacubePosition.value );64 lysate.qiacubePosition = parseInt(frm.qiacubePosition.value, 10); 65 65 lysate.originalQuantity = parseFloat(frm.lysateOriginalQuantity.value); 66 66 lysate.processedQuantity = parseFloat(frm.lysateUsedQuantity.value); … … 84 84 85 85 // Qiacube position 86 var qiacubePosition = parseInt(frm.qiacubePosition.value );86 var qiacubePosition = parseInt(frm.qiacubePosition.value, 10); 87 87 if (!(qiacubePosition > 0) || !(qiacubePosition <= 12)) 88 88 { -
extensions/net.sf.basedb.reggie/trunk/resources/extraction_registration.jsp
r1719 r1726 550 550 submitInfo.lysates = selectedLysates; 551 551 submitInfo.lysisDate = frm.lysisDate.value; 552 submitInfo.lysisProtocol = parseInt(frm.lysisProtocol.value );552 submitInfo.lysisProtocol = parseInt(frm.lysisProtocol.value, 10); 553 553 submitInfo.qiacubeDate = frm.qiacubeDate.value; 554 submitInfo.qiacubeRunNo = parseInt(frm.qiacubeRunNo.value );554 submitInfo.qiacubeRunNo = parseInt(frm.qiacubeRunNo.value, 10); 555 555 submitInfo.qiacubeOperator = frm.qiacubeOperator.value; 556 submitInfo.dnaProtocol = parseInt(frm.dnaProtocol.value );557 submitInfo.rnaProtocol = parseInt(frm.rnaProtocol.value );558 submitInfo.ftProtocol = parseInt(frm.ftProtocol.value );556 submitInfo.dnaProtocol = parseInt(frm.dnaProtocol.value, 10); 557 submitInfo.rnaProtocol = parseInt(frm.rnaProtocol.value, 10); 558 submitInfo.ftProtocol = parseInt(frm.ftProtocol.value, 10); 559 559 560 560 if (debug) Main.debug(JSON.stringify(submitInfo)); … … 669 669 return; 670 670 } 671 if (!(parseInt(runNumber ) >= 1))671 if (!(parseInt(runNumber, 10) >= 1)) 672 672 { 673 673 setInputStatus('qiacubeRunNo', 'Must be at least 1', 'invalid'); -
extensions/net.sf.basedb.reggie/trunk/resources/histology_block.jsp
r1696 r1726 272 272 273 273 workList.moveDate = frm.moveDate.value; 274 workList.protocolId = parseInt(frm.histologyProtocol[frm.histologyProtocol.selectedIndex].value );274 workList.protocolId = parseInt(frm.histologyProtocol[frm.histologyProtocol.selectedIndex].value, 10); 275 275 276 276 for (var blockNo = 0; blockNo < workList.blocks.length; blockNo++) -
extensions/net.sf.basedb.reggie/trunk/resources/histology_glass.jsp
r1696 r1726 332 332 { 333 333 var field = frm[wells[i]]; 334 if (!(parseInt(field.value ) > 0))334 if (!(parseInt(field.value, 10) > 0)) 335 335 { 336 336 setInputStatus(field.name, null, 'invalid'); … … 358 358 { 359 359 var frm = document.forms['reggie']; 360 if (!(parseInt(frm[field].value ) > 0))360 if (!(parseInt(frm[field].value, 10) > 0)) 361 361 { 362 362 frm[field].focus(); … … 380 380 var field = frm[wells[i]]; 381 381 field.disabled = true; 382 if (parseInt(field.value ) > maxIndex)383 { 384 maxIndex = parseInt(field.value );382 if (parseInt(field.value, 10) > maxIndex) 383 { 384 maxIndex = parseInt(field.value, 10); 385 385 } 386 386 } … … 538 538 if (frm[field]) 539 539 { 540 well.GoodStain = parseInt(frm[field].value );540 well.GoodStain = parseInt(frm[field].value, 10); 541 541 } 542 542 } … … 559 559 var submitInfo = new Object(); 560 560 paraffinBlock.stainDate = frm.stainDate.value; 561 paraffinBlock.protocolId = parseInt(frm.stainingProtocol[frm.stainingProtocol.selectedIndex].value );561 paraffinBlock.protocolId = parseInt(frm.stainingProtocol[frm.stainingProtocol.selectedIndex].value, 10); 562 562 submitInfo.paraffinBlock = paraffinBlock; 563 563 -
extensions/net.sf.basedb.reggie/trunk/resources/histology_protocol2.jsp
r1699 r1726 150 150 if (numLabelsPerBlock == null) return; 151 151 152 if (!parseInt(numLabelsPerBlock ))152 if (!parseInt(numLabelsPerBlock, 10)) 153 153 { 154 154 alert('"' + numLabelsPerBlock + '" is not a valid number'); … … 158 158 var url = 'Histology.servlet?ID=<%=ID%>&cmd=DownloadHEGlassLabels'; 159 159 url += '&workListId=<%=listId%>'; 160 url += '&numSlides=' + parseInt(numLabelsPerBlock );160 url += '&numSlides=' + parseInt(numLabelsPerBlock, 10); 161 161 162 162 location.href = url; -
extensions/net.sf.basedb.reggie/trunk/resources/histology_work_list.jsp
r1696 r1726 220 220 for (var i = 0; i < frm.histology.length; i++) 221 221 { 222 if (frm.histology[i].selected) histology[histology.length] = parseInt(frm.histology[i].value );222 if (frm.histology[i].selected) histology[histology.length] = parseInt(frm.histology[i].value, 10); 223 223 } 224 224 -
extensions/net.sf.basedb.reggie/trunk/resources/persinfo.jsp
r1720 r1726 226 226 if (!isValidDate) 227 227 { 228 var dayInMonth = parseInt(datePart.substring(-2) ); // Last two characters228 var dayInMonth = parseInt(datePart.substring(-2), 10); // Last two characters 229 229 if (dayInMonth > 60) 230 230 { … … 463 463 if (pnr.length == 10 && pnrIsValid) 464 464 { 465 var year = fullYear(parseInt(pnr.substr(0, 2) ));465 var year = fullYear(parseInt(pnr.substr(0, 2), 10)); 466 466 pnr = year + pnr.substr(2); 467 467 } … … 805 805 if (frm.copyConsent.checked && frm.copyConsent.value) 806 806 { 807 caseInfo.copyConsent = parseInt(frm.copyConsent.value );807 caseInfo.copyConsent = parseInt(frm.copyConsent.value, 10); 808 808 } 809 809 -
extensions/net.sf.basedb.reggie/trunk/resources/reggie.js
r1668 r1726 169 169 for (var i = 0; i < 9; i++) 170 170 { 171 var digit = parseInt(pnr.substr(i, 1) );171 var digit = parseInt(pnr.substr(i, 1), 10); 172 172 var tmp = factor * digit; 173 173 sum += tmp >= 10 ? tmp - 9: tmp; … … 177 177 var control = 10 - (sum % 10); 178 178 if (control == 10) control = 0; 179 return (control == parseInt(pnr.substr(9, 1) ))179 return (control == parseInt(pnr.substr(9, 1), 10)) 180 180 } 181 181 … … 207 207 if (shortDate.length == 4 && Dates.isDate(shortDate, 'MMdd')) 208 208 { 209 var month = parseInt(shortDate.substring(0,2) );210 var date = parseInt(shortDate.substring(2) );209 var month = parseInt(shortDate.substring(0,2), 10); 210 var date = parseInt(shortDate.substring(2), 10); 211 211 if ((month > (currentDate.getMonth()+1)) || 212 212 ( (month == (currentDate.getMonth()+1)) && (date > currentDate.getDate())) ) … … 218 218 else if (shortDate.length == 6 && Dates.isDate(shortDate, 'yyMMdd')) 219 219 { 220 var year = parseInt(shortDate.substring(0,2) );220 var year = parseInt(shortDate.substring(0,2), 10); 221 221 fullDateString = ((2000+year)>currentYear ? "19" : "20") + fullDateString; 222 222 } -
extensions/net.sf.basedb.reggie/trunk/resources/rnaqc_aliquot.jsp
r1689 r1726 656 656 } 657 657 658 var colC = parseInt(column )-1;658 var colC = parseInt(column, 10)-1; 659 659 if (isNaN(colC) || colC < 0 || colC >= selectedBioPlate.geometry.columns) 660 660 { … … 767 767 768 768 var protocol = new Object(); 769 protocol.id = parseInt(frm.protocols[frm.protocols.selectedIndex].value );769 protocol.id = parseInt(frm.protocols[frm.protocols.selectedIndex].value, 10); 770 770 if (protocol.id != 0) 771 771 { … … 777 777 { 778 778 var rnaQc = new Object(); 779 rnaQc.parentId = parseInt(selectedRnaExtracts[i].id );779 rnaQc.parentId = parseInt(selectedRnaExtracts[i].id, 10); 780 780 rnaQc.name = selectedRnaExtracts[i].nextRnaQcName; 781 781 rnaQc.row = frm['row'+i].value; -
extensions/net.sf.basedb.reggie/trunk/resources/rnaqc_plate_import.jsp
r1653 r1726 151 151 { 152 152 var frm = document.forms['reggie']; 153 var csvId = parseInt(frm['csv.id'].value );154 var gxdStdId = parseInt(frm['gxd.std.id'].value );155 var gxdHiId = parseInt(frm['gxd.hi.id'].value );156 var pdfId = parseInt(frm['pdf.id'].value );153 var csvId = parseInt(frm['csv.id'].value, 10); 154 var gxdStdId = parseInt(frm['gxd.std.id'].value, 10); 155 var gxdHiId = parseInt(frm['gxd.hi.id'].value, 10); 156 var pdfId = parseInt(frm['pdf.id'].value, 10); 157 157 158 158 if (!csvId) -
extensions/net.sf.basedb.reggie/trunk/resources/samplereportgenerator.jsp
r1653 r1726 94 94 { 95 95 fdate = frm.fromdate.value; 96 fdate = new Date(fdate.substr(0,4), parseInt(fdate.substr(4,2) )-1, fdate.substr(6,2));96 fdate = new Date(fdate.substr(0,4), parseInt(fdate.substr(4,2), 10)-1, fdate.substr(6,2)); 97 97 } 98 98 } … … 109 109 { 110 110 tdate = frm.todate.value; 111 tdate = new Date(tdate.substr(0,4), parseInt(tdate.substr(4,2) )-1, tdate.substr(6,2));111 tdate = new Date(tdate.substr(0,4), parseInt(tdate.substr(4,2), 10)-1, tdate.substr(6,2)); 112 112 } 113 113 } … … 371 371 if (currentYear == startDate.getFullYear()) 372 372 { 373 colspan = 11- parseInt(startDate.getMonth())+1;373 colspan = 11-startDate.getMonth()+1; 374 374 if (endDate.getFullYear() == currentYear) 375 375 { 376 colspan = colspan - (11- parseInt(endDate.getMonth()));376 colspan = colspan - (11-endDate.getMonth()); 377 377 } 378 378 } 379 379 else if (currentYear == endDate.getFullYear()) 380 colspan = parseInt(endDate.getMonth()+1);380 colspan = endDate.getMonth()+1; 381 381 else 382 382 colspan = 12; … … 560 560 columnCounter++; 561 561 }while (columnCounter< numCols) 562 tableRow.appendChild(getTableCellElement( parseInt(grandTotal), 'rowsummary'));562 tableRow.appendChild(getTableCellElement(grandTotal, 'rowsummary')); 563 563 reportTable.appendChild(tableRow); 564 564 } -
extensions/net.sf.basedb.reggie/trunk/resources/specimentube.jsp
r1720 r1726 422 422 { 423 423 nextWellRow = response.freeRow; 424 nextWellColumn = parseInt(response.freeColumn )+1;424 nextWellColumn = parseInt(response.freeColumn, 10)+1; 425 425 426 426 nextWellColumn = nextWellColumn + tubeIndex; … … 553 553 { 554 554 nextWellRow = response.freeRow; 555 nextWellColumn = parseInt(response.freeColumn )+1;555 nextWellColumn = parseInt(response.freeColumn, 10)+1; 556 556 if( (nextWellColumn + tubeIndex) > response.columns) 557 557 {
Note: See TracChangeset
for help on using the changeset viewer.