示例#1
0
        public Dictionary <string, object> GetNameValueList(string Categorys)
        {
            CheckParameter.NotEmpty(Categorys, "GetNameValueList 中的Categorys值为空");
            Dictionary <string, object> dic = new Dictionary <string, object>();

            string[] CategoryArray = Categorys.Split(',');
            foreach (string item in CategoryArray)
            {
                dic.Add(item, GetNameValue(item));
            }
            return(dic);
        }
示例#2
0
        public List <string> GetNameValue(string Category)
        {
            CheckParameter.NotEmpty(Category, "GetNameValue 中的Category值为空");
            List <string> ValueList = new List <string>();

            var NameValueList = nameValuePairsRepository.GetNameValuePairs(Category);

            if (NameValueList != null)
            {
                foreach (var item in NameValueList)
                {
                    ValueList.Add(item.Value);
                }
            }
            return(ValueList);
        }