【物料变更】多选下拉 去掉字段值最前面的逗号

This commit is contained in:
tanfengling@x-ri.com 2025-12-19 17:54:14 +08:00
parent 28230174f7
commit f3dae0d6b9
1 changed files with 6 additions and 0 deletions

View File

@ -348,7 +348,13 @@ public class MaterialBillPlugin extends AbstractBillPlugIn {
if ("name".equals(name)) {
newValue = newValue.replaceAll("_copy", "");
}
if(newValue.startsWith(",")){
newValue = newValue.substring(1);
}
if (StringUtils.isNotBlank(oldValue)) {
if(oldValue.startsWith(",")){
oldValue = oldValue.substring(1);
}
if (!oldValue.equals(newValue)) {
changeFields.append(",").append(name);
changeContent.append("字段:" + displayName + ",变更前:" + oldValue + ",变更后:" + newValue + "");