diff --git a/MyCode.Project.Services/Implementation/PurchaseOrder/SysLoginService.cs b/MyCode.Project.Services/Implementation/PurchaseOrder/SysLoginService.cs index 4cb9d83..4dab397 100644 --- a/MyCode.Project.Services/Implementation/PurchaseOrder/SysLoginService.cs +++ b/MyCode.Project.Services/Implementation/PurchaseOrder/SysLoginService.cs @@ -103,6 +103,11 @@ namespace MyCode.Project.Services.Implementation { pwd = EncryptHelper.SHA1Hash(request.Password); } + + if (string.IsNullOrWhiteSpace(request.SupplierId) && request.SystemType == 0) + { + throw new BaseException("供应商类型的账号必须选一个供应商"); + } SysLogin entity = new SysLogin(); if (request.Id.IsEmpty()) {