示例#1
0
 /// <summary>
 /// 保存用户对象
 /// </summary>
 /// <param name="userEntity">用户实体</param>
 /// <param name="userLogOnEntity">登录实体</param>
 /// <param name="id">用户Id,为空则创建实体,否则更新实体</param>
 public Task <int> Save(UserEntity userEntity, UserLogOnEntity userLogOnEntity, string id, string userId)
 {
     if (!string.IsNullOrEmpty(id))
     {
         userEntity.AttachModifyInfo(id, userId);
     }
     else
     {
         userEntity.AttachCreateInfo(userId);
     }
     return(service.Save(userEntity, userLogOnEntity, id, userId));
 }