diff --git a/bonus-modules/bonus-material/src/main/java/com/bonus/material/basic/domain/BmAgreementInfo.java b/bonus-modules/bonus-material/src/main/java/com/bonus/material/basic/domain/BmAgreementInfo.java index 4cfe2321..5994a9c9 100644 --- a/bonus-modules/bonus-material/src/main/java/com/bonus/material/basic/domain/BmAgreementInfo.java +++ b/bonus-modules/bonus-material/src/main/java/com/bonus/material/basic/domain/BmAgreementInfo.java @@ -41,8 +41,8 @@ public class BmAgreementInfo extends BaseEntity private Date signTime; /** 往来单位id */ - @Excel(name = "往来单位id") - @ApiModelProperty(value = "往来单位id") + //@Excel(name = "往来单位ID") + @ApiModelProperty(value = "往来单位ID") @NotNull(message = "往来单位id不能为空") private Long unitId; @@ -54,7 +54,7 @@ public class BmAgreementInfo extends BaseEntity private String unitName; /** 工程标段ID */ - @Excel(name = "工程标段ID") + //@Excel(name = "工程标段ID") @ApiModelProperty(value = "工程标段ID") @NotNull(message = "工程标段ID不能为空") private Long projectId; @@ -91,32 +91,32 @@ public class BmAgreementInfo extends BaseEntity private String phone; /** 数据所属组织 */ - @Excel(name = "数据所属组织") + //@Excel(name = "数据所属组织") @ApiModelProperty(value = "数据所属组织") private Long companyId; - /** 文件名 */ - @Excel(name = "文件名") - @ApiModelProperty(value = "文件名") - private String fileName; +// /** 文件名 */ +// @Excel(name = "文件名") +// @ApiModelProperty(value = "文件名") +// private String fileName; +// +// /** 文件URL */ +// @Excel(name = "文件URL") +// @ApiModelProperty(value = "文件URL") +// private String fileUrl; - /** 文件URL */ - @Excel(name = "文件URL") - @ApiModelProperty(value = "文件URL") - private String fileUrl; - - /** 0删除1启用 */ - @Excel(name = "0删除1启用") - @ApiModelProperty(value = "0删除1启用") + /** 0删除 1启用 */ + @Excel(name = "是否启用", readConverterExp = "0=删除,1=启用") + @ApiModelProperty(value = "0删除 1启用") private String status; /** 1内部单位 2外部单位 */ - @Excel(name = "1内部单位 2外部单位") - @ApiModelProperty(value = "1内部单位 2外部单位") + @Excel(name = "内外部单位", readConverterExp = "1=内部单位,2=外部单位") + @ApiModelProperty(value = "1内部单位 2外部单位") private String protocol; /** 是否结算(0 结算中 1已结算) */ - @Excel(name = "是否结算", readConverterExp = "0=,结=算中,1=已结算") + @Excel(name = "是否结算", readConverterExp = "0=结算中,1=已结算") private Long isSlt; @ApiModelProperty(value = "关键词") diff --git a/bonus-modules/bonus-material/src/main/java/com/bonus/material/lease/domain/LeaseApplyDetails.java b/bonus-modules/bonus-material/src/main/java/com/bonus/material/lease/domain/LeaseApplyDetails.java index f69f2587..0dac353a 100644 --- a/bonus-modules/bonus-material/src/main/java/com/bonus/material/lease/domain/LeaseApplyDetails.java +++ b/bonus-modules/bonus-material/src/main/java/com/bonus/material/lease/domain/LeaseApplyDetails.java @@ -12,11 +12,10 @@ import com.bonus.common.core.web.domain.BaseEntity; * @author xsheng * @date 2024-10-16 */ - - @Data @ToString public class LeaseApplyDetails extends BaseEntity { + private static final long serialVersionUID = 1L; /** ID */ diff --git a/bonus-modules/bonus-material/src/main/java/com/bonus/material/lease/domain/LeaseApplyInfo.java b/bonus-modules/bonus-material/src/main/java/com/bonus/material/lease/domain/LeaseApplyInfo.java index 255659ed..0d9eb19d 100644 --- a/bonus-modules/bonus-material/src/main/java/com/bonus/material/lease/domain/LeaseApplyInfo.java +++ b/bonus-modules/bonus-material/src/main/java/com/bonus/material/lease/domain/LeaseApplyInfo.java @@ -148,6 +148,9 @@ public class LeaseApplyInfo extends BaseEntity { @ApiModelProperty(value = "租赁单位id") private Integer leaseUnitId; + @ApiModelProperty(value = "协议id") + private Long agreementId; + @ApiModelProperty(value = "协议号") private String agreementCode; diff --git a/bonus-modules/bonus-material/src/main/java/com/bonus/material/lease/service/impl/LeaseApplyInfoServiceImpl.java b/bonus-modules/bonus-material/src/main/java/com/bonus/material/lease/service/impl/LeaseApplyInfoServiceImpl.java index fb892c2a..f2c94666 100644 --- a/bonus-modules/bonus-material/src/main/java/com/bonus/material/lease/service/impl/LeaseApplyInfoServiceImpl.java +++ b/bonus-modules/bonus-material/src/main/java/com/bonus/material/lease/service/impl/LeaseApplyInfoServiceImpl.java @@ -98,6 +98,9 @@ public class LeaseApplyInfoServiceImpl implements ILeaseApplyInfoService { */ @Override public AjaxResult insertLeaseApplyInfo(TmTaskRequestVo tmTaskRequestVo) { + if (tmTaskRequestVo.getLeaseApplyInfo() == null) { + return AjaxResult.error("请先填写领料任务信息"); + } tmTaskRequestVo.getLeaseApplyInfo().setCreateTime(DateUtils.getNowDate()); tmTaskRequestVo.getLeaseApplyInfo().setCreateBy(SecurityUtils.getUsername()); try { @@ -109,7 +112,7 @@ public class LeaseApplyInfoServiceImpl implements ILeaseApplyInfoService { tmTask.setCreateTime(DateUtils.getNowDate()); tmTask.setCreateBy(SecurityUtils.getUsername()); tmTaskMapper.insertTmTask(tmTask); - TmTaskAgreement tmTaskAgreement = new TmTaskAgreement(tmTask.getTaskId(), tmTaskRequestVo.getAgreementId()); + TmTaskAgreement tmTaskAgreement = new TmTaskAgreement(tmTask.getTaskId(), tmTaskRequestVo.getLeaseApplyInfo().getAgreementId()); tmTaskAgreement.setCreateTime(DateUtils.getNowDate()); tmTaskAgreement.setCreateBy(SecurityUtils.getUsername()); tmTaskAgreementMapper.insertTmTaskAgreement(tmTaskAgreement); diff --git a/bonus-modules/bonus-material/src/main/java/com/bonus/material/task/domain/TmTask.java b/bonus-modules/bonus-material/src/main/java/com/bonus/material/task/domain/TmTask.java index 1f68885f..a6eaf172 100644 --- a/bonus-modules/bonus-material/src/main/java/com/bonus/material/task/domain/TmTask.java +++ b/bonus-modules/bonus-material/src/main/java/com/bonus/material/task/domain/TmTask.java @@ -37,8 +37,8 @@ public class TmTask extends BaseEntity { private Integer taskStatus; /** 编号 */ - @Excel(name = "编号") - @ApiModelProperty(value = "编号") + @Excel(name = "任务编号") + @ApiModelProperty(value = "任务编号,如新购单号,领料单号,退料单号等") private String code; /** 数据所属组织 */ diff --git a/bonus-modules/bonus-material/src/main/java/com/bonus/material/task/domain/vo/TmTaskRequestVo.java b/bonus-modules/bonus-material/src/main/java/com/bonus/material/task/domain/vo/TmTaskRequestVo.java index 9c394f56..5c1796a0 100644 --- a/bonus-modules/bonus-material/src/main/java/com/bonus/material/task/domain/vo/TmTaskRequestVo.java +++ b/bonus-modules/bonus-material/src/main/java/com/bonus/material/task/domain/vo/TmTaskRequestVo.java @@ -24,8 +24,8 @@ public class TmTaskRequestVo extends BaseEntity { @ApiModelProperty(value = "任务状态(定义数据字典)") private Integer taskStatus; - /** 编号 */ - @Excel(name = "编号") + /** 任务编号,如新购单号,领料单号,退料单号等 */ + @Excel(name = "任务编号") @ApiModelProperty(value = "编号") private String code; diff --git a/bonus-modules/bonus-material/src/main/resources/mapper/material/lease/LeaseOutDetailsMapper.xml b/bonus-modules/bonus-material/src/main/resources/mapper/material/lease/LeaseOutDetailsMapper.xml index e033aec8..159b18cb 100644 --- a/bonus-modules/bonus-material/src/main/resources/mapper/material/lease/LeaseOutDetailsMapper.xml +++ b/bonus-modules/bonus-material/src/main/resources/mapper/material/lease/LeaseOutDetailsMapper.xml @@ -144,7 +144,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" WHEN 0 THEN IFNULL(subquery0.num, 0) ELSE - IFNULL(mt.num, 0) + IFNULL(mt.storage_num, 0) END as num FROM ma_type mt left join (SELECT mt.type_id, diff --git a/bonus-modules/bonus-material/src/main/resources/mapper/material/task/TmTaskMapper.xml b/bonus-modules/bonus-material/src/main/resources/mapper/material/task/TmTaskMapper.xml index 2401e197..90dbacd8 100644 --- a/bonus-modules/bonus-material/src/main/resources/mapper/material/task/TmTaskMapper.xml +++ b/bonus-modules/bonus-material/src/main/resources/mapper/material/task/TmTaskMapper.xml @@ -131,20 +131,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"