Exemple #1
0
 public void SetNodes()
 {
     temp_drepos = repositoryProvider.GetRepositorys(1);
     foreach (var item in temp_drepos)
     {
         TreeNode treenode = ConvertDRepository(item);
         this.treeView1.Nodes.Add(treenode);
     }
 }
        public OrganisedRepositoryResults GetRepositorys(int IDAccount)
        {
            //string sql = "SELECT * FROM campaigns where  IDAccount = @IDAccount";
            Dictionary <string, object> ins = new Dictionary <string, object>();

            if (IDAccount != 0)
            {
                ins.Add("IDAccount", IDAccount);
            }
            string sql = "SELECT * FROM organizedrepository WHERE IDAccount=@IDAccount";

            System.Data.DataTable      ret     = this.Connector.Query(sql, ins);
            OrganisedRepositoryResults results = new OrganisedRepositoryResults();

            results.LoadFromDataTable(ret);
            //return NGLib.DATA.DATAPO.DataPOParser.ListFromDataTable<Campaign>(ret);
            return(results);
        }