yuyou_x
2024-03-13 37a2e1209d1cddb71f7740543e8df2e3a03cfd1f
新增或修改物料信息时 物料编码唯一
1个文件已修改
16 ■■■■■ 已修改文件
Wms/WMS.BLL/SysServer/MaterialsServer.cs 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Wms/WMS.BLL/SysServer/MaterialsServer.cs
@@ -146,6 +146,14 @@
            //捕获异常
            try
            {
                int count = GetMateByNo(matedto.SkuNo);
                if (count > 0)
                {
                    throw new Exception("物料编码重复");
                }
                //映射模型
                SysMaterials mate = _mapper.Map<SysMaterials>(matedto);
                mate.AuditStatusNo = "9"; //审核状态
@@ -201,6 +209,14 @@
            //捕获异常
            try
            {
                int count = GetMateByNo(matedto.SkuNo);
                if (count > 0)
                {
                    throw new Exception("物料编码重复");
                }
                if (matedto.AdventTime > 365 && matedto.AdventTime < 30)
                {
                    return 2;