| | |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | @Slf4j |
| | | @RestController |
| | |
| | | |
| | | |
| | | |
| | | /********************************************************************************************************************************************** |
| | | * |
| | | * 大屏居家养老 |
| | | * |
| | | **********************************************************************************************************************************************/ |
| | | |
| | | /** |
| | | * 手环人数 |
| | | * @return |
| | | */ |
| | | @GetMapping("/getUserNum") |
| | | public R getUserNum(@RequestParam("communityId") String communityId) |
| | | { |
| | | return R.ok(braceletUserDataService.getUserNum(communityId)); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 手环定位数据 |
| | | */ |
| | | @GetMapping("/getUserList") |
| | | public R getUserList(@RequestParam("communityId") String communityId) |
| | | { |
| | | return R.ok(braceletUserDataService.getUserList(communityId)); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 获取手环预警次数 |
| | | * @return |
| | | */ |
| | | @GetMapping("/getWarningNum") |
| | | public R getWarningNum(@RequestParam("communityId") String communityId, |
| | | @RequestParam(value = "disposeType",required = false) String disposeType) |
| | | { |
| | | //未处理 |
| | | Integer num1=braceletEarlyWarningService.getWarningNum(communityId,"1"); |
| | | //已处理 |
| | | Integer num2=braceletEarlyWarningService.getWarningNum(communityId,"2"); |
| | | //处理中 |
| | | Integer num4=braceletEarlyWarningService.getWarningNum(communityId,"3"); |
| | | //忽略 |
| | | Integer num3=braceletEarlyWarningService.getWarningNum(communityId,"4"); |
| | | |
| | | Map<String,Integer> map=new HashMap<>(); |
| | | map.put("untreatedNum",num1); |
| | | map.put("processedNum",num2); |
| | | map.put("ignoreNum",num3); |
| | | map.put("beingProcessedNum",num4); |
| | | |
| | | return R.ok(map); |
| | | } |
| | | |
| | | |
| | | |
| | | } |