| | |
| | | |
| | | import io.swagger.annotations.*; |
| | | import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
| | | import io.swagger.models.auth.In; |
| | | import lombok.AllArgsConstructor; |
| | | |
| | | import javax.validation.Valid; |
| | |
| | | */ |
| | | @PostMapping("/selectLi") |
| | | public R<IPage> selectLi(String jurisdiction, String deptid, Query query) { |
| | | IPage list = informationService.selectLi(Condition.getPage(query),jurisdiction, deptid); |
| | | IPage list = informationService.selectLi(Condition.getPage(query), jurisdiction, deptid); |
| | | return R.data(list); |
| | | } |
| | | |
| | |
| | | */ |
| | | @PostMapping("/selectTb") |
| | | public R<IPage> selectTb(String jurisdiction, String enterpriseName, Query query) { |
| | | IPage list =informationService.selectTb(Condition.getPage(query),jurisdiction, enterpriseName); |
| | | IPage list = informationService.selectTb(Condition.getPage(query), jurisdiction, enterpriseName); |
| | | return R.data(list); |
| | | } |
| | | |
| | |
| | | */ |
| | | @PostMapping("/selectJj") |
| | | public R<IPage> selectJj(String jurisdiction, String enterpriseName, Query query) { |
| | | IPage list = informationService.selectJj(Condition.getPage(query),jurisdiction, enterpriseName); |
| | | IPage list = informationService.selectJj(Condition.getPage(query), jurisdiction, enterpriseName); |
| | | return R.data(list); |
| | | } |
| | | |
| | |
| | | */ |
| | | @PostMapping("/selectYw") |
| | | public R<IPage> selectYw(String jurisdiction, String deptid, Query query) { |
| | | IPage list = informationService.selectYw(Condition.getPage(query),jurisdiction, deptid); |
| | | IPage list = informationService.selectYw(Condition.getPage(query), jurisdiction, deptid); |
| | | return R.data(list); |
| | | } |
| | | |
| | |
| | | * 保安员详情 |
| | | */ |
| | | @PostMapping("/selectUIn") |
| | | public R selectUIn(String deptid, String name, String hold, String photo, String examinationtype, String dispatch, String soil) { |
| | | List<Map<Object, Object>> list = informationService.selectUIn(deptid, name, hold, photo, examinationtype, dispatch, soil); |
| | | public R<IPage> selectUIn(String deptid, String name, String hold, String photo, String examinationtype, String dispatch, String soil,Query query) { |
| | | IPage list = informationService.selectUIn(Condition.getPage(query),deptid, name, hold, photo, examinationtype, dispatch, soil); |
| | | return R.data(list); |
| | | } |
| | | |
| | |
| | | */ |
| | | @PostMapping("/selectDis") |
| | | public R<IPage> selectDis(String jurisdiction, String deptid, String fid, Query query) { |
| | | IPage list = informationService.selectDis(Condition.getPage(query),jurisdiction, deptid, fid); |
| | | IPage list = informationService.selectDis(Condition.getPage(query), jurisdiction, deptid, fid); |
| | | return R.data(list); |
| | | } |
| | | |
| | |
| | | * 违规经营 |
| | | */ |
| | | @PostMapping("/selectWg") |
| | | public R selectWg() { |
| | | List<Map<Object, Object>> list = informationService.selectWg(); |
| | | for (int i=0;i<list.size();i++){ |
| | | public R selectWg(String jurisdiction) { |
| | | List<Map<Object, Object>> list = informationService.selectWg(jurisdiction); |
| | | List list1 = new ArrayList(); |
| | | int count=0; |
| | | Map map = new HashMap(); |
| | | for (int i = 0; i < list.size(); i++) { |
| | | //总数 |
| | | String znums = list.get(i).get("znum").toString(); |
| | | int znum=Integer.parseInt(znums); |
| | | int znum = Integer.parseInt(znums); |
| | | //持证人数 |
| | | String cznums = list.get(i).get("cznum").toString(); |
| | | int cznum=Integer.parseInt(cznums); |
| | | int cznum = Integer.parseInt(cznums); |
| | | //缴纳社保人数 |
| | | String sbnums = list.get(i).get("sbnum").toString(); |
| | | int sbnum=Integer.parseInt(sbnums); |
| | | int sbnum = Integer.parseInt(sbnums); |
| | | //保安总人数为0 |
| | | if (znum==0){ |
| | | continue; |
| | | } |
| | | else { |
| | | int a = znum / 2; |
| | | if (cznum<=a || sbnum<=a){ |
| | | count++; |
| | | list1.add(list.get(i)); |
| | | } |
| | | } |
| | | } |
| | | return R.data(list); |
| | | map.put("count",count); |
| | | map.put("list",list1); |
| | | return R.data(map); |
| | | } |
| | | |
| | | /** |
| | | * 经营不善 |
| | | */ |
| | | @PostMapping("/selectJy") |
| | | public R selectJy() { |
| | | List<Map<Object, Object>> list = informationService.selectJy(); |
| | | for (int i=0;i<list.size();i++){ |
| | | |
| | | public R selectJy(String jurisdiction) { |
| | | List<Map<Object, Object>> list = informationService.selectJy(jurisdiction); |
| | | List list1 = new ArrayList(); |
| | | Map map = new HashMap(); |
| | | int count = 0; |
| | | for (int i = 0; i < list.size(); i++) { |
| | | String num = list.get(i).get("num").toString(); |
| | | int a = Integer.parseInt(num); |
| | | if (a == 0) { |
| | | count++; |
| | | list1.add(list.get(i)); |
| | | } |
| | | } |
| | | return R.data(list); |
| | | map.put("Count", count); |
| | | map.put("List", list1); |
| | | return R.data(map); |
| | | } |
| | | |
| | | /** |
| | | * 有实无名 |
| | | */ |
| | | @PostMapping("/selectYs") |
| | | public R selectYs(String jurisdiction) { |
| | | List<Map<Object, Object>> list = informationService.selectYs(jurisdiction); |
| | | List list1 = new ArrayList(); |
| | | Map map = new HashMap(); |
| | | int count = 0; |
| | | for (int i = 0; i < list.size(); i++) { |
| | | String num = list.get(i).get("num").toString(); |
| | | int a = Integer.parseInt(num); |
| | | if (a == 0) { |
| | | count++; |
| | | list1.add(list.get(i)); |
| | | } |
| | | } |
| | | map.put("Count", count); |
| | | map.put("List", list1); |
| | | return R.data(map); |
| | | } |
| | | |
| | | /** |
| | | * @return |
| | | */ |
| | | @PostMapping("/selectAge") |
| | | public R selectAge(String jurisdiction, String deptid) { |
| | | List<Map<Object, Object>> list = informationService.selectAge(jurisdiction, deptid); |
| | | int qcount = 0;//青年 |
| | | int zcount = 0;//中年 |
| | | int lcount = 0;//老年 |
| | | for (int i = 0; i < list.size(); i++) { |
| | | String age = list.get(i).get("age").toString(); |
| | | int a = Integer.parseInt(age); |
| | | if (a <= 0) { |
| | | continue; |
| | | } else if (a >= 19 && a < 35) { |
| | | qcount ++; |
| | | } else if (a >= 36 && a < 59) { |
| | | zcount++; |
| | | } else { |
| | | lcount++; |
| | | } |
| | | } |
| | | Map map = new HashMap(); |
| | | map.put("qcount",qcount); |
| | | map.put("zcount",zcount); |
| | | map.put("lcount",lcount); |
| | | return R.data(map); |
| | | } |
| | | |
| | | |