Commit 5c029641 authored by 季圣华's avatar 季圣华
Browse files

优化序列号新增的时候的判断,过滤序列号外的空格

parent c503b9c0
......@@ -406,7 +406,7 @@ public class SerialNumberService {
for (String sn : snArr) {
List<SerialNumber> list = new ArrayList<>();
SerialNumberExample example = new SerialNumberExample();
example.createCriteria().andMaterialIdEqualTo(materialId).andSerialNumberEqualTo(sn).andIsSellEqualTo("0")
example.createCriteria().andMaterialIdEqualTo(materialId).andSerialNumberEqualTo(sn.trim()).andIsSellEqualTo("0")
.andDeleteFlagNotEqualTo(BusinessConstants.DELETE_FLAG_DELETED);
list = serialNumberMapper.selectByExample(example);
//判断如果不存在重复序列号就新增
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment