用户新增bug修复

usertest
cjy 4 months ago
parent 236dc8f006
commit 8a7ff27f2e

@ -127,7 +127,7 @@ public class UserService : IUserService
var entity = db.Insertable(data).ExecuteReturnEntity();
if (model.RoleIds.Count() > 0)
if (model.RoleIds.IsNotNull() && model.RoleIds.Count() > 0)
{
foreach (var item in model.RoleIds)
{
@ -140,7 +140,7 @@ public class UserService : IUserService
}
}
if (model.OrgIds.Count() > 0)
if (model.OrgIds.IsNotNull() && model.OrgIds.Count() > 0)
{
foreach (var item in model.OrgIds)
{
@ -152,7 +152,7 @@ public class UserService : IUserService
db.Insertable(orgUser).ExecuteCommand();
}
}
if (model.LaneIds.Count() > 0)
if (model.LaneIds.IsNotNull() && model.LaneIds.Count() > 0)
{
foreach (var item in model.LaneIds)
{

Loading…
Cancel
Save