Merge branch 'dev_20260429' into dev_WMS20260401
# Conflicts: # mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/OmsServiceFeign.java # mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/UserServiceFeign.java # mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/factory/RemoteOmsFeignFallbackFactory.java # mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/factory/RemoteUserFeignFallbackFactory.java # mhd-modules/mhd-system/src/main/java/com/mhd/basic/application/service/batchDetail/BatchDetailApplicationService.java # mhd-modules/mhd-system/src/main/java/com/mhd/basic/domain/batchDetail/service/BatchDetailDomainService.java # mhd_oms/src/main/java/com/mhd/oms/interfaces/facade/sysTableConfig/SysTableConfigApi.java
This commit is contained in:
+32
@@ -264,4 +264,36 @@ public class MaterialBaseInfoDTO extends BaseVOEntity {
|
||||
@ApiModelProperty("是否抄码: 1-是 2-否")
|
||||
@Excel(name = "是否抄码: 1-是 2-否")
|
||||
private Integer copyCode;
|
||||
|
||||
@ApiModelProperty("货物类型:0-物料 1-半成品 2-成品")
|
||||
@Excel(name = "货物类型:0-物料 1-半成品 2-成品")
|
||||
private Integer goodsType;
|
||||
|
||||
@ApiModelProperty("毛重(kg)")
|
||||
@Excel(name = "毛重(kg)")
|
||||
private BigDecimal grossWeight;
|
||||
|
||||
@ApiModelProperty("推送状态")
|
||||
private Integer pushStatus;
|
||||
|
||||
@ApiModelProperty("推送时间起")
|
||||
private String pushTimeStart;
|
||||
|
||||
@ApiModelProperty("推送时间止")
|
||||
private String pushTimeEnd;
|
||||
|
||||
@ApiModelProperty("创建时间起")
|
||||
private String createTimeStart;
|
||||
|
||||
@ApiModelProperty("创建时间止")
|
||||
private String createTimeEnd;
|
||||
|
||||
@ApiModelProperty("更新时间起")
|
||||
private String updateTimeStart;
|
||||
|
||||
@ApiModelProperty("更新时间止")
|
||||
private String updateTimeEnd;
|
||||
|
||||
@ApiModelProperty(name = "推送人名称")
|
||||
private String pushByName;
|
||||
}
|
||||
|
||||
+5
-1
@@ -162,7 +162,7 @@ public class MaterialInventoryDTO extends MaterialBaseDTO {
|
||||
@ApiModelProperty("箱号/卡板号")
|
||||
@Excel(name = "箱号/卡板号")
|
||||
private String boxPalletNo;
|
||||
//查询规则 hz:货主,wl:物料,kw:库位,wlkw:物料库位,all:全部
|
||||
//查询规则 hz:货主,hzwl:货主+物料,wl:物料,kw:库位,wlkw:物料库位,all:全部(materialInventoryApi/listAll 传 hz 时后端按货主+物料分组)
|
||||
private String queryRule;
|
||||
|
||||
@ApiModelProperty("净重(KG)")
|
||||
@@ -185,4 +185,8 @@ public class MaterialInventoryDTO extends MaterialBaseDTO {
|
||||
@Excel(name = "冻结数量大于0条件")
|
||||
private String greaterThanFreezeQuantity;
|
||||
|
||||
/** 为 true 时排除库存数量为 0 的行(出库分配选库存用);库存查询页不传或 false */
|
||||
@ApiModelProperty(value = "是否排除库存数量为0", example = "false")
|
||||
private Boolean excludeZeroInventoryQuantity;
|
||||
|
||||
}
|
||||
+38
-1
@@ -1,7 +1,10 @@
|
||||
package com.mhd.wms.interfaces.facadeApi.materialBaseInfo;
|
||||
|
||||
import cn.hutool.core.date.DateUtil;
|
||||
import com.github.pagehelper.Page;
|
||||
import com.mhd.common.core.domain.entity.R;
|
||||
import com.mhd.common.core.exception.ServiceException;
|
||||
import com.mhd.common.core.utils.StringUtils;
|
||||
import com.mhd.common.core.web.controller.BaseController;
|
||||
import com.mhd.common.core.web.domain.AjaxResult;
|
||||
import com.mhd.common.core.web.page.TableDataInfo;
|
||||
@@ -17,6 +20,7 @@ import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
@@ -109,10 +113,43 @@ public class MaterialBaseInfoApi extends BaseController {
|
||||
return materialBaseInfoApplicationService.importData(file);
|
||||
}
|
||||
|
||||
@ApiOperation("物料管理更新推送信息")
|
||||
@PostMapping("/updatePushStatus")
|
||||
public AjaxResult<?> updateMaterialPushStatus(@RequestParam("materialBaseInfoId") Long materialBaseInfoId,
|
||||
@RequestParam("pushStatus") Integer pushStatus,
|
||||
@RequestParam(value = "pushTime",required = false) String pushTime,
|
||||
@RequestParam(value = "pushBy",required = false) Long pushBy,
|
||||
@RequestParam(value = "pushByName",required = false) String pushByName){
|
||||
Date pushTimeDate = null;
|
||||
if (StringUtils.isNotBlank(pushTime)) {
|
||||
pushTimeDate = DateUtil.parse(pushTime);
|
||||
}
|
||||
return toAjax(materialBaseInfoApplicationService.updatePushStatus(materialBaseInfoId, pushStatus, pushTimeDate, pushBy, pushByName));
|
||||
}
|
||||
|
||||
@ApiOperation("查询物料基础信息列表")
|
||||
@GetMapping("/queryList")
|
||||
public TableDataInfo queryList(MaterialBaseInfoDTO materialBaseInfoDTO)
|
||||
{
|
||||
//转换实体
|
||||
MaterialBaseInfoDO materialBaseInfoDO = materialBaseInfoAssembler.toDO(materialBaseInfoDTO);
|
||||
startPage();
|
||||
List<MaterialBaseInfoPO> list = materialBaseInfoApplicationService.queryList(materialBaseInfoDO);
|
||||
Page<MaterialBaseInfoPO> page = (Page<MaterialBaseInfoPO>) list;
|
||||
TableDataInfo tableDataInfo = new TableDataInfo();
|
||||
tableDataInfo.setTotal(page.getTotal());
|
||||
tableDataInfo.setCode(200);
|
||||
tableDataInfo.setData(list);
|
||||
return tableDataInfo;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
@ApiOperation("根据物料ID列表批量查询物料")
|
||||
@GetMapping("/getBatchByIds")
|
||||
public TableDataInfo getBatchByIds(@RequestParam("materialBaseInfoIds") List<Long> materialBaseInfoIds) {
|
||||
return materialBaseInfoApplicationService.getBatchByIds(materialBaseInfoIds);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
+11
-3
@@ -48,11 +48,15 @@ public class MaterialInventoryApi extends BaseController {
|
||||
/**
|
||||
* 分页查询物料库存列表
|
||||
*/
|
||||
@ApiOperation("查询物料库存列表")
|
||||
@ApiOperation(value = "查询物料库存列表", notes = "库存查询页不传 excludeZeroInventoryQuantity 可查出数量为0;出库分配页传 excludeZeroInventoryQuantity=true 排除库存数量为0")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(MaterialInventoryDTO materialInventoryDTO,
|
||||
@RequestParam(value = "customerName", required = false) String customerName)
|
||||
@RequestParam(value = "customerName", required = false) String customerName,
|
||||
@RequestParam(value = "excludeZeroInventoryQuantity", required = false) Boolean excludeZeroInventoryQuantity)
|
||||
{
|
||||
if (Boolean.TRUE.equals(excludeZeroInventoryQuantity)) {
|
||||
materialInventoryDTO.setExcludeZeroInventoryQuantity(true);
|
||||
}
|
||||
// 出库分配前端传的是客户名称 customerName,这里通过名称查询货主ID,使用精确匹配(不模糊匹配)
|
||||
String shipperName = null; // 保存查询到的货主名称
|
||||
if (StringUtils.isNotBlank(customerName) && materialInventoryDTO.getShipperId() == null) {
|
||||
@@ -124,12 +128,16 @@ public class MaterialInventoryApi extends BaseController {
|
||||
return tableDataInfo;
|
||||
}
|
||||
|
||||
@ApiOperation("查询物料库存列表不分页")
|
||||
@ApiOperation("查询物料库存列表不分页;queryRule=hz 时按货主+物料分组(同一物料在不同货主各占一行)")
|
||||
@GetMapping("/listAll")
|
||||
public TableDataInfo listAll(MaterialInventoryDTO materialInventoryDTO)
|
||||
{
|
||||
//转换实体
|
||||
MaterialInventoryDO materialInventoryDO = materialInventoryAssembler.toDO(materialInventoryDTO);
|
||||
// 不分页列表按货主查询:需按「货主+物料」汇总;分页 /list 仍用 hz 表示仅按货主一行
|
||||
if ("hz".equals(materialInventoryDO.getQueryRule())) {
|
||||
materialInventoryDO.setQueryRule("hzwl");
|
||||
}
|
||||
List<MaterialInventoryPO> list = materialInventoryApplicationService.queryList(materialInventoryDO);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
+15
@@ -1,8 +1,11 @@
|
||||
package com.mhd.wms.interfaces.facadeApi.statementStatistics;
|
||||
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.github.pagehelper.PageInfo;
|
||||
import com.mhd.common.core.constant.HttpStatus;
|
||||
import com.mhd.common.core.utils.PageUtils;
|
||||
import com.mhd.common.core.web.page.PageDomain;
|
||||
import com.mhd.common.core.web.page.TableSupport;
|
||||
import com.mhd.common.core.web.page.TableDataInfo;
|
||||
import com.mhd.wms.application.service.statementStatistics.StatementStatisticsService;
|
||||
import com.mhd.wms.domain.statementStatistics.po.ImmediateInventoryPO;
|
||||
@@ -100,6 +103,18 @@ public class StatementStatisticsApi {
|
||||
PageUtils.startPage();
|
||||
}
|
||||
|
||||
/**
|
||||
* 即时库存分页:不注入 PageHelper 的 orderBy,保证仅使用 SQL 中的倒序(时间由晚到早)。
|
||||
*/
|
||||
private void startPageImmediateInventory()
|
||||
{
|
||||
PageDomain pageDomain = TableSupport.buildPageRequest();
|
||||
Integer pageNum = pageDomain.getPageNum();
|
||||
Integer pageSize = pageDomain.getPageSize();
|
||||
Boolean reasonable = pageDomain.getReasonable();
|
||||
PageHelper.startPage(pageNum, pageSize, "").setReasonable(reasonable);
|
||||
}
|
||||
|
||||
/**
|
||||
* 响应请求分页数据
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user