public string AddAttr(string attrname, string description, string categoryID, int type, string operateid) { var attrid = Guid.NewGuid().ToString().ToLower(); var dal = new ProductsDAL(); if (dal.AddAttr(attrid, attrname, description, categoryID, type, operateid)) { CacheAttrs.Add(new ProductAttr() { AttrID = attrid, AttrName = attrname, Description = description, CategoryID = categoryID, ClientID = "", CreateTime = DateTime.Now, CreateUserID = operateid, Status = 1, AttrValues = new List<AttrValue>() }); return attrid; } return string.Empty; }