| | |
| | | @RequestParam(required = false)String orderByType, |
| | | @RequestParam(required = false)String condition, |
| | | @RequestParam Map<String, Object> param){ |
| | | // String row = ""; |
| | | EntityWrapper<LocDetl> wrapper = new EntityWrapper<>(); |
| | | // if (param.get("row") != null) { |
| | | // String chooseRow = (String) param.get("row"); |
| | | // if (chooseRow.length() == 1) { |
| | | // row = "0" + chooseRow; |
| | | // param.remove("row"); |
| | | // }else { |
| | | // row = chooseRow; |
| | | // param.remove("row"); |
| | | // } |
| | | // } |
| | | excludeTrash(param); |
| | | convert(param, wrapper); |
| | | allLike(LocDetl.class, param.keySet(), wrapper, condition); |
| | | if (!Cools.isEmpty(orderByField)){wrapper.orderBy(humpToLine(orderByField), "asc".equals(orderByType));} |
| | | // if (!row.equals("")){ |
| | | // wrapper.and() |
| | | // .where("loc_no like '" +row +"%'"); |
| | | // } |
| | | return R.ok(locDetlService.selectPage(new Page<>(curr, limit), wrapper)); |
| | | } |
| | | |
| | |
| | | .where("loc_no like '" +row +"%'"); |
| | | } |
| | | List<LocDetl> list = locDetlService.selectList(wrapper); |
| | | for (LocDetl item : list) { |
| | | if (item.getSpecs() != null) { |
| | | item.setSpecs(item.getSpecs().replace("\"", "\"\"")); // 转义双引号 |
| | | } |
| | | if (item.getBrand() != null) { |
| | | item.setBrand(item.getBrand().replace("\"", "\"\"")); |
| | | } |
| | | } |
| | | return R.ok(exportSupport(list, fields)); |
| | | } |
| | | |