public BudgetModel LoadBudget(string budgetPath) { var deviceSettings = _settingsProvider.Get <Device>(); Guid deviceId = deviceSettings.DeviceID; if (!File.Exists(budgetPath)) { throw new FileNotFoundException(budgetPath); } IBudgetStore budgetStore = new SQLiteBudgetStore(deviceId, budgetPath); var budgetModel = BudgetModel.Load(deviceId, budgetStore); return(budgetModel); }
public void ReloadBudget() { BudgetModel = BudgetModel.Load(DeviceID, BudgetStore); Budget = BudgetModel.GetBudget(); }