From b7a577cc4c2a0ff5b1b18bbd422d38d6c78b4e5d Mon Sep 17 00:00:00 2001 From: Joris Date: Sun, 3 Feb 2019 14:44:32 +0100 Subject: [PATCH 01/33] Fix delete-account confirmation --- resources/views/v1/profile/delete-account.twig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/views/v1/profile/delete-account.twig b/resources/views/v1/profile/delete-account.twig index 5d48147444..0b937630d3 100644 --- a/resources/views/v1/profile/delete-account.twig +++ b/resources/views/v1/profile/delete-account.twig @@ -43,7 +43,7 @@ From 25b2b43a38e2202c76d4efe64013f94e2e58182f Mon Sep 17 00:00:00 2001 From: James Cole Date: Sun, 3 Feb 2019 18:25:58 +0100 Subject: [PATCH 02/33] Fix for #2049 --- app/Support/Preferences.php | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/app/Support/Preferences.php b/app/Support/Preferences.php index f86340ded9..09106f4c9a 100644 --- a/app/Support/Preferences.php +++ b/app/Support/Preferences.php @@ -216,8 +216,22 @@ class Preferences { $fullName = sprintf('preference%s%s', $user->id, $name); Cache::forget($fullName); + /** @var Preference $pref */ $pref = Preference::where('user_id', $user->id)->where('name', $name)->first(['id', 'name', 'data', 'updated_at', 'created_at']); + if (null !== $pref && null === $value) { + try { + $pref->delete(); + } catch (Exception $e) { + Log::error(sprintf('Could not delete preference: %s', $e->getMessage())); + } + + return new Preference; + } + if (null === $value) { + return new Preference; + } + if (null !== $pref) { $pref->data = $value; $pref->save(); From 73c8c6de37e5cb503ffe39f3ef95ef56a4eaea98 Mon Sep 17 00:00:00 2001 From: James Cole Date: Sun, 3 Feb 2019 20:19:59 +0100 Subject: [PATCH 03/33] Disable manifest push [skip ci] --- .deploy/docker/manifest.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.deploy/docker/manifest.sh b/.deploy/docker/manifest.sh index 7dc254cc47..7e7d9b0abb 100755 --- a/.deploy/docker/manifest.sh +++ b/.deploy/docker/manifest.sh @@ -1,4 +1,8 @@ #!/usr/bin/env bash + +# Disabled until I can figure out how this works in Travis. +exit 0 + if [ "$TRAVIS_BRANCH" == "develop" ]; then TARGET=jc5x/firefly-iii:develop ARM=jc5x/firefly-iii:develop-arm From def95df49ec59502ca59f6946c8ba7e5054f5697 Mon Sep 17 00:00:00 2001 From: James Cole Date: Sun, 3 Feb 2019 20:20:24 +0100 Subject: [PATCH 04/33] Fix link in changelog [skip ci] --- changelog.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/changelog.md b/changelog.md index 26960597e4..a7dbd6c452 100644 --- a/changelog.md +++ b/changelog.md @@ -18,7 +18,7 @@ This project adheres to [Semantic Versioning](http://semver.org/). - I will no longer accept PR's that introduce new currencies. ### Removed -- Firefly III no longer encrypts the database and will [decrypt the database]() on its first run. +- Firefly III no longer encrypts the database and will [decrypt the database](https://github.com/firefly-iii/help/wiki/Database-encryption) on its first run. ### Fixed - [Issue 1923](https://github.com/firefly-iii/firefly-iii/issues/1923) Broken window position for date picker. From 0e1da3f797b7dac54b3a55e1491dc814352a7635 Mon Sep 17 00:00:00 2001 From: James Cole Date: Mon, 4 Feb 2019 20:35:46 +0100 Subject: [PATCH 05/33] Fix webbased upgrade routine. --- .../Controllers/System/InstallController.php | 28 +++++++++++++++++++ public/v1/js/ff/install/index.js | 16 +++++++++++ resources/views/v1/install/index.twig | 1 + routes/web.php | 1 + 4 files changed, 46 insertions(+) diff --git a/app/Http/Controllers/System/InstallController.php b/app/Http/Controllers/System/InstallController.php index 711f091db4..c4c779c1db 100644 --- a/app/Http/Controllers/System/InstallController.php +++ b/app/Http/Controllers/System/InstallController.php @@ -153,6 +153,34 @@ class InstallController extends Controller return response()->json(['error' => false, 'message' => 'OK']); } + /** + * Do database decrypt. + * + * @return \Illuminate\Http\JsonResponse + */ + public function decrypt(): JsonResponse + { + if ($this->hasForbiddenFunctions()) { + return response()->json(['error' => true, 'message' => self::FORBIDDEN_ERROR]); + } + try { + Log::debug('Am now calling decrypt database routine...'); + Artisan::call('firefly:decrypt-all'); + Log::debug(Artisan::output()); + } catch (Exception $e) { + Log::error($e->getMessage()); + Log::error($e->getTraceAsString()); + if (strpos($e->getMessage(), 'open_basedir restriction in effect')) { + return response()->json(['error' => true, 'message' => self::BASEDIR_ERROR]); + } + + return response()->json(['error' => true, 'message' => self::OTHER_ERROR . ' ' . $e->getMessage()]); + } + + return response()->json(['error' => false, 'message' => 'OK']); + } + + /** * Do database verification. * diff --git a/public/v1/js/ff/install/index.js b/public/v1/js/ff/install/index.js index 66b4a50429..6c1fe2e4a1 100644 --- a/public/v1/js/ff/install/index.js +++ b/public/v1/js/ff/install/index.js @@ -30,6 +30,22 @@ function startMigration() { $('#status-box').html(' Setting up DB...'); $.post(migrateUri, {_token: token}).done(function (data) { if(data.error === false) { + // move to decrypt routine. + startDecryption(); + } else { + displaySoftFail(data.message); + } + + }).fail(function () { + $('#status-box').html(' Migration failed! See log files :('); + }); +} + +function startDecryption() { + $('#status-box').html(' Setting up DB #2...'); + $.post(decryptUri, {_token: token}).done(function (data) { + if(data.error === false) { + // move to decrypt routine. startPassport(); } else { displaySoftFail(data.message); diff --git a/resources/views/v1/install/index.twig b/resources/views/v1/install/index.twig index 6a3c3118f0..36d9fd56c2 100644 --- a/resources/views/v1/install/index.twig +++ b/resources/views/v1/install/index.twig @@ -19,6 +19,7 @@ var keysUri = '{{ route('installer.keys') }}'; var upgradeUri = '{{ route('installer.upgrade') }}'; var verifyUri = '{{ route('installer.verify') }}'; + var decryptUri = '{{ route('installer.decrypt') }}'; var homeUri = '{{ route('home') }}'; diff --git a/routes/web.php b/routes/web.php index 10be4ae45c..86cedba3f8 100644 --- a/routes/web.php +++ b/routes/web.php @@ -30,6 +30,7 @@ Route::group( Route::post('keys', ['uses' => 'InstallController@keys', 'as' => 'keys']); Route::post('upgrade', ['uses' => 'InstallController@upgrade', 'as' => 'upgrade']); Route::post('verify', ['uses' => 'InstallController@verify', 'as' => 'verify']); + Route::post('decrypt', ['uses' => 'InstallController@decrypt', 'as' => 'decrypt']); } ); From d3d4439b03235926241d5b46eaf801d87a194600 Mon Sep 17 00:00:00 2001 From: Simon Taddiken Date: Tue, 5 Feb 2019 15:02:36 +0100 Subject: [PATCH 06/33] Remove console.log statement --- public/v1/js/ff/charts.js | 1 - 1 file changed, 1 deletion(-) diff --git a/public/v1/js/ff/charts.js b/public/v1/js/ff/charts.js index ba98bb07f4..7013842bbe 100644 --- a/public/v1/js/ff/charts.js +++ b/public/v1/js/ff/charts.js @@ -346,7 +346,6 @@ function drawAChart(URI, container, chartType, options, colorData) { if (typeof drawVerticalLine !== 'undefined') { if (drawVerticalLine !== '') { // draw line using annotation plugin. - console.log('Will draw line'); chartOpts.options.annotation = { annotations: [{ type: 'line', From f1e83f240e9bf66f7a13f0a842c62ee9ba924473 Mon Sep 17 00:00:00 2001 From: James Cole Date: Fri, 8 Feb 2019 03:21:34 +0100 Subject: [PATCH 07/33] Build with a new distribution. --- .travis.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.travis.yml b/.travis.yml index ae31eb4043..5ebaaaf8ab 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,5 +1,6 @@ sudo: required language: bash +dist: xenial # safelist branches: only: From d63c9c9aeae1746f7c02c1d0db451c949ab835d0 Mon Sep 17 00:00:00 2001 From: James Cole Date: Fri, 8 Feb 2019 07:13:59 +0100 Subject: [PATCH 08/33] Add audit logging. --- .../Controllers/Account/CreateController.php | 4 +-- app/Http/Controllers/CurrencyController.php | 34 +++++++++++++++---- app/Http/Controllers/HomeController.php | 3 ++ app/Support/Logging/AuditLogger.php | 23 +++++++++++++ app/Support/Logging/AuditProcessor.php | 28 +++++++++++++++ config/logging.php | 10 +++++- 6 files changed, 93 insertions(+), 9 deletions(-) create mode 100644 app/Support/Logging/AuditLogger.php create mode 100644 app/Support/Logging/AuditProcessor.php diff --git a/app/Http/Controllers/Account/CreateController.php b/app/Http/Controllers/Account/CreateController.php index 02c32fb94b..50bf7ac4ac 100644 --- a/app/Http/Controllers/Account/CreateController.php +++ b/app/Http/Controllers/Account/CreateController.php @@ -111,7 +111,7 @@ class CreateController extends Controller $this->rememberPreviousUri('accounts.create.uri'); } $request->session()->forget('accounts.create.fromStore'); - + Log::channel('audit')->info('Create new account.'); return view('accounts.create', compact('subTitleIcon', 'what', 'interestPeriods', 'subTitle', 'roles', 'liabilityTypes')); } @@ -131,7 +131,7 @@ class CreateController extends Controller $request->session()->flash('success', (string)trans('firefly.stored_new_account', ['name' => $account->name])); app('preferences')->mark(); - + Log::channel('audit')->info('Store new account.', $data); // update preferences if necessary: $frontPage = app('preferences')->get('frontPageAccounts', [])->data; diff --git a/app/Http/Controllers/CurrencyController.php b/app/Http/Controllers/CurrencyController.php index 4c72b09e3e..dda6f02d1f 100644 --- a/app/Http/Controllers/CurrencyController.php +++ b/app/Http/Controllers/CurrencyController.php @@ -91,6 +91,8 @@ class CurrencyController extends Controller } $request->session()->forget('currencies.create.fromStore'); + Log::channel('audit')->info('Create new currency.'); + return view('currencies.create', compact('subTitleIcon', 'subTitle')); } @@ -107,6 +109,8 @@ class CurrencyController extends Controller app('preferences')->set('currencyPreference', $currency->code); app('preferences')->mark(); + Log::channel('audit')->info(sprintf('Make %s the default currency.', $currency->code)); + $this->repository->enable($currency); $request->session()->flash('success', (string)trans('firefly.new_default_currency', ['name' => $currency->name])); @@ -128,6 +132,7 @@ class CurrencyController extends Controller if (!$this->userRepository->hasRole($user, 'owner')) { // @codeCoverageIgnoreStart $request->session()->flash('error', (string)trans('firefly.ask_site_owner', ['owner' => config('firefly.site_owner')])); + Log::channel('audit')->info(sprintf('Tried to visit page to delete currency %s but is not site owner.', $currency->code)); return redirect(route('currencies.index')); // @codeCoverageIgnoreEnd @@ -135,6 +140,7 @@ class CurrencyController extends Controller if ($this->repository->currencyInUse($currency)) { $request->session()->flash('error', (string)trans('firefly.cannot_delete_currency', ['name' => $currency->name])); + Log::channel('audit')->info(sprintf('Tried to visit page to delete currency %s but currency is in use.', $currency->code)); return redirect(route('currencies.index')); } @@ -142,6 +148,7 @@ class CurrencyController extends Controller // put previous url in session $this->rememberPreviousUri('currencies.delete.uri'); $subTitle = (string)trans('form.delete_currency', ['name' => $currency->name]); + Log::channel('audit')->info(sprintf('Visit page to delete currency %s.', $currency->code)); return view('currencies.delete', compact('currency', 'subTitle')); } @@ -161,6 +168,7 @@ class CurrencyController extends Controller if (!$this->userRepository->hasRole($user, 'owner')) { // @codeCoverageIgnoreStart $request->session()->flash('error', (string)trans('firefly.ask_site_owner', ['owner' => config('firefly.site_owner')])); + Log::channel('audit')->info(sprintf('Tried to delete currency %s but is not site owner.', $currency->code)); return redirect(route('currencies.index')); // @codeCoverageIgnoreEnd @@ -168,11 +176,13 @@ class CurrencyController extends Controller if ($this->repository->currencyInUse($currency)) { $request->session()->flash('error', (string)trans('firefly.cannot_delete_currency', ['name' => $currency->name])); + Log::channel('audit')->info(sprintf('Tried to delete currency %s but is in use.', $currency->code)); return redirect(route('currencies.index')); } - + Log::channel('audit')->info(sprintf('Deleted currency %s.', $currency->code)); $this->repository->destroy($currency); + $request->session()->flash('success', (string)trans('firefly.deleted_currency', ['name' => $currency->name])); return redirect($this->getPreviousUri('currencies.delete.uri')); @@ -193,6 +203,7 @@ class CurrencyController extends Controller if (!$this->userRepository->hasRole($user, 'owner')) { // @codeCoverageIgnoreStart $request->session()->flash('error', (string)trans('firefly.ask_site_owner', ['owner' => config('firefly.site_owner')])); + Log::channel('audit')->info(sprintf('Tried to disable currency %s but is not site owner.', $currency->code)); return redirect(route('currencies.index')); // @codeCoverageIgnoreEnd @@ -200,20 +211,23 @@ class CurrencyController extends Controller if ($this->repository->currencyInUse($currency)) { $request->session()->flash('error', (string)trans('firefly.cannot_disable_currency', ['name' => $currency->name])); + Log::channel('audit')->info(sprintf('Tried to disable currency %s but is in use.', $currency->code)); return redirect(route('currencies.index')); } $this->repository->disable($currency); - + Log::channel('audit')->info(sprintf('Disabled currency %s.', $currency->code)); // if no currencies are enabled, enable the first one in the DB (usually the EUR) if (0 === $this->repository->get()->count()) { + /** @var TransactionCurrency $first */ $first = $this->repository->getAll()->first(); if (null === $first) { throw new FireflyException('No currencies found.'); } + Log::channel('audit')->info(sprintf('Auto-enabled currency %s.', $first->code)); $this->repository->enable($first); - app('preferences')->set('currencyPreference', $currency->code); + app('preferences')->set('currencyPreference', $first->code); app('preferences')->mark(); } @@ -237,6 +251,7 @@ class CurrencyController extends Controller if (!$this->userRepository->hasRole($user, 'owner')) { // @codeCoverageIgnoreStart $request->session()->flash('error', (string)trans('firefly.ask_site_owner', ['owner' => config('firefly.site_owner')])); + Log::channel('audit')->info(sprintf('Tried to edit currency %s but is not owner.', $currency->code)); return redirect(route('currencies.index')); // @codeCoverageIgnoreEnd @@ -275,6 +290,7 @@ class CurrencyController extends Controller $this->repository->enable($currency); session()->flash('success', (string)trans('firefly.currency_is_now_enabled', ['name' => $currency->name])); + Log::channel('audit')->info(sprintf('Enabled currency %s.', $currency->code)); return redirect(route('currencies.index')); } @@ -329,21 +345,23 @@ class CurrencyController extends Controller { /** @var User $user */ $user = auth()->user(); + $data = $request->getCurrencyData(); if (!$this->userRepository->hasRole($user, 'owner')) { // @codeCoverageIgnoreStart Log::error('User ' . auth()->user()->id . ' is not admin, but tried to store a currency.'); + Log::channel('audit')->info('Tried to create (POST) currency without admin rights.', $data); return redirect($this->getPreviousUri('currencies.create.uri')); // @codeCoverageIgnoreEnd } - $data = $request->getCurrencyData(); $data['enabled'] = true; $currency = $this->repository->store($data); $redirect = redirect($this->getPreviousUri('currencies.create.uri')); + if (null !== $currency) { $request->session()->flash('success', (string)trans('firefly.created_currency', ['name' => $currency->name])); - + Log::channel('audit')->info('Created (POST) currency.', $data); if (1 === (int)$request->get('create_another')) { // @codeCoverageIgnoreStart $request->session()->put('currencies.create.fromStore', true); @@ -353,6 +371,7 @@ class CurrencyController extends Controller } } if (null === $currency) { + Log::channel('audit')->info('Could not store (POST) currency without admin rights.', $data); $request->session()->flash('error', (string)trans('firefly.could_not_store_currency')); } @@ -372,16 +391,19 @@ class CurrencyController extends Controller { /** @var User $user */ $user = auth()->user(); + $data = $request->getCurrencyData(); if (!$this->userRepository->hasRole($user, 'owner')) { // @codeCoverageIgnoreStart $request->session()->flash('error', (string)trans('firefly.ask_site_owner', ['owner' => config('firefly.site_owner')])); + Log::channel('audit')->info('Tried to update (POST) currency without admin rights.', $data); return redirect(route('currencies.index')); // @codeCoverageIgnoreEnd } - $data = $request->getCurrencyData(); + $currency = $this->repository->update($currency, $data); + Log::channel('audit')->info('Updated (POST) currency.', $data); $request->session()->flash('success', (string)trans('firefly.updated_currency', ['name' => $currency->name])); app('preferences')->mark(); diff --git a/app/Http/Controllers/HomeController.php b/app/Http/Controllers/HomeController.php index 804deca82b..703e53aa53 100644 --- a/app/Http/Controllers/HomeController.php +++ b/app/Http/Controllers/HomeController.php @@ -67,6 +67,7 @@ class HomeController extends Controller Log::debug('Received dateRange', ['start' => $request->get('start'), 'end' => $request->get('end'), 'label' => $request->get('label')]); + // check if the label is "everything" or "Custom range" which will betray // a possible problem with the budgets. if ($label === (string)trans('firefly.everything') || $label === (string)trans('firefly.customRange')) { @@ -103,6 +104,8 @@ class HomeController extends Controller $types = config('firefly.accountTypesByIdentifier.asset'); $count = $repository->count($types); + Log::channel('audit')->info('User visits homepage.'); + if (0 === $count) { return redirect(route('new-user.index')); } diff --git a/app/Support/Logging/AuditLogger.php b/app/Support/Logging/AuditLogger.php new file mode 100644 index 0000000000..3c98651b85 --- /dev/null +++ b/app/Support/Logging/AuditLogger.php @@ -0,0 +1,23 @@ +pushProcessor($processor); + } +} \ No newline at end of file diff --git a/app/Support/Logging/AuditProcessor.php b/app/Support/Logging/AuditProcessor.php new file mode 100644 index 0000000000..84fb2c4b86 --- /dev/null +++ b/app/Support/Logging/AuditProcessor.php @@ -0,0 +1,28 @@ +method() . ':' . request()->url(); + + $record['extra']['IP'] = app('request')->ip(); + if (auth()->check()) { + $record['extra']['user'] = auth()->user()->email; + } + + + return $record; + } +} \ No newline at end of file diff --git a/config/logging.php b/config/logging.php index 1ac3fb0284..f031506d13 100644 --- a/config/logging.php +++ b/config/logging.php @@ -19,7 +19,9 @@ * along with Firefly III. If not, see . */ + declare(strict_types=1); +use FireflyIII\Support\Logging\AuditLogger; return [ @@ -66,13 +68,19 @@ return [ 'path' => 'php://stdout', 'level' => envNonEmpty('APP_LOG_LEVEL', 'info'), ], - 'daily' => [ 'driver' => 'daily', 'path' => storage_path('logs/ff3-' . PHP_SAPI . '.log'), 'level' => envNonEmpty('APP_LOG_LEVEL', 'info'), 'days' => 7, ], + 'audit' => [ + 'driver' => 'daily', + 'path' => storage_path('logs/ff3-audit.log'), + 'tap' => [AuditLogger::class], + 'level' => envNonEmpty('APP_LOG_LEVEL', 'info'), + 'days' => 90, + ], 'dailytest' => [ 'driver' => 'daily', 'path' => storage_path('logs/test-ff3-' . PHP_SAPI . '.log'), From 311d51464d2a1b09f7933e00103bea7ba0a32163 Mon Sep 17 00:00:00 2001 From: James Cole Date: Fri, 8 Feb 2019 07:14:45 +0100 Subject: [PATCH 09/33] Add support for #2006 --- app/Api/V1/Controllers/Controller.php | 2 +- app/Api/V1/Requests/TransactionRequest.php | 5 +- app/Factory/TransactionJournalFactory.php | 11 +++- app/Http/Requests/Request.php | 40 ++++++++++++ app/Models/TransactionJournal.php | 2 +- app/Rules/IsDateOrTime.php | 61 +++++++++++++++++++ app/Transformers/TransactionTransformer.php | 2 +- .../2019_01_28_193833_changes_for_v4710.php | 4 +- .../2019_02_05_055516_changes_for_v4711.php | 37 +++++++++++ resources/lang/en_US/validation.php | 1 + 10 files changed, 155 insertions(+), 10 deletions(-) create mode 100644 app/Rules/IsDateOrTime.php create mode 100644 database/migrations/2019_02_05_055516_changes_for_v4711.php diff --git a/app/Api/V1/Controllers/Controller.php b/app/Api/V1/Controllers/Controller.php index 8e9a8153e6..aa15ba0d17 100644 --- a/app/Api/V1/Controllers/Controller.php +++ b/app/Api/V1/Controllers/Controller.php @@ -104,7 +104,7 @@ class Controller extends BaseController $obj = null; if (null !== $date) { try { - $obj = new Carbon($date); + $obj = Carbon::parse($date); } catch (InvalidDateException $e) { // don't care Log::error(sprintf('Invalid date exception in API controller: %s', $e->getMessage())); diff --git a/app/Api/V1/Requests/TransactionRequest.php b/app/Api/V1/Requests/TransactionRequest.php index 9c6820dad7..a9b024cc37 100644 --- a/app/Api/V1/Requests/TransactionRequest.php +++ b/app/Api/V1/Requests/TransactionRequest.php @@ -26,6 +26,7 @@ namespace FireflyIII\Api\V1\Requests; use FireflyIII\Rules\BelongsUser; use FireflyIII\Rules\IsBoolean; +use FireflyIII\Rules\IsDateOrTime; use FireflyIII\Validation\TransactionValidation; use Illuminate\Validation\Validator; @@ -59,7 +60,7 @@ class TransactionRequest extends Request { $data = [ 'type' => $this->string('type'), - 'date' => $this->date('date'), + 'date' => $this->dateTime('date'), 'description' => $this->string('description'), 'piggy_bank_id' => $this->integer('piggy_bank_id'), 'piggy_bank_name' => $this->string('piggy_bank_name'), @@ -103,7 +104,7 @@ class TransactionRequest extends Request // basic fields for journal: 'type' => 'required|in:withdrawal,deposit,transfer,opening-balance,reconciliation', 'description' => 'between:1,255', - 'date' => 'required|date', + 'date' => ['required', new IsDateOrTime], 'piggy_bank_id' => ['numeric', 'nullable', 'mustExist:piggy_banks,id', new BelongsUser], 'piggy_bank_name' => ['between:1,255', 'nullable', new BelongsUser], 'bill_id' => ['numeric', 'nullable', 'mustExist:bills,id', new BelongsUser], diff --git a/app/Factory/TransactionJournalFactory.php b/app/Factory/TransactionJournalFactory.php index 6c022a0271..9dc5c3c654 100644 --- a/app/Factory/TransactionJournalFactory.php +++ b/app/Factory/TransactionJournalFactory.php @@ -24,6 +24,7 @@ declare(strict_types=1); namespace FireflyIII\Factory; +use Carbon\Carbon; use FireflyIII\Exceptions\FireflyException; use FireflyIII\Models\TransactionJournal; use FireflyIII\Services\Internal\Support\JournalServiceTrait; @@ -70,14 +71,18 @@ class TransactionJournalFactory Log::debug(sprintf('Going to store a %s', $type->type)); $description = app('steam')->cleanString($data['description']); $description = str_replace(["\n", "\t", "\r"], "\x20", $description); - $journal = TransactionJournal::create( + /** @var Carbon $carbon */ + $carbon = $data['date']; + $carbon->setTimezone(config('app.timezone')); + + $journal = TransactionJournal::create( [ 'user_id' => $data['user'], 'transaction_type_id' => $type->id, 'bill_id' => null, 'transaction_currency_id' => $defaultCurrency->id, 'description' => $description, - 'date' => $data['date']->format('Y-m-d'), + 'date' => $carbon->format('Y-m-d H:i:s'), 'order' => 0, 'tag_count' => 0, 'completed' => 0, @@ -92,7 +97,7 @@ class TransactionJournalFactory /** @var TransactionFactory $factory */ $factory = app(TransactionFactory::class); $factory->setUser($this->user); - $totalAmount= '0'; + $totalAmount = '0'; Log::debug(sprintf('Found %d transactions in array.', \count($data['transactions']))); /** @var array $trData */ foreach ($data['transactions'] as $index => $trData) { diff --git a/app/Http/Requests/Request.php b/app/Http/Requests/Request.php index 6bd87f2af6..be04cca2ba 100644 --- a/app/Http/Requests/Request.php +++ b/app/Http/Requests/Request.php @@ -23,7 +23,9 @@ declare(strict_types=1); namespace FireflyIII\Http\Requests; use Carbon\Carbon; +use Carbon\Exceptions\InvalidDateException; use Illuminate\Foundation\Http\FormRequest; +use Log; /** * Class Request. @@ -130,4 +132,42 @@ class Request extends FormRequest { return $this->get($field) ? new Carbon($this->get($field)) : null; } + + /** + * Return date time or NULL. + * + * @param string $field + * + * @return Carbon|null + */ + protected function dateTime(string $field): ?Carbon + { + if (null === $this->get($field)) { + return null; + } + $value = (string)$this->get($field); + if (10 === \strlen($value)) { + // probably a date format. + try { + $result = Carbon::createFromFormat('Y-m-d', $value); + } catch (InvalidDateException $e) { + Log::error(sprintf('"%s" is not a valid date: %s', $value, $e->getMessage())); + + return null; + } + + return $result; + } + // is an atom string, I hope? + try { + $result = Carbon::parse($value); + } catch (InvalidDateException $e) { + Log::error(sprintf('"%s" is not a valid date or time: %s', $value, $e->getMessage())); + + return null; + } + + return $result; + } + } diff --git a/app/Models/TransactionJournal.php b/app/Models/TransactionJournal.php index 1cba19f5ed..458b4c7c13 100644 --- a/app/Models/TransactionJournal.php +++ b/app/Models/TransactionJournal.php @@ -84,7 +84,7 @@ class TransactionJournal extends Model 'created_at' => 'datetime', 'updated_at' => 'datetime', 'deleted_at' => 'datetime', - 'date' => 'date', + 'date' => 'datetime', 'interest_date' => 'date', 'book_date' => 'date', 'process_date' => 'date', diff --git a/app/Rules/IsDateOrTime.php b/app/Rules/IsDateOrTime.php new file mode 100644 index 0000000000..52c40b6ead --- /dev/null +++ b/app/Rules/IsDateOrTime.php @@ -0,0 +1,61 @@ +getMessage())); + + return false; + } + + return true; + } + // is an atom string, I hope? + try { + Carbon::parse($value); + } catch (InvalidDateException $e) { + Log::error(sprintf('"%s" is not a valid date or time: %s', $value, $e->getMessage())); + + return false; + } + + return true; + } +} \ No newline at end of file diff --git a/app/Transformers/TransactionTransformer.php b/app/Transformers/TransactionTransformer.php index 80e9ff8e9f..353b9fffa6 100644 --- a/app/Transformers/TransactionTransformer.php +++ b/app/Transformers/TransactionTransformer.php @@ -77,7 +77,7 @@ class TransactionTransformer extends AbstractTransformer 'description' => $transaction->description, 'journal_description' => $transaction->description, 'transaction_description' => $transaction->transaction_description, - 'date' => $transaction->date->format('Y-m-d'), + 'date' => $transaction->date->toAtomString(), 'type' => $transaction->transaction_type_type, 'identifier' => $transaction->identifier, 'journal_id' => (int)$transaction->journal_id, diff --git a/database/migrations/2019_01_28_193833_changes_for_v4710.php b/database/migrations/2019_01_28_193833_changes_for_v4710.php index 011305f270..f1edfb3b6e 100644 --- a/database/migrations/2019_01_28_193833_changes_for_v4710.php +++ b/database/migrations/2019_01_28_193833_changes_for_v4710.php @@ -11,7 +11,7 @@ class ChangesForV4710 extends Migration * * @return void */ - public function down() + public function down(): void { Schema::dropIfExists('group_journals'); Schema::dropIfExists('transaction_groups'); @@ -22,7 +22,7 @@ class ChangesForV4710 extends Migration * * @return void */ - public function up() + public function up(): void { if (!Schema::hasTable('transaction_groups')) { Schema::create( diff --git a/database/migrations/2019_02_05_055516_changes_for_v4711.php b/database/migrations/2019_02_05_055516_changes_for_v4711.php new file mode 100644 index 0000000000..365d67df24 --- /dev/null +++ b/database/migrations/2019_02_05_055516_changes_for_v4711.php @@ -0,0 +1,37 @@ +dateTimeTz('date')->change(); + } + ); + + Schema::table('preferences', function (Blueprint $table) { + $table->text('data')->nullable()->change(); + } + ); + } +} diff --git a/resources/lang/en_US/validation.php b/resources/lang/en_US/validation.php index f1aff6e459..6bbd33b028 100644 --- a/resources/lang/en_US/validation.php +++ b/resources/lang/en_US/validation.php @@ -25,6 +25,7 @@ declare(strict_types=1); return [ 'iban' => 'This is not a valid IBAN.', 'zero_or_more' => 'The value cannot be negative.', + 'date_or_time' => 'The value must be a valid date or time value (ISO 8601).', 'source_equals_destination' => 'The source account equals the destination account.', 'unique_account_number_for_user' => 'It looks like this account number is already in use.', 'unique_iban_for_user' => 'It looks like this IBAN is already in use.', From 40d77d82cd438d478bf2714ff679add27d0d6600 Mon Sep 17 00:00:00 2001 From: James Cole Date: Fri, 8 Feb 2019 16:45:42 +0100 Subject: [PATCH 10/33] Bunq import can now handle timestamps. --- app/Import/Storage/ImportArrayStorage.php | 4 ++-- app/Support/Import/Routine/Bunq/PaymentConverter.php | 9 ++++++--- app/Support/Logging/AuditLogger.php | 2 +- resources/views/v1/transactions/show.twig | 2 +- 4 files changed, 10 insertions(+), 7 deletions(-) diff --git a/app/Import/Storage/ImportArrayStorage.php b/app/Import/Storage/ImportArrayStorage.php index 6da281f269..eb1299a6ce 100644 --- a/app/Import/Storage/ImportArrayStorage.php +++ b/app/Import/Storage/ImportArrayStorage.php @@ -457,7 +457,7 @@ class ImportArrayStorage Log::debug(sprintf('Going to store entry %d of %d', $index + 1, $count)); // convert the date to an object: - $store['date'] = Carbon::createFromFormat('Y-m-d', $store['date']); + $store['date'] = Carbon::parse($store['date'], config('app.timezone')); $store['description'] = '' === $store['description'] ? '(empty description)' : $store['description']; // store the journal. try { @@ -556,7 +556,7 @@ class ImportArrayStorage Log::debug(sprintf('Comparison is a hit! (%s)', $hits)); // compare date: - $transferDate = $transfer->date->format('Y-m-d'); + $transferDate = $transfer->date->format('Y-m-d H:i:s'); Log::debug(sprintf('Comparing dates "%s" to "%s"', $transaction['date'], $transferDate)); if ($transaction['date'] !== $transferDate) { continue; // @codeCoverageIgnore diff --git a/app/Support/Import/Routine/Bunq/PaymentConverter.php b/app/Support/Import/Routine/Bunq/PaymentConverter.php index cff39a747a..e37da1ecaf 100644 --- a/app/Support/Import/Routine/Bunq/PaymentConverter.php +++ b/app/Support/Import/Routine/Bunq/PaymentConverter.php @@ -105,7 +105,10 @@ class PaymentConverter $type = TransactionType::TRANSFER; Log::debug('Because both transctions are asset, will make it a transfer.'); } - $created = new Carbon($payment->getCreated()); + Log::debug(sprintf('Bunq created = %s', $payment->getCreated())); + $created = new Carbon($payment->getCreated(), 'UTC'); + // correct timezone to system timezone. + $created->setTimezone(config('app.timezone')); $description = $payment->getDescription(); if ('' === $payment->getDescription() && 'SAVINGS' === $payment->getType()) { @@ -115,7 +118,7 @@ class PaymentConverter $storeData = [ 'user' => $this->importJob->user_id, 'type' => $type, - 'date' => $created->format('Y-m-d'), + 'date' => $created->format('Y-m-d H:i:s'), 'timestamp' => $created->toAtomString(), 'description' => $description, 'piggy_bank_id' => null, @@ -151,7 +154,7 @@ class PaymentConverter ], ], ]; - Log::info(sprintf('Parsed %s: "%s" (%s).', $created->format('Y-m-d'), $storeData['description'], $storeData['transactions'][0]['amount'])); + Log::info(sprintf('Parsed %s: "%s" (%s).', $created->format('Y-m-d H:i:s'), $storeData['description'], $storeData['transactions'][0]['amount'])); return $storeData; diff --git a/app/Support/Logging/AuditLogger.php b/app/Support/Logging/AuditLogger.php index 3c98651b85..751fccac66 100644 --- a/app/Support/Logging/AuditLogger.php +++ b/app/Support/Logging/AuditLogger.php @@ -17,7 +17,7 @@ class AuditLogger */ public function __invoke($logger) { - $processor = new AuditProcessor(); + $processor = new AuditProcessor; $logger->pushProcessor($processor); } } \ No newline at end of file diff --git a/resources/views/v1/transactions/show.twig b/resources/views/v1/transactions/show.twig index 94ce47984e..57a7c397cc 100644 --- a/resources/views/v1/transactions/show.twig +++ b/resources/views/v1/transactions/show.twig @@ -108,7 +108,7 @@ {{ trans('list.date') }} - {{ journal.date.formatLocalized(monthAndDayFormat) }} + {{ journal.date.formatLocalized(dateTimeFormat) }} From 1ec27722552dcf8f950a7aa43c03f34daba1b38f Mon Sep 17 00:00:00 2001 From: James Cole Date: Fri, 8 Feb 2019 16:51:29 +0100 Subject: [PATCH 11/33] Fix #2052 --- app/TransactionRules/Actions/ConvertToTransfer.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/app/TransactionRules/Actions/ConvertToTransfer.php b/app/TransactionRules/Actions/ConvertToTransfer.php index b4dbe20d50..5570187836 100644 --- a/app/TransactionRules/Actions/ConvertToTransfer.php +++ b/app/TransactionRules/Actions/ConvertToTransfer.php @@ -72,7 +72,9 @@ class ConvertToTransfer implements ActionInterface /** @var AccountRepositoryInterface $repository */ $repository = app(AccountRepositoryInterface::class); $repository->setUser($journal->user); - $asset = $repository->findByName($this->action->action_value, [AccountType::ASSET, AccountType::DEFAULT]); + $asset = $repository->findByName( + $this->action->action_value, [AccountType::ASSET, AccountType::DEFAULT, AccountType::LOAN, AccountType::DEBT, AccountType::MORTGAGE] + ); if (null === $asset) { // @codeCoverageIgnoreStart Log::error( @@ -129,6 +131,7 @@ class ConvertToTransfer implements ActionInterface return false; // @codeCoverageIgnore } + /** * A deposit is from Revenue to Asset. * We replace the Revenue with another asset. From e1bb0298cbf2a2de5c5578f4c938deb1110a8ee3 Mon Sep 17 00:00:00 2001 From: James Cole Date: Fri, 8 Feb 2019 16:56:07 +0100 Subject: [PATCH 12/33] Fix category use date. --- app/Repositories/Category/CategoryRepository.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Repositories/Category/CategoryRepository.php b/app/Repositories/Category/CategoryRepository.php index 9bb76ab7b4..a4b318d529 100644 --- a/app/Repositories/Category/CategoryRepository.php +++ b/app/Repositories/Category/CategoryRepository.php @@ -292,7 +292,7 @@ class CategoryRepository implements CategoryRepositoryInterface return $lastTransactionDate; } - if ($lastTransactionDate < $lastJournalDate) { + if ($lastTransactionDate > $lastJournalDate) { return $lastTransactionDate; } From 41d22876c432628ebac8fd73bc9808abbc076ae5 Mon Sep 17 00:00:00 2001 From: James Cole Date: Fri, 8 Feb 2019 17:00:46 +0100 Subject: [PATCH 13/33] Update changelog and version. --- changelog.md | 26 ++++++++++++++++++++++++++ config/firefly.php | 6 +++--- 2 files changed, 29 insertions(+), 3 deletions(-) diff --git a/changelog.md b/changelog.md index a7dbd6c452..c5ee397bf6 100644 --- a/changelog.md +++ b/changelog.md @@ -2,6 +2,32 @@ All notable changes to this project will be documented in this file. This project adheres to [Semantic Versioning](http://semver.org/). +## [4.7.11] - 2019-02-09 +### Added +- Experimental audit logging channel to track important events (separate from debug logging). + + +### Changed +- #2003, #2006 Transactions can be stored with a timestamp. The user-interface does not support this yet. But the API does. +- Docker image tags a new manifest for arm and amd64. + +### Deprecated +- Initial release. + +### Removed +- @skuzzle removed an annoying console.log statement. + +### Fixed +- #2048 Fix "Are you sure?" popup, thanks to @nescafe2002! +- #2049 Empty preferences would crash Firefly III. +- #2052 Rules could not auto-covert to liabilities. +- Webbased upgrade routine will also decrypt the database. +- Last use date for categories was off. + +### API +- The `date`-field in any transaction object now returns a ISO 8601 timestamp instead of a date. + + ## [4.7.10] - 2019-02-03 ### Added - [Issue 2037](https://github.com/firefly-iii/firefly-iii/issues/2037) Added some new magic keywords to reports. diff --git a/config/firefly.php b/config/firefly.php index 2056381f44..0332c36569 100644 --- a/config/firefly.php +++ b/config/firefly.php @@ -93,9 +93,9 @@ return [ 'is_demo_site' => false, ], 'encryption' => null === env('USE_ENCRYPTION') || env('USE_ENCRYPTION') === true, - 'version' => '4.7.10', - 'api_version' => '0.9.1', - 'db_version' => 7, + 'version' => '4.7.11', + 'api_version' => '0.9.2', + 'db_version' => 8, 'maxUploadSize' => 15242880, 'send_error_message' => env('SEND_ERROR_MESSAGE', true), 'site_owner' => env('SITE_OWNER', ''), From a1ac1a4a293a6cbc475be5ad9eeeca67d4dc3d01 Mon Sep 17 00:00:00 2001 From: James Cole Date: Fri, 8 Feb 2019 17:01:49 +0100 Subject: [PATCH 14/33] Remove empty header from changelog [skip ci] --- changelog.md | 4 ---- 1 file changed, 4 deletions(-) diff --git a/changelog.md b/changelog.md index c5ee397bf6..372048015e 100644 --- a/changelog.md +++ b/changelog.md @@ -6,14 +6,10 @@ This project adheres to [Semantic Versioning](http://semver.org/). ### Added - Experimental audit logging channel to track important events (separate from debug logging). - ### Changed - #2003, #2006 Transactions can be stored with a timestamp. The user-interface does not support this yet. But the API does. - Docker image tags a new manifest for arm and amd64. -### Deprecated -- Initial release. - ### Removed - @skuzzle removed an annoying console.log statement. From d0d7c437f2905050026b8afbbbec81ae5dffd39b Mon Sep 17 00:00:00 2001 From: James Cole Date: Fri, 8 Feb 2019 17:15:54 +0100 Subject: [PATCH 15/33] Different build flow. --- .deploy/docker/build-generic.sh | 20 ++++++++++++++++++++ .travis.yml | 14 ++++++++------ 2 files changed, 28 insertions(+), 6 deletions(-) create mode 100755 .deploy/docker/build-generic.sh diff --git a/.deploy/docker/build-generic.sh b/.deploy/docker/build-generic.sh new file mode 100755 index 0000000000..e72e769973 --- /dev/null +++ b/.deploy/docker/build-generic.sh @@ -0,0 +1,20 @@ +#!/usr/bin/env bash + +# build image +echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin + +# build develop +if [ "$TRAVIS_BRANCH" == "develop" ]; then + echo "Build develop $ARCH" + #docker build -t whoami --build-arg "arch=$ARCH" . + #docker build -t jc5x/firefly-iii:develop -f Dockerfile --build-arg "arch=$env:ARCH" . + #docker push jc5x/firefly-iii:develop +fi + +#if [ "$TRAVIS_BRANCH" == "master" ]; then +# echo "Build master amd64" +# docker build -t jc5x/firefly-iii:latest-amd -f Dockerfile . +# docker tag jc5x/firefly-iii:latest-amd jc5x/firefly-iii:release-$VERSION-amd +# docker push jc5x/firefly-iii:latest-amd +# docker push jc5x/firefly-iii:release-$VERSION-amd +#fi \ No newline at end of file diff --git a/.travis.yml b/.travis.yml index 5ebaaaf8ab..3b99f0ad5c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,5 +1,11 @@ sudo: required -language: bash +env: + - VERSION=4.7.10 + matrix: + - ARCH=arm + - ARCH=arm64 + - ARCH=amd64 + dist: xenial # safelist branches: @@ -7,9 +13,6 @@ branches: - develop - master -env: - - VERSION=4.7.10 - services: - docker @@ -19,6 +22,5 @@ script: - sudo service docker restart - docker version -f '{{.Server.Experimental}}' - docker version - - .deploy/docker/build-amd64.sh - - .deploy/docker/build-arm.sh + - .deploy/docker/build-generic.sh - .deploy/docker/manifest.sh \ No newline at end of file From e88061199c59abf765ac2e389b46367755ef804f Mon Sep 17 00:00:00 2001 From: James Cole Date: Fri, 8 Feb 2019 17:17:19 +0100 Subject: [PATCH 16/33] Trigger a new build. --- .deploy/docker/build-generic.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.deploy/docker/build-generic.sh b/.deploy/docker/build-generic.sh index e72e769973..e5a3096b2c 100755 --- a/.deploy/docker/build-generic.sh +++ b/.deploy/docker/build-generic.sh @@ -6,7 +6,7 @@ echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin # build develop if [ "$TRAVIS_BRANCH" == "develop" ]; then echo "Build develop $ARCH" - #docker build -t whoami --build-arg "arch=$ARCH" . + # > original command. docker build -t whoami --build-arg "arch=$ARCH" . #docker build -t jc5x/firefly-iii:develop -f Dockerfile --build-arg "arch=$env:ARCH" . #docker push jc5x/firefly-iii:develop fi From a18272513db5c945f9a08d9a20c62143875bc0de Mon Sep 17 00:00:00 2001 From: James Cole Date: Fri, 8 Feb 2019 17:28:04 +0100 Subject: [PATCH 17/33] Fix YML --- .travis.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 3b99f0ad5c..edc0dea906 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,6 +1,5 @@ sudo: required env: - - VERSION=4.7.10 matrix: - ARCH=arm - ARCH=arm64 From d41be08b483010f3277110a1a7b3687bf007a7ee Mon Sep 17 00:00:00 2001 From: James Cole Date: Fri, 8 Feb 2019 17:30:42 +0100 Subject: [PATCH 18/33] Rename file --- Dockerfile-ARM => Dockerfile-env | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename Dockerfile-ARM => Dockerfile-env (100%) diff --git a/Dockerfile-ARM b/Dockerfile-env similarity index 100% rename from Dockerfile-ARM rename to Dockerfile-env From e55fd968cfbe4c3b4637a86c6cbd1eb689c3f413 Mon Sep 17 00:00:00 2001 From: James Cole Date: Fri, 8 Feb 2019 17:31:25 +0100 Subject: [PATCH 19/33] Rename file --- Dockerfile.amd64 | 51 ++++++++++++++++++++++++++++++++ Dockerfile-env => Dockerfile.arm | 0 Dockerfile.arm64 | 50 +++++++++++++++++++++++++++++++ 3 files changed, 101 insertions(+) create mode 100644 Dockerfile.amd64 rename Dockerfile-env => Dockerfile.arm (100%) create mode 100644 Dockerfile.arm64 diff --git a/Dockerfile.amd64 b/Dockerfile.amd64 new file mode 100644 index 0000000000..c056613149 --- /dev/null +++ b/Dockerfile.amd64 @@ -0,0 +1,51 @@ +FROM php:7.2-apache + +ENV FIREFLY_PATH=/var/www/firefly-iii COMPOSER_ALLOW_SUPERUSER=1 +LABEL version="1.3" maintainer="thegrumpydictator@gmail.com" + +# Create volumes +VOLUME $FIREFLY_PATH/storage/export $FIREFLY_PATH/storage/upload + +# Install some stuff +RUN apt-get update && apt-get install -y libpng-dev \ + libicu-dev \ + unzip \ + gettext-base \ + libldap2-dev \ + libpq-dev \ + locales \ + libmemcached-dev && \ + apt-get clean && \ + rm -rf /var/lib/apt/lists/* + +# Copy in Firefly III source +WORKDIR $FIREFLY_PATH +ADD . $FIREFLY_PATH + +# copy ca certs to correct location +COPY ./.deploy/docker/cacert.pem /usr/local/ssl/cert.pem + +# copy Apache config to correct spot. +COPY ./.deploy/docker/apache2.conf /etc/apache2/apache2.conf + +# Enable default site (Firefly III) +COPY ./.deploy/docker/apache-firefly.conf /etc/apache2/sites-available/000-default.conf + +# Run a lot of installation commands: +RUN chown -R www-data:www-data /var/www && \ + chmod -R 775 $FIREFLY_PATH/storage && \ + a2enmod rewrite && a2enmod ssl && \ + docker-php-ext-configure ldap --with-libdir=lib/$(gcc -dumpmachine)/ && \ + docker-php-ext-install -j$(nproc) zip bcmath ldap gd pdo_pgsql pdo_mysql intl opcache && \ + pecl install memcached-3.1.3 && \ + docker-php-ext-enable memcached && \ + curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer && \ + echo "de_DE.UTF-8 UTF-8\nen_US.UTF-8 UTF-8\nes_ES.UTF-8 UTF-8\nfr_FR.UTF-8 UTF-8\nid_ID.UTF-8 UTF-8\nit_IT.UTF-8 UTF-8\nnl_NL.UTF-8 UTF-8\npl_PL.UTF-8 UTF-8\npt_BR.UTF-8 UTF-8\nru_RU.UTF-8 UTF-8\ntr_TR.UTF-8 UTF-8\nzh_TW.UTF-8 UTF-8\nzh_CN.UTF-8 UTF-8\n\n" > /etc/locale.gen && \ + locale-gen && \ + composer install --prefer-dist --no-dev --no-scripts --no-suggest + +# Expose port 80 +EXPOSE 80 + +# Run entrypoint thing +ENTRYPOINT [".deploy/docker/entrypoint.sh"] diff --git a/Dockerfile-env b/Dockerfile.arm similarity index 100% rename from Dockerfile-env rename to Dockerfile.arm diff --git a/Dockerfile.arm64 b/Dockerfile.arm64 new file mode 100644 index 0000000000..cfe6e0ad31 --- /dev/null +++ b/Dockerfile.arm64 @@ -0,0 +1,50 @@ +FROM arm32v7/php:7.2.8-apache-stretch +ARG TARGETPLATFORM +COPY tmp/qemu-arm-static /usr/bin/qemu-arm-static +ENV FIREFLY_PATH=/var/www/firefly-iii COMPOSER_ALLOW_SUPERUSER=1 +LABEL version="1.3" maintainer="thegrumpydictator@gmail.com" + +# Create volumes +VOLUME $FIREFLY_PATH/storage/export $FIREFLY_PATH/storage/upload + +# Install some stuff +RUN apt-get update && apt-get install -y libpng-dev \ + libicu-dev \ + unzip \ + gettext-base \ + libldap2-dev \ + libpq-dev \ + locales \ + libmemcached-dev + +# Copy in Firefly III source +WORKDIR $FIREFLY_PATH +ADD . $FIREFLY_PATH + +# copy ca certs to correct location +COPY ./.deploy/docker/cacert.pem /usr/local/ssl/cert.pem + +# copy Apache config to correct spot. +COPY ./.deploy/docker/apache2.conf /etc/apache2/apache2.conf + +# Enable default site (Firefly III) +COPY ./.deploy/docker/apache-firefly.conf /etc/apache2/sites-available/000-default.conf + +# Run a lot of installation commands: +RUN chown -R www-data:www-data /var/www && \ + chmod -R 775 $FIREFLY_PATH/storage && \ + a2enmod rewrite && a2enmod ssl && \ + docker-php-ext-configure ldap --with-libdir=lib/$(gcc -dumpmachine)/ && \ + docker-php-ext-install -j$(nproc) zip bcmath ldap gd pdo_pgsql pdo_mysql intl opcache && \ + pecl install memcached-3.1.3 && \ + docker-php-ext-enable memcached && \ + curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer && \ + echo "de_DE.UTF-8 UTF-8\nen_US.UTF-8 UTF-8\nes_ES.UTF-8 UTF-8\nfr_FR.UTF-8 UTF-8\nid_ID.UTF-8 UTF-8\nit_IT.UTF-8 UTF-8\nnl_NL.UTF-8 UTF-8\npl_PL.UTF-8 UTF-8\npt_BR.UTF-8 UTF-8\nru_RU.UTF-8 UTF-8\ntr_TR.UTF-8 UTF-8\nzh_TW.UTF-8 UTF-8\nzh_CN.UTF-8 UTF-8\n\n" > /etc/locale.gen && \ + locale-gen && \ + composer install --prefer-dist --no-dev --no-scripts --no-suggest + +# Expose port 80 +EXPOSE 80 + +# Run entrypoint thing +ENTRYPOINT [".deploy/docker/entrypoint.sh"] From 3a0eb5a428a15302761c83e6b6f171a750261203 Mon Sep 17 00:00:00 2001 From: James Cole Date: Fri, 8 Feb 2019 17:31:32 +0100 Subject: [PATCH 20/33] Do actual build --- .deploy/docker/build-generic.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.deploy/docker/build-generic.sh b/.deploy/docker/build-generic.sh index e5a3096b2c..5d148784bd 100755 --- a/.deploy/docker/build-generic.sh +++ b/.deploy/docker/build-generic.sh @@ -7,7 +7,7 @@ echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin if [ "$TRAVIS_BRANCH" == "develop" ]; then echo "Build develop $ARCH" # > original command. docker build -t whoami --build-arg "arch=$ARCH" . - #docker build -t jc5x/firefly-iii:develop -f Dockerfile --build-arg "arch=$env:ARCH" . + docker build -t jc5x/firefly-iii:develop-$ARCH -f Dockerfile.$ARCH --build-arg "arch=$ARCH" . #docker push jc5x/firefly-iii:develop fi From e4a95e55edb12c74d3abc497137a6e079933fa7b Mon Sep 17 00:00:00 2001 From: James Cole Date: Fri, 8 Feb 2019 17:34:46 +0100 Subject: [PATCH 21/33] Remove copy argument. --- Dockerfile.arm | 2 +- Dockerfile.arm64 | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile.arm b/Dockerfile.arm index cfe6e0ad31..10a3e1c91a 100644 --- a/Dockerfile.arm +++ b/Dockerfile.arm @@ -1,6 +1,6 @@ FROM arm32v7/php:7.2.8-apache-stretch ARG TARGETPLATFORM -COPY tmp/qemu-arm-static /usr/bin/qemu-arm-static +#COPY tmp/qemu-arm-static /usr/bin/qemu-arm-static ENV FIREFLY_PATH=/var/www/firefly-iii COMPOSER_ALLOW_SUPERUSER=1 LABEL version="1.3" maintainer="thegrumpydictator@gmail.com" diff --git a/Dockerfile.arm64 b/Dockerfile.arm64 index cfe6e0ad31..10a3e1c91a 100644 --- a/Dockerfile.arm64 +++ b/Dockerfile.arm64 @@ -1,6 +1,6 @@ FROM arm32v7/php:7.2.8-apache-stretch ARG TARGETPLATFORM -COPY tmp/qemu-arm-static /usr/bin/qemu-arm-static +#COPY tmp/qemu-arm-static /usr/bin/qemu-arm-static ENV FIREFLY_PATH=/var/www/firefly-iii COMPOSER_ALLOW_SUPERUSER=1 LABEL version="1.3" maintainer="thegrumpydictator@gmail.com" From 21ddbd220ab6101263341150bdb912aed5be04a6 Mon Sep 17 00:00:00 2001 From: James Cole Date: Fri, 8 Feb 2019 17:40:29 +0100 Subject: [PATCH 22/33] Include lib for arm --- .deploy/docker/build-generic.sh | 9 +++++++++ Dockerfile.arm | 2 +- Dockerfile.arm64 | 2 +- 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/.deploy/docker/build-generic.sh b/.deploy/docker/build-generic.sh index 5d148784bd..83cd672e2c 100755 --- a/.deploy/docker/build-generic.sh +++ b/.deploy/docker/build-generic.sh @@ -3,6 +3,15 @@ # build image echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin +# get qemu-arm-static binary +if [ "$TRAVIS_BRANCH" != "amd64" ]; then + mkdir tmp + pushd tmp && \ + curl -L -o qemu-arm-static.tar.gz https://github.com/multiarch/qemu-user-static/releases/download/v2.6.0/qemu-arm-static.tar.gz && \ + tar xzf qemu-arm-static.tar.gz && \ + popd +fi + # build develop if [ "$TRAVIS_BRANCH" == "develop" ]; then echo "Build develop $ARCH" diff --git a/Dockerfile.arm b/Dockerfile.arm index 10a3e1c91a..cfe6e0ad31 100644 --- a/Dockerfile.arm +++ b/Dockerfile.arm @@ -1,6 +1,6 @@ FROM arm32v7/php:7.2.8-apache-stretch ARG TARGETPLATFORM -#COPY tmp/qemu-arm-static /usr/bin/qemu-arm-static +COPY tmp/qemu-arm-static /usr/bin/qemu-arm-static ENV FIREFLY_PATH=/var/www/firefly-iii COMPOSER_ALLOW_SUPERUSER=1 LABEL version="1.3" maintainer="thegrumpydictator@gmail.com" diff --git a/Dockerfile.arm64 b/Dockerfile.arm64 index 10a3e1c91a..cfe6e0ad31 100644 --- a/Dockerfile.arm64 +++ b/Dockerfile.arm64 @@ -1,6 +1,6 @@ FROM arm32v7/php:7.2.8-apache-stretch ARG TARGETPLATFORM -#COPY tmp/qemu-arm-static /usr/bin/qemu-arm-static +COPY tmp/qemu-arm-static /usr/bin/qemu-arm-static ENV FIREFLY_PATH=/var/www/firefly-iii COMPOSER_ALLOW_SUPERUSER=1 LABEL version="1.3" maintainer="thegrumpydictator@gmail.com" From 492c11784b7f5223459ec4559067c9560be3d88e Mon Sep 17 00:00:00 2001 From: James Cole Date: Sat, 9 Feb 2019 06:40:55 +0100 Subject: [PATCH 23/33] Update with manifest commands. --- .deploy/docker/build-generic.sh | 21 ++++++++++----------- .deploy/docker/entrypoint.sh | 2 ++ .deploy/docker/manifest.sh | 9 +++------ .travis.yml | 4 +++- Dockerfile.amd64 | 2 +- Dockerfile.arm | 2 +- Dockerfile.arm64 | 2 +- 7 files changed, 21 insertions(+), 21 deletions(-) diff --git a/.deploy/docker/build-generic.sh b/.deploy/docker/build-generic.sh index 83cd672e2c..ede14570c8 100755 --- a/.deploy/docker/build-generic.sh +++ b/.deploy/docker/build-generic.sh @@ -4,7 +4,7 @@ echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin # get qemu-arm-static binary -if [ "$TRAVIS_BRANCH" != "amd64" ]; then +if [ "$TRAVIS_BRANCH" == "arm" ]; then mkdir tmp pushd tmp && \ curl -L -o qemu-arm-static.tar.gz https://github.com/multiarch/qemu-user-static/releases/download/v2.6.0/qemu-arm-static.tar.gz && \ @@ -15,15 +15,14 @@ fi # build develop if [ "$TRAVIS_BRANCH" == "develop" ]; then echo "Build develop $ARCH" - # > original command. docker build -t whoami --build-arg "arch=$ARCH" . - docker build -t jc5x/firefly-iii:develop-$ARCH -f Dockerfile.$ARCH --build-arg "arch=$ARCH" . - #docker push jc5x/firefly-iii:develop + docker build -t jc5x/firefly-iii:develop-$ARCH -f Dockerfile.$ARCH . + docker push jc5x/firefly-iii:develop-$ARCH fi -#if [ "$TRAVIS_BRANCH" == "master" ]; then -# echo "Build master amd64" -# docker build -t jc5x/firefly-iii:latest-amd -f Dockerfile . -# docker tag jc5x/firefly-iii:latest-amd jc5x/firefly-iii:release-$VERSION-amd -# docker push jc5x/firefly-iii:latest-amd -# docker push jc5x/firefly-iii:release-$VERSION-amd -#fi \ No newline at end of file +if [ "$TRAVIS_BRANCH" == "master" ]; then + echo "Build master $ARCH" + docker build -t jc5x/firefly-iii:latest-$ARCH -f Dockerfile.$ARCH . + docker tag jc5x/firefly-iii:latest-$ARCH jc5x/firefly-iii:release-$VERSION-$ARCH + docker push jc5x/firefly-iii:latest-$ARCH + docker push jc5x/firefly-iii:release-$VERSION-$ARCH +fi \ No newline at end of file diff --git a/.deploy/docker/entrypoint.sh b/.deploy/docker/entrypoint.sh index 326d932e26..f5978beb77 100755 --- a/.deploy/docker/entrypoint.sh +++ b/.deploy/docker/entrypoint.sh @@ -2,6 +2,8 @@ echo "Now in entrypoint.sh for Firefly III" +lscpu + # make sure the correct directories exists (suggested by @chrif): echo "Making directories..." mkdir -p $FIREFLY_PATH/storage/app/public diff --git a/.deploy/docker/manifest.sh b/.deploy/docker/manifest.sh index 7e7d9b0abb..f67bf4792f 100755 --- a/.deploy/docker/manifest.sh +++ b/.deploy/docker/manifest.sh @@ -1,12 +1,9 @@ #!/usr/bin/env bash -# Disabled until I can figure out how this works in Travis. -exit 0 - if [ "$TRAVIS_BRANCH" == "develop" ]; then TARGET=jc5x/firefly-iii:develop ARM=jc5x/firefly-iii:develop-arm - AMD=jc5x/firefly-iii:develop-amd + AMD=jc5x/firefly-iii:develop-amd64 docker manifest create $TARGET $AMD $ARM docker manifest annotate $TARGET $ARM --arch arm --os linux @@ -19,7 +16,7 @@ echo "The version is $VERSION" if [ "$TRAVIS_BRANCH" == "master" ]; then TARGET=jc5x/firefly-iii:latest ARM=jc5x/firefly-iii:latest-arm - AMD=jc5x/firefly-iii:latest-amd + AMD=jc5x/firefly-iii:latest-amd64 docker manifest create $TARGET $AMD $ARM docker manifest annotate $TARGET $ARM --arch arm --os linux @@ -29,7 +26,7 @@ if [ "$TRAVIS_BRANCH" == "master" ]; then # and another one for version specific: TARGET=jc5x/firefly-iii:release-$VERSION ARM=jc5x/firefly-iii:release-$VERSION-arm - AMD=jc5x/firefly-iii:release-$VERSION-amd + AMD=jc5x/firefly-iii:release-$VERSION-amd64 docker manifest create $TARGET $AMD $ARM docker manifest annotate $TARGET $ARM --arch arm --os linux diff --git a/.travis.yml b/.travis.yml index edc0dea906..6444c709df 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,8 +1,10 @@ sudo: required env: + global: + - VERSION=4.7.11 matrix: - ARCH=arm - - ARCH=arm64 + #- ARCH=arm64 - ARCH=amd64 dist: xenial diff --git a/Dockerfile.amd64 b/Dockerfile.amd64 index c056613149..4b27c86669 100644 --- a/Dockerfile.amd64 +++ b/Dockerfile.amd64 @@ -1,5 +1,5 @@ FROM php:7.2-apache - +ARG ARCH ENV FIREFLY_PATH=/var/www/firefly-iii COMPOSER_ALLOW_SUPERUSER=1 LABEL version="1.3" maintainer="thegrumpydictator@gmail.com" diff --git a/Dockerfile.arm b/Dockerfile.arm index cfe6e0ad31..3860b358af 100644 --- a/Dockerfile.arm +++ b/Dockerfile.arm @@ -1,5 +1,5 @@ FROM arm32v7/php:7.2.8-apache-stretch -ARG TARGETPLATFORM +ARG ARCH COPY tmp/qemu-arm-static /usr/bin/qemu-arm-static ENV FIREFLY_PATH=/var/www/firefly-iii COMPOSER_ALLOW_SUPERUSER=1 LABEL version="1.3" maintainer="thegrumpydictator@gmail.com" diff --git a/Dockerfile.arm64 b/Dockerfile.arm64 index cfe6e0ad31..3860b358af 100644 --- a/Dockerfile.arm64 +++ b/Dockerfile.arm64 @@ -1,5 +1,5 @@ FROM arm32v7/php:7.2.8-apache-stretch -ARG TARGETPLATFORM +ARG ARCH COPY tmp/qemu-arm-static /usr/bin/qemu-arm-static ENV FIREFLY_PATH=/var/www/firefly-iii COMPOSER_ALLOW_SUPERUSER=1 LABEL version="1.3" maintainer="thegrumpydictator@gmail.com" From 1774bcbabec43060b98ca33175c7d53dc6d7a0ab Mon Sep 17 00:00:00 2001 From: James Cole Date: Sat, 9 Feb 2019 10:36:59 +0100 Subject: [PATCH 24/33] Add copyright statements and newlines. --- .travis.yml | 2 +- .../Controllers/Chart/AccountController.php | 23 +- .../Chart/AvailableBudgetController.php | 23 +- .../Controllers/Chart/CategoryController.php | 23 +- app/Api/V1/Controllers/SummaryController.php | 23 +- app/Console/Commands/DecryptDatabase.php | 22 ++ app/Import/Converter/BankDebitCredit.php | 2 +- app/Import/Specifics/RabobankDescription.php | 2 +- app/Rules/IsDateOrTime.php | 23 +- .../Http/Controllers/ChartGeneration.php | 2 +- app/Support/Logging/AuditLogger.php | 23 +- app/Support/Logging/AuditProcessor.php | 23 +- .../Recurring/CalculateRangeOccurrences.php | 23 +- .../Recurring/CalculateXOccurrences.php | 23 +- .../Recurring/FiltersWeekends.php | 23 +- changelog.md | 12 +- composer.lock | 223 +++++++++--------- .../2019_01_28_193833_changes_for_v4710.php | 22 ++ .../2019_02_05_055516_changes_for_v4711.php | 22 ++ index.php | 21 ++ resources/lang/en_US/import.php | 17 -- resources/views/v1/import/index.twig | 67 ------ resources/views/v2/auth/passwords/email.twig | 2 +- resources/views/v2/auth/passwords/reset.twig | 2 +- routes/api.php | 21 ++ routes/channels.php | 21 ++ routes/console.php | 21 ++ server.php | 21 ++ 28 files changed, 516 insertions(+), 216 deletions(-) diff --git a/.travis.yml b/.travis.yml index 6444c709df..730eb79b79 100644 --- a/.travis.yml +++ b/.travis.yml @@ -24,4 +24,4 @@ script: - docker version -f '{{.Server.Experimental}}' - docker version - .deploy/docker/build-generic.sh - - .deploy/docker/manifest.sh \ No newline at end of file + - .deploy/docker/manifest.sh diff --git a/app/Api/V1/Controllers/Chart/AccountController.php b/app/Api/V1/Controllers/Chart/AccountController.php index 22c97e13d9..fcb2a0739e 100644 --- a/app/Api/V1/Controllers/Chart/AccountController.php +++ b/app/Api/V1/Controllers/Chart/AccountController.php @@ -1,4 +1,25 @@ . + */ + declare(strict_types=1); namespace FireflyIII\Api\V1\Controllers\Chart; @@ -324,4 +345,4 @@ class AccountController extends Controller return $return; } -} \ No newline at end of file +} diff --git a/app/Api/V1/Controllers/Chart/AvailableBudgetController.php b/app/Api/V1/Controllers/Chart/AvailableBudgetController.php index 0f2c2d79a6..8335acc3bc 100644 --- a/app/Api/V1/Controllers/Chart/AvailableBudgetController.php +++ b/app/Api/V1/Controllers/Chart/AvailableBudgetController.php @@ -1,4 +1,25 @@ . + */ + declare(strict_types=1); namespace FireflyIII\Api\V1\Controllers\Chart; @@ -90,4 +111,4 @@ class AvailableBudgetController extends Controller return response()->json($chartData); } -} \ No newline at end of file +} diff --git a/app/Api/V1/Controllers/Chart/CategoryController.php b/app/Api/V1/Controllers/Chart/CategoryController.php index 4d7a6a4422..868297af1e 100644 --- a/app/Api/V1/Controllers/Chart/CategoryController.php +++ b/app/Api/V1/Controllers/Chart/CategoryController.php @@ -1,4 +1,25 @@ . + */ + declare(strict_types=1); namespace FireflyIII\Api\V1\Controllers\Chart; @@ -185,4 +206,4 @@ class CategoryController extends Controller return response()->json($chartData); } -} \ No newline at end of file +} diff --git a/app/Api/V1/Controllers/SummaryController.php b/app/Api/V1/Controllers/SummaryController.php index f617db72b7..a56ccc1671 100644 --- a/app/Api/V1/Controllers/SummaryController.php +++ b/app/Api/V1/Controllers/SummaryController.php @@ -1,4 +1,25 @@ . + */ + declare(strict_types=1); namespace FireflyIII\Api\V1\Controllers; @@ -389,4 +410,4 @@ class SummaryController extends Controller return $return; } -} \ No newline at end of file +} diff --git a/app/Console/Commands/DecryptDatabase.php b/app/Console/Commands/DecryptDatabase.php index 5c7eb3e519..ad8a83e4a3 100644 --- a/app/Console/Commands/DecryptDatabase.php +++ b/app/Console/Commands/DecryptDatabase.php @@ -1,5 +1,27 @@ . + */ + +declare(strict_types=1); + namespace FireflyIII\Console\Commands; use Crypt; diff --git a/app/Import/Converter/BankDebitCredit.php b/app/Import/Converter/BankDebitCredit.php index 7b91ef895a..3e131f4aaf 100644 --- a/app/Import/Converter/BankDebitCredit.php +++ b/app/Import/Converter/BankDebitCredit.php @@ -55,4 +55,4 @@ class BankDebitCredit implements ConverterInterface return 1; } -} \ No newline at end of file +} diff --git a/app/Import/Specifics/RabobankDescription.php b/app/Import/Specifics/RabobankDescription.php index d27392ca80..7dea7e493a 100644 --- a/app/Import/Specifics/RabobankDescription.php +++ b/app/Import/Specifics/RabobankDescription.php @@ -38,7 +38,7 @@ class RabobankDescription implements SpecificInterface */ public static function getDescription(): string { - return 'import.specific_pres_descr'; + return 'import.specific_rabo_descr'; } /** diff --git a/app/Rules/IsDateOrTime.php b/app/Rules/IsDateOrTime.php index 52c40b6ead..a8c76eb604 100644 --- a/app/Rules/IsDateOrTime.php +++ b/app/Rules/IsDateOrTime.php @@ -1,4 +1,25 @@ . + */ + declare(strict_types=1); namespace FireflyIII\Rules; @@ -58,4 +79,4 @@ class IsDateOrTime implements Rule return true; } -} \ No newline at end of file +} diff --git a/app/Support/Http/Controllers/ChartGeneration.php b/app/Support/Http/Controllers/ChartGeneration.php index ddf24454f9..efdcc4198c 100644 --- a/app/Support/Http/Controllers/ChartGeneration.php +++ b/app/Support/Http/Controllers/ChartGeneration.php @@ -259,4 +259,4 @@ trait ChartGeneration return $data; } -} \ No newline at end of file +} diff --git a/app/Support/Logging/AuditLogger.php b/app/Support/Logging/AuditLogger.php index 751fccac66..1f303c63cf 100644 --- a/app/Support/Logging/AuditLogger.php +++ b/app/Support/Logging/AuditLogger.php @@ -1,4 +1,25 @@ . + */ + declare(strict_types=1); namespace FireflyIII\Support\Logging; @@ -20,4 +41,4 @@ class AuditLogger $processor = new AuditProcessor; $logger->pushProcessor($processor); } -} \ No newline at end of file +} diff --git a/app/Support/Logging/AuditProcessor.php b/app/Support/Logging/AuditProcessor.php index 84fb2c4b86..823f5e57ff 100644 --- a/app/Support/Logging/AuditProcessor.php +++ b/app/Support/Logging/AuditProcessor.php @@ -1,4 +1,25 @@ . + */ + declare(strict_types=1); namespace FireflyIII\Support\Logging; @@ -25,4 +46,4 @@ class AuditProcessor return $record; } -} \ No newline at end of file +} diff --git a/app/Support/Repositories/Recurring/CalculateRangeOccurrences.php b/app/Support/Repositories/Recurring/CalculateRangeOccurrences.php index bb19a14ac7..4f8dfb0d62 100644 --- a/app/Support/Repositories/Recurring/CalculateRangeOccurrences.php +++ b/app/Support/Repositories/Recurring/CalculateRangeOccurrences.php @@ -1,4 +1,25 @@ . + */ + declare(strict_types=1); namespace FireflyIII\Support\Repositories\Recurring; @@ -200,4 +221,4 @@ trait CalculateRangeOccurrences return $return; } -} \ No newline at end of file +} diff --git a/app/Support/Repositories/Recurring/CalculateXOccurrences.php b/app/Support/Repositories/Recurring/CalculateXOccurrences.php index 9d586ad4d1..b640b1475d 100644 --- a/app/Support/Repositories/Recurring/CalculateXOccurrences.php +++ b/app/Support/Repositories/Recurring/CalculateXOccurrences.php @@ -1,4 +1,25 @@ . + */ + declare(strict_types=1); namespace FireflyIII\Support\Repositories\Recurring; @@ -199,4 +220,4 @@ trait CalculateXOccurrences return $return; } -} \ No newline at end of file +} diff --git a/app/Support/Repositories/Recurring/FiltersWeekends.php b/app/Support/Repositories/Recurring/FiltersWeekends.php index 1c0e1c8e87..b46daf1105 100644 --- a/app/Support/Repositories/Recurring/FiltersWeekends.php +++ b/app/Support/Repositories/Recurring/FiltersWeekends.php @@ -1,4 +1,25 @@ . + */ + declare(strict_types=1); namespace FireflyIII\Support\Repositories\Recurring; @@ -75,4 +96,4 @@ trait FiltersWeekends return $return; } -} \ No newline at end of file +} diff --git a/changelog.md b/changelog.md index 372048015e..7231863962 100644 --- a/changelog.md +++ b/changelog.md @@ -7,16 +7,16 @@ This project adheres to [Semantic Versioning](http://semver.org/). - Experimental audit logging channel to track important events (separate from debug logging). ### Changed -- #2003, #2006 Transactions can be stored with a timestamp. The user-interface does not support this yet. But the API does. +- [Issue 2003](https://github.com/firefly-iii/firefly-iii/issues/2003), [issue 2006](https://github.com/firefly-iii/firefly-iii/issues/2006) Transactions can be stored with a timestamp. The user-interface does not support this yet. But the API does. - Docker image tags a new manifest for arm and amd64. ### Removed -- @skuzzle removed an annoying console.log statement. +- [skuzzle](https://github.com/skuzzle) removed an annoying console.log statement. ### Fixed -- #2048 Fix "Are you sure?" popup, thanks to @nescafe2002! -- #2049 Empty preferences would crash Firefly III. -- #2052 Rules could not auto-covert to liabilities. +- [Issue 2048](https://github.com/firefly-iii/firefly-iii/issues/2048) Fix "Are you sure?" popup, thanks to @nescafe2002! +- [Issue 2049](https://github.com/firefly-iii/firefly-iii/issues/2049) Empty preferences would crash Firefly III. +- [Issue 2052](https://github.com/firefly-iii/firefly-iii/issues/2052) Rules could not auto-covert to liabilities. - Webbased upgrade routine will also decrypt the database. - Last use date for categories was off. @@ -64,7 +64,7 @@ This project adheres to [Semantic Versioning](http://semver.org/). - [Issue 2009](https://github.com/firefly-iii/firefly-iii/issues/2009) Could not change recurrence back to "forever". - [Issue 2033](https://github.com/firefly-iii/firefly-iii/issues/2033) Longitude can go from -180 to 180. - [Issue 2034](https://github.com/firefly-iii/firefly-iii/issues/2034) Rules were not being triggered in mass-edit. -- #2043 In rare instances the repetition of a recurring transaction was displayed incorrectly. +- [Issue 2043](https://github.com/firefly-iii/firefly-iii/issues/2043) In rare instances the repetition of a recurring transaction was displayed incorrectly. - Fixed broken translations in the recurring transactions overview. - When you create a recurring transfer you make make it fill (or empty) a piggy bank. This was not working, despite a fix in 4.7.8. - Fixed a bug where the importer would not be capable of creating new currencies. diff --git a/composer.lock b/composer.lock index e8cc91569d..0b1923ef29 100644 --- a/composer.lock +++ b/composer.lock @@ -1303,16 +1303,16 @@ }, { "name": "laravel/framework", - "version": "v5.7.24", + "version": "v5.7.25", "source": { "type": "git", "url": "https://github.com/laravel/framework.git", - "reference": "2ede55db4b8201ed0450fa7e7a4d7220aa29bc34" + "reference": "f8fb354878064b94a3ff09a6ffd48ee9a8d712cf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/framework/zipball/2ede55db4b8201ed0450fa7e7a4d7220aa29bc34", - "reference": "2ede55db4b8201ed0450fa7e7a4d7220aa29bc34", + "url": "https://api.github.com/repos/laravel/framework/zipball/f8fb354878064b94a3ff09a6ffd48ee9a8d712cf", + "reference": "f8fb354878064b94a3ff09a6ffd48ee9a8d712cf", "shasum": "" }, "require": { @@ -1445,7 +1445,7 @@ "framework", "laravel" ], - "time": "2019-01-29T22:13:46+00:00" + "time": "2019-02-05T14:28:43+00:00" }, { "name": "laravel/nexmo-notification-channel", @@ -2470,16 +2470,16 @@ }, { "name": "nexmo/client", - "version": "1.6.1", + "version": "1.6.2", "source": { "type": "git", "url": "https://github.com/Nexmo/nexmo-php.git", - "reference": "3dc03ca1dab726a23b757110897740e54304fc65" + "reference": "2f79f67f24225ea627ee14578e98c96276cdd4c5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Nexmo/nexmo-php/zipball/3dc03ca1dab726a23b757110897740e54304fc65", - "reference": "3dc03ca1dab726a23b757110897740e54304fc65", + "url": "https://api.github.com/repos/Nexmo/nexmo-php/zipball/2f79f67f24225ea627ee14578e98c96276cdd4c5", + "reference": "2f79f67f24225ea627ee14578e98c96276cdd4c5", "shasum": "" }, "require": { @@ -2514,7 +2514,7 @@ } ], "description": "PHP Client for using Nexmo's API.", - "time": "2019-01-02T09:06:47+00:00" + "time": "2019-02-07T11:14:34+00:00" }, { "name": "opis/closure", @@ -3523,16 +3523,16 @@ }, { "name": "symfony/console", - "version": "v4.2.2", + "version": "v4.2.3", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "b0a03c1bb0fcbe288629956cf2f1dd3f1dc97522" + "reference": "1f0ad51dfde4da8a6070f06adc58b4e37cbb37a4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/b0a03c1bb0fcbe288629956cf2f1dd3f1dc97522", - "reference": "b0a03c1bb0fcbe288629956cf2f1dd3f1dc97522", + "url": "https://api.github.com/repos/symfony/console/zipball/1f0ad51dfde4da8a6070f06adc58b4e37cbb37a4", + "reference": "1f0ad51dfde4da8a6070f06adc58b4e37cbb37a4", "shasum": "" }, "require": { @@ -3544,6 +3544,9 @@ "symfony/dependency-injection": "<3.4", "symfony/process": "<3.3" }, + "provide": { + "psr/log-implementation": "1.0" + }, "require-dev": { "psr/log": "~1.0", "symfony/config": "~3.4|~4.0", @@ -3553,7 +3556,7 @@ "symfony/process": "~3.4|~4.0" }, "suggest": { - "psr/log-implementation": "For using the console logger", + "psr/log": "For using the console logger", "symfony/event-dispatcher": "", "symfony/lock": "", "symfony/process": "" @@ -3588,7 +3591,7 @@ ], "description": "Symfony Console Component", "homepage": "https://symfony.com", - "time": "2019-01-04T15:13:53+00:00" + "time": "2019-01-25T14:35:16+00:00" }, { "name": "symfony/contracts", @@ -3660,16 +3663,16 @@ }, { "name": "symfony/css-selector", - "version": "v4.2.2", + "version": "v4.2.3", "source": { "type": "git", "url": "https://github.com/symfony/css-selector.git", - "reference": "76dac1dbe2830213e95892c7c2ec1edd74113ea4" + "reference": "48eddf66950fa57996e1be4a55916d65c10c604a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/css-selector/zipball/76dac1dbe2830213e95892c7c2ec1edd74113ea4", - "reference": "76dac1dbe2830213e95892c7c2ec1edd74113ea4", + "url": "https://api.github.com/repos/symfony/css-selector/zipball/48eddf66950fa57996e1be4a55916d65c10c604a", + "reference": "48eddf66950fa57996e1be4a55916d65c10c604a", "shasum": "" }, "require": { @@ -3709,20 +3712,20 @@ ], "description": "Symfony CssSelector Component", "homepage": "https://symfony.com", - "time": "2019-01-03T09:07:35+00:00" + "time": "2019-01-16T20:31:39+00:00" }, { "name": "symfony/debug", - "version": "v4.2.2", + "version": "v4.2.3", "source": { "type": "git", "url": "https://github.com/symfony/debug.git", - "reference": "64cb33c81e37d19b7715d4a6a4d49c1c382066dd" + "reference": "cf9b2e33f757deb884ce474e06d2647c1c769b65" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/debug/zipball/64cb33c81e37d19b7715d4a6a4d49c1c382066dd", - "reference": "64cb33c81e37d19b7715d4a6a4d49c1c382066dd", + "url": "https://api.github.com/repos/symfony/debug/zipball/cf9b2e33f757deb884ce474e06d2647c1c769b65", + "reference": "cf9b2e33f757deb884ce474e06d2647c1c769b65", "shasum": "" }, "require": { @@ -3765,20 +3768,20 @@ ], "description": "Symfony Debug Component", "homepage": "https://symfony.com", - "time": "2019-01-03T09:07:35+00:00" + "time": "2019-01-25T14:35:16+00:00" }, { "name": "symfony/event-dispatcher", - "version": "v4.2.2", + "version": "v4.2.3", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "887de6d34c86cf0cb6cbf910afb170cdb743cb5e" + "reference": "bd09ad265cd50b2b9d09d65ce6aba2d29bc81fe1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/887de6d34c86cf0cb6cbf910afb170cdb743cb5e", - "reference": "887de6d34c86cf0cb6cbf910afb170cdb743cb5e", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/bd09ad265cd50b2b9d09d65ce6aba2d29bc81fe1", + "reference": "bd09ad265cd50b2b9d09d65ce6aba2d29bc81fe1", "shasum": "" }, "require": { @@ -3829,20 +3832,20 @@ ], "description": "Symfony EventDispatcher Component", "homepage": "https://symfony.com", - "time": "2019-01-05T16:37:49+00:00" + "time": "2019-01-16T20:35:37+00:00" }, { "name": "symfony/finder", - "version": "v4.2.2", + "version": "v4.2.3", "source": { "type": "git", "url": "https://github.com/symfony/finder.git", - "reference": "9094d69e8c6ee3fe186a0ec5a4f1401e506071ce" + "reference": "ef71816cbb264988bb57fe6a73f610888b9aa70c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/9094d69e8c6ee3fe186a0ec5a4f1401e506071ce", - "reference": "9094d69e8c6ee3fe186a0ec5a4f1401e506071ce", + "url": "https://api.github.com/repos/symfony/finder/zipball/ef71816cbb264988bb57fe6a73f610888b9aa70c", + "reference": "ef71816cbb264988bb57fe6a73f610888b9aa70c", "shasum": "" }, "require": { @@ -3878,20 +3881,20 @@ ], "description": "Symfony Finder Component", "homepage": "https://symfony.com", - "time": "2019-01-03T09:07:35+00:00" + "time": "2019-01-16T20:35:37+00:00" }, { "name": "symfony/http-foundation", - "version": "v4.2.2", + "version": "v4.2.3", "source": { "type": "git", "url": "https://github.com/symfony/http-foundation.git", - "reference": "a633d422a09242064ba24e44a6e1494c5126de86" + "reference": "8d2318b73e0a1bc75baa699d00ebe2ae8b595a39" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-foundation/zipball/a633d422a09242064ba24e44a6e1494c5126de86", - "reference": "a633d422a09242064ba24e44a6e1494c5126de86", + "url": "https://api.github.com/repos/symfony/http-foundation/zipball/8d2318b73e0a1bc75baa699d00ebe2ae8b595a39", + "reference": "8d2318b73e0a1bc75baa699d00ebe2ae8b595a39", "shasum": "" }, "require": { @@ -3932,20 +3935,20 @@ ], "description": "Symfony HttpFoundation Component", "homepage": "https://symfony.com", - "time": "2019-01-05T16:37:49+00:00" + "time": "2019-01-29T09:49:29+00:00" }, { "name": "symfony/http-kernel", - "version": "v4.2.2", + "version": "v4.2.3", "source": { "type": "git", "url": "https://github.com/symfony/http-kernel.git", - "reference": "83de6543328917c18d5498eeb6bb6d36f7aab31b" + "reference": "d56b1706abaa771eb6acd894c6787cb88f1dc97d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-kernel/zipball/83de6543328917c18d5498eeb6bb6d36f7aab31b", - "reference": "83de6543328917c18d5498eeb6bb6d36f7aab31b", + "url": "https://api.github.com/repos/symfony/http-kernel/zipball/d56b1706abaa771eb6acd894c6787cb88f1dc97d", + "reference": "d56b1706abaa771eb6acd894c6787cb88f1dc97d", "shasum": "" }, "require": { @@ -4021,7 +4024,7 @@ ], "description": "Symfony HttpKernel Component", "homepage": "https://symfony.com", - "time": "2019-01-06T16:19:23+00:00" + "time": "2019-02-03T12:47:33+00:00" }, { "name": "symfony/polyfill-ctype", @@ -4305,16 +4308,16 @@ }, { "name": "symfony/process", - "version": "v4.2.2", + "version": "v4.2.3", "source": { "type": "git", "url": "https://github.com/symfony/process.git", - "reference": "ea043ab5d8ed13b467a9087d81cb876aee7f689a" + "reference": "6c05edb11fbeff9e2b324b4270ecb17911a8b7ad" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/process/zipball/ea043ab5d8ed13b467a9087d81cb876aee7f689a", - "reference": "ea043ab5d8ed13b467a9087d81cb876aee7f689a", + "url": "https://api.github.com/repos/symfony/process/zipball/6c05edb11fbeff9e2b324b4270ecb17911a8b7ad", + "reference": "6c05edb11fbeff9e2b324b4270ecb17911a8b7ad", "shasum": "" }, "require": { @@ -4350,7 +4353,7 @@ ], "description": "Symfony Process Component", "homepage": "https://symfony.com", - "time": "2019-01-03T14:48:52+00:00" + "time": "2019-01-24T22:05:03+00:00" }, { "name": "symfony/psr-http-message-bridge", @@ -4415,16 +4418,16 @@ }, { "name": "symfony/routing", - "version": "v4.2.2", + "version": "v4.2.3", "source": { "type": "git", "url": "https://github.com/symfony/routing.git", - "reference": "e69b7a13a0b58af378a49b49dd7084462de16cee" + "reference": "7f8e44fc498972466f0841c3e48dc555f23bdf53" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/routing/zipball/e69b7a13a0b58af378a49b49dd7084462de16cee", - "reference": "e69b7a13a0b58af378a49b49dd7084462de16cee", + "url": "https://api.github.com/repos/symfony/routing/zipball/7f8e44fc498972466f0841c3e48dc555f23bdf53", + "reference": "7f8e44fc498972466f0841c3e48dc555f23bdf53", "shasum": "" }, "require": { @@ -4488,20 +4491,20 @@ "uri", "url" ], - "time": "2019-01-03T09:07:35+00:00" + "time": "2019-01-29T09:49:29+00:00" }, { "name": "symfony/translation", - "version": "v4.2.2", + "version": "v4.2.3", "source": { "type": "git", "url": "https://github.com/symfony/translation.git", - "reference": "939fb792d73f2ce80e6ae9019d205fc480f1c9a0" + "reference": "23fd7aac70d99a17a8e6473a41fec8fab3331050" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/translation/zipball/939fb792d73f2ce80e6ae9019d205fc480f1c9a0", - "reference": "939fb792d73f2ce80e6ae9019d205fc480f1c9a0", + "url": "https://api.github.com/repos/symfony/translation/zipball/23fd7aac70d99a17a8e6473a41fec8fab3331050", + "reference": "23fd7aac70d99a17a8e6473a41fec8fab3331050", "shasum": "" }, "require": { @@ -4561,20 +4564,20 @@ ], "description": "Symfony Translation Component", "homepage": "https://symfony.com", - "time": "2019-01-03T09:07:35+00:00" + "time": "2019-01-27T23:11:39+00:00" }, { "name": "symfony/var-dumper", - "version": "v4.2.2", + "version": "v4.2.3", "source": { "type": "git", "url": "https://github.com/symfony/var-dumper.git", - "reference": "85bde661b178173d85c6f11ea9d03b61d1212bb2" + "reference": "223bda89f9be41cf7033eeaf11bc61a280489c17" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/var-dumper/zipball/85bde661b178173d85c6f11ea9d03b61d1212bb2", - "reference": "85bde661b178173d85c6f11ea9d03b61d1212bb2", + "url": "https://api.github.com/repos/symfony/var-dumper/zipball/223bda89f9be41cf7033eeaf11bc61a280489c17", + "reference": "223bda89f9be41cf7033eeaf11bc61a280489c17", "shasum": "" }, "require": { @@ -4637,7 +4640,7 @@ "debug", "dump" ], - "time": "2019-01-03T09:07:35+00:00" + "time": "2019-01-30T11:44:30+00:00" }, { "name": "tijsverkoyen/css-to-inline-styles", @@ -5624,16 +5627,16 @@ }, { "name": "mockery/mockery", - "version": "1.2.0", + "version": "1.2.1", "source": { "type": "git", "url": "https://github.com/mockery/mockery.git", - "reference": "100633629bf76d57430b86b7098cd6beb996a35a" + "reference": "dc4f10b6b1148744facb784015e4b339d7feec23" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/mockery/mockery/zipball/100633629bf76d57430b86b7098cd6beb996a35a", - "reference": "100633629bf76d57430b86b7098cd6beb996a35a", + "url": "https://api.github.com/repos/mockery/mockery/zipball/dc4f10b6b1148744facb784015e4b339d7feec23", + "reference": "dc4f10b6b1148744facb784015e4b339d7feec23", "shasum": "" }, "require": { @@ -5642,7 +5645,7 @@ "php": ">=5.6.0" }, "require-dev": { - "phpunit/phpunit": "~5.7.10|~6.5|~7.0" + "phpunit/phpunit": "~5.7.10|~6.5|~7.0|~8.0" }, "type": "library", "extra": { @@ -5685,7 +5688,7 @@ "test double", "testing" ], - "time": "2018-10-02T21:52:37+00:00" + "time": "2019-02-08T14:43:54+00:00" }, { "name": "myclabs/deep-copy", @@ -6389,16 +6392,16 @@ }, { "name": "phpunit/phpunit", - "version": "7.5.3", + "version": "7.5.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "2cb759721e53bc05f56487f628c6b9fbb6c18746" + "reference": "2896657da5fb237bc316bdfc18c2650efeee0dc0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/2cb759721e53bc05f56487f628c6b9fbb6c18746", - "reference": "2cb759721e53bc05f56487f628c6b9fbb6c18746", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/2896657da5fb237bc316bdfc18c2650efeee0dc0", + "reference": "2896657da5fb237bc316bdfc18c2650efeee0dc0", "shasum": "" }, "require": { @@ -6469,7 +6472,7 @@ "testing", "xunit" ], - "time": "2019-02-01T05:24:07+00:00" + "time": "2019-02-07T14:15:04+00:00" }, { "name": "roave/security-advisories", @@ -6477,12 +6480,12 @@ "source": { "type": "git", "url": "https://github.com/Roave/SecurityAdvisories.git", - "reference": "db876706aacd4ffbd1c253358d19a651e50e65c2" + "reference": "344bf4ed1263c75e7f96b87b80c52e8373561e19" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Roave/SecurityAdvisories/zipball/db876706aacd4ffbd1c253358d19a651e50e65c2", - "reference": "db876706aacd4ffbd1c253358d19a651e50e65c2", + "url": "https://api.github.com/repos/Roave/SecurityAdvisories/zipball/344bf4ed1263c75e7f96b87b80c52e8373561e19", + "reference": "344bf4ed1263c75e7f96b87b80c52e8373561e19", "shasum": "" }, "conflict": { @@ -6517,8 +6520,8 @@ "doctrine/mongodb-odm-bundle": ">=2,<3.0.1", "doctrine/orm": ">=2,<2.4.8|>=2.5,<2.5.1", "dompdf/dompdf": ">=0.6,<0.6.2", - "drupal/core": ">=7,<7.60|>=8,<8.5.8|>=8.6,<8.6.2", - "drupal/drupal": ">=7,<7.60|>=8,<8.5.8|>=8.6,<8.6.2", + "drupal/core": ">=7,<7.62|>=8,<8.5.9|>=8.6,<8.6.6", + "drupal/drupal": ">=7,<7.62|>=8,<8.5.9|>=8.6,<8.6.6", "erusev/parsedown": "<1.7", "ezsystems/ezpublish-kernel": ">=5.3,<5.3.12.1|>=5.4,<5.4.13.1|>=6,<6.7.9.1|>=6.8,<6.13.5.1|>=7,<7.2.4.1|>=7.3,<7.3.2.1", "ezsystems/ezpublish-legacy": ">=5.3,<5.3.12.6|>=5.4,<5.4.12.3|>=2011,<2017.12.4.3|>=2018.6,<2018.6.1.4|>=2018.9,<2018.9.1.3", @@ -6615,7 +6618,7 @@ "symfony/yaml": ">=2,<2.0.22|>=2.1,<2.1.7", "tecnickcom/tcpdf": "<6.2.22", "thelia/backoffice-default-template": ">=2.1,<2.1.2", - "thelia/thelia": ">=2.1.0-beta1,<2.1.3|>=2.1,<2.1.2", + "thelia/thelia": ">=2.1,<2.1.2|>=2.1.0-beta1,<2.1.3", "theonedemon/phpwhois": "<=4.2.5", "titon/framework": ">=0,<9.9.99", "truckersmp/phpwhois": "<=4.3.1", @@ -6673,7 +6676,7 @@ } ], "description": "Prevents installation of composer packages with known security vulnerabilities: no API, simply require it", - "time": "2019-01-22T18:37:22+00:00" + "time": "2019-02-05T19:58:17+00:00" }, { "name": "sebastian/code-unit-reverse-lookup", @@ -6786,23 +6789,23 @@ }, { "name": "sebastian/diff", - "version": "3.0.1", + "version": "3.0.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "366541b989927187c4ca70490a35615d3fef2dce" + "reference": "720fcc7e9b5cf384ea68d9d930d480907a0c1a29" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/366541b989927187c4ca70490a35615d3fef2dce", - "reference": "366541b989927187c4ca70490a35615d3fef2dce", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/720fcc7e9b5cf384ea68d9d930d480907a0c1a29", + "reference": "720fcc7e9b5cf384ea68d9d930d480907a0c1a29", "shasum": "" }, "require": { "php": "^7.1" }, "require-dev": { - "phpunit/phpunit": "^7.0", + "phpunit/phpunit": "^7.5 || ^8.0", "symfony/process": "^2 || ^3.3 || ^4" }, "type": "library", @@ -6838,7 +6841,7 @@ "unidiff", "unified diff" ], - "time": "2018-06-10T07:54:39+00:00" + "time": "2019-02-04T06:01:07+00:00" }, { "name": "sebastian/environment", @@ -7336,16 +7339,16 @@ }, { "name": "symfony/config", - "version": "v4.2.2", + "version": "v4.2.3", "source": { "type": "git", "url": "https://github.com/symfony/config.git", - "reference": "a7a7d0a0244cfc82f040729ccf769e6cf55a78fb" + "reference": "25a2e7abe0d97e70282537292e3df45cf6da7b98" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/config/zipball/a7a7d0a0244cfc82f040729ccf769e6cf55a78fb", - "reference": "a7a7d0a0244cfc82f040729ccf769e6cf55a78fb", + "url": "https://api.github.com/repos/symfony/config/zipball/25a2e7abe0d97e70282537292e3df45cf6da7b98", + "reference": "25a2e7abe0d97e70282537292e3df45cf6da7b98", "shasum": "" }, "require": { @@ -7395,20 +7398,20 @@ ], "description": "Symfony Config Component", "homepage": "https://symfony.com", - "time": "2019-01-03T09:07:35+00:00" + "time": "2019-01-30T11:44:30+00:00" }, { "name": "symfony/filesystem", - "version": "v4.2.2", + "version": "v4.2.3", "source": { "type": "git", "url": "https://github.com/symfony/filesystem.git", - "reference": "c2ffd9a93f2d6c5be2f68a0aa7953cc229f871f8" + "reference": "7c16ebc2629827d4ec915a52ac809768d060a4ee" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/filesystem/zipball/c2ffd9a93f2d6c5be2f68a0aa7953cc229f871f8", - "reference": "c2ffd9a93f2d6c5be2f68a0aa7953cc229f871f8", + "url": "https://api.github.com/repos/symfony/filesystem/zipball/7c16ebc2629827d4ec915a52ac809768d060a4ee", + "reference": "7c16ebc2629827d4ec915a52ac809768d060a4ee", "shasum": "" }, "require": { @@ -7445,20 +7448,20 @@ ], "description": "Symfony Filesystem Component", "homepage": "https://symfony.com", - "time": "2019-01-03T09:07:35+00:00" + "time": "2019-01-16T20:35:37+00:00" }, { "name": "symfony/stopwatch", - "version": "v4.2.2", + "version": "v4.2.3", "source": { "type": "git", "url": "https://github.com/symfony/stopwatch.git", - "reference": "af62b35760fc92c8dbdce659b4eebdfe0e6a0472" + "reference": "b1a5f646d56a3290230dbc8edf2a0d62cda23f67" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/stopwatch/zipball/af62b35760fc92c8dbdce659b4eebdfe0e6a0472", - "reference": "af62b35760fc92c8dbdce659b4eebdfe0e6a0472", + "url": "https://api.github.com/repos/symfony/stopwatch/zipball/b1a5f646d56a3290230dbc8edf2a0d62cda23f67", + "reference": "b1a5f646d56a3290230dbc8edf2a0d62cda23f67", "shasum": "" }, "require": { @@ -7495,20 +7498,20 @@ ], "description": "Symfony Stopwatch Component", "homepage": "https://symfony.com", - "time": "2019-01-03T09:07:35+00:00" + "time": "2019-01-16T20:31:39+00:00" }, { "name": "symfony/yaml", - "version": "v4.2.2", + "version": "v4.2.3", "source": { "type": "git", "url": "https://github.com/symfony/yaml.git", - "reference": "d0aa6c0ea484087927b49fd513383a7d36190ca6" + "reference": "d461670ee145092b7e2a56c1da7118f19cadadb0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/yaml/zipball/d0aa6c0ea484087927b49fd513383a7d36190ca6", - "reference": "d0aa6c0ea484087927b49fd513383a7d36190ca6", + "url": "https://api.github.com/repos/symfony/yaml/zipball/d461670ee145092b7e2a56c1da7118f19cadadb0", + "reference": "d461670ee145092b7e2a56c1da7118f19cadadb0", "shasum": "" }, "require": { @@ -7554,7 +7557,7 @@ ], "description": "Symfony Yaml Component", "homepage": "https://symfony.com", - "time": "2019-01-03T09:07:35+00:00" + "time": "2019-01-16T20:35:37+00:00" }, { "name": "theseer/tokenizer", diff --git a/database/migrations/2019_01_28_193833_changes_for_v4710.php b/database/migrations/2019_01_28_193833_changes_for_v4710.php index f1edfb3b6e..cce324b8c1 100644 --- a/database/migrations/2019_01_28_193833_changes_for_v4710.php +++ b/database/migrations/2019_01_28_193833_changes_for_v4710.php @@ -1,5 +1,27 @@ . + */ + +declare(strict_types=1); + use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; diff --git a/database/migrations/2019_02_05_055516_changes_for_v4711.php b/database/migrations/2019_02_05_055516_changes_for_v4711.php index 365d67df24..e89902f9e8 100644 --- a/database/migrations/2019_02_05_055516_changes_for_v4711.php +++ b/database/migrations/2019_02_05_055516_changes_for_v4711.php @@ -1,5 +1,27 @@ . + */ + +declare(strict_types=1); + use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; diff --git a/index.php b/index.php index d588e4711a..cced70fbd1 100644 --- a/index.php +++ b/index.php @@ -1,4 +1,25 @@ . + */ + declare(strict_types=1); /** * index.php diff --git a/resources/lang/en_US/import.php b/resources/lang/en_US/import.php index d067dd066c..3f19501654 100644 --- a/resources/lang/en_US/import.php +++ b/resources/lang/en_US/import.php @@ -31,11 +31,9 @@ return [ 'prerequisites_breadcrumb_ynab' => 'Prerequisites for YNAB', 'job_configuration_breadcrumb' => 'Configuration for ":key"', 'job_status_breadcrumb' => 'Import status for ":key"', - 'cannot_create_for_provider' => 'Firefly III cannot create a job for the ":provider"-provider.', 'disabled_for_demo_user' => 'disabled in demo', // index page: - 'general_index_title' => 'Import a file', 'general_index_intro' => 'Welcome to Firefly III\'s import routine. There are a few ways of importing data into Firefly III, displayed here as buttons.', // import provider strings (index): @@ -50,9 +48,6 @@ return [ 'button_fints' => 'Import using FinTS', - // global config box (index) - 'global_config_title' => 'Global import configuration', - 'global_config_text' => 'In the future, this box will feature preferences that apply to ALL import providers above.', // prerequisites box (index) 'need_prereq_title' => 'Import prerequisites', 'need_prereq_intro' => 'Some import methods need your attention before they can be used. For example, they might require special API keys or application secrets. You can configure them here. The icon indicates if these prerequisites have been met.', @@ -65,17 +60,6 @@ return [ 'do_prereq_quovo' => 'Prerequisites for imports using Quovo', 'do_prereq_ynab' => 'Prerequisites for imports from YNAB', - // provider config box (index) - 'can_config_title' => 'Import configuration', - 'can_config_intro' => 'Some import methods can be configured to your liking. They have extra settings you can tweak.', - 'do_config_fake' => 'Configuration for the fake provider', - 'do_config_file' => 'Configuration for file imports', - 'do_config_bunq' => 'Configuration for bunq imports', - 'do_config_spectre' => 'Configuration for imports from Spectre', - 'do_config_plaid' => 'Configuration for imports from Plaid', - 'do_config_yodlee' => 'Configuration for imports from Yodlee', - 'do_config_quovo' => 'Configuration for imports from Quovo', - // prerequisites: 'prereq_fake_title' => 'Prerequisites for an import from the fake import provider', 'prereq_fake_text' => 'This fake provider requires a fake API key. It must be 32 characters long. You can use this one: 123456789012345678901234567890AA', @@ -138,7 +122,6 @@ return [ 'spectre_login_new_login' => 'Login with another bank, or one of these banks with different credentials.', 'job_config_spectre_accounts_title' => 'Select accounts to import from', 'job_config_spectre_accounts_text' => 'You have selected ":name" (:country). You have :count account(s) available from this provider. Please select the Firefly III asset account(s) where the transactions from these accounts should be stored. Remember, in order to import data both the Firefly III account and the ":name"-account must have the same currency.', - 'spectre_no_supported_accounts' => 'You cannot import from this account due to a currency mismatch.', 'spectre_do_not_import' => '(do not import)', 'spectre_no_mapping' => 'It seems you have not selected any accounts to import from.', 'imported_from_account' => 'Imported from ":account"', diff --git a/resources/views/v1/import/index.twig b/resources/views/v1/import/index.twig index 3416c481ab..addef3857a 100644 --- a/resources/views/v1/import/index.twig +++ b/resources/views/v1/import/index.twig @@ -38,20 +38,6 @@
- {# -
-
-
-

{{ trans('import.global_config_title') }}

-
-
-

- {{ trans('import.global_config_text') }} -

-
-
-
- #}
@@ -78,60 +64,7 @@
- {# -
-
-
-

{{ trans('import.can_config_title') }}

-
-
-

- {{ trans('import.can_config_title') }} -

- -
-
-
- #}
- {% endblock %} {% block scripts %} {% endblock %} diff --git a/resources/views/v2/auth/passwords/email.twig b/resources/views/v2/auth/passwords/email.twig index a772966eea..3d096e7acf 100644 --- a/resources/views/v2/auth/passwords/email.twig +++ b/resources/views/v2/auth/passwords/email.twig @@ -5,7 +5,7 @@