bug修复
This commit is contained in:
parent
1a2adabb77
commit
bd628eeae6
|
|
@ -168,4 +168,7 @@ public class LeaseApplyInfo implements Serializable {
|
||||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||||
@JSONField(format = "yyyy-MM-dd HH:mm:ss")
|
@JSONField(format = "yyyy-MM-dd HH:mm:ss")
|
||||||
private Date estimateLeaseTime;
|
private Date estimateLeaseTime;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "任务状态(数据字典)")
|
||||||
|
private Integer taskStatus;
|
||||||
}
|
}
|
||||||
|
|
@ -39,4 +39,11 @@ public interface LeaseApplyInfoMapper {
|
||||||
int batchInsert(@Param("list") List<LeaseApplyInfo> list);
|
int batchInsert(@Param("list") List<LeaseApplyInfo> list);
|
||||||
|
|
||||||
LeaseApplyInfo selectByTaskIdAndCompIdCq(@Param("taskId") String taskId);
|
LeaseApplyInfo selectByTaskIdAndCompIdCq(@Param("taskId") String taskId);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 根据任务id更新
|
||||||
|
* @param record
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
int updateById(LeaseApplyInfo record);
|
||||||
}
|
}
|
||||||
|
|
@ -1029,7 +1029,15 @@ public class TmTaskServiceImpl implements TmTaskService {
|
||||||
// 再审核领料任务信息表
|
// 再审核领料任务信息表
|
||||||
List<LeaseApplyInfo> leaseApplyInfoList = record.getLeaseApplyInfoList();
|
List<LeaseApplyInfo> leaseApplyInfoList = record.getLeaseApplyInfoList();
|
||||||
if (CollUtil.isNotEmpty(leaseApplyInfoList)) {
|
if (CollUtil.isNotEmpty(leaseApplyInfoList)) {
|
||||||
List<LeaseApplyInfo> applyInfoList = leaseApplyInfoList.stream().filter(t -> t.getCompanyId().equals(companyId.intValue())).collect(Collectors.toList());
|
for (LeaseApplyInfo info : leaseApplyInfoList) {
|
||||||
|
Integer companyId1 = info.getCompanyId();
|
||||||
|
List<LeaseApplyInfo> applyInfoList = new ArrayList<>();
|
||||||
|
if (companyId1 != null && companyId1 == 101) {
|
||||||
|
applyInfoList = leaseApplyInfoList.stream().filter(t -> t.getCompanyId().equals(101)).collect(Collectors.toList());
|
||||||
|
} else if (companyId1 != null && companyId1 == 102) {
|
||||||
|
applyInfoList = leaseApplyInfoList.stream().filter(t -> t.getCompanyId().equals(102)).collect(Collectors.toList());
|
||||||
|
}
|
||||||
|
//List<LeaseApplyInfo> applyInfoList = leaseApplyInfoList.stream().filter(t -> t.getCompanyId().equals(companyId.intValue())).collect(Collectors.toList());
|
||||||
if (CollUtil.isNotEmpty(applyInfoList)) {
|
if (CollUtil.isNotEmpty(applyInfoList)) {
|
||||||
for (LeaseApplyInfo leaseApplyInfo : applyInfoList) {
|
for (LeaseApplyInfo leaseApplyInfo : applyInfoList) {
|
||||||
taskId = leaseApplyInfo.getTaskId();
|
taskId = leaseApplyInfo.getTaskId();
|
||||||
|
|
@ -1040,6 +1048,7 @@ public class TmTaskServiceImpl implements TmTaskService {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
List<LeaseApplyInfo> leaseApplyInfo = tmTaskMapper.getLeaseApplyInfo(taskId);
|
List<LeaseApplyInfo> leaseApplyInfo = tmTaskMapper.getLeaseApplyInfo(taskId);
|
||||||
for (LeaseApplyInfo applyInfo : leaseApplyInfo) {
|
for (LeaseApplyInfo applyInfo : leaseApplyInfo) {
|
||||||
if (applyInfo.getStatus() != null) {
|
if (applyInfo.getStatus() != null) {
|
||||||
|
|
@ -1243,12 +1252,22 @@ public class TmTaskServiceImpl implements TmTaskService {
|
||||||
}
|
}
|
||||||
// 修改任务关联的协议
|
// 修改任务关联的协议
|
||||||
this.updateAgreementByTask(tmTask);
|
this.updateAgreementByTask(tmTask);
|
||||||
// 分公司审核
|
/*//根据taskId查询任务状态
|
||||||
tmTask.setTaskStatus(30);
|
TmTask task = tmTaskMapper.selectByPrimaryKey(tmTask.getTaskId());
|
||||||
|
if (task != null) {
|
||||||
|
// 内部审核驳回
|
||||||
|
if (task.getTaskStatus() == 100) {
|
||||||
|
// 待内部审核
|
||||||
|
task.setTaskStatus(32);
|
||||||
|
} else {
|
||||||
|
// 分公司审核
|
||||||
|
tmTask.setTaskStatus(30);
|
||||||
|
}
|
||||||
|
}
|
||||||
res = tmTaskMapper.updateTmTaskAuditStatus(tmTask);
|
res = tmTaskMapper.updateTmTaskAuditStatus(tmTask);
|
||||||
if (res == 0) {
|
if (res == 0) {
|
||||||
throw new RuntimeException("修改任务状态异常");
|
throw new RuntimeException("修改任务状态异常");
|
||||||
}
|
}*/
|
||||||
//先删除leaseApplyDetail
|
//先删除leaseApplyDetail
|
||||||
res = deletePreDetailData(tmTask);
|
res = deletePreDetailData(tmTask);
|
||||||
if (res == 0) {
|
if (res == 0) {
|
||||||
|
|
@ -1331,7 +1350,8 @@ public class TmTaskServiceImpl implements TmTaskService {
|
||||||
// 根据taskId查询id
|
// 根据taskId查询id
|
||||||
LeaseApplyInfo leaseApplyInfo = leaseApplyInfoMapper.selectByTaskIdAndCompId(String.valueOf(task.getTaskId()), task.getCompanyId());
|
LeaseApplyInfo leaseApplyInfo = leaseApplyInfoMapper.selectByTaskIdAndCompId(String.valueOf(task.getTaskId()), task.getCompanyId());
|
||||||
record.setId(leaseApplyInfo.getId());
|
record.setId(leaseApplyInfo.getId());
|
||||||
res = leaseApplyInfoMapper.updateByPrimaryKeySelective(record);
|
record.setTaskStatus(task.getTaskStatus());
|
||||||
|
res = leaseApplyInfoMapper.updateById(record);
|
||||||
/*LeaseApplyInfo leaseApplyInfo1 = task.getLeaseApplyInfo();
|
/*LeaseApplyInfo leaseApplyInfo1 = task.getLeaseApplyInfo();
|
||||||
String leasePerson = "";
|
String leasePerson = "";
|
||||||
String remark = "";
|
String remark = "";
|
||||||
|
|
|
||||||
|
|
@ -490,6 +490,57 @@
|
||||||
#{item.id,jdbcType=INTEGER}
|
#{item.id,jdbcType=INTEGER}
|
||||||
</foreach>
|
</foreach>
|
||||||
</update>
|
</update>
|
||||||
|
<update id="updateById">
|
||||||
|
update lease_apply_info
|
||||||
|
<set>
|
||||||
|
<if test="taskId != null">
|
||||||
|
task_id = #{taskId},
|
||||||
|
</if>
|
||||||
|
<if test="leasePerson != null and leasePerson != ''">
|
||||||
|
lease_person = #{leasePerson},
|
||||||
|
</if>
|
||||||
|
<if test="phone != null and phone != ''">
|
||||||
|
phone = #{phone},
|
||||||
|
</if>
|
||||||
|
<if test="type != null and type != ''">
|
||||||
|
`type` = #{type},
|
||||||
|
</if>
|
||||||
|
<choose>
|
||||||
|
<when test="taskStatus != null and taskStatus == 30">
|
||||||
|
company_audit_by = NULL,
|
||||||
|
company_audit_time = NULL,
|
||||||
|
company_audit_remark = NULL,
|
||||||
|
dept_audit_by = NULL,
|
||||||
|
dept_audit_time = NULL,
|
||||||
|
dept_audit_remark = NULL,
|
||||||
|
</when>
|
||||||
|
<when test="taskStatus != null and taskStatus == 32">
|
||||||
|
direct_audit_by = NULL,
|
||||||
|
direct_audit_time = NULL,
|
||||||
|
direct_audit_remark = NULL,
|
||||||
|
</when>
|
||||||
|
</choose>
|
||||||
|
<if test="createBy != null and createBy != ''">
|
||||||
|
create_by = #{createBy},
|
||||||
|
</if>
|
||||||
|
<if test="createTime != null">
|
||||||
|
create_time = #{createTime},
|
||||||
|
</if>
|
||||||
|
<if test="updateBy != null and updateBy != ''">
|
||||||
|
update_by = #{updateBy},
|
||||||
|
</if>
|
||||||
|
<if test="updateTime != null">
|
||||||
|
update_time = #{updateTime},
|
||||||
|
</if>
|
||||||
|
<if test="remark != null and remark != ''">
|
||||||
|
remark = #{remark},
|
||||||
|
</if>
|
||||||
|
<if test="companyId != null">
|
||||||
|
company_id = #{companyId},
|
||||||
|
</if>
|
||||||
|
</set>
|
||||||
|
where id = #{id}
|
||||||
|
</update>
|
||||||
|
|
||||||
<insert id="batchInsert" keyColumn="id" keyProperty="id" parameterType="map" useGeneratedKeys="true">
|
<insert id="batchInsert" keyColumn="id" keyProperty="id" parameterType="map" useGeneratedKeys="true">
|
||||||
<!--@mbg.generated-->
|
<!--@mbg.generated-->
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue