protected override async Task PrepareReadAsync(AccountingIdentificationState accountingIdentificationState) { NullGuard.NotNull(accountingIdentificationState, nameof(accountingIdentificationState)); _accountingModel ??= await AccountingModelHandler.ForAsync(accountingIdentificationState.AccountingIdentifier); if (_includePostingLines == false || PostingLineModelHandler == null) { return; } _postingLineModelCollection ??= await PostingLineModelHandler.ForAsync(accountingIdentificationState.AccountingIdentifier); }
protected override async Task PrepareReadAsync(AccountingIdentificationState accountingIdentificationState) { NullGuard.NotNull(accountingIdentificationState, nameof(accountingIdentificationState)); if (_includeAccounts) { _accountModelCollection ??= await _accountModelHandler.ForAsync(accountingIdentificationState.AccountingIdentifier); _budgetAccountModelCollection ??= await _budgetAccountModelHandler.ForAsync(accountingIdentificationState.AccountingIdentifier); _contactAccountModelCollection ??= await _contactAccountModelHandler.ForAsync(accountingIdentificationState.AccountingIdentifier); } if (_includePostingLines == false) { return; } _postingLineModelCollection ??= await _postingLineModelHandler.ForAsync(accountingIdentificationState.AccountingIdentifier); }