Пример #1
0
        public static void AddUserVLan(int userId, UserVlan vLan)
        {
            UserInfo user = GetUser(userId);

            //
            if (user == null)
            {
                throw new ApplicationException(String.Format("User with UserID={0} not found", userId));
            }

            XDocument doc   = XDocument.Parse(user.AdditionalParams ?? userAdditionalParamsTemplate);
            XElement  vlans = doc.Root.Element("VLans");

            vlans.Add(new XElement("VLan", new XAttribute("VLanID", vLan.VLanID), new XAttribute("Comment", vLan.Comment)));

            user.AdditionalParams = doc.ToString();
            UpdateUser(user);
        }
Пример #2
0
 public void AddUserVLan(int userId, UserVlan vLan)
 {
     UserController.AddUserVLan(userId, vLan);
 }
Пример #3
0
 public static void AddUserVLan(int userId, UserVlan vLan)
 {
     ES.Services.Users.AddUserVLan(userId, vLan);
 }
Пример #4
0
 public void AddUserVLan(int userId, UserVlan vLan)
 {
     UserController.AddUserVLan(userId, vLan);
 }
Пример #5
0
        public static void AddUserVLan(int userId, UserVlan vLan)
        {
            UserInfo user = GetUser(userId);
            //
			if (user == null)
                throw new ApplicationException(String.Format("User with UserID={0} not found", userId));

            XDocument doc = XDocument.Parse(user.AdditionalParams ?? userAdditionalParamsTemplate);
            XElement vlans = doc.Root.Element("VLans");
            vlans.Add(new XElement("VLan", new XAttribute("VLanID", vLan.VLanID), new XAttribute("Comment", vLan.Comment)));

            user.AdditionalParams = doc.ToString();
            UpdateUser(user);
        }
Пример #6
0
		public void AddUserVLan(int userId, UserVlan vLan)
		{
			object[] results = this.Invoke("AddUserVLan", new object[] {
                        userId,
                        vLan});
		}