public List<Templates> GetTemplates(string strTheme)
 {
     try
     {
         DataSet dsTemplates = GetDataSet("usp_GetThemes", new string[] { strTheme });
         List<Templates> lstTemplates = new List<Templates>();
         if (dsTemplates.Tables[0].Rows.Count > 0)
         {
             foreach (DataRow dr in dsTemplates.Tables[0].Rows)
             {
                 Templates objTemplates = new Templates();
                 objTemplates.TemplateID = int.Parse(dr["ThemeId"].ToString());
                 objTemplates.TemplateName = dr["ThemeName"].ToString();
                 objTemplates.TemplatePath = dr["ThemePath"].ToString();
                 objTemplates.ThemeCssClass = dr["ThemeClassId"].ToString();
                 objTemplates.ThemeValue = dr["ThemeValue"].ToString();
                 lstTemplates.Add(objTemplates);
                 objTemplates = null;
             }
         }
         return lstTemplates;
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
        /// <summary>
        /// 
        /// </summary>
        /// <param name="objTheme"></param>
        /// <returns></returns>
        public Templates GetExistingFolderName(object[] objTheme)
        {
            try
            {
                Templates objTributeTheme = new Templates();
                object[] objParam = { ((Tributes)objTheme[0]).TributeId };

                DataSet dsTheme = GetDataSet("usp_GetTributeThemeFoldername", objParam);

                if (dsTheme.Tables[0].Rows.Count > 0)
                {
                    objTributeTheme.TemplateID = int.Parse(dsTheme.Tables[0].Rows[0]["ThemeId"].ToString());
                    objTributeTheme.TemplateName = dsTheme.Tables[0].Rows[0]["ThemeName"].ToString();
                    objTributeTheme.ThemeValue = dsTheme.Tables[0].Rows[0]["ThemeValue"].ToString();
                    objTributeTheme.FolderName = dsTheme.Tables[0].Rows[0]["FolderName"].ToString();
                }
                return objTributeTheme;
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
 /// <summary>
 /// Method to get the list of Themes based on Tribute Type
 /// </summary>
 /// <param name="objTributeType">Type of tribute in Template entity</param>
 /// <returns>List of Themes</returns>
 public List<Templates> GetThemesList(Templates objTributeType)
 {
     return FacadeManager.TributeThemeManager.GetThemes(objTributeType);
 }
 /// <summary>
 /// 
 /// </summary>
 /// <param name="objTributeType"></param>
 /// <returns></returns>
 public List<Templates> GetThemesFolderList(Templates objTributeType,string applicationType)
 {
     return FacadeManager.TributeThemeManager.GetThemesFolder(objTributeType, applicationType);
 }
 public List<Templates> GetThemesFolder(Templates objTributeType, string applicationType)
 {
     TemplateResource objTheme = new TemplateResource();
     return objTheme.GetThemesTemplates(objTributeType.TributeType, applicationType);
 }
 /// <summary>
 /// Method to get the list of themes for a tribute
 /// </summary>
 /// <param name="objTributeType">Type of Tribute</param>
 public List<Templates> GetThemes(Templates objTributeType)
 {
     TemplateResource objTheme = new TemplateResource();
     return objTheme.GetTemplates(objTributeType.TributeType);
 }