单据验收人,创建人修改
parent
4d39ca149e
commit
5a6be7ed07
@ -0,0 +1,44 @@
|
|||||||
|
package com.glxp.sale.admin.util;
|
||||||
|
|
||||||
|
import cn.hutool.core.collection.CollUtil;
|
||||||
|
import cn.hutool.core.util.StrUtil;
|
||||||
|
import com.glxp.sale.admin.entity.basic.UdiInfoEntity;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public class UdiInfoUtil {
|
||||||
|
|
||||||
|
|
||||||
|
public static UdiInfoEntity initUdiInfoEntity(UdiInfoEntity udiInfoEntity) {
|
||||||
|
if (StrUtil.isNotEmpty(udiInfoEntity.getScbssfbhph()) && "否".equals(udiInfoEntity.getScbssfbhph())) {
|
||||||
|
udiInfoEntity.setAllowNoBatch(true);
|
||||||
|
}
|
||||||
|
if (StrUtil.isNotEmpty(udiInfoEntity.getScbssfbhscrq()) && "否".equals(udiInfoEntity.getScbssfbhscrq())) {
|
||||||
|
udiInfoEntity.setAllowNoProduct(true);
|
||||||
|
}
|
||||||
|
if (StrUtil.isNotEmpty(udiInfoEntity.getScbssfbhsxrq()) && "否".equals(udiInfoEntity.getScbssfbhsxrq())) {
|
||||||
|
udiInfoEntity.setAllowNoExpire(true);
|
||||||
|
}
|
||||||
|
return udiInfoEntity;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static List<UdiInfoEntity> initUdiInfoEntitys(List<UdiInfoEntity> udiInfoEntitys) {
|
||||||
|
if (CollUtil.isNotEmpty(udiInfoEntitys)) {
|
||||||
|
for (UdiInfoEntity udiInfoEntity : udiInfoEntitys) {
|
||||||
|
if (StrUtil.isNotEmpty(udiInfoEntity.getScbssfbhph()) && "否".equals(udiInfoEntity.getScbssfbhph())) {
|
||||||
|
udiInfoEntity.setAllowNoBatch(true);
|
||||||
|
}
|
||||||
|
if (StrUtil.isNotEmpty(udiInfoEntity.getScbssfbhscrq()) && "否".equals(udiInfoEntity.getScbssfbhscrq())) {
|
||||||
|
udiInfoEntity.setAllowNoProduct(true);
|
||||||
|
}
|
||||||
|
if (StrUtil.isNotEmpty(udiInfoEntity.getScbssfbhsxrq()) && "否".equals(udiInfoEntity.getScbssfbhsxrq())) {
|
||||||
|
udiInfoEntity.setAllowNoExpire(true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return udiInfoEntitys;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
Loading…
Reference in New Issue