自动化立体仓库 - WMS系统
whycq
2024-07-04 09a482e8fb4d4dac63aed1503fd91e738ddb070d
src/main/java/com/zy/asrs/controller/LocDetlController.java
@@ -31,6 +31,7 @@
    @Autowired
    private LocDetlService locDetlService;
    @Autowired
    private LocDetlMapper locDetlMapper;
    @Autowired
@@ -66,6 +67,18 @@
        return R.parse(BaseRes.EMPTY);
    }
    @GetMapping (value = "/locDetl/pageList/auth")
    @ManagerAuth(memo = "分页查询库存明细")
    public R pageList(@RequestParam Map<String,Object> param){
        if (Cools.isEmpty(param.get("locNo"))){
            return new R(201,"");
        }
        Page<LocDetl> locDetlPage = locDetlService.selectPage(new Page<>(Integer.parseInt((String) param.get("curr"))
                , Integer.parseInt((String) param.get("limit"))), new EntityWrapper<LocDetl>().eq("loc_no", param.get("locNo")));
        return R.ok(locDetlPage);
    }
    @RequestMapping(value = "/stock/out/list/auth")
    @ManagerAuth
    public R stockOutList(@RequestParam(defaultValue = "1")Integer curr,
@@ -83,22 +96,14 @@
        return R.ok(locDetlService.getStockOut(toPage(curr, limit, param, LocDetl.class)));
    }
    @RequestMapping(value = "/locDetl/list/auth")
    @RequestMapping(value = "/locDetl/list/auth")// /locDetl/list/auth 接口问题
    @ManagerAuth
    public R list(@RequestParam(defaultValue = "1")Integer curr,
                  @RequestParam(defaultValue = "10")Integer limit,
                  @RequestParam(required = false)String orderByField,
                  @RequestParam(required = false)String orderByType,
                  @RequestParam(required = false)String condition,
                  @RequestParam Map<String, Object> param,
                  @RequestParam(required = false)Boolean unreason){
        if (unreason) {
            return R.ok(locDetlService.selectPage(new Page<>(curr, limit), new EntityWrapper<LocDetl>()
                    .where(" DATALENGTH( batch ) != 11 or\n" +
                            "            batch LIKE '%[a-z]%'")));
        }
        param.remove("unreason");
                  @RequestParam Map<String, Object> param){
//        String row = "";
        EntityWrapper<LocDetl> wrapper = new EntityWrapper<>();
//        if (param.get("row") != null) {
@@ -119,10 +124,10 @@
//            wrapper.and()
//                    .where("loc_no like '" +row +"%'");
//        }
        return R.ok(locDetlService.selectPage(new Page<>(curr, limit), wrapper));
    }
    private <T> void convert(Map<String, Object> map, EntityWrapper<T> wrapper){
        for (Map.Entry<String, Object> entry : map.entrySet()){
            String val = String.valueOf(entry.getValue());