仓库导出修改

liweidong
jinna 3 days ago
parent 5bd525ed71
commit 509f2444e9
  1. 20
      blade-service/blade-wms/src/main/java/org/springblade/wms/controller/StStorageLocationController.java
  2. 1
      blade-service/blade-wms/src/main/java/org/springblade/wms/mapper/StStorageLocationMapper.xml

@ -240,7 +240,25 @@ public class StStorageLocationController extends BladeController {
//if (!AuthUtil.isAdministrator()) { //if (!AuthUtil.isAdministrator()) {
// queryWrapper.lambda().eq(StStorageLocation::getTenantId, bladeUser.getTenantId()); // queryWrapper.lambda().eq(StStorageLocation::getTenantId, bladeUser.getTenantId());
//} //}
queryWrapper.lambda().eq(StStorageLocation::getIsDeleted, BladeConstant.DB_NOT_DELETED); queryWrapper.clear();
Object shIdObj = stStorageLocation.get("shId");
String shId = shIdObj != null ? shIdObj.toString() : "";
if (org.springblade.core.tool.utils.StringUtil.isNotBlank(shId)) {
queryWrapper.like("sl.sh_id", shId);
}
Object locationObj = stStorageLocation.get("location");
String location = locationObj != null ? locationObj.toString().trim() : "";
if (org.springblade.core.tool.utils.StringUtil.isNotBlank(location)) {
queryWrapper.like("sl.location", location);
}
Object goodsCodeObj = stStorageLocation.get("goodsCode");
String goodsCode = goodsCodeObj != null ? goodsCodeObj.toString().trim() : "";
if (org.springblade.core.tool.utils.StringUtil.isNotBlank(goodsCode)) {
queryWrapper.like("sl.goods_code", goodsCode);
}
queryWrapper.eq("sl.is_deleted", BladeConstant.DB_NOT_DELETED);
List<StStorageLocationExcel> list = stStorageLocationService.exportStStorageLocation(queryWrapper); List<StStorageLocationExcel> list = stStorageLocationService.exportStStorageLocation(queryWrapper);
ExcelUtil.export(response, "库位维护表数据" + DateUtil.time(), "库位维护表数据表", list, StStorageLocationExcel.class); ExcelUtil.export(response, "库位维护表数据" + DateUtil.time(), "库位维护表数据表", list, StStorageLocationExcel.class);
} }

@ -135,7 +135,6 @@
sh.sh_name sh.sh_name
FROM st_storage_location sl FROM st_storage_location sl
LEFT JOIN st_storehouse sh ON sl.sh_id = sh.id LEFT JOIN st_storehouse sh ON sl.sh_id = sh.id
WHERE 1=1
${ew.customSqlSegment} ${ew.customSqlSegment}
</select> </select>

Loading…
Cancel
Save