public UserTransport[] GetUserTransports(string userName)
 {
     HTTPBasicCheckAttribute.AdditionalCheck(userName, HTTPCheckRoles.sysAdmin | HTTPCheckRoles.clinAdmin);
     UserTransportEntity[] tes = new CriticalResultsEntityManager().GetUserTransports(userName);
     List<UserTransport> transports = new List<UserTransport>();
     foreach (UserTransportEntity te in tes)
     {
         UserTransport transport = new UserTransport(te);
         transport.ResolveLevels();
         transport.ResolveTransport();
         transports.Add(transport);
     }
     return transports.ToArray();
 }
 public UserTransport UpdateUserTransport(string userName, string transportName, string originalAddress, string address)
 {
     HTTPBasicCheckAttribute.AdditionalCheck(userName, HTTPCheckRoles.sysAdmin | HTTPCheckRoles.clinAdmin);
     UserTransportEntity ute = new CriticalResultsEntityManager().UpdateUserTransport(userName, transportName, originalAddress, address);
     UserTransport ut = new UserTransport(ute);
     ut.ResolveTransport();
     ut.ResolveLevels();
     return ut;
 }
Ejemplo n.º 3
0
        public bool ResolveTransports()
        {
            if (_Entity == null)
                return false;
            if (_Entity.UserTransports == null)
                return false;

            _UserTransports = new List<UserTransport>();
            foreach (UserTransportEntity e in _Entity.UserTransports)
            {
                UserTransport t = new UserTransport(e);
                t.ResolveTransport();
                _UserTransports.Add(t);
            }
            return true;
        }