| | |
| | | * 新增临时枪 |
| | | * @return |
| | | */ |
| | | @InnerAuth |
| | | @PostMapping("/addGunTemp") |
| | | @ResponseBody |
| | | R<Integer> addGunTemp(@RequestBody TChargingGun gun){ |
| | |
| | | /** |
| | | * 查询所有枪 |
| | | */ |
| | | @InnerAuth |
| | | @PostMapping(value = "/getAllGun") |
| | | @ResponseBody |
| | | public R<List<TChargingGun>> getAllGun() { |
| | |
| | | /** |
| | | * 查询所有桩 |
| | | */ |
| | | @InnerAuth |
| | | @PostMapping(value = "/getAllPile") |
| | | public R<List<TChargingPile>> getAllPile() { |
| | | return R.ok(chargingPileService.list()); |
| | |
| | | * @return |
| | | */ |
| | | @ResponseBody |
| | | @InnerAuth |
| | | @PostMapping(value = "/getAllName/{id}") |
| | | public R<String> getAllName(@PathVariable Integer id){ |
| | | TChargingGun chargingGun = chargingGunService.getById(id); |
| | |
| | | * @return |
| | | */ |
| | | @ResponseBody |
| | | @InnerAuth |
| | | @PostMapping(value = "/getChargingGunById/{id}") |
| | | public R<TChargingGun> getChargingGunById(@PathVariable Integer id){ |
| | | TChargingGun chargingGun = chargingGunService.getById(id); |
| | |
| | | * @return |
| | | */ |
| | | @ResponseBody |
| | | @InnerAuth |
| | | @PostMapping(value = "/getAllInfoById/{id}") |
| | | public R<SiteNameVO> getAllInfoById(@PathVariable Integer id){ |
| | | SiteNameVO siteNameVO = new SiteNameVO(); |
| | |
| | | * @param code |
| | | * @return |
| | | */ |
| | | @InnerAuth |
| | | @PostMapping("/getChargingGunByCode") |
| | | public R<TChargingGun> getChargingGunByCode(@RequestBody GetChargingGunByCode code){ |
| | | TChargingPile chargingPile = chargingPileService.getOne(new LambdaQueryWrapper<TChargingPile>() |
| | |
| | | * @param chargingGun |
| | | * @return |
| | | */ |
| | | @InnerAuth |
| | | @PostMapping("/updateChargingGunById") |
| | | public R<String> updateChargingGunById(@RequestBody TChargingGun chargingGun){ |
| | | chargingGunService.updateById(chargingGun); |
| | |
| | | * @param chargingPileId |
| | | * @return |
| | | */ |
| | | @InnerAuth |
| | | @PostMapping("/getChargingGunByChargingPileId") |
| | | public R<List<TChargingGun>> getChargingGunByChargingPileId(@RequestParam("chargingPileId") Integer chargingPileId){ |
| | | List<TChargingGun> list = chargingGunService.list(new LambdaQueryWrapper<TChargingGun>().eq(TChargingGun::getChargingPileId, chargingPileId) |
| | |
| | | * 根据充电桩ids获取枪 |
| | | * @return |
| | | */ |
| | | @InnerAuth |
| | | @PostMapping("/getChargingGunByChargingPileIds") |
| | | public R<List<TChargingGun>> getChargingGunByChargingPileIds(@RequestBody GetChargingGunByChargingPileIdsVo vo){ |
| | | if(vo.getChargingPileIds().isEmpty()){ |
| | |
| | | * 根据枪唯一码查询信息 |
| | | * @return |
| | | */ |
| | | @InnerAuth |
| | | @PostMapping("/getChargingGunByFullNumber") |
| | | public R<TChargingGun> getChargingGunByFullNumber(@RequestParam("fullNumber") String fullNumber){ |
| | | TChargingGun chargingGun = chargingGunService.getOne(new LambdaQueryWrapper<TChargingGun>().eq(TChargingGun::getDelFlag, 0).eq(TChargingGun::getFullNumber, fullNumber)); |