Currency code expansion.

This commit is contained in:
James Cole
2021-05-13 05:52:06 +02:00
parent 53dffc961f
commit 3f1bd6b3f1
9 changed files with 139 additions and 107 deletions

View File

@@ -72,8 +72,8 @@ class StoreRequest extends FormRequest
{
return [
'name' => 'required|between:1,255|unique:transaction_currencies,name',
'code' => 'required|between:3,3|unique:transaction_currencies,code',
'symbol' => 'required|between:1,8|unique:transaction_currencies,symbol',
'code' => 'required|between:3,51|unique:transaction_currencies,code',
'symbol' => 'required|between:1,51|unique:transaction_currencies,symbol',
'decimal_places' => 'between:0,20|numeric|min:0|max:20',
'enabled' => [new IsBoolean()],
'default' => [new IsBoolean()],

View File

@@ -71,8 +71,8 @@ class UpdateRequest extends FormRequest
return [
'name' => sprintf('between:1,255|unique:transaction_currencies,name,%d', $currency->id),
'code' => sprintf('between:3,3|unique:transaction_currencies,code,%d', $currency->id),
'symbol' => sprintf('between:1,8|unique:transaction_currencies,symbol,%d', $currency->id),
'code' => sprintf('between:3,51|unique:transaction_currencies,code,%d', $currency->id),
'symbol' => sprintf('between:1,51|unique:transaction_currencies,symbol,%d', $currency->id),
'decimal_places' => 'between:0,20|numeric|min:0|max:20',
'enabled' => [new IsBoolean()],
'default' => [new IsBoolean()],

View File

@@ -39,11 +39,8 @@ use Log;
*/
class CurrencyController extends Controller
{
/** @var CurrencyRepositoryInterface The currency repository */
protected $repository;
/** @var UserRepositoryInterface The user repository */
protected $userRepository;
protected CurrencyRepositoryInterface $repository;
protected UserRepositoryInterface $userRepository;
/**
* CurrencyController constructor.

View File

@@ -60,8 +60,8 @@ class CurrencyFormRequest extends FormRequest
// fixed
$rules = [
'name' => 'required|max:48|min:1|unique:transaction_currencies,name',
'code' => 'required|min:3|max:3|unique:transaction_currencies,code',
'symbol' => 'required|min:1|max:8|unique:transaction_currencies,symbol',
'code' => 'required|min:3|max:51|unique:transaction_currencies,code',
'symbol' => 'required|min:1|max:51|unique:transaction_currencies,symbol',
'decimal_places' => 'required|min:0|max:12|numeric',
'enabled' => 'in:0,1',
];
@@ -72,8 +72,8 @@ class CurrencyFormRequest extends FormRequest
if (null !== $currency) {
$rules = [
'name' => 'required|max:48|min:1',
'code' => 'required|min:3|max:3',
'symbol' => 'required|min:1|max:8',
'code' => 'required|min:3|max:51',
'symbol' => 'required|min:1|max:51',
'decimal_places' => 'required|min:0|max:12|numeric',
'enabled' => 'in:0,1',
];

View File

@@ -161,9 +161,6 @@ class Amount
$currencyCode = $this->tryDecrypt((string)$currencyPrefStr);
// could still be json encoded:
if (strlen($currencyCode) > 3) {
$currencyCode = json_decode($currencyCode, true, 512, JSON_THROW_ON_ERROR) ?? 'EUR';
}
/** @var TransactionCurrency|null $currency */
$currency = TransactionCurrency::where('code', $currencyCode)->first();
if (null === $currency) {

176
composer.lock generated
View File

@@ -1683,16 +1683,16 @@
},
{
"name": "laravel/framework",
"version": "v8.40.0",
"version": "v8.41.0",
"source": {
"type": "git",
"url": "https://github.com/laravel/framework.git",
"reference": "a654897ad7f97aea9d7ef292803939798c4a02a4"
"reference": "05417155d886df8710e55c84e12622b52d83c47c"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/laravel/framework/zipball/a654897ad7f97aea9d7ef292803939798c4a02a4",
"reference": "a654897ad7f97aea9d7ef292803939798c4a02a4",
"url": "https://api.github.com/repos/laravel/framework/zipball/05417155d886df8710e55c84e12622b52d83c47c",
"reference": "05417155d886df8710e55c84e12622b52d83c47c",
"shasum": ""
},
"require": {
@@ -1800,7 +1800,7 @@
"phpunit/phpunit": "Required to use assertions and run tests (^8.5.8|^9.3.3).",
"predis/predis": "Required to use the predis connector (^1.1.2).",
"psr/http-message": "Required to allow Storage::put to accept a StreamInterface (^1.0).",
"pusher/pusher-php-server": "Required to use the Pusher broadcast driver (^4.0|^5.0).",
"pusher/pusher-php-server": "Required to use the Pusher broadcast driver (^4.0|^5.0|^6.0).",
"symfony/cache": "Required to PSR-6 cache bridge (^5.1.4).",
"symfony/filesystem": "Required to enable support for relative symbolic links (^5.1.4).",
"symfony/psr-http-message-bridge": "Required to use PSR-7 bridging features (^2.0).",
@@ -1847,7 +1847,7 @@
"issues": "https://github.com/laravel/framework/issues",
"source": "https://github.com/laravel/framework"
},
"time": "2021-04-28T14:38:56+00:00"
"time": "2021-05-11T14:00:02+00:00"
},
{
"name": "laravel/passport",
@@ -2192,16 +2192,16 @@
},
{
"name": "league/commonmark",
"version": "1.6.1",
"version": "1.6.2",
"source": {
"type": "git",
"url": "https://github.com/thephpleague/commonmark.git",
"reference": "2651c497f005de305c7ba3f232cbd87b8c00ee8c"
"reference": "7d70d2f19c84bcc16275ea47edabee24747352eb"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/thephpleague/commonmark/zipball/2651c497f005de305c7ba3f232cbd87b8c00ee8c",
"reference": "2651c497f005de305c7ba3f232cbd87b8c00ee8c",
"url": "https://api.github.com/repos/thephpleague/commonmark/zipball/7d70d2f19c84bcc16275ea47edabee24747352eb",
"reference": "7d70d2f19c84bcc16275ea47edabee24747352eb",
"shasum": ""
},
"require": {
@@ -2289,7 +2289,7 @@
"type": "tidelift"
}
],
"time": "2021-05-08T16:08:00+00:00"
"time": "2021-05-12T11:39:41+00:00"
},
{
"name": "league/csv",
@@ -2833,16 +2833,16 @@
},
{
"name": "nesbot/carbon",
"version": "2.47.0",
"version": "2.48.0",
"source": {
"type": "git",
"url": "https://github.com/briannesbitt/Carbon.git",
"reference": "606262fd8888b75317ba9461825a24fc34001e1e"
"reference": "d3c447f21072766cddec3522f9468a5849a76147"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/606262fd8888b75317ba9461825a24fc34001e1e",
"reference": "606262fd8888b75317ba9461825a24fc34001e1e",
"url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/d3c447f21072766cddec3522f9468a5849a76147",
"reference": "d3c447f21072766cddec3522f9468a5849a76147",
"shasum": ""
},
"require": {
@@ -2922,7 +2922,7 @@
"type": "tidelift"
}
],
"time": "2021-04-13T21:54:02+00:00"
"time": "2021-05-07T10:08:30+00:00"
},
{
"name": "nyholm/psr7",
@@ -4449,16 +4449,16 @@
},
{
"name": "symfony/console",
"version": "v5.2.7",
"version": "v5.2.8",
"source": {
"type": "git",
"url": "https://github.com/symfony/console.git",
"reference": "90374b8ed059325b49a29b55b3f8bb4062c87629"
"reference": "864568fdc0208b3eba3638b6000b69d2386e6768"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/console/zipball/90374b8ed059325b49a29b55b3f8bb4062c87629",
"reference": "90374b8ed059325b49a29b55b3f8bb4062c87629",
"url": "https://api.github.com/repos/symfony/console/zipball/864568fdc0208b3eba3638b6000b69d2386e6768",
"reference": "864568fdc0208b3eba3638b6000b69d2386e6768",
"shasum": ""
},
"require": {
@@ -4526,7 +4526,7 @@
"terminal"
],
"support": {
"source": "https://github.com/symfony/console/tree/v5.2.7"
"source": "https://github.com/symfony/console/tree/v5.2.8"
},
"funding": [
{
@@ -4542,7 +4542,7 @@
"type": "tidelift"
}
],
"time": "2021-04-19T14:07:32+00:00"
"time": "2021-05-11T15:45:21+00:00"
},
{
"name": "symfony/css-selector",
@@ -4678,16 +4678,16 @@
},
{
"name": "symfony/error-handler",
"version": "v5.2.7",
"version": "v5.2.8",
"source": {
"type": "git",
"url": "https://github.com/symfony/error-handler.git",
"reference": "ea3ddbf67615e883ca7c33a4de61213789846782"
"reference": "1416bc16317a8188aabde251afef7618bf4687ac"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/error-handler/zipball/ea3ddbf67615e883ca7c33a4de61213789846782",
"reference": "ea3ddbf67615e883ca7c33a4de61213789846782",
"url": "https://api.github.com/repos/symfony/error-handler/zipball/1416bc16317a8188aabde251afef7618bf4687ac",
"reference": "1416bc16317a8188aabde251afef7618bf4687ac",
"shasum": ""
},
"require": {
@@ -4727,7 +4727,7 @@
"description": "Provides tools to manage errors and ease debugging PHP code",
"homepage": "https://symfony.com",
"support": {
"source": "https://github.com/symfony/error-handler/tree/v5.2.7"
"source": "https://github.com/symfony/error-handler/tree/v5.2.8"
},
"funding": [
{
@@ -4743,7 +4743,7 @@
"type": "tidelift"
}
],
"time": "2021-04-07T15:57:33+00:00"
"time": "2021-05-07T13:42:21+00:00"
},
{
"name": "symfony/event-dispatcher",
@@ -4911,16 +4911,16 @@
},
{
"name": "symfony/finder",
"version": "v5.2.4",
"version": "v5.2.8",
"source": {
"type": "git",
"url": "https://github.com/symfony/finder.git",
"reference": "0d639a0943822626290d169965804f79400e6a04"
"reference": "eccb8be70d7a6a2230d05f6ecede40f3fdd9e252"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/finder/zipball/0d639a0943822626290d169965804f79400e6a04",
"reference": "0d639a0943822626290d169965804f79400e6a04",
"url": "https://api.github.com/repos/symfony/finder/zipball/eccb8be70d7a6a2230d05f6ecede40f3fdd9e252",
"reference": "eccb8be70d7a6a2230d05f6ecede40f3fdd9e252",
"shasum": ""
},
"require": {
@@ -4952,7 +4952,7 @@
"description": "Finds files and directories via an intuitive fluent interface",
"homepage": "https://symfony.com",
"support": {
"source": "https://github.com/symfony/finder/tree/v5.2.4"
"source": "https://github.com/symfony/finder/tree/v5.2.8"
},
"funding": [
{
@@ -4968,7 +4968,7 @@
"type": "tidelift"
}
],
"time": "2021-02-15T18:55:04+00:00"
"time": "2021-05-10T14:39:23+00:00"
},
{
"name": "symfony/http-client-contracts",
@@ -5050,16 +5050,16 @@
},
{
"name": "symfony/http-foundation",
"version": "v5.2.7",
"version": "v5.2.8",
"source": {
"type": "git",
"url": "https://github.com/symfony/http-foundation.git",
"reference": "a416487a73bb9c9d120e9ba3a60547f4a3fb7a1f"
"reference": "e8fbbab7c4a71592985019477532629cb2e142dc"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/http-foundation/zipball/a416487a73bb9c9d120e9ba3a60547f4a3fb7a1f",
"reference": "a416487a73bb9c9d120e9ba3a60547f4a3fb7a1f",
"url": "https://api.github.com/repos/symfony/http-foundation/zipball/e8fbbab7c4a71592985019477532629cb2e142dc",
"reference": "e8fbbab7c4a71592985019477532629cb2e142dc",
"shasum": ""
},
"require": {
@@ -5103,7 +5103,7 @@
"description": "Defines an object-oriented layer for the HTTP specification",
"homepage": "https://symfony.com",
"support": {
"source": "https://github.com/symfony/http-foundation/tree/v5.2.7"
"source": "https://github.com/symfony/http-foundation/tree/v5.2.8"
},
"funding": [
{
@@ -5119,20 +5119,20 @@
"type": "tidelift"
}
],
"time": "2021-05-01T13:46:24+00:00"
"time": "2021-05-07T13:41:16+00:00"
},
{
"name": "symfony/http-kernel",
"version": "v5.2.7",
"version": "v5.2.8",
"source": {
"type": "git",
"url": "https://github.com/symfony/http-kernel.git",
"reference": "1e9f6879f070f718e0055fbac232a56f67b8b6bd"
"reference": "c3cb71ee7e2d3eae5fe1001f81780d6a49b37937"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/http-kernel/zipball/1e9f6879f070f718e0055fbac232a56f67b8b6bd",
"reference": "1e9f6879f070f718e0055fbac232a56f67b8b6bd",
"url": "https://api.github.com/repos/symfony/http-kernel/zipball/c3cb71ee7e2d3eae5fe1001f81780d6a49b37937",
"reference": "c3cb71ee7e2d3eae5fe1001f81780d6a49b37937",
"shasum": ""
},
"require": {
@@ -5215,7 +5215,7 @@
"description": "Provides a structured process for converting a Request into a Response",
"homepage": "https://symfony.com",
"support": {
"source": "https://github.com/symfony/http-kernel/tree/v5.2.7"
"source": "https://github.com/symfony/http-kernel/tree/v5.2.8"
},
"funding": [
{
@@ -5231,7 +5231,7 @@
"type": "tidelift"
}
],
"time": "2021-05-01T14:53:15+00:00"
"time": "2021-05-12T13:27:53+00:00"
},
{
"name": "symfony/mime",
@@ -6365,16 +6365,16 @@
},
{
"name": "symfony/string",
"version": "v5.2.6",
"version": "v5.2.8",
"source": {
"type": "git",
"url": "https://github.com/symfony/string.git",
"reference": "ad0bd91bce2054103f5eaa18ebeba8d3bc2a0572"
"reference": "01b35eb64cac8467c3f94cd0ce2d0d376bb7d1db"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/string/zipball/ad0bd91bce2054103f5eaa18ebeba8d3bc2a0572",
"reference": "ad0bd91bce2054103f5eaa18ebeba8d3bc2a0572",
"url": "https://api.github.com/repos/symfony/string/zipball/01b35eb64cac8467c3f94cd0ce2d0d376bb7d1db",
"reference": "01b35eb64cac8467c3f94cd0ce2d0d376bb7d1db",
"shasum": ""
},
"require": {
@@ -6428,7 +6428,7 @@
"utf8"
],
"support": {
"source": "https://github.com/symfony/string/tree/v5.2.6"
"source": "https://github.com/symfony/string/tree/v5.2.8"
},
"funding": [
{
@@ -6444,20 +6444,20 @@
"type": "tidelift"
}
],
"time": "2021-03-17T17:12:15+00:00"
"time": "2021-05-10T14:56:10+00:00"
},
{
"name": "symfony/translation",
"version": "v5.2.7",
"version": "v5.2.8",
"source": {
"type": "git",
"url": "https://github.com/symfony/translation.git",
"reference": "e37ece5242564bceea54d709eafc948377ec9749"
"reference": "445caa74a5986f1cc9dd91a2975ef68fa7cb2068"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/translation/zipball/e37ece5242564bceea54d709eafc948377ec9749",
"reference": "e37ece5242564bceea54d709eafc948377ec9749",
"url": "https://api.github.com/repos/symfony/translation/zipball/445caa74a5986f1cc9dd91a2975ef68fa7cb2068",
"reference": "445caa74a5986f1cc9dd91a2975ef68fa7cb2068",
"shasum": ""
},
"require": {
@@ -6521,7 +6521,7 @@
"description": "Provides tools to internationalize your application",
"homepage": "https://symfony.com",
"support": {
"source": "https://github.com/symfony/translation/tree/v5.2.7"
"source": "https://github.com/symfony/translation/tree/v5.2.8"
},
"funding": [
{
@@ -6537,7 +6537,7 @@
"type": "tidelift"
}
],
"time": "2021-04-01T08:15:21+00:00"
"time": "2021-05-07T13:41:16+00:00"
},
{
"name": "symfony/translation-contracts",
@@ -6619,16 +6619,16 @@
},
{
"name": "symfony/var-dumper",
"version": "v5.2.7",
"version": "v5.2.8",
"source": {
"type": "git",
"url": "https://github.com/symfony/var-dumper.git",
"reference": "27cb9f7cfa3853c736425c7233a8f68814b19636"
"reference": "d693200a73fae179d27f8f1b16b4faf3e8569eba"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/var-dumper/zipball/27cb9f7cfa3853c736425c7233a8f68814b19636",
"reference": "27cb9f7cfa3853c736425c7233a8f68814b19636",
"url": "https://api.github.com/repos/symfony/var-dumper/zipball/d693200a73fae179d27f8f1b16b4faf3e8569eba",
"reference": "d693200a73fae179d27f8f1b16b4faf3e8569eba",
"shasum": ""
},
"require": {
@@ -6687,7 +6687,7 @@
"dump"
],
"support": {
"source": "https://github.com/symfony/var-dumper/tree/v5.2.7"
"source": "https://github.com/symfony/var-dumper/tree/v5.2.8"
},
"funding": [
{
@@ -6703,7 +6703,7 @@
"type": "tidelift"
}
],
"time": "2021-04-19T14:07:32+00:00"
"time": "2021-05-07T13:42:21+00:00"
},
{
"name": "tijsverkoyen/css-to-inline-styles",
@@ -6760,16 +6760,16 @@
},
{
"name": "twig/twig",
"version": "v2.14.4",
"version": "v2.14.5",
"source": {
"type": "git",
"url": "https://github.com/twigphp/Twig.git",
"reference": "0b4ba691fb99ec7952d25deb36c0a83061b93bbf"
"reference": "c9dd15b3a80725bc4919730fae462bddcc960820"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/twigphp/Twig/zipball/0b4ba691fb99ec7952d25deb36c0a83061b93bbf",
"reference": "0b4ba691fb99ec7952d25deb36c0a83061b93bbf",
"url": "https://api.github.com/repos/twigphp/Twig/zipball/c9dd15b3a80725bc4919730fae462bddcc960820",
"reference": "c9dd15b3a80725bc4919730fae462bddcc960820",
"shasum": ""
},
"require": {
@@ -6823,7 +6823,7 @@
],
"support": {
"issues": "https://github.com/twigphp/Twig/issues",
"source": "https://github.com/twigphp/Twig/tree/v2.14.4"
"source": "https://github.com/twigphp/Twig/tree/v2.14.5"
},
"funding": [
{
@@ -6835,7 +6835,7 @@
"type": "tidelift"
}
],
"time": "2021-03-10T10:05:55+00:00"
"time": "2021-05-12T08:02:35+00:00"
},
{
"name": "vlucas/phpdotenv",
@@ -8830,16 +8830,16 @@
},
{
"name": "phpstan/phpstan",
"version": "0.12.86",
"version": "0.12.87",
"source": {
"type": "git",
"url": "https://github.com/phpstan/phpstan.git",
"reference": "a84fdc53ecca7643dbc89ef8880d8b393a6c155a"
"reference": "d464e00776afb711f419faffa96826dc02e4d145"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/phpstan/phpstan/zipball/a84fdc53ecca7643dbc89ef8880d8b393a6c155a",
"reference": "a84fdc53ecca7643dbc89ef8880d8b393a6c155a",
"url": "https://api.github.com/repos/phpstan/phpstan/zipball/d464e00776afb711f419faffa96826dc02e4d145",
"reference": "d464e00776afb711f419faffa96826dc02e4d145",
"shasum": ""
},
"require": {
@@ -8870,7 +8870,7 @@
"description": "PHPStan - PHP Static Analysis Tool",
"support": {
"issues": "https://github.com/phpstan/phpstan/issues",
"source": "https://github.com/phpstan/phpstan/tree/0.12.86"
"source": "https://github.com/phpstan/phpstan/tree/0.12.87"
},
"funding": [
{
@@ -8886,7 +8886,7 @@
"type": "tidelift"
}
],
"time": "2021-05-08T11:29:01+00:00"
"time": "2021-05-12T15:17:52+00:00"
},
{
"name": "phpstan/phpstan-deprecation-rules",
@@ -9416,12 +9416,12 @@
"source": {
"type": "git",
"url": "https://github.com/Roave/SecurityAdvisories.git",
"reference": "07314cf15422b2e162d591fe8ef2b850612b808f"
"reference": "630d41ce85b7af3598a7d2c07952739da298ecc6"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/Roave/SecurityAdvisories/zipball/07314cf15422b2e162d591fe8ef2b850612b808f",
"reference": "07314cf15422b2e162d591fe8ef2b850612b808f",
"url": "https://api.github.com/repos/Roave/SecurityAdvisories/zipball/630d41ce85b7af3598a7d2c07952739da298ecc6",
"reference": "630d41ce85b7af3598a7d2c07952739da298ecc6",
"shasum": ""
},
"conflict": {
@@ -9469,8 +9469,8 @@
"doctrine/orm": ">=2,<2.4.8|>=2.5,<2.5.1|>=2.8.3,<2.8.4",
"dolibarr/dolibarr": "<11.0.4",
"dompdf/dompdf": ">=0.6,<0.6.2",
"drupal/core": ">=7,<7.74|>=8,<8.8.11|>=8.9,<8.9.9|>=9,<9.0.8",
"drupal/drupal": ">=7,<7.74|>=8,<8.8.11|>=8.9,<8.9.9|>=9,<9.0.8",
"drupal/core": ">=7,<7.80|>=8,<8.9.14|>=9,<9.0.12|>=9.1,<9.1.7",
"drupal/drupal": ">=7,<7.80|>=8,<8.9.14|>=9,<9.0.12|>=9.1,<9.1.7",
"dweeves/magmi": "<=0.7.24",
"endroid/qr-code-bundle": "<3.4.2",
"enshrined/svg-sanitize": "<0.13.1",
@@ -9529,6 +9529,7 @@
"laravel/framework": "<6.20.26|>=7,<8.40",
"laravel/socialite": ">=1,<1.0.99|>=2,<2.0.10",
"league/commonmark": "<0.18.3",
"lexik/jwt-authentication-bundle": ">=2,<2.10.7|>=2.11,<2.11.3",
"librenms/librenms": "<21.1",
"livewire/livewire": ">2.2.4,<2.2.6",
"magento/community-edition": ">=2,<2.2.10|>=2.3,<2.3.3",
@@ -9649,20 +9650,21 @@
"symfony/http-foundation": ">=2,<2.8.52|>=3,<3.4.35|>=4,<4.2.12|>=4.3,<4.3.8|>=4.4,<4.4.7|>=5,<5.0.7",
"symfony/http-kernel": ">=2,<2.8.52|>=3,<3.4.35|>=4,<4.2.12|>=4.3,<4.4.13|>=5,<5.1.5",
"symfony/intl": ">=2.7,<2.7.38|>=2.8,<2.8.31|>=3,<3.2.14|>=3.3,<3.3.13",
"symfony/maker-bundle": ">=1.27,<1.31.1",
"symfony/mime": ">=4.3,<4.3.8",
"symfony/phpunit-bridge": ">=2.8,<2.8.50|>=3,<3.4.26|>=4,<4.1.12|>=4.2,<4.2.7",
"symfony/polyfill": ">=1,<1.10",
"symfony/polyfill-php55": ">=1,<1.10",
"symfony/proxy-manager-bridge": ">=2.7,<2.7.51|>=2.8,<2.8.50|>=3,<3.4.26|>=4,<4.1.12|>=4.2,<4.2.7",
"symfony/routing": ">=2,<2.0.19",
"symfony/security": ">=2,<2.7.51|>=2.8,<2.8.50|>=3,<3.4.26|>=4,<4.1.12|>=4.2,<4.2.7|>=4.4,<4.4.7|>=5,<5.0.7",
"symfony/security": ">=2,<2.7.51|>=2.8,<3.4.48|>=4,<4.4.23|>=5,<5.2.8",
"symfony/security-bundle": ">=2,<2.7.48|>=2.8,<2.8.41|>=3,<3.3.17|>=3.4,<3.4.11|>=4,<4.0.11",
"symfony/security-core": ">=2.4,<2.6.13|>=2.7,<2.7.9|>=2.7.30,<2.7.32|>=2.8,<2.8.37|>=3,<3.3.17|>=3.4,<3.4.7|>=4,<4.0.7",
"symfony/security-core": ">=2.4,<2.6.13|>=2.7,<2.7.9|>=2.7.30,<2.7.32|>=2.8,<3.4.48|>=4,<4.4.23|>=5,<5.2.8",
"symfony/security-csrf": ">=2.4,<2.7.48|>=2.8,<2.8.41|>=3,<3.3.17|>=3.4,<3.4.11|>=4,<4.0.11",
"symfony/security-guard": ">=2.8,<2.8.41|>=3,<3.3.17|>=3.4,<3.4.11|>=4,<4.0.11",
"symfony/security-http": ">=2.3,<2.3.41|>=2.4,<2.7.51|>=2.8,<2.8.50|>=3,<3.4.26|>=4,<4.2.12|>=4.3,<4.3.8|>=4.4,<4.4.7|>=5,<5.0.7",
"symfony/security-guard": ">=2.8,<3.4.48|>=4,<4.4.23|>=5,<5.2.8",
"symfony/security-http": ">=2.3,<2.3.41|>=2.4,<2.7.51|>=2.8,<2.8.50|>=3,<3.4.26|>=4,<4.2.12|>=4.3,<4.3.8|>=4.4,<4.4.7|>=5,<5.0.7|>=5.1,<5.2.8",
"symfony/serializer": ">=2,<2.0.11",
"symfony/symfony": ">=2,<2.8.52|>=3,<3.4.35|>=4,<4.2.12|>=4.3,<4.4.13|>=5,<5.1.5",
"symfony/symfony": ">=2,<3.4.48|>=4,<4.4.23|>=5,<5.2.8",
"symfony/translation": ">=2,<2.0.17",
"symfony/validator": ">=2,<2.0.24|>=2.1,<2.1.12|>=2.2,<2.2.5|>=2.3,<2.3.3",
"symfony/var-exporter": ">=4.2,<4.2.12|>=4.3,<4.3.8",
@@ -9762,7 +9764,7 @@
"type": "tidelift"
}
],
"time": "2021-05-06T19:08:33+00:00"
"time": "2021-05-12T16:13:16+00:00"
},
{
"name": "sebastian/cli-parser",

View File

@@ -0,0 +1,36 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
/**
* Class ExtendCurrencyInfo
*/
class ExtendCurrencyInfo extends Migration
{
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
//
}
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::table(
'transaction_currencies', function (Blueprint $table) {
$table->string('code', 51)->change();
$table->string('symbol', 51)->change();
}
);
}
}

View File

@@ -15,8 +15,8 @@
</div>
<div class="box-body">
{{ ExpandedForm.text('name',null,{'maxlength' : 48}) }}
{{ ExpandedForm.text('symbol',null,{'maxlength': 8}) }}
{{ ExpandedForm.text('code',null,{'maxlength' : 3}) }}
{{ ExpandedForm.text('symbol',null,{'maxlength': 51}) }}
{{ ExpandedForm.text('code',null,{'maxlength' : 51}) }}
{{ ExpandedForm.integer('decimal_places',2,{'maxlength' : 2,'min': 0,'max': 12}) }}
</div>
</div>

View File

@@ -16,8 +16,8 @@
</div>
<div class="box-body">
{{ ExpandedForm.text('name',null,{'maxlength' : 48}) }}
{{ ExpandedForm.text('symbol',null,{'maxlength' : 8}) }}
{{ ExpandedForm.text('code',null,{'maxlength' : 3}) }}
{{ ExpandedForm.text('symbol',null,{'maxlength' : 51}) }}
{{ ExpandedForm.text('code',null,{'maxlength' : 51}) }}
{{ ExpandedForm.integer('decimal_places',null,{'maxlength' : 2,'min': 0,'max': 12}) }}
{{ ExpandedForm.checkbox('enabled',null) }}
</div>