diff --git a/app/Http/Controllers/Bank/YodleeController.php b/app/Http/Controllers/Bank/YodleeController.php index fa9d7889dd..d20ccfa195 100644 --- a/app/Http/Controllers/Bank/YodleeController.php +++ b/app/Http/Controllers/Bank/YodleeController.php @@ -14,6 +14,7 @@ namespace App\Http\Controllers\Bank; use App\Helpers\Bank\Yodlee\Yodlee; use App\Http\Controllers\BaseController; use App\Http\Requests\Yodlee\YodleeAuthRequest; +use App\Jobs\Bank\ProcessBankTransactions; use App\Models\BankIntegration; use Illuminate\Http\Request; @@ -102,6 +103,15 @@ class YodleeController extends BaseController } } + + + $company->account->bank_integrations->each(function ($bank_integration) use ($company){ + + ProcessBankTransactions::dispatch($company->account->bank_integration_account_id, $bank_integration); + + }); + + } } diff --git a/app/Jobs/Bank/ProcessBankTransactions.php b/app/Jobs/Bank/ProcessBankTransactions.php index ddbeee233d..7e7c85083e 100644 --- a/app/Jobs/Bank/ProcessBankTransactions.php +++ b/app/Jobs/Bank/ProcessBankTransactions.php @@ -64,7 +64,7 @@ class ProcessBankTransactions implements ShouldQueue set_time_limit(0); //Loop through everything until we are up to date - $this->from_date = $this->from_date ?: '2020-01-01'; + $this->from_date = $this->from_date ?: '2021-01-01'; do{