Pu Zhibing
2025-05-19 3244b550596e0330031b3f4547356927df83b0ad
ruoyi-service/ruoyi-chargingPile/src/main/java/com/ruoyi/chargingPile/controller/TChargingGunController.java
@@ -69,6 +69,22 @@
    @Autowired
    private FileUploadConfig fileUploadConfig;
    /**
     * 查询所有枪
     */
    @PostMapping(value = "/getAllGun")
    public R<List<TChargingGun>> getAllGun() {
        return R.ok(chargingGunService.list());
    }
    /**
     * 查询所有桩
     */
    @PostMapping(value = "/getAllPile")
    public R<List<TChargingPile>> getAllPile() {
        return R.ok(chargingPileService.list());
    }
    /**
     * 查询充电枪列表
     */
@@ -321,5 +337,16 @@
                .eq(TChargingGun::getDelFlag, 0));
        return R.ok(list);
    }
    /**
     * 根据枪唯一码查询信息
     * @return
     */
    @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));
        return R.ok(chargingGun);
    }
}