public void Load(string clientId, string practiceId, int numberMonths) { ICashFlowManagerService service = new CashFlowManagerService(); Transactions = service.GetTransactions(new Guid(clientId)); BankAccounts = service.GetBankAccounts(new Guid(clientId)); PracticeId = practiceId; ClientId = clientId; TransactionHelper helper = new TransactionHelper(); var results = helper.GenerateData(Transactions, numberMonths); SummaryChartData = helper.SummariseData(results, BankAccounts); }
public void LoadData(Guid clientId) { ICashFlowManagerService service = new CashFlowManagerService(); SelectedTransaction = new TransactionInfo(){StartDate=DateTime.Now}; Transactions = service.GetTransactions(clientId); IncomeTransactions = new List<TransactionInfo>(); ExpenseTransactions = new List<TransactionInfo>(); IncomeTransactions.AddRange((from t in Transactions where t.TransactionTypeId == new Guid(StringEnum.GetStringValue(Enumerations.TransactionType.Income)) select t).ToList()); ExpenseTransactions.AddRange((from t in Transactions where t.TransactionTypeId == new Guid(StringEnum.GetStringValue(Enumerations.TransactionType.Expense)) select t).ToList()); Schedules = service.GetScheduleTypes(); TransactionTypes = service.GetTransactionTypes(); }
public void LoadData(Guid clientId , Guid transactionId) { ICashFlowManagerService service = new CashFlowManagerService(); var trans = service.GetTransactions(clientId,transactionId); Schedules = service.GetScheduleTypes(); TransactionTypes = service.GetTransactionTypes(); if (trans != null && trans.Count > 0) { SelectedTransaction = trans.First(); SelectedSchedule = SelectedTransaction.ScheduleId; SelectedTransactionType = SelectedTransaction.TransactionTypeId; } }
public void LoadData(string practiceId) { ICashFlowManagerService service = new CashFlowManagerService(); PracticeId = new Guid(practiceId); Clients = service.GetClients(PracticeId); Transactions = service.GetTransactions(); BankAccounts = service.GetBankAccounts(); PracticeId = new Guid(practiceId); PopulateClientPosition(); }