Example #1
0
        static void Main(string[] args)
        {
            var config = Factory.GetConnectionString();

            ISqlDataAccess        dataAccess           = Factory.CreateSqlDataAccess(config);
            IConnectionStringData connectionStringName = Factory.CreateConnectionStringName();
            ISqlCrud sqlCrud = Factory.CreateSqlCrud(dataAccess, connectionStringName);

            try
            {
                //ReadAllContacts(sqlCrud);
                //ReadAllGiftsEntered(sqlCrud);
                //ReadAllBudgetActuals(sqlCrud);
                CreateNewGiftEntry(sqlCrud);
                //InsertNewContact(sqlCrud);
                //UpdateBudgetAmount(sqlCrud);
                //RemoveGiftFromContact(sqlCrud);
            }
            catch (Exception ex)
            {
                Console.WriteLine("We had an error");
                Console.WriteLine(ex.Message);
            }

            Console.ReadLine();
        }
        private static async Task ReseedAsync(string tableName, int NEWSEEDNUMBER, IConnectionStringData connectionString,
                                              IDataGateway dataGateway)
        {
            var storedProcedure = "dbo.Testing_Reseed";

            await dataGateway.Execute(storedProcedure, new
            {
                @TableName     = tableName,
                @NEWSEEDNUMBER = NEWSEEDNUMBER
            },
                                      connectionString.SqlConnectionString);
        }
 public LoginTrackerRepo(IDataGateway dataGateway, IConnectionStringData connectionString)
 {
     _dataGateway      = dataGateway;
     _connectionString = connectionString;
 }
 public LoginAttemptsRepository(IDataGateway dataGateway, IConnectionStringData connectionString)
 {
     _dataGateway      = dataGateway;
     _connectionString = connectionString;
 }
Example #5
0
 public SqlCrud(ISqlDataAccess dataAccess, IConnectionStringData connectionString)
 {
     _dataAccess       = dataAccess;
     _connectionString = connectionString;
 }
 public MessagesRepo(IDataGateway dataGateway, IConnectionStringData connectionString)
 {
     _dataGateway      = dataGateway;
     _connectionString = connectionString;
 }
 public UserScopeClaimRepository(IDataGateway dataGateway, IConnectionStringData connectionString)
 {
     _dataGateway      = dataGateway;
     _connectionString = connectionString;
 }
Example #8
0
 public FriendBlockListRepo(IDataGateway dataGateway, IConnectionStringData connectionString)
 {
     _dataGateway      = dataGateway;
     _connectionString = connectionString;
 }
Example #9
0
 public AccessPolicyPairingRepository(IDataGateway dataGateway, IConnectionStringData connectionString)
 {
     _dataGateway      = dataGateway;
     _connectionString = connectionString;
 }
Example #10
0
 public TraditionalListingSearchRepository(IDataGateway dataGateway, IConnectionStringData connectionString)
 {
     _dataGateway      = dataGateway;
     _connectionString = connectionString;
 }
Example #11
0
 public AssignmentPolicyRepository(IDataGateway dataGateway, IConnectionStringData connectionString)
 {
     _dataGateway      = dataGateway;
     _connectionString = connectionString;
 }
 public UserReportsRepo(IDataGateway dataGateway, IConnectionStringData connectionString)
 {
     _dataGateway      = dataGateway;
     _connectionString = connectionString;
 }
 public PublicUserProfileRepo(IDataGateway dataGateway, IConnectionStringData connectionString)
 {
     _dataGateway      = dataGateway;
     _connectionString = connectionString;
 }
 public ChannelsRepo(IDataGateway dataGateway, IConnectionStringData connectionString)
 {
     _dataGateway      = dataGateway;
     _connectionString = connectionString;
 }
Example #15
0
 public static ISqlCrud CreateSqlCrud(ISqlDataAccess dataAccess, IConnectionStringData connectionStringName)
 {
     return(new SqlCrud(dataAccess, connectionStringName));
 }
 public DatingRepository(IDataGateway dataGateway, IConnectionStringData connectionString)
 {
     _dataGateway      = dataGateway;
     _connectionString = connectionString;
 }
 public UserAccountRepository(IDataGateway dataGateway, IConnectionStringData connectionString)
 {
     _dataGateway      = dataGateway;
     _connectionString = connectionString;
 }
Example #18
0
 public AccountVerificationRepo(IDataGateway dataGateway, IConnectionStringData connectionString)
 {
     _dataGateway      = dataGateway;
     _connectionString = connectionString;
 }
 public PageVisitTrackerRepo(IDataGateway dataGateway, IConnectionStringData connectionString)
 {
     _dataGateway      = dataGateway;
     _connectionString = connectionString;
 }