Moved getAccountsByType

This commit is contained in:
James Cole
2016-10-10 07:49:39 +02:00
parent e8a095e543
commit de6f838413
25 changed files with 215 additions and 202 deletions

View File

@@ -15,7 +15,6 @@ namespace FireflyIII\Http\Controllers;
use Carbon\Carbon;
use ExpandedForm;
use FireflyIII\Crud\Account\AccountCrudInterface;
use FireflyIII\Http\Requests\RuleGroupFormRequest;
use FireflyIII\Http\Requests\SelectTransactionsRequest;
use FireflyIII\Jobs\ExecuteRuleGroupOnExistingTransactions;
@@ -179,15 +178,15 @@ class RuleGroupController extends Controller
}
/**
* @param AccountCrudInterface $crud
* @param RuleGroup $ruleGroup
* @param AccountRepositoryInterface $repository
* @param RuleGroup $ruleGroup
*
* @return View
*/
public function selectTransactions(AccountCrudInterface $crud, RuleGroup $ruleGroup)
public function selectTransactions(AccountRepositoryInterface $repository, RuleGroup $ruleGroup)
{
// does the user have shared accounts?
$accounts = $crud->getAccountsByType([AccountType::DEFAULT, AccountType::ASSET]);
$accounts = $repository->getAccountsByType([AccountType::DEFAULT, AccountType::ASSET]);
$accountList = ExpandedForm::makeSelectList($accounts);
$checkedAccounts = array_keys($accountList);
$first = session('first')->format('Y-m-d');