Commit b3bccd1b8ac7ab82958a623466ab6701fb608207
1 parent
66ed371373
Exists in
master
and in
6 other branches
分娩报告单导出修改
Showing 1 changed file with 16 additions and 2 deletions
platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/MatDeliverController.java
View file @
b3bccd1
... | ... | @@ -467,7 +467,14 @@ |
467 | 467 | for (int i = 0 ; i < arrs.length ; i++) |
468 | 468 | { |
469 | 469 | try { |
470 | - weight+=(Double.parseDouble(arrs[i]) * 1000)+""; | |
470 | + String w = String.valueOf(Double.parseDouble(arrs[i]) * 1000); | |
471 | + int dex = w.indexOf("."); | |
472 | + if(-1 == dex){ | |
473 | + weight+=w+""; | |
474 | + }else{ | |
475 | + weight+=w.substring(0,dex)+""; | |
476 | + } | |
477 | + //weight+=(Double.parseDouble(arrs[i]) * 1000)+""; | |
471 | 478 | } |
472 | 479 | catch (Exception E) |
473 | 480 | { |
... | ... | @@ -481,7 +488,14 @@ |
481 | 488 | } |
482 | 489 | } |
483 | 490 | if(0 == nu && !"-".equals(queryModel.getBabyWeight())){ |
484 | - weight = (Double.parseDouble(queryModel.getBabyWeight()) * 1000)+""; | |
491 | + String w = String.valueOf(Double.parseDouble(queryModel.getBabyWeight()) * 1000); | |
492 | + int dex = w.indexOf("."); | |
493 | + if(-1 == dex){ | |
494 | + weight=w+""; | |
495 | + }else{ | |
496 | + weight=w.substring(0,dex)+""; | |
497 | + } | |
498 | + //weight = (Double.parseDouble(queryModel.getBabyWeight()) * 1000)+""; | |
485 | 499 | } |
486 | 500 | else if(0 == nu && "-".equals(queryModel.getBabyWeight())){ |
487 | 501 | weight = queryModel.getBabyWeight(); |