Commit 65939cf61d6c7944313606d8d793f5718f984178
1 parent
fe3971a44c
Exists in
master
and in
6 other branches
体成分分析
Showing 2 changed files with 6 additions and 8 deletions
platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/VolumeComponentAnalysisController.java
View file @
65939cf
| ... | ... | @@ -10,12 +10,10 @@ |
| 10 | 10 | import com.lyms.platform.pojo.VolumeComponentAnalysisModel; |
| 11 | 11 | import org.springframework.beans.factory.annotation.Autowired; |
| 12 | 12 | import org.springframework.stereotype.Controller; |
| 13 | -import org.springframework.web.bind.annotation.RequestMapping; | |
| 14 | -import org.springframework.web.bind.annotation.RequestMethod; | |
| 15 | -import org.springframework.web.bind.annotation.RequestParam; | |
| 16 | -import org.springframework.web.bind.annotation.ResponseBody; | |
| 13 | +import org.springframework.web.bind.annotation.*; | |
| 17 | 14 | |
| 18 | 15 | import javax.servlet.http.HttpServletRequest; |
| 16 | +import javax.validation.Valid; | |
| 19 | 17 | |
| 20 | 18 | /** |
| 21 | 19 | * 体成分分析 |
| 22 | 20 | |
| ... | ... | @@ -47,9 +45,9 @@ |
| 47 | 45 | /** |
| 48 | 46 | * 添加蓝牙体成分分析后的数据 |
| 49 | 47 | */ |
| 50 | - @RequestMapping(method = RequestMethod.GET, value = "/addComponentAnalysis") | |
| 48 | + @RequestMapping(method = RequestMethod.POST, value = "/addComponentAnalysis") | |
| 51 | 49 | @ResponseBody |
| 52 | - public BaseObjectResponse addComponentAnalysis(VolumeComponentAnalysisModel volume) { | |
| 50 | + public BaseObjectResponse addComponentAnalysis(@RequestBody @Valid VolumeComponentAnalysisModel volume) { | |
| 53 | 51 | |
| 54 | 52 | return volumeComponentAnalysisFacade.addComponentAnalysis(volume); |
| 55 | 53 |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/service/impl/TemporaryBloodServiceImpl.java
View file @
65939cf
| ... | ... | @@ -325,12 +325,12 @@ |
| 325 | 325 | this.getSeries(series, bmiStr, bregmatic); |
| 326 | 326 | Map<Integer, Double> lowMap = series.get("lowData"); |
| 327 | 327 | for (Map.Entry<Integer, Double> entry : lowMap.entrySet()) { |
| 328 | - if (entry.getKey() == weeks) { | |
| 328 | + if (entry.getKey().equals(weeks)) { | |
| 329 | 329 | } |
| 330 | 330 | } |
| 331 | 331 | Map<Integer, Double> highMap = series.get("highData"); |
| 332 | 332 | for (Map.Entry<Integer, Double> entry : highMap.entrySet()) { |
| 333 | - if (entry.getKey() == weeks) { | |
| 333 | + if (entry.getKey().equals(weeks)) { | |
| 334 | 334 | high = entry.getValue(); |
| 335 | 335 | } |
| 336 | 336 | } |