mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-25 18:45:27 -06:00
Apply fixes from StyleCI
This commit is contained in:
parent
9a25d6a741
commit
ba4c1d95a7
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* app.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -21,7 +21,6 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Create The Application
|
||||
@ -33,7 +32,6 @@ declare(strict_types=1);
|
||||
|
|
||||
*/
|
||||
|
||||
|
||||
bcscale(12);
|
||||
|
||||
if (!function_exists('envNonEmpty')) {
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* app.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -19,12 +19,10 @@
|
||||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
use FireflyIII\Providers\ImportServiceProvider;
|
||||
|
||||
|
||||
return [
|
||||
'name' => envNonEmpty('APP_NAME', 'Firefly III'),
|
||||
'env' => envNonEmpty('APP_ENV', 'local'),
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* auth.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -21,9 +21,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Authentication Defaults
|
||||
@ -87,7 +85,7 @@ return [
|
||||
|
||||
'providers' => [
|
||||
'users' => [
|
||||
'driver' => envNonEmpty('LOGIN_PROVIDER', 'eloquent'),//'adldap',
|
||||
'driver' => envNonEmpty('LOGIN_PROVIDER', 'eloquent'), //'adldap',
|
||||
'model' => FireflyIII\User::class,
|
||||
],
|
||||
],
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* breadcrumbs.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -23,7 +23,6 @@
|
||||
declare(strict_types=1);
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| View Name
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* broadcasting.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -21,9 +21,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Broadcaster
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* cache.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -21,9 +21,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Cache Store
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* csv.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -23,14 +23,13 @@
|
||||
declare(strict_types=1);
|
||||
|
||||
use FireflyIII\Import\Specifics\AbnAmroDescription;
|
||||
use FireflyIII\Import\Specifics\Belfius;
|
||||
use FireflyIII\Import\Specifics\IngBelgium;
|
||||
use FireflyIII\Import\Specifics\IngDescription;
|
||||
use FireflyIII\Import\Specifics\PresidentsChoice;
|
||||
use FireflyIII\Import\Specifics\SnsDescription;
|
||||
use FireflyIII\Import\Specifics\Belfius;
|
||||
use FireflyIII\Import\Specifics\IngBelgium;
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
* Configuration for the CSV specifics.
|
||||
*/
|
||||
@ -40,7 +39,7 @@ return [
|
||||
'SnsDescription' => SnsDescription::class,
|
||||
'PresidentsChoice' => PresidentsChoice::class,
|
||||
'Belfius' => Belfius::class,
|
||||
'IngBelgium' => IngBelgium::class
|
||||
'IngBelgium' => IngBelgium::class,
|
||||
],
|
||||
|
||||
/*
|
||||
@ -88,7 +87,6 @@ return [
|
||||
'converter' => 'Ignore',
|
||||
'mapper' => null,
|
||||
|
||||
|
||||
],
|
||||
'bill-id' => [
|
||||
'mappable' => true,
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* database.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -23,8 +23,6 @@ declare(strict_types=1);
|
||||
|
||||
use Illuminate\Support\Str;
|
||||
|
||||
|
||||
|
||||
$databaseUrl = getenv('DATABASE_URL');
|
||||
$host = '';
|
||||
$username = '';
|
||||
@ -33,7 +31,6 @@ $database = '';
|
||||
$port = '';
|
||||
|
||||
if (!(false === $databaseUrl)) {
|
||||
|
||||
$options = parse_url($databaseUrl);
|
||||
$host = $options['host'] ?? 'firefly_iii_db';
|
||||
$username = $options['user'] ?? 'firefly';
|
||||
@ -43,7 +40,6 @@ if (!(false === $databaseUrl)) {
|
||||
}
|
||||
|
||||
return [
|
||||
|
||||
'default' => envNonEmpty('DB_CONNECTION', 'pgsql'),
|
||||
'connections' => [
|
||||
'sqlite' => [
|
||||
|
@ -1,9 +1,10 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* debugbar.php
|
||||
* Copyright (c) 2020 james@firefly-iii.org
|
||||
* Copyright (c) 2020 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -22,7 +23,6 @@
|
||||
*/
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Debugbar Settings
|
||||
@ -36,8 +36,8 @@ return [
|
||||
*/
|
||||
|
||||
'enabled' => env('DEBUGBAR_ENABLED', null),
|
||||
'except' => [
|
||||
'telescope*'
|
||||
'except' => [
|
||||
'telescope*',
|
||||
],
|
||||
|
||||
/*
|
||||
@ -57,7 +57,7 @@ return [
|
||||
'driver' => 'file', // redis, file, pdo, custom
|
||||
'path' => storage_path('debugbar'), // For file driver
|
||||
'connection' => null, // Leave null for default connection (Redis/PDO)
|
||||
'provider' => '' // Instance of StorageInterface for custom driver
|
||||
'provider' => '', // Instance of StorageInterface for custom driver
|
||||
],
|
||||
|
||||
/*
|
||||
@ -87,7 +87,7 @@ return [
|
||||
| Optionally, you can also send ServerTiming headers on ajax requests for the Chrome DevTools.
|
||||
*/
|
||||
|
||||
'capture_ajax' => true,
|
||||
'capture_ajax' => true,
|
||||
'add_ajax_timing' => false,
|
||||
|
||||
/*
|
||||
@ -163,26 +163,26 @@ return [
|
||||
'with_params' => true, // Render SQL with the parameters substituted
|
||||
'backtrace' => true, // Use a backtrace to find the origin of the query in your files.
|
||||
'timeline' => false, // Add the queries to the timeline
|
||||
'explain' => [ // Show EXPLAIN output on queries
|
||||
'explain' => [ // Show EXPLAIN output on queries
|
||||
'enabled' => false,
|
||||
'types' => ['SELECT'], // // workaround ['SELECT'] only. https://github.com/barryvdh/laravel-debugbar/issues/888 ['SELECT', 'INSERT', 'UPDATE', 'DELETE']; for MySQL 5.6.3+
|
||||
'types' => ['SELECT'], // // workaround ['SELECT'] only. https://github.com/barryvdh/laravel-debugbar/issues/888 ['SELECT', 'INSERT', 'UPDATE', 'DELETE']; for MySQL 5.6.3+
|
||||
],
|
||||
'hints' => true, // Show hints for common mistakes
|
||||
],
|
||||
'mail' => [
|
||||
'full_log' => false
|
||||
'full_log' => false,
|
||||
],
|
||||
'views' => [
|
||||
'data' => true, //Note: Can slow down the application, because the data can be quite large..
|
||||
],
|
||||
'route' => [
|
||||
'label' => true // show complete route on bar
|
||||
'label' => true, // show complete route on bar
|
||||
],
|
||||
'logs' => [
|
||||
'file' => null
|
||||
'file' => null,
|
||||
],
|
||||
'cache' => [
|
||||
'values' => true // collect cache values
|
||||
'values' => true, // collect cache values
|
||||
],
|
||||
],
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* filesystems.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -22,7 +22,6 @@
|
||||
declare(strict_types=1);
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Filesystem Disk
|
||||
@ -117,7 +116,7 @@ return [
|
||||
| registered when used.
|
||||
|
|
||||
*/
|
||||
/*
|
||||
/*
|
||||
// Disabled, pending "twistor/flysystem-stream-wrapper" dependency
|
||||
'autowrap' => [
|
||||
'local',
|
||||
|
@ -1,9 +1,8 @@
|
||||
<?php
|
||||
|
||||
|
||||
/**
|
||||
* firefly.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -133,7 +132,7 @@ return [
|
||||
'is_demo_site' => false,
|
||||
],
|
||||
'feature_flags' => [
|
||||
'export' => true,
|
||||
'export' => true,
|
||||
'telemetry' => false,
|
||||
],
|
||||
|
||||
@ -182,7 +181,6 @@ return [
|
||||
/* PDF */
|
||||
'application/pdf',
|
||||
|
||||
|
||||
/* MS word */
|
||||
'application/msword',
|
||||
'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
|
||||
@ -246,66 +244,61 @@ return [
|
||||
'1Y' => 'yearly',
|
||||
'custom' => 'custom',
|
||||
],
|
||||
'subTitlesByIdentifier' =>
|
||||
[
|
||||
'asset' => 'Asset accounts',
|
||||
'expense' => 'Expense accounts',
|
||||
'revenue' => 'Revenue accounts',
|
||||
'cash' => 'Cash accounts',
|
||||
'liabilities' => 'Liabilities',
|
||||
'liability' => 'Liabilities',
|
||||
],
|
||||
'subIconsByIdentifier' =>
|
||||
[
|
||||
'asset' => 'fa-money',
|
||||
'Asset account' => 'fa-money',
|
||||
'Default account' => 'fa-money',
|
||||
'Cash account' => 'fa-money',
|
||||
'expense' => 'fa-shopping-cart',
|
||||
'Expense account' => 'fa-shopping-cart',
|
||||
'Beneficiary account' => 'fa-shopping-cart',
|
||||
'revenue' => 'fa-download',
|
||||
'Revenue account' => 'fa-download',
|
||||
'import' => 'fa-download',
|
||||
'Import account' => 'fa-download',
|
||||
'liabilities' => 'fa-ticket',
|
||||
],
|
||||
'accountTypesByIdentifier' =>
|
||||
[
|
||||
'asset' => ['Default account', 'Asset account'],
|
||||
'expense' => ['Expense account', 'Beneficiary account'],
|
||||
'revenue' => ['Revenue account'],
|
||||
'import' => ['Import account'],
|
||||
'liabilities' => ['Loan', 'Debt', 'Credit card', 'Mortgage'],
|
||||
],
|
||||
'accountTypeByIdentifier' =>
|
||||
[
|
||||
'asset' => ['Asset account'],
|
||||
'expense' => ['Expense account'],
|
||||
'revenue' => ['Revenue account'],
|
||||
'opening' => ['Initial balance account'],
|
||||
'initial' => ['Initial balance account'],
|
||||
'import' => ['Import account'],
|
||||
'reconcile' => ['Reconciliation account'],
|
||||
'liabilities' => ['Loan', 'Debt', 'Mortgage', 'Credit card'],
|
||||
'liability' => ['Loan', 'Debt', 'Mortgage', 'Credit card'],
|
||||
],
|
||||
'shortNamesByFullName' =>
|
||||
[
|
||||
'Default account' => 'asset',
|
||||
'Asset account' => 'asset',
|
||||
'Import account' => 'import',
|
||||
'Expense account' => 'expense',
|
||||
'Beneficiary account' => 'expense',
|
||||
'Revenue account' => 'revenue',
|
||||
'Cash account' => 'cash',
|
||||
'Initial balance account' => 'initial-balance',
|
||||
'Reconciliation account' => 'reconciliation',
|
||||
'Credit card' => 'liabilities',
|
||||
'Loan' => 'liabilities',
|
||||
'Debt' => 'liabilities',
|
||||
'Mortgage' => 'liabilities',
|
||||
],
|
||||
'subTitlesByIdentifier' => [
|
||||
'asset' => 'Asset accounts',
|
||||
'expense' => 'Expense accounts',
|
||||
'revenue' => 'Revenue accounts',
|
||||
'cash' => 'Cash accounts',
|
||||
'liabilities' => 'Liabilities',
|
||||
'liability' => 'Liabilities',
|
||||
],
|
||||
'subIconsByIdentifier' => [
|
||||
'asset' => 'fa-money',
|
||||
'Asset account' => 'fa-money',
|
||||
'Default account' => 'fa-money',
|
||||
'Cash account' => 'fa-money',
|
||||
'expense' => 'fa-shopping-cart',
|
||||
'Expense account' => 'fa-shopping-cart',
|
||||
'Beneficiary account' => 'fa-shopping-cart',
|
||||
'revenue' => 'fa-download',
|
||||
'Revenue account' => 'fa-download',
|
||||
'import' => 'fa-download',
|
||||
'Import account' => 'fa-download',
|
||||
'liabilities' => 'fa-ticket',
|
||||
],
|
||||
'accountTypesByIdentifier' => [
|
||||
'asset' => ['Default account', 'Asset account'],
|
||||
'expense' => ['Expense account', 'Beneficiary account'],
|
||||
'revenue' => ['Revenue account'],
|
||||
'import' => ['Import account'],
|
||||
'liabilities' => ['Loan', 'Debt', 'Credit card', 'Mortgage'],
|
||||
],
|
||||
'accountTypeByIdentifier' => [
|
||||
'asset' => ['Asset account'],
|
||||
'expense' => ['Expense account'],
|
||||
'revenue' => ['Revenue account'],
|
||||
'opening' => ['Initial balance account'],
|
||||
'initial' => ['Initial balance account'],
|
||||
'import' => ['Import account'],
|
||||
'reconcile' => ['Reconciliation account'],
|
||||
'liabilities' => ['Loan', 'Debt', 'Mortgage', 'Credit card'],
|
||||
'liability' => ['Loan', 'Debt', 'Mortgage', 'Credit card'],
|
||||
],
|
||||
'shortNamesByFullName' => [
|
||||
'Default account' => 'asset',
|
||||
'Asset account' => 'asset',
|
||||
'Import account' => 'import',
|
||||
'Expense account' => 'expense',
|
||||
'Beneficiary account' => 'expense',
|
||||
'Revenue account' => 'revenue',
|
||||
'Cash account' => 'cash',
|
||||
'Initial balance account' => 'initial-balance',
|
||||
'Reconciliation account' => 'reconciliation',
|
||||
'Credit card' => 'liabilities',
|
||||
'Loan' => 'liabilities',
|
||||
'Debt' => 'liabilities',
|
||||
'Mortgage' => 'liabilities',
|
||||
],
|
||||
'shortLiabilityNameByFullName' => [
|
||||
'Credit card' => 'creditcard',
|
||||
'Loan' => 'loan',
|
||||
@ -313,7 +306,7 @@ return [
|
||||
'Mortgage' => 'mortgage',
|
||||
],
|
||||
/**
|
||||
* Languages configuration
|
||||
* Languages configuration.
|
||||
*/
|
||||
'languages' => [
|
||||
// currently enabled languages
|
||||
@ -337,7 +330,6 @@ return [
|
||||
'fi_FI' => ['name_locale' => 'Suomi', 'name_english' => 'Finnish'],
|
||||
'vi_VN' => ['name_locale' => 'Tiếng Việt', 'name_english' => 'Vietnamese'],
|
||||
|
||||
|
||||
// currently disabled languages:
|
||||
// 'bg_BG' => ['name_locale' => 'Български', 'name_english' => 'Bulgarian'],
|
||||
// 'ca_ES' => ['name_locale' => 'Catalan', 'name_english' => 'Catalan'],
|
||||
@ -434,7 +426,6 @@ return [
|
||||
'tagOrId' => TagOrId::class,
|
||||
'configName' => ConfigurationName::class,
|
||||
|
||||
|
||||
],
|
||||
'rule-triggers' => [
|
||||
'user_action' => UserAction::class,
|
||||
@ -547,7 +538,6 @@ return [
|
||||
'notes_are',
|
||||
],
|
||||
|
||||
|
||||
'test-triggers' => [
|
||||
'limit' => 10,
|
||||
'range' => 200,
|
||||
@ -555,8 +545,8 @@ return [
|
||||
'default_currency' => 'EUR',
|
||||
'default_language' => envNonEmpty('DEFAULT_LANGUAGE', 'en_US'),
|
||||
'search_modifiers' => ['amount_is', 'amount', 'amount_max', 'amount_min', 'amount_less', 'amount_more', 'source', 'destination', 'category',
|
||||
'budget', 'bill', 'type', 'date', 'date_before', 'date_after', 'on', 'before', 'after', 'from', 'to', 'tag', 'created_on',
|
||||
'updated_on'],
|
||||
'budget', 'bill', 'type', 'date', 'date_before', 'date_after', 'on', 'before', 'after', 'from', 'to', 'tag', 'created_on',
|
||||
'updated_on', ],
|
||||
// TODO notes has_attachments
|
||||
|
||||
'cer_providers' => [
|
||||
@ -569,10 +559,10 @@ return [
|
||||
'source' => [
|
||||
TransactionTypeModel::WITHDRAWAL => [AccountType::ASSET, AccountType::LOAN, AccountType::DEBT, AccountType::MORTGAGE],
|
||||
TransactionTypeModel::DEPOSIT => [AccountType::REVENUE, AccountType::CASH, AccountType::LOAN, AccountType::DEBT, AccountType::MORTGAGE,
|
||||
AccountType::INITIAL_BALANCE, AccountType::RECONCILIATION],
|
||||
AccountType::INITIAL_BALANCE, AccountType::RECONCILIATION, ],
|
||||
TransactionTypeModel::TRANSFER => [AccountType::ASSET, AccountType::LOAN, AccountType::DEBT, AccountType::MORTGAGE],
|
||||
TransactionTypeModel::OPENING_BALANCE => [AccountType::INITIAL_BALANCE, AccountType::ASSET, AccountType::LOAN, AccountType::DEBT,
|
||||
AccountType::MORTGAGE],
|
||||
AccountType::MORTGAGE, ],
|
||||
TransactionTypeModel::RECONCILIATION => [AccountType::RECONCILIATION, AccountType::ASSET],
|
||||
// in case no transaction type is known yet, it could be anything.
|
||||
'none' => [
|
||||
@ -586,43 +576,43 @@ return [
|
||||
],
|
||||
'destination' => [
|
||||
TransactionTypeModel::WITHDRAWAL => [AccountType::EXPENSE, AccountType::CASH, AccountType::LOAN, AccountType::DEBT,
|
||||
AccountType::MORTGAGE],
|
||||
AccountType::MORTGAGE, ],
|
||||
TransactionTypeModel::DEPOSIT => [AccountType::ASSET, AccountType::LOAN, AccountType::DEBT, AccountType::MORTGAGE],
|
||||
TransactionTypeModel::TRANSFER => [AccountType::ASSET, AccountType::LOAN, AccountType::DEBT, AccountType::MORTGAGE],
|
||||
TransactionTypeModel::OPENING_BALANCE => [AccountType::INITIAL_BALANCE, AccountType::ASSET, AccountType::LOAN, AccountType::DEBT,
|
||||
AccountType::MORTGAGE],
|
||||
AccountType::MORTGAGE, ],
|
||||
TransactionTypeModel::RECONCILIATION => [AccountType::RECONCILIATION, AccountType::ASSET],
|
||||
],
|
||||
],
|
||||
'allowed_opposing_types' => [
|
||||
'source' => [
|
||||
AccountType::ASSET => [AccountType::ASSET, AccountType::CASH, AccountType::DEBT, AccountType::EXPENSE, AccountType::INITIAL_BALANCE,
|
||||
AccountType::LOAN, AccountType::RECONCILIATION],
|
||||
AccountType::LOAN, AccountType::RECONCILIATION, ],
|
||||
AccountType::CASH => [AccountType::ASSET],
|
||||
AccountType::DEBT => [AccountType::ASSET, AccountType::DEBT, AccountType::EXPENSE, AccountType::INITIAL_BALANCE, AccountType::LOAN,
|
||||
AccountType::MORTGAGE],
|
||||
AccountType::MORTGAGE, ],
|
||||
AccountType::EXPENSE => [], // is not allowed as a source.
|
||||
AccountType::INITIAL_BALANCE => [AccountType::ASSET, AccountType::DEBT, AccountType::LOAN, AccountType::MORTGAGE],
|
||||
AccountType::LOAN => [AccountType::ASSET, AccountType::DEBT, AccountType::EXPENSE, AccountType::INITIAL_BALANCE, AccountType::LOAN,
|
||||
AccountType::MORTGAGE],
|
||||
AccountType::MORTGAGE, ],
|
||||
AccountType::MORTGAGE => [AccountType::ASSET, AccountType::DEBT, AccountType::EXPENSE, AccountType::INITIAL_BALANCE, AccountType::LOAN,
|
||||
AccountType::MORTGAGE],
|
||||
AccountType::MORTGAGE, ],
|
||||
AccountType::RECONCILIATION => [AccountType::ASSET],
|
||||
AccountType::REVENUE => [AccountType::ASSET, AccountType::DEBT, AccountType::LOAN, AccountType::MORTGAGE],
|
||||
|
||||
],
|
||||
'destination' => [
|
||||
AccountType::ASSET => [AccountType::ASSET, AccountType::CASH, AccountType::DEBT, AccountType::INITIAL_BALANCE, AccountType::LOAN,
|
||||
AccountType::MORTGAGE, AccountType::RECONCILIATION, AccountType::REVENUE],
|
||||
AccountType::MORTGAGE, AccountType::RECONCILIATION, AccountType::REVENUE, ],
|
||||
AccountType::CASH => [AccountType::ASSET],
|
||||
AccountType::DEBT => [AccountType::ASSET, AccountType::DEBT, AccountType::INITIAL_BALANCE, AccountType::LOAN, AccountType::MORTGAGE,
|
||||
AccountType::REVENUE],
|
||||
AccountType::REVENUE, ],
|
||||
AccountType::EXPENSE => [AccountType::ASSET, AccountType::DEBT, AccountType::LOAN, AccountType::MORTGAGE],
|
||||
AccountType::INITIAL_BALANCE => [AccountType::ASSET, AccountType::DEBT, AccountType::LOAN, AccountType::MORTGAGE],
|
||||
AccountType::LOAN => [AccountType::ASSET, AccountType::DEBT, AccountType::INITIAL_BALANCE, AccountType::LOAN, AccountType::MORTGAGE,
|
||||
AccountType::REVENUE],
|
||||
AccountType::REVENUE, ],
|
||||
AccountType::MORTGAGE => [AccountType::ASSET, AccountType::DEBT, AccountType::INITIAL_BALANCE, AccountType::LOAN, AccountType::MORTGAGE,
|
||||
AccountType::REVENUE],
|
||||
AccountType::REVENUE, ],
|
||||
AccountType::RECONCILIATION => [AccountType::ASSET],
|
||||
AccountType::REVENUE => [], // is not allowed as a destination
|
||||
],
|
||||
@ -631,29 +621,29 @@ return [
|
||||
'allowed_transaction_types' => [
|
||||
'source' => [
|
||||
AccountType::ASSET => [TransactionTypeModel::WITHDRAWAL, TransactionTypeModel::TRANSFER, TransactionTypeModel::OPENING_BALANCE,
|
||||
TransactionTypeModel::RECONCILIATION],
|
||||
TransactionTypeModel::RECONCILIATION, ],
|
||||
AccountType::EXPENSE => [], // is not allowed as a source.
|
||||
AccountType::REVENUE => [TransactionTypeModel::DEPOSIT],
|
||||
AccountType::LOAN => [TransactionTypeModel::WITHDRAWAL, TransactionTypeModel::DEPOSIT, TransactionTypeModel::TRANSFER,
|
||||
TransactionTypeModel::OPENING_BALANCE],
|
||||
TransactionTypeModel::OPENING_BALANCE, ],
|
||||
AccountType::DEBT => [TransactionTypeModel::WITHDRAWAL, TransactionTypeModel::DEPOSIT, TransactionTypeModel::TRANSFER,
|
||||
TransactionTypeModel::OPENING_BALANCE],
|
||||
TransactionTypeModel::OPENING_BALANCE, ],
|
||||
AccountType::MORTGAGE => [TransactionTypeModel::WITHDRAWAL, TransactionTypeModel::DEPOSIT, TransactionTypeModel::TRANSFER,
|
||||
TransactionTypeModel::OPENING_BALANCE],
|
||||
TransactionTypeModel::OPENING_BALANCE, ],
|
||||
AccountType::INITIAL_BALANCE => [], // todo fill me in.
|
||||
AccountType::RECONCILIATION => [], // todo fill me in.
|
||||
],
|
||||
'destination' => [
|
||||
AccountType::ASSET => [TransactionTypeModel::DEPOSIT, TransactionTypeModel::TRANSFER, TransactionTypeModel::OPENING_BALANCE,
|
||||
TransactionTypeModel::RECONCILIATION],
|
||||
TransactionTypeModel::RECONCILIATION, ],
|
||||
AccountType::EXPENSE => [TransactionTypeModel::WITHDRAWAL],
|
||||
AccountType::REVENUE => [], // is not allowed as destination.
|
||||
AccountType::LOAN => [TransactionTypeModel::WITHDRAWAL, TransactionTypeModel::DEPOSIT, TransactionTypeModel::TRANSFER,
|
||||
TransactionTypeModel::OPENING_BALANCE],
|
||||
TransactionTypeModel::OPENING_BALANCE, ],
|
||||
AccountType::DEBT => [TransactionTypeModel::WITHDRAWAL, TransactionTypeModel::DEPOSIT, TransactionTypeModel::TRANSFER,
|
||||
TransactionTypeModel::OPENING_BALANCE],
|
||||
TransactionTypeModel::OPENING_BALANCE, ],
|
||||
AccountType::MORTGAGE => [TransactionTypeModel::WITHDRAWAL, TransactionTypeModel::DEPOSIT, TransactionTypeModel::TRANSFER,
|
||||
TransactionTypeModel::OPENING_BALANCE],
|
||||
TransactionTypeModel::OPENING_BALANCE, ],
|
||||
AccountType::INITIAL_BALANCE => [], // todo fill me in.
|
||||
AccountType::RECONCILIATION => [], // todo fill me in.
|
||||
],
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* google2fa.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -22,7 +22,6 @@
|
||||
declare(strict_types=1);
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
* Auth container binding
|
||||
*/
|
||||
@ -91,7 +90,6 @@ return [
|
||||
*/
|
||||
'throw_exceptions' => true,
|
||||
|
||||
|
||||
'store_in_cookie' => true,
|
||||
|
||||
];
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* hashing.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -23,7 +23,6 @@
|
||||
declare(strict_types=1);
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Hash Driver
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* ide-helper.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -21,8 +21,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
return array(
|
||||
|
||||
return [
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Filename & Format
|
||||
@ -34,7 +33,7 @@ return array(
|
||||
|
||||
'filename' => '_ide_helper',
|
||||
'format' => 'php',
|
||||
|
||||
|
||||
'meta_filename' => '.phpstorm.meta.php',
|
||||
|
||||
/*
|
||||
@ -86,9 +85,9 @@ return array(
|
||||
|
||||
'include_helpers' => false,
|
||||
|
||||
'helper_files' => array(
|
||||
base_path().'/vendor/laravel/framework/src/Illuminate/Support/helpers.php',
|
||||
),
|
||||
'helper_files' => [
|
||||
base_path() . '/vendor/laravel/framework/src/Illuminate/Support/helpers.php',
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
@ -100,10 +99,9 @@ return array(
|
||||
|
|
||||
*/
|
||||
|
||||
'model_locations' => array(
|
||||
'model_locations' => [
|
||||
'app',
|
||||
),
|
||||
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
@ -114,13 +112,13 @@ return array(
|
||||
|
|
||||
*/
|
||||
|
||||
'extra' => array(
|
||||
'Eloquent' => array('Illuminate\Database\Eloquent\Builder', 'Illuminate\Database\Query\Builder'),
|
||||
'Session' => array('Illuminate\Session\Store'),
|
||||
),
|
||||
'extra' => [
|
||||
'Eloquent' => ['Illuminate\Database\Eloquent\Builder', 'Illuminate\Database\Query\Builder'],
|
||||
'Session' => ['Illuminate\Session\Store'],
|
||||
],
|
||||
|
||||
'magic' => array(
|
||||
'Log' => array(
|
||||
'magic' => [
|
||||
'Log' => [
|
||||
'debug' => 'Monolog\Logger::addDebug',
|
||||
'info' => 'Monolog\Logger::addInfo',
|
||||
'notice' => 'Monolog\Logger::addNotice',
|
||||
@ -129,8 +127,8 @@ return array(
|
||||
'critical' => 'Monolog\Logger::addCritical',
|
||||
'alert' => 'Monolog\Logger::addAlert',
|
||||
'emergency' => 'Monolog\Logger::addEmergency',
|
||||
)
|
||||
),
|
||||
],
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
@ -142,9 +140,9 @@ return array(
|
||||
|
|
||||
*/
|
||||
|
||||
'interfaces' => array(
|
||||
'interfaces' => [
|
||||
|
||||
),
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
@ -172,9 +170,9 @@ return array(
|
||||
| ),
|
||||
|
|
||||
*/
|
||||
'custom_db_types' => array(
|
||||
'custom_db_types' => [
|
||||
|
||||
),
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
@ -210,10 +208,10 @@ return array(
|
||||
| Cast the given "real type" to the given "type".
|
||||
|
|
||||
*/
|
||||
'type_overrides' => array(
|
||||
'type_overrides' => [
|
||||
'integer' => 'int',
|
||||
'boolean' => 'bool',
|
||||
),
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
@ -226,4 +224,4 @@ return array(
|
||||
*/
|
||||
'include_class_docblocks' => false,
|
||||
|
||||
);
|
||||
];
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* import.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* intro.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -33,7 +33,7 @@ return [
|
||||
'box_out_holder' => ['element' => '#box_out_holder'],
|
||||
'help' => ['element' => '#help', 'position' => 'bottom'],
|
||||
'sidebar-toggle' => ['element' => '#sidebar-toggle', 'position' => 'bottom'],
|
||||
'cash_account' => ['element' => '#all_transactions','position' => 'left'],
|
||||
'cash_account' => ['element' => '#all_transactions', 'position' => 'left'],
|
||||
'outro' => [],
|
||||
],
|
||||
// accounts: create
|
||||
@ -42,24 +42,24 @@ return [
|
||||
],
|
||||
// transactions: create
|
||||
'transactions_create_withdrawal' => [
|
||||
'source' => ['element' => 'input[name="source[]"]'],
|
||||
'source' => ['element' => 'input[name="source[]"]'],
|
||||
'destination' => ['element' => 'input[name="destination[]"]'],
|
||||
'more_meta' => ['element' => 'input[name="category[]"]'],
|
||||
'split_add' => ['element' => '.split_add_btn'],
|
||||
'more_meta' => ['element' => 'input[name="category[]"]'],
|
||||
'split_add' => ['element' => '.split_add_btn'],
|
||||
],
|
||||
|
||||
'transactions_create_deposit' => [
|
||||
'source' => ['element' => 'input[name="source[]"]'],
|
||||
'source' => ['element' => 'input[name="source[]"]'],
|
||||
'destination' => ['element' => 'input[name="destination[]"]'],
|
||||
'more_meta' => ['element' => 'input[name="category[]"]'],
|
||||
'split_add' => ['element' => '.split_add_btn'],
|
||||
'more_meta' => ['element' => 'input[name="category[]"]'],
|
||||
'split_add' => ['element' => '.split_add_btn'],
|
||||
],
|
||||
|
||||
'transactions_create_transfer' => [
|
||||
'source' => ['element' => 'input[name="source[]"]'],
|
||||
'source' => ['element' => 'input[name="source[]"]'],
|
||||
'destination' => ['element' => 'input[name="destination[]"]'],
|
||||
'more_meta' => ['element' => 'input[name="category[]"]'],
|
||||
'split_add' => ['element' => '.split_add_btn'],
|
||||
'more_meta' => ['element' => 'input[name="category[]"]'],
|
||||
'split_add' => ['element' => '.split_add_btn'],
|
||||
],
|
||||
|
||||
// extra text for asset account creation.
|
||||
@ -72,7 +72,7 @@ return [
|
||||
// budgets: index
|
||||
'budgets_index' => [
|
||||
'intro' => [],
|
||||
'set_budget' => ['element' => '#availableBar',],
|
||||
'set_budget' => ['element' => '#availableBar'],
|
||||
'see_expenses_bar' => ['element' => '#spentBar'],
|
||||
'navigate_periods' => ['element' => '#periodNavigator'],
|
||||
'new_budget' => ['element' => '#createBudgetBox'],
|
||||
@ -115,7 +115,7 @@ return [
|
||||
// piggies: index, create, show
|
||||
'piggy-banks_index' => [
|
||||
'saved' => ['element' => '.piggySaved'],
|
||||
'button' => ['element' => '.piggyBar',],
|
||||
'button' => ['element' => '.piggyBar'],
|
||||
'accountStatus' => ['element' => '#accountStatus', 'position' => 'top'],
|
||||
],
|
||||
'piggy-banks_create' => [
|
||||
@ -173,9 +173,9 @@ return [
|
||||
'currencies_index' => [
|
||||
'intro' => [],
|
||||
'default' => ['element' => '#default-currency'],
|
||||
'buttons' => ['element' => '.buttons',]
|
||||
'buttons' => ['element' => '.buttons'],
|
||||
],
|
||||
'currencies_create' => [
|
||||
'code' => ['element' => '#ffInput_code',],
|
||||
'code' => ['element' => '#ffInput_code'],
|
||||
],
|
||||
];
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* ldap.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -37,8 +37,8 @@ if ('FreeIPA' === envNonEmpty('ADLDAP_CONNECTION_SCHEME', 'OpenLDAP')) {
|
||||
if ('ActiveDirectory' === envNonEmpty('ADLDAP_CONNECTION_SCHEME', 'OpenLDAP')) {
|
||||
$schema = ActiveDirectory::class;
|
||||
}
|
||||
return [
|
||||
|
||||
return [
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Connections
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* ldap_auth.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -25,7 +25,6 @@ declare(strict_types=1);
|
||||
use Adldap\Laravel\Scopes\UidScope;
|
||||
use Adldap\Laravel\Scopes\UpnScope;
|
||||
|
||||
|
||||
// default OpenLDAP scopes.
|
||||
$scopes = [
|
||||
UidScope::class,
|
||||
@ -39,9 +38,7 @@ if ('ActiveDirectory' === env('ADLDAP_CONNECTION_SCHEME')) {
|
||||
];
|
||||
}
|
||||
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Connection
|
||||
@ -78,7 +75,6 @@ return [
|
||||
'provider' => Adldap\Laravel\Auth\DatabaseUserProvider::class,
|
||||
//'provider' => Adldap\Laravel\Auth\NoDatabaseUserProvider::class,
|
||||
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Model
|
||||
@ -174,7 +170,7 @@ return [
|
||||
'ldap' => [
|
||||
|
||||
'locate_users_by' => envNonEmpty('ADLDAP_DISCOVER_FIELD', 'userprincipalname'),
|
||||
'bind_users_by' => envNonEmpty('ADLDAP_AUTH_FIELD', 'distinguishedname'),
|
||||
'bind_users_by' => envNonEmpty('ADLDAP_AUTH_FIELD', 'distinguishedname'),
|
||||
|
||||
],
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* logging.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -19,13 +19,11 @@
|
||||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
use FireflyIII\Support\Logging\AuditLogger;
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Log Channel
|
||||
@ -38,7 +36,7 @@ return [
|
||||
*/
|
||||
|
||||
'default' => envNonEmpty('LOG_CHANNEL', 'stack'),
|
||||
'level' => envNonEmpty('APP_LOG_LEVEL', 'info'),
|
||||
'level' => envNonEmpty('APP_LOG_LEVEL', 'info'),
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Log Channels
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* mail.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -21,9 +21,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Mail Driver
|
||||
@ -78,7 +76,6 @@ return [
|
||||
*/
|
||||
'from' => ['address' => envNonEmpty('MAIL_FROM', 'changeme@example.com'), 'name' => 'Firefly III Mailer'],
|
||||
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| E-Mail Encryption Protocol
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* queue.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -21,9 +21,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Queue Driver
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* services.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -21,9 +21,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Third Party Services
|
||||
@ -37,9 +35,9 @@ return [
|
||||
*/
|
||||
|
||||
'mailgun' => [
|
||||
'domain' => env('MAILGUN_DOMAIN'),
|
||||
'endpoint' => env('MAILGUN_ENDPOINT','api.mailgun.net'),
|
||||
'secret' => env('MAILGUN_SECRET'),
|
||||
'domain' => env('MAILGUN_DOMAIN'),
|
||||
'endpoint' => env('MAILGUN_ENDPOINT', 'api.mailgun.net'),
|
||||
'secret' => env('MAILGUN_SECRET'),
|
||||
],
|
||||
|
||||
'ses' => [
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* session.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -21,7 +21,6 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
|
||||
return [
|
||||
'driver' => env('SESSION_DRIVER', 'file'),
|
||||
'lifetime' => 120,
|
||||
|
@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the TwigBridge package.
|
||||
*
|
||||
@ -28,7 +30,6 @@ use TwigBridge\Extension\Loader\Functions;
|
||||
* Configuration options for Twig.
|
||||
*/
|
||||
return [
|
||||
|
||||
'twig' => [
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
@ -181,13 +182,12 @@ return [
|
||||
'Steam',
|
||||
'Config',
|
||||
'Request',
|
||||
'Form' => ['is_safe' => ['input', 'select', 'checkbox', 'model', 'open', 'radio', 'textarea', 'file',],],
|
||||
'Form' => ['is_safe' => ['input', 'select', 'checkbox', 'model', 'open', 'radio', 'textarea', 'file']],
|
||||
'ExpandedForm' => [
|
||||
'is_safe' => [
|
||||
'date', 'text', 'select', 'balance', 'optionsList', 'checkbox', 'amount', 'tags', 'integer', 'textarea', 'location', 'file', 'staticText',
|
||||
'password', 'nonSelectableAmount', 'number', 'amountNoCurrency', 'percentage',
|
||||
|
||||
|
||||
],
|
||||
],
|
||||
'AccountForm' => [
|
||||
@ -201,12 +201,11 @@ return [
|
||||
'currencyList', 'currencyListEmpty', 'balanceAll',
|
||||
],
|
||||
],
|
||||
'PiggyBankForm' =>
|
||||
[
|
||||
'is_safe' => [
|
||||
'piggyBankList',
|
||||
],
|
||||
'PiggyBankForm' => [
|
||||
'is_safe' => [
|
||||
'piggyBankList',
|
||||
],
|
||||
],
|
||||
'RuleForm' => [
|
||||
'is_safe' => [
|
||||
'ruleGroupList', 'ruleGroupListWithEmpty',
|
||||
@ -214,7 +213,6 @@ return [
|
||||
],
|
||||
],
|
||||
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Functions
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* upgrade.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -23,31 +23,29 @@ declare(strict_types=1);
|
||||
|
||||
return [
|
||||
'text' => [
|
||||
'upgrade' =>
|
||||
[
|
||||
'4.3' => 'Make sure you run the migrations and clear your cache. If you need more help, please check Github or the Firefly III website.',
|
||||
'4.6.3' => 'This will be the last version to require PHP7.0. Future versions will require PHP7.1 minimum.',
|
||||
'4.6.4' => 'This version of Firefly III requires PHP7.1.',
|
||||
'4.7.3' => 'This version of Firefly III handles bills differently. See http://bit.ly/FF3-new-bills for more information.',
|
||||
'4.7.4' => 'This version of Firefly III has a new import routine. See http://bit.ly/FF3-new-import for more information.',
|
||||
'4.7.6' => 'This will be the last version to require PHP7.1. Future versions will require PHP7.2 minimum.',
|
||||
'4.7.7' => 'This version of Firefly III requires PHP7.2.',
|
||||
'4.7.10' => 'Firefly III no longer encrypts database values. To protect your data, make sure you use TDE or FDE. Read more: https://bit.ly/FF3-encryption',
|
||||
'4.8.0' => 'This is a huge upgrade for Firefly III. Please expect bugs and errors, and bear with me as I fix them. I tested a lot of things but pretty sure I missed some. Thanks for understanding.',
|
||||
'4.8.1' => 'This version of Firefly III requires PHP7.3.',
|
||||
],
|
||||
'install' =>
|
||||
[
|
||||
'4.3' => 'Welcome to Firefly! Make sure you follow the installation guide. If you need more help, please check Github or the Firefly III website. The installation guide has a FAQ which you should check out as well.',
|
||||
'4.6.3' => 'This will be the last version to require PHP7.0. Future versions will require PHP7.1 minimum.',
|
||||
'4.6.4' => 'This version of Firefly III requires PHP7.1.',
|
||||
'4.7.3' => 'This version of Firefly III handles bills differently. See http://bit.ly/FF3-new-bills for more information.',
|
||||
'4.7.4' => 'This version of Firefly III has a new import routine. See http://bit.ly/FF3-new-import for more information.',
|
||||
'4.7.6' => 'This will be the last version to require PHP7.1. Future versions will require PHP7.2 minimum.',
|
||||
'4.7.7' => 'This version of Firefly III requires PHP7.2.',
|
||||
'4.7.10' => 'Firefly III no longer encrypts database values. To protect your data, make sure you use TDE or FDE. Read more: https://bit.ly/FF3-encryption',
|
||||
'4.8.0' => 'This is a huge upgrade for Firefly III. Please expect bugs and errors, and bear with me as I fix them. I tested a lot of things but pretty sure I missed some. Thanks for understanding.',
|
||||
'4.8.1' => 'This version of Firefly III requires PHP7.3.',
|
||||
],
|
||||
'upgrade' => [
|
||||
'4.3' => 'Make sure you run the migrations and clear your cache. If you need more help, please check Github or the Firefly III website.',
|
||||
'4.6.3' => 'This will be the last version to require PHP7.0. Future versions will require PHP7.1 minimum.',
|
||||
'4.6.4' => 'This version of Firefly III requires PHP7.1.',
|
||||
'4.7.3' => 'This version of Firefly III handles bills differently. See http://bit.ly/FF3-new-bills for more information.',
|
||||
'4.7.4' => 'This version of Firefly III has a new import routine. See http://bit.ly/FF3-new-import for more information.',
|
||||
'4.7.6' => 'This will be the last version to require PHP7.1. Future versions will require PHP7.2 minimum.',
|
||||
'4.7.7' => 'This version of Firefly III requires PHP7.2.',
|
||||
'4.7.10' => 'Firefly III no longer encrypts database values. To protect your data, make sure you use TDE or FDE. Read more: https://bit.ly/FF3-encryption',
|
||||
'4.8.0' => 'This is a huge upgrade for Firefly III. Please expect bugs and errors, and bear with me as I fix them. I tested a lot of things but pretty sure I missed some. Thanks for understanding.',
|
||||
'4.8.1' => 'This version of Firefly III requires PHP7.3.',
|
||||
],
|
||||
'install' => [
|
||||
'4.3' => 'Welcome to Firefly! Make sure you follow the installation guide. If you need more help, please check Github or the Firefly III website. The installation guide has a FAQ which you should check out as well.',
|
||||
'4.6.3' => 'This will be the last version to require PHP7.0. Future versions will require PHP7.1 minimum.',
|
||||
'4.6.4' => 'This version of Firefly III requires PHP7.1.',
|
||||
'4.7.3' => 'This version of Firefly III handles bills differently. See http://bit.ly/FF3-new-bills for more information.',
|
||||
'4.7.4' => 'This version of Firefly III has a new import routine. See http://bit.ly/FF3-new-import for more information.',
|
||||
'4.7.6' => 'This will be the last version to require PHP7.1. Future versions will require PHP7.2 minimum.',
|
||||
'4.7.7' => 'This version of Firefly III requires PHP7.2.',
|
||||
'4.7.10' => 'Firefly III no longer encrypts database values. To protect your data, make sure you use TDE or FDE. Read more: https://bit.ly/FF3-encryption',
|
||||
'4.8.0' => 'This is a huge upgrade for Firefly III. Please expect bugs and errors, and bear with me as I fix them. I tested a lot of things but pretty sure I missed some. Thanks for understanding.',
|
||||
'4.8.1' => 'This version of Firefly III requires PHP7.3.',
|
||||
],
|
||||
],
|
||||
];
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* view.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -21,9 +21,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| View Storage Paths
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* AccountFactory.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -22,10 +22,9 @@ declare(strict_types=1);
|
||||
|
||||
use Carbon\Carbon;
|
||||
|
||||
|
||||
$factory->define(
|
||||
FireflyIII\Models\Account::class,
|
||||
function (Faker\Generator $faker) {
|
||||
static function (Faker\Generator $faker) {
|
||||
return [
|
||||
'id' => $faker->unique()->numberBetween(1000, 10000),
|
||||
'user_id' => 1,
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* ModelFactory.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -23,10 +23,9 @@ declare(strict_types=1);
|
||||
use Carbon\Carbon;
|
||||
use FireflyIII\Models\TransactionJournal;
|
||||
|
||||
|
||||
$factory->define(
|
||||
FireflyIII\Models\Attachment::class,
|
||||
function (Faker\Generator $faker) {
|
||||
static function (Faker\Generator $faker) {
|
||||
return [
|
||||
'user_id' => 1,
|
||||
'attachable_id' => 1,
|
||||
@ -43,7 +42,7 @@ $factory->define(
|
||||
|
||||
$factory->define(
|
||||
FireflyIII\Models\CurrencyExchangeRate::class,
|
||||
function (Faker\Generator $faker) {
|
||||
static function (Faker\Generator $faker) {
|
||||
return [
|
||||
'user_id' => 1,
|
||||
'from_currency_id' => 1,
|
||||
@ -57,7 +56,7 @@ $factory->define(
|
||||
|
||||
$factory->define(
|
||||
FireflyIII\Models\TransactionCurrency::class,
|
||||
function (Faker\Generator $faker) {
|
||||
static function (Faker\Generator $faker) {
|
||||
return [
|
||||
'name' => $faker->words(1, true),
|
||||
'code' => 'ABC',
|
||||
@ -68,7 +67,7 @@ $factory->define(
|
||||
|
||||
$factory->define(
|
||||
FireflyIII\Models\ImportJob::class,
|
||||
function (Faker\Generator $faker) {
|
||||
static function (Faker\Generator $faker) {
|
||||
return [
|
||||
'id' => $faker->numberBetween(1, 100),
|
||||
'user_id' => 1,
|
||||
@ -89,7 +88,7 @@ $factory->define(
|
||||
|
||||
$factory->define(
|
||||
FireflyIII\Models\TransactionJournal::class,
|
||||
function (Faker\Generator $faker) {
|
||||
static function (Faker\Generator $faker) {
|
||||
return [
|
||||
'id' => $faker->unique()->numberBetween(1000, 10000),
|
||||
'user_id' => 1,
|
||||
@ -111,7 +110,7 @@ $factory->define(
|
||||
|
||||
$factory->define(
|
||||
FireflyIII\Models\Bill::class,
|
||||
function (Faker\Generator $faker) {
|
||||
static function (Faker\Generator $faker) {
|
||||
return [
|
||||
'created_at' => new Carbon,
|
||||
'updated_at' => new Carbon,
|
||||
@ -131,7 +130,7 @@ $factory->define(
|
||||
|
||||
$factory->define(
|
||||
FireflyIII\Models\PiggyBankRepetition::class,
|
||||
function (Faker\Generator $faker) {
|
||||
static function (Faker\Generator $faker) {
|
||||
return [
|
||||
'id' => $faker->unique()->numberBetween(100, 10000),
|
||||
'piggy_bank_id' => $faker->numberBetween(1, 10),
|
||||
@ -144,7 +143,7 @@ $factory->define(
|
||||
|
||||
$factory->define(
|
||||
FireflyIII\Models\PiggyBank::class,
|
||||
function (Faker\Generator $faker) {
|
||||
static function (Faker\Generator $faker) {
|
||||
return [
|
||||
'id' => $faker->unique()->numberBetween(100, 10000),
|
||||
'created_at' => new Carbon,
|
||||
@ -162,7 +161,7 @@ $factory->define(
|
||||
|
||||
$factory->define(
|
||||
FireflyIII\Models\Tag::class,
|
||||
function (Faker\Generator $faker) {
|
||||
static function (Faker\Generator $faker) {
|
||||
return [
|
||||
'id' => $faker->unique()->numberBetween(200, 10000),
|
||||
'user_id' => 1,
|
||||
@ -174,7 +173,7 @@ $factory->define(
|
||||
|
||||
$factory->define(
|
||||
FireflyIII\Models\Category::class,
|
||||
function (Faker\Generator $faker) {
|
||||
static function (Faker\Generator $faker) {
|
||||
return [
|
||||
'id' => $faker->numberBetween(1, 10),
|
||||
'name' => $faker->words(3, true),
|
||||
@ -184,7 +183,7 @@ $factory->define(
|
||||
|
||||
$factory->define(
|
||||
FireflyIII\Models\Budget::class,
|
||||
function (Faker\Generator $faker) {
|
||||
static function (Faker\Generator $faker) {
|
||||
return [
|
||||
'id' => $faker->numberBetween(1, 10),
|
||||
'name' => $faker->words(3, true),
|
||||
@ -194,7 +193,7 @@ $factory->define(
|
||||
|
||||
$factory->define(
|
||||
FireflyIII\Models\PiggyBankEvent::class,
|
||||
function (Faker\Generator $faker) {
|
||||
static function (Faker\Generator $faker) {
|
||||
return [
|
||||
'id' => $faker->numberBetween(1, 10),
|
||||
'piggy_bank_id' => $faker->numberBetween(1, 10),
|
||||
@ -207,7 +206,7 @@ $factory->define(
|
||||
|
||||
$factory->define(
|
||||
FireflyIII\Models\BudgetLimit::class,
|
||||
function (Faker\Generator $faker) {
|
||||
static function (Faker\Generator $faker) {
|
||||
return [
|
||||
'id' => $faker->numberBetween(1, 10),
|
||||
'start_date' => '2017-01-01',
|
||||
@ -220,7 +219,7 @@ $factory->define(
|
||||
|
||||
$factory->define(
|
||||
FireflyIII\Models\Transaction::class,
|
||||
function (Faker\Generator $faker) {
|
||||
static function (Faker\Generator $faker) {
|
||||
return [
|
||||
'transaction_amount' => (string)$faker->randomFloat(2, -100, 100),
|
||||
'destination_amount' => (string)$faker->randomFloat(2, -100, 100),
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* UserFactory.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -36,11 +36,11 @@ use Faker\Generator as Faker;
|
||||
*/
|
||||
|
||||
$factory->define(
|
||||
FireflyIII\User::class, function (Faker $faker) {
|
||||
return [
|
||||
'email' => $faker->unique()->safeEmail,
|
||||
'password' => '$2y$10$TKh8H1.PfQx37YgCzwiKb.KjNyWgaHb9cbcoQgdIVFlYg7B77UdFm', // secret
|
||||
'remember_token' => str_random(10),
|
||||
];
|
||||
}
|
||||
FireflyIII\User::class, static function (Faker $faker) {
|
||||
return [
|
||||
'email' => $faker->unique()->safeEmail,
|
||||
'password' => '$2y$10$TKh8H1.PfQx37YgCzwiKb.KjNyWgaHb9cbcoQgdIVFlYg7B77UdFm', // secret
|
||||
'remember_token' => str_random(10),
|
||||
];
|
||||
}
|
||||
);
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* 2016_06_16_000000_create_support_tables.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -24,7 +24,7 @@ use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
/**
|
||||
* Class CreateSupportTables
|
||||
* Class CreateSupportTables.
|
||||
*/
|
||||
class CreateSupportTables extends Migration
|
||||
{
|
||||
@ -64,15 +64,12 @@ class CreateSupportTables extends Migration
|
||||
$this->createConfigurationTable();
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private function createAccountTypeTable(): void
|
||||
{
|
||||
if (!Schema::hasTable('account_types')) {
|
||||
Schema::create(
|
||||
'account_types',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->string('type', 50);
|
||||
@ -89,7 +86,7 @@ class CreateSupportTables extends Migration
|
||||
if (!Schema::hasTable('configuration')) {
|
||||
Schema::create(
|
||||
'configuration',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
@ -101,15 +98,12 @@ class CreateSupportTables extends Migration
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private function createCurrencyTable(): void
|
||||
{
|
||||
if (!Schema::hasTable('transaction_currencies')) {
|
||||
Schema::create(
|
||||
'transaction_currencies',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
@ -124,15 +118,12 @@ class CreateSupportTables extends Migration
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private function createJobsTable(): void
|
||||
{
|
||||
if (!Schema::hasTable('jobs')) {
|
||||
Schema::create(
|
||||
'jobs',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
// straight from Laravel
|
||||
$table->bigIncrements('id');
|
||||
$table->string('queue');
|
||||
@ -148,15 +139,12 @@ class CreateSupportTables extends Migration
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private function createPasswordTable(): void
|
||||
{
|
||||
if (!Schema::hasTable('password_resets')) {
|
||||
Schema::create(
|
||||
'password_resets',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
// straight from laravel
|
||||
$table->string('email')->index();
|
||||
$table->string('token')->index();
|
||||
@ -166,15 +154,12 @@ class CreateSupportTables extends Migration
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private function createPermissionRoleTable(): void
|
||||
{
|
||||
if (!Schema::hasTable('permission_role')) {
|
||||
Schema::create(
|
||||
'permission_role',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->integer('permission_id')->unsigned();
|
||||
$table->integer('role_id')->unsigned();
|
||||
|
||||
@ -187,15 +172,12 @@ class CreateSupportTables extends Migration
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private function createPermissionsTable(): void
|
||||
{
|
||||
if (!Schema::hasTable('permissions')) {
|
||||
Schema::create(
|
||||
'permissions',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->string('name')->unique();
|
||||
@ -206,15 +188,12 @@ class CreateSupportTables extends Migration
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private function createRolesTable(): void
|
||||
{
|
||||
if (!Schema::hasTable('roles')) {
|
||||
Schema::create(
|
||||
'roles',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->string('name')->unique();
|
||||
@ -225,15 +204,12 @@ class CreateSupportTables extends Migration
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private function createSessionsTable(): void
|
||||
{
|
||||
if (!Schema::hasTable('sessions')) {
|
||||
Schema::create(
|
||||
'sessions',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->string('id')->unique();
|
||||
$table->integer('user_id')->nullable();
|
||||
$table->string('ip_address', 45)->nullable();
|
||||
@ -245,15 +221,12 @@ class CreateSupportTables extends Migration
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private function createTransactionTypeTable(): void
|
||||
{
|
||||
if (!Schema::hasTable('transaction_types')) {
|
||||
Schema::create(
|
||||
'transaction_types',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* 2016_06_16_000001_create_users_table.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -24,7 +24,7 @@ use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
/**
|
||||
* Class CreateUsersTable
|
||||
* Class CreateUsersTable.
|
||||
*/
|
||||
class CreateUsersTable extends Migration
|
||||
{
|
||||
@ -46,7 +46,7 @@ class CreateUsersTable extends Migration
|
||||
if (!Schema::hasTable('users')) {
|
||||
Schema::create(
|
||||
'users',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->string('email', 255);
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* 2016_06_16_000002_create_main_tables.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -24,7 +24,7 @@ use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
/**
|
||||
* Class CreateMainTables
|
||||
* Class CreateMainTables.
|
||||
*/
|
||||
class CreateMainTables extends Migration
|
||||
{
|
||||
@ -84,15 +84,12 @@ class CreateMainTables extends Migration
|
||||
$this->createTransactionTables();
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private function createAccountTables(): void
|
||||
{
|
||||
if (!Schema::hasTable('accounts')) {
|
||||
Schema::create(
|
||||
'accounts',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
@ -112,7 +109,7 @@ class CreateMainTables extends Migration
|
||||
if (!Schema::hasTable('account_meta')) {
|
||||
Schema::create(
|
||||
'account_meta',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->integer('account_id', false, true);
|
||||
@ -124,15 +121,12 @@ class CreateMainTables extends Migration
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private function createAttachmentsTable(): void
|
||||
{
|
||||
if (!Schema::hasTable('attachments')) {
|
||||
Schema::create(
|
||||
'attachments',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
@ -155,15 +149,12 @@ class CreateMainTables extends Migration
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private function createBillsTable(): void
|
||||
{
|
||||
if (!Schema::hasTable('bills')) {
|
||||
Schema::create(
|
||||
'bills',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
@ -195,7 +186,7 @@ class CreateMainTables extends Migration
|
||||
if (!Schema::hasTable('budgets')) {
|
||||
Schema::create(
|
||||
'budgets',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
@ -210,7 +201,7 @@ class CreateMainTables extends Migration
|
||||
if (!Schema::hasTable('budget_limits')) {
|
||||
Schema::create(
|
||||
'budget_limits',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->integer('budget_id', false, true);
|
||||
@ -225,7 +216,7 @@ class CreateMainTables extends Migration
|
||||
if (!Schema::hasTable('limit_repetitions')) {
|
||||
Schema::create(
|
||||
'limit_repetitions',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->integer('budget_limit_id', false, true);
|
||||
@ -238,15 +229,12 @@ class CreateMainTables extends Migration
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private function createCategoriesTable(): void
|
||||
{
|
||||
if (!Schema::hasTable('categories')) {
|
||||
Schema::create(
|
||||
'categories',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
@ -261,15 +249,12 @@ class CreateMainTables extends Migration
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private function createExportJobsTable(): void
|
||||
{
|
||||
if (!Schema::hasTable('export_jobs')) {
|
||||
Schema::create(
|
||||
'export_jobs',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->integer('user_id', false, true);
|
||||
@ -283,7 +268,7 @@ class CreateMainTables extends Migration
|
||||
if (!Schema::hasTable('import_jobs')) {
|
||||
Schema::create(
|
||||
'import_jobs',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->integer('user_id')->unsigned();
|
||||
@ -297,15 +282,12 @@ class CreateMainTables extends Migration
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private function createPiggyBanksTable(): void
|
||||
{
|
||||
if (!Schema::hasTable('piggy_banks')) {
|
||||
Schema::create(
|
||||
'piggy_banks',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
@ -325,7 +307,7 @@ class CreateMainTables extends Migration
|
||||
if (!Schema::hasTable('piggy_bank_repetitions')) {
|
||||
Schema::create(
|
||||
'piggy_bank_repetitions',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->integer('piggy_bank_id', false, true);
|
||||
@ -338,15 +320,12 @@ class CreateMainTables extends Migration
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private function createPreferencesTable(): void
|
||||
{
|
||||
if (!Schema::hasTable('preferences')) {
|
||||
Schema::create(
|
||||
'preferences',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->integer('user_id', false, true);
|
||||
@ -359,15 +338,12 @@ class CreateMainTables extends Migration
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private function createRoleTable(): void
|
||||
{
|
||||
if (!Schema::hasTable('role_user')) {
|
||||
Schema::create(
|
||||
'role_user',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->integer('user_id', false, true);
|
||||
$table->integer('role_id', false, true);
|
||||
|
||||
@ -389,7 +365,7 @@ class CreateMainTables extends Migration
|
||||
if (!Schema::hasTable('rule_groups')) {
|
||||
Schema::create(
|
||||
'rule_groups',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
@ -407,7 +383,7 @@ class CreateMainTables extends Migration
|
||||
if (!Schema::hasTable('rules')) {
|
||||
Schema::create(
|
||||
'rules',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
@ -430,7 +406,7 @@ class CreateMainTables extends Migration
|
||||
if (!Schema::hasTable('rule_actions')) {
|
||||
Schema::create(
|
||||
'rule_actions',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->integer('rule_id', false, true);
|
||||
@ -450,7 +426,7 @@ class CreateMainTables extends Migration
|
||||
if (!Schema::hasTable('rule_triggers')) {
|
||||
Schema::create(
|
||||
'rule_triggers',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->integer('rule_id', false, true);
|
||||
@ -469,15 +445,12 @@ class CreateMainTables extends Migration
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private function createTagsTable(): void
|
||||
{
|
||||
if (!Schema::hasTable('tags')) {
|
||||
Schema::create(
|
||||
'tags',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
@ -508,7 +481,7 @@ class CreateMainTables extends Migration
|
||||
if (!Schema::hasTable('transaction_journals')) {
|
||||
Schema::create(
|
||||
'transaction_journals',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
@ -536,7 +509,7 @@ class CreateMainTables extends Migration
|
||||
if (!Schema::hasTable('journal_meta')) {
|
||||
Schema::create(
|
||||
'journal_meta',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->integer('transaction_journal_id', false, true);
|
||||
@ -551,7 +524,7 @@ class CreateMainTables extends Migration
|
||||
if (!Schema::hasTable('tag_transaction_journal')) {
|
||||
Schema::create(
|
||||
'tag_transaction_journal',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->integer('tag_id', false, true);
|
||||
$table->integer('transaction_journal_id', false, true);
|
||||
@ -567,7 +540,7 @@ class CreateMainTables extends Migration
|
||||
if (!Schema::hasTable('budget_transaction_journal')) {
|
||||
Schema::create(
|
||||
'budget_transaction_journal',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->integer('budget_id', false, true);
|
||||
$table->integer('transaction_journal_id', false, true);
|
||||
@ -580,7 +553,7 @@ class CreateMainTables extends Migration
|
||||
if (!Schema::hasTable('category_transaction_journal')) {
|
||||
Schema::create(
|
||||
'category_transaction_journal',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->integer('category_id', false, true);
|
||||
$table->integer('transaction_journal_id', false, true);
|
||||
@ -593,7 +566,7 @@ class CreateMainTables extends Migration
|
||||
if (!Schema::hasTable('piggy_bank_events')) {
|
||||
Schema::create(
|
||||
'piggy_bank_events',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->integer('piggy_bank_id', false, true);
|
||||
@ -610,7 +583,7 @@ class CreateMainTables extends Migration
|
||||
if (!Schema::hasTable('transactions')) {
|
||||
Schema::create(
|
||||
'transactions',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
@ -628,7 +601,7 @@ class CreateMainTables extends Migration
|
||||
if (!Schema::hasTable('budget_transaction')) {
|
||||
Schema::create(
|
||||
'budget_transaction',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->integer('budget_id', false, true);
|
||||
$table->integer('transaction_id', false, true);
|
||||
@ -642,7 +615,7 @@ class CreateMainTables extends Migration
|
||||
if (!Schema::hasTable('category_transaction')) {
|
||||
Schema::create(
|
||||
'category_transaction',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->integer('category_id', false, true);
|
||||
$table->integer('transaction_id', false, true);
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* 2016_08_25_091522_changes_for_3101.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -24,7 +24,7 @@ use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
/**
|
||||
* Class ChangesFor3101
|
||||
* Class ChangesFor3101.
|
||||
*/
|
||||
class ChangesFor3101 extends Migration
|
||||
{
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* 2016_09_12_121359_fix_nullables.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -24,7 +24,7 @@ use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
/**
|
||||
* Class FixNullables
|
||||
* Class FixNullables.
|
||||
*/
|
||||
class FixNullables extends Migration
|
||||
{
|
||||
@ -44,14 +44,14 @@ class FixNullables extends Migration
|
||||
{
|
||||
Schema::table(
|
||||
'rule_groups',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->text('description')->nullable()->change();
|
||||
}
|
||||
);
|
||||
|
||||
Schema::table(
|
||||
'rules',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->text('description')->nullable()->change();
|
||||
}
|
||||
);
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* 2016_10_09_150037_expand_transactions_table.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -24,7 +24,7 @@ use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
/**
|
||||
* Class ExpandTransactionsTable
|
||||
* Class ExpandTransactionsTable.
|
||||
*/
|
||||
class ExpandTransactionsTable extends Migration
|
||||
{
|
||||
@ -35,7 +35,7 @@ class ExpandTransactionsTable extends Migration
|
||||
{
|
||||
Schema::table(
|
||||
'transactions',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->dropColumn('identifier');
|
||||
}
|
||||
);
|
||||
@ -50,7 +50,7 @@ class ExpandTransactionsTable extends Migration
|
||||
{
|
||||
Schema::table(
|
||||
'transactions',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->smallInteger('identifier', false, true)->default(0);
|
||||
}
|
||||
);
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* 2016_10_22_075804_changes_for_v410.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -24,7 +24,7 @@ use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
/**
|
||||
* Class ChangesForV410
|
||||
* Class ChangesForV410.
|
||||
*/
|
||||
class ChangesForV410 extends Migration
|
||||
{
|
||||
@ -45,7 +45,7 @@ class ChangesForV410 extends Migration
|
||||
{
|
||||
Schema::create(
|
||||
'notes',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* 2016_11_24_210552_changes_for_v420.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -24,7 +24,7 @@ use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
/**
|
||||
* Class ChangesForV420
|
||||
* Class ChangesForV420.
|
||||
*/
|
||||
class ChangesForV420 extends Migration
|
||||
{
|
||||
@ -35,7 +35,7 @@ class ChangesForV420 extends Migration
|
||||
{
|
||||
Schema::table(
|
||||
'journal_meta',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->dropSoftDeletes();
|
||||
}
|
||||
);
|
||||
@ -50,7 +50,7 @@ class ChangesForV420 extends Migration
|
||||
{
|
||||
Schema::table(
|
||||
'journal_meta',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->softDeletes();
|
||||
}
|
||||
);
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* 2016_12_22_150431_changes_for_v430.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -24,7 +24,7 @@ use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
/**
|
||||
* Class ChangesForV430
|
||||
* Class ChangesForV430.
|
||||
*/
|
||||
class ChangesForV430 extends Migration
|
||||
{
|
||||
@ -45,7 +45,7 @@ class ChangesForV430 extends Migration
|
||||
{
|
||||
Schema::create(
|
||||
'available_budgets',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* 2016_12_28_203205_changes_for_v431.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -24,7 +24,7 @@ use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
/**
|
||||
* Class ChangesForV431
|
||||
* Class ChangesForV431.
|
||||
*/
|
||||
class ChangesForV431 extends Migration
|
||||
{
|
||||
@ -36,13 +36,13 @@ class ChangesForV431 extends Migration
|
||||
// reinstate "repeats" and "repeat_freq".
|
||||
Schema::table(
|
||||
'budget_limits',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->string('repeat_freq', 30)->nullable();
|
||||
}
|
||||
);
|
||||
Schema::table(
|
||||
'budget_limits',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->boolean('repeats')->default(0);
|
||||
}
|
||||
);
|
||||
@ -50,7 +50,7 @@ class ChangesForV431 extends Migration
|
||||
// change field "start_date" to "startdate"
|
||||
Schema::table(
|
||||
'budget_limits',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->renameColumn('start_date', 'startdate');
|
||||
}
|
||||
);
|
||||
@ -58,14 +58,14 @@ class ChangesForV431 extends Migration
|
||||
// remove date field "end_date"
|
||||
Schema::table(
|
||||
'budget_limits',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->dropColumn('end_date');
|
||||
}
|
||||
);
|
||||
// remove decimal places
|
||||
Schema::table(
|
||||
'transaction_currencies',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->dropColumn('decimal_places');
|
||||
}
|
||||
);
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* 2017_04_13_163623_changes_for_v440.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -24,7 +24,7 @@ use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
/**
|
||||
* Class ChangesForV440
|
||||
* Class ChangesForV440.
|
||||
*/
|
||||
class ChangesForV440 extends Migration
|
||||
{
|
||||
@ -83,8 +83,8 @@ class ChangesForV440 extends Migration
|
||||
'transactions',
|
||||
static function (Blueprint $table) {
|
||||
if (!Schema::hasColumn('transactions', 'transaction_currency_id')) {
|
||||
$table->integer('transaction_currency_id', false, true)->after('description')->nullable();
|
||||
$table->foreign('transaction_currency_id')->references('id')->on('transaction_currencies')->onDelete('set null');
|
||||
$table->integer('transaction_currency_id', false, true)->after('description')->nullable();
|
||||
$table->foreign('transaction_currency_id')->references('id')->on('transaction_currencies')->onDelete('set null');
|
||||
}
|
||||
}
|
||||
);
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* 2017_06_02_105232_changes_for_v450.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -24,7 +24,7 @@ use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
/**
|
||||
* Class ChangesForV450
|
||||
* Class ChangesForV450.
|
||||
*/
|
||||
class ChangesForV450 extends Migration
|
||||
{
|
||||
@ -38,7 +38,6 @@ class ChangesForV450 extends Migration
|
||||
'transactions',
|
||||
static function (Blueprint $table) {
|
||||
$table->dropColumn('foreign_amount');
|
||||
|
||||
}
|
||||
);
|
||||
|
||||
@ -70,7 +69,7 @@ class ChangesForV450 extends Migration
|
||||
// add "foreign_amount" to transactions
|
||||
Schema::table(
|
||||
'transactions',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->decimal('foreign_amount', 22, 12)->nullable()->after('amount');
|
||||
}
|
||||
);
|
||||
@ -78,7 +77,7 @@ class ChangesForV450 extends Migration
|
||||
// add foreign transaction currency id to transactions (is nullable):
|
||||
Schema::table(
|
||||
'transactions',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->integer('foreign_currency_id', false, true)->default(null)->after('foreign_amount')->nullable();
|
||||
$table->foreign('foreign_currency_id')->references('id')->on('transaction_currencies')->onDelete('set null');
|
||||
}
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* 2017_08_20_062014_changes_for_v470.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -25,7 +25,7 @@ use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
/**
|
||||
* Class ChangesForV470
|
||||
* Class ChangesForV470.
|
||||
*/
|
||||
class ChangesForV470 extends Migration
|
||||
{
|
||||
@ -48,7 +48,7 @@ class ChangesForV470 extends Migration
|
||||
if (!Schema::hasTable('link_types')) {
|
||||
Schema::create(
|
||||
'link_types',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
@ -65,7 +65,7 @@ class ChangesForV470 extends Migration
|
||||
if (!Schema::hasTable('journal_links')) {
|
||||
Schema::create(
|
||||
'journal_links',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->integer('link_type_id', false, true);
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* 2017_11_04_170844_changes_for_v470a.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -25,7 +25,7 @@ use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
/**
|
||||
* Class ChangesForV470a
|
||||
* Class ChangesForV470a.
|
||||
*/
|
||||
class ChangesForV470a extends Migration
|
||||
{
|
||||
@ -36,7 +36,7 @@ class ChangesForV470a extends Migration
|
||||
{
|
||||
Schema::table(
|
||||
'transactions',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->dropColumn('reconciled');
|
||||
}
|
||||
);
|
||||
@ -51,7 +51,7 @@ class ChangesForV470a extends Migration
|
||||
{
|
||||
Schema::table(
|
||||
'transactions',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->boolean('reconciled')->after('deleted_at')->default(0);
|
||||
}
|
||||
);
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* 2018_01_01_000001_create_oauth_auth_codes_table.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -27,7 +27,7 @@ use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
/**
|
||||
* Class CreateOauthAuthCodesTable
|
||||
* Class CreateOauthAuthCodesTable.
|
||||
*/
|
||||
class CreateOauthAuthCodesTable extends Migration
|
||||
{
|
||||
@ -46,14 +46,14 @@ class CreateOauthAuthCodesTable extends Migration
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create(
|
||||
'oauth_auth_codes', function (Blueprint $table) {
|
||||
$table->string('id', 100)->primary();
|
||||
$table->integer('user_id');
|
||||
$table->integer('client_id');
|
||||
$table->text('scopes')->nullable();
|
||||
$table->boolean('revoked');
|
||||
$table->dateTime('expires_at')->nullable();
|
||||
}
|
||||
'oauth_auth_codes', static function (Blueprint $table) {
|
||||
$table->string('id', 100)->primary();
|
||||
$table->integer('user_id');
|
||||
$table->integer('client_id');
|
||||
$table->text('scopes')->nullable();
|
||||
$table->boolean('revoked');
|
||||
$table->dateTime('expires_at')->nullable();
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* 2018_01_01_000002_create_oauth_access_tokens_table.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -27,7 +27,7 @@ use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
/**
|
||||
* Class CreateOauthAccessTokensTable
|
||||
* Class CreateOauthAccessTokensTable.
|
||||
*/
|
||||
class CreateOauthAccessTokensTable extends Migration
|
||||
{
|
||||
@ -46,16 +46,16 @@ class CreateOauthAccessTokensTable extends Migration
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create(
|
||||
'oauth_access_tokens', function (Blueprint $table) {
|
||||
$table->string('id', 100)->primary();
|
||||
$table->integer('user_id')->index()->nullable();
|
||||
$table->integer('client_id');
|
||||
$table->string('name')->nullable();
|
||||
$table->text('scopes')->nullable();
|
||||
$table->boolean('revoked');
|
||||
$table->timestamps();
|
||||
$table->dateTime('expires_at')->nullable();
|
||||
}
|
||||
'oauth_access_tokens', static function (Blueprint $table) {
|
||||
$table->string('id', 100)->primary();
|
||||
$table->integer('user_id')->index()->nullable();
|
||||
$table->integer('client_id');
|
||||
$table->string('name')->nullable();
|
||||
$table->text('scopes')->nullable();
|
||||
$table->boolean('revoked');
|
||||
$table->timestamps();
|
||||
$table->dateTime('expires_at')->nullable();
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* 2018_01_01_000003_create_oauth_refresh_tokens_table.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -27,7 +27,7 @@ use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
/**
|
||||
* Class CreateOauthRefreshTokensTable
|
||||
* Class CreateOauthRefreshTokensTable.
|
||||
*/
|
||||
class CreateOauthRefreshTokensTable extends Migration
|
||||
{
|
||||
@ -46,12 +46,12 @@ class CreateOauthRefreshTokensTable extends Migration
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create(
|
||||
'oauth_refresh_tokens', function (Blueprint $table) {
|
||||
$table->string('id', 100)->primary();
|
||||
$table->string('access_token_id', 100)->index();
|
||||
$table->boolean('revoked');
|
||||
$table->dateTime('expires_at')->nullable();
|
||||
}
|
||||
'oauth_refresh_tokens', static function (Blueprint $table) {
|
||||
$table->string('id', 100)->primary();
|
||||
$table->string('access_token_id', 100)->index();
|
||||
$table->boolean('revoked');
|
||||
$table->dateTime('expires_at')->nullable();
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* 2018_01_01_000004_create_oauth_clients_table.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -27,7 +27,7 @@ use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
/**
|
||||
* Class CreateOauthClientsTable
|
||||
* Class CreateOauthClientsTable.
|
||||
*/
|
||||
class CreateOauthClientsTable extends Migration
|
||||
{
|
||||
@ -46,17 +46,17 @@ class CreateOauthClientsTable extends Migration
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create(
|
||||
'oauth_clients', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->integer('user_id')->index()->nullable();
|
||||
$table->string('name');
|
||||
$table->string('secret', 100);
|
||||
$table->text('redirect');
|
||||
$table->boolean('personal_access_client');
|
||||
$table->boolean('password_client');
|
||||
$table->boolean('revoked');
|
||||
$table->timestamps();
|
||||
}
|
||||
'oauth_clients', static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->integer('user_id')->index()->nullable();
|
||||
$table->string('name');
|
||||
$table->string('secret', 100);
|
||||
$table->text('redirect');
|
||||
$table->boolean('personal_access_client');
|
||||
$table->boolean('password_client');
|
||||
$table->boolean('revoked');
|
||||
$table->timestamps();
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* 2018_01_01_000005_create_oauth_personal_access_clients_table.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -27,7 +27,7 @@ use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
/**
|
||||
* Class CreateOauthPersonalAccessClientsTable
|
||||
* Class CreateOauthPersonalAccessClientsTable.
|
||||
*/
|
||||
class CreateOauthPersonalAccessClientsTable extends Migration
|
||||
{
|
||||
@ -37,7 +37,6 @@ class CreateOauthPersonalAccessClientsTable extends Migration
|
||||
public function down(): void
|
||||
{
|
||||
Schema::drop('oauth_personal_access_clients');
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -47,11 +46,11 @@ class CreateOauthPersonalAccessClientsTable extends Migration
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create(
|
||||
'oauth_personal_access_clients', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->integer('client_id')->index();
|
||||
$table->timestamps();
|
||||
}
|
||||
'oauth_personal_access_clients', static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->integer('client_id')->index();
|
||||
$table->timestamps();
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* 2018_03_19_141348_changes_for_v472.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -26,7 +26,7 @@ use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
/**
|
||||
* Class ChangesForV472
|
||||
* Class ChangesForV472.
|
||||
*/
|
||||
class ChangesForV472 extends Migration
|
||||
{
|
||||
@ -39,13 +39,13 @@ class ChangesForV472 extends Migration
|
||||
{
|
||||
Schema::table(
|
||||
'attachments',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->text('notes')->nullable();
|
||||
}
|
||||
);
|
||||
Schema::table(
|
||||
'budgets',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->dropColumn('order');
|
||||
}
|
||||
);
|
||||
@ -61,14 +61,14 @@ class ChangesForV472 extends Migration
|
||||
{
|
||||
Schema::table(
|
||||
'attachments',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->dropColumn('notes');
|
||||
}
|
||||
);
|
||||
|
||||
Schema::table(
|
||||
'budgets',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->mediumInteger('order', false, true)->default(0);
|
||||
}
|
||||
);
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* 2018_04_07_210913_changes_for_v473.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -27,7 +27,7 @@ use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
/**
|
||||
* Class ChangesForV473
|
||||
* Class ChangesForV473.
|
||||
*/
|
||||
class ChangesForV473 extends Migration
|
||||
{
|
||||
@ -40,7 +40,7 @@ class ChangesForV473 extends Migration
|
||||
{
|
||||
Schema::table(
|
||||
'bills',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
|
||||
// cannot drop foreign keys in SQLite:
|
||||
if ('sqlite' !== config('database.default')) {
|
||||
@ -50,10 +50,9 @@ class ChangesForV473 extends Migration
|
||||
}
|
||||
);
|
||||
|
||||
|
||||
Schema::table(
|
||||
'rules',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->dropColumn('strict');
|
||||
}
|
||||
);
|
||||
@ -69,14 +68,14 @@ class ChangesForV473 extends Migration
|
||||
{
|
||||
Schema::table(
|
||||
'bills',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->integer('transaction_currency_id', false, true)->nullable()->after('user_id');
|
||||
$table->foreign('transaction_currency_id')->references('id')->on('transaction_currencies')->onDelete('set null');
|
||||
}
|
||||
);
|
||||
Schema::table(
|
||||
'rules',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->boolean('strict')->default(true);
|
||||
}
|
||||
);
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* 2018_04_29_174524_changes_for_v474.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -26,7 +26,7 @@ use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
/**
|
||||
* Class ChangesForV474
|
||||
* Class ChangesForV474.
|
||||
*/
|
||||
class ChangesForV474 extends Migration
|
||||
{
|
||||
@ -54,7 +54,6 @@ class ChangesForV474 extends Migration
|
||||
'import_jobs',
|
||||
static function (Blueprint $table) {
|
||||
$table->dropColumn('provider');
|
||||
|
||||
}
|
||||
);
|
||||
|
||||
@ -62,7 +61,6 @@ class ChangesForV474 extends Migration
|
||||
'import_jobs',
|
||||
static function (Blueprint $table) {
|
||||
$table->dropColumn('stage');
|
||||
|
||||
}
|
||||
);
|
||||
|
||||
@ -70,7 +68,6 @@ class ChangesForV474 extends Migration
|
||||
'import_jobs',
|
||||
static function (Blueprint $table) {
|
||||
$table->dropColumn('transactions');
|
||||
|
||||
}
|
||||
);
|
||||
|
||||
@ -78,7 +75,6 @@ class ChangesForV474 extends Migration
|
||||
'import_jobs',
|
||||
static function (Blueprint $table) {
|
||||
$table->dropColumn('errors');
|
||||
|
||||
}
|
||||
);
|
||||
|
||||
@ -86,7 +82,6 @@ class ChangesForV474 extends Migration
|
||||
'import_jobs',
|
||||
static function (Blueprint $table) {
|
||||
$table->dropColumn('tag_id');
|
||||
|
||||
}
|
||||
);
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* 2018_06_08_200526_changes_for_v475.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -26,8 +26,7 @@ use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
/**
|
||||
*
|
||||
* Class ChangesForV475
|
||||
* Class ChangesForV475.
|
||||
*/
|
||||
class ChangesForV475 extends Migration
|
||||
{
|
||||
@ -55,97 +54,93 @@ class ChangesForV475 extends Migration
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create(
|
||||
'recurrences', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
$table->integer('user_id', false, true);
|
||||
$table->integer('transaction_type_id', false, true);
|
||||
'recurrences', static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
$table->integer('user_id', false, true);
|
||||
$table->integer('transaction_type_id', false, true);
|
||||
|
||||
$table->string('title', 1024);
|
||||
$table->text('description');
|
||||
$table->string('title', 1024);
|
||||
$table->text('description');
|
||||
|
||||
$table->date('first_date');
|
||||
$table->date('repeat_until')->nullable();
|
||||
$table->date('latest_date')->nullable();
|
||||
$table->smallInteger('repetitions', false, true);
|
||||
$table->date('first_date');
|
||||
$table->date('repeat_until')->nullable();
|
||||
$table->date('latest_date')->nullable();
|
||||
$table->smallInteger('repetitions', false, true);
|
||||
|
||||
$table->boolean('apply_rules')->default(true);
|
||||
$table->boolean('active')->default(true);
|
||||
$table->boolean('apply_rules')->default(true);
|
||||
$table->boolean('active')->default(true);
|
||||
|
||||
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
|
||||
$table->foreign('transaction_type_id')->references('id')->on('transaction_types')->onDelete('cascade');
|
||||
}
|
||||
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
|
||||
$table->foreign('transaction_type_id')->references('id')->on('transaction_types')->onDelete('cascade');
|
||||
}
|
||||
);
|
||||
|
||||
Schema::create(
|
||||
'recurrences_transactions', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
$table->integer('recurrence_id', false, true);
|
||||
$table->integer('transaction_currency_id', false, true);
|
||||
$table->integer('foreign_currency_id', false, true)->nullable();
|
||||
$table->integer('source_id', false, true);
|
||||
$table->integer('destination_id', false, true);
|
||||
'recurrences_transactions', static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
$table->integer('recurrence_id', false, true);
|
||||
$table->integer('transaction_currency_id', false, true);
|
||||
$table->integer('foreign_currency_id', false, true)->nullable();
|
||||
$table->integer('source_id', false, true);
|
||||
$table->integer('destination_id', false, true);
|
||||
|
||||
$table->decimal('amount', 22, 12);
|
||||
$table->decimal('foreign_amount', 22, 12)->nullable();
|
||||
$table->string('description', 1024);
|
||||
$table->decimal('amount', 22, 12);
|
||||
$table->decimal('foreign_amount', 22, 12)->nullable();
|
||||
$table->string('description', 1024);
|
||||
|
||||
|
||||
$table->foreign('recurrence_id')->references('id')->on('recurrences')->onDelete('cascade');
|
||||
$table->foreign('transaction_currency_id')->references('id')->on('transaction_currencies')->onDelete('cascade');
|
||||
$table->foreign('foreign_currency_id')->references('id')->on('transaction_currencies')->onDelete('set null');
|
||||
$table->foreign('source_id')->references('id')->on('accounts')->onDelete('cascade');
|
||||
$table->foreign('destination_id')->references('id')->on('accounts')->onDelete('cascade');
|
||||
}
|
||||
);
|
||||
|
||||
|
||||
Schema::create(
|
||||
'recurrences_repetitions', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
$table->integer('recurrence_id', false, true);
|
||||
$table->string('repetition_type', 50);
|
||||
$table->string('repetition_moment', 50);
|
||||
$table->smallInteger('repetition_skip', false, true);
|
||||
$table->smallInteger('weekend', false, true);
|
||||
|
||||
$table->foreign('recurrence_id')->references('id')->on('recurrences')->onDelete('cascade');
|
||||
}
|
||||
$table->foreign('recurrence_id')->references('id')->on('recurrences')->onDelete('cascade');
|
||||
$table->foreign('transaction_currency_id')->references('id')->on('transaction_currencies')->onDelete('cascade');
|
||||
$table->foreign('foreign_currency_id')->references('id')->on('transaction_currencies')->onDelete('set null');
|
||||
$table->foreign('source_id')->references('id')->on('accounts')->onDelete('cascade');
|
||||
$table->foreign('destination_id')->references('id')->on('accounts')->onDelete('cascade');
|
||||
}
|
||||
);
|
||||
|
||||
Schema::create(
|
||||
'recurrences_meta', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
$table->integer('recurrence_id', false, true);
|
||||
'recurrences_repetitions', static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
$table->integer('recurrence_id', false, true);
|
||||
$table->string('repetition_type', 50);
|
||||
$table->string('repetition_moment', 50);
|
||||
$table->smallInteger('repetition_skip', false, true);
|
||||
$table->smallInteger('weekend', false, true);
|
||||
|
||||
$table->string('name', 50);
|
||||
$table->text('value');
|
||||
|
||||
$table->foreign('recurrence_id')->references('id')->on('recurrences')->onDelete('cascade');
|
||||
}
|
||||
$table->foreign('recurrence_id')->references('id')->on('recurrences')->onDelete('cascade');
|
||||
}
|
||||
);
|
||||
|
||||
Schema::create(
|
||||
'rt_meta', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
$table->integer('rt_id', false, true);
|
||||
'recurrences_meta', static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
$table->integer('recurrence_id', false, true);
|
||||
|
||||
$table->string('name', 50);
|
||||
$table->text('value');
|
||||
$table->string('name', 50);
|
||||
$table->text('value');
|
||||
|
||||
$table->foreign('rt_id')->references('id')->on('recurrences_transactions')->onDelete('cascade');
|
||||
}
|
||||
$table->foreign('recurrence_id')->references('id')->on('recurrences')->onDelete('cascade');
|
||||
}
|
||||
);
|
||||
|
||||
Schema::create(
|
||||
'rt_meta', static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
$table->integer('rt_id', false, true);
|
||||
|
||||
$table->string('name', 50);
|
||||
$table->text('value');
|
||||
|
||||
$table->foreign('rt_id')->references('id')->on('recurrences_transactions')->onDelete('cascade');
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* 2018_09_05_195147_changes_for_v477.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -26,8 +26,7 @@ use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
/**
|
||||
*
|
||||
* Class ChangesForV477
|
||||
* Class ChangesForV477.
|
||||
*/
|
||||
class ChangesForV477 extends Migration
|
||||
{
|
||||
@ -39,15 +38,15 @@ class ChangesForV477 extends Migration
|
||||
public function down(): void
|
||||
{
|
||||
Schema::table(
|
||||
'budget_limits', function (Blueprint $table) {
|
||||
'budget_limits', static function (Blueprint $table) {
|
||||
|
||||
// cannot drop foreign keys in SQLite:
|
||||
if ('sqlite' !== config('database.default')) {
|
||||
$table->dropForeign('budget_limits_transaction_currency_id_foreign');
|
||||
}
|
||||
if ('sqlite' !== config('database.default')) {
|
||||
$table->dropForeign('budget_limits_transaction_currency_id_foreign');
|
||||
}
|
||||
|
||||
$table->dropColumn(['transaction_currency_id']);
|
||||
}
|
||||
$table->dropColumn(['transaction_currency_id']);
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
@ -61,7 +60,7 @@ class ChangesForV477 extends Migration
|
||||
{
|
||||
Schema::table(
|
||||
'budget_limits',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->integer('transaction_currency_id', false, true)->nullable()->after('budget_id');
|
||||
$table->foreign('transaction_currency_id')->references('id')->on('transaction_currencies')->onDelete('set null');
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* 2018_11_06_172532_changes_for_v479.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -26,7 +26,7 @@ use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
/**
|
||||
* Class ChangesForV479
|
||||
* Class ChangesForV479.
|
||||
*/
|
||||
class ChangesForV479 extends Migration
|
||||
{
|
||||
@ -38,9 +38,9 @@ class ChangesForV479 extends Migration
|
||||
public function down()
|
||||
{
|
||||
Schema::table(
|
||||
'transaction_currencies', function (Blueprint $table) {
|
||||
$table->dropColumn(['enabled']);
|
||||
}
|
||||
'transaction_currencies', static function (Blueprint $table) {
|
||||
$table->dropColumn(['enabled']);
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
@ -54,7 +54,7 @@ class ChangesForV479 extends Migration
|
||||
{
|
||||
Schema::table(
|
||||
'transaction_currencies',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->boolean('enabled')->default(0)->after('deleted_at');
|
||||
}
|
||||
);
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* 2019_01_28_193833_changes_for_v4710.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -49,23 +49,22 @@ class ChangesForV4710 extends Migration
|
||||
{
|
||||
if (!Schema::hasTable('transaction_groups')) {
|
||||
Schema::create(
|
||||
'transaction_groups', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
$table->integer('user_id', false, true);
|
||||
$table->string('title', 1024)->nullable();
|
||||
'transaction_groups', static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
$table->integer('user_id', false, true);
|
||||
$table->string('title', 1024)->nullable();
|
||||
|
||||
|
||||
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
|
||||
}
|
||||
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
if (!Schema::hasTable('group_journals')) {
|
||||
Schema::create(
|
||||
'group_journals',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->integer('transaction_group_id', false, true);
|
||||
$table->integer('transaction_journal_id', false, true);
|
||||
@ -78,6 +77,5 @@ class ChangesForV4710 extends Migration
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* 2019_02_05_055516_changes_for_v4711.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -55,15 +55,15 @@ class ChangesForV4711 extends Migration
|
||||
* nice.
|
||||
*/
|
||||
Schema::table(
|
||||
'transaction_journals', function (Blueprint $table) {
|
||||
$table->dateTime('date')->change();
|
||||
}
|
||||
'transaction_journals', static function (Blueprint $table) {
|
||||
$table->dateTime('date')->change();
|
||||
}
|
||||
);
|
||||
|
||||
Schema::table(
|
||||
'preferences', function (Blueprint $table) {
|
||||
$table->text('data')->nullable()->change();
|
||||
}
|
||||
'preferences', static function (Blueprint $table) {
|
||||
$table->text('data')->nullable()->change();
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* 2019_02_11_170529_changes_for_v4712.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -26,7 +26,7 @@ use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
/**
|
||||
* Class ChangesForV4712
|
||||
* Class ChangesForV4712.
|
||||
*/
|
||||
class ChangesForV4712 extends Migration
|
||||
{
|
||||
@ -57,9 +57,9 @@ class ChangesForV4712 extends Migration
|
||||
* nice.
|
||||
*/
|
||||
Schema::table(
|
||||
'transaction_journals', function (Blueprint $table) {
|
||||
$table->dateTime('date')->change();
|
||||
}
|
||||
'transaction_journals', static function (Blueprint $table) {
|
||||
$table->dateTime('date')->change();
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* 2019_03_11_223700_fix_ldap_configuration.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -21,13 +21,12 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
/**
|
||||
* Class FixLdapConfiguration
|
||||
* Class FixLdapConfiguration.
|
||||
*/
|
||||
class FixLdapConfiguration extends Migration
|
||||
{
|
||||
@ -39,9 +38,9 @@ class FixLdapConfiguration extends Migration
|
||||
public function down(): void
|
||||
{
|
||||
Schema::table(
|
||||
'users', function (Blueprint $table) {
|
||||
$table->dropColumn(['objectguid']);
|
||||
}
|
||||
'users', static function (Blueprint $table) {
|
||||
$table->dropColumn(['objectguid']);
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
@ -58,9 +57,9 @@ class FixLdapConfiguration extends Migration
|
||||
* now. To support this, we add the column.
|
||||
*/
|
||||
Schema::table(
|
||||
'users', function (Blueprint $table) {
|
||||
$table->uuid('objectguid')->nullable()->after('id');
|
||||
}
|
||||
'users', static function (Blueprint $table) {
|
||||
$table->uuid('objectguid')->nullable()->after('id');
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* 2019_03_22_183214_changes_for_v480.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -21,12 +21,11 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
/**
|
||||
* Class ChangesForV480
|
||||
* Class ChangesForV480.
|
||||
*/
|
||||
class ChangesForV480 extends Migration
|
||||
{
|
||||
@ -39,7 +38,7 @@ class ChangesForV480 extends Migration
|
||||
{
|
||||
Schema::table(
|
||||
'transaction_journals',
|
||||
function (Blueprint $table) {
|
||||
static function (Blueprint $table) {
|
||||
// drop transaction_group_id + foreign key.
|
||||
// cannot drop foreign keys in SQLite:
|
||||
if ('sqlite' !== config('database.default')) {
|
||||
@ -50,14 +49,14 @@ class ChangesForV480 extends Migration
|
||||
);
|
||||
Schema::table(
|
||||
'rule_groups', static function (Blueprint $table) {
|
||||
$table->dropColumn('stop_processing');
|
||||
}
|
||||
$table->dropColumn('stop_processing');
|
||||
}
|
||||
);
|
||||
|
||||
Schema::table(
|
||||
'users', static function (Blueprint $table) {
|
||||
$table->dropColumn('mfa_secret');
|
||||
}
|
||||
$table->dropColumn('mfa_secret');
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
@ -69,11 +68,9 @@ class ChangesForV480 extends Migration
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
|
||||
Schema::table(
|
||||
'transaction_journals',
|
||||
static function (Blueprint $table) {
|
||||
|
||||
$table->integer('transaction_currency_id', false, true)->nullable()->change();
|
||||
|
||||
// add column "group_id" after "transaction_type_id"
|
||||
@ -86,13 +83,13 @@ class ChangesForV480 extends Migration
|
||||
);
|
||||
Schema::table(
|
||||
'rule_groups', static function (Blueprint $table) {
|
||||
$table->boolean('stop_processing')->default(false);
|
||||
}
|
||||
$table->boolean('stop_processing')->default(false);
|
||||
}
|
||||
);
|
||||
Schema::table(
|
||||
'users', static function (Blueprint $table) {
|
||||
$table->string('mfa_secret', 50)->nullable();
|
||||
}
|
||||
$table->string('mfa_secret', 50)->nullable();
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* 2019_12_28_191351_make_locations_table.php
|
||||
* Copyright (c) 2020 james@firefly-iii.org
|
||||
* Copyright (c) 2020 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -27,7 +27,7 @@ use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
/**
|
||||
* Class MakeLocationsTable
|
||||
* Class MakeLocationsTable.
|
||||
*/
|
||||
class MakeLocationsTable extends Migration
|
||||
{
|
||||
@ -50,17 +50,17 @@ class MakeLocationsTable extends Migration
|
||||
{
|
||||
Schema::create(
|
||||
'locations', static function (Blueprint $table) {
|
||||
$table->bigIncrements('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
$table->bigIncrements('id');
|
||||
$table->timestamps();
|
||||
$table->softDeletes();
|
||||
|
||||
$table->integer('locatable_id', false, true);
|
||||
$table->string('locatable_type', 255);
|
||||
$table->integer('locatable_id', false, true);
|
||||
$table->string('locatable_type', 255);
|
||||
|
||||
$table->decimal('latitude', 24, 12)->nullable();
|
||||
$table->decimal('longitude', 24, 12)->nullable();
|
||||
$table->smallInteger('zoom_level', false, true)->nullable();
|
||||
}
|
||||
$table->decimal('latitude', 24, 12)->nullable();
|
||||
$table->decimal('longitude', 24, 12)->nullable();
|
||||
$table->smallInteger('zoom_level', false, true)->nullable();
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
|
@ -1,10 +1,12 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
/**
|
||||
* Class ChangesForV520
|
||||
* Class ChangesForV520.
|
||||
*/
|
||||
class ChangesForV520 extends Migration
|
||||
{
|
||||
@ -38,7 +40,6 @@ class ChangesForV520 extends Migration
|
||||
$table->decimal('amount', 22, 12);
|
||||
$table->string('period', 50);
|
||||
|
||||
|
||||
//$table->string('password', 60);
|
||||
//$table->string('remember_token', 100)->nullable();
|
||||
//$table->string('reset', 32)->nullable();
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* AccountTypeSeeder.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -24,7 +24,7 @@ use FireflyIII\Models\AccountType;
|
||||
use Illuminate\Database\Seeder;
|
||||
|
||||
/**
|
||||
* Class AccountTypeSeeder
|
||||
* Class AccountTypeSeeder.
|
||||
*/
|
||||
class AccountTypeSeeder extends Seeder
|
||||
{
|
||||
|
@ -1,9 +1,10 @@
|
||||
<?php declare(strict_types=1);
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* ConfigSeeder.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -25,7 +26,7 @@ use FireflyIII\Models\Configuration;
|
||||
use Illuminate\Database\Seeder;
|
||||
|
||||
/**
|
||||
* Class ConfigSeeder
|
||||
* Class ConfigSeeder.
|
||||
*/
|
||||
class ConfigSeeder extends Seeder
|
||||
{
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* DatabaseSeeder.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -23,7 +23,7 @@ declare(strict_types=1);
|
||||
use Illuminate\Database\Seeder;
|
||||
|
||||
/**
|
||||
* Class DatabaseSeeder
|
||||
* Class DatabaseSeeder.
|
||||
*/
|
||||
class DatabaseSeeder extends Seeder
|
||||
{
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* LinkTypeSeeder.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -24,13 +24,10 @@ use FireflyIII\Models\LinkType;
|
||||
use Illuminate\Database\Seeder;
|
||||
|
||||
/**
|
||||
* Class LinkTypeSeeder
|
||||
* Class LinkTypeSeeder.
|
||||
*/
|
||||
class LinkTypeSeeder extends Seeder
|
||||
{
|
||||
/**
|
||||
*
|
||||
*/
|
||||
public function run()
|
||||
{
|
||||
$types = [
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* PermissionSeeder.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -24,7 +24,7 @@ use FireflyIII\Models\Role;
|
||||
use Illuminate\Database\Seeder;
|
||||
|
||||
/**
|
||||
* Class PermissionSeeder
|
||||
* Class PermissionSeeder.
|
||||
*/
|
||||
class PermissionSeeder extends Seeder
|
||||
{
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* TransactionCurrencySeeder.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -24,7 +24,7 @@ use FireflyIII\Models\TransactionCurrency;
|
||||
use Illuminate\Database\Seeder;
|
||||
|
||||
/**
|
||||
* Class TransactionCurrencySeeder
|
||||
* Class TransactionCurrencySeeder.
|
||||
*/
|
||||
class TransactionCurrencySeeder extends Seeder
|
||||
{
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* TransactionTypeSeeder.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -24,7 +24,7 @@ use FireflyIII\Models\TransactionType;
|
||||
use Illuminate\Database\Seeder;
|
||||
|
||||
/**
|
||||
* Class TransactionTypeSeeder
|
||||
* Class TransactionTypeSeeder.
|
||||
*/
|
||||
class TransactionTypeSeeder extends Seeder
|
||||
{
|
||||
|
149
routes/api.php
149
routes/api.php
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* api.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -22,11 +22,10 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
|
||||
Route::group(
|
||||
[
|
||||
'namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'about',
|
||||
'as' => 'api.v1.about.'],
|
||||
'as' => 'api.v1.about.', ],
|
||||
static function () {
|
||||
|
||||
// Accounts API routes:
|
||||
@ -35,10 +34,9 @@ Route::group(
|
||||
}
|
||||
);
|
||||
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'accounts',
|
||||
'as' => 'api.v1.accounts.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'accounts',
|
||||
'as' => 'api.v1.accounts.', ],
|
||||
static function () {
|
||||
|
||||
// Accounts API routes:
|
||||
@ -50,13 +48,12 @@ Route::group(
|
||||
|
||||
Route::get('{account}/piggy_banks', ['uses' => 'AccountController@piggyBanks', 'as' => 'piggy_banks']);
|
||||
Route::get('{account}/transactions', ['uses' => 'AccountController@transactions', 'as' => 'transactions']);
|
||||
|
||||
}
|
||||
);
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'attachments',
|
||||
'as' => 'api.v1.attachments.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'attachments',
|
||||
'as' => 'api.v1.attachments.', ],
|
||||
static function () {
|
||||
|
||||
// Attachment API routes:
|
||||
@ -71,8 +68,8 @@ Route::group(
|
||||
);
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'available_budgets',
|
||||
'as' => 'api.v1.available_budgets.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'available_budgets',
|
||||
'as' => 'api.v1.available_budgets.', ],
|
||||
static function () {
|
||||
|
||||
// Available Budget API routes:
|
||||
@ -85,26 +82,25 @@ Route::group(
|
||||
);
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'bills',
|
||||
'as' => 'api.v1.bills.'], static function () {
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'bills',
|
||||
'as' => 'api.v1.bills.', ], static function () {
|
||||
|
||||
// Bills API routes:
|
||||
Route::get('', ['uses' => 'BillController@index', 'as' => 'index']);
|
||||
Route::post('', ['uses' => 'BillController@store', 'as' => 'store']);
|
||||
Route::get('{bill}', ['uses' => 'BillController@show', 'as' => 'show']);
|
||||
Route::put('{bill}', ['uses' => 'BillController@update', 'as' => 'update']);
|
||||
Route::delete('{bill}', ['uses' => 'BillController@delete', 'as' => 'delete']);
|
||||
Route::get('', ['uses' => 'BillController@index', 'as' => 'index']);
|
||||
Route::post('', ['uses' => 'BillController@store', 'as' => 'store']);
|
||||
Route::get('{bill}', ['uses' => 'BillController@show', 'as' => 'show']);
|
||||
Route::put('{bill}', ['uses' => 'BillController@update', 'as' => 'update']);
|
||||
Route::delete('{bill}', ['uses' => 'BillController@delete', 'as' => 'delete']);
|
||||
|
||||
Route::get('{bill}/attachments', ['uses' => 'BillController@attachments', 'as' => 'attachments']);
|
||||
Route::get('{bill}/rules', ['uses' => 'BillController@rules', 'as' => 'rules']);
|
||||
Route::get('{bill}/transactions', ['uses' => 'BillController@transactions', 'as' => 'transactions']);
|
||||
}
|
||||
Route::get('{bill}/attachments', ['uses' => 'BillController@attachments', 'as' => 'attachments']);
|
||||
Route::get('{bill}/rules', ['uses' => 'BillController@rules', 'as' => 'rules']);
|
||||
Route::get('{bill}/transactions', ['uses' => 'BillController@transactions', 'as' => 'transactions']);
|
||||
}
|
||||
);
|
||||
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'budgets/limits',
|
||||
'as' => 'api.v1.budget_limits.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'budgets/limits',
|
||||
'as' => 'api.v1.budget_limits.', ],
|
||||
static function () {
|
||||
|
||||
// Budget Limit API routes:
|
||||
@ -118,8 +114,8 @@ Route::group(
|
||||
);
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'budgets',
|
||||
'as' => 'api.v1.budgets.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'budgets',
|
||||
'as' => 'api.v1.budgets.', ],
|
||||
static function () {
|
||||
|
||||
// Budget API routes:
|
||||
@ -135,8 +131,8 @@ Route::group(
|
||||
);
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'categories',
|
||||
'as' => 'api.v1.categories.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'categories',
|
||||
'as' => 'api.v1.categories.', ],
|
||||
static function () {
|
||||
|
||||
// Category API routes:
|
||||
@ -150,25 +146,24 @@ Route::group(
|
||||
);
|
||||
|
||||
/**
|
||||
* CHART ROUTES
|
||||
* CHART ROUTES.
|
||||
*/
|
||||
|
||||
// Accounts
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers\Chart', 'prefix' => 'chart/account',
|
||||
'as' => 'api.v1.chart.account.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers\Chart', 'prefix' => 'chart/account',
|
||||
'as' => 'api.v1.chart.account.', ],
|
||||
static function () {
|
||||
Route::get('overview', ['uses' => 'AccountController@overview', 'as' => 'overview']);
|
||||
Route::get('expense', ['uses' => 'AccountController@expenseOverview', 'as' => 'expense']);
|
||||
Route::get('revenue', ['uses' => 'AccountController@revenueOverview', 'as' => 'revenue']);
|
||||
|
||||
}
|
||||
);
|
||||
|
||||
// Available budgets
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers\Chart', 'prefix' => 'chart/ab',
|
||||
'as' => 'api.v1.chart.ab.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers\Chart', 'prefix' => 'chart/ab',
|
||||
'as' => 'api.v1.chart.ab.', ],
|
||||
static function () {
|
||||
|
||||
// Overview API routes:
|
||||
@ -178,8 +173,8 @@ Route::group(
|
||||
|
||||
// Categories
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers\Chart', 'prefix' => 'chart/category',
|
||||
'as' => 'api.v1.chart.category.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers\Chart', 'prefix' => 'chart/category',
|
||||
'as' => 'api.v1.chart.category.', ],
|
||||
static function () {
|
||||
|
||||
// Overview API routes:
|
||||
@ -187,13 +182,9 @@ Route::group(
|
||||
}
|
||||
);
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'configuration',
|
||||
'as' => 'api.v1.configuration.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'configuration',
|
||||
'as' => 'api.v1.configuration.', ],
|
||||
static function () {
|
||||
|
||||
// Configuration API routes:
|
||||
@ -203,8 +194,8 @@ Route::group(
|
||||
);
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'cer',
|
||||
'as' => 'api.v1.cer.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'cer',
|
||||
'as' => 'api.v1.cer.', ],
|
||||
static function () {
|
||||
|
||||
// Currency Exchange Rate API routes:
|
||||
@ -213,8 +204,8 @@ Route::group(
|
||||
);
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'import',
|
||||
'as' => 'api.v1.import.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'import',
|
||||
'as' => 'api.v1.import.', ],
|
||||
static function () {
|
||||
|
||||
// Transaction Links API routes:
|
||||
@ -224,8 +215,8 @@ Route::group(
|
||||
}
|
||||
);
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'link_types',
|
||||
'as' => 'api.v1.link_types.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'link_types',
|
||||
'as' => 'api.v1.link_types.', ],
|
||||
static function () {
|
||||
|
||||
// Link Type API routes:
|
||||
@ -239,8 +230,8 @@ Route::group(
|
||||
);
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'transaction_links',
|
||||
'as' => 'api.v1.transaction_links.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'transaction_links',
|
||||
'as' => 'api.v1.transaction_links.', ],
|
||||
static function () {
|
||||
|
||||
// Transaction Links API routes:
|
||||
@ -249,13 +240,12 @@ Route::group(
|
||||
Route::get('{journalLink}', ['uses' => 'TransactionLinkController@show', 'as' => 'show']);
|
||||
Route::put('{journalLink}', ['uses' => 'TransactionLinkController@update', 'as' => 'update']);
|
||||
Route::delete('{journalLink}', ['uses' => 'TransactionLinkController@delete', 'as' => 'delete']);
|
||||
|
||||
}
|
||||
);
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'piggy_banks',
|
||||
'as' => 'api.v1.piggy_banks.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'piggy_banks',
|
||||
'as' => 'api.v1.piggy_banks.', ],
|
||||
static function () {
|
||||
|
||||
// Piggy Bank API routes:
|
||||
@ -269,8 +259,8 @@ Route::group(
|
||||
);
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'preferences',
|
||||
'as' => 'api.v1.preferences.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'preferences',
|
||||
'as' => 'api.v1.preferences.', ],
|
||||
static function () {
|
||||
|
||||
// Preference API routes:
|
||||
@ -281,8 +271,8 @@ Route::group(
|
||||
);
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'recurrences',
|
||||
'as' => 'api.v1.recurrences.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'recurrences',
|
||||
'as' => 'api.v1.recurrences.', ],
|
||||
static function () {
|
||||
|
||||
// Recurrence API routes:
|
||||
@ -297,8 +287,8 @@ Route::group(
|
||||
);
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'rules',
|
||||
'as' => 'api.v1.rules.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'rules',
|
||||
'as' => 'api.v1.rules.', ],
|
||||
static function () {
|
||||
|
||||
// Rules API routes:
|
||||
@ -315,8 +305,8 @@ Route::group(
|
||||
);
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'rule_groups',
|
||||
'as' => 'api.v1.rule_groups.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'rule_groups',
|
||||
'as' => 'api.v1.rule_groups.', ],
|
||||
static function () {
|
||||
|
||||
// Rules API routes:
|
||||
@ -335,8 +325,8 @@ Route::group(
|
||||
);
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers\Search', 'prefix' => 'search',
|
||||
'as' => 'api.v1.search.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers\Search', 'prefix' => 'search',
|
||||
'as' => 'api.v1.search.', ],
|
||||
static function () {
|
||||
|
||||
// Attachment API routes:
|
||||
@ -347,19 +337,18 @@ Route::group(
|
||||
);
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'summary',
|
||||
'as' => 'api.v1.summary.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'summary',
|
||||
'as' => 'api.v1.summary.', ],
|
||||
static function () {
|
||||
|
||||
// Overview API routes:
|
||||
Route::get('basic', ['uses' => 'SummaryController@basic', 'as' => 'basic']);
|
||||
|
||||
}
|
||||
);
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'currencies',
|
||||
'as' => 'api.v1.currencies.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'currencies',
|
||||
'as' => 'api.v1.currencies.', ],
|
||||
static function () {
|
||||
|
||||
// Transaction currency API routes:
|
||||
@ -385,8 +374,8 @@ Route::group(
|
||||
);
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'tags',
|
||||
'as' => 'api.v1.tags.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'tags',
|
||||
'as' => 'api.v1.tags.', ],
|
||||
static function () {
|
||||
// Tag API routes:
|
||||
Route::get('', ['uses' => 'TagController@index', 'as' => 'index']);
|
||||
@ -399,18 +388,17 @@ Route::group(
|
||||
);
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'tag-cloud',
|
||||
'as' => 'api.v1.tag-cloud.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'tag-cloud',
|
||||
'as' => 'api.v1.tag-cloud.', ],
|
||||
static function () {
|
||||
// Tag cloud API routes (to prevent collisions)
|
||||
Route::get('', ['uses' => 'TagController@cloud', 'as' => 'cloud']);
|
||||
}
|
||||
);
|
||||
|
||||
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'transactions',
|
||||
'as' => 'api.v1.transactions.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'transactions',
|
||||
'as' => 'api.v1.transactions.', ],
|
||||
static function () {
|
||||
|
||||
// Transaction API routes:
|
||||
@ -427,8 +415,8 @@ Route::group(
|
||||
|
||||
// special group for transaction journals
|
||||
Route::group(
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'transaction-journals',
|
||||
'as' => 'api.v1.journals.'],
|
||||
['namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'transaction-journals',
|
||||
'as' => 'api.v1.journals.', ],
|
||||
static function () {
|
||||
|
||||
// Transaction API routes:
|
||||
@ -436,10 +424,9 @@ Route::group(
|
||||
}
|
||||
);
|
||||
|
||||
|
||||
Route::group(
|
||||
['middleware' => ['auth:api', 'bindings', \FireflyIII\Http\Middleware\IsAdmin::class], 'namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'users',
|
||||
'as' => 'api.v1.users.'],
|
||||
['middleware' => ['auth:api', 'bindings', \FireflyIII\Http\Middleware\IsAdmin::class], 'namespace' => 'FireflyIII\Api\V1\Controllers', 'prefix' => 'users',
|
||||
'as' => 'api.v1.users.', ],
|
||||
static function () {
|
||||
|
||||
// Users API routes:
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/**
|
||||
* breadcrumbs.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -68,14 +68,14 @@ try {
|
||||
// HOME
|
||||
Breadcrumbs::register(
|
||||
'home',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->push(trans('breadcrumbs.home'), route('index'));
|
||||
}
|
||||
);
|
||||
|
||||
Breadcrumbs::register(
|
||||
'index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->push(trans('breadcrumbs.home'), route('index'));
|
||||
}
|
||||
);
|
||||
@ -83,7 +83,7 @@ try {
|
||||
// ACCOUNTS
|
||||
Breadcrumbs::register(
|
||||
'accounts.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, string $what) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, string $what) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('firefly.' . strtolower(e($what)) . '_accounts'), route('accounts.index', [$what]));
|
||||
}
|
||||
@ -98,7 +98,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'accounts.create',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, string $what) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, string $what) {
|
||||
$breadcrumbs->parent('accounts.index', $what);
|
||||
$breadcrumbs->push(trans('firefly.new_' . strtolower(e($what)) . '_account'), route('accounts.create', [$what]));
|
||||
}
|
||||
@ -106,7 +106,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'accounts.show',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Account $account, Carbon $start = null, Carbon $end = null) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Account $account, Carbon $start = null, Carbon $end = null) {
|
||||
$what = config('firefly.shortNamesByFullName.' . $account->accountType->type);
|
||||
|
||||
$breadcrumbs->parent('accounts.index', $what);
|
||||
@ -114,8 +114,8 @@ try {
|
||||
if (null !== $start && null !== $end) {
|
||||
$title = trans(
|
||||
'firefly.between_dates_breadcrumb',
|
||||
['start' => $start ? $start->formatLocalized((string)trans('config.month_and_day')) : '',
|
||||
'end' => $end ? $end->formatLocalized((string)trans('config.month_and_day')) : '',]
|
||||
['start' => $start ? $start->formatLocalized((string)trans('config.month_and_day')) : '',
|
||||
'end' => $end ? $end->formatLocalized((string)trans('config.month_and_day')) : '', ]
|
||||
);
|
||||
$breadcrumbs->push($title, route('accounts.show', $account));
|
||||
}
|
||||
@ -124,7 +124,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'accounts.show.all',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Account $account) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Account $account) {
|
||||
$what = config('firefly.shortNamesByFullName.' . $account->accountType->type);
|
||||
|
||||
$breadcrumbs->parent('accounts.index', $what);
|
||||
@ -134,7 +134,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'accounts.reconcile',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Account $account) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Account $account) {
|
||||
$breadcrumbs->parent('accounts.show', $account);
|
||||
$breadcrumbs->push(trans('firefly.reconcile_account', ['account' => $account->name]), route('accounts.reconcile', [$account->id]));
|
||||
}
|
||||
@ -142,7 +142,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'accounts.reconcile.show',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Account $account, TransactionJournal $journal) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Account $account, TransactionJournal $journal) {
|
||||
$breadcrumbs->parent('accounts.show', $account);
|
||||
$title = trans('firefly.reconciliation') . ' "' . $journal->description . '"';
|
||||
$breadcrumbs->push($title, route('accounts.reconcile.show', [$journal->id]));
|
||||
@ -151,7 +151,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'accounts.delete',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Account $account) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Account $account) {
|
||||
$breadcrumbs->parent('accounts.show', $account);
|
||||
$breadcrumbs->push(trans('firefly.delete_account', ['name' => limitStringLength($account->name)]), route('accounts.delete', [$account->id]));
|
||||
}
|
||||
@ -159,7 +159,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'accounts.edit',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Account $account) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Account $account) {
|
||||
$breadcrumbs->parent('accounts.show', $account);
|
||||
$what = config('firefly.shortNamesByFullName.' . $account->accountType->type);
|
||||
|
||||
@ -172,7 +172,7 @@ try {
|
||||
// ADMIN
|
||||
Breadcrumbs::register(
|
||||
'admin.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('firefly.administration'), route('admin.index'));
|
||||
}
|
||||
@ -180,7 +180,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'admin.users',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('admin.index');
|
||||
$breadcrumbs->push(trans('firefly.list_all_users'), route('admin.users'));
|
||||
}
|
||||
@ -188,21 +188,21 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'admin.users.show',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, User $user) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, User $user) {
|
||||
$breadcrumbs->parent('admin.users');
|
||||
$breadcrumbs->push(trans('firefly.single_user_administration', ['email' => $user->email]), route('admin.users.show', [$user->id]));
|
||||
}
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'admin.users.edit',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, User $user) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, User $user) {
|
||||
$breadcrumbs->parent('admin.users');
|
||||
$breadcrumbs->push(trans('firefly.edit_user', ['email' => $user->email]), route('admin.users.edit', [$user->id]));
|
||||
}
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'admin.users.delete',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, User $user) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, User $user) {
|
||||
$breadcrumbs->parent('admin.users');
|
||||
$breadcrumbs->push(trans('firefly.delete_user', ['email' => $user->email]), route('admin.users.delete', [$user->id]));
|
||||
}
|
||||
@ -210,7 +210,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'admin.users.domains',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('admin.index');
|
||||
$breadcrumbs->push(trans('firefly.blocked_domains'), route('admin.users.domains'));
|
||||
}
|
||||
@ -218,14 +218,14 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'admin.configuration.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('admin.index');
|
||||
$breadcrumbs->push(trans('firefly.instance_configuration'), route('admin.configuration.index'));
|
||||
}
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'admin.update-check',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('admin.index');
|
||||
$breadcrumbs->push(trans('firefly.update_check_title'), route('admin.update-check'));
|
||||
}
|
||||
@ -233,7 +233,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'admin.links.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('admin.index');
|
||||
$breadcrumbs->push(trans('firefly.journal_link_configuration'), route('admin.links.index'));
|
||||
}
|
||||
@ -241,7 +241,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'admin.links.create',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('admin.links.index');
|
||||
$breadcrumbs->push(trans('firefly.create_new_link_type'), route('admin.links.create'));
|
||||
}
|
||||
@ -249,7 +249,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'admin.links.show',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, LinkType $linkType) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, LinkType $linkType) {
|
||||
$breadcrumbs->parent('admin.links.index');
|
||||
$breadcrumbs->push(trans('firefly.overview_for_link', ['name' => limitStringLength($linkType->name)]), route('admin.links.show', [$linkType->id]));
|
||||
}
|
||||
@ -257,7 +257,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'admin.links.edit',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, LinkType $linkType) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, LinkType $linkType) {
|
||||
$breadcrumbs->parent('admin.links.index');
|
||||
$breadcrumbs->push(trans('firefly.edit_link_type', ['name' => limitStringLength($linkType->name)]), route('admin.links.edit', [$linkType->id]));
|
||||
}
|
||||
@ -265,7 +265,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'admin.links.delete',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, LinkType $linkType) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, LinkType $linkType) {
|
||||
$breadcrumbs->parent('admin.links.index');
|
||||
$breadcrumbs->push(trans('firefly.delete_link_type', ['name' => limitStringLength($linkType->name)]), route('admin.links.delete', [$linkType->id]));
|
||||
}
|
||||
@ -289,7 +289,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'transactions.link.delete',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, TransactionJournalLink $link) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, TransactionJournalLink $link) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('breadcrumbs.delete_journal_link'), route('transactions.link.delete', $link->id));
|
||||
}
|
||||
@ -298,7 +298,7 @@ try {
|
||||
// ATTACHMENTS
|
||||
Breadcrumbs::register(
|
||||
'attachments.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('firefly.attachments'), route('attachments.index'));
|
||||
}
|
||||
@ -306,7 +306,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'attachments.edit',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Attachment $attachment) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Attachment $attachment) {
|
||||
$object = $attachment->attachable;
|
||||
if ($object instanceof TransactionJournal) {
|
||||
$group = $object->transactionGroup;
|
||||
@ -323,7 +323,7 @@ try {
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'attachments.delete',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Attachment $attachment) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Attachment $attachment) {
|
||||
$object = $attachment->attachable;
|
||||
if ($object instanceof TransactionJournal) {
|
||||
$breadcrumbs->parent('transactions.show', $object->transactionGroup);
|
||||
@ -340,14 +340,14 @@ try {
|
||||
// BILLS
|
||||
Breadcrumbs::register(
|
||||
'bills.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('breadcrumbs.bills'), route('bills.index'));
|
||||
}
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'bills.create',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('bills.index');
|
||||
$breadcrumbs->push(trans('breadcrumbs.newBill'), route('bills.create'));
|
||||
}
|
||||
@ -355,14 +355,14 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'bills.edit',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Bill $bill) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Bill $bill) {
|
||||
$breadcrumbs->parent('bills.show', $bill);
|
||||
$breadcrumbs->push(trans('breadcrumbs.edit_bill', ['name' => limitStringLength($bill->name)]), route('bills.edit', [$bill->id]));
|
||||
}
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'bills.delete',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Bill $bill) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Bill $bill) {
|
||||
$breadcrumbs->parent('bills.show', $bill);
|
||||
$breadcrumbs->push(trans('breadcrumbs.delete_bill', ['name' => limitStringLength($bill->name)]), route('bills.delete', [$bill->id]));
|
||||
}
|
||||
@ -370,7 +370,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'bills.show',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Bill $bill) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Bill $bill) {
|
||||
$breadcrumbs->parent('bills.index');
|
||||
$breadcrumbs->push(limitStringLength($bill->name), route('bills.show', [$bill->id]));
|
||||
}
|
||||
@ -379,14 +379,14 @@ try {
|
||||
// BUDGETS
|
||||
Breadcrumbs::register(
|
||||
'budgets.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('firefly.budgets'), route('budgets.index'));
|
||||
}
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'budgets.create',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('budgets.index');
|
||||
$breadcrumbs->push(trans('firefly.create_new_budget'), route('budgets.create'));
|
||||
}
|
||||
@ -394,14 +394,14 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'budgets.edit',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Budget $budget) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Budget $budget) {
|
||||
$breadcrumbs->parent('budgets.show', $budget);
|
||||
$breadcrumbs->push(trans('firefly.edit_budget', ['name' => limitStringLength($budget->name)]), route('budgets.edit', [$budget->id]));
|
||||
}
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'budgets.delete',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Budget $budget) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Budget $budget) {
|
||||
$breadcrumbs->parent('budgets.show', $budget);
|
||||
$breadcrumbs->push(trans('firefly.delete_budget', ['name' => limitStringLength($budget->name)]), route('budgets.delete', [$budget->id]));
|
||||
}
|
||||
@ -409,14 +409,14 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'budgets.no-budget',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Carbon $start = null, Carbon $end = null) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Carbon $start = null, Carbon $end = null) {
|
||||
$breadcrumbs->parent('budgets.index');
|
||||
$breadcrumbs->push(trans('firefly.journals_without_budget'), route('budgets.no-budget'));
|
||||
if (null !== $start && null !== $end) {
|
||||
$title = trans(
|
||||
'firefly.between_dates_breadcrumb',
|
||||
['start' => $start->formatLocalized((string)trans('config.month_and_day')),
|
||||
'end' => $end->formatLocalized((string)trans('config.month_and_day')),]
|
||||
['start' => $start->formatLocalized((string)trans('config.month_and_day')),
|
||||
'end' => $end->formatLocalized((string)trans('config.month_and_day')), ]
|
||||
);
|
||||
$breadcrumbs->push($title, route('budgets.no-budget'));
|
||||
}
|
||||
@ -425,7 +425,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'budgets.no-budget-all',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('budgets.index');
|
||||
$breadcrumbs->push(trans('firefly.journals_without_budget'), route('budgets.no-budget'));
|
||||
$breadcrumbs->push(trans('firefly.everything'), route('budgets.no-budget-all'));
|
||||
@ -434,7 +434,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'budgets.show',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Budget $budget) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Budget $budget) {
|
||||
$breadcrumbs->parent('budgets.index');
|
||||
$breadcrumbs->push(limitStringLength($budget->name), route('budgets.show', [$budget->id]));
|
||||
$breadcrumbs->push(trans('firefly.everything'), route('budgets.show', [$budget->id]));
|
||||
@ -443,14 +443,14 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'budgets.show.limit',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Budget $budget, BudgetLimit $budgetLimit) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Budget $budget, BudgetLimit $budgetLimit) {
|
||||
$breadcrumbs->parent('budgets.index');
|
||||
$breadcrumbs->push(limitStringLength($budget->name), route('budgets.show', [$budget->id]));
|
||||
|
||||
$title = trans(
|
||||
'firefly.between_dates_breadcrumb',
|
||||
['start' => $budgetLimit->start_date->formatLocalized((string)trans('config.month_and_day')),
|
||||
'end' => $budgetLimit->end_date->formatLocalized((string)trans('config.month_and_day')),]
|
||||
['start' => $budgetLimit->start_date->formatLocalized((string)trans('config.month_and_day')),
|
||||
'end' => $budgetLimit->end_date->formatLocalized((string)trans('config.month_and_day')), ]
|
||||
);
|
||||
|
||||
$breadcrumbs->push(
|
||||
@ -463,14 +463,14 @@ try {
|
||||
// CATEGORIES
|
||||
Breadcrumbs::register(
|
||||
'categories.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('firefly.categories'), route('categories.index'));
|
||||
}
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'categories.create',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('categories.index');
|
||||
$breadcrumbs->push(trans('firefly.new_category'), route('categories.create'));
|
||||
}
|
||||
@ -478,14 +478,14 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'categories.edit',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Category $category) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Category $category) {
|
||||
$breadcrumbs->parent('categories.show.all', $category);
|
||||
$breadcrumbs->push(trans('firefly.edit_category', ['name' => limitStringLength($category->name)]), route('categories.edit', [$category->id]));
|
||||
}
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'categories.delete',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Category $category) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Category $category) {
|
||||
$breadcrumbs->parent('categories.show', $category);
|
||||
$breadcrumbs->push(trans('firefly.delete_category', ['name' => limitStringLength($category->name)]), route('categories.delete', [$category->id]));
|
||||
}
|
||||
@ -493,14 +493,14 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'categories.show',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Category $category, Carbon $start = null, Carbon $end = null) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Category $category, Carbon $start = null, Carbon $end = null) {
|
||||
$breadcrumbs->parent('categories.index');
|
||||
$breadcrumbs->push(limitStringLength($category->name), route('categories.show', [$category->id]));
|
||||
if (null !== $start && null !== $end) {
|
||||
$title = trans(
|
||||
'firefly.between_dates_breadcrumb',
|
||||
['start' => $start->formatLocalized((string)trans('config.month_and_day')),
|
||||
'end' => $end->formatLocalized((string)trans('config.month_and_day')),]
|
||||
['start' => $start->formatLocalized((string)trans('config.month_and_day')),
|
||||
'end' => $end->formatLocalized((string)trans('config.month_and_day')), ]
|
||||
);
|
||||
$breadcrumbs->push($title, route('categories.show', [$category->id]));
|
||||
}
|
||||
@ -509,7 +509,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'categories.show.all',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Category $category) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Category $category) {
|
||||
$breadcrumbs->parent('categories.index');
|
||||
$breadcrumbs->push(limitStringLength($category->name), route('categories.show', [$category->id]));
|
||||
$breadcrumbs->push(trans('firefly.everything'), route('categories.show.all', [$category->id]));
|
||||
@ -518,24 +518,23 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'categories.no-category',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Carbon $start = null, Carbon $end = null) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Carbon $start = null, Carbon $end = null) {
|
||||
$breadcrumbs->parent('categories.index');
|
||||
$breadcrumbs->push(trans('firefly.journals_without_category'), route('categories.no-category'));
|
||||
if (null !== $start && null !== $end) {
|
||||
$title = trans(
|
||||
'firefly.between_dates_breadcrumb',
|
||||
['start' => $start->formatLocalized((string)trans('config.month_and_day')),
|
||||
'end' => $end->formatLocalized((string)trans('config.month_and_day')),]
|
||||
['start' => $start->formatLocalized((string)trans('config.month_and_day')),
|
||||
'end' => $end->formatLocalized((string)trans('config.month_and_day')), ]
|
||||
);
|
||||
$breadcrumbs->push($title, route('categories.no-category'));
|
||||
}
|
||||
}
|
||||
);
|
||||
|
||||
|
||||
Breadcrumbs::register(
|
||||
'categories.no-category.all',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('categories.index');
|
||||
$breadcrumbs->push(trans('firefly.journals_without_category'), route('categories.no-category'));
|
||||
$breadcrumbs->push(trans('firefly.everything'), route('categories.no-category.all'));
|
||||
@ -545,7 +544,7 @@ try {
|
||||
// CURRENCIES
|
||||
Breadcrumbs::register(
|
||||
'currencies.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('firefly.currencies'), route('currencies.index'));
|
||||
}
|
||||
@ -553,7 +552,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'currencies.create',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('currencies.index');
|
||||
$breadcrumbs->push(trans('firefly.create_currency'), route('currencies.create'));
|
||||
}
|
||||
@ -561,14 +560,14 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'currencies.edit',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, TransactionCurrency $currency) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, TransactionCurrency $currency) {
|
||||
$breadcrumbs->parent('currencies.index');
|
||||
$breadcrumbs->push(trans('breadcrumbs.edit_currency', ['name' => $currency->name]), route('currencies.edit', [$currency->id]));
|
||||
}
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'currencies.delete',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, TransactionCurrency $currency) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, TransactionCurrency $currency) {
|
||||
$breadcrumbs->parent('currencies.index');
|
||||
$breadcrumbs->push(trans('breadcrumbs.delete_currency', ['name' => $currency->name]), route('currencies.delete', [$currency->id]));
|
||||
}
|
||||
@ -577,7 +576,7 @@ try {
|
||||
// EXPORT
|
||||
Breadcrumbs::register(
|
||||
'export.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('firefly.export_data_bc'), route('export.index'));
|
||||
}
|
||||
@ -586,14 +585,14 @@ try {
|
||||
// PIGGY BANKS
|
||||
Breadcrumbs::register(
|
||||
'piggy-banks.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('firefly.piggyBanks'), route('piggy-banks.index'));
|
||||
}
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'piggy-banks.create',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('piggy-banks.index');
|
||||
$breadcrumbs->push(trans('breadcrumbs.newPiggyBank'), route('piggy-banks.create'));
|
||||
}
|
||||
@ -601,14 +600,14 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'piggy-banks.edit',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, PiggyBank $piggyBank) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, PiggyBank $piggyBank) {
|
||||
$breadcrumbs->parent('piggy-banks.show', $piggyBank);
|
||||
$breadcrumbs->push(trans('breadcrumbs.edit_piggyBank', ['name' => $piggyBank->name]), route('piggy-banks.edit', [$piggyBank->id]));
|
||||
}
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'piggy-banks.delete',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, PiggyBank $piggyBank) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, PiggyBank $piggyBank) {
|
||||
$breadcrumbs->parent('piggy-banks.show', $piggyBank);
|
||||
$breadcrumbs->push(trans('firefly.delete_piggy_bank', ['name' => $piggyBank->name]), route('piggy-banks.delete', [$piggyBank->id]));
|
||||
}
|
||||
@ -616,7 +615,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'piggy-banks.show',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, PiggyBank $piggyBank) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, PiggyBank $piggyBank) {
|
||||
$breadcrumbs->parent('piggy-banks.index');
|
||||
$breadcrumbs->push($piggyBank->name, route('piggy-banks.show', [$piggyBank->id]));
|
||||
}
|
||||
@ -624,7 +623,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'piggy-banks.add-money-mobile',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, PiggyBank $piggyBank) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, PiggyBank $piggyBank) {
|
||||
$breadcrumbs->parent('piggy-banks.show', $piggyBank);
|
||||
$breadcrumbs->push(trans('firefly.add_money_to_piggy', ['name' => $piggyBank->name]), route('piggy-banks.add-money-mobile', [$piggyBank->id]));
|
||||
}
|
||||
@ -632,7 +631,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'piggy-banks.remove-money-mobile',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, PiggyBank $piggyBank) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, PiggyBank $piggyBank) {
|
||||
$breadcrumbs->parent('piggy-banks.show', $piggyBank);
|
||||
$breadcrumbs->push(
|
||||
trans('firefly.remove_money_from_piggy_title', ['name' => $piggyBank->name]),
|
||||
@ -644,7 +643,7 @@ try {
|
||||
// IMPORT
|
||||
Breadcrumbs::register(
|
||||
'import.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('firefly.import_index_title'), route('import.index'));
|
||||
}
|
||||
@ -652,7 +651,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'import.prerequisites.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, string $importProvider) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, string $importProvider) {
|
||||
$breadcrumbs->parent('import.index');
|
||||
$breadcrumbs->push(trans('import.prerequisites_breadcrumb_' . $importProvider), route('import.prerequisites.index', [$importProvider]));
|
||||
}
|
||||
@ -660,7 +659,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'import.job.configuration.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, ImportJob $job) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, ImportJob $job) {
|
||||
$breadcrumbs->parent('import.index');
|
||||
$breadcrumbs->push(trans('import.job_configuration_breadcrumb', ['key' => $job->key]), route('import.job.configuration.index', [$job->key]));
|
||||
}
|
||||
@ -668,17 +667,16 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'import.job.status.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, ImportJob $job) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, ImportJob $job) {
|
||||
$breadcrumbs->parent('import.index');
|
||||
$breadcrumbs->push(trans('import.job_status_breadcrumb', ['key' => $job->key]), route('import.job.status.index', [$job->key]));
|
||||
}
|
||||
);
|
||||
|
||||
|
||||
// PREFERENCES
|
||||
Breadcrumbs::register(
|
||||
'preferences.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('breadcrumbs.preferences'), route('preferences.index'));
|
||||
}
|
||||
@ -686,7 +684,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'profile.code',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('breadcrumbs.profile'), route('profile.index'));
|
||||
}
|
||||
@ -694,7 +692,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'profile.new-backup-codes',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('breadcrumbs.profile'), route('profile.index'));
|
||||
}
|
||||
@ -703,14 +701,14 @@ try {
|
||||
// PROFILE
|
||||
Breadcrumbs::register(
|
||||
'profile.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('breadcrumbs.profile'), route('profile.index'));
|
||||
}
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'profile.change-password',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('profile.index');
|
||||
$breadcrumbs->push(trans('breadcrumbs.changePassword'), route('profile.change-password'));
|
||||
}
|
||||
@ -718,7 +716,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'profile.change-email',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('profile.index');
|
||||
$breadcrumbs->push(trans('breadcrumbs.change_email'), route('profile.change-email'));
|
||||
}
|
||||
@ -726,7 +724,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'profile.delete-account',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('profile.index');
|
||||
$breadcrumbs->push(trans('firefly.delete_account'), route('profile.delete-account'));
|
||||
}
|
||||
@ -735,7 +733,7 @@ try {
|
||||
// REPORTS
|
||||
Breadcrumbs::register(
|
||||
'reports.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('breadcrumbs.reports'), route('reports.index'));
|
||||
}
|
||||
@ -743,7 +741,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'reports.report.audit',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, string $accountIds, Carbon $start, Carbon $end) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, string $accountIds, Carbon $start, Carbon $end) {
|
||||
$breadcrumbs->parent('reports.index');
|
||||
|
||||
$monthFormat = (string)trans('config.month_and_day');
|
||||
@ -756,7 +754,7 @@ try {
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'reports.report.budget',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, string $accountIds, string $budgetIds, Carbon $start, Carbon $end) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, string $accountIds, string $budgetIds, Carbon $start, Carbon $end) {
|
||||
$breadcrumbs->parent('reports.index');
|
||||
|
||||
$monthFormat = (string)trans('config.month_and_day');
|
||||
@ -770,7 +768,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'reports.report.tag',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, string $accountIds, string $tagTags, Carbon $start, Carbon $end) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, string $accountIds, string $tagTags, Carbon $start, Carbon $end) {
|
||||
$breadcrumbs->parent('reports.index');
|
||||
|
||||
$monthFormat = (string)trans('config.month_and_day');
|
||||
@ -784,7 +782,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'reports.report.category',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, string $accountIds, string $categoryIds, Carbon $start, Carbon $end) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, string $accountIds, string $categoryIds, Carbon $start, Carbon $end) {
|
||||
$breadcrumbs->parent('reports.index');
|
||||
|
||||
$monthFormat = (string)trans('config.month_and_day');
|
||||
@ -798,7 +796,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'reports.report.double',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, string $accountIds, string $doubleIds, Carbon $start, Carbon $end) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, string $accountIds, string $doubleIds, Carbon $start, Carbon $end) {
|
||||
$breadcrumbs->parent('reports.index');
|
||||
|
||||
$monthFormat = (string)trans('config.month_and_day');
|
||||
@ -812,7 +810,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'reports.report.default',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, string $accountIds, Carbon $start, Carbon $end) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, string $accountIds, Carbon $start, Carbon $end) {
|
||||
$breadcrumbs->parent('reports.index');
|
||||
|
||||
$monthFormat = (string)trans('config.month_and_day');
|
||||
@ -827,7 +825,7 @@ try {
|
||||
// New user Controller
|
||||
Breadcrumbs::register(
|
||||
'new-user.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('firefly.getting_started'), route('new-user.index'));
|
||||
}
|
||||
@ -836,14 +834,14 @@ try {
|
||||
// Recurring transactions controller:
|
||||
Breadcrumbs::register(
|
||||
'recurring.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('firefly.recurrences'), route('recurring.index'));
|
||||
}
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'recurring.show',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Recurrence $recurrence) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Recurrence $recurrence) {
|
||||
$breadcrumbs->parent('recurring.index');
|
||||
$breadcrumbs->push($recurrence->title, route('recurring.show', [$recurrence->id]));
|
||||
}
|
||||
@ -851,7 +849,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'recurring.delete',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Recurrence $recurrence) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Recurrence $recurrence) {
|
||||
$breadcrumbs->parent('recurring.index');
|
||||
$breadcrumbs->push(trans('firefly.delete_recurring', ['title' => $recurrence->title]), route('recurring.delete', [$recurrence->id]));
|
||||
}
|
||||
@ -859,7 +857,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'recurring.edit',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Recurrence $recurrence) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Recurrence $recurrence) {
|
||||
$breadcrumbs->parent('recurring.index');
|
||||
$breadcrumbs->push(trans('firefly.edit_recurrence', ['title' => $recurrence->title]), route('recurring.edit', [$recurrence->id]));
|
||||
}
|
||||
@ -867,7 +865,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'recurring.create',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('recurring.index');
|
||||
$breadcrumbs->push(trans('firefly.create_new_recurrence'), route('recurring.create'));
|
||||
}
|
||||
@ -876,7 +874,7 @@ try {
|
||||
// Rules
|
||||
Breadcrumbs::register(
|
||||
'rules.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('firefly.rules'), route('rules.index'));
|
||||
}
|
||||
@ -884,7 +882,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'rules.create',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, RuleGroup $ruleGroup = null) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, RuleGroup $ruleGroup = null) {
|
||||
$breadcrumbs->parent('rules.index');
|
||||
if (null === $ruleGroup) {
|
||||
$breadcrumbs->push(trans('firefly.make_new_rule_no_group'), route('rules.create'));
|
||||
@ -892,13 +890,12 @@ try {
|
||||
if (null !== $ruleGroup) {
|
||||
$breadcrumbs->push(trans('firefly.make_new_rule', ['title' => $ruleGroup->title]), route('rules.create', [$ruleGroup]));
|
||||
}
|
||||
|
||||
}
|
||||
);
|
||||
|
||||
Breadcrumbs::register(
|
||||
'rules.create-from-bill',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('rules.index');
|
||||
$breadcrumbs->push(trans('firefly.make_new_rule_no_group'), route('rules.create'));
|
||||
}
|
||||
@ -906,7 +903,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'rules.create-from-journal',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('rules.index');
|
||||
$breadcrumbs->push(trans('firefly.make_new_rule_no_group'), route('rules.create'));
|
||||
}
|
||||
@ -914,35 +911,35 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'rules.edit',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Rule $rule) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Rule $rule) {
|
||||
$breadcrumbs->parent('rules.index');
|
||||
$breadcrumbs->push(trans('firefly.edit_rule', ['title' => $rule->title]), route('rules.edit', [$rule]));
|
||||
}
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'rules.delete',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Rule $rule) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Rule $rule) {
|
||||
$breadcrumbs->parent('rules.index');
|
||||
$breadcrumbs->push(trans('firefly.delete_rule', ['title' => $rule->title]), route('rules.delete', [$rule]));
|
||||
}
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'rule-groups.create',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('rules.index');
|
||||
$breadcrumbs->push(trans('firefly.make_new_rule_group'), route('rule-groups.create'));
|
||||
}
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'rule-groups.edit',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, RuleGroup $ruleGroup) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, RuleGroup $ruleGroup) {
|
||||
$breadcrumbs->parent('rules.index');
|
||||
$breadcrumbs->push(trans('firefly.edit_rule_group', ['title' => $ruleGroup->title]), route('rule-groups.edit', [$ruleGroup]));
|
||||
}
|
||||
);
|
||||
Breadcrumbs::register(
|
||||
'rule-groups.delete',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, RuleGroup $ruleGroup) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, RuleGroup $ruleGroup) {
|
||||
$breadcrumbs->parent('rules.index');
|
||||
$breadcrumbs->push(trans('firefly.delete_rule_group', ['title' => $ruleGroup->title]), route('rule-groups.delete', [$ruleGroup]));
|
||||
}
|
||||
@ -950,7 +947,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'rules.select-transactions',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Rule $rule) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Rule $rule) {
|
||||
$breadcrumbs->parent('rules.index');
|
||||
$breadcrumbs->push(
|
||||
trans('firefly.rule_select_transactions', ['title' => $rule->title]), route('rules.select-transactions', [$rule])
|
||||
@ -960,7 +957,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'rule-groups.select-transactions',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, RuleGroup $ruleGroup) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, RuleGroup $ruleGroup) {
|
||||
$breadcrumbs->parent('rules.index');
|
||||
$breadcrumbs->push(
|
||||
trans('firefly.rule_group_select_transactions', ['title' => $ruleGroup->title]), route('rule-groups.select-transactions', [$ruleGroup])
|
||||
@ -971,7 +968,7 @@ try {
|
||||
// SEARCH
|
||||
Breadcrumbs::register(
|
||||
'search.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, $query) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, $query) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('breadcrumbs.search_result', ['query' => $query]), route('search.index'));
|
||||
}
|
||||
@ -980,7 +977,7 @@ try {
|
||||
// TAGS
|
||||
Breadcrumbs::register(
|
||||
'tags.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('breadcrumbs.tags'), route('tags.index'));
|
||||
}
|
||||
@ -988,7 +985,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'tags.create',
|
||||
function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs) {
|
||||
$breadcrumbs->parent('tags.index');
|
||||
$breadcrumbs->push(trans('breadcrumbs.createTag'), route('tags.create'));
|
||||
}
|
||||
@ -996,7 +993,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'tags.edit',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Tag $tag) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Tag $tag) {
|
||||
$breadcrumbs->parent('tags.show', $tag);
|
||||
$breadcrumbs->push(trans('breadcrumbs.edit_tag', ['tag' => $tag->tag]), route('tags.edit', [$tag->id]));
|
||||
}
|
||||
@ -1004,7 +1001,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'tags.delete',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Tag $tag) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Tag $tag) {
|
||||
$breadcrumbs->parent('tags.show', $tag);
|
||||
$breadcrumbs->push(trans('breadcrumbs.delete_tag', ['tag' => $tag->tag]), route('tags.delete', [$tag->id]));
|
||||
}
|
||||
@ -1012,25 +1009,24 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'tags.show',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Tag $tag, Carbon $start = null, Carbon $end = null) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Tag $tag, Carbon $start = null, Carbon $end = null) {
|
||||
$breadcrumbs->parent('tags.index');
|
||||
|
||||
$breadcrumbs->push($tag->tag, route('tags.show', [$tag->id, $start, $end]));
|
||||
if (null !== $start && $end !== null) {
|
||||
if (null !== $start && null !== $end) {
|
||||
$title = trans(
|
||||
'firefly.between_dates_breadcrumb',
|
||||
['start' => $start->formatLocalized((string)trans('config.month_and_day')),
|
||||
'end' => $end->formatLocalized((string)trans('config.month_and_day')),]
|
||||
['start' => $start->formatLocalized((string)trans('config.month_and_day')),
|
||||
'end' => $end->formatLocalized((string)trans('config.month_and_day')), ]
|
||||
);
|
||||
$breadcrumbs->push($title, route('tags.show', [$tag->id, $start, $end]));
|
||||
}
|
||||
}
|
||||
);
|
||||
|
||||
|
||||
Breadcrumbs::register(
|
||||
'tags.show.all',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, Tag $tag) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, Tag $tag) {
|
||||
$breadcrumbs->parent('tags.index');
|
||||
$breadcrumbs->push($tag->tag, route('tags.show', [$tag->id]));
|
||||
$title = (string)trans('firefly.all_journals_for_tag', ['tag' => $tag->tag]);
|
||||
@ -1042,7 +1038,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'transactions.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, string $what, Carbon $start = null, Carbon $end = null) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, string $what, Carbon $start = null, Carbon $end = null) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('breadcrumbs.' . $what . '_list'), route('transactions.index', [$what]));
|
||||
|
||||
@ -1050,8 +1046,8 @@ try {
|
||||
// add date range:
|
||||
$title = trans(
|
||||
'firefly.between_dates_breadcrumb',
|
||||
['start' => $start->formatLocalized((string)trans('config.month_and_day')),
|
||||
'end' => $end->formatLocalized((string)trans('config.month_and_day')),]
|
||||
['start' => $start->formatLocalized((string)trans('config.month_and_day')),
|
||||
'end' => $end->formatLocalized((string)trans('config.month_and_day')), ]
|
||||
);
|
||||
$breadcrumbs->push($title, route('transactions.index', [$what, $start, $end]));
|
||||
}
|
||||
@ -1060,7 +1056,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'transactions.index.all',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, string $what) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, string $what) {
|
||||
$breadcrumbs->parent('home');
|
||||
$breadcrumbs->push(trans('breadcrumbs.' . $what . '_list'), route('transactions.index', [$what]));
|
||||
}
|
||||
@ -1068,7 +1064,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'transactions.create',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, string $objectType) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, string $objectType) {
|
||||
$breadcrumbs->parent('transactions.index', $objectType);
|
||||
$breadcrumbs->push(trans('breadcrumbs.create_new_transaction'), route('transactions.create', [$objectType]));
|
||||
}
|
||||
@ -1076,7 +1072,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'transactions.edit',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, TransactionGroup $group) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, TransactionGroup $group) {
|
||||
$breadcrumbs->parent('transactions.show', $group);
|
||||
|
||||
/** @var TransactionJournal $first */
|
||||
@ -1091,7 +1087,7 @@ try {
|
||||
// also edit reconciliations:
|
||||
Breadcrumbs::register(
|
||||
'accounts.reconcile.edit',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, TransactionJournal $journal) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, TransactionJournal $journal) {
|
||||
$breadcrumbs->parent('transactions.show', $journal);
|
||||
$breadcrumbs->push(
|
||||
trans('breadcrumbs.edit_reconciliation', ['description' => limitStringLength($journal->description)]),
|
||||
@ -1123,14 +1119,16 @@ try {
|
||||
if ($group->transactionJournals()->count() > 1) {
|
||||
$title = limitStringLength($group->title);
|
||||
}
|
||||
if('opening balance' === $type) {
|
||||
if ('opening balance' === $type) {
|
||||
// TODO link to account.
|
||||
$breadcrumbs->push($title, route('transactions.show', [$group->id]));
|
||||
|
||||
return;
|
||||
}
|
||||
if('reconciliation' === $type) {
|
||||
if ('reconciliation' === $type) {
|
||||
// TODO link to account.
|
||||
$breadcrumbs->push($title, route('transactions.show', [$group->id]));
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
@ -1141,7 +1139,7 @@ try {
|
||||
|
||||
Breadcrumbs::register(
|
||||
'transactions.convert.index',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, TransactionGroup $group, string $groupTitle) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, TransactionGroup $group, string $groupTitle) {
|
||||
$breadcrumbs->parent('transactions.show', $group);
|
||||
$breadcrumbs->push(
|
||||
trans('firefly.breadcrumb_convert_group', ['description' => limitStringLength($groupTitle)]),
|
||||
@ -1194,7 +1192,7 @@ try {
|
||||
// SPLIT
|
||||
Breadcrumbs::register(
|
||||
'transactions.split.edit',
|
||||
function (BreadcrumbsGenerator $breadcrumbs, TransactionJournal $journal) {
|
||||
static function (BreadcrumbsGenerator $breadcrumbs, TransactionJournal $journal) {
|
||||
$breadcrumbs->parent('transactions.show', $journal);
|
||||
$breadcrumbs->push(trans('breadcrumbs.edit_journal', ['description' => $journal->description]), route('transactions.split.edit', [$journal->id]));
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* channels.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -22,7 +22,6 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Broadcast Channels
|
||||
@ -35,7 +34,7 @@ declare(strict_types=1);
|
||||
*/
|
||||
|
||||
Broadcast::channel(
|
||||
'App.User.{id}', function ($user, $id) {
|
||||
return (int)$user->id === (int)$id;
|
||||
}
|
||||
'App.User.{id}', static function ($user, $id) {
|
||||
return (int)$user->id === (int)$id;
|
||||
}
|
||||
);
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* console.php
|
||||
* Copyright (c) 2019 james@firefly-iii.org
|
||||
* Copyright (c) 2019 james@firefly-iii.org.
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
@ -21,4 +21,3 @@
|
||||
*/
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
|
927
routes/web.php
927
routes/web.php
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user