Merge remote-tracking branch 'origin/feature/DM/nflg-bom-transition' into feature/DM/nflg-bom-transition
This commit is contained in:
commit
fd54b8aead
|
|
@ -111,4 +111,13 @@ public interface BomNewEbomParentMapper extends BaseMapper<BomNewEbomParentEntit
|
|||
void updateLastVersionIs();
|
||||
|
||||
List<BomNewPbomParentVO> getReverseBoms(Long parentRowId);
|
||||
|
||||
//判断是否跟节点
|
||||
Integer isRoot(@Param("materialNo") String materialNo);
|
||||
|
||||
//判断是否用户跟节点
|
||||
Integer isUserRoot(@Param("materialNo")String materialNo, @Param("createdBy") String createdBy);
|
||||
|
||||
//判断是否跟节点
|
||||
Integer isRootIsForWaitReview(@Param("materialNo") String materialNo);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -78,10 +78,11 @@ public class ForwardReportVO extends BaseMaterialVO {
|
|||
DecimalFormat df2 = new DecimalFormat("#.####");
|
||||
|
||||
return new BigDecimal(df2.format(num));
|
||||
}else{
|
||||
return new BigDecimal(1);
|
||||
}
|
||||
// return num;
|
||||
// else{
|
||||
// return new BigDecimal(1);
|
||||
// }
|
||||
return num;
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -1249,8 +1249,9 @@ public class BomNewEbomParentService extends ServiceImpl<BomNewEbomParentMapper,
|
|||
newParent.setRevertUserName(null);
|
||||
newParent.setAuditUserName(null);
|
||||
newParent.setAuditTime(null);
|
||||
newParent.setRootIs(1);
|
||||
newParent.setUserRootIs(1);
|
||||
newParent.setRootIs(this.getBaseMapper().isRoot(parent.getMaterialNo())>0?0:1);
|
||||
newParent.setUserRootIs(this.getBaseMapper().isUserRoot(parent.getMaterialNo(),SessionUtil.getUserCode())>0?0:1);
|
||||
newParent.setRootIsForWaitReview(this.getBaseMapper().isRootIsForWaitReview(parent.getMaterialNo())>0?0:1);
|
||||
newParent.setSapState(1);
|
||||
newParent.setSapTime(null);
|
||||
newParent.setModifyTime(null);
|
||||
|
|
|
|||
|
|
@ -77,7 +77,11 @@ public abstract class BaseForwardReport {
|
|||
if(Objects.nonNull(parent.getNum())) {
|
||||
for (ForwardReportVO data :
|
||||
dataList) {
|
||||
data.setNum(parent.getNum().multiply(data.getNum()));
|
||||
if(Objects.nonNull(data.getNum())) {
|
||||
data.setNum(parent.getNum().multiply(data.getNum()));
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -439,9 +439,9 @@
|
|||
created_by=#{userCode}
|
||||
</if>
|
||||
<if test="userJob==1">
|
||||
AND ((root_is=1 OR user_root_is=1) AND status=2) OR (status IN (1,3) AND (root_is=1 OR
|
||||
AND (((root_is=1 OR user_root_is=1) AND status=2) OR (status IN (1,3) AND (root_is=1 OR
|
||||
user_root_is=1 OR
|
||||
root_is_for_wait_review=1) AND created_by=#{userCode})
|
||||
root_is_for_wait_review=1) AND created_by=#{userCode}))
|
||||
</if>
|
||||
<if test="query.deviseName!=null and query.deviseName!=''">
|
||||
AND devise_name LIKE concat('%', #{query.deviseName}, '%')
|
||||
|
|
@ -623,4 +623,20 @@
|
|||
#{parentRowId}
|
||||
</foreach>
|
||||
</delete>
|
||||
|
||||
<!--是否跟节点大于0为否-->
|
||||
<select id="isRoot" resultType="java.lang.Integer">
|
||||
select count(1) from t_bom_new_ebom_child where material_no=#{materialNo}
|
||||
</select>
|
||||
|
||||
<!--是否用户跟节点大于0为否-->
|
||||
<select id="isUserRoot">
|
||||
select count(1) from t_bom_new_ebom_child where material_no=#{materialNo} and created_by=#{createdBy}
|
||||
</select>
|
||||
|
||||
<!--是否工作表跟节点大于0就是否-->
|
||||
<select id="isRootIsForWaitReview">
|
||||
select COUNT(1) from t_bom_new_ebom_parent a join t_bom_new_ebom_child b on a.row_id=b.parent_row_id
|
||||
where b.material_no=#{materialNo} and a.status < 4
|
||||
</select>
|
||||
</mapper>
|
||||
|
|
|
|||
Loading…
Reference in New Issue