예제 #1
0
 public static void CopyToEntity(this DT.ProjectPermission source, DA.ProjectPermission target)
 {
     if ((source == null) || (target == null))
     {
         return;
     }
     target.ProjectId       = source.ProjectId;
     target.GrantedUserId   = source.GrantedUserId;
     target.GrantedByUserId = source.GrantedByUserId;
 }
예제 #2
0
        public static DA.ProjectPermission ToEntity(this DT.ProjectPermission source)
        {
            if (source == null)
            {
                return(null);
            }
            var result = new DA.ProjectPermission();

            source.CopyToEntity(result);
            return(result);
        }
예제 #3
0
 public static DT.ProjectPermission ToDto(this DA.ProjectPermission source)
 {
     if (source == null)
     {
         return(null);
     }
     return(new DT.ProjectPermission {
         ProjectId = source.ProjectId,
         GrantedUserId = source.GrantedUserId,
         GrantedByUserId = source.GrantedByUserId
     });
 }