Ejemplo n.º 1
0
        public UserCollection GetUnSignedUsers(BPMConnection cn, BPMObjectNameCollection accounts)
        {
            BPMObjectNameCollection accountsUnSigned = new BPMObjectNameCollection();

            accountsUnSigned.AddRange(accounts);

            foreach (Footmark footmark in this)
            {
                if (accountsUnSigned.Contains(footmark.Account))
                {
                    accountsUnSigned.Remove(footmark.Account);
                }
            }

            UserCollection users = new UserCollection();

            foreach (string account in accountsUnSigned)
            {
                if (users.Contains(account))
                {
                    continue;
                }

                User user = User.TryGetUser(cn, account);
                if (user != null)
                {
                    users.Add(user);
                }
            }

            return(users);
        }