Various PSR12 code cleanup

This commit is contained in:
James Cole 2022-12-29 19:43:43 +01:00
parent 56b9b66352
commit 5b8e01fbfb
No known key found for this signature in database
GPG Key ID: B49A324B7EAD6D80
240 changed files with 8059 additions and 7895 deletions

View File

@ -21,7 +21,6 @@
declare(strict_types=1); declare(strict_types=1);
use Illuminate\Contracts\View\Factory as ViewFactory;
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
| Create The Application | Create The Application

View File

@ -87,7 +87,6 @@ use FireflyIII\TransactionRules\Actions\SetSourceAccount;
use FireflyIII\TransactionRules\Actions\UpdatePiggybank; use FireflyIII\TransactionRules\Actions\UpdatePiggybank;
use FireflyIII\User; use FireflyIII\User;
/* /*
* DO NOT EDIT THIS FILE. IT IS AUTO GENERATED. * DO NOT EDIT THIS FILE. IT IS AUTO GENERATED.
* *

View File

@ -44,7 +44,7 @@ return [
'username' => env('MAIL_USERNAME'), 'username' => env('MAIL_USERNAME'),
'password' => env('MAIL_PASSWORD'), 'password' => env('MAIL_PASSWORD'),
'timeout' => null, 'timeout' => null,
'verify_peer' => null !== env('MAIL_ENCRYPTION') 'verify_peer' => null !== env('MAIL_ENCRYPTION'),
], ],
'ses' => [ 'ses' => [

View File

@ -1,4 +1,5 @@
<?php <?php
declare(strict_types=1); declare(strict_types=1);
return [ return [

View File

@ -174,19 +174,42 @@ return [
'Form' => ['is_safe' => ['input', 'select', 'checkbox', 'model', 'open', 'radio', 'textarea', 'file']], 'Form' => ['is_safe' => ['input', 'select', 'checkbox', 'model', 'open', 'radio', 'textarea', 'file']],
'ExpandedForm' => [ 'ExpandedForm' => [
'is_safe' => [ 'is_safe' => [
'date', 'text', 'select', 'balance', 'optionsList', 'checkbox', 'amount', 'tags', 'integer', 'textarea', 'location', 'file', 'staticText', 'date',
'password', 'nonSelectableAmount', 'number', 'amountNoCurrency', 'percentage', 'objectGroup', 'text',
'select',
'balance',
'optionsList',
'checkbox',
'amount',
'tags',
'integer',
'textarea',
'location',
'file',
'staticText',
'password',
'nonSelectableAmount',
'number',
'amountNoCurrency',
'percentage',
'objectGroup',
], ],
], ],
'AccountForm' => [ 'AccountForm' => [
'is_safe' => [ 'is_safe' => [
'activeWithdrawalDestinations', 'activeDepositDestinations', 'assetAccountCheckList', 'assetAccountList', 'longAccountList', 'activeWithdrawalDestinations',
'activeDepositDestinations',
'assetAccountCheckList',
'assetAccountList',
'longAccountList',
], ],
], ],
'CurrencyForm' => [ 'CurrencyForm' => [
'is_safe' => [ 'is_safe' => [
'currencyList', 'currencyListEmpty', 'balanceAll', 'currencyList',
'currencyListEmpty',
'balanceAll',
], ],
], ],
'PiggyBankForm' => [ 'PiggyBankForm' => [
@ -196,7 +219,8 @@ return [
], ],
'RuleForm' => [ 'RuleForm' => [
'is_safe' => [ 'is_safe' => [
'ruleGroupList', 'ruleGroupListWithEmpty', 'ruleGroupList',
'ruleGroupListWithEmpty',
], ],
], ],
], ],

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* 2016_06_16_000000_create_support_tables.php * 2016_06_16_000000_create_support_tables.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* 2016_06_16_000001_create_users_table.php * 2016_06_16_000001_create_users_table.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* 2016_06_16_000002_create_main_tables.php * 2016_06_16_000002_create_main_tables.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* 2016_08_25_091522_changes_for_3101.php * 2016_08_25_091522_changes_for_3101.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* 2016_09_12_121359_fix_nullables.php * 2016_09_12_121359_fix_nullables.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* 2016_10_09_150037_expand_transactions_table.php * 2016_10_09_150037_expand_transactions_table.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* 2016_10_22_075804_changes_for_v410.php * 2016_10_22_075804_changes_for_v410.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* 2016_11_24_210552_changes_for_v420.php * 2016_11_24_210552_changes_for_v420.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* 2016_12_22_150431_changes_for_v430.php * 2016_12_22_150431_changes_for_v430.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* 2016_12_28_203205_changes_for_v431.php * 2016_12_28_203205_changes_for_v431.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* 2017_04_13_163623_changes_for_v440.php * 2017_04_13_163623_changes_for_v440.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* 2017_06_02_105232_changes_for_v450.php * 2017_06_02_105232_changes_for_v450.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* 2017_08_20_062014_changes_for_v470.php * 2017_08_20_062014_changes_for_v470.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* 2017_11_04_170844_changes_for_v470a.php * 2017_11_04_170844_changes_for_v470a.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -48,7 +48,8 @@ class CreateOauthAuthCodesTable extends Migration
public function up(): void public function up(): void
{ {
Schema::create( Schema::create(
'oauth_auth_codes', static function (Blueprint $table) { 'oauth_auth_codes',
static function (Blueprint $table) {
$table->string('id', 100)->primary(); $table->string('id', 100)->primary();
$table->integer('user_id'); $table->integer('user_id');
$table->integer('client_id'); $table->integer('client_id');

View File

@ -48,7 +48,8 @@ class CreateOauthAccessTokensTable extends Migration
public function up(): void public function up(): void
{ {
Schema::create( Schema::create(
'oauth_access_tokens', static function (Blueprint $table) { 'oauth_access_tokens',
static function (Blueprint $table) {
$table->string('id', 100)->primary(); $table->string('id', 100)->primary();
$table->integer('user_id')->index()->nullable(); $table->integer('user_id')->index()->nullable();
$table->integer('client_id'); $table->integer('client_id');

View File

@ -48,7 +48,8 @@ class CreateOauthRefreshTokensTable extends Migration
public function up(): void public function up(): void
{ {
Schema::create( Schema::create(
'oauth_refresh_tokens', static function (Blueprint $table) { 'oauth_refresh_tokens',
static function (Blueprint $table) {
$table->string('id', 100)->primary(); $table->string('id', 100)->primary();
$table->string('access_token_id', 100)->index(); $table->string('access_token_id', 100)->index();
$table->boolean('revoked'); $table->boolean('revoked');

View File

@ -48,7 +48,8 @@ class CreateOauthClientsTable extends Migration
public function up(): void public function up(): void
{ {
Schema::create( Schema::create(
'oauth_clients', static function (Blueprint $table) { 'oauth_clients',
static function (Blueprint $table) {
$table->increments('id'); $table->increments('id');
$table->integer('user_id')->index()->nullable(); $table->integer('user_id')->index()->nullable();
$table->string('name'); $table->string('name');

View File

@ -48,7 +48,8 @@ class CreateOauthPersonalAccessClientsTable extends Migration
public function up(): void public function up(): void
{ {
Schema::create( Schema::create(
'oauth_personal_access_clients', static function (Blueprint $table) { 'oauth_personal_access_clients',
static function (Blueprint $table) {
$table->increments('id'); $table->increments('id');
$table->integer('client_id')->index(); $table->integer('client_id')->index();
$table->timestamps(); $table->timestamps();

View File

@ -43,7 +43,6 @@ class ChangesForV473 extends Migration
Schema::table( Schema::table(
'bills', 'bills',
static function (Blueprint $table) { static function (Blueprint $table) {
// cannot drop foreign keys in SQLite: // cannot drop foreign keys in SQLite:
if ('sqlite' !== config('database.default')) { if ('sqlite' !== config('database.default')) {
$table->dropForeign('bills_transaction_currency_id_foreign'); $table->dropForeign('bills_transaction_currency_id_foreign');

View File

@ -44,7 +44,6 @@ class ChangesForV474 extends Migration
Schema::table( Schema::table(
'import_jobs', 'import_jobs',
static function (Blueprint $table) { static function (Blueprint $table) {
// cannot drop foreign keys in SQLite: // cannot drop foreign keys in SQLite:
if ('sqlite' !== config('database.default')) { if ('sqlite' !== config('database.default')) {
$table->dropForeign('import_jobs_tag_id_foreign'); $table->dropForeign('import_jobs_tag_id_foreign');

View File

@ -56,7 +56,8 @@ class ChangesForV475 extends Migration
public function up(): void public function up(): void
{ {
Schema::create( Schema::create(
'recurrences', static function (Blueprint $table) { 'recurrences',
static function (Blueprint $table) {
$table->increments('id'); $table->increments('id');
$table->timestamps(); $table->timestamps();
$table->softDeletes(); $table->softDeletes();
@ -80,7 +81,8 @@ class ChangesForV475 extends Migration
); );
Schema::create( Schema::create(
'recurrences_transactions', static function (Blueprint $table) { 'recurrences_transactions',
static function (Blueprint $table) {
$table->increments('id'); $table->increments('id');
$table->timestamps(); $table->timestamps();
$table->softDeletes(); $table->softDeletes();
@ -103,7 +105,8 @@ class ChangesForV475 extends Migration
); );
Schema::create( Schema::create(
'recurrences_repetitions', static function (Blueprint $table) { 'recurrences_repetitions',
static function (Blueprint $table) {
$table->increments('id'); $table->increments('id');
$table->timestamps(); $table->timestamps();
$table->softDeletes(); $table->softDeletes();
@ -118,7 +121,8 @@ class ChangesForV475 extends Migration
); );
Schema::create( Schema::create(
'recurrences_meta', static function (Blueprint $table) { 'recurrences_meta',
static function (Blueprint $table) {
$table->increments('id'); $table->increments('id');
$table->timestamps(); $table->timestamps();
$table->softDeletes(); $table->softDeletes();
@ -132,7 +136,8 @@ class ChangesForV475 extends Migration
); );
Schema::create( Schema::create(
'rt_meta', static function (Blueprint $table) { 'rt_meta',
static function (Blueprint $table) {
$table->increments('id'); $table->increments('id');
$table->timestamps(); $table->timestamps();
$table->softDeletes(); $table->softDeletes();

View File

@ -40,8 +40,8 @@ class ChangesForV477 extends Migration
public function down(): void public function down(): void
{ {
Schema::table( Schema::table(
'budget_limits', static function (Blueprint $table) { 'budget_limits',
static function (Blueprint $table) {
// cannot drop foreign keys in SQLite: // cannot drop foreign keys in SQLite:
if ('sqlite' !== config('database.default')) { if ('sqlite' !== config('database.default')) {
$table->dropForeign('budget_limits_transaction_currency_id_foreign'); $table->dropForeign('budget_limits_transaction_currency_id_foreign');

View File

@ -40,7 +40,8 @@ class ChangesForV479 extends Migration
public function down() public function down()
{ {
Schema::table( Schema::table(
'transaction_currencies', static function (Blueprint $table) { 'transaction_currencies',
static function (Blueprint $table) {
$table->dropColumn(['enabled']); $table->dropColumn(['enabled']);
} }
); );

View File

@ -54,7 +54,8 @@ class ChangesForV4710 extends Migration
{ {
if (!Schema::hasTable('transaction_groups')) { if (!Schema::hasTable('transaction_groups')) {
Schema::create( Schema::create(
'transaction_groups', static function (Blueprint $table) { 'transaction_groups',
static function (Blueprint $table) {
$table->increments('id'); $table->increments('id');
$table->timestamps(); $table->timestamps();
$table->softDeletes(); $table->softDeletes();

View File

@ -60,13 +60,15 @@ class ChangesForV4711 extends Migration
* nice. * nice.
*/ */
Schema::table( Schema::table(
'transaction_journals', static function (Blueprint $table) { 'transaction_journals',
static function (Blueprint $table) {
$table->dateTime('date')->change(); $table->dateTime('date')->change();
} }
); );
Schema::table( Schema::table(
'preferences', static function (Blueprint $table) { 'preferences',
static function (Blueprint $table) {
$table->text('data')->nullable()->change(); $table->text('data')->nullable()->change();
} }
); );

View File

@ -59,7 +59,8 @@ class ChangesForV4712 extends Migration
* nice. * nice.
*/ */
Schema::table( Schema::table(
'transaction_journals', static function (Blueprint $table) { 'transaction_journals',
static function (Blueprint $table) {
$table->dateTime('date')->change(); $table->dateTime('date')->change();
} }
); );

View File

@ -40,7 +40,8 @@ class FixLdapConfiguration extends Migration
public function down(): void public function down(): void
{ {
Schema::table( Schema::table(
'users', static function (Blueprint $table) { 'users',
static function (Blueprint $table) {
$table->dropColumn(['objectguid']); $table->dropColumn(['objectguid']);
} }
); );
@ -59,7 +60,8 @@ class FixLdapConfiguration extends Migration
* now. To support this, we add the column. * now. To support this, we add the column.
*/ */
Schema::table( Schema::table(
'users', static function (Blueprint $table) { 'users',
static function (Blueprint $table) {
$table->uuid('objectguid')->nullable()->after('id'); $table->uuid('objectguid')->nullable()->after('id');
} }
); );

View File

@ -50,13 +50,15 @@ class ChangesForV480 extends Migration
} }
); );
Schema::table( Schema::table(
'rule_groups', static function (Blueprint $table) { 'rule_groups',
static function (Blueprint $table) {
$table->dropColumn('stop_processing'); $table->dropColumn('stop_processing');
} }
); );
Schema::table( Schema::table(
'users', static function (Blueprint $table) { 'users',
static function (Blueprint $table) {
$table->dropColumn('mfa_secret'); $table->dropColumn('mfa_secret');
} }
); );
@ -84,12 +86,14 @@ class ChangesForV480 extends Migration
} }
); );
Schema::table( Schema::table(
'rule_groups', static function (Blueprint $table) { 'rule_groups',
static function (Blueprint $table) {
$table->boolean('stop_processing')->default(false); $table->boolean('stop_processing')->default(false);
} }
); );
Schema::table( Schema::table(
'users', static function (Blueprint $table) { 'users',
static function (Blueprint $table) {
$table->string('mfa_secret', 50)->nullable(); $table->string('mfa_secret', 50)->nullable();
} }
); );

View File

@ -51,7 +51,8 @@ class MakeLocationsTable extends Migration
public function up() public function up()
{ {
Schema::create( Schema::create(
'locations', static function (Blueprint $table) { 'locations',
static function (Blueprint $table) {
$table->bigIncrements('id'); $table->bigIncrements('id');
$table->timestamps(); $table->timestamps();
$table->softDeletes(); $table->softDeletes();

View File

@ -52,7 +52,8 @@ class ChangesForV530 extends Migration
{ {
if (!Schema::hasTable('object_groups')) { if (!Schema::hasTable('object_groups')) {
Schema::create( Schema::create(
'object_groups', static function (Blueprint $table) { 'object_groups',
static function (Blueprint $table) {
$table->increments('id'); $table->increments('id');
$table->integer('user_id', false, true); $table->integer('user_id', false, true);
$table->timestamps(); $table->timestamps();
@ -65,7 +66,8 @@ class ChangesForV530 extends Migration
} }
if (!Schema::hasTable('object_groupables')) { if (!Schema::hasTable('object_groupables')) {
Schema::create( Schema::create(
'object_groupables', static function (Blueprint $table) { 'object_groupables',
static function (Blueprint $table) {
$table->integer('object_group_id'); $table->integer('object_group_id');
$table->integer('object_groupable_id', false, true); $table->integer('object_groupable_id', false, true);
$table->string('object_groupable_type', 255); $table->string('object_groupable_type', 255);

View File

@ -41,7 +41,8 @@ class ChangesForV530a extends Migration
public function down(): void public function down(): void
{ {
Schema::table( Schema::table(
'bills', static function (Blueprint $table) { 'bills',
static function (Blueprint $table) {
$table->dropColumn('order'); $table->dropColumn('order');
} }
); );
@ -55,7 +56,8 @@ class ChangesForV530a extends Migration
public function up(): void public function up(): void
{ {
Schema::table( Schema::table(
'bills', static function (Blueprint $table) { 'bills',
static function (Blueprint $table) {
$table->integer('order', false, true)->default(0); $table->integer('order', false, true)->default(0);
} }
); );

View File

@ -41,19 +41,22 @@ class ChangesForV540 extends Migration
public function down(): void public function down(): void
{ {
Schema::table( Schema::table(
'oauth_clients', static function (Blueprint $table) { 'oauth_clients',
static function (Blueprint $table) {
$table->dropColumn('provider'); $table->dropColumn('provider');
} }
); );
Schema::table( Schema::table(
'accounts', static function (Blueprint $table) { 'accounts',
static function (Blueprint $table) {
$table->dropColumn('order'); $table->dropColumn('order');
} }
); );
Schema::table( Schema::table(
'bills', static function (Blueprint $table) { 'bills',
static function (Blueprint $table) {
$table->dropColumn('end_date'); $table->dropColumn('end_date');
$table->dropColumn('extension_date'); $table->dropColumn('extension_date');
} }
@ -68,24 +71,28 @@ class ChangesForV540 extends Migration
public function up(): void public function up(): void
{ {
Schema::table( Schema::table(
'accounts', static function (Blueprint $table) { 'accounts',
static function (Blueprint $table) {
$table->integer('order', false, true)->default(0); $table->integer('order', false, true)->default(0);
} }
); );
Schema::table( Schema::table(
'oauth_clients', static function (Blueprint $table) { 'oauth_clients',
static function (Blueprint $table) {
$table->string('provider')->nullable(); $table->string('provider')->nullable();
} }
); );
Schema::table( Schema::table(
'bills', static function (Blueprint $table) { 'bills',
static function (Blueprint $table) {
$table->date('end_date')->nullable()->after('date'); $table->date('end_date')->nullable()->after('date');
$table->date('extension_date')->nullable()->after('end_date'); $table->date('extension_date')->nullable()->after('end_date');
} }
); );
// make column nullable: // make column nullable:
Schema::table( Schema::table(
'oauth_clients', function (Blueprint $table) { 'oauth_clients',
function (Blueprint $table) {
$table->string('secret', 100)->nullable()->change(); $table->string('secret', 100)->nullable()->change();
} }
); );

View File

@ -58,7 +58,8 @@ class ChangesForV550 extends Migration
// expand budget / transaction journal table. // expand budget / transaction journal table.
Schema::table( Schema::table(
'budget_transaction_journal', function (Blueprint $table) { 'budget_transaction_journal',
function (Blueprint $table) {
$table->dropForeign('budget_id_foreign'); $table->dropForeign('budget_id_foreign');
$table->dropColumn('budget_limit_id'); $table->dropColumn('budget_limit_id');
} }
@ -91,7 +92,8 @@ class ChangesForV550 extends Migration
Schema::dropIfExists('jobs'); Schema::dropIfExists('jobs');
// this is the NEW table // this is the NEW table
Schema::create( Schema::create(
'jobs', function (Blueprint $table) { 'jobs',
function (Blueprint $table) {
$table->bigIncrements('id'); $table->bigIncrements('id');
$table->string('queue')->index(); $table->string('queue')->index();
$table->longText('payload'); $table->longText('payload');
@ -106,7 +108,8 @@ class ChangesForV550 extends Migration
// create new failed_jobs table. // create new failed_jobs table.
Schema::create( Schema::create(
'failed_jobs', function (Blueprint $table) { 'failed_jobs',
function (Blueprint $table) {
$table->bigIncrements('id'); $table->bigIncrements('id');
$table->string('uuid')->unique(); $table->string('uuid')->unique();
$table->text('connection'); $table->text('connection');
@ -119,7 +122,8 @@ class ChangesForV550 extends Migration
// update budget / transaction journal table. // update budget / transaction journal table.
Schema::table( Schema::table(
'budget_transaction_journal', function (Blueprint $table) { 'budget_transaction_journal',
function (Blueprint $table) {
if (!Schema::hasColumn('budget_transaction_journal', 'budget_limit_id')) { if (!Schema::hasColumn('budget_transaction_journal', 'budget_limit_id')) {
$table->integer('budget_limit_id', false, true)->nullable()->default(null)->after('budget_id'); $table->integer('budget_limit_id', false, true)->nullable()->default(null)->after('budget_id');
$table->foreign('budget_limit_id', 'budget_id_foreign')->references('id')->on('budget_limits')->onDelete('set null'); $table->foreign('budget_limit_id', 'budget_id_foreign')->references('id')->on('budget_limits')->onDelete('set null');

View File

@ -39,13 +39,12 @@ class ChangesForV550b2 extends Migration
public function down(): void public function down(): void
{ {
Schema::table( Schema::table(
'recurrences_transactions', function (Blueprint $table) { 'recurrences_transactions',
function (Blueprint $table) {
$table->dropForeign('type_foreign'); $table->dropForeign('type_foreign');
if (Schema::hasColumn('recurrences_transactions', 'transaction_type_id')) { if (Schema::hasColumn('recurrences_transactions', 'transaction_type_id')) {
$table->dropColumn('transaction_type_id'); $table->dropColumn('transaction_type_id');
} }
} }
); );
} }
@ -59,7 +58,8 @@ class ChangesForV550b2 extends Migration
{ {
// expand recurrence transaction table // expand recurrence transaction table
Schema::table( Schema::table(
'recurrences_transactions', function (Blueprint $table) { 'recurrences_transactions',
function (Blueprint $table) {
if (!Schema::hasColumn('recurrences_transactions', 'transaction_type_id')) { if (!Schema::hasColumn('recurrences_transactions', 'transaction_type_id')) {
$table->integer('transaction_type_id', false, true)->nullable()->after('transaction_currency_id'); $table->integer('transaction_type_id', false, true)->nullable()->after('transaction_currency_id');
$table->foreign('transaction_type_id', 'type_foreign')->references('id')->on('transaction_types')->onDelete('set null'); $table->foreign('transaction_type_id', 'type_foreign')->references('id')->on('transaction_types')->onDelete('set null');

View File

@ -34,7 +34,8 @@ class AddLdapColumnsToUsersTable extends Migration
public function down() public function down()
{ {
Schema::table( Schema::table(
'users', function (Blueprint $table) { 'users',
function (Blueprint $table) {
$table->dropColumn(['domain']); $table->dropColumn(['domain']);
} }
); );
@ -46,7 +47,8 @@ class AddLdapColumnsToUsersTable extends Migration
public function up() public function up()
{ {
Schema::table( Schema::table(
'users', function (Blueprint $table) { 'users',
function (Blueprint $table) {
$table->string('domain')->nullable(); $table->string('domain')->nullable();
} }
); );

View File

@ -49,7 +49,8 @@ class ExtendCurrencyInfo extends Migration
public function up() public function up()
{ {
Schema::table( Schema::table(
'transaction_currencies', function (Blueprint $table) { 'transaction_currencies',
function (Blueprint $table) {
$table->string('code', 51)->change(); $table->string('code', 51)->change();
$table->string('symbol', 51)->change(); $table->string('symbol', 51)->change();
} }

View File

@ -32,8 +32,21 @@ use Illuminate\Support\Facades\Schema;
class UserGroups extends Migration class UserGroups extends Migration
{ {
private array $tables private array $tables
= ['accounts', 'attachments', 'available_budgets', 'bills', 'budgets', 'categories', 'recurrences', 'rule_groups', 'rules', 'tags', = [
'transaction_groups', 'transaction_journals', 'webhooks']; 'accounts',
'attachments',
'available_budgets',
'bills',
'budgets',
'categories',
'recurrences',
'rule_groups',
'rules',
'tags',
'transaction_groups',
'transaction_journals',
'webhooks',
];
/** /**
* Reverse the migrations. * Reverse the migrations.
@ -46,8 +59,8 @@ class UserGroups extends Migration
/** @var string $tableName */ /** @var string $tableName */
foreach ($this->tables as $tableName) { foreach ($this->tables as $tableName) {
Schema::table( Schema::table(
$tableName, function (Blueprint $table) use ($tableName) { $tableName,
function (Blueprint $table) use ($tableName) {
$table->dropForeign(sprintf('%s_to_ugi', $tableName)); $table->dropForeign(sprintf('%s_to_ugi', $tableName));
if (Schema::hasColumn($tableName, 'user_group_id')) { if (Schema::hasColumn($tableName, 'user_group_id')) {
$table->dropColumn('user_group_id'); $table->dropColumn('user_group_id');
@ -57,13 +70,12 @@ class UserGroups extends Migration
} }
Schema::table( Schema::table(
'users', function (Blueprint $table) { 'users',
function (Blueprint $table) {
$table->dropForeign('type_user_group_id'); $table->dropForeign('type_user_group_id');
if (Schema::hasColumn('users', 'user_group_id')) { if (Schema::hasColumn('users', 'user_group_id')) {
$table->dropColumn('user_group_id'); $table->dropColumn('user_group_id');
} }
} }
); );
@ -84,7 +96,8 @@ class UserGroups extends Migration
* may have multiple roles in a group * may have multiple roles in a group
*/ */
Schema::create( Schema::create(
'user_groups', static function (Blueprint $table) { 'user_groups',
static function (Blueprint $table) {
$table->bigIncrements('id'); $table->bigIncrements('id');
$table->timestamps(); $table->timestamps();
$table->softDeletes(); $table->softDeletes();
@ -95,7 +108,8 @@ class UserGroups extends Migration
); );
Schema::create( Schema::create(
'user_roles', static function (Blueprint $table) { 'user_roles',
static function (Blueprint $table) {
$table->bigIncrements('id'); $table->bigIncrements('id');
$table->timestamps(); $table->timestamps();
$table->softDeletes(); $table->softDeletes();
@ -122,7 +136,8 @@ class UserGroups extends Migration
} }
); );
Schema::table( Schema::table(
'users', function (Blueprint $table) { 'users',
function (Blueprint $table) {
if (!Schema::hasColumn('users', 'user_group_id')) { if (!Schema::hasColumn('users', 'user_group_id')) {
$table->bigInteger('user_group_id', false, true)->nullable(); $table->bigInteger('user_group_id', false, true)->nullable();
$table->foreign('user_group_id', 'type_user_group_id')->references('id')->on('user_groups')->onDelete('set null')->onUpdate('cascade'); $table->foreign('user_group_id', 'type_user_group_id')->references('id')->on('user_groups')->onDelete('set null')->onUpdate('cascade');
@ -134,15 +149,16 @@ class UserGroups extends Migration
/** @var string $tableName */ /** @var string $tableName */
foreach ($this->tables as $tableName) { foreach ($this->tables as $tableName) {
Schema::table( Schema::table(
$tableName, function (Blueprint $table) use ($tableName) { $tableName,
function (Blueprint $table) use ($tableName) {
if (!Schema::hasColumn($tableName, 'user_group_id')) { if (!Schema::hasColumn($tableName, 'user_group_id')) {
$table->bigInteger('user_group_id', false, true)->nullable()->after('user_id'); $table->bigInteger('user_group_id', false, true)->nullable()->after('user_id');
$table->foreign('user_group_id', sprintf('%s_to_ugi', $tableName))->references('id')->on('user_groups')->onDelete('set null')->onUpdate('cascade'); $table->foreign('user_group_id', sprintf('%s_to_ugi', $tableName))->references('id')->on('user_groups')->onDelete('set null')->onUpdate(
'cascade'
);
} }
} }
); );
} }
} }
} }

View File

@ -29,7 +29,7 @@ use Illuminate\Support\Facades\Schema;
/** /**
* *
*/ */
return new class extends Migration { return new class () extends Migration {
/** /**
* Run the migrations. * Run the migrations.
* *
@ -38,8 +38,8 @@ return new class extends Migration {
public function up(): void public function up(): void
{ {
Schema::table( Schema::table(
'currency_exchange_rates', function (Blueprint $table) { 'currency_exchange_rates',
function (Blueprint $table) {
if (!Schema::hasColumn('currency_exchange_rates', 'user_group_id')) { if (!Schema::hasColumn('currency_exchange_rates', 'user_group_id')) {
$table->bigInteger('user_group_id', false, true)->nullable()->after('user_id'); $table->bigInteger('user_group_id', false, true)->nullable()->after('user_id');
$table->foreign('user_group_id', 'cer_to_ugi')->references('id')->on('user_groups')->onDelete('set null')->onUpdate('cascade'); $table->foreign('user_group_id', 'cer_to_ugi')->references('id')->on('user_groups')->onDelete('set null')->onUpdate('cascade');
@ -56,8 +56,8 @@ return new class extends Migration {
public function down(): void public function down(): void
{ {
Schema::table( Schema::table(
'currency_exchange_rates', function (Blueprint $table) { 'currency_exchange_rates',
function (Blueprint $table) {
$table->dropForeign('cer_to_ugi'); $table->dropForeign('cer_to_ugi');
if (Schema::hasColumn('currency_exchange_rates', 'user_group_id')) { if (Schema::hasColumn('currency_exchange_rates', 'user_group_id')) {
$table->dropColumn('user_group_id'); $table->dropColumn('user_group_id');

View File

@ -26,8 +26,7 @@ use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint; use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema; use Illuminate\Support\Facades\Schema;
return new class extends Migration return new class () extends Migration {
{
/** /**
* Run the migrations. * Run the migrations.
* *

View File

@ -26,8 +26,7 @@ use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint; use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema; use Illuminate\Support\Facades\Schema;
return new class extends Migration return new class () extends Migration {
{
/** /**
* Run the migrations. * Run the migrations.
* *

View File

@ -26,8 +26,7 @@ use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint; use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema; use Illuminate\Support\Facades\Schema;
return new class extends Migration return new class () extends Migration {
{
/** /**
* Run the migrations. * Run the migrations.
* *

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* AccountTypeSeeder.php * AccountTypeSeeder.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* DatabaseSeeder.php * DatabaseSeeder.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* LinkTypeSeeder.php * LinkTypeSeeder.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* PermissionSeeder.php * PermissionSeeder.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* TransactionCurrencySeeder.php * TransactionCurrencySeeder.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -1,4 +1,5 @@
<?php <?php
/** /**
* TransactionTypeSeeder.php * TransactionTypeSeeder.php
* Copyright (c) 2019 james@firefly-iii.org. * Copyright (c) 2019 james@firefly-iii.org.

View File

@ -25,10 +25,12 @@ export default class Get {
let url = '/api/v1/categories/' + identifier; let url = '/api/v1/categories/' + identifier;
return api.get(url); return api.get(url);
} }
transactions(identifier, page, cacheKey) { transactions(identifier, page, cacheKey) {
let url = '/api/v1/categories/' + identifier + '/transactions'; let url = '/api/v1/categories/' + identifier + '/transactions';
return api.get(url, {params: {page: page, cache: cacheKey}}); return api.get(url, {params: {page: page, cache: cacheKey}});
} }
transactionsWithoutCategory(page, cacheKey) { transactionsWithoutCategory(page, cacheKey) {
let url = '/api/v1/categories/transactions-without-category'; let url = '/api/v1/categories/transactions-without-category';
return api.get(url, {params: {page: page, cache: cacheKey}}); return api.get(url, {params: {page: page, cache: cacheKey}});

View File

@ -25,6 +25,7 @@ export default class Get {
let url = '/api/v1/currencies/' + identifier; let url = '/api/v1/currencies/' + identifier;
return api.get(url); return api.get(url);
} }
transactions(identifier, page, cacheKey) { transactions(identifier, page, cacheKey) {
let url = '/api/v1/currencies/' + identifier + '/transactions'; let url = '/api/v1/currencies/' + identifier + '/transactions';
return api.get(url, {params: {page: page, cache: cacheKey}}); return api.get(url, {params: {page: page, cache: cacheKey}});

View File

@ -20,9 +20,12 @@
import {api} from "boot/axios"; import {api} from "boot/axios";
import Authenticate from '../authenticate/index'; import Authenticate from '../authenticate/index';
export default class Currencies { export default class Currencies {
default() { default() {
let auth = new Authenticate(); let auth = new Authenticate();
return auth.authenticate().then(() => {return api.get('/api/v1/currencies/default')}); return auth.authenticate().then(() => {
return api.get('/api/v1/currencies/default')
});
} }
} }

View File

@ -25,6 +25,7 @@ export default class Post {
let url = '/api/v1/currencies'; let url = '/api/v1/currencies';
return api.post(url, submission); return api.post(url, submission);
} }
makeDefault(currency) { makeDefault(currency) {
let url = '/api/v1/currencies/' + currency + '/default'; let url = '/api/v1/currencies/' + currency + '/default';
return api.post(url); return api.post(url);

View File

@ -25,6 +25,7 @@ export default class Get {
let url = '/api/v1/piggy_banks/' + identifier; let url = '/api/v1/piggy_banks/' + identifier;
return api.get(url); return api.get(url);
} }
transactions(identifier, page, cacheKey) { transactions(identifier, page, cacheKey) {
let url = '/api/v1/piggy_banks/' + identifier + '/transactions'; let url = '/api/v1/piggy_banks/' + identifier + '/transactions';
return api.get(url, {params: {page: page, cache: cacheKey}}); return api.get(url, {params: {page: page, cache: cacheKey}});

View File

@ -24,6 +24,7 @@ export default class Preferences {
getByName(name) { getByName(name) {
return api.get('/api/v1/preferences/' + name); return api.get('/api/v1/preferences/' + name);
} }
postByName(name, value) { postByName(name, value) {
return api.post('/api/v1/preferences', {name: name, data: value}); return api.post('/api/v1/preferences', {name: name, data: value});
} }

View File

@ -28,6 +28,7 @@ export default class Get {
} }
return api.get(url, {params: {date: date}}); return api.get(url, {params: {date: date}});
} }
rules(identifier, page, cacheKey) { rules(identifier, page, cacheKey) {
let url = '/api/v1/rule_groups/' + identifier + '/rules'; let url = '/api/v1/rule_groups/' + identifier + '/rules';
return api.get(url, {params: {page: page, cache: cacheKey}}); return api.get(url, {params: {page: page, cache: cacheKey}});

View File

@ -25,6 +25,7 @@ export default class Get {
let url = '/api/v1/bills/' + identifier; let url = '/api/v1/bills/' + identifier;
return api.get(url); return api.get(url);
} }
transactions(identifier, page, cacheKey) { transactions(identifier, page, cacheKey) {
let url = '/api/v1/bills/' + identifier + '/transactions'; let url = '/api/v1/bills/' + identifier + '/transactions';
return api.get(url, {params: {page: page, cache: cacheKey}}); return api.get(url, {params: {page: page, cache: cacheKey}});

View File

@ -1,4 +1,3 @@
/* /*
* configuration.js * configuration.js
* Copyright (c) 2022 james@firefly-iii.org * Copyright (c) 2022 james@firefly-iii.org

View File

@ -25,6 +25,7 @@ export default class Get {
let url = '/api/v1/tags/' + identifier; let url = '/api/v1/tags/' + identifier;
return api.get(url); return api.get(url);
} }
transactions(identifier, page, cacheKey) { transactions(identifier, page, cacheKey) {
let url = '/api/v1/tags/' + identifier + '/transactions'; let url = '/api/v1/tags/' + identifier + '/transactions';
return api.get(url, {params: {page: page, cache: cacheKey}}); return api.get(url, {params: {page: page, cache: cacheKey}});

View File

@ -38,6 +38,7 @@ export default class Get extends Api {
} }
return this.apiGet(identifier, params); return this.apiGet(identifier, params);
} }
transactions(identifier, params) { transactions(identifier, params) {
if (!params) { if (!params) {
return this.apiGetTransactions(identifier); return this.apiGetTransactions(identifier);

View File

@ -24,6 +24,7 @@ export default class Preferences {
get(name) { get(name) {
return api.get('/api/v2/preferences/' + name); return api.get('/api/v2/preferences/' + name);
} }
// postByName(name, value) { // postByName(name, value) {
// return api.post('/api/v1/preferences', {name: name, data: value}); // return api.post('/api/v1/preferences', {name: name, data: value});
// } // }

View File

@ -52,6 +52,7 @@ export default class Api {
} }
return api.get(url); return api.get(url);
} }
/** /**
* *
* @param object * @param object

View File

@ -19,14 +19,14 @@
--> -->
<template> <template>
<div class="q-ma-md" v-if="showAlert"> <div v-if="showAlert" class="q-ma-md">
<div class="row"> <div class="row">
<div class="col-12"> <div class="col-12">
<q-banner :class="alertClass" inline-actions> <q-banner :class="alertClass" inline-actions>
{{ message }} {{ message }}
<template v-slot:action> <template v-slot:action>
<q-btn flat @click="dismissBanner" color="white" label="Dismiss"/> <q-btn color="white" flat label="Dismiss" @click="dismissBanner"/>
<q-btn flat color="white" v-if="showAction" :to="actionLink" :label="actionText"/> <q-btn v-if="showAction" :label="actionText" :to="actionLink" color="white" flat/>
</template> </template>
</q-banner> </q-banner>
</div> </div>

View File

@ -33,18 +33,12 @@
</template> </template>
<script> <script>
import { import {computed, defineComponent, PropType, ref, Ref, toRef,} from 'vue';
defineComponent, import {Meta, Todo} from './models';
PropType,
computed,
ref,
toRef,
Ref,
} from 'vue';
import { Todo, Meta } from './models';
function useClickCount() { function useClickCount() {
const clickCount = ref(0); const clickCount = ref(0);
function increment() { function increment() {
clickCount.value += 1 clickCount.value += 1
return clickCount.value; return clickCount.value;

View File

@ -22,14 +22,15 @@
<div class="q-pa-xs"> <div class="q-pa-xs">
<div> <div>
<!-- <DatePicker v-model="range" is-range :is-dark="darkMode" :model-config="modelConfig"/> --> <!-- <DatePicker v-model="range" is-range :is-dark="darkMode" :model-config="modelConfig"/> -->
<q-date v-model="localRange" range minimal mask="YYYY-MM-DD"/> <q-date v-model="localRange" mask="YYYY-MM-DD" minimal range/>
</div> </div>
<div class="q-mt-xs"> <div class="q-mt-xs">
<span class="q-mr-xs"><q-btn @click="resetRange" size="sm" color="primary" label="Reset"/></span> <span class="q-mr-xs"><q-btn color="primary" label="Reset" size="sm" @click="resetRange"/></span>
<q-btn color="primary" size="sm" label="Change range" icon-right="fas fa-caret-down" title="More options in preferences"> <q-btn color="primary" icon-right="fas fa-caret-down" label="Change range" size="sm"
title="More options in preferences">
<q-menu> <q-menu>
<q-list style="min-width: 100px"> <q-list style="min-width: 100px">
<q-item clickable v-close-popup v-for="choice in rangeChoices" @click="setViewRange(choice)"> <q-item v-for="choice in rangeChoices" v-close-popup clickable @click="setViewRange(choice)">
<q-item-section>{{ $t('firefly.pref_' + choice.value) }}</q-item-section> <q-item-section>{{ $t('firefly.pref_' + choice.value) }}</q-item-section>
</q-item> </q-item>
</q-list> </q-list>

View File

@ -20,10 +20,10 @@
<template> <template>
<q-item <q-item
:href="link"
clickable clickable
tag="a" tag="a"
target="_blank" target="_blank"
:href="link"
> >
<q-item-section <q-item-section
v-if="icon" v-if="icon"

View File

@ -27,7 +27,7 @@
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-separator/> <q-separator/>
<ApexChart ref="chart" height="350" type="line" :options="options" :series="series"></ApexChart> <ApexChart ref="chart" :options="options" :series="series" height="350" type="line"></ApexChart>
</q-card> </q-card>
</div> </div>
<div> <div>

View File

@ -33,10 +33,10 @@
<q-card-section horizontal> <q-card-section horizontal>
<q-card-section> <q-card-section>
<q-circular-progress <q-circular-progress
:value="percentage"
size="50px"
:thickness="0.22" :thickness="0.22"
:value="percentage"
color="positive" color="positive"
size="50px"
track-color="negative" track-color="negative"
/> />
</q-card-section> </q-card-section>
@ -52,7 +52,9 @@
{{ formatAmount(item.code, item.sum) }}<span v-if="index+1 !== unpaid.length"> + </span></span> {{ formatAmount(item.code, item.sum) }}<span v-if="index+1 !== unpaid.length"> + </span></span>
</span> </span>
<br/> <br/>
<span v-if="paid.length > 0" :title="formatAmount(this.currency, this.paidAmount)">{{ $t('firefly.bills_paid') }}:</span> <span v-if="paid.length > 0" :title="formatAmount(this.currency, this.paidAmount)">{{
$t('firefly.bills_paid')
}}:</span>
<span v-for="(item, index) in paid"> <span v-for="(item, index) in paid">
<span :title="formatAmount(item.native_code, item.native_sum)"> <span :title="formatAmount(item.native_code, item.native_sum)">
{{ formatAmount(item.code, item.sum) }} {{ formatAmount(item.code, item.sum) }}

View File

@ -32,14 +32,16 @@
<q-separator/> <q-separator/>
<q-card-section horizontal> <q-card-section horizontal>
<q-card-section> <q-card-section>
<q-icon name="fas fa-chart-line" size="50px" :color="primary > 0 ? 'positive' : 'negative'"/> <q-icon :color="primary > 0 ? 'positive' : 'negative'" name="fas fa-chart-line" size="50px"/>
</q-card-section> </q-card-section>
<q-separator vertical/> <q-separator vertical/>
<q-card-section> <q-card-section>
<strong>{{ formatAmount(currency, primary) }}</strong><br/> <strong>{{ formatAmount(currency, primary) }}</strong><br/>
<small> <small>
<span v-for="(item, index) in netWorth"> <span v-for="(item, index) in netWorth">
<span :title="formatAmount(item.native_code, item.native_sum)">{{ formatAmount(item.code, item.sum) }}</span> <span :title="formatAmount(item.native_code, item.native_sum)">{{
formatAmount(item.code, item.sum)
}}</span>
<span v-if="index+1 !== netWorth.length"> + </span></span> <span v-if="index+1 !== netWorth.length"> + </span></span>
</small> </small>
</q-card-section> </q-card-section>
@ -120,7 +122,10 @@ export default {
}, },
// TODO this method is recycled a lot. // TODO this method is recycled a lot.
formatAmount: function (currencyCode, amount) { formatAmount: function (currencyCode, amount) {
return Intl.NumberFormat(this.store?.getLocale ?? 'en-US', {style: 'currency', currency: currencyCode}).format(amount); return Intl.NumberFormat(this.store?.getLocale ?? 'en-US', {
style: 'currency',
currency: currencyCode
}).format(amount);
}, },
}, },
} }

View File

@ -21,7 +21,7 @@
<template> <template>
<div class="row"> <div class="row">
<div class="col q-mb-xs"> <div class="col q-mb-xs">
<q-banner rounded class="bg-purple-8 text-white"> <q-banner class="bg-purple-8 text-white" rounded>
Hi! You must be new to Firefly III. Welcome! Please fill in this form to create some basic accounts and get you Hi! You must be new to Firefly III. Welcome! Please fill in this form to create some basic accounts and get you
started. started.
</q-banner> </q-banner>
@ -37,12 +37,12 @@
<div class="row q-mb-xs"> <div class="row q-mb-xs">
<div class="col-8 offset-2"> <div class="col-8 offset-2">
<q-input <q-input
:error-message="bank_name_error" v-model="bank_name"
:error="bank_name_has_error"
bottom-slots
:disable="disabledInput" :disable="disabledInput"
clearable :error="bank_name_has_error"
outlined v-model="bank_name" label="The name of your bank"> :error-message="bank_name_error"
bottom-slots
clearable label="The name of your bank" outlined>
<template v-slot:prepend> <template v-slot:prepend>
<q-icon name="fas fa-university"/> <q-icon name="fas fa-university"/>
</template> </template>
@ -52,23 +52,23 @@
<div class="row q-mb-xs"> <div class="row q-mb-xs">
<div class="col-3 offset-2"> <div class="col-3 offset-2">
<q-select <q-select
:error-message="currency_error" v-model="currency"
:error="currency_has_error"
bottom-slots
:disable="disabledInput" :disable="disabledInput"
outlined :error="currency_has_error"
v-model="currency" emit-value class="q-pr-xs" :error-message="currency_error"
map-options :options="currencies" label="Currency"/> :options="currencies"
bottom-slots class="q-pr-xs" emit-value
label="Currency" map-options outlined/>
</div> </div>
<div class="col-5"> <div class="col-5">
<q-input <q-input
:error-message="bank_balance_error" v-model="bank_balance"
:error="bank_balance_has_error"
bottom-slots
:disable="disabledInput" :disable="disabledInput"
outlined :error="bank_balance_has_error"
v-model="bank_balance" :mask="balance_input_mask" reverse-fill-mask fill-mask="0" :error-message="bank_balance_error"
label="Today's balance" hint="Enter your current balance"> :mask="balance_input_mask"
bottom-slots fill-mask="0" hint="Enter your current balance" label="Today's balance"
outlined reverse-fill-mask>
<template v-slot:prepend> <template v-slot:prepend>
<q-icon name="fas fa-money-bill-wave"/> <q-icon name="fas fa-money-bill-wave"/>
</template> </template>
@ -78,13 +78,13 @@
<div class="row q-mb-xs"> <div class="row q-mb-xs">
<div class="col-8 offset-2"> <div class="col-8 offset-2">
<q-input <q-input
:error-message="savings_balance_error" v-model="savings_balance"
:error="savings_balance_has_error"
bottom-slots
:disable="disabledInput" :disable="disabledInput"
outlined :error="savings_balance_has_error"
v-model="savings_balance" :mask="balance_input_mask" reverse-fill-mask fill-mask="0" :error-message="savings_balance_error"
label="Today's savings account balance" hint="Leave empty or set to zero if not relevant."> :mask="balance_input_mask"
bottom-slots fill-mask="0" hint="Leave empty or set to zero if not relevant." label="Today's savings account balance"
outlined reverse-fill-mask>
<template v-slot:prepend> <template v-slot:prepend>
<q-icon name="fas fa-coins"/> <q-icon name="fas fa-coins"/>
</template> </template>
@ -105,21 +105,21 @@
<div class="row q-mb-xs"> <div class="row q-mb-xs">
<div class="col-8 offset-2"> <div class="col-8 offset-2">
<q-select <q-select
:error-message="language_error" v-model="language"
:error="language_has_error"
bottom-slots
outlined
:disable="disabledInput" :disable="disabledInput"
v-model="language" emit-value :error="language_has_error"
map-options :options="languages" label="I prefer the following language"/> :error-message="language_error"
:options="languages"
bottom-slots emit-value
label="I prefer the following language" map-options outlined/>
</div> </div>
</div> </div>
<div class="row"> <div class="row">
<div class="col-10 offset-2"> <div class="col-10 offset-2">
<q-checkbox <q-checkbox
:disable="disabledInput" v-model="manage_cash"
v-model="manage_cash" label="I want to manage cash using Firefly III"/> :disable="disabledInput" label="I want to manage cash using Firefly III"/>
<q-banner v-if="manage_cash_has_error" class="text-white bg-red">{{ manage_cash_error }}</q-banner> <q-banner v-if="manage_cash_has_error" class="text-white bg-red">{{ manage_cash_error }}</q-banner>
</div> </div>
</div> </div>
@ -127,8 +127,8 @@
<div class="row"> <div class="row">
<div class="col-8 offset-2"> <div class="col-8 offset-2">
<q-checkbox <q-checkbox
:disable="disabledInput" v-model="have_cc"
v-model="have_cc" label="I have a credit card."/> :disable="disabledInput" label="I have a credit card."/>
<q-banner v-if="have_cc_has_error" class="text-white bg-red">{{ have_cc_error }}</q-banner> <q-banner v-if="have_cc_has_error" class="text-white bg-red">{{ have_cc_error }}</q-banner>
</div> </div>
</div> </div>
@ -136,8 +136,8 @@
<div class="row"> <div class="row">
<div class="col-8 offset-2"> <div class="col-8 offset-2">
<q-checkbox <q-checkbox
:disable="disabledInput" v-model="have_questions"
v-model="have_questions" label="I know where to go when I have questions"/> :disable="disabledInput" label="I know where to go when I have questions"/>
<div class="q-px-sm"> <div class="q-px-sm">
Hint: visit <a href="https://github.com/firefly-iii/firefly-iii/discussions/">GitHub</a> Hint: visit <a href="https://github.com/firefly-iii/firefly-iii/discussions/">GitHub</a>
or <a href="#">Gitter.im</a>. You can also or <a href="#">Gitter.im</a>. You can also

View File

@ -33,10 +33,10 @@
<q-card-section horizontal> <q-card-section horizontal>
<q-card-section> <q-card-section>
<q-circular-progress <q-circular-progress
:value="percentage"
size="50px"
:thickness="0.22" :thickness="0.22"
:value="percentage"
color="negative" color="negative"
size="50px"
track-color="positive" track-color="positive"
/> />
</q-card-section> </q-card-section>
@ -48,14 +48,20 @@
<span :title="formatAmount(this.currency, this.budgetedAmount)">{{ $t('firefly.budgeted') }}</span>: <span :title="formatAmount(this.currency, this.budgetedAmount)">{{ $t('firefly.budgeted') }}</span>:
<!-- list budgeted --> <!-- list budgeted -->
<span v-for="(item, index) in budgeted"> <span v-for="(item, index) in budgeted">
<span :title="formatAmount(item.native_code, item.native_sum)">{{ formatAmount(item.code, item.sum) }}</span> <span :title="formatAmount(item.native_code, item.native_sum)">{{
formatAmount(item.code, item.sum)
}}</span>
<span v-if="index+1 !== budgeted.length"> + </span> <span v-if="index+1 !== budgeted.length"> + </span>
</span> </span>
<br/> <br/>
<span v-if="spent.length > 0" :title="formatAmount(this.currency, this.spentAmount)">{{ $t('firefly.spent') }}: </span> <span v-if="spent.length > 0" :title="formatAmount(this.currency, this.spentAmount)">{{
$t('firefly.spent')
}}: </span>
<!-- list spent --> <!-- list spent -->
<span v-for="(item, index) in spent"> <span v-for="(item, index) in spent">
<span :title="formatAmount(item.native_code, item.native_sum)">{{ formatAmount(item.code, item.sum) }}</span> <span :title="formatAmount(item.native_code, item.native_sum)">{{
formatAmount(item.code, item.sum)
}}</span>
<span v-if="index+1 !== spent.length"> + </span></span> <span v-if="index+1 !== spent.length"> + </span></span>
</q-card-section> </q-card-section>
</q-card-section> </q-card-section>

View File

@ -52,8 +52,8 @@
{{ tr.description }} {{ tr.description }}
<br/> <br/>
</span> </span>
<router-link :to="{ name: 'transactions.show', params: {id: transaction.transactionGroupId} }" <router-link v-if="transaction.transactions.length === 1"
v-if="transaction.transactions.length === 1"> :to="{ name: 'transactions.show', params: {id: transaction.transactionGroupId} }">
{{ tr.description }} {{ tr.description }}
</router-link> </router-link>
</span> </span>
@ -86,8 +86,13 @@
<!-- show foreign amount if present and not converted (may lead to double amounts) --> <!-- show foreign amount if present and not converted (may lead to double amounts) -->
<span v-if="null !== tr.foreign_amount"> <span v-if="null !== tr.foreign_amount">
<span v-if="false === tr.foreign_currency_converted"> ({{ formatAmount(tr.foreign_currency_code, tr.foreign_amount) }})</span> <span v-if="false === tr.foreign_currency_converted"> ({{
<span v-if="true === tr.foreign_currency_converted" :title="formatAmount(tr.foreign_currency_code, tr.foreign_amount)"> ({{ formatAmount(tr.native_currency_code, tr.native_foreign_amount) }})</span> formatAmount(tr.foreign_currency_code, tr.foreign_amount)
}})</span>
<span v-if="true === tr.foreign_currency_converted"
:title="formatAmount(tr.foreign_currency_code, tr.foreign_amount)"> ({{
formatAmount(tr.native_currency_code, tr.native_foreign_amount)
}})</span>
</span> </span>
<br v-if="transaction.transactions.length > 1"/> <br v-if="transaction.transactions.length > 1"/>
</span> </span>

View File

@ -20,7 +20,7 @@
<template> <template>
<div class="row"> <div class="row">
<div class="col q-mr-sm" v-for="(account) in accounts"> <div v-for="(account) in accounts" class="col q-mr-sm">
<TransactionList :account-id="account"/> <TransactionList :account-id="account"/>
</div> </div>
</div> </div>

View File

@ -20,13 +20,13 @@
<template> <template>
<q-table <q-table
:title="title"
:rows="rows"
:columns="columns"
row-key="group_id"
v-model:pagination="pagination" v-model:pagination="pagination"
:columns="columns"
:loading="loading" :loading="loading"
:rows="rows"
:title="title"
class="q-ma-md" class="q-ma-md"
row-key="group_id"
@request="onRequest" @request="onRequest"
> >
<template v-slot:header="props"> <template v-slot:header="props">
@ -44,13 +44,13 @@
<template v-slot:body="props"> <template v-slot:body="props">
<q-tr :props="props"> <q-tr :props="props">
<q-td auto-width> <q-td auto-width>
<q-btn size="sm" v-if="props.row.splits.length > 1" round dense @click="props.expand = !props.expand" <q-btn v-if="props.row.splits.length > 1" :icon="props.expand ? 'fas fa-minus-circle' : 'fas fa-plus-circle'" dense round size="sm"
:icon="props.expand ? 'fas fa-minus-circle' : 'fas fa-plus-circle'"/> @click="props.expand = !props.expand"/>
</q-td> </q-td>
<q-td key="type" :props="props"> <q-td key="type" :props="props">
<q-icon class="fas fa-long-arrow-alt-right" v-if="'deposit' === props.row.type.toLowerCase()"></q-icon> <q-icon v-if="'deposit' === props.row.type.toLowerCase()" class="fas fa-long-arrow-alt-right"></q-icon>
<q-icon class="fas fa-long-arrow-alt-left" v-if="'withdrawal' === props.row.type.toLowerCase()"></q-icon> <q-icon v-if="'withdrawal' === props.row.type.toLowerCase()" class="fas fa-long-arrow-alt-left"></q-icon>
<q-icon class="fas fa-arrows-alt-h" v-if="'transfer' === props.row.type.toLowerCase()"></q-icon> <q-icon v-if="'transfer' === props.row.type.toLowerCase()" class="fas fa-arrows-alt-h"></q-icon>
</q-td> </q-td>
<q-td key="description" :props="props"> <q-td key="description" :props="props">
<router-link :to="{ name: 'transactions.show', params: {id: props.row.group_id} }" class="text-primary"> <router-link :to="{ name: 'transactions.show', params: {id: props.row.group_id} }" class="text-primary">
@ -79,12 +79,12 @@
<q-td key="menu" :props="props"> <q-td key="menu" :props="props">
<q-btn-dropdown color="primary" label="Actions" size="sm"> <q-btn-dropdown color="primary" label="Actions" size="sm">
<q-list> <q-list>
<q-item clickable v-close-popup :to="{name: 'transactions.edit', params: {id: props.row.group_id}}"> <q-item v-close-popup :to="{name: 'transactions.edit', params: {id: props.row.group_id}}" clickable>
<q-item-section> <q-item-section>
<q-item-label>Edit</q-item-label> <q-item-label>Edit</q-item-label>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-close-popup <q-item v-close-popup clickable
@click="deleteTransaction(props.row.group_id, props.row.description, props.row.group_title)"> @click="deleteTransaction(props.row.group_id, props.row.description, props.row.group_title)">
<q-item-section> <q-item-section>
<q-item-label>Delete</q-item-label> <q-item-label>Delete</q-item-label>
@ -94,7 +94,7 @@
</q-btn-dropdown> </q-btn-dropdown>
</q-td> </q-td>
</q-tr> </q-tr>
<q-tr v-show="props.expand" :props="props" v-for="currentRow in props.row.splits"> <q-tr v-for="currentRow in props.row.splits" v-show="props.expand" :props="props">
<q-td auto-width/> <q-td auto-width/>
<q-td auto-width/> <q-td auto-width/>
<q-td> <q-td>

View File

@ -24,38 +24,39 @@
<title><%= productName %></title> <title><%= productName %></title>
<meta charset="utf-8"> <meta charset="utf-8">
<meta name="description" content="<%= productDescription %>"> <meta content="<%= productDescription %>" name="description">
<meta name="format-detection" content="telephone=no"> <meta content="telephone=no" name="format-detection">
<meta name="msapplication-tap-highlight" content="no"> <meta content="no" name="msapplication-tap-highlight">
<meta name="viewport" content="user-scalable=no, initial-scale=1, maximum-scale=1, minimum-scale=1, width=device-width<% if (ctx.mode.cordova || ctx.mode.capacitor) { %>, viewport-fit=cover<% } %>"> <meta content="user-scalable=no, initial-scale=1, maximum-scale=1, minimum-scale=1, width=device-width<% if (ctx.mode.cordova || ctx.mode.capacitor) { %>, viewport-fit=cover<% } %>"
name="viewport">
<link rel="icon" type="image/png" sizes="32x32" href="favicon-32x32.png"> <link href="favicon-32x32.png" rel="icon" sizes="32x32" type="image/png">
<link rel="icon" type="image/png" sizes="16x16" href="favicon-16x16.png"> <link href="favicon-16x16.png" rel="icon" sizes="16x16" type="image/png">
<link rel="apple-touch-icon" sizes="76x76" href="maskable76.png"> <link href="maskable76.png" rel="apple-touch-icon" sizes="76x76">
<link rel="apple-touch-icon" sizes="120x120" href="maskable120.png"> <link href="maskable120.png" rel="apple-touch-icon" sizes="120x120">
<link rel="apple-touch-icon" sizes="152x152" href="maskable152.png"> <link href="maskable152.png" rel="apple-touch-icon" sizes="152x152">
<link rel="apple-touch-icon" sizes="180x180" href="apple-touch-icon.png"> <link href="apple-touch-icon.png" rel="apple-touch-icon" sizes="180x180">
<link rel="mask-icon" href="safari-pinned-tab.svg" color="#3c8dbc"> <link color="#3c8dbc" href="safari-pinned-tab.svg" rel="mask-icon">
<link href="maskable192.png" rel="icon" sizes="192x192"> <link href="maskable192.png" rel="icon" sizes="192x192">
<link href="maskable128.png" rel="icon" sizes="128x128"> <link href="maskable128.png" rel="icon" sizes="128x128">
<link rel="manifest" href="manifest.webmanifest"> <link href="manifest.webmanifest" rel="manifest">
<meta name="msapplication-TileColor" content="#1e6581"> <meta content="#1e6581" name="msapplication-TileColor">
<meta name="msapplication-TileImage" content="maskable512.png"> <meta content="maskable512.png" name="msapplication-TileImage">
<meta name="msapplication-tap-highlight" content="no"> <meta content="no" name="msapplication-tap-highlight">
<meta name="application-name" content="Firefly III"> <meta content="Firefly III" name="application-name">
<meta name="robots" content="noindex, nofollow, noarchive, noodp, NoImageIndex, noydir"> <meta content="noindex, nofollow, noarchive, noodp, NoImageIndex, noydir" name="robots">
<meta name="apple-mobile-web-app-capable" content="yes"> <meta content="yes" name="apple-mobile-web-app-capable">
<meta name="apple-mobile-web-app-title" content="Firefly III"> <meta content="Firefly III" name="apple-mobile-web-app-title">
<meta name="application-name" content="Firefly III"> <meta content="Firefly III" name="application-name">
<meta name="msapplication-TileColor" content="#3c8dbc"> <meta content="#3c8dbc" name="msapplication-TileColor">
<meta name="msapplication-TileImage" content="mstile-144x144.png?v=3e8AboOwbd"> <meta content="mstile-144x144.png?v=3e8AboOwbd" name="msapplication-TileImage">
<meta name="theme-color" content="#3c8dbc"> <meta content="#3c8dbc" name="theme-color">
</head> </head>
<body> <body>
<div id="q-app"></div> <div id="q-app"></div>

View File

@ -21,24 +21,24 @@
<template> <template>
<q-layout view="hHh lpR fFf"> <q-layout view="hHh lpR fFf">
<q-header elevated class="bg-primary text-white"> <q-header class="bg-primary text-white" elevated>
<q-toolbar> <q-toolbar>
<q-btn dense flat round icon="fas fa-bars" @click="toggleLeftDrawer"/> <q-btn dense flat icon="fas fa-bars" round @click="toggleLeftDrawer"/>
<q-toolbar-title> <q-toolbar-title>
<q-avatar> <q-avatar>
<img src="maskable-icon.svg" alt="Firefly III Logo" title="Firefly III"> <img alt="Firefly III Logo" src="maskable-icon.svg" title="Firefly III">
</q-avatar> </q-avatar>
Firefly III Firefly III
</q-toolbar-title> </q-toolbar-title>
<q-select <q-select
ref="search" dark dense standout use-input hide-selected ref="search" v-model="search" :stack-label="false" class="q-mx-xs" color="black" dark
class="q-mx-xs" dense
color="black" :stack-label="false" label="Search" hide-selected label="Search" standout
v-model="search"
style="width: 250px" style="width: 250px"
use-input
> >
<template v-slot:append> <template v-slot:append>
@ -47,8 +47,8 @@
<template v-slot:option="scope"> <template v-slot:option="scope">
<q-item <q-item
v-bind="scope.itemProps"
class="" class=""
v-bind="scope.itemProps"
> >
<q-item-section side> <q-item-section side>
<q-icon name="collections_bookmark"/> <q-icon name="collections_bookmark"/>
@ -56,8 +56,8 @@
<q-item-section> <q-item-section>
<q-item-label v-html="scope.opt.label"/> <q-item-label v-html="scope.opt.label"/>
</q-item-section> </q-item-section>
<q-item-section side class="default-type"> <q-item-section class="default-type" side>
<q-btn outline dense no-caps text-color="blue-grey-5" size="12px" class="bg-grey-1 q-px-sm"> <q-btn class="bg-grey-1 q-px-sm" dense no-caps outline size="12px" text-color="blue-grey-5">
{{ 'Jump to' }} {{ 'Jump to' }}
<q-icon name="subdirectory_arrow_left" size="14px"/> <q-icon name="subdirectory_arrow_left" size="14px"/>
</q-btn> </q-btn>
@ -66,49 +66,49 @@
</template> </template>
</q-select> </q-select>
<q-separator dark vertical inset/> <q-separator dark inset vertical/>
<q-btn flat icon="fas fa-skull-crossbones" :to="{name: 'development.index'}" class="q-mx-xs"/> <q-btn :to="{name: 'development.index'}" class="q-mx-xs" flat icon="fas fa-skull-crossbones"/>
<q-separator dark vertical inset/> <q-separator dark inset vertical/>
<q-btn flat icon="fas fa-question-circle" @click="showHelpBox" class="q-mx-xs"/> <q-btn class="q-mx-xs" flat icon="fas fa-question-circle" @click="showHelpBox"/>
<q-separator dark vertical inset/> <q-separator dark inset vertical/>
<!-- TODO notifications --> <!-- TODO notifications -->
<!-- date range --> <!-- date range -->
<q-btn v-if="$q.screen.gt.xs && $route.meta.dateSelector" flat class="q-mx-xs"> <q-btn v-if="$q.screen.gt.xs && $route.meta.dateSelector" class="q-mx-xs" flat>
<div class="row items-center no-wrap"> <div class="row items-center no-wrap">
<q-icon name="fas fa-calendar" size="20px"/> <q-icon name="fas fa-calendar" size="20px"/>
<q-icon name="fas fa-caret-down" size="12px" right/> <q-icon name="fas fa-caret-down" right size="12px"/>
</div> </div>
<q-menu> <q-menu>
<DateRange></DateRange> <DateRange></DateRange>
</q-menu> </q-menu>
</q-btn> </q-btn>
<q-separator dark vertical inset v-if="$route.meta.dateSelector"/> <q-separator v-if="$route.meta.dateSelector" dark inset vertical/>
<!-- specials --> <!-- specials -->
<q-btn v-if="$q.screen.gt.xs" flat class="q-mx-xs"> <q-btn v-if="$q.screen.gt.xs" class="q-mx-xs" flat>
<div class="row items-center no-wrap"> <div class="row items-center no-wrap">
<q-icon name="fas fa-dragon" size="20px"/> <q-icon name="fas fa-dragon" size="20px"/>
<q-icon name="fas fa-caret-down" size="12px" right/> <q-icon name="fas fa-caret-down" right size="12px"/>
</div> </div>
<q-menu auto-close> <q-menu auto-close>
<q-list style="min-width: 120px"> <q-list style="min-width: 120px">
<q-item clickable :to="{ name: 'webhooks.index' }"> <q-item :to="{ name: 'webhooks.index' }" clickable>
<q-item-section>Webhooks</q-item-section> <q-item-section>Webhooks</q-item-section>
</q-item> </q-item>
<q-item clickable :to="{ name: 'currencies.index' }"> <q-item :to="{ name: 'currencies.index' }" clickable>
<q-item-section>Currencies</q-item-section> <q-item-section>Currencies</q-item-section>
</q-item> </q-item>
<q-item clickable :to="{ name: 'admin.index' }"> <q-item :to="{ name: 'admin.index' }" clickable>
<q-item-section>Administration</q-item-section> <q-item-section>Administration</q-item-section>
</q-item> </q-item>
</q-list> </q-list>
</q-menu> </q-menu>
</q-btn> </q-btn>
<q-separator dark vertical inset/> <q-separator dark inset vertical/>
<!-- profile --> <!-- profile -->
<q-btn v-if="$q.screen.gt.xs" flat class="q-mx-xs"> <q-btn v-if="$q.screen.gt.xs" class="q-mx-xs" flat>
<div class="row items-center no-wrap"> <div class="row items-center no-wrap">
<q-icon name="fas fa-user-circle" size="20px"/> <q-icon name="fas fa-user-circle" size="20px"/>
<q-icon name="fas fa-caret-down" right size="12px"/> <q-icon name="fas fa-caret-down" right size="12px"/>
@ -116,20 +116,20 @@
<q-menu auto-close> <q-menu auto-close>
<q-list style="min-width: 180px"> <q-list style="min-width: 180px">
<q-item clickable :to="{ name: 'profile.index' }"> <q-item :to="{ name: 'profile.index' }" clickable>
<q-item-section> Profile</q-item-section> <q-item-section> Profile</q-item-section>
</q-item> </q-item>
<q-item clickable :to="{ name: 'profile.daa' }"> <q-item :to="{ name: 'profile.daa' }" clickable>
<q-item-section> Data management</q-item-section> <q-item-section> Data management</q-item-section>
</q-item> </q-item>
<q-item clickable :to="{ name: 'preferences.index' }"> <q-item :to="{ name: 'preferences.index' }" clickable>
<q-item-section>Preferences</q-item-section> <q-item-section>Preferences</q-item-section>
</q-item> </q-item>
<q-item clickable :to="{ name: 'export.index' }"> <q-item :to="{ name: 'export.index' }" clickable>
<q-item-section>Export data</q-item-section> <q-item-section>Export data</q-item-section>
</q-item> </q-item>
<q-separator/> <q-separator/>
<q-item clickable :to="{ name: 'logout' }"> <q-item :to="{ name: 'logout' }" clickable>
<q-item-section>Logout</q-item-section> <q-item-section>Logout</q-item-section>
</q-item> </q-item>
</q-list> </q-list>
@ -137,11 +137,11 @@
</q-btn> </q-btn>
</q-toolbar> </q-toolbar>
</q-header> </q-header>
<q-drawer show-if-above v-model="leftDrawerOpen" side="left" bordered> <q-drawer v-model="leftDrawerOpen" bordered show-if-above side="left">
<q-scroll-area class="fit"> <q-scroll-area class="fit">
<div class="q-pa-md"> <div class="q-pa-md">
<q-list> <q-list>
<q-item clickable v-ripple :to="{ name: 'index' }"> <q-item v-ripple :to="{ name: 'index' }" clickable>
<q-item-section avatar> <q-item-section avatar>
<q-icon name="fas fa-tachometer-alt"/> <q-icon name="fas fa-tachometer-alt"/>
</q-item-section> </q-item-section>
@ -149,7 +149,7 @@
Dashboard Dashboard
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-ripple :to="{ name: 'budgets.index' }"> <q-item v-ripple :to="{ name: 'budgets.index' }" clickable>
<q-item-section avatar> <q-item-section avatar>
<q-icon name="fas fa-chart-pie"/> <q-icon name="fas fa-chart-pie"/>
</q-item-section> </q-item-section>
@ -157,7 +157,7 @@
Budgets Budgets
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-ripple :to="{ name: 'subscriptions.index' }"> <q-item v-ripple :to="{ name: 'subscriptions.index' }" clickable>
<q-item-section avatar> <q-item-section avatar>
<q-icon name="far fa-calendar-alt"/> <q-icon name="far fa-calendar-alt"/>
</q-item-section> </q-item-section>
@ -165,7 +165,7 @@
Subscriptions Subscriptions
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-ripple :to="{ name: 'piggy-banks.index' }"> <q-item v-ripple :to="{ name: 'piggy-banks.index' }" clickable>
<q-item-section avatar> <q-item-section avatar>
<q-icon name="fas fa-piggy-bank"/> <q-icon name="fas fa-piggy-bank"/>
</q-item-section> </q-item-section>
@ -175,22 +175,25 @@
</q-item> </q-item>
<q-expansion-item <q-expansion-item
:default-opened="this.$route.name === 'transactions.index' || this.$route.name === 'transactions.show'"
expand-separator expand-separator
icon="fas fa-exchange-alt" icon="fas fa-exchange-alt"
label="Transactions" label="Transactions"
:default-opened="this.$route.name === 'transactions.index' || this.$route.name === 'transactions.show'"
> >
<q-item :inset-level="1" clickable v-ripple :to="{ name: 'transactions.index', params: {type: 'withdrawal'} }"> <q-item v-ripple :inset-level="1" :to="{ name: 'transactions.index', params: {type: 'withdrawal'} }"
clickable>
<q-item-section> <q-item-section>
Withdrawals Withdrawals
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-ripple :inset-level="1" :to="{ name: 'transactions.index', params: {type: 'deposit'} }"> <q-item v-ripple :inset-level="1" :to="{ name: 'transactions.index', params: {type: 'deposit'} }"
clickable>
<q-item-section> <q-item-section>
Deposits Deposits
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-ripple :inset-level="1" :to="{ name: 'transactions.index', params: {type: 'transfers'} }"> <q-item v-ripple :inset-level="1" :to="{ name: 'transactions.index', params: {type: 'transfers'} }"
clickable>
<q-item-section> <q-item-section>
Transfers Transfers
@ -202,17 +205,17 @@
<q-expansion-item <q-expansion-item
default-unopened
expand-separator expand-separator
icon="fas fa-microchip" icon="fas fa-microchip"
label="Automation" label="Automation"
default-unopened
> >
<q-item :inset-level="1" clickable v-ripple :to="{ name: 'rules.index' }"> <q-item v-ripple :inset-level="1" :to="{ name: 'rules.index' }" clickable>
<q-item-section> <q-item-section>
Rules Rules
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item :inset-level="1" clickable v-ripple :to="{ name: 'recurring.index' }"> <q-item v-ripple :inset-level="1" :to="{ name: 'recurring.index' }" clickable>
<q-item-section> <q-item-section>
Recurring transactions Recurring transactions
</q-item-section> </q-item-section>
@ -221,27 +224,28 @@
</q-expansion-item> </q-expansion-item>
<q-expansion-item <q-expansion-item
:default-opened="this.$route.name === 'accounts.index' || this.$route.name === 'accounts.show'"
expand-separator expand-separator
icon="fas fa-credit-card" icon="fas fa-credit-card"
label="Accounts" label="Accounts"
:default-opened="this.$route.name === 'accounts.index' || this.$route.name === 'accounts.show'"
> >
<q-item clickable v-ripple :inset-level="1" :to="{ name: 'accounts.index', params: {type: 'asset'} }"> <q-item v-ripple :inset-level="1" :to="{ name: 'accounts.index', params: {type: 'asset'} }" clickable>
<q-item-section> <q-item-section>
Asset accounts Asset accounts
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-ripple :inset-level="1" :to="{ name: 'accounts.index', params: {type: 'expense'} }"> <q-item v-ripple :inset-level="1" :to="{ name: 'accounts.index', params: {type: 'expense'} }" clickable>
<q-item-section> <q-item-section>
Expense accounts Expense accounts
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-ripple :inset-level="1" :to="{ name: 'accounts.index', params: {type: 'revenue'} }"> <q-item v-ripple :inset-level="1" :to="{ name: 'accounts.index', params: {type: 'revenue'} }" clickable>
<q-item-section> <q-item-section>
Revenue accounts Revenue accounts
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-ripple :inset-level="1" :to="{ name: 'accounts.index', params: {type: 'liabilities'} }"> <q-item v-ripple :inset-level="1" :to="{ name: 'accounts.index', params: {type: 'liabilities'} }"
clickable>
<q-item-section> <q-item-section>
Liabilities Liabilities
</q-item-section> </q-item-section>
@ -250,28 +254,28 @@
</q-expansion-item> </q-expansion-item>
<q-expansion-item <q-expansion-item
default-unopened
expand-separator expand-separator
icon="fas fa-tags" icon="fas fa-tags"
label="Classification" label="Classification"
default-unopened
> >
<q-item clickable v-ripple :inset-level="1" :to="{ name: 'categories.index' }"> <q-item v-ripple :inset-level="1" :to="{ name: 'categories.index' }" clickable>
<q-item-section> <q-item-section>
Categories Categories
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-ripple :inset-level="1" :to="{ name: 'tags.index' }"> <q-item v-ripple :inset-level="1" :to="{ name: 'tags.index' }" clickable>
<q-item-section> <q-item-section>
Tags Tags
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-ripple :inset-level="1" :to="{ name: 'groups.index'}"> <q-item v-ripple :inset-level="1" :to="{ name: 'groups.index'}" clickable>
<q-item-section> <q-item-section>
Groups Groups
</q-item-section> </q-item-section>
</q-item> </q-item>
</q-expansion-item> </q-expansion-item>
<q-item clickable v-ripple :to="{ name: 'reports.index'}"> <q-item v-ripple :to="{ name: 'reports.index'}" clickable>
<q-item-section avatar> <q-item-section avatar>
<q-icon name="far fa-chart-bar"/> <q-icon name="far fa-chart-bar"/>
</q-item-section> </q-item-section>
@ -296,7 +300,7 @@
</div> </div>
<div class="col-6"> <div class="col-6">
<q-breadcrumbs align="right"> <q-breadcrumbs align="right">
<q-breadcrumbs-el label="Home" :to="{ name: 'index' }"/> <q-breadcrumbs-el :to="{ name: 'index' }" label="Home"/>
<q-breadcrumbs-el v-for="step in $route.meta.breadcrumbs" :label="$t('breadcrumbs.' + step.title)" <q-breadcrumbs-el v-for="step in $route.meta.breadcrumbs" :label="$t('breadcrumbs.' + step.title)"
:to="step.route ? {name: step.route, params: step.params} : ''"/> :to="step.route ? {name: step.route, params: step.params} : ''"/>
</q-breadcrumbs> </q-breadcrumbs>
@ -307,7 +311,7 @@
<router-view/> <router-view/>
</q-page-container> </q-page-container>
<q-footer elevated class="bg-grey-8 text-white"> <q-footer class="bg-grey-8 text-white" elevated>
<q-toolbar> <q-toolbar>
<div> <div>
<small>Firefly III v TODO &copy; James Cole, AGPL-3.0-or-later.</small> <small>Firefly III v TODO &copy; James Cole, AGPL-3.0-or-later.</small>

View File

@ -32,11 +32,11 @@
<q-btn <q-btn
class="q-mt-xl" class="q-mt-xl"
color="white" color="white"
text-color="blue"
unelevated
to="/"
label="Go Home" label="Go Home"
no-caps no-caps
text-color="blue"
to="/"
unelevated
/> />
</div> </div>
</div> </div>

View File

@ -22,10 +22,10 @@
<q-page> <q-page>
<div class="row q-mx-md"> <div class="row q-mx-md">
<div class="col-12"> <div class="col-12">
<q-banner inline-actions rounded class="bg-orange text-white" v-if="'' !== errorMessage"> <q-banner v-if="'' !== errorMessage" class="bg-orange text-white" inline-actions rounded>
{{ errorMessage }} {{ errorMessage }}
<template v-slot:action> <template v-slot:action>
<q-btn flat @click="dismissBanner" label="Dismiss"/> <q-btn flat label="Dismiss" @click="dismissBanner"/>
</template> </template>
</q-banner> </q-banner>
</div> </div>
@ -40,22 +40,22 @@
<div class="row"> <div class="row">
<div class="col-12 q-mb-xs"> <div class="col-12 q-mb-xs">
<q-input <q-input
:error-message="submissionErrors.name" v-model="name"
:error="hasSubmissionErrors.name"
bottom-slots
:disable="disabledInput" :disable="disabledInput"
type="text" clearable v-model="name" :label="$t('form.name')" :error="hasSubmissionErrors.name"
outlined/> :error-message="submissionErrors.name"
:label="$t('form.name')" bottom-slots clearable outlined
type="text"/>
</div> </div>
</div> </div>
<div class="row"> <div class="row">
<div class="col-12 q-mb-xs"> <div class="col-12 q-mb-xs">
<q-input <q-input
:error-message="submissionErrors.iban" v-model="iban"
:disable="disabledInput"
:error="hasSubmissionErrors.iban" :error="hasSubmissionErrors.iban"
mask="AA## XXXX XXXX XXXX XXXX XXXX XXXX XXXX XX" :error-message="submissionErrors.iban" :label="$t('form.iban')" bottom-slots clearable mask="AA## XXXX XXXX XXXX XXXX XXXX XXXX XXXX XX" outlined
bottom-slots :disable="disabledInput" type="text" clearable v-model="iban" :label="$t('form.iban')" type="text"/>
outlined/>
</div> </div>
</div> </div>
</q-card-section> </q-card-section>
@ -74,9 +74,11 @@
</div> </div>
<div class="row"> <div class="row">
<div class="col-12 text-right"> <div class="col-12 text-right">
<q-checkbox :disable="disabledInput" v-model="doReturnHere" left-label label="Return here to create another one"/> <q-checkbox v-model="doReturnHere" :disable="disabledInput" label="Return here to create another one"
left-label/>
<br/> <br/>
<q-checkbox v-model="doResetForm" left-label :disable="!doReturnHere || disabledInput" label="Reset form after submission"/> <q-checkbox v-model="doResetForm" :disable="!doReturnHere || disabledInput" label="Reset form after submission"
left-label/>
</div> </div>
</div> </div>
</q-card-section> </q-card-section>

View File

@ -22,10 +22,10 @@
<q-page> <q-page>
<div class="row q-mx-md"> <div class="row q-mx-md">
<div class="col-12"> <div class="col-12">
<q-banner inline-actions rounded class="bg-orange text-white" v-if="'' !== errorMessage"> <q-banner v-if="'' !== errorMessage" class="bg-orange text-white" inline-actions rounded>
{{ errorMessage }} {{ errorMessage }}
<template v-slot:action> <template v-slot:action>
<q-btn flat @click="dismissBanner" label="Dismiss"/> <q-btn flat label="Dismiss" @click="dismissBanner"/>
</template> </template>
</q-banner> </q-banner>
</div> </div>
@ -40,20 +40,20 @@
<div class="row"> <div class="row">
<div class="col-12 q-mb-xs"> <div class="col-12 q-mb-xs">
<q-input <q-input
:error-message="submissionErrors.name" v-model="name"
:error="hasSubmissionErrors.name" :disable="disabledInput"
bottom-slots :disable="disabledInput" type="text" clearable v-model="name" :label="$t('form.name')" :error="hasSubmissionErrors.name" :error-message="submissionErrors.name" :label="$t('form.name')" bottom-slots clearable outlined
outlined/> type="text"/>
</div> </div>
</div> </div>
<div class="row"> <div class="row">
<div class="col-12 q-mb-xs"> <div class="col-12 q-mb-xs">
<q-input <q-input
:error-message="submissionErrors.iban" v-model="iban"
:disable="disabledInput"
:error="hasSubmissionErrors.iban" :error="hasSubmissionErrors.iban"
mask="AA## XXXX XXXX XXXX XXXX XXXX XXXX XXXX XX" :error-message="submissionErrors.iban" :label="$t('form.iban')" bottom-slots clearable mask="AA## XXXX XXXX XXXX XXXX XXXX XXXX XXXX XX" outlined
bottom-slots :disable="disabledInput" type="text" clearable v-model="iban" :label="$t('form.iban')" type="text"/>
outlined/>
</div> </div>
</div> </div>
</q-card-section> </q-card-section>
@ -72,7 +72,7 @@
</div> </div>
<div class="row"> <div class="row">
<div class="col-12 text-right"> <div class="col-12 text-right">
<q-checkbox :disable="disabledInput" v-model="doReturnHere" left-label label="Return here"/> <q-checkbox v-model="doReturnHere" :disable="disabledInput" label="Return here" left-label/>
</div> </div>
</div> </div>
</q-card-section> </q-card-section>

View File

@ -21,14 +21,14 @@
<template> <template>
<q-page> <q-page>
<q-table <q-table
:title="$t('firefly.' + this.type + '_accounts')"
:rows="rows"
:columns="columns"
row-key="id"
:dense="$q.screen.lt.md"
v-model:pagination="pagination" v-model:pagination="pagination"
:columns="columns"
:dense="$q.screen.lt.md"
:loading="loading" :loading="loading"
:rows="rows"
:title="$t('firefly.' + this.type + '_accounts')"
class="q-ma-md" class="q-ma-md"
row-key="id"
> >
<template v-slot:header="props"> <template v-slot:header="props">
<q-tr :props="props"> <q-tr :props="props">
@ -47,14 +47,14 @@
<router-link :to="{ name: 'accounts.show', params: {id: props.row.id} }" class="text-primary"> <router-link :to="{ name: 'accounts.show', params: {id: props.row.id} }" class="text-primary">
{{ props.row.name }} {{ props.row.name }}
</router-link> </router-link>
<q-popup-edit v-model="props.row.name" v-slot="scope"> <q-popup-edit v-slot="scope" v-model="props.row.name">
<q-input v-model="scope.value" dense autofocus counter /> <q-input v-model="scope.value" autofocus counter dense/>
</q-popup-edit> </q-popup-edit>
</q-td> </q-td>
<q-td key="iban" :props="props"> <q-td key="iban" :props="props">
{{ formatIban(props.row.iban) }} {{ formatIban(props.row.iban) }}
<q-popup-edit v-model="props.row.iban" v-slot="scope"> <q-popup-edit v-slot="scope" v-model="props.row.iban">
<q-input v-model="scope.value" dense autofocus counter /> <q-input v-model="scope.value" autofocus counter dense/>
</q-popup-edit> </q-popup-edit>
</q-td> </q-td>
<q-td key="current_balance" :props="props"> <q-td key="current_balance" :props="props">
@ -67,19 +67,20 @@
C C
</q-td> </q-td>
<q-td key="menu" :props="props"> <q-td key="menu" :props="props">
<q-btn-dropdown color="primary" :label="$t('firefly.actions')" size="sm"> <q-btn-dropdown :label="$t('firefly.actions')" color="primary" size="sm">
<q-list> <q-list>
<q-item clickable v-close-popup :to="{name: 'accounts.edit', params: {id: props.row.id}}"> <q-item v-close-popup :to="{name: 'accounts.edit', params: {id: props.row.id}}" clickable>
<q-item-section> <q-item-section>
<q-item-label>{{ $t('firefly.edit') }}</q-item-label> <q-item-label>{{ $t('firefly.edit') }}</q-item-label>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-close-popup :to="{name: 'accounts.reconcile', params: {id: props.row.id}}" v-if="'asset' === props.row.type"> <q-item v-if="'asset' === props.row.type" v-close-popup :to="{name: 'accounts.reconcile', params: {id: props.row.id}}"
clickable>
<q-item-section> <q-item-section>
<q-item-label>{{ $t('firefly.reconcile') }}</q-item-label> <q-item-label>{{ $t('firefly.reconcile') }}</q-item-label>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-close-popup @click="deleteAccount(props.row.id, props.row.name)"> <q-item v-close-popup clickable @click="deleteAccount(props.row.id, props.row.name)">
<q-item-section> <q-item-section>
<q-item-label>{{ $t('firefly.delete') }}</q-item-label> <q-item-label>{{ $t('firefly.delete') }}</q-item-label>
</q-item-section> </q-item-section>
@ -90,19 +91,20 @@
</q-tr> </q-tr>
</template> </template>
</q-table> </q-table>
<q-page-sticky position="bottom-right" :offset="[18, 18]"> <q-page-sticky :offset="[18, 18]" position="bottom-right">
<q-fab <q-fab
:label="$t('firefly.actions')" :label="$t('firefly.actions')"
color="green"
direction="up"
icon="fas fa-chevron-up"
label-position="left"
square square
vertical-actions-align="right" vertical-actions-align="right"
label-position="left"
color="green"
icon="fas fa-chevron-up"
direction="up"
> >
<!-- TODO --> <!-- TODO -->
<!--<q-fab-action color="primary" square :to="{ name: 'accounts.create', params: {type: 'liability'} }" icon="fas fa-long-arrow-alt-right" label="New liability"/>--> <!--<q-fab-action color="primary" square :to="{ name: 'accounts.create', params: {type: 'liability'} }" icon="fas fa-long-arrow-alt-right" label="New liability"/>-->
<q-fab-action color="primary" square :to="{ name: 'accounts.create', params: {type: 'asset'} }" icon="fas fa-exchange-alt" :label="$t('firefly.create_new_asset')"/> <q-fab-action :label="$t('firefly.create_new_asset')" :to="{ name: 'accounts.create', params: {type: 'asset'} }" color="primary"
icon="fas fa-exchange-alt" square/>
</q-fab> </q-fab>
</q-page-sticky> </q-page-sticky>
</q-page> </q-page>
@ -161,7 +163,6 @@ export default {
this.type = this.$route.params.type; this.type = this.$route.params.type;
if (null === this.store.getRange.start || null === this.store.getRange.end) { if (null === this.store.getRange.start || null === this.store.getRange.end) {
// subscribe, then update: // subscribe, then update:
this.store.$onAction( this.store.$onAction(

View File

@ -20,7 +20,7 @@
<template> <template>
<q-page> <q-page>
<div class="row q-mx-md" v-if="!canReconcile"> <div v-if="!canReconcile" class="row q-mx-md">
<div class="col-12"> <div class="col-12">
<q-card bordered> <q-card bordered>
<q-card-section> <q-card-section>
@ -38,28 +38,28 @@
<q-card-section> <q-card-section>
<div class="row"> <div class="row">
<div class="col-3 q-pr-xs"> <div class="col-3 q-pr-xs">
<q-input outlined v-model="startDate" hint="Start date" type="date" dense> <q-input v-model="startDate" dense hint="Start date" outlined type="date">
<template v-slot:prepend> <template v-slot:prepend>
<q-icon name="far fa-calendar"/> <q-icon name="far fa-calendar"/>
</template> </template>
</q-input> </q-input>
</div> </div>
<div class="col-3 q-px-xs"> <div class="col-3 q-px-xs">
<q-input outlined v-model="startBalance" hint="Start balance" step="0.00" type="number" dense> <q-input v-model="startBalance" dense hint="Start balance" outlined step="0.00" type="number">
<template v-slot:prepend> <template v-slot:prepend>
<q-icon name="fas fa-coins"/> <q-icon name="fas fa-coins"/>
</template> </template>
</q-input> </q-input>
</div> </div>
<div class="col-3"> <div class="col-3">
<q-input outlined v-model="endDate" hint="End date" type="date" dense> <q-input v-model="endDate" dense hint="End date" outlined type="date">
<template v-slot:prepend> <template v-slot:prepend>
<q-icon name="far fa-calendar"/> <q-icon name="far fa-calendar"/>
</template> </template>
</q-input> </q-input>
</div> </div>
<div class="col-3 q-px-xs"> <div class="col-3 q-px-xs">
<q-input outlined v-model="endBalance" hint="End Balance" step="0.00" type="number" dense> <q-input v-model="endBalance" dense hint="End Balance" outlined step="0.00" type="number">
<template v-slot:prepend> <template v-slot:prepend>
<q-icon name="fas fa-coins"/> <q-icon name="fas fa-coins"/>
</template> </template>
@ -170,7 +170,7 @@
</div> </div>
</div> </div>
<q-page-scroller position="bottom-right" :offset="[16,16]" scroll-offset="120" v-if="canReconcile"> <q-page-scroller v-if="canReconcile" :offset="[16,16]" position="bottom-right" scroll-offset="120">
<div class="bg-primary text-white q-px-xl q-pa-md rounded-borders">EUR {{ balanceDiff }}</div> <div class="bg-primary text-white q-px-xl q-pa-md rounded-borders">EUR {{ balanceDiff }}</div>
</q-page-scroller> </q-page-scroller>
</q-page> </q-page>

View File

@ -42,13 +42,13 @@
<div class="row q-mt-sm"> <div class="row q-mt-sm">
<div class="col-12"> <div class="col-12">
<LargeTable ref="table" <LargeTable ref="table"
title="Transactions"
:rows="rows"
:loading="loading" :loading="loading"
v-on:on-request="onRequest" :page="page"
:rows="rows"
:rows-number="rowsNumber" :rows-number="rowsNumber"
:rows-per-page="rowsPerPage" :rows-per-page="rowsPerPage"
:page="page" title="Transactions"
v-on:on-request="onRequest"
> >
</LargeTable> </LargeTable>
</div> </div>

View File

@ -59,11 +59,11 @@
<q-card bordered> <q-card bordered>
<q-card-section> <q-card-section>
<div class="text-h6">Is demo site? <div class="text-h6">Is demo site?
<span class="text-secondary" v-if="true === isOk.is_demo_site"><span <span v-if="true === isOk.is_demo_site" class="text-secondary"><span
class="far fa-check-circle"></span></span> class="far fa-check-circle"></span></span>
<span class="text-blue" v-if="true === isLoading.is_demo_site"><span <span v-if="true === isLoading.is_demo_site" class="text-blue"><span
class="fas fa-spinner fa-spin"></span></span> class="fas fa-spinner fa-spin"></span></span>
<span class="text-red" v-if="true === isFailure.is_demo_site"><span <span v-if="true === isFailure.is_demo_site" class="text-red"><span
class="fas fa-skull-crossbones"></span> <small>Please refresh the page...</small></span> class="fas fa-skull-crossbones"></span> <small>Please refresh the page...</small></span>
</div> </div>
</q-card-section> </q-card-section>
@ -77,11 +77,11 @@
<q-card bordered> <q-card bordered>
<q-card-section> <q-card-section>
<div class="text-h6">Single user mode? <div class="text-h6">Single user mode?
<span class="text-secondary" v-if="true === isOk.single_user_mode"><span <span v-if="true === isOk.single_user_mode" class="text-secondary"><span
class="far fa-check-circle"></span></span> class="far fa-check-circle"></span></span>
<span class="text-blue" v-if="true === isLoading.single_user_mode"><span <span v-if="true === isLoading.single_user_mode" class="text-blue"><span
class="fas fa-spinner fa-spin"></span></span> class="fas fa-spinner fa-spin"></span></span>
<span class="text-red" v-if="true === isFailure.single_user_mode"><span <span v-if="true === isFailure.single_user_mode" class="text-red"><span
class="fas fa-skull-crossbones"></span> <small>Please refresh the page...</small></span> class="fas fa-skull-crossbones"></span> <small>Please refresh the page...</small></span>
</div> </div>
</q-card-section> </q-card-section>
@ -95,20 +95,20 @@
<q-card bordered> <q-card bordered>
<q-card-section> <q-card-section>
<div class="text-h6">Check for updates? <div class="text-h6">Check for updates?
<span class="text-secondary" v-if="true === isOk.update_check"><span <span v-if="true === isOk.update_check" class="text-secondary"><span
class="far fa-check-circle"></span></span> class="far fa-check-circle"></span></span>
<span class="text-blue" v-if="true === isLoading.update_check"><span <span v-if="true === isLoading.update_check" class="text-blue"><span
class="fas fa-spinner fa-spin"></span></span> class="fas fa-spinner fa-spin"></span></span>
<span class="text-red" v-if="true === isFailure.update_check"><span <span v-if="true === isFailure.update_check" class="text-red"><span
class="fas fa-skull-crossbones"></span> <small>Please refresh the page...</small></span> class="fas fa-skull-crossbones"></span> <small>Please refresh the page...</small></span>
</div> </div>
</q-card-section> </q-card-section>
<q-card-section> <q-card-section>
<q-select <q-select
bottom-slots v-model="permissionUpdateCheck"
outlined :options="permissions"
v-model="permissionUpdateCheck" emit-value bottom-slots emit-value
map-options :options="permissions" label="Check for updates"/> label="Check for updates" map-options outlined/>
</q-card-section> </q-card-section>
</q-card> </q-card>
</div> </div>

View File

@ -22,10 +22,10 @@
<q-page> <q-page>
<div class="row q-mx-md"> <div class="row q-mx-md">
<div class="col-12"> <div class="col-12">
<q-banner inline-actions rounded class="bg-orange text-white" v-if="'' !== errorMessage"> <q-banner v-if="'' !== errorMessage" class="bg-orange text-white" inline-actions rounded>
{{ errorMessage }} {{ errorMessage }}
<template v-slot:action> <template v-slot:action>
<q-btn flat @click="dismissBanner" label="Dismiss"/> <q-btn flat label="Dismiss" @click="dismissBanner"/>
</template> </template>
</q-banner> </q-banner>
</div> </div>
@ -41,10 +41,10 @@
<div class="row"> <div class="row">
<div class="col-12 q-mb-xs"> <div class="col-12 q-mb-xs">
<q-input <q-input
:error-message="submissionErrors.name" v-model="name"
:error="hasSubmissionErrors.name" :disable="disabledInput"
bottom-slots :disable="disabledInput" type="text" clearable v-model="name" :label="$t('form.name')" :error="hasSubmissionErrors.name" :error-message="submissionErrors.name" :label="$t('form.name')" bottom-slots clearable outlined
outlined/> type="text"/>
</div> </div>
</div> </div>
</q-card-section> </q-card-section>
@ -63,9 +63,11 @@
</div> </div>
<div class="row"> <div class="row">
<div class="col-12 text-right"> <div class="col-12 text-right">
<q-checkbox :disable="disabledInput" v-model="doReturnHere" left-label label="Return here to create another one"/> <q-checkbox v-model="doReturnHere" :disable="disabledInput" label="Return here to create another one"
left-label/>
<br/> <br/>
<q-checkbox v-model="doResetForm" left-label :disable="!doReturnHere || disabledInput" label="Reset form after submission"/> <q-checkbox v-model="doResetForm" :disable="!doReturnHere || disabledInput" label="Reset form after submission"
left-label/>
</div> </div>
</div> </div>
</q-card-section> </q-card-section>

View File

@ -22,10 +22,10 @@
<q-page> <q-page>
<div class="row q-mx-md"> <div class="row q-mx-md">
<div class="col-12"> <div class="col-12">
<q-banner inline-actions rounded class="bg-orange text-white" v-if="'' !== errorMessage"> <q-banner v-if="'' !== errorMessage" class="bg-orange text-white" inline-actions rounded>
{{ errorMessage }} {{ errorMessage }}
<template v-slot:action> <template v-slot:action>
<q-btn flat @click="dismissBanner" label="Dismiss"/> <q-btn flat label="Dismiss" @click="dismissBanner"/>
</template> </template>
</q-banner> </q-banner>
</div> </div>
@ -41,10 +41,10 @@
<div class="row"> <div class="row">
<div class="col-12 q-mb-xs"> <div class="col-12 q-mb-xs">
<q-input <q-input
:error-message="submissionErrors.name" v-model="name"
:error="hasSubmissionErrors.name" :disable="disabledInput"
bottom-slots :disable="disabledInput" type="text" clearable v-model="name" :label="$t('form.name')" :error="hasSubmissionErrors.name" :error-message="submissionErrors.name" :label="$t('form.name')" bottom-slots clearable outlined
outlined/> type="text"/>
</div> </div>
</div> </div>
</q-card-section> </q-card-section>
@ -63,7 +63,7 @@
</div> </div>
<div class="row"> <div class="row">
<div class="col-12 text-right"> <div class="col-12 text-right">
<q-checkbox :disable="disabledInput" v-model="doReturnHere" left-label label="Return here"/> <q-checkbox v-model="doReturnHere" :disable="disabledInput" label="Return here" left-label/>
</div> </div>
</div> </div>
</q-card-section> </q-card-section>

View File

@ -21,14 +21,14 @@
<template> <template>
<q-page> <q-page>
<q-table <q-table
:title="$t('firefly.budgets')" v-model:pagination="pagination"
:rows="rows"
:columns="columns" :columns="columns"
:loading="loading"
:rows="rows"
:title="$t('firefly.budgets')"
class="q-ma-md"
row-key="id" row-key="id"
@request="onRequest" @request="onRequest"
v-model:pagination="pagination"
:loading="loading"
class="q-ma-md"
> >
<template v-slot:header="props"> <template v-slot:header="props">
<q-tr :props="props"> <q-tr :props="props">
@ -51,12 +51,12 @@
<q-td key="menu" :props="props"> <q-td key="menu" :props="props">
<q-btn-dropdown color="primary" label="Actions" size="sm"> <q-btn-dropdown color="primary" label="Actions" size="sm">
<q-list> <q-list>
<q-item clickable v-close-popup :to="{name: 'budgets.edit', params: {id: props.row.id}}"> <q-item v-close-popup :to="{name: 'budgets.edit', params: {id: props.row.id}}" clickable>
<q-item-section> <q-item-section>
<q-item-label>Edit</q-item-label> <q-item-label>Edit</q-item-label>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-close-popup @click="deleteBudget(props.row.id, props.row.name)"> <q-item v-close-popup clickable @click="deleteBudget(props.row.id, props.row.name)">
<q-item-section> <q-item-section>
<q-item-label>Delete</q-item-label> <q-item-label>Delete</q-item-label>
</q-item-section> </q-item-section>
@ -70,18 +70,18 @@
<p> <p>
<q-btn :to="{name: 'budgets.show', params: {id: 0}}">Transactions without a budget</q-btn> <q-btn :to="{name: 'budgets.show', params: {id: 0}}">Transactions without a budget</q-btn>
</p> </p>
<q-page-sticky position="bottom-right" :offset="[18, 18]"> <q-page-sticky :offset="[18, 18]" position="bottom-right">
<q-fab <q-fab
color="green"
direction="up"
icon="fas fa-chevron-up"
label="Actions" label="Actions"
label-position="left"
square square
vertical-actions-align="right" vertical-actions-align="right"
label-position="left"
color="green"
icon="fas fa-chevron-up"
direction="up"
> >
<q-fab-action color="primary" square :to="{ name: 'budgets.create'}" icon="fas fa-exchange-alt" <q-fab-action :to="{ name: 'budgets.create'}" color="primary" icon="fas fa-exchange-alt" label="New budget"
label="New budget"/> square/>
</q-fab> </q-fab>
</q-page-sticky> </q-page-sticky>
</q-page> </q-page>

View File

@ -41,13 +41,13 @@
<div class="row q-mt-sm"> <div class="row q-mt-sm">
<div class="col-12"> <div class="col-12">
<LargeTable ref="table" <LargeTable ref="table"
title="Transactions"
:rows="rows"
:loading="loading" :loading="loading"
v-on:on-request="onRequest" :page="page"
:rows="rows"
:rows-number="rowsNumber" :rows-number="rowsNumber"
:rows-per-page="rowsPerPage" :rows-per-page="rowsPerPage"
:page="page" title="Transactions"
v-on:on-request="onRequest"
> >
</LargeTable> </LargeTable>
</div> </div>

View File

@ -22,10 +22,10 @@
<q-page> <q-page>
<div class="row q-mx-md"> <div class="row q-mx-md">
<div class="col-12"> <div class="col-12">
<q-banner inline-actions rounded class="bg-orange text-white" v-if="'' !== errorMessage"> <q-banner v-if="'' !== errorMessage" class="bg-orange text-white" inline-actions rounded>
{{ errorMessage }} {{ errorMessage }}
<template v-slot:action> <template v-slot:action>
<q-btn flat @click="dismissBanner" label="Dismiss"/> <q-btn flat label="Dismiss" @click="dismissBanner"/>
</template> </template>
</q-banner> </q-banner>
</div> </div>
@ -40,10 +40,10 @@
<div class="row"> <div class="row">
<div class="col-12 q-mb-xs"> <div class="col-12 q-mb-xs">
<q-input <q-input
:error-message="submissionErrors.name" v-model="name"
:error="hasSubmissionErrors.name" :disable="disabledInput"
bottom-slots :disable="disabledInput" type="text" clearable v-model="name" :label="$t('form.name')" :error="hasSubmissionErrors.name" :error-message="submissionErrors.name" :label="$t('form.name')" bottom-slots clearable outlined
outlined/> type="text"/>
</div> </div>
</div> </div>
</q-card-section> </q-card-section>
@ -62,9 +62,11 @@
</div> </div>
<div class="row"> <div class="row">
<div class="col-12 text-right"> <div class="col-12 text-right">
<q-checkbox :disable="disabledInput" v-model="doReturnHere" left-label label="Return here to create another one"/> <q-checkbox v-model="doReturnHere" :disable="disabledInput" label="Return here to create another one"
left-label/>
<br/> <br/>
<q-checkbox v-model="doResetForm" left-label :disable="!doReturnHere || disabledInput" label="Reset form after submission"/> <q-checkbox v-model="doResetForm" :disable="!doReturnHere || disabledInput" label="Reset form after submission"
left-label/>
</div> </div>
</div> </div>
</q-card-section> </q-card-section>

View File

@ -22,10 +22,10 @@
<q-page> <q-page>
<div class="row q-mx-md"> <div class="row q-mx-md">
<div class="col-12"> <div class="col-12">
<q-banner inline-actions rounded class="bg-orange text-white" v-if="'' !== errorMessage"> <q-banner v-if="'' !== errorMessage" class="bg-orange text-white" inline-actions rounded>
{{ errorMessage }} {{ errorMessage }}
<template v-slot:action> <template v-slot:action>
<q-btn flat @click="dismissBanner" label="Dismiss"/> <q-btn flat label="Dismiss" @click="dismissBanner"/>
</template> </template>
</q-banner> </q-banner>
</div> </div>
@ -40,10 +40,10 @@
<div class="row"> <div class="row">
<div class="col-12 q-mb-xs"> <div class="col-12 q-mb-xs">
<q-input <q-input
:error-message="submissionErrors.name" v-model="name"
:error="hasSubmissionErrors.name" :disable="disabledInput"
bottom-slots :disable="disabledInput" type="text" clearable v-model="name" :label="$t('form.name')" :error="hasSubmissionErrors.name" :error-message="submissionErrors.name" :label="$t('form.name')" bottom-slots clearable outlined
outlined/> type="text"/>
</div> </div>
</div> </div>
</q-card-section> </q-card-section>
@ -62,7 +62,7 @@
</div> </div>
<div class="row"> <div class="row">
<div class="col-12 text-right"> <div class="col-12 text-right">
<q-checkbox :disable="disabledInput" v-model="doReturnHere" left-label label="Return here"/> <q-checkbox v-model="doReturnHere" :disable="disabledInput" label="Return here" left-label/>
</div> </div>
</div> </div>
</q-card-section> </q-card-section>

View File

@ -21,14 +21,14 @@
<template> <template>
<q-page> <q-page>
<q-table <q-table
:title="$t('firefly.categories')" v-model:pagination="pagination"
:rows="rows"
:columns="columns" :columns="columns"
:loading="loading"
:rows="rows"
:title="$t('firefly.categories')"
class="q-ma-md"
row-key="id" row-key="id"
@request="onRequest" @request="onRequest"
v-model:pagination="pagination"
:loading="loading"
class="q-ma-md"
> >
<template v-slot:header="props"> <template v-slot:header="props">
<q-tr :props="props"> <q-tr :props="props">
@ -51,12 +51,12 @@
<q-td key="menu" :props="props"> <q-td key="menu" :props="props">
<q-btn-dropdown color="primary" label="Actions" size="sm"> <q-btn-dropdown color="primary" label="Actions" size="sm">
<q-list> <q-list>
<q-item clickable v-close-popup :to="{name: 'categories.edit', params: {id: props.row.id}}"> <q-item v-close-popup :to="{name: 'categories.edit', params: {id: props.row.id}}" clickable>
<q-item-section> <q-item-section>
<q-item-label>Edit</q-item-label> <q-item-label>Edit</q-item-label>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-close-popup @click="deleteCategory(props.row.id, props.row.name)"> <q-item v-close-popup clickable @click="deleteCategory(props.row.id, props.row.name)">
<q-item-section> <q-item-section>
<q-item-label>Delete</q-item-label> <q-item-label>Delete</q-item-label>
</q-item-section> </q-item-section>
@ -70,17 +70,18 @@
<p> <p>
<q-btn :to="{name: 'categories.show', params: {id: 0}}">Transactions without a category</q-btn> <q-btn :to="{name: 'categories.show', params: {id: 0}}">Transactions without a category</q-btn>
</p> </p>
<q-page-sticky position="bottom-right" :offset="[18, 18]"> <q-page-sticky :offset="[18, 18]" position="bottom-right">
<q-fab <q-fab
color="green"
direction="up"
icon="fas fa-chevron-up"
label="Actions" label="Actions"
label-position="left"
square square
vertical-actions-align="right" vertical-actions-align="right"
label-position="left"
color="green"
icon="fas fa-chevron-up"
direction="up"
> >
<q-fab-action color="primary" square :to="{ name: 'categories.create'}" icon="fas fa-exchange-alt" label="New category"/> <q-fab-action :to="{ name: 'categories.create'}" color="primary" icon="fas fa-exchange-alt" label="New category"
square/>
</q-fab> </q-fab>
</q-page-sticky> </q-page-sticky>
</q-page> </q-page>

View File

@ -41,13 +41,13 @@
<div class="row q-mt-sm"> <div class="row q-mt-sm">
<div class="col-12"> <div class="col-12">
<LargeTable ref="table" <LargeTable ref="table"
title="Transactions"
:rows="rows"
:loading="loading" :loading="loading"
v-on:on-request="onRequest" :page="page"
:rows="rows"
:rows-number="rowsNumber" :rows-number="rowsNumber"
:rows-per-page="rowsPerPage" :rows-per-page="rowsPerPage"
:page="page" title="Transactions"
v-on:on-request="onRequest"
> >
</LargeTable> </LargeTable>
</div> </div>

View File

@ -22,10 +22,10 @@
<q-page> <q-page>
<div class="row q-mx-md"> <div class="row q-mx-md">
<div class="col-12"> <div class="col-12">
<q-banner inline-actions rounded class="bg-orange text-white" v-if="'' !== errorMessage"> <q-banner v-if="'' !== errorMessage" class="bg-orange text-white" inline-actions rounded>
{{ errorMessage }} {{ errorMessage }}
<template v-slot:action> <template v-slot:action>
<q-btn flat @click="dismissBanner" label="Dismiss"/> <q-btn flat label="Dismiss" @click="dismissBanner"/>
</template> </template>
</q-banner> </q-banner>
</div> </div>
@ -40,30 +40,31 @@
<div class="row"> <div class="row">
<div class="col-12 q-mb-xs"> <div class="col-12 q-mb-xs">
<q-input <q-input
:error-message="submissionErrors.name" v-model="name"
:error="hasSubmissionErrors.name" :disable="disabledInput"
bottom-slots :disable="disabledInput" type="text" clearable v-model="name" :label="$t('form.name')" :error="hasSubmissionErrors.name" :error-message="submissionErrors.name" :label="$t('form.name')" bottom-slots clearable outlined
outlined/> type="text"/>
</div> </div>
</div> </div>
<div class="row"> <div class="row">
<div class="col-12 q-mb-xs"> <div class="col-12 q-mb-xs">
<q-input <q-input
:error-message="submissionErrors.code" v-model="code"
:error="hasSubmissionErrors.code" :disable="disabledInput"
bottom-slots :disable="disabledInput" type="text" clearable v-model="code" :label="$t('form.code')" :error="hasSubmissionErrors.code" :error-message="submissionErrors.code" :label="$t('form.code')" bottom-slots clearable outlined
outlined/> type="text"/>
</div> </div>
</div> </div>
<div class="row"> <div class="row">
<div class="col-12 q-mb-xs"> <div class="col-12 q-mb-xs">
<q-input <q-input
:error-message="submissionErrors.symbol" v-model="symbol"
:error="hasSubmissionErrors.symbol" :disable="disabledInput"
bottom-slots :disable="disabledInput" type="text" clearable v-model="symbol" :label="$t('form.symbol')" :error="hasSubmissionErrors.symbol" :error-message="submissionErrors.symbol" :label="$t('form.symbol')" bottom-slots clearable
outlined/> outlined
type="text"/>
</div> </div>
</div> </div>
</q-card-section> </q-card-section>
@ -82,9 +83,11 @@
</div> </div>
<div class="row"> <div class="row">
<div class="col-12 text-right"> <div class="col-12 text-right">
<q-checkbox :disable="disabledInput" v-model="doReturnHere" left-label label="Return here to create another one"/> <q-checkbox v-model="doReturnHere" :disable="disabledInput" label="Return here to create another one"
left-label/>
<br/> <br/>
<q-checkbox v-model="doResetForm" left-label :disable="!doReturnHere || disabledInput" label="Reset form after submission"/> <q-checkbox v-model="doResetForm" :disable="!doReturnHere || disabledInput" label="Reset form after submission"
left-label/>
</div> </div>
</div> </div>
</q-card-section> </q-card-section>

View File

@ -22,10 +22,10 @@
<q-page> <q-page>
<div class="row q-mx-md"> <div class="row q-mx-md">
<div class="col-12"> <div class="col-12">
<q-banner inline-actions rounded class="bg-orange text-white" v-if="'' !== errorMessage"> <q-banner v-if="'' !== errorMessage" class="bg-orange text-white" inline-actions rounded>
{{ errorMessage }} {{ errorMessage }}
<template v-slot:action> <template v-slot:action>
<q-btn flat @click="dismissBanner" label="Dismiss"/> <q-btn flat label="Dismiss" @click="dismissBanner"/>
</template> </template>
</q-banner> </q-banner>
</div> </div>
@ -40,30 +40,31 @@
<div class="row"> <div class="row">
<div class="col-12 q-mb-xs"> <div class="col-12 q-mb-xs">
<q-input <q-input
:error-message="submissionErrors.name" v-model="name"
:error="hasSubmissionErrors.name" :disable="disabledInput"
bottom-slots :disable="disabledInput" type="text" clearable v-model="name" :label="$t('form.name')" :error="hasSubmissionErrors.name" :error-message="submissionErrors.name" :label="$t('form.name')" bottom-slots clearable outlined
outlined/> type="text"/>
</div> </div>
</div> </div>
<div class="row"> <div class="row">
<div class="col-12 q-mb-xs"> <div class="col-12 q-mb-xs">
<q-input <q-input
:error-message="submissionErrors.code" v-model="code"
:error="hasSubmissionErrors.code" :disable="disabledInput"
bottom-slots :disable="disabledInput" type="text" clearable v-model="code" :label="$t('form.code')" :error="hasSubmissionErrors.code" :error-message="submissionErrors.code" :label="$t('form.code')" bottom-slots clearable outlined
outlined/> type="text"/>
</div> </div>
</div> </div>
<div class="row"> <div class="row">
<div class="col-12 q-mb-xs"> <div class="col-12 q-mb-xs">
<q-input <q-input
:error-message="submissionErrors.symbol" v-model="symbol"
:error="hasSubmissionErrors.symbol" :disable="disabledInput"
bottom-slots :disable="disabledInput" type="text" clearable v-model="symbol" :label="$t('form.symbol')" :error="hasSubmissionErrors.symbol" :error-message="submissionErrors.symbol" :label="$t('form.symbol')" bottom-slots clearable
outlined/> outlined
type="text"/>
</div> </div>
</div> </div>
</q-card-section> </q-card-section>
@ -82,7 +83,7 @@
</div> </div>
<div class="row"> <div class="row">
<div class="col-12 text-right"> <div class="col-12 text-right">
<q-checkbox :disable="disabledInput" v-model="doReturnHere" left-label label="Return here"/> <q-checkbox v-model="doReturnHere" :disable="disabledInput" label="Return here" left-label/>
</div> </div>
</div> </div>
</q-card-section> </q-card-section>

View File

@ -21,14 +21,14 @@
<template> <template>
<q-page> <q-page>
<q-table <q-table
:title="$t('firefly.currencies')" v-model:pagination="pagination"
:rows="rows"
:columns="columns" :columns="columns"
:loading="loading"
:rows="rows"
:title="$t('firefly.currencies')"
class="q-ma-md"
row-key="id" row-key="id"
@request="onRequest" @request="onRequest"
v-model:pagination="pagination"
:loading="loading"
class="q-ma-md"
> >
<template v-slot:header="props"> <template v-slot:header="props">
<q-tr :props="props"> <q-tr :props="props">
@ -54,12 +54,12 @@
<q-td key="menu" :props="props"> <q-td key="menu" :props="props">
<q-btn-dropdown color="primary" label="Actions" size="sm"> <q-btn-dropdown color="primary" label="Actions" size="sm">
<q-list> <q-list>
<q-item clickable v-close-popup :to="{name: 'currencies.edit', params: {code: props.row.code}}"> <q-item v-close-popup :to="{name: 'currencies.edit', params: {code: props.row.code}}" clickable>
<q-item-section> <q-item-section>
<q-item-label>Edit</q-item-label> <q-item-label>Edit</q-item-label>
</q-item-section> </q-item-section>
</q-item> </q-item>
<q-item clickable v-close-popup @click="deleteCurrency(props.row.code, props.row.name)"> <q-item v-close-popup clickable @click="deleteCurrency(props.row.code, props.row.name)">
<q-item-section> <q-item-section>
<q-item-label>Delete</q-item-label> <q-item-label>Delete</q-item-label>
</q-item-section> </q-item-section>
@ -70,17 +70,18 @@
</q-tr> </q-tr>
</template> </template>
</q-table> </q-table>
<q-page-sticky position="bottom-right" :offset="[18, 18]"> <q-page-sticky :offset="[18, 18]" position="bottom-right">
<q-fab <q-fab
color="green"
direction="up"
icon="fas fa-chevron-up"
label="Actions" label="Actions"
label-position="left"
square square
vertical-actions-align="right" vertical-actions-align="right"
label-position="left"
color="green"
icon="fas fa-chevron-up"
direction="up"
> >
<q-fab-action color="primary" square :to="{ name: 'currencies.create'}" icon="fas fa-exchange-alt" label="New currency"/> <q-fab-action :to="{ name: 'currencies.create'}" color="primary" icon="fas fa-exchange-alt" label="New currency"
square/>
</q-fab> </q-fab>
</q-page-sticky> </q-page-sticky>
</q-page> </q-page>

View File

@ -42,13 +42,13 @@
<div class="row q-mt-sm"> <div class="row q-mt-sm">
<div class="col-12"> <div class="col-12">
<LargeTable ref="table" <LargeTable ref="table"
title="Transactions"
:rows="rows"
:loading="loading" :loading="loading"
v-on:on-request="onRequest" :page="page"
:rows="rows"
:rows-number="rowsNumber" :rows-number="rowsNumber"
:rows-per-page="rowsPerPage" :rows-per-page="rowsPerPage"
:page="page" title="Transactions"
v-on:on-request="onRequest"
> >
</LargeTable> </LargeTable>
</div> </div>

View File

@ -154,7 +154,10 @@ export default {
triggerUpdate: function () { triggerUpdate: function () {
if (null !== this.store.getRange.start && null !== this.store.getRange.end) { if (null !== this.store.getRange.start && null !== this.store.getRange.end) {
const basic = new Basic; const basic = new Basic;
basic.list({start: this.store.getRange.start, end: this.store.getRange.end}, this.store.getCacheKey).then(data => { basic.list({
start: this.store.getRange.start,
end: this.store.getRange.end
}, this.store.getCacheKey).then(data => {
this.netWorth = this.getKeyedEntries(data.data, 'net-worth-in-'); this.netWorth = this.getKeyedEntries(data.data, 'net-worth-in-');
this.leftToSpend = this.getKeyedEntries(data.data, 'left-to-spend-in-'); this.leftToSpend = this.getKeyedEntries(data.data, 'left-to-spend-in-');
this.billsPaid = this.getKeyedEntries(data.data, 'bills-paid-in-'); this.billsPaid = this.getKeyedEntries(data.data, 'bills-paid-in-');

Some files were not shown because too many files have changed in this diff Show More