protected override void RetrieveData() { System.Collections.Generic.List <ModuleEntity> entities = DMFactory.GetModuleEntities(); System.Collections.Generic.List <DEListDetail> data = new System.Collections.Generic.List <DEListDetail>(); DEListDetail listDetail = default(DEListDetail); foreach (ModuleEntity entity in entities) { listDetail = new DEListDetail(new string[] { entity.Title }, new string[] { }); if (entity.Type == ModuleType.List) { listDetail.SelectURL = string.Format(DefaultListURL, entity.Name, "{1}"); } else { listDetail.SelectURL = string.Format(SystemDefaultURL, entity.Name, "{1}"); } data.Add(listDetail); } DEList.Data = data; DEList.BusinessUnits = Utilities.GetBusinessUnits(settings); }
protected List <DEListDetail> GetDEEntities(System.Collections.Generic.List <DataColumn> dataColumns, System.Collections.Generic.List <KeyColumn> defaultKeyColumns, DataTable dataTable) { System.Collections.Generic.List <DEListDetail> result = new System.Collections.Generic.List <DEListDetail>(); foreach (DataRow dr in dataTable.Rows) { System.Collections.Generic.List <string> values = new System.Collections.Generic.List <string>(); foreach (DataColumn column in dataColumns) { string value = dr[column.Name].ToString(); values.Add(value); } System.Collections.Generic.List <string> VariableKeyValues = new System.Collections.Generic.List <string>(); foreach (KeyColumn keyColumn in defaultKeyColumns) { string value = dr[keyColumn.Name].ToString(); VariableKeyValues.Add(value); } DEListDetail entity = new DEListDetail(values.ToArray(), VariableKeyValues.ToArray()); entity.SelectURL = GetSelectURL(entity); result.Add(entity); } Format(ref result); return(result); }
protected override string GetSelectURL(DEListDetail listDetail) { return(string.Format("/DatabaseUpdates.aspx?moduleName={0}&businessUnit={1}&variablekey1={2}", DEList.ModuleName, settings.BusinessUnit, listDetail.VariableKeys[0].Replace("\"", string.Empty))); }
protected virtual string GetSelectURL(DEListDetail listDetail) { return(string.Empty); }