Compare commits

...

467 Commits

Author SHA1 Message Date
James Cole
e8618047bd More readable fix for division by zero error. 2024-03-31 08:40:47 +02:00
James Cole
f104b76f73 Merge pull request #8735 from mansuf/develop
Fix `Division error by zero` in budget views
2024-03-31 08:37:09 +02:00
Rahman Yusuf
cb701d8506 Fix Division error by zero in budget views 2024-03-31 12:03:54 +07:00
James Cole
70a334c56e Merge branch 'main' into develop 2024-03-31 03:16:54 +02:00
github-actions
e6b2db1e29 Auto commit for release 'develop' on 2024-03-31 2024-03-31 03:14:08 +02:00
James Cole
e8dffa0052 Update script version 2024-03-31 03:09:00 +02:00
James Cole
c4f0512f39 Run another composer, and dump the autoload files. 2024-03-31 03:06:58 +02:00
James Cole
3268019d0c Fix #8732 2024-03-31 01:24:18 +01:00
James Cole
a0ef6a1fc8 Fix https://github.com/firefly-iii/firefly-iii/issues/8725 2024-03-30 09:56:51 +01:00
James Cole
99d0098b20 Merge branch 'main' into develop 2024-03-28 05:59:30 +01:00
James Cole
a7a54c042c Touch and exclude tar name 2024-03-28 05:53:31 +01:00
github-actions
c44e48a793 Auto commit for release 'develop' on 2024-03-28 2024-03-28 04:10:19 +01:00
James Cole
53b501ca73 Add tar.gz file 2024-03-27 20:04:14 +01:00
James Cole
322f70bcca Merge branch 'main' into develop
# Conflicts:
#	.github/workflows/release.yml
2024-03-27 07:10:24 +01:00
James Cole
35559c077b Update text in output. 2024-03-27 06:59:48 +01:00
github-actions
590ffe7c76 Auto commit for release 'develop' on 2024-03-27 2024-03-27 06:58:44 +01:00
James Cole
8a2d8f148e Expand text under development release 2024-03-27 06:50:39 +01:00
James Cole
4f0e15e07d Expand text in dev release. 2024-03-27 06:49:56 +01:00
James Cole
7463861e0c Merge branch 'develop' of github.com:firefly-iii/firefly-iii into develop 2024-03-26 07:40:51 +01:00
James Cole
1e70fa28be Fix https://github.com/firefly-iii/firefly-iii/issues/8648 2024-03-26 07:37:21 +01:00
github-actions
26c6ca470b Auto commit for release 'develop' on 2024-03-26 2024-03-26 07:37:05 +01:00
James Cole
5e54034e0e Merge branch 'main' into develop
# Conflicts:
#	.github/workflows/release.yml
2024-03-26 07:32:26 +01:00
James Cole
25873ef734 add npm update. 2024-03-26 07:31:33 +01:00
James Cole
1092b04b22 Merge branch 'main' into develop 2024-03-26 07:30:27 +01:00
James Cole
01ce74dd72 Expand release script with shasum 2024-03-26 07:30:15 +01:00
James Cole
41430d8386 Fix bill box and hover CSS 2024-03-26 07:25:36 +01:00
James Cole
01eb19169c Merge pull request #8714 from firefly-iii/dependabot/npm_and_yarn/develop/vite-4.5.3 2024-03-25 07:08:14 +01:00
dependabot[bot]
cfaa7d7c68 Bump vite from 4.5.2 to 4.5.3
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 4.5.2 to 4.5.3.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v4.5.3/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v4.5.3/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-25 03:13:52 +00:00
github-actions
14d3312a10 Auto commit for release 'develop' on 2024-03-25 2024-03-25 04:10:34 +01:00
James Cole
87be478dd8 Expand dashboard view 2024-03-24 16:22:27 +01:00
James Cole
0b6877a20e Fix null pointer 2024-03-24 14:11:30 +01:00
James Cole
7186f0ef60 Improve boxes 2024-03-24 14:10:07 +01:00
James Cole
538933691e Add sort column to account overview. and some css fixes 2024-03-24 13:24:48 +01:00
James Cole
46c49ddbd8 Add translations, fix error message. 2024-03-24 12:07:26 +01:00
James Cole
bcfb134b6e Clean up 2024-03-24 11:43:37 +01:00
James Cole
57981f1cf9 Read and remember sort order by URL 2024-03-24 11:08:24 +01:00
James Cole
0310186fb7 Expand accounts page. 2024-03-23 20:37:15 +01:00
James Cole
4dcb38290e Better inline editor. 2024-03-23 15:20:49 +01:00
James Cole
2f5c37048b Update vite.config.js
Add relative path.

Signed-off-by: James Cole <james@firefly-iii.org>
2024-03-21 13:44:51 +01:00
github-actions
370c8b16ae Auto commit for release 'develop' on 2024-03-21 2024-03-21 04:11:26 +01:00
github-actions
af0555592a Auto commit for release 'v6.1.12' on 2024-03-20 2024-03-20 17:55:25 +01:00
James Cole
9c07ddaed6 Replace shitty Laravel Passport command. 2024-03-20 17:48:13 +01:00
James Cole
bb7355a566 Fix https://github.com/orgs/firefly-iii/discussions/8696 2024-03-20 17:32:06 +01:00
James Cole
1d48347f8c Update release notes for new version. 2024-03-20 17:28:56 +01:00
James Cole
060b76ca9c Replace command in composer.json 2024-03-20 11:45:56 +01:00
James Cole
2b2b9b6f7a Drop duplicate index 2024-03-20 06:14:32 +01:00
James Cole
f3dd05a0c0 Move jobs to better times. 2024-03-20 06:12:56 +01:00
James Cole
47a91aa273 Exclude file from release. 2024-03-19 17:52:00 +01:00
github-actions
41bc236603 Auto commit for release 'v6.1.11' on 2024-03-19 2024-03-19 17:44:55 +01:00
James Cole
65349451ea Update changelog. 2024-03-19 17:39:54 +01:00
James Cole
e77b6a55a4 Merge branch 'main' into develop 2024-03-19 17:33:49 +01:00
James Cole
2379bcff11 git Merge branch 'develop' of https://github.com/firefly-iii/firefly-iii into develop 2024-03-19 14:28:46 +01:00
James Cole
7133156fa1 add empty dir 2024-03-19 14:28:40 +01:00
github-actions
a59176689d Auto commit for release 'develop' on 2024-03-19 2024-03-19 14:23:12 +01:00
James Cole
bc2d8f3dfb Deleted generated JS 2024-03-19 14:06:57 +01:00
James Cole
ddf89a9d5a remove build dir 2024-03-19 11:10:05 +01:00
James Cole
7daaba17f6 Update git ignore file 2024-03-19 10:23:17 +01:00
James Cole
9cb5b1384f Remove generated files 2024-03-19 10:23:01 +01:00
github-actions
7d13263482 Auto commit for release 'develop' on 2024-03-18 2024-03-18 21:08:27 +01:00
James Cole
d9ff252915 Unignore files 2024-03-18 21:03:17 +01:00
James Cole
51ba550251 Ignore generated files. 2024-03-18 20:29:09 +01:00
James Cole
fd21c467ad Remove generated files. 2024-03-18 20:28:58 +01:00
github-actions
9aa90650b4 Auto commit for release 'develop' on 2024-03-18 2024-03-18 20:25:30 +01:00
James Cole
d892257e8b Add artifact. 2024-03-18 20:19:18 +01:00
James Cole
db0dbcfcf1 Disable exchange rates by default. 2024-03-18 06:20:33 +01:00
James Cole
f591996f04 Remove deferrable interface 2024-03-18 06:14:17 +01:00
James Cole
b08d385586 Merge pull request #8683 from firefly-iii/dependabot/npm_and_yarn/develop/axios-1.6.8 2024-03-18 05:45:38 +01:00
James Cole
20ef22f67e Merge pull request #8682 from firefly-iii/dependabot/npm_and_yarn/develop/sass-1.72.0 2024-03-18 05:45:31 +01:00
James Cole
c888baf542 Merge pull request #8681 from firefly-iii/dependabot/npm_and_yarn/develop/date-fns-3.6.0 2024-03-18 05:45:22 +01:00
dependabot[bot]
8b0af3f666 Bump axios from 1.6.7 to 1.6.8
Bumps [axios](https://github.com/axios/axios) from 1.6.7 to 1.6.8.
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md)
- [Commits](https://github.com/axios/axios/compare/v1.6.7...v1.6.8)

---
updated-dependencies:
- dependency-name: axios
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-18 03:07:58 +00:00
dependabot[bot]
7043e1e7c0 Bump sass from 1.71.1 to 1.72.0
Bumps [sass](https://github.com/sass/dart-sass) from 1.71.1 to 1.72.0.
- [Release notes](https://github.com/sass/dart-sass/releases)
- [Changelog](https://github.com/sass/dart-sass/blob/main/CHANGELOG.md)
- [Commits](https://github.com/sass/dart-sass/compare/1.71.1...1.72.0)

---
updated-dependencies:
- dependency-name: sass
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-18 03:07:43 +00:00
dependabot[bot]
c5854eba23 Bump date-fns from 3.3.1 to 3.6.0
Bumps [date-fns](https://github.com/date-fns/date-fns) from 3.3.1 to 3.6.0.
- [Release notes](https://github.com/date-fns/date-fns/releases)
- [Changelog](https://github.com/date-fns/date-fns/blob/main/CHANGELOG.md)
- [Commits](https://github.com/date-fns/date-fns/compare/v3.3.1...v3.6.0)

---
updated-dependencies:
- dependency-name: date-fns
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-18 03:07:29 +00:00
github-actions
ddf1a8cebb Auto commit for release 'develop' on 2024-03-18 2024-03-18 01:30:56 +01:00
James Cole
7dcaf167e9 Replace blade template with twig template 2024-03-17 15:54:18 +01:00
James Cole
b359d51d3a Fix code and tests. 2024-03-17 12:26:56 +01:00
James Cole
3913fa5086 Restore old behavior 2024-03-17 12:00:28 +01:00
James Cole
ab2772abe0 Remove deferrable. 2024-03-17 11:44:58 +01:00
James Cole
bc7875b17b Add stub component. 2024-03-17 09:30:26 +01:00
James Cole
4938fa9990 Add stub component. 2024-03-17 09:29:49 +01:00
James Cole
84df2c80ee Fix missing var 2024-03-17 09:27:04 +01:00
James Cole
dc17060754 Remove deferrable. 2024-03-17 09:24:50 +01:00
James Cole
e2fa81dddc Remove deferrable. 2024-03-17 09:24:25 +01:00
James Cole
182dfc95fe Remove deferrable. 2024-03-17 09:23:44 +01:00
James Cole
c8979b6c33 Remove deferrable. 2024-03-17 09:23:12 +01:00
James Cole
ab872e8912 Remove deferrable. 2024-03-17 09:22:45 +01:00
James Cole
d36b94fabf Remove deferrable. 2024-03-17 09:22:13 +01:00
James Cole
e3d4ceaecb Merge branch 'main' into develop 2024-03-17 09:19:26 +01:00
James Cole
e3a6e5b788 Upgrade to laravel 11 2024-03-17 09:19:01 +01:00
James Cole
57235c0e00 Merge pull request #8675 from firefly-iii/dependabot/npm_and_yarn/follow-redirects-1.15.6 2024-03-17 07:43:18 +01:00
dependabot[bot]
2298c3ddaf Bump follow-redirects from 1.15.5 to 1.15.6
Bumps [follow-redirects](https://github.com/follow-redirects/follow-redirects) from 1.15.5 to 1.15.6.
- [Release notes](https://github.com/follow-redirects/follow-redirects/releases)
- [Commits](https://github.com/follow-redirects/follow-redirects/compare/v1.15.5...v1.15.6)

---
updated-dependencies:
- dependency-name: follow-redirects
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-16 23:39:53 +00:00
James Cole
7224f1be6f Small code cleanup. 2024-03-16 23:06:16 +01:00
James Cole
1bd3019c16 Small code cleanup. 2024-03-16 22:57:48 +01:00
James Cole
f0fa21dead First version of line edit. 2024-03-16 22:00:25 +01:00
James Cole
845eaed8d7 Code cleanup. 2024-03-16 11:27:07 +01:00
James Cole
b3649cd4d0 Add migration routine for https://github.com/firefly-iii/firefly-iii/pull/8650 2024-03-16 07:03:50 +01:00
James Cole
55f14c587b New funding file. 2024-03-16 06:33:31 +01:00
James Cole
441a8a8408 Some code cleanup 2024-03-16 06:28:21 +01:00
James Cole
060c9648f1 Fix https://github.com/firefly-iii/firefly-iii/issues/8668 2024-03-16 06:25:56 +01:00
James Cole
7680c8733f Expand. include discussions. 2024-03-16 06:09:10 +01:00
James Cole
5a0af5c93b Fix https://github.com/firefly-iii/firefly-iii/issues/8672 2024-03-15 06:13:40 +01:00
James Cole
f4b066add1 Fix https://github.com/firefly-iii/firefly-iii/issues/8671 2024-03-14 21:20:30 +01:00
github-actions
9ecb414b02 Auto commit for release 'develop' on 2024-03-14 2024-03-14 01:29:53 +01:00
James Cole
ad4f908c24 CI will stop complaining about code base, bi-weekly release picks this up. 2024-03-13 06:52:16 +01:00
James Cole
025f739442 Reformat some code. 2024-03-13 06:51:31 +01:00
James Cole
6df7354c48 Rebuild frontend cause lazy. 2024-03-13 06:51:22 +01:00
James Cole
3f77c845ca Add last activity column 2024-03-13 06:50:08 +01:00
James Cole
d4771f7a5c Remove old configuration file. 2024-03-13 06:29:39 +01:00
James Cole
ec4e2bfa4f Fix https://github.com/firefly-iii/firefly-iii/issues/8663 2024-03-12 20:36:31 +01:00
github-actions
dfdbfae4b5 Auto commit for release 'develop' on 2024-03-11 2024-03-11 06:17:46 +01:00
James Cole
349d38b956 Merge branch 'main' into develop 2024-03-11 06:12:38 +01:00
James Cole
2267aa3ac4 Fix workflow 2024-03-11 06:12:29 +01:00
James Cole
2323aa454e Add git keep 2024-03-11 06:10:17 +01:00
James Cole
8b3317b665 Merge pull request #8658 from firefly-iii/dependabot/composer/develop/symfony/expression-language-7.0.3 2024-03-11 05:26:48 +01:00
James Cole
15f893c343 Merge pull request #8657 from firefly-iii/dependabot/npm_and_yarn/develop/alpinejs-3.13.7 2024-03-11 05:26:21 +01:00
James Cole
309b3e765e Merge pull request #8656 from firefly-iii/dependabot/npm_and_yarn/develop/i18next-23.10.1 2024-03-11 05:26:12 +01:00
dependabot[bot]
d3fad06e00 Bump symfony/expression-language from 6.4.3 to 7.0.3
Bumps [symfony/expression-language](https://github.com/symfony/expression-language) from 6.4.3 to 7.0.3.
- [Release notes](https://github.com/symfony/expression-language/releases)
- [Changelog](https://github.com/symfony/expression-language/blob/7.0/CHANGELOG.md)
- [Commits](https://github.com/symfony/expression-language/compare/v6.4.3...v7.0.3)

---
updated-dependencies:
- dependency-name: symfony/expression-language
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-11 03:55:59 +00:00
dependabot[bot]
834f24c99c Bump alpinejs from 3.13.6 to 3.13.7
Bumps [alpinejs](https://github.com/alpinejs/alpine/tree/HEAD/packages/alpinejs) from 3.13.6 to 3.13.7.
- [Release notes](https://github.com/alpinejs/alpine/releases)
- [Commits](https://github.com/alpinejs/alpine/commits/v3.13.7/packages/alpinejs)

---
updated-dependencies:
- dependency-name: alpinejs
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-11 03:39:56 +00:00
dependabot[bot]
35291e1298 Bump i18next from 23.10.0 to 23.10.1
Bumps [i18next](https://github.com/i18next/i18next) from 23.10.0 to 23.10.1.
- [Release notes](https://github.com/i18next/i18next/releases)
- [Changelog](https://github.com/i18next/i18next/blob/master/CHANGELOG.md)
- [Commits](https://github.com/i18next/i18next/compare/v23.10.0...v23.10.1)

---
updated-dependencies:
- dependency-name: i18next
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-11 03:39:44 +00:00
James Cole
ac4e9dcbc5 Code cleanup. 2024-03-10 17:15:38 +01:00
James Cole
d57806f2ba Drop hashes 2024-03-10 16:52:59 +01:00
James Cole
3b005c317d Remove 'strict-dynamic' 2024-03-10 16:49:16 +01:00
James Cole
e91903fed2 Different orderRemove self 2024-03-10 16:47:59 +01:00
James Cole
fee2002b0f Remove self 2024-03-10 16:47:36 +01:00
James Cole
f12e502eb8 Fix header 2024-03-10 16:46:33 +01:00
James Cole
24e62b1cee Fix header 2024-03-10 16:45:19 +01:00
James Cole
f559ec73e0 Add exception catch. 2024-03-10 16:44:41 +01:00
James Cole
530b501fcf Disable engine. [skip ci] 2024-03-10 11:57:54 +01:00
James Cole
d5ea78025e Fix a few small bugs and rearrange code. 2024-03-10 11:57:21 +01:00
James Cole
3413b9b5b5 Refresh notes in various actions. 2024-03-10 08:11:58 +01:00
James Cole
0b45c1aa76 Better validation, can now also use notes in expression. 2024-03-10 08:08:26 +01:00
James Cole
5718d1690a Add debug logging 2024-03-10 08:07:47 +01:00
James Cole
67b16cc070 Overrule "constant" and "enum" actions. 2024-03-10 06:46:38 +01:00
James Cole
5746ac3247 Add feature flag for expression engine and disable it by default. 2024-03-10 06:46:24 +01:00
James Cole
8a2c520b11 Update packages 2024-03-10 06:29:24 +01:00
James Cole
f46c14df8c Validation over GET, take precedence over other routes 2024-03-10 06:29:15 +01:00
James Cole
009fbba491 Drop "failedValidation" method because this is handled by the system already. 2024-03-10 06:28:58 +01:00
James Cole
53d84347c2 sprintf the rules 2024-03-10 06:24:32 +01:00
James Cole
1961487055 Reformat code. 2024-03-10 06:17:31 +01:00
James Cole
c9ce5df74b Merge pull request #8650 from michaelhthomas/feat/expression-engine
[feat] Rules Expression Engine
2024-03-10 06:04:06 +01:00
Michael Thomas
1371b6773e chore: ignore PHPMD unused parameter errors 2024-03-09 14:09:36 -05:00
James Cole
b9f1baf150 Update packages 2024-03-09 19:50:46 +01:00
James Cole
66b322e844 Fix methods and clean up code. 2024-03-09 19:46:16 +01:00
James Cole
487b65b669 Rebuild frontend. 2024-03-09 19:33:43 +01:00
James Cole
9078781d61 New endpoint, fixed logo, better account overview. 2024-03-09 19:31:27 +01:00
Michael Thomas
1ec830521a fix: resolve PHPstan errors 2024-03-09 13:02:04 -05:00
Michael Thomas
c4bf2aae7d fix: migrate action expression validation to separate rule class 2024-03-09 12:57:34 -05:00
Michael Thomas
69ca88d9f8 fix(api): use kebab case route for validate-expression endpoint 2024-03-09 12:07:20 -05:00
Michael Thomas
b38b7b2534 fix: drop unnecessary changes to composer.lock 2024-03-09 12:05:56 -05:00
Michael Thomas
f19bfc3b4b fix(ActionExpression): update list of valid variable names to reflect actual values 2024-03-09 12:03:46 -05:00
Michael Thomas
d22f9c09d7 fix(RuleAction): add return type to getValue 2024-03-09 12:02:47 -05:00
Michael Thomas
fc2da9eb42 fix(ExpressionController): remove unnecessary rule repository 2024-03-09 11:27:21 -05:00
James Cole
f2c9e20aef Fix other pages 2024-03-09 13:35:22 +01:00
James Cole
16b8ca2746 Add some spacing 2024-03-09 13:20:43 +01:00
James Cole
46ea074821 Merge branch 'main' into develop 2024-03-09 13:20:03 +01:00
James Cole
d2c89781e2 Rebuild frontend 2024-03-09 13:19:39 +01:00
James Cole
e54d711891 Improve colors. 2024-03-09 13:17:58 +01:00
James Cole
84d3ad4764 Remove unused local files. 2024-03-09 13:12:33 +01:00
James Cole
b908951a2d Refactor views 2024-03-09 13:08:23 +01:00
James Cole
8b87deea58 Refactor error pages 2024-03-09 13:03:02 +01:00
James Cole
0d7325b3dc Fix CSS and JS (on dashboard) 2024-03-09 12:21:45 +01:00
James Cole
a3fd99a498 Rename (unused) files. 2024-03-09 12:11:18 +01:00
James Cole
0ff405d1e0 Refactor views and CSS 2024-03-09 12:11:06 +01:00
James Cole
46a60af966 Clean up authentication views. 2024-03-09 08:13:53 +01:00
James Cole
591c9e3b39 Move old login screen. 2024-03-09 07:00:35 +01:00
James Cole
c30461b20b Update lock.yml
Signed-off-by: James Cole <james@firefly-iii.org>
2024-03-09 05:20:30 +01:00
James Cole
2c3f86d9bc Update lock.yml
Signed-off-by: James Cole <james@firefly-iii.org>
2024-03-09 05:19:17 +01:00
Michael Thomas
34349e4475 chore: fix typo 2024-03-07 21:37:24 -05:00
Michael Thomas
6acd5be5dc chore: remove accidental changes 2024-03-07 21:10:11 -05:00
Michael Thomas
55a2b4e789 feat: make all transaction journal variables globals
removes redundant reference to the `transaction` object by making all its properties global
2024-03-07 20:58:43 -05:00
Michael Thomas
f41397eb43 refactor: add method on RuleAction to compute action value 2024-03-07 19:02:40 -05:00
Michael Thomas
41fc1e8f82 Merge remote-tracking branch 'upstream/develop' into feat/expression-engine 2024-03-07 13:09:43 -05:00
Michael Thomas
bee219ebf7 refactor: inject ExpressionLanguage singleton using DI 2024-03-07 13:00:57 -05:00
Michael Thomas
438f602961 feat: surface expression validation errors when creating or updating rules 2024-03-07 12:23:32 -05:00
James Cole
429e72e681 Merge branch 'develop' of github.com:firefly-iii/firefly-iii into develop 2024-03-07 06:08:09 +01:00
James Cole
7a134781f2 Fix route name. 2024-03-07 06:01:39 +01:00
Michael Thomas
b572c1dcd3 Merge remote-tracking branch 'upstream/main' into feat/expression-engine 2024-03-06 21:38:40 -05:00
Michael Thomas
95593f847b feat: update all rules to support action value expressions 2024-03-06 20:54:50 -05:00
github-actions
b82fcbd97b Auto commit for release 'develop' on 2024-03-07 2024-03-07 01:29:08 +01:00
Michael Thomas
daddee7806 feat: support action expression parsing, validation, and evaluation 2024-03-06 17:50:16 -05:00
James Cole
930a08ec90 Better index for accounts. 2024-03-06 19:54:09 +01:00
James Cole
fd2edf3b23 Various code cleanup. 2024-03-06 07:16:01 +01:00
James Cole
0597255c08 Fix #8632 2024-03-06 07:01:21 +01:00
James Cole
955ab38a85 Merge pull request #8634 from WardenJakx/develop 2024-03-06 06:10:29 +01:00
WardenJakx
1311a0db8b fix broken link 2024-03-05 22:35:23 -05:00
James Cole
0ce9ee6a6c Ignore phpstan error [skip ci] 2024-03-05 19:39:20 +01:00
James Cole
3a339382d4 Add a button to go back to the v1 layout. 2024-03-05 19:38:45 +01:00
James Cole
a5b15bbc16 Rebuild frontend for basic account list. 2024-03-05 05:54:04 +01:00
James Cole
fbf89fd514 Merge branch 'develop' of github.com:firefly-iii/firefly-iii into develop 2024-03-04 20:42:05 +01:00
James Cole
b3223feba2 Add debug log 2024-03-04 20:41:59 +01:00
James Cole
88a9bc379e Expand account list 2024-03-04 20:41:34 +01:00
James Cole
b442b91b7c Merge pull request #8621 from firefly-iii/dependabot/composer/develop/barryvdh/laravel-ide-helper-3.0.0 2024-03-04 06:01:38 +01:00
dependabot[bot]
9fadbbe087 Bump barryvdh/laravel-ide-helper from 2.15.1 to 3.0.0
Bumps [barryvdh/laravel-ide-helper](https://github.com/barryvdh/laravel-ide-helper) from 2.15.1 to 3.0.0.
- [Release notes](https://github.com/barryvdh/laravel-ide-helper/releases)
- [Changelog](https://github.com/barryvdh/laravel-ide-helper/blob/master/CHANGELOG.md)
- [Commits](https://github.com/barryvdh/laravel-ide-helper/compare/v2.15.1...v3.0.0)

---
updated-dependencies:
- dependency-name: barryvdh/laravel-ide-helper
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-03-04 03:49:45 +00:00
github-actions
1ef7239276 Auto commit for release 'develop' on 2024-03-04 2024-03-04 01:30:26 +01:00
James Cole
ea573e9434 Remove some. 2024-03-03 20:07:47 +01:00
James Cole
34fa24e4a8 Remove some indices 2024-03-03 20:01:35 +01:00
James Cole
a1be4a4d8a Add indices 2024-03-03 19:58:51 +01:00
James Cole
b8e8af1e2a Update database version. 2024-03-03 17:58:13 +01:00
James Cole
c13a3fb30c Add missing indices. 2024-03-03 17:55:59 +01:00
James Cole
cb8fa4e1f4 Fix https://github.com/firefly-iii/firefly-iii/issues/8616 2024-03-03 13:45:05 +01:00
James Cole
bf7f4f9887 Fix https://github.com/firefly-iii/firefly-iii/issues/8597 2024-03-03 10:13:49 +01:00
James Cole
af48548e81 Fix https://github.com/firefly-iii/firefly-iii/issues/8608 2024-03-02 19:20:54 +01:00
github-actions
90d58ec8fa Auto commit for release 'v6.1.10' on 2024-03-02 2024-03-02 17:12:03 +01:00
github-actions
e92dd7f464 Merge branch 'develop' 2024-03-02 16:08:11 +00:00
James Cole
3bdf9eeed2 Jump to v34 2024-03-02 17:06:47 +01:00
James Cole
558ac7b0da Update changelog. 2024-03-02 16:53:19 +01:00
James Cole
9d0488ffbc fix phpstan issues. 2024-02-29 06:39:58 +01:00
James Cole
d7fa8b283e Merge branch 'develop' of github.com:firefly-iii/firefly-iii into develop 2024-02-29 06:27:24 +01:00
James Cole
a0097bd613 Fix issues with available budgets. 2024-02-29 06:26:23 +01:00
github-actions
ffc2156e5f Auto commit for release 'develop' on 2024-02-29 2024-02-29 01:28:57 +01:00
James Cole
e0a89bb5fe Rebuild JS 2024-02-26 20:08:14 +01:00
James Cole
647179cd3c Rebuild JS 2024-02-26 19:56:19 +01:00
James Cole
5106ccdbd7 Merge branch 'main' into develop 2024-02-26 19:55:14 +01:00
James Cole
7103098fe7 Better error handling 2024-02-26 19:54:45 +01:00
James Cole
f8072f0bfc Merge pull request #8588 from firefly-iii/dependabot/github_actions/JC5/firefly-iii-dev-33
Bump JC5/firefly-iii-dev from 32 to 33
2024-02-26 06:17:04 +01:00
dependabot[bot]
96ac3a95c8 Bump JC5/firefly-iii-dev from 32 to 33
Bumps [JC5/firefly-iii-dev](https://github.com/jc5/firefly-iii-dev) from 32 to 33.
- [Commits](https://github.com/jc5/firefly-iii-dev/compare/v32...v33)

---
updated-dependencies:
- dependency-name: JC5/firefly-iii-dev
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-02-26 03:23:03 +00:00
github-actions
cd713dc40f Auto commit for release 'develop' on 2024-02-26 2024-02-26 01:29:50 +01:00
James Cole
d9fba39d80 Fix detection of transaction type. 2024-02-25 18:24:10 +01:00
James Cole
2564470197 Update source account detection. 2024-02-25 18:14:30 +01:00
James Cole
9222c82af0 Expand frontend, first attempt at sorting. 2024-02-25 18:09:52 +01:00
James Cole
243f283bfd Fix tests 2024-02-24 08:36:57 +01:00
James Cole
5b60aaecc0 Update translations. 2024-02-24 08:19:23 +01:00
James Cole
20a4caec60 Add some missing translations 2024-02-24 06:03:34 +01:00
James Cole
99cc096b71 Fix https://github.com/firefly-iii/firefly-iii/issues/8578 2024-02-24 05:38:02 +01:00
James Cole
5626d1c56d Fix https://github.com/firefly-iii/firefly-iii/issues/8575 2024-02-23 17:06:25 +01:00
James Cole
68c9c4ec3c PHPStorm can order methods by alphabet, who knew. 2024-02-22 20:11:09 +01:00
James Cole
f9d4a43e05 This should fix the ci issues. 2024-02-22 06:57:57 +01:00
James Cole
92e7f344e0 Refresh update code. 2024-02-22 06:52:58 +01:00
github-actions
89ce2838d5 Auto commit for release 'develop' on 2024-02-22 2024-02-22 01:29:01 +01:00
James Cole
356b217692 Add missing array 2024-02-20 20:33:33 +01:00
James Cole
950e39b753 Clean up methods. 2024-02-20 20:05:43 +01:00
James Cole
8f14979717 Clean up rule set. 2024-02-20 19:59:55 +01:00
James Cole
aa2afd162e Fix https://github.com/orgs/firefly-iii/discussions/8557 2024-02-20 19:51:13 +01:00
James Cole
fe33352ec1 Fix translation for https://github.com/firefly-iii/firefly-iii/issues/8555 2024-02-19 05:57:06 +01:00
github-actions
65c5249815 Auto commit for release 'develop' on 2024-02-19 2024-02-19 01:30:23 +01:00
James Cole
b1afaea1aa Various updates. 2024-02-18 11:35:08 +01:00
James Cole
997dc3814b Add host header validation 2024-02-17 08:18:49 +01:00
James Cole
b37b5b86d4 Fix https://github.com/firefly-iii/firefly-iii/issues/8544 2024-02-16 20:42:04 +01:00
github-actions
b13a4e1016 Auto commit for release 'develop' on 2024-02-15 2024-02-15 01:29:20 +01:00
James Cole
7897ebc4d5 Update code 2024-02-14 19:47:35 +01:00
James Cole
ac17b82d85 Do not complain when the category is already set. 2024-02-14 19:34:36 +01:00
James Cole
1b1712d998 Make sure that errors in the incoming webhook url are caught. 2024-02-14 19:32:15 +01:00
James Cole
a2c0d9f7d0 The update checker can handle the development releases 2024-02-14 06:34:38 +01:00
James Cole
5b68b25c85 Merge pull request #8538 from firefly-iii/dependabot/composer/develop/phpunit/phpunit-11.0.3
Bump phpunit/phpunit from 10.5.10 to 11.0.3
2024-02-12 19:52:51 +01:00
dependabot[bot]
d3a215b575 Bump phpunit/phpunit from 10.5.10 to 11.0.3
Bumps [phpunit/phpunit](https://github.com/sebastianbergmann/phpunit) from 10.5.10 to 11.0.3.
- [Changelog](https://github.com/sebastianbergmann/phpunit/blob/11.0.3/ChangeLog-11.0.md)
- [Commits](https://github.com/sebastianbergmann/phpunit/compare/10.5.10...11.0.3)

---
updated-dependencies:
- dependency-name: phpunit/phpunit
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-02-12 03:35:09 +00:00
github-actions
5c352a0d3e Auto commit for release 'develop' on 2024-02-12 2024-02-12 01:29:15 +01:00
James Cole
fded058ea6 Rebuild frontend. 2024-02-11 19:16:27 +01:00
James Cole
99f041b114 Editable up until date. 2024-02-11 10:43:14 +01:00
James Cole
283b594995 Merge branch 'develop' of github.com:firefly-iii/firefly-iii into develop
# Conflicts:
#	app/Helpers/Collector/GroupCollector.php
2024-02-10 08:29:59 +01:00
James Cole
723aa65e7a Inline edit for v2 2024-02-10 08:28:59 +01:00
github-actions
64d315ad51 Auto commit for release 'develop' on 2024-02-08 2024-02-08 01:29:34 +01:00
James Cole
d0844356cb Fix https://github.com/firefly-iii/firefly-iii/issues/8521 2024-02-07 06:14:40 +01:00
James Cole
ba8d65835a Remove unused translation. 2024-02-07 06:02:43 +01:00
github-actions
fa3343f437 Auto commit for release 'v6.1.9' on 2024-02-05 2024-02-05 19:53:12 +01:00
James Cole
c5b8a951d2 Update changelog for new release. 2024-02-05 06:37:16 +01:00
James Cole
20b1fc05cb Don't put a "v" in front of the version when it's a develop version. 2024-02-05 06:29:19 +01:00
github-actions
ab441d7d0c Auto commit for release 'develop' on 2024-02-05 2024-02-05 01:31:01 +01:00
James Cole
b621d14bdf Merge branch 'main' into develop 2024-02-04 06:42:12 +01:00
James Cole
94730e998b Better workflow for prune. 2024-02-04 06:39:55 +01:00
James Cole
23c2f76e52 Merge branch 'main' into develop 2024-02-04 06:36:42 +01:00
James Cole
40196d48b2 Back to monday/thursday 2024-02-04 06:36:32 +01:00
James Cole
ef3c2eb701 Merge branch 'develop' of github.com:firefly-iii/firefly-iii into develop 2024-02-04 06:35:50 +01:00
github-actions
4f994a2795 Auto commit for release 'develop' on 2024-02-04 2024-02-04 01:31:06 +01:00
James Cole
807e575dac Merge pull request #8502 from likuilin/issue-8501
Fix incorrect ID in bulk delete tx URL
2024-02-03 20:35:55 +01:00
kuilin
04b1465eb7 Fix incorrect ID in bulk delete tx URL
Fixes #8501

Signed-off-by: kuilin <kuilin@gmail.com>
2024-02-03 14:23:26 -05:00
James Cole
6f79ab2a70 Merge branch 'main' into develop 2024-02-03 20:00:52 +01:00
James Cole
c1469f016e Add version to develop branch. 2024-02-03 20:00:41 +01:00
James Cole
373ec934df Update version, fix https://github.com/firefly-iii/firefly-iii/issues/8499 2024-02-03 19:04:25 +01:00
github-actions
abd34ba1dc Auto commit for release 'v6.1.8' on 2024-02-03 2024-02-03 16:38:48 +01:00
James Cole
89b7596caf Add fixed issue to changelog. 2024-02-03 16:31:58 +01:00
James Cole
3543548ba0 Fix https://github.com/firefly-iii/firefly-iii/issues/8497 2024-02-03 13:09:44 +01:00
James Cole
a932965908 Merge branch 'main' into develop 2024-02-03 10:09:41 +01:00
James Cole
9056126328 Update release script. 2024-02-03 10:09:30 +01:00
James Cole
0e85a5123d Changelog for next release. 2024-02-03 10:08:46 +01:00
James Cole
d3f19db42d This should fix the tests again. 2024-02-03 10:08:34 +01:00
James Cole
9894d16d26 Fix https://github.com/firefly-iii/firefly-iii/issues/8493 2024-02-03 07:51:18 +01:00
James Cole
0b069bcb58 Merge branch 'main' into develop 2024-02-01 05:44:52 +01:00
James Cole
36d54c3fac Cast to string. 2024-02-01 05:44:41 +01:00
James Cole
530e48f16e Fix description. 2024-02-01 05:43:48 +01:00
github-actions
9763f9f922 Auto commit for release 'develop' on 2024-02-01 2024-02-01 01:31:55 +01:00
James Cole
bbd4d7a8ef Rebuild JS as well. 2024-01-31 07:35:43 +01:00
James Cole
bafe2ece8c Should fix message title. 2024-01-31 07:25:51 +01:00
James Cole
b2449eb726 Merge branch 'main' into develop 2024-01-31 06:38:48 +01:00
James Cole
353c345d9a Updated release script. 2024-01-31 06:38:36 +01:00
James Cole
e2461ba839 Also support redirect 2024-01-30 18:14:56 +01:00
James Cole
e199fdd2b6 Make sure the demo user can't export data. 2024-01-30 18:11:45 +01:00
James Cole
592a89d6a5 Merge pull request #8478 from firefly-iii/dependabot/github_actions/actions/github-script-7
Bump actions/github-script from 6 to 7
2024-01-30 08:31:34 +01:00
James Cole
7a7b629225 Merge pull request #8477 from firefly-iii/dependabot/github_actions/actions/checkout-4
Bump actions/checkout from 3 to 4
2024-01-30 08:31:25 +01:00
James Cole
21a4774561 Merge pull request #8476 from firefly-iii/dependabot/github_actions/actions/dependency-review-action-4
Bump actions/dependency-review-action from 3 to 4
2024-01-30 08:31:17 +01:00
James Cole
5be97bb18f Merge pull request #8475 from firefly-iii/dependabot/github_actions/JC5/firefly-iii-dev-29
Bump JC5/firefly-iii-dev from 16 to 29
2024-01-30 08:31:07 +01:00
dependabot[bot]
a12ff10550 Bump actions/github-script from 6 to 7
Bumps [actions/github-script](https://github.com/actions/github-script) from 6 to 7.
- [Release notes](https://github.com/actions/github-script/releases)
- [Commits](https://github.com/actions/github-script/compare/v6...v7)

---
updated-dependencies:
- dependency-name: actions/github-script
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-01-30 07:28:29 +00:00
dependabot[bot]
c808294ca1 Bump actions/checkout from 3 to 4
Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 4.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-01-30 07:28:25 +00:00
dependabot[bot]
9dcf264658 Bump actions/dependency-review-action from 3 to 4
Bumps [actions/dependency-review-action](https://github.com/actions/dependency-review-action) from 3 to 4.
- [Release notes](https://github.com/actions/dependency-review-action/releases)
- [Commits](https://github.com/actions/dependency-review-action/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/dependency-review-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-01-30 07:28:21 +00:00
dependabot[bot]
e0bbd3a810 Bump JC5/firefly-iii-dev from 16 to 29
Bumps [JC5/firefly-iii-dev](https://github.com/jc5/firefly-iii-dev) from 16 to 29.
- [Commits](https://github.com/jc5/firefly-iii-dev/compare/v16...v29)

---
updated-dependencies:
- dependency-name: JC5/firefly-iii-dev
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-01-30 07:28:16 +00:00
James Cole
2886a22f4e Update dependabot.yml
Signed-off-by: James Cole <james@firefly-iii.org>
2024-01-30 08:27:47 +01:00
James Cole
6f783f7662 Update stale.yml
Signed-off-by: James Cole <james@firefly-iii.org>
2024-01-30 08:24:08 +01:00
James Cole
992fdc9e27 Merge branch 'main' into develop 2024-01-30 05:41:55 +01:00
James Cole
73529c31e0 Only monday / thursday 2024-01-30 05:41:44 +01:00
github-actions
d9fc91a432 Auto commit for release 'develop' on 2024-01-30 2024-01-30 01:29:11 +01:00
James Cole
6a432e7931 Fix https://github.com/firefly-iii/firefly-iii/issues/8447 2024-01-29 19:47:00 +01:00
James Cole
26f7575ba2 Fix https://github.com/firefly-iii/firefly-iii/issues/8471 2024-01-29 19:10:24 +01:00
James Cole
b1c1bbd6c0 Fix https://github.com/firefly-iii/firefly-iii/issues/8472 2024-01-29 19:05:40 +01:00
James Cole
d40643af54 Merge branch 'main' into develop 2024-01-29 06:24:46 +01:00
James Cole
11cfefd908 Update workflow and support guide. 2024-01-29 06:24:24 +01:00
github-actions
ff2b2eec9b Auto commit for release 'develop' on 2024-01-29 2024-01-29 02:35:54 +00:00
James Cole
4f1187bf6e Fix https://github.com/firefly-iii/firefly-iii/issues/8467 2024-01-28 17:29:25 +01:00
James Cole
642539e410 Fix https://github.com/firefly-iii/firefly-iii/issues/8457 2024-01-28 16:34:17 +01:00
github-actions
1f774e0d71 Auto commit for release 'develop' on 2024-01-28 2024-01-28 13:48:09 +00:00
James Cole
1da19cde6f Merge branch 'main' into develop 2024-01-28 14:42:40 +01:00
James Cole
ac5973833e Fix phpcs before it fails anyway 2024-01-28 14:42:23 +01:00
James Cole
40b0e31d27 Merge branch 'main' into develop 2024-01-28 14:37:24 +01:00
James Cole
f56f8d72df Make sure crowdin config is correct. 2024-01-28 14:37:12 +01:00
James Cole
b47bb13558 Change some code. 2024-01-28 14:34:07 +01:00
James Cole
b4133b6512 Merge branch 'main' into develop 2024-01-28 14:33:21 +01:00
James Cole
fb20095502 Slight change in workflow. 2024-01-28 14:33:07 +01:00
James Cole
cfc23c4cb9 Merge branch 'main' into develop 2024-01-28 14:28:33 +01:00
James Cole
44701f1633 Clean up workflow. 2024-01-28 14:25:38 +01:00
James Cole
fadf799b9c Add new workflow. 2024-01-28 12:41:23 +01:00
James Cole
c22a9784ee Clean up code 2024-01-25 03:18:23 +01:00
James Cole
a6512d3d74 Add manifest to session pages. https://github.com/firefly-iii/firefly-iii/issues/8455 2024-01-25 03:18:13 +01:00
James Cole
cea2ca7532 Rebuild old and new JS. 2024-01-24 07:03:08 +01:00
James Cole
e322069bb4 Possible fix for https://github.com/firefly-iii/firefly-iii/issues/8442 2024-01-24 07:00:06 +01:00
James Cole
da7a976c4e Fix https://github.com/firefly-iii/firefly-iii/issues/8446 2024-01-23 20:21:41 +01:00
James Cole
300dba7257 Rebuild frontend for dynamic title update 2024-01-23 19:36:45 +01:00
James Cole
ec59f80fe3 Fix label actions. 2024-01-22 06:17:26 +01:00
James Cole
37aa5bcc60 Merge branch 'develop' of github.com:firefly-iii/firefly-iii into develop 2024-01-22 06:13:26 +01:00
James Cole
e50d2cb481 Add experimental menu. 2024-01-22 06:13:19 +01:00
James Cole
468709c092 Merge pull request #8438 from firefly-iii/dependabot/composer/develop/doctrine/dbal-3.7.3
Bump doctrine/dbal from 3.7.2 to 3.7.3
2024-01-22 06:12:18 +01:00
James Cole
11ced9216c Merge pull request #8439 from firefly-iii/dependabot/npm_and_yarn/develop/i18next-23.7.18
Bump i18next from 23.7.17 to 23.7.18
2024-01-22 06:12:08 +01:00
dependabot[bot]
cfa9151f45 Bump i18next from 23.7.17 to 23.7.18
Bumps [i18next](https://github.com/i18next/i18next) from 23.7.17 to 23.7.18.
- [Release notes](https://github.com/i18next/i18next/releases)
- [Changelog](https://github.com/i18next/i18next/blob/master/CHANGELOG.md)
- [Commits](https://github.com/i18next/i18next/compare/v23.7.17...v23.7.18)

---
updated-dependencies:
- dependency-name: i18next
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-01-22 03:59:00 +00:00
dependabot[bot]
6577224a55 Bump doctrine/dbal from 3.7.2 to 3.7.3
Bumps [doctrine/dbal](https://github.com/doctrine/dbal) from 3.7.2 to 3.7.3.
- [Release notes](https://github.com/doctrine/dbal/releases)
- [Commits](https://github.com/doctrine/dbal/compare/3.7.2...3.7.3)

---
updated-dependencies:
- dependency-name: doctrine/dbal
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-01-22 03:18:11 +00:00
James Cole
b4209f2e72 Enable inline edit. 2024-01-21 19:36:56 +01:00
James Cole
f045e4ea69 Fix amount 2024-01-21 18:01:00 +01:00
James Cole
4a37152aea Fix https://github.com/firefly-iii/firefly-iii/issues/8433 2024-01-21 15:58:40 +01:00
James Cole
2907db1380 Merge branch 'develop' of github.com:firefly-iii/firefly-iii into develop 2024-01-21 15:00:59 +01:00
James Cole
80a35692c5 Fix logs. 2024-01-21 15:00:51 +01:00
James Cole
1a6fe5ca3c Apparently people need to be warned. 2024-01-21 15:00:43 +01:00
James Cole
13ec3493bd Merge pull request #8432 from stevietv/patch-1
Update favicons.twig
2024-01-21 14:56:15 +01:00
Stevie Robinson
bf55e8df72 Update favicons.twig
Signed-off-by: Stevie Robinson <stevie.robinson@gmail.com>
2024-01-21 11:18:34 +01:00
James Cole
775504d812 Merge branch 'main' into develop 2024-01-21 07:35:14 +01:00
James Cole
8d6c45b68e No longer lock issues. 2024-01-21 07:35:02 +01:00
James Cole
db9094956e Support even bigger amounts for https://github.com/firefly-iii/firefly-iii/issues/8431 2024-01-21 07:24:16 +01:00
James Cole
25d02e92f4 Change issue to PR. 2024-01-20 18:30:46 +01:00
James Cole
81cb0a38f3 Add debug trigger label. 2024-01-20 16:44:10 +01:00
James Cole
e07a9d6162 Remove huntr thing. 2024-01-20 16:37:28 +01:00
James Cole
2ccbc16dfa Merge tag 'v6.1.7' into develop
v6.1.7
2024-01-20 16:30:23 +01:00
James Cole
e00addc0b0 Merge branch 'release/v6.1.7' 2024-01-20 16:30:16 +01:00
James Cole
da7a2cf0c0 Update meta data for new release. 2024-01-20 16:29:00 +01:00
James Cole
2368788405 Fix issue with "createFromFormat". 2024-01-20 08:07:27 +01:00
James Cole
f603415931 Rebuild edit script. 2024-01-20 07:09:26 +01:00
James Cole
523fa42998 Merge branch 'main' into develop 2024-01-20 07:05:27 +01:00
James Cole
e449395f3f Clean up some code. 2024-01-20 07:04:19 +01:00
James Cole
d8d8002f1e Add some debug to non strict search 2024-01-20 06:53:43 +01:00
James Cole
2570ca9573 Fix account type filter 2024-01-20 06:53:30 +01:00
James Cole
e5fdc2cbfd Merge pull request #8429 from firefly-iii/dependabot/npm_and_yarn/vite-4.5.2
Bump vite from 4.5.1 to 4.5.2
2024-01-20 06:53:12 +01:00
dependabot[bot]
0349cdbc1b Bump vite from 4.5.1 to 4.5.2
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 4.5.1 to 4.5.2.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v4.5.2/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v4.5.2/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-01-20 05:39:48 +00:00
James Cole
122f0309a6 Fix #8425 2024-01-19 20:23:04 +01:00
James Cole
09bff5ea4e Fix https://github.com/firefly-iii/firefly-iii/issues/8418 2024-01-18 18:57:29 +01:00
James Cole
7ea112c5e7 Fix https://github.com/firefly-iii/firefly-iii/issues/8349 and 2024-01-18 18:57:23 +01:00
James Cole
44df07a5f5 Update, rebuild, and add a new API endpoint. 2024-01-17 20:23:02 +01:00
James Cole
66b0d9d309 Merge pull request #8394 from firefly-iii/dependabot/npm_and_yarn/develop/date-fns-3.2.0 2024-01-15 05:24:53 +01:00
dependabot[bot]
6ac3d3e62c Bump date-fns from 3.1.0 to 3.2.0
Bumps [date-fns](https://github.com/date-fns/date-fns) from 3.1.0 to 3.2.0.
- [Release notes](https://github.com/date-fns/date-fns/releases)
- [Changelog](https://github.com/date-fns/date-fns/blob/main/CHANGELOG.md)
- [Commits](https://github.com/date-fns/date-fns/compare/v3.1.0...v3.2.0)

---
updated-dependencies:
- dependency-name: date-fns
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-01-15 03:22:07 +00:00
James Cole
925450f84c Fix https://github.com/firefly-iii/firefly-iii/issues/8390 2024-01-14 13:59:09 +01:00
James Cole
62f59c6a19 Update packages 2024-01-14 13:58:16 +01:00
James Cole
7db21612a0 Escape backticks [skip ci] 2024-01-14 11:20:43 +01:00
James Cole
2c0da2cf26 Duh, single quotes [skip ci] 2024-01-14 11:19:47 +01:00
James Cole
79484cc194 Experimental action [skip ci] 2024-01-14 11:18:17 +01:00
James Cole
6f18748c72 Merge branch 'main' into develop 2024-01-14 07:16:21 +01:00
James Cole
577824930f Attempt at newline. 2024-01-14 07:15:08 +01:00
James Cole
d614519ee7 Add necessary params. 2024-01-14 07:12:47 +01:00
James Cole
ae31041f7f Add context 2024-01-14 07:11:39 +01:00
James Cole
62c4d0cf86 new command 2024-01-14 07:07:14 +01:00
James Cole
c2ddabbad2 Expand index. 2024-01-14 07:06:55 +01:00
James Cole
458402aaff Code cleanup. 2024-01-14 05:10:05 +01:00
James Cole
5c81e98218 Add list of transactions. 2024-01-13 20:34:09 +01:00
James Cole
37a46b02f4 Fix https://github.com/firefly-iii/firefly-iii/issues/8374 2024-01-13 08:13:25 +01:00
James Cole
b3e1ecdd02 Merge branch 'main' into develop 2024-01-13 08:13:10 +01:00
James Cole
1780e6dc61 Remove label step, no longer necessary. 2024-01-13 07:55:04 +01:00
James Cole
50f346d092 Add body to secret 2024-01-13 07:54:12 +01:00
James Cole
ccc851090a Manually add comment, lock and redirect user. 2024-01-13 07:50:43 +01:00
James Cole
4605d84cc8 Add more permissions 2024-01-13 07:41:15 +01:00
James Cole
8c7ab50325 Add the action manually. 2024-01-13 07:40:01 +01:00
James Cole
908539836b Use correct string name. 2024-01-13 07:38:21 +01:00
James Cole
9f71cf966c Remove the old step. 2024-01-13 07:36:55 +01:00
James Cole
02ed47c578 Update job. Do it manually. 2024-01-13 07:36:09 +01:00
James Cole
1ddbaf0884 Merge branch 'main' into develop 2024-01-13 07:24:23 +01:00
James Cole
d3ed8c6f0f New action for issues. 2024-01-13 07:24:11 +01:00
James Cole
4f1ac2ac6f Minor code cleanup 2024-01-12 19:03:51 +01:00
James Cole
1e733f4c8b Fix https://github.com/firefly-iii/firefly-iii/issues/8377 2024-01-12 18:57:38 +01:00
James Cole
8e2546da9d Update translations. 2024-01-10 20:29:00 +01:00
James Cole
3a8162d3c5 Add button for https://github.com/firefly-iii/firefly-iii/issues/8369 2024-01-10 05:34:20 +01:00
James Cole
f7ceb75316 Merge pull request #8370 from luzpaz/typos
Fix various typos
2024-01-10 05:31:16 +01:00
luzpaz
744e193faa Fix various typos
Found via `codespell -q 3 -S "./resources/lang,./resources/assets/js/locales" -L hastable`
2024-01-10 01:12:48 +00:00
James Cole
12b0e11592 From error to debug. 2024-01-09 21:05:17 +01:00
James Cole
717f3a9e3d From info to debug 2024-01-09 21:04:12 +01:00
James Cole
b9f0682f04 Add audit entries. 2024-01-09 21:03:26 +01:00
James Cole
8792465fd5 Add validation warnings in audit logs. 2024-01-09 20:58:18 +01:00
James Cole
6fbf9a119d Change priority on audit messages. 2024-01-09 20:48:17 +01:00
James Cole
0dfa21a92e Merge branch 'main' into develop 2024-01-08 20:39:02 +01:00
James Cole
136fe8e8eb Update label-actions.yml
Signed-off-by: James Cole <james@firefly-iii.org>
2024-01-08 20:32:31 +01:00
James Cole
d510c4e31d Rebuild frontend v2 2024-01-08 20:31:35 +01:00
James Cole
c066bcc4ce Update label-actions.yml
Signed-off-by: James Cole <james@firefly-iii.org>
2024-01-08 20:30:47 +01:00
James Cole
c9e7ae1f08 Update label-actions.yml
Signed-off-by: James Cole <james@firefly-iii.org>
2024-01-08 20:25:25 +01:00
James Cole
6a9b4f4d55 Update label-actions.yml
Signed-off-by: James Cole <james@firefly-iii.org>
2024-01-08 20:20:22 +01:00
James Cole
2b5054b905 Merge branch 'develop' of github.com:firefly-iii/firefly-iii into develop 2024-01-08 20:11:39 +01:00
James Cole
0a45a2485b Small edit and show updates 2024-01-08 20:11:27 +01:00
James Cole
fcc0294d07 Smaller max size 2024-01-08 12:56:57 +01:00
James Cole
ad981c2bf0 Fix breadcrumb bg color. 2024-01-07 19:55:56 +01:00
James Cole
75a32b2f94 Expand v2 layout with experimental view. 2024-01-07 12:51:42 +01:00
James Cole
70b60f756b Rebuild frontend [skip ci] 2024-01-07 07:02:53 +01:00
James Cole
0d2ae8ae23 Clean up languages [skip ci] 2024-01-07 07:02:28 +01:00
James Cole
8043c86942 Update readme. 2024-01-06 19:22:38 +01:00
James Cole
4c30a7bc55 Expand edit form. 2024-01-06 17:24:54 +01:00
James Cole
f615b9c252 Fix https://github.com/firefly-iii/firefly-iii/issues/8352 2024-01-06 14:44:50 +01:00
James Cole
c19b36a391 Fix https://github.com/firefly-iii/firefly-iii/issues/8352 2024-01-06 14:40:06 +01:00
James Cole
935634e487 Sanity check on number. 2024-01-06 14:23:20 +01:00
James Cole
2c3f032a2b Merge branch 'release/v6.1.6' 2024-01-06 11:13:41 +01:00
James Cole
7e62b75b12 Merge tag 'v6.1.6' into develop
v6.1.6
2024-01-06 11:13:41 +01:00
James Cole
de57ab0874 Update meta files for new release. 2024-01-06 11:11:18 +01:00
James Cole
6fb4aaecd3 Fix a very dumb bug. 2024-01-06 11:09:40 +01:00
James Cole
45fdbf5a11 Merge tag 'v6.1.5' into develop
v6.1.5
2024-01-06 10:59:05 +01:00
James Cole
c6615a7b17 Merge branch 'release/v6.1.5' 2024-01-06 10:59:02 +01:00
James Cole
0efb3d2dcf Fix currency validation. 2024-01-06 08:33:38 +01:00
James Cole
b8a58f83ee New packages. 2024-01-06 07:59:46 +01:00
James Cole
110228e65e Fix phpstan issue. 2024-01-06 07:49:50 +01:00
James Cole
8ad27e0eda Update meta files for new release. 2024-01-06 07:42:00 +01:00
James Cole
2e0d90c685 Expand edit transaction form. 2024-01-06 07:26:03 +01:00
James Cole
bd2ecb13b8 Change time for rule. 2024-01-05 18:09:19 +01:00
James Cole
5725570dbb Add marker. Seems fastest solution. 2024-01-05 14:47:44 +01:00
James Cole
11f77685e4 Experimental code cleanup. 2024-01-05 14:29:59 +01:00
James Cole
0521c46d27 test 2024-01-05 14:15:26 +01:00
James Cole
50d6225590 test 2024-01-05 14:15:02 +01:00
James Cole
df55f7de79 test 2024-01-05 14:13:44 +01:00
James Cole
5152ae9622 test 2024-01-05 14:11:06 +01:00
James Cole
075d0da63d test 2024-01-05 14:10:07 +01:00
James Cole
d804df2a2f test 2024-01-05 14:09:47 +01:00
James Cole
ff0f8beb81 Of course phpstan has an opinion on this lol 2024-01-05 14:07:13 +01:00
James Cole
c00be92f97 Finalize create transaction form. 2024-01-05 14:04:44 +01:00
James Cole
88f6221424 Small code fix. 2024-01-05 11:09:52 +01:00
James Cole
f9463e02a2 Fix null pointer 2024-01-05 10:55:46 +01:00
James Cole
25a23801be Fix error mail 2024-01-05 10:55:07 +01:00
James Cole
fe7bb02dc5 Clean up min/max sizes of requests. 2024-01-05 09:48:59 +01:00
James Cole
68edcfc4e8 Clean up files and add alias 2024-01-05 08:12:17 +01:00
James Cole
5f8a24a684 Add newline. 2024-01-04 15:43:51 +01:00
James Cole
0a5d62605a Code cleanup and new translations. 2024-01-04 15:42:00 +01:00
James Cole
1873be8d95 Merge branch 'develop' of github.com:firefly-iii/firefly-iii into develop 2024-01-04 15:41:18 +01:00
James Cole
01892c3828 Merge pull request #8348 from lemuelroberto/develop
Update outdated documentation URLs in .env.example
2024-01-04 15:41:00 +01:00
Lemuel Roberto Bonifácio
b87e60c72f Update outdated documentation URLs in .env.example 2024-01-04 11:32:36 -03:00
James Cole
3a083f88b5 Clean up code. 2024-01-04 14:59:55 +01:00
James Cole
566bb2f097 Expand create transaction form. 2024-01-04 14:59:37 +01:00
James Cole
1ba7847d84 Add more details in message. 2024-01-04 11:46:23 +01:00
James Cole
c32044a8eb Smaller notes 2024-01-04 11:41:03 +01:00
James Cole
72a2d417af Change log levels. 2024-01-04 08:35:58 +01:00
James Cole
09c18d6d44 More audit logs. 2024-01-04 08:34:57 +01:00
James Cole
84ae6a633e Add some audit logs. 2024-01-04 08:32:42 +01:00
James Cole
82749cea07 Sanity check in date. 2024-01-04 07:51:37 +01:00
James Cole
23aa0e3ba3 Add some audit log info. 2024-01-04 07:48:51 +01:00
James Cole
8be27a2201 Small code cleanup 2024-01-04 07:44:52 +01:00
James Cole
ff98f3cc3e Expand create transaction form. 2024-01-04 07:26:45 +01:00
James Cole
01c4d25646 Better currency validation for foreign amount 2024-01-04 07:26:12 +01:00
James Cole
292b9ac9d0 Fix wording for https://github.com/firefly-iii/firefly-iii/issues/8328 2024-01-04 07:25:24 +01:00
James Cole
6bdae03961 Extra fix for https://github.com/firefly-iii/firefly-iii/issues/8328 2024-01-04 06:22:47 +01:00
James Cole
7426c6aac3 Split form in parts, add "edit" page. 2024-01-03 19:34:50 +01:00
James Cole
211526c032 Expand new transaction form. 2024-01-03 17:43:05 +01:00
James Cole
e6fe08dd61 Update translations. 2024-01-03 13:05:54 +01:00
James Cole
7bba67130a Merge pull request #8335 from maureenferreira/patch-2
Update intro.php
2024-01-03 07:28:43 +00:00
maureenferreira
7186d8ddfd Update intro.php
Signed-off-by: maureenferreira <142938968+maureenferreira@users.noreply.github.com>
2024-01-03 00:19:18 -06:00
James Cole
5b11c86113 Merge tag 'v6.1.4' into develop
v6.1.4
2024-01-02 22:29:55 +01:00
1101 changed files with 27672 additions and 88630 deletions

View File

@@ -22,6 +22,9 @@
SCRIPT_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
echo "Running PHP CS Fixer"
$SCRIPT_DIR/phpcs.sh
echo "Running PHPStan"
$SCRIPT_DIR/phpstan.sh
echo "Running PHPMD"
$SCRIPT_DIR/phpmd.sh

View File

@@ -35,36 +35,39 @@ $finder = PhpCsFixer\Finder::create()
$config = new PhpCsFixer\Config();
return $config->setRules([
'no_unused_imports' => true,
'@PhpCsFixer' => true,
'@PHP83Migration' => true,
'@PhpCsFixer:risky' => true,
'@PSR12:risky' => true,
'declare_strict_types' => true,
'strict_param' => true,
'comment_to_phpdoc' => false, // breaks phpstan lines in combination with PHPStorm.
'array_syntax' => ['syntax' => 'short'],
'native_function_invocation' => false, // annoying
'php_unit_data_provider_name' => false, // bloody annoying long test names
'static_lambda' => false, // breaks the Response macro for API's.
'phpdoc_summary' => false, // annoying.
'single_space_around_construct' => [
'constructs_followed_by_a_single_space' => [
'protected',
],
],
'statement_indentation' => true,
'type_declaration_spaces' => false,
'cast_spaces' => false,
'binary_operator_spaces' => [
'default' => 'at_least_single_space',
'operators' => [
'=>' => 'align_single_space_by_scope',
'=' => 'align_single_space_minimal_by_scope',
'??=' => 'align_single_space_minimal_by_scope',
],
],
'void_return' => true,
])
return $config->setRules(
[
// rule sets
'@PHP83Migration' => true,
'@PhpCsFixer' => true,
'@PhpCsFixer:risky' => true,
'@PSR12' => true,
'@PSR12:risky' => true,
'declare_strict_types' => true,
'strict_param' => true,
'no_unused_imports' => true,
'single_space_around_construct' => true,
'statement_indentation' => true,
'void_return' => true,
// disabled rules
'native_function_invocation' => false, // annoying
'php_unit_data_provider_name' => false, // bloody annoying long test names
'static_lambda' => false, // breaks the Response macro for API's.
'phpdoc_summary' => false, // annoying.
'comment_to_phpdoc' => false, // breaks phpstan lines in combination with PHPStorm.
'type_declaration_spaces' => false,
'cast_spaces' => false,
// complex rules
'array_syntax' => ['syntax' => 'short'],
'binary_operator_spaces' => [
'default' => 'at_least_single_space',
'operators' => [
'=>' => 'align_single_space_by_scope',
'=' => 'align_single_space_minimal_by_scope',
'??=' => 'align_single_space_minimal_by_scope',
],
],
])
->setFinder($finder);

View File

@@ -8,16 +8,16 @@
"packages": [
{
"name": "composer/pcre",
"version": "3.1.1",
"version": "3.1.3",
"source": {
"type": "git",
"url": "https://github.com/composer/pcre.git",
"reference": "00104306927c7a0919b4ced2aaa6782c1e61a3c9"
"reference": "5b16e25a5355f1f3afdfc2f954a0a80aec4826a8"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/composer/pcre/zipball/00104306927c7a0919b4ced2aaa6782c1e61a3c9",
"reference": "00104306927c7a0919b4ced2aaa6782c1e61a3c9",
"url": "https://api.github.com/repos/composer/pcre/zipball/5b16e25a5355f1f3afdfc2f954a0a80aec4826a8",
"reference": "5b16e25a5355f1f3afdfc2f954a0a80aec4826a8",
"shasum": ""
},
"require": {
@@ -59,7 +59,7 @@
],
"support": {
"issues": "https://github.com/composer/pcre/issues",
"source": "https://github.com/composer/pcre/tree/3.1.1"
"source": "https://github.com/composer/pcre/tree/3.1.3"
},
"funding": [
{
@@ -75,7 +75,7 @@
"type": "tidelift"
}
],
"time": "2023-10-11T07:11:09+00:00"
"time": "2024-03-19T10:26:25+00:00"
},
{
"name": "composer/semver",
@@ -160,16 +160,16 @@
},
{
"name": "composer/xdebug-handler",
"version": "3.0.3",
"version": "3.0.4",
"source": {
"type": "git",
"url": "https://github.com/composer/xdebug-handler.git",
"reference": "ced299686f41dce890debac69273b47ffe98a40c"
"reference": "4f988f8fdf580d53bdb2d1278fe93d1ed5462255"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/composer/xdebug-handler/zipball/ced299686f41dce890debac69273b47ffe98a40c",
"reference": "ced299686f41dce890debac69273b47ffe98a40c",
"url": "https://api.github.com/repos/composer/xdebug-handler/zipball/4f988f8fdf580d53bdb2d1278fe93d1ed5462255",
"reference": "4f988f8fdf580d53bdb2d1278fe93d1ed5462255",
"shasum": ""
},
"require": {
@@ -180,7 +180,7 @@
"require-dev": {
"phpstan/phpstan": "^1.0",
"phpstan/phpstan-strict-rules": "^1.1",
"symfony/phpunit-bridge": "^6.0"
"phpunit/phpunit": "^8.5 || ^9.6 || ^10.5"
},
"type": "library",
"autoload": {
@@ -204,9 +204,9 @@
"performance"
],
"support": {
"irc": "irc://irc.freenode.org/composer",
"irc": "ircs://irc.libera.chat:6697/composer",
"issues": "https://github.com/composer/xdebug-handler/issues",
"source": "https://github.com/composer/xdebug-handler/tree/3.0.3"
"source": "https://github.com/composer/xdebug-handler/tree/3.0.4"
},
"funding": [
{
@@ -222,29 +222,30 @@
"type": "tidelift"
}
],
"time": "2022-02-25T21:32:43+00:00"
"time": "2024-03-26T18:29:49+00:00"
},
{
"name": "friendsofphp/php-cs-fixer",
"version": "v3.45.0",
"version": "v3.52.1",
"source": {
"type": "git",
"url": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer.git",
"reference": "c0daa33cb2533cd73f48dde1c70c2afa3e7953b5"
"reference": "6e77207f0d851862ceeb6da63e6e22c01b1587bc"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/PHP-CS-Fixer/PHP-CS-Fixer/zipball/c0daa33cb2533cd73f48dde1c70c2afa3e7953b5",
"reference": "c0daa33cb2533cd73f48dde1c70c2afa3e7953b5",
"url": "https://api.github.com/repos/PHP-CS-Fixer/PHP-CS-Fixer/zipball/6e77207f0d851862ceeb6da63e6e22c01b1587bc",
"reference": "6e77207f0d851862ceeb6da63e6e22c01b1587bc",
"shasum": ""
},
"require": {
"composer/semver": "^3.4",
"composer/xdebug-handler": "^3.0.3",
"ext-filter": "*",
"ext-json": "*",
"ext-tokenizer": "*",
"php": "^7.4 || ^8.0",
"sebastian/diff": "^4.0 || ^5.0",
"sebastian/diff": "^4.0 || ^5.0 || ^6.0",
"symfony/console": "^5.4 || ^6.0 || ^7.0",
"symfony/event-dispatcher": "^5.4 || ^6.0 || ^7.0",
"symfony/filesystem": "^5.4 || ^6.0 || ^7.0",
@@ -265,7 +266,8 @@
"php-cs-fixer/accessible-object": "^1.1",
"php-cs-fixer/phpunit-constraint-isidenticalstring": "^1.4",
"php-cs-fixer/phpunit-constraint-xmlmatchesxsd": "^1.4",
"phpunit/phpunit": "^9.6 || ^10.5.5",
"phpunit/phpunit": "^9.6 || ^10.5.5 || ^11.0.2",
"symfony/var-dumper": "^5.4 || ^6.0 || ^7.0",
"symfony/yaml": "^5.4 || ^6.0 || ^7.0"
},
"suggest": {
@@ -304,7 +306,7 @@
],
"support": {
"issues": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues",
"source": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/tree/v3.45.0"
"source": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/tree/v3.52.1"
},
"funding": [
{
@@ -312,7 +314,7 @@
"type": "github"
}
],
"time": "2023-12-30T02:07:07+00:00"
"time": "2024-03-19T21:02:43+00:00"
},
{
"name": "psr/container",
@@ -469,29 +471,29 @@
},
{
"name": "sebastian/diff",
"version": "5.1.0",
"version": "6.0.1",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/diff.git",
"reference": "fbf413a49e54f6b9b17e12d900ac7f6101591b7f"
"reference": "ab83243ecc233de5655b76f577711de9f842e712"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/fbf413a49e54f6b9b17e12d900ac7f6101591b7f",
"reference": "fbf413a49e54f6b9b17e12d900ac7f6101591b7f",
"url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/ab83243ecc233de5655b76f577711de9f842e712",
"reference": "ab83243ecc233de5655b76f577711de9f842e712",
"shasum": ""
},
"require": {
"php": ">=8.1"
"php": ">=8.2"
},
"require-dev": {
"phpunit/phpunit": "^10.0",
"phpunit/phpunit": "^11.0",
"symfony/process": "^4.2 || ^5"
},
"type": "library",
"extra": {
"branch-alias": {
"dev-main": "5.1-dev"
"dev-main": "6.0-dev"
}
},
"autoload": {
@@ -524,7 +526,7 @@
"support": {
"issues": "https://github.com/sebastianbergmann/diff/issues",
"security": "https://github.com/sebastianbergmann/diff/security/policy",
"source": "https://github.com/sebastianbergmann/diff/tree/5.1.0"
"source": "https://github.com/sebastianbergmann/diff/tree/6.0.1"
},
"funding": [
{
@@ -532,20 +534,20 @@
"type": "github"
}
],
"time": "2023-12-22T10:55:06+00:00"
"time": "2024-03-02T07:30:33+00:00"
},
{
"name": "symfony/console",
"version": "v7.0.2",
"version": "v7.0.4",
"source": {
"type": "git",
"url": "https://github.com/symfony/console.git",
"reference": "f8587c4cdc5acad67af71c37db34ef03af91e59c"
"reference": "6b099f3306f7c9c2d2786ed736d0026b2903205f"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/console/zipball/f8587c4cdc5acad67af71c37db34ef03af91e59c",
"reference": "f8587c4cdc5acad67af71c37db34ef03af91e59c",
"url": "https://api.github.com/repos/symfony/console/zipball/6b099f3306f7c9c2d2786ed736d0026b2903205f",
"reference": "6b099f3306f7c9c2d2786ed736d0026b2903205f",
"shasum": ""
},
"require": {
@@ -609,7 +611,7 @@
"terminal"
],
"support": {
"source": "https://github.com/symfony/console/tree/v7.0.2"
"source": "https://github.com/symfony/console/tree/v7.0.4"
},
"funding": [
{
@@ -625,7 +627,7 @@
"type": "tidelift"
}
],
"time": "2023-12-10T16:54:46+00:00"
"time": "2024-02-22T20:27:20+00:00"
},
{
"name": "symfony/deprecation-contracts",
@@ -696,16 +698,16 @@
},
{
"name": "symfony/event-dispatcher",
"version": "v7.0.2",
"version": "v7.0.3",
"source": {
"type": "git",
"url": "https://github.com/symfony/event-dispatcher.git",
"reference": "098b62ae81fdd6cbf941f355059f617db28f4f9a"
"reference": "834c28d533dd0636f910909d01b9ff45cc094b5e"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/098b62ae81fdd6cbf941f355059f617db28f4f9a",
"reference": "098b62ae81fdd6cbf941f355059f617db28f4f9a",
"url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/834c28d533dd0636f910909d01b9ff45cc094b5e",
"reference": "834c28d533dd0636f910909d01b9ff45cc094b5e",
"shasum": ""
},
"require": {
@@ -756,7 +758,7 @@
"description": "Provides tools that allow your application components to communicate with each other by dispatching events and listening to them",
"homepage": "https://symfony.com",
"support": {
"source": "https://github.com/symfony/event-dispatcher/tree/v7.0.2"
"source": "https://github.com/symfony/event-dispatcher/tree/v7.0.3"
},
"funding": [
{
@@ -772,7 +774,7 @@
"type": "tidelift"
}
],
"time": "2023-12-27T22:24:19+00:00"
"time": "2024-01-23T15:02:46+00:00"
},
{
"name": "symfony/event-dispatcher-contracts",
@@ -852,16 +854,16 @@
},
{
"name": "symfony/filesystem",
"version": "v7.0.0",
"version": "v7.0.3",
"source": {
"type": "git",
"url": "https://github.com/symfony/filesystem.git",
"reference": "7da8ea2362a283771478c5f7729cfcb43a76b8b7"
"reference": "2890e3a825bc0c0558526c04499c13f83e1b6b12"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/filesystem/zipball/7da8ea2362a283771478c5f7729cfcb43a76b8b7",
"reference": "7da8ea2362a283771478c5f7729cfcb43a76b8b7",
"url": "https://api.github.com/repos/symfony/filesystem/zipball/2890e3a825bc0c0558526c04499c13f83e1b6b12",
"reference": "2890e3a825bc0c0558526c04499c13f83e1b6b12",
"shasum": ""
},
"require": {
@@ -895,7 +897,7 @@
"description": "Provides basic utilities for the filesystem",
"homepage": "https://symfony.com",
"support": {
"source": "https://github.com/symfony/filesystem/tree/v7.0.0"
"source": "https://github.com/symfony/filesystem/tree/v7.0.3"
},
"funding": [
{
@@ -911,7 +913,7 @@
"type": "tidelift"
}
],
"time": "2023-07-27T06:33:22+00:00"
"time": "2024-01-23T15:02:46+00:00"
},
{
"name": "symfony/finder",
@@ -1046,16 +1048,16 @@
},
{
"name": "symfony/polyfill-ctype",
"version": "v1.28.0",
"version": "v1.29.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/polyfill-ctype.git",
"reference": "ea208ce43cbb04af6867b4fdddb1bdbf84cc28cb"
"reference": "ef4d7e442ca910c4764bce785146269b30cb5fc4"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/ea208ce43cbb04af6867b4fdddb1bdbf84cc28cb",
"reference": "ea208ce43cbb04af6867b4fdddb1bdbf84cc28cb",
"url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/ef4d7e442ca910c4764bce785146269b30cb5fc4",
"reference": "ef4d7e442ca910c4764bce785146269b30cb5fc4",
"shasum": ""
},
"require": {
@@ -1069,9 +1071,6 @@
},
"type": "library",
"extra": {
"branch-alias": {
"dev-main": "1.28-dev"
},
"thanks": {
"name": "symfony/polyfill",
"url": "https://github.com/symfony/polyfill"
@@ -1108,7 +1107,7 @@
"portable"
],
"support": {
"source": "https://github.com/symfony/polyfill-ctype/tree/v1.28.0"
"source": "https://github.com/symfony/polyfill-ctype/tree/v1.29.0"
},
"funding": [
{
@@ -1124,20 +1123,20 @@
"type": "tidelift"
}
],
"time": "2023-01-26T09:26:14+00:00"
"time": "2024-01-29T20:11:03+00:00"
},
{
"name": "symfony/polyfill-intl-grapheme",
"version": "v1.28.0",
"version": "v1.29.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/polyfill-intl-grapheme.git",
"reference": "875e90aeea2777b6f135677f618529449334a612"
"reference": "32a9da87d7b3245e09ac426c83d334ae9f06f80f"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/875e90aeea2777b6f135677f618529449334a612",
"reference": "875e90aeea2777b6f135677f618529449334a612",
"url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/32a9da87d7b3245e09ac426c83d334ae9f06f80f",
"reference": "32a9da87d7b3245e09ac426c83d334ae9f06f80f",
"shasum": ""
},
"require": {
@@ -1148,9 +1147,6 @@
},
"type": "library",
"extra": {
"branch-alias": {
"dev-main": "1.28-dev"
},
"thanks": {
"name": "symfony/polyfill",
"url": "https://github.com/symfony/polyfill"
@@ -1189,7 +1185,7 @@
"shim"
],
"support": {
"source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.28.0"
"source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.29.0"
},
"funding": [
{
@@ -1205,20 +1201,20 @@
"type": "tidelift"
}
],
"time": "2023-01-26T09:26:14+00:00"
"time": "2024-01-29T20:11:03+00:00"
},
{
"name": "symfony/polyfill-intl-normalizer",
"version": "v1.28.0",
"version": "v1.29.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/polyfill-intl-normalizer.git",
"reference": "8c4ad05dd0120b6a53c1ca374dca2ad0a1c4ed92"
"reference": "bc45c394692b948b4d383a08d7753968bed9a83d"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/8c4ad05dd0120b6a53c1ca374dca2ad0a1c4ed92",
"reference": "8c4ad05dd0120b6a53c1ca374dca2ad0a1c4ed92",
"url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/bc45c394692b948b4d383a08d7753968bed9a83d",
"reference": "bc45c394692b948b4d383a08d7753968bed9a83d",
"shasum": ""
},
"require": {
@@ -1229,9 +1225,6 @@
},
"type": "library",
"extra": {
"branch-alias": {
"dev-main": "1.28-dev"
},
"thanks": {
"name": "symfony/polyfill",
"url": "https://github.com/symfony/polyfill"
@@ -1273,7 +1266,7 @@
"shim"
],
"support": {
"source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.28.0"
"source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.29.0"
},
"funding": [
{
@@ -1289,20 +1282,20 @@
"type": "tidelift"
}
],
"time": "2023-01-26T09:26:14+00:00"
"time": "2024-01-29T20:11:03+00:00"
},
{
"name": "symfony/polyfill-mbstring",
"version": "v1.28.0",
"version": "v1.29.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/polyfill-mbstring.git",
"reference": "42292d99c55abe617799667f454222c54c60e229"
"reference": "9773676c8a1bb1f8d4340a62efe641cf76eda7ec"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/42292d99c55abe617799667f454222c54c60e229",
"reference": "42292d99c55abe617799667f454222c54c60e229",
"url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/9773676c8a1bb1f8d4340a62efe641cf76eda7ec",
"reference": "9773676c8a1bb1f8d4340a62efe641cf76eda7ec",
"shasum": ""
},
"require": {
@@ -1316,9 +1309,6 @@
},
"type": "library",
"extra": {
"branch-alias": {
"dev-main": "1.28-dev"
},
"thanks": {
"name": "symfony/polyfill",
"url": "https://github.com/symfony/polyfill"
@@ -1356,7 +1346,7 @@
"shim"
],
"support": {
"source": "https://github.com/symfony/polyfill-mbstring/tree/v1.28.0"
"source": "https://github.com/symfony/polyfill-mbstring/tree/v1.29.0"
},
"funding": [
{
@@ -1372,20 +1362,20 @@
"type": "tidelift"
}
],
"time": "2023-07-28T09:04:16+00:00"
"time": "2024-01-29T20:11:03+00:00"
},
{
"name": "symfony/polyfill-php80",
"version": "v1.28.0",
"version": "v1.29.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/polyfill-php80.git",
"reference": "6caa57379c4aec19c0a12a38b59b26487dcfe4b5"
"reference": "87b68208d5c1188808dd7839ee1e6c8ec3b02f1b"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/6caa57379c4aec19c0a12a38b59b26487dcfe4b5",
"reference": "6caa57379c4aec19c0a12a38b59b26487dcfe4b5",
"url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/87b68208d5c1188808dd7839ee1e6c8ec3b02f1b",
"reference": "87b68208d5c1188808dd7839ee1e6c8ec3b02f1b",
"shasum": ""
},
"require": {
@@ -1393,9 +1383,6 @@
},
"type": "library",
"extra": {
"branch-alias": {
"dev-main": "1.28-dev"
},
"thanks": {
"name": "symfony/polyfill",
"url": "https://github.com/symfony/polyfill"
@@ -1439,7 +1426,7 @@
"shim"
],
"support": {
"source": "https://github.com/symfony/polyfill-php80/tree/v1.28.0"
"source": "https://github.com/symfony/polyfill-php80/tree/v1.29.0"
},
"funding": [
{
@@ -1455,20 +1442,20 @@
"type": "tidelift"
}
],
"time": "2023-01-26T09:26:14+00:00"
"time": "2024-01-29T20:11:03+00:00"
},
{
"name": "symfony/polyfill-php81",
"version": "v1.28.0",
"version": "v1.29.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/polyfill-php81.git",
"reference": "7581cd600fa9fd681b797d00b02f068e2f13263b"
"reference": "c565ad1e63f30e7477fc40738343c62b40bc672d"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-php81/zipball/7581cd600fa9fd681b797d00b02f068e2f13263b",
"reference": "7581cd600fa9fd681b797d00b02f068e2f13263b",
"url": "https://api.github.com/repos/symfony/polyfill-php81/zipball/c565ad1e63f30e7477fc40738343c62b40bc672d",
"reference": "c565ad1e63f30e7477fc40738343c62b40bc672d",
"shasum": ""
},
"require": {
@@ -1476,9 +1463,6 @@
},
"type": "library",
"extra": {
"branch-alias": {
"dev-main": "1.28-dev"
},
"thanks": {
"name": "symfony/polyfill",
"url": "https://github.com/symfony/polyfill"
@@ -1518,7 +1502,7 @@
"shim"
],
"support": {
"source": "https://github.com/symfony/polyfill-php81/tree/v1.28.0"
"source": "https://github.com/symfony/polyfill-php81/tree/v1.29.0"
},
"funding": [
{
@@ -1534,20 +1518,20 @@
"type": "tidelift"
}
],
"time": "2023-01-26T09:26:14+00:00"
"time": "2024-01-29T20:11:03+00:00"
},
{
"name": "symfony/process",
"version": "v7.0.2",
"version": "v7.0.4",
"source": {
"type": "git",
"url": "https://github.com/symfony/process.git",
"reference": "acd3eb5cb02382c1cb0287ba29b2908cc6ffa83a"
"reference": "0e7727191c3b71ebec6d529fa0e50a01ca5679e9"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/process/zipball/acd3eb5cb02382c1cb0287ba29b2908cc6ffa83a",
"reference": "acd3eb5cb02382c1cb0287ba29b2908cc6ffa83a",
"url": "https://api.github.com/repos/symfony/process/zipball/0e7727191c3b71ebec6d529fa0e50a01ca5679e9",
"reference": "0e7727191c3b71ebec6d529fa0e50a01ca5679e9",
"shasum": ""
},
"require": {
@@ -1579,7 +1563,7 @@
"description": "Executes commands in sub-processes",
"homepage": "https://symfony.com",
"support": {
"source": "https://github.com/symfony/process/tree/v7.0.2"
"source": "https://github.com/symfony/process/tree/v7.0.4"
},
"funding": [
{
@@ -1595,7 +1579,7 @@
"type": "tidelift"
}
],
"time": "2023-12-24T09:15:37+00:00"
"time": "2024-02-22T20:27:20+00:00"
},
{
"name": "symfony/service-contracts",
@@ -1681,16 +1665,16 @@
},
{
"name": "symfony/stopwatch",
"version": "v7.0.0",
"version": "v7.0.3",
"source": {
"type": "git",
"url": "https://github.com/symfony/stopwatch.git",
"reference": "7bbfa3dd564a0ce12eb4acaaa46823c740f9cb7a"
"reference": "983900d6fddf2b0cbaacacbbad07610854bd8112"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/stopwatch/zipball/7bbfa3dd564a0ce12eb4acaaa46823c740f9cb7a",
"reference": "7bbfa3dd564a0ce12eb4acaaa46823c740f9cb7a",
"url": "https://api.github.com/repos/symfony/stopwatch/zipball/983900d6fddf2b0cbaacacbbad07610854bd8112",
"reference": "983900d6fddf2b0cbaacacbbad07610854bd8112",
"shasum": ""
},
"require": {
@@ -1723,7 +1707,7 @@
"description": "Provides a way to profile code",
"homepage": "https://symfony.com",
"support": {
"source": "https://github.com/symfony/stopwatch/tree/v7.0.0"
"source": "https://github.com/symfony/stopwatch/tree/v7.0.3"
},
"funding": [
{
@@ -1739,20 +1723,20 @@
"type": "tidelift"
}
],
"time": "2023-07-05T13:06:06+00:00"
"time": "2024-01-23T15:02:46+00:00"
},
{
"name": "symfony/string",
"version": "v7.0.2",
"version": "v7.0.4",
"source": {
"type": "git",
"url": "https://github.com/symfony/string.git",
"reference": "cc78f14f91f5e53b42044d0620961c48028ff9f5"
"reference": "f5832521b998b0bec40bee688ad5de98d4cf111b"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/string/zipball/cc78f14f91f5e53b42044d0620961c48028ff9f5",
"reference": "cc78f14f91f5e53b42044d0620961c48028ff9f5",
"url": "https://api.github.com/repos/symfony/string/zipball/f5832521b998b0bec40bee688ad5de98d4cf111b",
"reference": "f5832521b998b0bec40bee688ad5de98d4cf111b",
"shasum": ""
},
"require": {
@@ -1809,7 +1793,7 @@
"utf8"
],
"support": {
"source": "https://github.com/symfony/string/tree/v7.0.2"
"source": "https://github.com/symfony/string/tree/v7.0.4"
},
"funding": [
{
@@ -1825,7 +1809,7 @@
"type": "tidelift"
}
],
"time": "2023-12-10T16:54:46+00:00"
"time": "2024-02-01T13:17:36+00:00"
}
],
"packages-dev": [],

View File

@@ -29,12 +29,12 @@ SCRIPT_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
# cp .ci/.env.ci .env
OUTPUT_FORMAT=txt
EXTRA_PARAMS="-v"
EXTRA_PARAMS=""
if [[ $GITHUB_ACTIONS = "true" ]]
then
OUTPUT_FORMAT=gitlab
EXTRA_PARAMS="--diff --dry-run"
OUTPUT_FORMAT=txt
EXTRA_PARAMS=""
fi
# clean up php code

View File

@@ -9,16 +9,16 @@
"packages-dev": [
{
"name": "composer/pcre",
"version": "3.1.1",
"version": "3.1.2",
"source": {
"type": "git",
"url": "https://github.com/composer/pcre.git",
"reference": "00104306927c7a0919b4ced2aaa6782c1e61a3c9"
"reference": "4775f35b2d70865807c89d32c8e7385b86eb0ace"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/composer/pcre/zipball/00104306927c7a0919b4ced2aaa6782c1e61a3c9",
"reference": "00104306927c7a0919b4ced2aaa6782c1e61a3c9",
"url": "https://api.github.com/repos/composer/pcre/zipball/4775f35b2d70865807c89d32c8e7385b86eb0ace",
"reference": "4775f35b2d70865807c89d32c8e7385b86eb0ace",
"shasum": ""
},
"require": {
@@ -60,7 +60,7 @@
],
"support": {
"issues": "https://github.com/composer/pcre/issues",
"source": "https://github.com/composer/pcre/tree/3.1.1"
"source": "https://github.com/composer/pcre/tree/3.1.2"
},
"funding": [
{
@@ -76,7 +76,7 @@
"type": "tidelift"
}
],
"time": "2023-10-11T07:11:09+00:00"
"time": "2024-03-07T15:38:35+00:00"
},
{
"name": "composer/xdebug-handler",
@@ -395,16 +395,16 @@
},
{
"name": "symfony/config",
"version": "v7.0.0",
"version": "v7.0.4",
"source": {
"type": "git",
"url": "https://github.com/symfony/config.git",
"reference": "8789646600f4e7e451dde9e1dc81cfa429f3857a"
"reference": "44deeba7233f08f383185ffa37dace3b3bc87364"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/config/zipball/8789646600f4e7e451dde9e1dc81cfa429f3857a",
"reference": "8789646600f4e7e451dde9e1dc81cfa429f3857a",
"url": "https://api.github.com/repos/symfony/config/zipball/44deeba7233f08f383185ffa37dace3b3bc87364",
"reference": "44deeba7233f08f383185ffa37dace3b3bc87364",
"shasum": ""
},
"require": {
@@ -450,7 +450,7 @@
"description": "Helps you find, load, combine, autofill and validate configuration values of any kind",
"homepage": "https://symfony.com",
"support": {
"source": "https://github.com/symfony/config/tree/v7.0.0"
"source": "https://github.com/symfony/config/tree/v7.0.4"
},
"funding": [
{
@@ -466,20 +466,20 @@
"type": "tidelift"
}
],
"time": "2023-11-09T08:30:23+00:00"
"time": "2024-02-26T07:52:39+00:00"
},
{
"name": "symfony/dependency-injection",
"version": "v7.0.2",
"version": "v7.0.4",
"source": {
"type": "git",
"url": "https://github.com/symfony/dependency-injection.git",
"reference": "bd25ef7c937b9da12510bdc4f1c66728f19620e3"
"reference": "47f37af245df8457ea63409fc242b3cc825ce5eb"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/dependency-injection/zipball/bd25ef7c937b9da12510bdc4f1c66728f19620e3",
"reference": "bd25ef7c937b9da12510bdc4f1c66728f19620e3",
"url": "https://api.github.com/repos/symfony/dependency-injection/zipball/47f37af245df8457ea63409fc242b3cc825ce5eb",
"reference": "47f37af245df8457ea63409fc242b3cc825ce5eb",
"shasum": ""
},
"require": {
@@ -530,7 +530,7 @@
"description": "Allows you to standardize and centralize the way objects are constructed in your application",
"homepage": "https://symfony.com",
"support": {
"source": "https://github.com/symfony/dependency-injection/tree/v7.0.2"
"source": "https://github.com/symfony/dependency-injection/tree/v7.0.4"
},
"funding": [
{
@@ -546,7 +546,7 @@
"type": "tidelift"
}
],
"time": "2023-12-28T19:18:20+00:00"
"time": "2024-02-22T20:27:20+00:00"
},
{
"name": "symfony/deprecation-contracts",
@@ -617,16 +617,16 @@
},
{
"name": "symfony/filesystem",
"version": "v7.0.0",
"version": "v7.0.3",
"source": {
"type": "git",
"url": "https://github.com/symfony/filesystem.git",
"reference": "7da8ea2362a283771478c5f7729cfcb43a76b8b7"
"reference": "2890e3a825bc0c0558526c04499c13f83e1b6b12"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/filesystem/zipball/7da8ea2362a283771478c5f7729cfcb43a76b8b7",
"reference": "7da8ea2362a283771478c5f7729cfcb43a76b8b7",
"url": "https://api.github.com/repos/symfony/filesystem/zipball/2890e3a825bc0c0558526c04499c13f83e1b6b12",
"reference": "2890e3a825bc0c0558526c04499c13f83e1b6b12",
"shasum": ""
},
"require": {
@@ -660,7 +660,7 @@
"description": "Provides basic utilities for the filesystem",
"homepage": "https://symfony.com",
"support": {
"source": "https://github.com/symfony/filesystem/tree/v7.0.0"
"source": "https://github.com/symfony/filesystem/tree/v7.0.3"
},
"funding": [
{
@@ -676,20 +676,20 @@
"type": "tidelift"
}
],
"time": "2023-07-27T06:33:22+00:00"
"time": "2024-01-23T15:02:46+00:00"
},
{
"name": "symfony/polyfill-ctype",
"version": "v1.28.0",
"version": "v1.29.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/polyfill-ctype.git",
"reference": "ea208ce43cbb04af6867b4fdddb1bdbf84cc28cb"
"reference": "ef4d7e442ca910c4764bce785146269b30cb5fc4"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/ea208ce43cbb04af6867b4fdddb1bdbf84cc28cb",
"reference": "ea208ce43cbb04af6867b4fdddb1bdbf84cc28cb",
"url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/ef4d7e442ca910c4764bce785146269b30cb5fc4",
"reference": "ef4d7e442ca910c4764bce785146269b30cb5fc4",
"shasum": ""
},
"require": {
@@ -703,9 +703,6 @@
},
"type": "library",
"extra": {
"branch-alias": {
"dev-main": "1.28-dev"
},
"thanks": {
"name": "symfony/polyfill",
"url": "https://github.com/symfony/polyfill"
@@ -742,7 +739,7 @@
"portable"
],
"support": {
"source": "https://github.com/symfony/polyfill-ctype/tree/v1.28.0"
"source": "https://github.com/symfony/polyfill-ctype/tree/v1.29.0"
},
"funding": [
{
@@ -758,20 +755,20 @@
"type": "tidelift"
}
],
"time": "2023-01-26T09:26:14+00:00"
"time": "2024-01-29T20:11:03+00:00"
},
{
"name": "symfony/polyfill-mbstring",
"version": "v1.28.0",
"version": "v1.29.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/polyfill-mbstring.git",
"reference": "42292d99c55abe617799667f454222c54c60e229"
"reference": "9773676c8a1bb1f8d4340a62efe641cf76eda7ec"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/42292d99c55abe617799667f454222c54c60e229",
"reference": "42292d99c55abe617799667f454222c54c60e229",
"url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/9773676c8a1bb1f8d4340a62efe641cf76eda7ec",
"reference": "9773676c8a1bb1f8d4340a62efe641cf76eda7ec",
"shasum": ""
},
"require": {
@@ -785,9 +782,6 @@
},
"type": "library",
"extra": {
"branch-alias": {
"dev-main": "1.28-dev"
},
"thanks": {
"name": "symfony/polyfill",
"url": "https://github.com/symfony/polyfill"
@@ -825,7 +819,7 @@
"shim"
],
"support": {
"source": "https://github.com/symfony/polyfill-mbstring/tree/v1.28.0"
"source": "https://github.com/symfony/polyfill-mbstring/tree/v1.29.0"
},
"funding": [
{
@@ -841,7 +835,7 @@
"type": "tidelift"
}
],
"time": "2023-07-28T09:04:16+00:00"
"time": "2024-01-29T20:11:03+00:00"
},
{
"name": "symfony/service-contracts",
@@ -927,16 +921,16 @@
},
{
"name": "symfony/var-exporter",
"version": "v7.0.2",
"version": "v7.0.4",
"source": {
"type": "git",
"url": "https://github.com/symfony/var-exporter.git",
"reference": "345c62fefe92243c3a06fc0cc65f2ec1a47e0764"
"reference": "dfb0acb6803eb714f05d97dd4c5abe6d5fa9fe41"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/var-exporter/zipball/345c62fefe92243c3a06fc0cc65f2ec1a47e0764",
"reference": "345c62fefe92243c3a06fc0cc65f2ec1a47e0764",
"url": "https://api.github.com/repos/symfony/var-exporter/zipball/dfb0acb6803eb714f05d97dd4c5abe6d5fa9fe41",
"reference": "dfb0acb6803eb714f05d97dd4c5abe6d5fa9fe41",
"shasum": ""
},
"require": {
@@ -981,7 +975,7 @@
"serialize"
],
"support": {
"source": "https://github.com/symfony/var-exporter/tree/v7.0.2"
"source": "https://github.com/symfony/var-exporter/tree/v7.0.4"
},
"funding": [
{
@@ -997,7 +991,7 @@
"type": "tidelift"
}
],
"time": "2023-12-27T08:42:13+00:00"
"time": "2024-02-26T10:35:24+00:00"
}
],
"aliases": [],

View File

@@ -1,6 +1,6 @@
# You can leave this on "local". If you change it to production most console commands will ask for extra confirmation.
# Never set it to "testing".
APP_ENV=local
APP_ENV=production
# Set to true if you want to see debug information in error screens.
APP_DEBUG=false
@@ -78,7 +78,7 @@ PAPERTRAIL_HOST=
PAPERTRAIL_PORT=
# Database credentials. Make sure the database exists. I recommend a dedicated user for Firefly III
# For other database types, please see the FAQ: https://docs.firefly-iii.org/firefly-iii/faq/self-hosted/#i-want-to-use-sqlite
# For other database types, please see the FAQ: https://docs.firefly-iii.org/references/faq/install/#i-want-to-use-sqlite
# If you use Docker or similar, you can set these variables from a file by appending them with _FILE
# Use "pgsql" for PostgreSQL
# Use "mysql" for MySQL and MariaDB.
@@ -111,7 +111,10 @@ PGSQL_SSL_CERT=null
PGSQL_SSL_KEY=null
PGSQL_SSL_CRL_FILE=null
# more PostgreSQL settings
# For postgresql 15 and up, setting this to public will no longer work as expected, becasuse the
# 'public' schema is without grants. This can be worked around by having a super user grant those
# necessary privileges, but in security conscious setups that's not viable.
# You will need to set this to the schema you want to use.
PGSQL_SCHEMA=public
# If you're looking for performance improvements, you could install memcached or redis
@@ -122,7 +125,7 @@ SESSION_DRIVER=file
# If you use Docker or similar, you can set REDIS_HOST_FILE, REDIS_PASSWORD_FILE or
# REDIS_PORT_FILE to set the value from a file instead of from an environment variable
# can be tcp, unix or http
# can be tcp or unix. http is not supported
REDIS_SCHEME=tcp
# use only when using 'unix' for REDIS_SCHEME. Leave empty otherwise.
@@ -150,7 +153,7 @@ COOKIE_SECURE=false
COOKIE_SAMESITE=lax
# If you want Firefly III to email you, update these settings
# For instructions, see: https://docs.firefly-iii.org/firefly-iii/advanced-installation/email/#email
# For instructions, see: https://docs.firefly-iii.org/how-to/firefly-iii/advanced/notifications/#email
# If you use Docker or similar, you can set these variables from a file by appending them with _FILE
MAIL_MAILER=log
MAIL_HOST=null
@@ -184,6 +187,11 @@ SEND_REPORT_JOURNALS=true
# Since this involves an external service, it's optional and disabled by default.
ENABLE_EXTERNAL_MAP=false
#
# Enable or disable exchange rate conversion. This function isn't used yet by Firefly III
#
ENABLE_EXCHANGE_RATES=false
# Set this value to true if you want Firefly III to download currency exchange rates
# from the internet. These rates are hosted by the creator of Firefly III inside
# an Azure Storage Container.
@@ -214,7 +222,7 @@ VALID_URL_PROTOCOLS=
# - 'web' (default, uses built in DB)
# - 'remote_user_guard' for Authelia etc
# Read more about these settings in the documentation.
# https://docs.firefly-iii.org/firefly-iii/advanced-installation/authentication
# https://docs.firefly-iii.org/how-to/firefly-iii/advanced/authentication/
#
# LDAP is no longer supported :(
#
@@ -269,7 +277,7 @@ ALLOW_WEBHOOKS=false
# 1. Set this token to any 32-character value (this is important!).
# 2. Use this token in the cron URL instead of a user's command line token that you can find in /profile
#
# For more info: https://docs.firefly-iii.org/firefly-iii/advanced-installation/cron/
# For more info: https://docs.firefly-iii.org/how-to/firefly-iii/advanced/cron/
#
# You can set this variable from a file by appending it with _FILE
#
@@ -324,18 +332,15 @@ PUSHER_SECRET=
PUSHER_ID=
DEMO_USERNAME=
DEMO_PASSWORD=
#
# The v2 layout is very experimental. If it breaks you get to keep both parts.
# Be wary of data loss.
#
FIREFLY_III_LAYOUT=v1
#
# If you have trouble configuring your Firefly III installation, DON'T BOTHER setting this variable.
# It won't work. It doesn't do ANYTHING. Don't believe the lies you read online. I'm not joking.
# This configuration value WILL NOT HELP.
#
# Notable exception to this rule is Synology, which, according to some users, will use APP_URL to rewrite stuff.
#
# This variable is ONLY used in some of the emails Firefly III sends around. Nowhere else.
# So when configuring anything WEB related this variable doesn't do anything. Nothing
#
# If you're stuck I understand you get desperate but look SOMEWHERE ELSE.
# Please make sure this URL matches the external URL of your Firefly III installation.
# It is used to validate specific requests and to generate URLs in emails.
#
APP_URL=http://localhost

2
.github/CODEOWNERS vendored Normal file
View File

@@ -0,0 +1,2 @@
# code owners for this Firefly III related repository
* @JC5 @SDx3

View File

@@ -1,11 +1,16 @@
version: 2
updates:
# Check for updates to GitHub Actions every week
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
# composer updates
- package-ecosystem: "composer"
directory: "/" # Location of package manifests
target-branch: develop
labels: [ "bug" ]
versioning-strategy: increase
schedule:
interval: "weekly"
@@ -14,15 +19,6 @@ updates:
- package-ecosystem: "npm"
directory: "/"
target-branch: develop
labels: [ "bug" ]
versioning-strategy: increase
schedule:
interval: "weekly"
- package-ecosystem: "github-actions"
directory: "/"
target-branch: develop
labels: [ "bug" ]
versioning-strategy: increase
schedule:
interval: "weekly"

4
.github/funding.yml vendored
View File

@@ -1,4 +1,6 @@
# These are supported funding model platforms
# Firefly III sponsor options
github: jc5
patreon: JC5
ko_fi: jamesc5
liberapay: JC5

View File

@@ -5,7 +5,9 @@ feature:
issues:
# Post a comment, `{issue-author}` is an optional placeholder
comment: |
Hi there! This is an automatic reply. `Share and enjoy`
Hi there!
This is an automatic reply. `Share and enjoy`
This issue has been marked as a feature request. The requested (new) feature will become a part of Firefly III or the data importer in due course.
@@ -13,11 +15,29 @@ feature:
Thank you for your contributions.
epic:
issues:
# Post a comment, `{issue-author}` is an optional placeholder
comment: |
Hi there!
This is an automatic reply. `Share and enjoy`
This issue has been marked as an epic. In epics, large amounts of works are collected that will be part of a major new feature. If you have more ideas that could be a part of this epic, feel free to reply.
*However*, please be aware there is NO need to reply with "+1" or "me too" or "I need this too" or whatever. Such comments are not helpful, and do not influence [the roadmap](https://roadmap.firefly-iii.org/). Your comment may be :skull: deleted.
If you are merely interested in this epic's progress, you can subscribe to this issue to get updates.
Thank you for your contributions.
enhancement:
issues:
# Post a comment, `{issue-author}` is an optional placeholder
comment: |
Hi there! This is an automatic reply. `Share and enjoy`
Hi there!
This is an automatic reply. `Share and enjoy`
This issue has been marked as an enhancement. The requested enhancement to an existing feature will become a part of Firefly III or the data importer in due course.
@@ -25,13 +45,67 @@ enhancement:
Thank you for your contributions.
# The `solved` label is added to discussions
triage:
issues:
# Post a comment, `{issue-author}` is an optional placeholder
comment: |
Hi there! This is an automatic reply. `Share and enjoy`
Hi there!
This is an automatic reply. `Share and enjoy`
This issue has been marked as being in triage. The root cause is not known yet, or the issue needs more investigation. You can help by sharing debug information (from `/debug`) if you also have this issue or when you haven't already done so.
Thank you for your contributions.
needs-moar-debug:
issues:
comment: |
Hi there!
This is an automatic reply. `Share and enjoy`
To learn more about this issue, please make sure you share at least:
1. The table you can find on the `/debug` page
2. Firefly III version
2. Docker, self-hosted, or hosted by a third party?
3. Operating system and browser
Thank you for your contributions.
unlabel: needs-moar-debug
needs-moar-logs:
issues:
comment: |
Hi there!
This is an automatic reply. `Share and enjoy`
To learn more about this issue, please share the relevant log files from your Firefly III or data importer installation.
The relevant instructions can be found in the documentation: [How to debug Firefly III?](https://docs.firefly-iii.org/how-to/general/debug/) Once debug mode is activated per these instructions, you can repeat your action and find the logs, depending on your method of installation. All is explained on the page.
Please share the relevant log lines in your issue, either inline or as an attachment. If you feel the logs contain sensitive information, you may also send them to [james@firefly-iii.org](mailto:james@firefly-iii.org). Without these logs, it may not be possible to properly investigate this issue.
Thank you for your contributions.
unlabel: needs-moar-logs
v2-layout-issue:
issues:
comment: |
Hi there!
This is an automatic reply. `Share and enjoy`
It seems your issue is about the new v2-layout that is currently in development for Firefly III.
These issues are collected in [a GitHub discussion](https://github.com/firefly-iii/firefly-iii/issues/8361).
Please note that the v2 layout is still very much in development.
Thank you for your contributions.
close: true
close-reason: completed
lock: false
unlabel: v2-layout-issue

View File

@@ -2,9 +2,12 @@
name: "Chore - Prune old builds"
permissions:
actions: write
on:
schedule:
- cron: '0 0 * * *'
- cron: '0 1 * * *'
workflow_dispatch:
jobs:
prune:
@@ -12,9 +15,9 @@ jobs:
timeout-minutes: 10
steps:
- name: Prune cancelled/skipped runs
uses: actions/github-script@v6
uses: actions/github-script@v7
with:
github-token: ${{ secrets.GH_ACTIONS_PERSONAL_ACCESS_TOKEN }}
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const cancelled = await github.rest.actions.listWorkflowRunsForRepo({
owner: context.repo.owner,
@@ -42,9 +45,9 @@ jobs:
}
- name: Prune runs older than 3 days
uses: actions/github-script@v6
uses: actions/github-script@v7
with:
github-token: ${{ secrets.GH_ACTIONS_PERSONAL_ACCESS_TOKEN }}
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const days_to_expiration = 3;
const ms_in_day = 86400000;
@@ -56,10 +59,13 @@ jobs:
const workflows = [
'cleanup.yml',
'close-duplicates.yml',
'closed-issues.yml',
'debug-info-actions.yml',
'depsreview.yml',
'label-actions.yml',
'lock.yml',
'release.yml',
'sonarcloud.yml',
'stale.yml'
]

39
.github/workflows/close-duplicates.yml vendored Normal file
View File

@@ -0,0 +1,39 @@
name: "Issues - Command to close duplicate issues"
# the workflow to execute on is comments that are newly created
on:
issue_comment:
types: [created]
permissions:
issues: write
checks: read
jobs:
close_duplicates:
runs-on: ubuntu-latest
steps:
- uses: github/command@v1.1.0
id: command
with:
allowed_contexts: "issue"
command: ".duplicate"
- name: reply
if: ${{ steps.command.outputs.continue == 'true' }}
run: |
ISSUE_TITLE=$(gh issue view ${{ steps.command.outputs.params }} --json title --jq '.title')
gh issue comment "$NUMBER" --body "Hi there!
This is an automatic reply. \`Share and enjoy\`.
Your issue is probably a duplicate of issue <span>#</span>${{ steps.command.outputs.params }}: [$ISSUE_TITLE](https://github.com/firefly-iii/firefly-iii/issues/${{ steps.command.outputs.params }}). Please refer to issue #${{ steps.command.outputs.params }} for support.
You can close this issue now. If you believe this is not in fact a duplicate, please reply and let us know. Otherwise, this issue will be automatically closed in a few days time.
Thank you for your contributions."
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_REPO: ${{ github.repository }}
NUMBER: ${{ github.event.issue.number }}

View File

@@ -23,6 +23,3 @@ jobs:
Thank you for your contributions.
repo-token: ${{ secrets.GITHUB_TOKEN }}
- uses: OSDKDev/lock-issues@v1.1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}

View File

@@ -0,0 +1,32 @@
name: 'Issues - Respond to hidden commands'
# the workflow to execute on is comments that are newly created
on:
issues:
types: [opened, edited]
issue_comment:
types: [created]
# permissions needed for reacting to IssueOps commands on issues and PRs
permissions:
contents: read
pull-requests: write
issues: write
checks: read
jobs:
respond:
runs-on: ubuntu-latest
steps:
- run: |
ISSUE_BODY=$(gh issue view $NUMBER --json body)
if [[ $ISSUE_BODY == *".eOxNZAmyGz6CXMyf"* ]]; then
gh issue comment "$NUMBER" --body "$V2_ISSUE_REPLY_BODY"
gh issue close "$NUMBER" --reason completed
fi
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_REPO: ${{ github.repository }}
NUMBER: ${{ github.event.issue.number }}
V2_ISSUE_REPLY_BODY: ${{ secrets.V2_ISSUE_REPLY_BODY }}
LABELS: v2-layout-issue

View File

@@ -9,8 +9,8 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: 'Checkout repository'
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: 'Dependency review'
uses: actions/dependency-review-action@v3
uses: actions/dependency-review-action@v4

View File

@@ -18,4 +18,4 @@ jobs:
action:
runs-on: ubuntu-latest
steps:
- uses: dessant/label-actions@v3
- uses: dessant/label-actions@v4

View File

@@ -3,17 +3,27 @@ name: 'Issues - Lock old issues'
on:
workflow_dispatch:
schedule:
- cron: '0 0 * * *'
- cron: '0 2 * * *'
concurrency:
group: lock-threads
permissions:
issues: write
pull-requests: write
discussions: write
jobs:
lock:
permissions:
issues: write
pull-requests: write
discussions: write
runs-on: ubuntu-latest
steps:
- uses: JC5/lock-threads@main
- uses: dessant/lock-threads@v5
with:
github-token: ${{ github.token }}
issue-inactive-days: 90
pr-inactive-days: 90
issue-inactive-days: 21
pr-inactive-days: 21
discussion-inactive-days: 21
log-output: true

231
.github/workflows/release.yml vendored Normal file
View File

@@ -0,0 +1,231 @@
name: 'Code - Create new release'
on:
workflow_dispatch:
inputs:
version:
description: 'Version to release'
required: true
default: 'develop'
schedule:
- cron: '0 3 * * MON,THU'
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Switch branch
run: |
if [[ "develop" == "$version" ]]; then
git checkout --track origin/develop
git pull
else
git config user.name github-actions
git config user.email 41898282+github-actions[bot]@users.noreply.github.com
git checkout --track origin/develop
git pull
git checkout main
git merge develop
fi
env:
version: ${{ github.event_name == 'schedule' && 'develop' || github.event.inputs.version }}
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.3'
extensions: mbstring, intl, zip, bcmath
- name: crowdin action
uses: crowdin/github-action@v1
with:
upload_sources: true
download_translations: true
push_translations: false
push_sources: false
env:
GITHUB_TOKEN: ${{ github.token }}
CROWDIN_PROJECT_NR: ${{ secrets.CROWDIN_PROJECT_NR }}
CROWDIN_TOKEN: ${{ secrets.CROWDIN_TOKEN }}
- name: Cleanup translations
id: cleanup-transactions
uses: JC5/firefly-iii-dev@v36
with:
action: 'ff3:crowdin-warning'
output: ''
env:
FIREFLY_III_ROOT: /github/workspace
GH_TOKEN: ''
- name: Cleanup changelog
id: cleanup-changelog
uses: JC5/firefly-iii-dev@v36
with:
action: 'ff3:changelog'
output: ''
env:
FIREFLY_III_ROOT: /github/workspace
GH_TOKEN: ${{ secrets.CHANGELOG_TOKEN }}
- name: Extract changelog
id: extract-changelog
uses: JC5/firefly-iii-dev@v36
with:
action: 'ff3:extract-changelog'
output: 'output'
env:
FIREFLY_III_ROOT: /github/workspace
GH_TOKEN: ""
- name: Replace version
id: replace-version
uses: JC5/firefly-iii-dev@v36
with:
action: 'ff3:version'
output: ''
env:
FIREFLY_III_ROOT: /github/workspace
GH_TOKEN: ""
FF_III_VERSION: ${{ github.event_name == 'schedule' && 'develop' || github.event.inputs.version }}
- name: Generate JSON v1
id: json-v1
uses: JC5/firefly-iii-dev@v36
with:
action: 'ff3:json-translations v1'
output: ''
env:
FIREFLY_III_ROOT: /github/workspace
GH_TOKEN: ''
- name: Generate JSON v2
id: json-v2
uses: JC5/firefly-iii-dev@v36
with:
action: 'ff3:json-translations v2'
output: ''
env:
FIREFLY_III_ROOT: /github/workspace
GH_TOKEN: ''
- name: Code cleanup
id: code-cleanup
uses: JC5/firefly-iii-dev@v36
with:
action: 'ff3:code'
output: ''
env:
FIREFLY_III_ROOT: /github/workspace
GH_TOKEN: ''
- name: Build new JS
run: |
npm install
npm update
npm run build
- name: Build old JS
id: old-js
uses: JC5/firefly-iii-dev@v36
with:
action: 'ff3:old-js'
output: ''
env:
FIREFLY_III_ROOT: /github/workspace
GH_TOKEN: ''
- name: Run CI
run: |
rm -rf vendor composer.lock
composer validate --strict
composer update --no-dev --no-scripts --no-plugins -q
sudo chown -R runner:docker resources/lang
.ci/phpcs.sh
- name: Release
run: |
sudo timedatectl set-timezone Europe/Amsterdam
git config user.name github-actions
git config user.email 41898282+github-actions[bot]@users.noreply.github.com
git config advice.addIgnoredFile false
# update composer (again)
composer validate --strict
composer update --no-dev --no-scripts --no-plugins
composer dump-autoload
releaseName=$version
zipName=FireflyIII-$version.zip
tarName=FireflyIII-$version.tar.gz
if [[ "develop" == "$version" ]]; then
[[ -z $(git status --untracked-files=normal --porcelain) ]] && echo "this branch is clean, no need to push..." && exit 0;
releaseName=$version-$(date +'%Y%m%d')
zipName=FireflyIII-develop.zip
tarName=FireflyIII-develop.tar.gz
fi
git add -A
if test -f "output.txt"; then
git reset output.txt
fi
git commit -m "Auto commit for release '$version' on $(date +'%Y-%m-%d')" || true
git push
# zip and tar everything
zip -rq $zipName . -x "*.git*" "*.ci*" "*.github*" "*node_modules*" "*output.txt*"
touch $tarName
tar --exclude=$tarName --exclude='./.git' --exclude='./.ci' --exclude='./.github' --exclude='./node_modules' --exclude='./output.txt' -czf $tarName .
# add sha256 sum
sha256sum -b $zipName > $zipName.sha256
sha256sum -b $tarName > $tarName.sha256
if [[ "develop" == "$version" ]]; then
# add text to output.txt (instructions)
rm output.txt
echo "Bi-weekly development release of Firefly III with the latest fixes, translations and features. Docker users can find this release under the \`develop\` tag." >> output.txt
echo "" >> output.txt
echo "This release was created on **$(date +'%Y-%m-%d')** and may contain unexpected bugs. Data loss is rare but is not impossible." >> output.txt
echo "" >> output.txt
echo "* Please read the installation instructions for [Docker](https://docs.firefly-iii.org/how-to/firefly-iii/installation/docker/), [Portainer](https://docs.firefly-iii.org/how-to/firefly-iii/installation/portainer/), [Kubernetes](https://docs.firefly-iii.org/how-to/firefly-iii/installation/kubernetes/) or [self-managed servers](https://docs.firefly-iii.org/how-to/firefly-iii/installation/self-managed/)" >> output.txt
echo "* Or read the upgrade instructions for [Docker](https://docs.firefly-iii.org/how-to/firefly-iii/upgrade/docker/), [Kubernetes](https://docs.firefly-iii.org/how-to/firefly-iii/upgrade/kubernetes/) or [self-managed servers](https://docs.firefly-iii.org/how-to/firefly-iii/upgrade/self-managed/)" >> output.txt
echo "" >> output.txt
echo ":warning: Please be careful with this pre-release, as is may not work as expected." >> output.txt
# create the release:
echo "Create nightly release."
git tag -a $releaseName -m "Nightly development release '$version' on $(date +'%Y-%m-%d')"
git push origin $releaseName
gh release create $releaseName -p --verify-tag \
-t "Development release for $(date +'%Y-%m-%d')" \
-F output.txt
# add zip file to release.
gh release upload $releaseName $zipName
gh release upload $releaseName $tarName
# add sha256 sum to release
gh release upload $releaseName $zipName.sha256
gh release upload $releaseName $tarName.sha256
# rm output.txt again
rm output.txt
else
# add text to output.txt (more instructions)
echo '' >> output.txt
echo '### Instructions' >> output.txt
echo '' >> output.txt
echo "* Installation instructions for [Docker](https://docs.firefly-iii.org/how-to/firefly-iii/installation/docker/), [Portainer](https://docs.firefly-iii.org/how-to/firefly-iii/installation/portainer/), [Kubernetes](https://docs.firefly-iii.org/how-to/firefly-iii/installation/kubernetes/) or [self-managed servers](https://docs.firefly-iii.org/how-to/firefly-iii/installation/self-managed/)" >> output.txt
echo "* Or read the upgrade instructions for [Docker](https://docs.firefly-iii.org/how-to/firefly-iii/upgrade/docker/), [Kubernetes](https://docs.firefly-iii.org/how-to/firefly-iii/upgrade/kubernetes/) or [self-managed servers](https://docs.firefly-iii.org/how-to/firefly-iii/upgrade/self-managed/)" >> output.txt
echo "Create default release."
git tag -a $releaseName -m "Here be changelog"
git push origin $releaseName
gh release create $releaseName -F output.txt -t "$releaseName" --verify-tag
# add zip file to release.
gh release upload $releaseName $zipName
# add sha256 sum to release
gh release upload $releaseName $zipName.sha256
rm output.txt
rm $zipName
rm $zipName.sha256
git checkout develop
git merge main
git push
fi
env:
GH_TOKEN: ${{ github.token }}
version: ${{ github.event_name == 'schedule' && 'develop' || github.event.inputs.version }}

View File

@@ -45,15 +45,6 @@ jobs:
- name: Install Composer dependencies
run: composer install --prefer-dist --no-interaction --no-progress --no-scripts
- name: PHPStan
run: .ci/phpstan.sh
- name: PHPMD
run: .ci/phpmd.sh
- name: PHP CS Fixer
run: .ci/phpcs.sh
- name: "Create database file"
run: touch storage/database/database.sqlite

View File

@@ -1,7 +1,7 @@
name: "Issues - Close stale issues"
name: "Issues - Mark and close stale issues"
on:
schedule:
- cron: "30 1 * * *"
- cron: "0 4 * * *"
workflow_dispatch:
permissions:
@@ -14,21 +14,25 @@ jobs:
pull-requests: write # for actions/stale to close stale PRs
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v6
- uses: actions/stale@v9
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
stale-issue-message: >
Hi there! This is an automatic reply. `Share and enjoy`
Hi there!
This is an automatic reply. `Share and enjoy`
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.
Thank you for your contributions.
stale-pr-message: >
Hi there! This is an automatic reply. `Share and enjoy`
Hi there!
This is an automatic reply. `Share and enjoy`
This PR has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.
Thank you for your contributions.
days-before-stale: 14
days-before-close: 7
exempt-issue-labels: 'enhancement,feature,bug,announcement,epic'
exempt-issue-labels: 'enhancement,feature,bug,announcement,epic,triage'

4
.gitignore vendored
View File

@@ -1,8 +1,12 @@
/node_modules
/storage/*.key
/vendor
public/hot
npm-debug.log
yarn-error.log
.env
/.ci/php-cs-fixer/vendor
coverage.xml
# ignore generated files.
public/build

View File

@@ -77,7 +77,7 @@ class AccountController extends Controller
$query = $data['query'];
$date = $data['date'] ?? today(config('app.timezone'));
$return = [];
$result = $this->repository->searchAccount((string) $query, $types, $this->parameters->get('limit'));
$result = $this->repository->searchAccount((string)$query, $types, $this->parameters->get('limit'));
// TODO this code is duplicated in the V2 Autocomplete controller, which means this code is due to be deprecated.
$defaultCurrency = app('amount')->getDefaultCurrency();
@@ -97,11 +97,11 @@ class AccountController extends Controller
}
$return[] = [
'id' => (string) $account->id,
'id' => (string)$account->id,
'name' => $account->name,
'name_with_balance' => $nameWithBalance,
'type' => $account->accountType->type,
'currency_id' => (string) $currency->id,
'currency_id' => (string)$currency->id,
'currency_name' => $currency->name,
'currency_code' => $currency->code,
'currency_symbol' => $currency->symbol,
@@ -114,8 +114,8 @@ class AccountController extends Controller
$return,
static function (array $left, array $right) {
$order = [AccountType::ASSET, AccountType::REVENUE, AccountType::EXPENSE];
$posA = (int) array_search($left['type'], $order, true);
$posB = (int) array_search($right['type'], $order, true);
$posA = (int)array_search($left['type'], $order, true);
$posB = (int)array_search($right['type'], $order, true);
return $posA - $posB;
}

View File

@@ -66,7 +66,7 @@ class BillController extends Controller
$filtered = $result->map(
static function (Bill $item) {
return [
'id' => (string) $item->id,
'id' => (string)$item->id,
'name' => $item->name,
'active' => $item->active,
];

View File

@@ -66,7 +66,7 @@ class BudgetController extends Controller
$filtered = $result->map(
static function (Budget $item) {
return [
'id' => (string) $item->id,
'id' => (string)$item->id,
'name' => $item->name,
];
}

View File

@@ -66,7 +66,7 @@ class CategoryController extends Controller
$filtered = $result->map(
static function (Category $item) {
return [
'id' => (string) $item->id,
'id' => (string)$item->id,
'name' => $item->name,
];
}

View File

@@ -68,7 +68,7 @@ class CurrencyController extends Controller
/** @var TransactionCurrency $currency */
foreach ($collection as $currency) {
$result[] = [
'id' => (string) $currency->id,
'id' => (string)$currency->id,
'name' => $currency->name,
'code' => $currency->code,
'symbol' => $currency->symbol,
@@ -94,7 +94,7 @@ class CurrencyController extends Controller
/** @var TransactionCurrency $currency */
foreach ($collection as $currency) {
$result[] = [
'id' => (string) $currency->id,
'id' => (string)$currency->id,
'name' => sprintf('%s (%s)', $currency->name, $currency->code),
'code' => $currency->code,
'symbol' => $currency->symbol,

View File

@@ -68,7 +68,7 @@ class ObjectGroupController extends Controller
/** @var ObjectGroup $objectGroup */
foreach ($result as $objectGroup) {
$return[] = [
'id' => (string) $objectGroup->id,
'id' => (string)$objectGroup->id,
'name' => $objectGroup->title,
'title' => $objectGroup->title,
];

View File

@@ -75,14 +75,14 @@ class PiggyBankController extends Controller
$currency = $this->accountRepository->getAccountCurrency($piggy->account) ?? $defaultCurrency;
$objectGroup = $piggy->objectGroups()->first();
$response[] = [
'id' => (string) $piggy->id,
'id' => (string)$piggy->id,
'name' => $piggy->name,
'currency_id' => (string) $currency->id,
'currency_id' => (string)$currency->id,
'currency_name' => $currency->name,
'currency_code' => $currency->code,
'currency_symbol' => $currency->symbol,
'currency_decimal_places' => $currency->decimal_places,
'object_group_id' => null === $objectGroup ? null : (string) $objectGroup->id,
'object_group_id' => null === $objectGroup ? null : (string)$objectGroup->id,
'object_group_title' => $objectGroup?->title,
];
}
@@ -107,7 +107,7 @@ class PiggyBankController extends Controller
$currentAmount = $this->piggyRepository->getRepetition($piggy)->currentamount ?? '0';
$objectGroup = $piggy->objectGroups()->first();
$response[] = [
'id' => (string) $piggy->id,
'id' => (string)$piggy->id,
'name' => $piggy->name,
'name_with_balance' => sprintf(
'%s (%s / %s)',
@@ -115,12 +115,12 @@ class PiggyBankController extends Controller
app('amount')->formatAnything($currency, $currentAmount, false),
app('amount')->formatAnything($currency, $piggy->targetamount, false),
),
'currency_id' => (string) $currency->id,
'currency_id' => (string)$currency->id,
'currency_name' => $currency->name,
'currency_code' => $currency->code,
'currency_symbol' => $currency->symbol,
'currency_decimal_places' => $currency->decimal_places,
'object_group_id' => null === $objectGroup ? null : (string) $objectGroup->id,
'object_group_id' => null === $objectGroup ? null : (string)$objectGroup->id,
'object_group_title' => $objectGroup?->title,
];
}

View File

@@ -66,7 +66,7 @@ class RecurrenceController extends Controller
/** @var Recurrence $recurrence */
foreach ($recurrences as $recurrence) {
$response[] = [
'id' => (string) $recurrence->id,
'id' => (string)$recurrence->id,
'name' => $recurrence->title,
'description' => $recurrence->description,
];

View File

@@ -65,7 +65,7 @@ class RuleController extends Controller
/** @var Rule $rule */
foreach ($rules as $rule) {
$response[] = [
'id' => (string) $rule->id,
'id' => (string)$rule->id,
'name' => $rule->title,
'description' => $rule->description,
];

View File

@@ -65,7 +65,7 @@ class RuleGroupController extends Controller
/** @var RuleGroup $group */
foreach ($groups as $group) {
$response[] = [
'id' => (string) $group->id,
'id' => (string)$group->id,
'name' => $group->title,
'description' => $group->description,
];

View File

@@ -68,7 +68,7 @@ class TagController extends Controller
/** @var Tag $tag */
foreach ($result as $tag) {
$array[] = [
'id' => (string) $tag->id,
'id' => (string)$tag->id,
'name' => $tag->tag,
'tag' => $tag->tag,
];

View File

@@ -76,8 +76,8 @@ class TransactionController extends Controller
/** @var TransactionJournal $journal */
foreach ($filtered as $journal) {
$array[] = [
'id' => (string) $journal->id,
'transaction_group_id' => (string) $journal->transaction_group_id,
'id' => (string)$journal->id,
'transaction_group_id' => (string)$journal->transaction_group_id,
'name' => $journal->description,
'description' => $journal->description,
];
@@ -96,7 +96,7 @@ class TransactionController extends Controller
$result = new Collection();
if (is_numeric($data['query'])) {
// search for group, not journal.
$firstResult = $this->groupRepository->find((int) $data['query']);
$firstResult = $this->groupRepository->find((int)$data['query']);
if (null !== $firstResult) {
// group may contain multiple journals, each a result:
foreach ($firstResult->transactionJournals as $journal) {
@@ -114,8 +114,8 @@ class TransactionController extends Controller
/** @var TransactionJournal $journal */
foreach ($result as $journal) {
$array[] = [
'id' => (string) $journal->id,
'transaction_group_id' => (string) $journal->transaction_group_id,
'id' => (string)$journal->id,
'transaction_group_id' => (string)$journal->transaction_group_id,
'name' => sprintf('#%d: %s', $journal->transaction_group_id, $journal->description),
'description' => sprintf('#%d: %s', $journal->transaction_group_id, $journal->description),
];

View File

@@ -65,7 +65,7 @@ class TransactionTypeController extends Controller
foreach ($types as $type) {
// different key for consistency.
$array[] = [
'id' => (string) $type->id,
'id' => (string)$type->id,
'name' => $type->type,
'type' => $type->type,
];

View File

@@ -104,7 +104,7 @@ class AccountController extends Controller
}
$currentSet = [
'label' => $account->name,
'currency_id' => (string) $currency->id,
'currency_id' => (string)$currency->id,
'currency_code' => $currency->code,
'currency_symbol' => $currency->symbol,
'currency_decimal_places' => $currency->decimal_places,

View File

@@ -76,38 +76,6 @@ abstract class Controller extends BaseController
);
}
/**
* Method to help build URL's.
*/
final protected function buildParams(): string
{
$return = '?';
$params = [];
foreach ($this->parameters as $key => $value) {
if ('page' === $key) {
continue;
}
if ($value instanceof Carbon) {
$params[$key] = $value->format('Y-m-d');
continue;
}
$params[$key] = $value;
}
return $return.http_build_query($params);
}
final protected function getManager(): Manager
{
// create some objects:
$manager = new Manager();
$baseUrl = request()->getSchemeAndHttpHost().'/api/v1';
$manager->setSerializer(new JsonApiSerializer($baseUrl));
return $manager;
}
/**
* Method to grab all parameters from the URL.
*/
@@ -216,4 +184,36 @@ abstract class Controller extends BaseController
return $bag;
}
/**
* Method to help build URL's.
*/
final protected function buildParams(): string
{
$return = '?';
$params = [];
foreach ($this->parameters as $key => $value) {
if ('page' === $key) {
continue;
}
if ($value instanceof Carbon) {
$params[$key] = $value->format('Y-m-d');
continue;
}
$params[$key] = $value;
}
return $return.http_build_query($params);
}
final protected function getManager(): Manager
{
// create some objects:
$manager = new Manager();
$baseUrl = request()->getSchemeAndHttpHost().'/api/v1';
$manager->setSerializer(new JsonApiSerializer($baseUrl));
return $manager;
}
}

View File

@@ -70,8 +70,8 @@ class TransactionController extends Controller
// to respond to what is in the $query.
// this is OK because only one thing can be in the query at the moment.
if ($this->isUpdateTransactionAccount($params)) {
$original = $this->repository->find((int) $params['where']['account_id']);
$destination = $this->repository->find((int) $params['update']['account_id']);
$original = $this->repository->find((int)$params['where']['account_id']);
$destination = $this->repository->find((int)$params['update']['account_id']);
/** @var AccountDestroyService $service */
$service = app(AccountDestroyService::class);

View File

@@ -45,6 +45,7 @@ use FireflyIII\Repositories\Tag\TagRepositoryInterface;
use FireflyIII\Services\Internal\Destroy\AccountDestroyService;
use FireflyIII\Services\Internal\Destroy\JournalDestroyService;
use Illuminate\Http\JsonResponse;
use Illuminate\Support\Facades\Log;
/**
* Class DestroyController
@@ -67,7 +68,7 @@ class DestroyController extends Controller
$allExceptAssets = [AccountType::BENEFICIARY, AccountType::CASH, AccountType::CREDITCARD, AccountType::DEFAULT, AccountType::EXPENSE, AccountType::IMPORT, AccountType::INITIAL_BALANCE, AccountType::LIABILITY_CREDIT, AccountType::RECONCILIATION, AccountType::REVENUE];
$all = [AccountType::ASSET, AccountType::BENEFICIARY, AccountType::CASH, AccountType::CREDITCARD, AccountType::DEBT, AccountType::DEFAULT, AccountType::EXPENSE, AccountType::IMPORT, AccountType::INITIAL_BALANCE, AccountType::LIABILITY_CREDIT, AccountType::LOAN, AccountType::MORTGAGE, AccountType::RECONCILIATION];
$liabilities = [AccountType::DEBT, AccountType::LOAN, AccountType::MORTGAGE, AccountType::CREDITCARD];
$transactions = [TransactionType::WITHDRAWAL, TransactionType::DEPOSIT, TransactionType::TRANSFER, TransactionType::RECONCILIATION, TransactionType::OPENING_BALANCE];
$transactions = [TransactionType::WITHDRAWAL, TransactionType::DEPOSIT, TransactionType::TRANSFER, TransactionType::RECONCILIATION];
match ($objects) {
'budgets' => $this->destroyBudgets(),
@@ -175,12 +176,14 @@ class DestroyController extends Controller
$count = $account->transactions()->count();
if (true === $this->unused && 0 === $count) {
app('log')->info(sprintf('Deleted unused account #%d "%s"', $account->id, $account->name));
Log::channel('audit')->info(sprintf('Deleted unused account #%d "%s"', $account->id, $account->name));
$service->destroy($account, null);
continue;
}
if (false === $this->unused) {
app('log')->info(sprintf('Deleting account #%d "%s"', $account->id, $account->name));
Log::channel('audit')->warning(sprintf('Deleted account #%d "%s"', $account->id, $account->name));
$service->destroy($account, null);
}
}

View File

@@ -68,6 +68,32 @@ class ExportController extends Controller
return $this->returnExport('accounts');
}
/**
* @throws FireflyException
*/
private function returnExport(string $key): LaravelResponse
{
$date = date('Y-m-d-H-i-s');
$fileName = sprintf('%s-export-%s.csv', $date, $key);
$data = $this->exporter->export();
/** @var LaravelResponse $response */
$response = response($data[$key]);
$response
->header('Content-Description', 'File Transfer')
->header('Content-Type', 'application/octet-stream')
->header('Content-Disposition', 'attachment; filename='.$fileName)
->header('Content-Transfer-Encoding', 'binary')
->header('Connection', 'Keep-Alive')
->header('Expires', '0')
->header('Cache-Control', 'must-revalidate, post-check=0, pre-check=0')
->header('Pragma', 'public')
->header('Content-Length', (string)strlen($data[$key]))
;
return $response;
}
/**
* This endpoint is documented at:
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/data/exportBills
@@ -189,30 +215,4 @@ class ExportController extends Controller
return $this->returnExport('transactions');
}
/**
* @throws FireflyException
*/
private function returnExport(string $key): LaravelResponse
{
$date = date('Y-m-d-H-i-s');
$fileName = sprintf('%s-export-%s.csv', $date, $key);
$data = $this->exporter->export();
/** @var LaravelResponse $response */
$response = response($data[$key]);
$response
->header('Content-Description', 'File Transfer')
->header('Content-Type', 'application/octet-stream')
->header('Content-Disposition', 'attachment; filename='.$fileName)
->header('Content-Transfer-Encoding', 'binary')
->header('Connection', 'Keep-Alive')
->header('Expires', '0')
->header('Cache-Control', 'must-revalidate, post-check=0, pre-check=0')
->header('Pragma', 'public')
->header('Content-Length', (string) strlen($data[$key]))
;
return $response;
}
}

View File

@@ -75,28 +75,28 @@ class TagController extends Controller
$genericSet = $collector->getExtractedJournals();
foreach ($genericSet as $journal) {
$currencyId = (int) $journal['currency_id'];
$foreignCurrencyId = (int) $journal['foreign_currency_id'];
$currencyId = (int)$journal['currency_id'];
$foreignCurrencyId = (int)$journal['foreign_currency_id'];
if (0 !== $currencyId) {
$response[$currencyId] ??= [
'difference' => '0',
'difference_float' => 0,
'currency_id' => (string) $currencyId,
'currency_id' => (string)$currencyId,
'currency_code' => $journal['currency_code'],
];
$response[$currencyId]['difference'] = bcadd($response[$currencyId]['difference'], $journal['amount']);
$response[$currencyId]['difference_float'] = (float) $response[$currencyId]['difference']; // float but on purpose.
$response[$currencyId]['difference_float'] = (float)$response[$currencyId]['difference']; // float but on purpose.
}
if (0 !== $foreignCurrencyId) {
$response[$foreignCurrencyId] ??= [
'difference' => '0',
'difference_float' => 0,
'currency_id' => (string) $foreignCurrencyId,
'currency_id' => (string)$foreignCurrencyId,
'currency_code' => $journal['foreign_currency_code'],
];
$response[$foreignCurrencyId]['difference'] = bcadd($response[$foreignCurrencyId]['difference'], $journal['foreign_amount']);
$response[$foreignCurrencyId]['difference_float'] = (float) $response[$foreignCurrencyId]['difference']; // float but on purpose.
$response[$foreignCurrencyId]['difference_float'] = (float)$response[$foreignCurrencyId]['difference']; // float but on purpose.
}
}
@@ -130,8 +130,8 @@ class TagController extends Controller
/** @var array $journal */
foreach ($genericSet as $journal) {
$currencyId = (int) $journal['currency_id'];
$foreignCurrencyId = (int) $journal['foreign_currency_id'];
$currencyId = (int)$journal['currency_id'];
$foreignCurrencyId = (int)$journal['foreign_currency_id'];
/** @var array $tag */
foreach ($journal['tags'] as $tag) {
@@ -142,15 +142,15 @@ class TagController extends Controller
// on currency ID
if (0 !== $currencyId) {
$response[$key] ??= [
'id' => (string) $tagId,
'id' => (string)$tagId,
'name' => $tag['name'],
'difference' => '0',
'difference_float' => 0,
'currency_id' => (string) $currencyId,
'currency_id' => (string)$currencyId,
'currency_code' => $journal['currency_code'],
];
$response[$key]['difference'] = bcadd($response[$key]['difference'], $journal['amount']);
$response[$key]['difference_float'] = (float) $response[$key]['difference']; // float but on purpose.
$response[$key]['difference_float'] = (float)$response[$key]['difference']; // float but on purpose.
}
// on foreign ID
@@ -158,11 +158,11 @@ class TagController extends Controller
$response[$foreignKey] = $journal[$foreignKey] ?? [
'difference' => '0',
'difference_float' => 0,
'currency_id' => (string) $foreignCurrencyId,
'currency_id' => (string)$foreignCurrencyId,
'currency_code' => $journal['foreign_currency_code'],
];
$response[$foreignKey]['difference'] = bcadd($response[$foreignKey]['difference'], $journal['foreign_amount']);
$response[$foreignKey]['difference_float'] = (float) $response[$foreignKey]['difference']; // float but on purpose.
$response[$foreignKey]['difference_float'] = (float)$response[$foreignKey]['difference']; // float but on purpose.
}
}
}

View File

@@ -66,8 +66,8 @@ class DestroyController extends Controller
*/
public function destroy(Attachment $attachment): JsonResponse
{
if(true === auth()->user()->hasRole('demo')) {
Log::channel('audit')->info(sprintf('Demo user tries to access attachment API in %s', __METHOD__));
if (true === auth()->user()->hasRole('demo')) {
Log::channel('audit')->warning(sprintf('Demo user tries to access attachment API in %s', __METHOD__));
throw new NotFoundHttpException();
}

View File

@@ -75,8 +75,8 @@ class ShowController extends Controller
*/
public function download(Attachment $attachment): LaravelResponse
{
if(true === auth()->user()->hasRole('demo')) {
Log::channel('audit')->info(sprintf('Demo user tries to access attachment API in %s', __METHOD__));
if (true === auth()->user()->hasRole('demo')) {
Log::channel('audit')->warning(sprintf('Demo user tries to access attachment API in %s', __METHOD__));
throw new NotFoundHttpException();
}
@@ -123,8 +123,8 @@ class ShowController extends Controller
*/
public function index(): JsonResponse
{
if(true === auth()->user()->hasRole('demo')) {
Log::channel('audit')->info(sprintf('Demo user tries to access attachment API in %s', __METHOD__));
if (true === auth()->user()->hasRole('demo')) {
Log::channel('audit')->warning(sprintf('Demo user tries to access attachment API in %s', __METHOD__));
throw new NotFoundHttpException();
}
@@ -161,8 +161,8 @@ class ShowController extends Controller
*/
public function show(Attachment $attachment): JsonResponse
{
if(true === auth()->user()->hasRole('demo')) {
Log::channel('audit')->info(sprintf('Demo user tries to access attachment API in %s', __METHOD__));
if (true === auth()->user()->hasRole('demo')) {
Log::channel('audit')->warning(sprintf('Demo user tries to access attachment API in %s', __METHOD__));
throw new NotFoundHttpException();
}

View File

@@ -74,8 +74,8 @@ class StoreController extends Controller
*/
public function store(StoreRequest $request): JsonResponse
{
if(true === auth()->user()->hasRole('demo')) {
Log::channel('audit')->info(sprintf('Demo user tries to access attachment API in %s', __METHOD__));
if (true === auth()->user()->hasRole('demo')) {
Log::channel('audit')->warning(sprintf('Demo user tries to access attachment API in %s', __METHOD__));
throw new NotFoundHttpException();
}
@@ -98,8 +98,8 @@ class StoreController extends Controller
*/
public function upload(Request $request, Attachment $attachment): JsonResponse
{
if(true === auth()->user()->hasRole('demo')) {
Log::channel('audit')->info(sprintf('Demo user tries to access attachment API in %s', __METHOD__));
if (true === auth()->user()->hasRole('demo')) {
Log::channel('audit')->warning(sprintf('Demo user tries to access attachment API in %s', __METHOD__));
throw new NotFoundHttpException();
}

View File

@@ -69,8 +69,8 @@ class UpdateController extends Controller
*/
public function update(UpdateRequest $request, Attachment $attachment): JsonResponse
{
if(true === auth()->user()->hasRole('demo')) {
Log::channel('audit')->info(sprintf('Demo user tries to access attachment API in %s', __METHOD__));
if (true === auth()->user()->hasRole('demo')) {
Log::channel('audit')->warning(sprintf('Demo user tries to access attachment API in %s', __METHOD__));
throw new NotFoundHttpException();
}

View File

@@ -0,0 +1,47 @@
<?php
/*
* ExpressionController.php
* Copyright (c) 2024 Michael Thomas
*
* This file is part of Firefly III (https://github.com/firefly-iii).
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
declare(strict_types=1);
namespace FireflyIII\Api\V1\Controllers\Models\Rule;
use FireflyIII\Api\V1\Controllers\Controller;
use FireflyIII\Api\V1\Requests\Models\Rule\ValidateExpressionRequest;
use Illuminate\Http\JsonResponse;
/**
* Class ExpressionController
*/
class ExpressionController extends Controller
{
/**
* This endpoint is documented at:
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/rules/validateExpression
*
* @SuppressWarnings(PHPMD.UnusedFormalParameter)
*/
public function validateExpression(ValidateExpressionRequest $request): JsonResponse
{
return response()->json([
'valid' => true,
]);
}
}

View File

@@ -147,7 +147,7 @@ class TriggerController extends Controller
// add a range:
$ruleEngine->addOperator(['type' => 'date_before', 'value' => $parameters['end']->format('Y-m-d')]);
}
if (array_key_exists('accounts', $parameters) && '' !== $parameters['accounts']) {
if (array_key_exists('accounts', $parameters) && is_array($parameters['accounts']) && count($parameters['accounts']) > 0) {
$ruleEngine->addOperator(['type' => 'account_id', 'value' => implode(',', $parameters['accounts'])]);
}

View File

@@ -118,23 +118,6 @@ class BasicController extends Controller
return response()->json($return);
}
/**
* Check if date is outside session range.
*/
protected function notInDateRange(Carbon $date, Carbon $start, Carbon $end): bool // Validate a preference
{
$result = false;
if ($start->greaterThanOrEqualTo($date) && $end->greaterThanOrEqualTo($date)) {
$result = true;
}
// start and end in the past? use $end
if ($start->lessThanOrEqualTo($date) && $end->lessThanOrEqualTo($date)) {
$result = true;
}
return $result;
}
private function getBalanceInformation(Carbon $start, Carbon $end): array
{
// prep some arrays:
@@ -152,7 +135,7 @@ class BasicController extends Controller
/** @var array $transactionJournal */
foreach ($set as $transactionJournal) {
$currencyId = (int) $transactionJournal['currency_id'];
$currencyId = (int)$transactionJournal['currency_id'];
$incomes[$currencyId] ??= '0';
$incomes[$currencyId] = bcadd(
$incomes[$currencyId],
@@ -170,7 +153,7 @@ class BasicController extends Controller
/** @var array $transactionJournal */
foreach ($set as $transactionJournal) {
$currencyId = (int) $transactionJournal['currency_id'];
$currencyId = (int)$transactionJournal['currency_id'];
$expenses[$currencyId] ??= '0';
$expenses[$currencyId] = bcadd($expenses[$currencyId], $transactionJournal['amount']);
$sums[$currencyId] ??= '0';
@@ -189,7 +172,7 @@ class BasicController extends Controller
'key' => sprintf('balance-in-%s', $currency->code),
'title' => trans('firefly.box_balance_in_currency', ['currency' => $currency->symbol]),
'monetary_value' => $sums[$currencyId] ?? '0',
'currency_id' => (string) $currency->id,
'currency_id' => (string)$currency->id,
'currency_code' => $currency->code,
'currency_symbol' => $currency->symbol,
'currency_decimal_places' => $currency->decimal_places,
@@ -202,7 +185,7 @@ class BasicController extends Controller
'key' => sprintf('spent-in-%s', $currency->code),
'title' => trans('firefly.box_spent_in_currency', ['currency' => $currency->symbol]),
'monetary_value' => $expenses[$currencyId] ?? '0',
'currency_id' => (string) $currency->id,
'currency_id' => (string)$currency->id,
'currency_code' => $currency->code,
'currency_symbol' => $currency->symbol,
'currency_decimal_places' => $currency->decimal_places,
@@ -214,7 +197,7 @@ class BasicController extends Controller
'key' => sprintf('earned-in-%s', $currency->code),
'title' => trans('firefly.box_earned_in_currency', ['currency' => $currency->symbol]),
'monetary_value' => $incomes[$currencyId] ?? '0',
'currency_id' => (string) $currency->id,
'currency_id' => (string)$currency->id,
'currency_code' => $currency->code,
'currency_symbol' => $currency->symbol,
'currency_decimal_places' => $currency->decimal_places,
@@ -248,7 +231,7 @@ class BasicController extends Controller
'key' => sprintf('bills-paid-in-%s', $info['code']),
'title' => trans('firefly.box_bill_paid_in_currency', ['currency' => $info['symbol']]),
'monetary_value' => $amount,
'currency_id' => (string) $info['id'],
'currency_id' => (string)$info['id'],
'currency_code' => $info['code'],
'currency_symbol' => $info['symbol'],
'currency_decimal_places' => $info['decimal_places'],
@@ -267,7 +250,7 @@ class BasicController extends Controller
'key' => sprintf('bills-unpaid-in-%s', $info['code']),
'title' => trans('firefly.box_bill_unpaid_in_currency', ['currency' => $info['symbol']]),
'monetary_value' => $amount,
'currency_id' => (string) $info['id'],
'currency_id' => (string)$info['id'],
'currency_code' => $info['code'],
'currency_symbol' => $info['symbol'],
'currency_decimal_places' => $info['decimal_places'],
@@ -294,21 +277,21 @@ class BasicController extends Controller
foreach ($spent as $row) {
// either an amount was budgeted or 0 is available.
$amount = (string) ($available[$row['currency_id']] ?? '0');
$amount = (string)($available[$row['currency_id']] ?? '0');
$spentInCurrency = $row['sum'];
$leftToSpend = bcadd($amount, $spentInCurrency);
$days = $today->diffInDays($end) + 1;
$days = (int)$today->diffInDays($end, true) + 1;
$perDay = '0';
if (0 !== $days && bccomp($leftToSpend, '0') > -1) {
$perDay = bcdiv($leftToSpend, (string) $days);
$perDay = bcdiv($leftToSpend, (string)$days);
}
$return[] = [
'key' => sprintf('left-to-spend-in-%s', $row['currency_code']),
'title' => trans('firefly.box_left_to_spend_in_currency', ['currency' => $row['currency_symbol']]),
'monetary_value' => $leftToSpend,
'currency_id' => (string) $row['currency_id'],
'currency_id' => (string)$row['currency_id'],
'currency_code' => $row['currency_code'],
'currency_symbol' => $row['currency_symbol'],
'currency_decimal_places' => $row['currency_decimal_places'],
@@ -368,7 +351,7 @@ class BasicController extends Controller
'key' => sprintf('net-worth-in-%s', $data['currency_code']),
'title' => trans('firefly.box_net_worth_in_currency', ['currency' => $data['currency_symbol']]),
'monetary_value' => $amount,
'currency_id' => (string) $data['currency_id'],
'currency_id' => (string)$data['currency_id'],
'currency_code' => $data['currency_code'],
'currency_symbol' => $data['currency_symbol'],
'currency_decimal_places' => $data['currency_decimal_places'],
@@ -380,4 +363,21 @@ class BasicController extends Controller
return $return;
}
/**
* Check if date is outside session range.
*/
protected function notInDateRange(Carbon $date, Carbon $start, Carbon $end): bool // Validate a preference
{
$result = false;
if ($start->greaterThanOrEqualTo($date) && $end->greaterThanOrEqualTo($date)) {
$result = true;
}
// start and end in the past? use $end
if ($start->lessThanOrEqualTo($date) && $end->lessThanOrEqualTo($date)) {
$result = true;
}
return $result;
}
}

View File

@@ -88,6 +88,35 @@ class ConfigurationController extends Controller
return response()->json($return);
}
/**
* Get all config values.
*/
private function getDynamicConfiguration(): array
{
$isDemoSite = app('fireflyconfig')->get('is_demo_site');
$updateCheck = app('fireflyconfig')->get('permission_update_check');
$lastCheck = app('fireflyconfig')->get('last_update_check');
$singleUser = app('fireflyconfig')->get('single_user_mode');
return [
'is_demo_site' => $isDemoSite?->data,
'permission_update_check' => null === $updateCheck ? null : (int)$updateCheck->data,
'last_update_check' => null === $lastCheck ? null : (int)$lastCheck->data,
'single_user_mode' => $singleUser?->data,
];
}
private function getStaticConfiguration(): array
{
$list = EitherConfigKey::$static;
$return = [];
foreach ($list as $key) {
$return[$key] = config($key);
}
return $return;
}
/**
* This endpoint is documented at:
* https://api-docs.firefly-iii.org/?urls.primaryName=2.0.0%20(v1)#/configuration/getSingleConfiguration
@@ -145,33 +174,4 @@ class ConfigurationController extends Controller
return response()->json(['data' => $data])->header('Content-Type', self::CONTENT_TYPE);
}
/**
* Get all config values.
*/
private function getDynamicConfiguration(): array
{
$isDemoSite = app('fireflyconfig')->get('is_demo_site');
$updateCheck = app('fireflyconfig')->get('permission_update_check');
$lastCheck = app('fireflyconfig')->get('last_update_check');
$singleUser = app('fireflyconfig')->get('single_user_mode');
return [
'is_demo_site' => $isDemoSite?->data,
'permission_update_check' => null === $updateCheck ? null : (int)$updateCheck->data,
'last_update_check' => null === $lastCheck ? null : (int)$lastCheck->data,
'single_user_mode' => $singleUser?->data,
];
}
private function getStaticConfiguration(): array
{
$list = EitherConfigKey::$static;
$return = [];
foreach ($list as $key) {
$return[$key] = config($key);
}
return $return;
}
}

View File

@@ -70,8 +70,8 @@ class AttemptController extends Controller
if ($message->webhook_id !== $webhook->id) {
throw new FireflyException('200040: Webhook and webhook message are no match');
}
if(false === config('firefly.allow_webhooks')) {
Log::channel('audit')->info(sprintf('User lists webhook attempts of webhook #%d and message #%d, but webhooks are DISABLED.', $webhook->id, $message->id));
if (false === config('firefly.allow_webhooks')) {
Log::channel('audit')->warning(sprintf('User lists webhook attempts of webhook #%d and message #%d, but webhooks are DISABLED.', $webhook->id, $message->id));
throw new NotFoundHttpException('Webhooks are not enabled.');
}
@@ -114,8 +114,8 @@ class AttemptController extends Controller
throw new FireflyException('200041: Webhook message and webhook attempt are no match');
}
if(false === config('firefly.allow_webhooks')) {
Log::channel('audit')->info(sprintf('User views single webhook attempt #%d of webhook #%d and message #%d, but webhooks are DISABLED', $attempt->id, $webhook->id, $message->id));
if (false === config('firefly.allow_webhooks')) {
Log::channel('audit')->warning(sprintf('User views single webhook attempt #%d of webhook #%d and message #%d, but webhooks are DISABLED', $attempt->id, $webhook->id, $message->id));
throw new NotFoundHttpException('Webhooks are not enabled.');
}

View File

@@ -62,8 +62,8 @@ class DestroyController extends Controller
*/
public function destroy(Webhook $webhook): JsonResponse
{
if(false === config('firefly.allow_webhooks')) {
Log::channel('audit')->info(sprintf('User tries to destroy webhook #%d. but webhooks are DISABLED.', $webhook->id));
if (false === config('firefly.allow_webhooks')) {
Log::channel('audit')->warning(sprintf('User tries to destroy webhook #%d. but webhooks are DISABLED.', $webhook->id));
throw new NotFoundHttpException('Webhooks are not enabled.');
}
@@ -93,7 +93,7 @@ class DestroyController extends Controller
}
if (false === config('firefly.allow_webhooks')) {
Log::channel('audit')->info(sprintf('User tries to destroy webhook #%d, message #%d, attempt #%d, but webhooks are DISABLED.', $webhook->id, $message->id, $attempt->id));
Log::channel('audit')->warning(sprintf('User tries to destroy webhook #%d, message #%d, attempt #%d, but webhooks are DISABLED.', $webhook->id, $message->id, $attempt->id));
throw new NotFoundHttpException('Webhooks are not enabled.');
}
@@ -120,8 +120,8 @@ class DestroyController extends Controller
throw new FireflyException('200040: Webhook and webhook message are no match');
}
if(false === config('firefly.allow_webhooks')) {
Log::channel('audit')->info(sprintf('User tries to destroy webhook #%d, message #%d, but webhooks are DISABLED.', $webhook->id, $message->id));
if (false === config('firefly.allow_webhooks')) {
Log::channel('audit')->warning(sprintf('User tries to destroy webhook #%d, message #%d, but webhooks are DISABLED.', $webhook->id, $message->id));
throw new NotFoundHttpException('Webhooks are not enabled.');
}

View File

@@ -66,8 +66,8 @@ class MessageController extends Controller
*/
public function index(Webhook $webhook): JsonResponse
{
if(false === config('firefly.allow_webhooks')) {
Log::channel('audit')->info(sprintf('User tries to view messages of webhook #%d, but webhooks are DISABLED.', $webhook->id));
if (false === config('firefly.allow_webhooks')) {
Log::channel('audit')->warning(sprintf('User tries to view messages of webhook #%d, but webhooks are DISABLED.', $webhook->id));
throw new NotFoundHttpException('Webhooks are not enabled.');
}
@@ -106,8 +106,8 @@ class MessageController extends Controller
if ($message->webhook_id !== $webhook->id) {
throw new FireflyException('200040: Webhook and webhook message are no match');
}
if(false === config('firefly.allow_webhooks')) {
Log::channel('audit')->info(sprintf('User tries to view message #%d of webhook #%d, but webhooks are DISABLED.', $message->id, $webhook->id));
if (false === config('firefly.allow_webhooks')) {
Log::channel('audit')->warning(sprintf('User tries to view message #%d of webhook #%d, but webhooks are DISABLED.', $message->id, $webhook->id));
throw new NotFoundHttpException('Webhooks are not enabled.');
}

View File

@@ -71,7 +71,7 @@ class ShowController extends Controller
*/
public function index(): JsonResponse
{
if(false === config('firefly.allow_webhooks')) {
if (false === config('firefly.allow_webhooks')) {
Log::channel('audit')->info('User tries to view all webhooks, but webhooks are DISABLED.');
throw new NotFoundHttpException('Webhooks are not enabled.');
@@ -106,7 +106,7 @@ class ShowController extends Controller
*/
public function show(Webhook $webhook): JsonResponse
{
if(false === config('firefly.allow_webhooks')) {
if (false === config('firefly.allow_webhooks')) {
Log::channel('audit')->info(sprintf('User tries to view webhook #%d, but webhooks are DISABLED.', $webhook->id));
throw new NotFoundHttpException('Webhooks are not enabled.');
@@ -131,7 +131,7 @@ class ShowController extends Controller
*/
public function triggerTransaction(Webhook $webhook, TransactionGroup $group): JsonResponse
{
if(false === config('firefly.allow_webhooks')) {
if (false === config('firefly.allow_webhooks')) {
Log::channel('audit')->info(sprintf('User tries to trigger webhook #%d on transaction group #%d, but webhooks are DISABLED.', $webhook->id, $group->id));
throw new NotFoundHttpException('Webhooks are not enabled.');

View File

@@ -60,7 +60,7 @@ class StoreController extends Controller
public function store(CreateRequest $request): JsonResponse
{
$data = $request->getData();
if(false === config('firefly.allow_webhooks')) {
if (false === config('firefly.allow_webhooks')) {
Log::channel('audit')->info('User tries to store new webhook, but webhooks are DISABLED.', $data);
throw new NotFoundHttpException('Webhooks are not enabled.');

View File

@@ -57,7 +57,7 @@ class SubmitController extends Controller
*/
public function submit(Webhook $webhook): JsonResponse
{
if(false === config('firefly.allow_webhooks')) {
if (false === config('firefly.allow_webhooks')) {
Log::channel('audit')->info(sprintf('User tries to submit webhook #%d, but webhooks are DISABLED.', $webhook->id));
throw new NotFoundHttpException('Webhooks are not enabled.');

View File

@@ -60,7 +60,7 @@ class UpdateController extends Controller
public function update(Webhook $webhook, UpdateRequest $request): JsonResponse
{
$data = $request->getData();
if(false === config('firefly.allow_webhooks')) {
if (false === config('firefly.allow_webhooks')) {
Log::channel('audit')->info(sprintf('User tries to update webhook #%d, but webhooks are DISABLED.', $webhook->id), $data);
throw new NotFoundHttpException('Webhooks are not enabled.');

View File

@@ -28,6 +28,7 @@ use FireflyIII\Repositories\Account\AccountRepositoryInterface;
use FireflyIII\Support\Request\ChecksLogin;
use FireflyIII\Support\Request\ConvertsDataTypes;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Support\Facades\Log;
use Illuminate\Validation\Validator;
/**
@@ -59,9 +60,7 @@ class MoveTransactionsRequest extends FormRequest
/**
* Configure the validator instance with special rules for after the basic validation rules.
*
* @param validator $validator
* TODO this is duplicate
* TODO this is duplicate.
*/
public function withValidator(Validator $validator): void
{
@@ -74,6 +73,9 @@ class MoveTransactionsRequest extends FormRequest
}
}
);
if ($validator->fails()) {
Log::channel('audit')->error(sprintf('Validation errors in %s', __CLASS__), $validator->errors()->toArray());
}
}
private function validateMove(Validator $validator): void

View File

@@ -30,6 +30,7 @@ use FireflyIII\Support\Request\ChecksLogin;
use FireflyIII\Support\Request\ConvertsDataTypes;
use FireflyIII\Validation\Api\Data\Bulk\ValidatesBulkTransactionQuery;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Support\Facades\Log;
use Illuminate\Validation\Validator;
/**
@@ -72,5 +73,8 @@ class TransactionRequest extends FormRequest
$this->validateTransactionQuery($validator);
}
);
if ($validator->fails()) {
Log::channel('audit')->error(sprintf('Validation errors in %s', __CLASS__), $validator->errors()->toArray());
}
}
}

View File

@@ -46,7 +46,7 @@ class DateRequest extends FormRequest
{
$start = $this->getCarbonDate('start');
$end = $this->getCarbonDate('end');
if($start->diffInYears($end) > 5) {
if ($start->diffInYears($end, true) > 5) {
throw new FireflyException('Date range out of range.');
}

View File

@@ -71,7 +71,7 @@ class ExportRequest extends FormRequest
{
return [
'type' => 'in:csv',
'accounts' => 'min:1|max:65536',
'accounts' => 'min:1|max:32768',
'start' => 'date|before:end',
'end' => 'date|after:start',
];

View File

@@ -78,6 +78,25 @@ class GenericRequest extends FormRequest
return $return;
}
private function parseAccounts(): void
{
if (0 !== $this->accounts->count()) {
return;
}
$repository = app(AccountRepositoryInterface::class);
$repository->setUser(auth()->user());
$array = $this->get('accounts');
if (is_array($array)) {
foreach ($array as $accountId) {
$accountId = (int)$accountId;
$account = $repository->find($accountId);
if (null !== $account) {
$this->accounts->push($account);
}
}
}
}
public function getBills(): Collection
{
$this->parseBills();
@@ -85,6 +104,25 @@ class GenericRequest extends FormRequest
return $this->bills;
}
private function parseBills(): void
{
if (0 !== $this->bills->count()) {
return;
}
$repository = app(BillRepositoryInterface::class);
$repository->setUser(auth()->user());
$array = $this->get('bills');
if (is_array($array)) {
foreach ($array as $billId) {
$billId = (int)$billId;
$bill = $repository->find($billId);
if (null !== $bill) {
$this->bills->push($bill);
}
}
}
}
public function getBudgets(): Collection
{
$this->parseBudgets();
@@ -92,6 +130,25 @@ class GenericRequest extends FormRequest
return $this->budgets;
}
private function parseBudgets(): void
{
if (0 !== $this->budgets->count()) {
return;
}
$repository = app(BudgetRepositoryInterface::class);
$repository->setUser(auth()->user());
$array = $this->get('budgets');
if (is_array($array)) {
foreach ($array as $budgetId) {
$budgetId = (int)$budgetId;
$budget = $repository->find($budgetId);
if (null !== $budget) {
$this->budgets->push($budget);
}
}
}
}
public function getCategories(): Collection
{
$this->parseCategories();
@@ -99,6 +156,25 @@ class GenericRequest extends FormRequest
return $this->categories;
}
private function parseCategories(): void
{
if (0 !== $this->categories->count()) {
return;
}
$repository = app(CategoryRepositoryInterface::class);
$repository->setUser(auth()->user());
$array = $this->get('categories');
if (is_array($array)) {
foreach ($array as $categoryId) {
$categoryId = (int)$categoryId;
$category = $repository->find($categoryId);
if (null !== $category) {
$this->categories->push($category);
}
}
}
}
public function getEnd(): Carbon
{
$date = $this->getCarbonDate('end');
@@ -154,100 +230,6 @@ class GenericRequest extends FormRequest
return $this->tags;
}
/**
* The rules that the incoming request must be matched against.
*/
public function rules(): array
{
// this is cheating, but it works to initialize the collections.
$this->accounts = new Collection();
$this->budgets = new Collection();
$this->categories = new Collection();
$this->bills = new Collection();
$this->tags = new Collection();
return [
'start' => 'required|date',
'end' => 'required|date|after_or_equal:start',
];
}
private function parseAccounts(): void
{
if (0 !== $this->accounts->count()) {
return;
}
$repository = app(AccountRepositoryInterface::class);
$repository->setUser(auth()->user());
$array = $this->get('accounts');
if (is_array($array)) {
foreach ($array as $accountId) {
$accountId = (int)$accountId;
$account = $repository->find($accountId);
if (null !== $account) {
$this->accounts->push($account);
}
}
}
}
private function parseBills(): void
{
if (0 !== $this->bills->count()) {
return;
}
$repository = app(BillRepositoryInterface::class);
$repository->setUser(auth()->user());
$array = $this->get('bills');
if (is_array($array)) {
foreach ($array as $billId) {
$billId = (int)$billId;
$bill = $repository->find($billId);
if (null !== $bill) {
$this->bills->push($bill);
}
}
}
}
private function parseBudgets(): void
{
if (0 !== $this->budgets->count()) {
return;
}
$repository = app(BudgetRepositoryInterface::class);
$repository->setUser(auth()->user());
$array = $this->get('budgets');
if (is_array($array)) {
foreach ($array as $budgetId) {
$budgetId = (int)$budgetId;
$budget = $repository->find($budgetId);
if (null !== $budget) {
$this->budgets->push($budget);
}
}
}
}
private function parseCategories(): void
{
if (0 !== $this->categories->count()) {
return;
}
$repository = app(CategoryRepositoryInterface::class);
$repository->setUser(auth()->user());
$array = $this->get('categories');
if (is_array($array)) {
foreach ($array as $categoryId) {
$categoryId = (int)$categoryId;
$category = $repository->find($categoryId);
if (null !== $category) {
$this->categories->push($category);
}
}
}
}
private function parseTags(): void
{
if (0 !== $this->tags->count()) {
@@ -266,4 +248,22 @@ class GenericRequest extends FormRequest
}
}
}
/**
* The rules that the incoming request must be matched against.
*/
public function rules(): array
{
// this is cheating, but it works to initialize the collections.
$this->accounts = new Collection();
$this->budgets = new Collection();
$this->categories = new Collection();
$this->bills = new Collection();
$this->tags = new Collection();
return [
'start' => 'required|date',
'end' => 'required|date|after_or_equal:start',
];
}
}

View File

@@ -101,7 +101,7 @@ class StoreRequest extends FormRequest
'type' => 'required|max:1024|min:1|'.sprintf('in:%s', $types),
'iban' => ['iban', 'nullable', new UniqueIban(null, $type)],
'bic' => 'bic|nullable',
'account_number' => ['between:1,255', 'nullable', new UniqueAccountNumber(null, $type)],
'account_number' => ['min:1', 'max:255', 'nullable', new UniqueAccountNumber(null, $type)],
'opening_balance' => 'numeric|required_with:opening_balance_date|nullable',
'opening_balance_date' => 'date|required_with:opening_balance|nullable',
'virtual_balance' => 'numeric|nullable',
@@ -117,9 +117,9 @@ class StoreRequest extends FormRequest
'liability_amount' => ['required_with:liability_start_date', new IsValidPositiveAmount()],
'liability_start_date' => 'required_with:liability_amount|date',
'liability_direction' => 'nullable|required_if:type,liability|required_if:type,liabilities|in:credit,debit',
'interest' => 'between:0,100|numeric',
'interest' => 'min:0|max:100|numeric',
'interest_period' => sprintf('nullable|in:%s', implode(',', config('firefly.interest_periods'))),
'notes' => 'min:0|max:65536',
'notes' => 'min:0|max:32768',
];
return Location::requestRules($rules);

View File

@@ -91,7 +91,7 @@ class UpdateRequest extends FormRequest
'type' => sprintf('in:%s', $types),
'iban' => ['iban', 'nullable', new UniqueIban($account, $this->convertString('type'))],
'bic' => 'bic|nullable',
'account_number' => ['between:1,255', 'nullable', new UniqueAccountNumber($account, $this->convertString('type'))],
'account_number' => ['min:1', 'max:255', 'nullable', new UniqueAccountNumber($account, $this->convertString('type'))],
'opening_balance' => 'numeric|required_with:opening_balance_date|nullable',
'opening_balance_date' => 'date|required_with:opening_balance|nullable',
'virtual_balance' => 'numeric|nullable',
@@ -105,9 +105,9 @@ class UpdateRequest extends FormRequest
'monthly_payment_date' => 'date|nullable|required_if:account_role,ccAsset|required_if:credit_card_type,monthlyFull',
'liability_type' => 'required_if:type,liability|in:loan,debt,mortgage',
'liability_direction' => 'required_if:type,liability|in:credit,debit',
'interest' => 'required_if:type,liability|between:0,100|numeric',
'interest' => 'required_if:type,liability|min:0|max:100|numeric',
'interest_period' => 'required_if:type,liability|in:daily,monthly,yearly',
'notes' => 'min:0|max:65536',
'notes' => 'min:0|max:32768',
];
return Location::requestRules($rules);

View File

@@ -66,9 +66,9 @@ class StoreRequest extends FormRequest
$model = $this->convertString('attachable_type');
return [
'filename' => 'required|between:1,255',
'title' => 'between:1,255',
'notes' => 'between:1,65000',
'filename' => 'required|min:1|max:255',
'title' => ['min:1', 'max:255'],
'notes' => 'min:1|max:32768',
'attachable_type' => sprintf('required|in:%s', $models),
'attachable_id' => ['required', 'numeric', new IsValidAttachmentModel($model)],
];

View File

@@ -68,9 +68,9 @@ class UpdateRequest extends FormRequest
$model = $this->convertString('attachable_type');
return [
'filename' => 'between:1,255',
'title' => 'between:1,255',
'notes' => 'between:1,65000',
'filename' => ['min:1', 'max:255'],
'title' => ['min:1', 'max:255'],
'notes' => 'min:1|max:32768',
'attachable_type' => sprintf('in:%s', $models),
'attachable_id' => ['numeric', new IsValidAttachmentModel($model)],
];

View File

@@ -28,6 +28,7 @@ use FireflyIII\Rules\IsValidPositiveAmount;
use FireflyIII\Support\Request\ChecksLogin;
use FireflyIII\Support\Request\ConvertsDataTypes;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Support\Facades\Log;
use Illuminate\Validation\Validator;
/**
@@ -87,5 +88,8 @@ class Request extends FormRequest
}
}
);
if ($validator->fails()) {
Log::channel('audit')->error(sprintf('Validation errors in %s', __CLASS__), $validator->errors()->toArray());
}
}
}

View File

@@ -29,6 +29,7 @@ use FireflyIII\Rules\IsValidPositiveAmount;
use FireflyIII\Support\Request\ChecksLogin;
use FireflyIII\Support\Request\ConvertsDataTypes;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Support\Facades\Log;
use Illuminate\Validation\Validator;
/**
@@ -72,7 +73,7 @@ class StoreRequest extends FormRequest
public function rules(): array
{
return [
'name' => 'between:1,255|uniqueObjectForUser:bills,name',
'name' => 'min:1|max:255|uniqueObjectForUser:bills,name',
'amount_min' => ['required', new IsValidPositiveAmount()],
'amount_max' => ['required', new IsValidPositiveAmount()],
'currency_id' => 'numeric|exists:transaction_currencies,id',
@@ -81,9 +82,9 @@ class StoreRequest extends FormRequest
'end_date' => 'date|after:date',
'extension_date' => 'date|after:date',
'repeat_freq' => 'in:weekly,monthly,quarterly,half-year,yearly|required',
'skip' => 'between:0,31',
'skip' => 'min:0|max:31|numeric',
'active' => [new IsBoolean()],
'notes' => 'between:1,65536',
'notes' => 'min:1|max:32768',
];
}
@@ -103,5 +104,8 @@ class StoreRequest extends FormRequest
}
}
);
if ($validator->fails()) {
Log::channel('audit')->error(sprintf('Validation errors in %s', __CLASS__), $validator->errors()->toArray());
}
}
}

View File

@@ -30,6 +30,7 @@ use FireflyIII\Rules\IsValidPositiveAmount;
use FireflyIII\Support\Request\ChecksLogin;
use FireflyIII\Support\Request\ConvertsDataTypes;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Support\Facades\Log;
use Illuminate\Validation\Validator;
/**
@@ -75,7 +76,7 @@ class UpdateRequest extends FormRequest
$bill = $this->route()->parameter('bill');
return [
'name' => sprintf('between:1,255|uniqueObjectForUser:bills,name,%d', $bill->id),
'name' => sprintf('min:1|max:255|uniqueObjectForUser:bills,name,%d', $bill->id),
'amount_min' => ['nullable', new IsValidPositiveAmount()],
'amount_max' => ['nullable', new IsValidPositiveAmount()],
'currency_id' => 'numeric|exists:transaction_currencies,id',
@@ -84,9 +85,9 @@ class UpdateRequest extends FormRequest
'end_date' => 'date|after:date',
'extension_date' => 'date|after:date',
'repeat_freq' => 'in:weekly,monthly,quarterly,half-year,yearly',
'skip' => 'between:0,31',
'skip' => 'min:0|max:31|numeric',
'active' => [new IsBoolean()],
'notes' => 'between:1,65536',
'notes' => 'min:1|max:32768',
];
}
@@ -108,5 +109,8 @@ class UpdateRequest extends FormRequest
}
}
);
if ($validator->fails()) {
Log::channel('audit')->error(sprintf('Validation errors in %s', __CLASS__), $validator->errors()->toArray());
}
}
}

View File

@@ -29,6 +29,7 @@ use FireflyIII\Support\Request\ChecksLogin;
use FireflyIII\Support\Request\ConvertsDataTypes;
use FireflyIII\Validation\AutoBudget\ValidatesAutoBudgetRequest;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Support\Facades\Log;
use Illuminate\Validation\Validator;
/**
@@ -68,11 +69,11 @@ class StoreRequest extends FormRequest
public function rules(): array
{
return [
'name' => 'required|between:1,100|uniqueObjectForUser:budgets,name',
'name' => 'required|min:1|max:255|uniqueObjectForUser:budgets,name',
'active' => [new IsBoolean()],
'currency_id' => 'exists:transaction_currencies,id',
'currency_code' => 'exists:transaction_currencies,code',
'notes' => 'nullable|between:1,65536',
'notes' => 'nullable|min:1|max:32768',
// auto budget info
'auto_budget_type' => 'in:reset,rollover,adjusted,none',
'auto_budget_amount' => ['required_if:auto_budget_type,reset', 'required_if:auto_budget_type,rollover', 'required_if:auto_budget_type,adjusted', new IsValidPositiveAmount()],
@@ -91,5 +92,8 @@ class StoreRequest extends FormRequest
$this->validateAutoBudgetAmount($validator);
}
);
if ($validator->fails()) {
Log::channel('audit')->error(sprintf('Validation errors in %s', __CLASS__), $validator->errors()->toArray());
}
}
}

View File

@@ -30,6 +30,7 @@ use FireflyIII\Support\Request\ChecksLogin;
use FireflyIII\Support\Request\ConvertsDataTypes;
use FireflyIII\Validation\AutoBudget\ValidatesAutoBudgetRequest;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Support\Facades\Log;
use Illuminate\Validation\Validator;
/**
@@ -81,9 +82,9 @@ class UpdateRequest extends FormRequest
$budget = $this->route()->parameter('budget');
return [
'name' => sprintf('between:1,100|uniqueObjectForUser:budgets,name,%d', $budget->id),
'name' => sprintf('min:1|max:100|uniqueObjectForUser:budgets,name,%d', $budget->id),
'active' => [new IsBoolean()],
'notes' => 'nullable|between:1,65536',
'notes' => 'nullable|min:1|max:32768',
'auto_budget_type' => 'in:reset,rollover,adjusted,none',
'auto_budget_currency_id' => 'exists:transaction_currencies,id',
'auto_budget_currency_code' => 'exists:transaction_currencies,code',
@@ -103,5 +104,8 @@ class UpdateRequest extends FormRequest
$this->validateAutoBudgetAmount($validator);
}
);
if ($validator->fails()) {
Log::channel('audit')->error(sprintf('Validation errors in %s', __CLASS__), $validator->errors()->toArray());
}
}
}

View File

@@ -28,6 +28,7 @@ use FireflyIII\Rules\IsValidPositiveAmount;
use FireflyIII\Support\Request\ChecksLogin;
use FireflyIII\Support\Request\ConvertsDataTypes;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Support\Facades\Log;
use Illuminate\Validation\Validator;
/**
@@ -70,9 +71,7 @@ class UpdateRequest extends FormRequest
/**
* Configure the validator instance with special rules for after the basic validation rules.
*
* @param Validator $validator
* TODO duplicate code
* TODO duplicate code.
*/
public function withValidator(Validator $validator): void
{
@@ -89,5 +88,8 @@ class UpdateRequest extends FormRequest
}
}
);
if ($validator->fails()) {
Log::channel('audit')->error(sprintf('Validation errors in %s', __CLASS__), $validator->errors()->toArray());
}
}
}

View File

@@ -52,7 +52,7 @@ class StoreRequest extends FormRequest
public function rules(): array
{
return [
'name' => 'required|between:1,100|uniqueObjectForUser:categories,name',
'name' => 'required|min:1|max:100|uniqueObjectForUser:categories,name',
];
}
}

View File

@@ -58,7 +58,7 @@ class UpdateRequest extends FormRequest
$category = $this->route()->parameter('category');
return [
'name' => sprintf('between:1,100|uniqueObjectForUser:categories,name,%d', $category->id),
'name' => sprintf('min:1|max:100|uniqueObjectForUser:categories,name,%d', $category->id),
];
}
}

View File

@@ -64,11 +64,11 @@ class StoreRequest extends FormRequest
public function rules(): array
{
return [
'name' => 'required|between:1,255|uniquePiggyBankForUser',
'name' => 'required|min:1|max:255|uniquePiggyBankForUser',
'current_amount' => ['nullable', new IsValidPositiveAmount()],
'account_id' => 'required|numeric|belongsToUser:accounts,id',
'object_group_id' => 'numeric|belongsToUser:object_groups,id',
'object_group_title' => 'between:1,255',
'object_group_title' => ['min:1', 'max:255'],
'target_amount' => ['required', new IsValidPositiveAmount()],
'start_date' => 'date|nullable',
'target_date' => 'date|nullable|after:start_date',

View File

@@ -69,7 +69,7 @@ class UpdateRequest extends FormRequest
$piggyBank = $this->route()->parameter('piggyBank');
return [
'name' => 'between:1,255|uniquePiggyBankForUser:'.$piggyBank->id,
'name' => 'min:1|max:255|uniquePiggyBankForUser:'.$piggyBank->id,
'current_amount' => ['nullable', new LessThanPiggyTarget(), new IsValidPositiveAmount()],
'target_amount' => ['nullable', new IsValidPositiveAmount()],
'start_date' => 'date|nullable',

View File

@@ -33,6 +33,7 @@ use FireflyIII\Validation\CurrencyValidation;
use FireflyIII\Validation\RecurrenceValidation;
use FireflyIII\Validation\TransactionValidation;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Support\Facades\Log;
use Illuminate\Validation\Validator;
/**
@@ -72,67 +73,6 @@ class StoreRequest extends FormRequest
];
}
/**
* The rules that the incoming request must be matched against.
*/
public function rules(): array
{
return [
'type' => 'required|in:withdrawal,transfer,deposit',
'title' => 'required|between:1,255|uniqueObjectForUser:recurrences,title',
'description' => 'between:1,65000',
'first_date' => 'required|date',
'apply_rules' => [new IsBoolean()],
'active' => [new IsBoolean()],
'repeat_until' => 'nullable|date',
'nr_of_repetitions' => 'nullable|numeric|between:1,31',
'repetitions.*.type' => 'required|in:daily,weekly,ndom,monthly,yearly',
'repetitions.*.moment' => 'between:0,10',
'repetitions.*.skip' => 'nullable|numeric|between:0,31',
'repetitions.*.weekend' => 'numeric|min:1|max:4',
'transactions.*.description' => 'required|between:1,255',
'transactions.*.amount' => ['required', new IsValidPositiveAmount()],
'transactions.*.foreign_amount' => ['nullable', new IsValidPositiveAmount()],
'transactions.*.currency_id' => 'nullable|numeric|exists:transaction_currencies,id',
'transactions.*.currency_code' => 'nullable|min:3|max:51|exists:transaction_currencies,code',
'transactions.*.foreign_currency_id' => 'nullable|numeric|exists:transaction_currencies,id',
'transactions.*.foreign_currency_code' => 'nullable|min:3|max:51|exists:transaction_currencies,code',
'transactions.*.source_id' => ['numeric', 'nullable', new BelongsUser()],
'transactions.*.source_name' => 'between:1,255|nullable',
'transactions.*.destination_id' => ['numeric', 'nullable', new BelongsUser()],
'transactions.*.destination_name' => 'between:1,255|nullable',
// new and updated fields:
'transactions.*.budget_id' => ['nullable', 'mustExist:budgets,id', new BelongsUser()],
'transactions.*.budget_name' => ['between:1,255', 'nullable', new BelongsUser()],
'transactions.*.category_id' => ['nullable', 'mustExist:categories,id', new BelongsUser()],
'transactions.*.category_name' => 'between:1,255|nullable',
'transactions.*.piggy_bank_id' => ['nullable', 'numeric', 'mustExist:piggy_banks,id', new BelongsUser()],
'transactions.*.piggy_bank_name' => ['between:1,255', 'nullable', new BelongsUser()],
'transactions.*.tags' => 'nullable|between:1,255',
];
}
/**
* Configure the validator instance.
*/
public function withValidator(Validator $validator): void
{
$validator->after(
function (Validator $validator): void {
$this->validateRecurringConfig($validator);
$this->validateOneRecurrenceTransaction($validator);
$this->validateOneRepetition($validator);
$this->validateRecurrenceRepetition($validator);
$this->validateRepetitionMoment($validator);
$this->validateForeignCurrencyInformation($validator);
$this->validateAccountInformation($validator);
}
);
}
/**
* Returns the transaction data as it is found in the submitted data. It's a complex method according to code
* standards but it just has a lot of ??-statements because of the fields that may or may not exist.
@@ -191,4 +131,68 @@ class StoreRequest extends FormRequest
return $return;
}
/**
* The rules that the incoming request must be matched against.
*/
public function rules(): array
{
return [
'type' => 'required|in:withdrawal,transfer,deposit',
'title' => 'required|min:1|max:255|uniqueObjectForUser:recurrences,title',
'description' => 'min:1|max:32768',
'first_date' => 'required|date',
'apply_rules' => [new IsBoolean()],
'active' => [new IsBoolean()],
'repeat_until' => 'nullable|date',
'nr_of_repetitions' => 'nullable|numeric|min:1|max:31',
'repetitions.*.type' => 'required|in:daily,weekly,ndom,monthly,yearly',
'repetitions.*.moment' => 'min:0|max:10',
'repetitions.*.skip' => 'nullable|numeric|min:0|max:31',
'repetitions.*.weekend' => 'numeric|min:1|max:4',
'transactions.*.description' => 'required|min:1|max:255',
'transactions.*.amount' => ['required', new IsValidPositiveAmount()],
'transactions.*.foreign_amount' => ['nullable', new IsValidPositiveAmount()],
'transactions.*.currency_id' => 'nullable|numeric|exists:transaction_currencies,id',
'transactions.*.currency_code' => 'nullable|min:3|max:51|exists:transaction_currencies,code',
'transactions.*.foreign_currency_id' => 'nullable|numeric|exists:transaction_currencies,id',
'transactions.*.foreign_currency_code' => 'nullable|min:3|max:51|exists:transaction_currencies,code',
'transactions.*.source_id' => ['numeric', 'nullable', new BelongsUser()],
'transactions.*.source_name' => 'min:1|max:255|nullable',
'transactions.*.destination_id' => ['numeric', 'nullable', new BelongsUser()],
'transactions.*.destination_name' => 'min:1|max:255|nullable',
// new and updated fields:
'transactions.*.budget_id' => ['nullable', 'mustExist:budgets,id', new BelongsUser()],
'transactions.*.budget_name' => ['min:1', 'max:255', 'nullable', new BelongsUser()],
'transactions.*.category_id' => ['nullable', 'mustExist:categories,id', new BelongsUser()],
'transactions.*.category_name' => 'min:1|max:255|nullable',
'transactions.*.piggy_bank_id' => ['nullable', 'numeric', 'mustExist:piggy_banks,id', new BelongsUser()],
'transactions.*.piggy_bank_name' => ['min:1', 'max:255', 'nullable', new BelongsUser()],
'transactions.*.tags' => 'nullable|min:1|max:255',
];
}
/**
* Configure the validator instance.
*/
public function withValidator(Validator $validator): void
{
$validator->after(
function (Validator $validator): void {
$this->validateRecurringConfig($validator);
$this->validateOneRecurrenceTransaction($validator);
$this->validateOneRepetition($validator);
$this->validateRecurrenceRepetition($validator);
$this->validateRepetitionMoment($validator);
$this->validateForeignCurrencyInformation($validator);
$this->validateAccountInformation($validator);
}
);
if ($validator->fails()) {
Log::channel('audit')->error(sprintf('Validation errors in %s', __CLASS__), $validator->errors()->toArray());
}
}
}

View File

@@ -34,6 +34,7 @@ use FireflyIII\Validation\CurrencyValidation;
use FireflyIII\Validation\RecurrenceValidation;
use FireflyIII\Validation\TransactionValidation;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Support\Facades\Log;
use Illuminate\Validation\Validator;
/**
@@ -77,72 +78,6 @@ class UpdateRequest extends FormRequest
return $return;
}
/**
* The rules that the incoming request must be matched against.
*/
public function rules(): array
{
/** @var Recurrence $recurrence */
$recurrence = $this->route()->parameter('recurrence');
return [
'title' => sprintf('between:1,255|uniqueObjectForUser:recurrences,title,%d', $recurrence->id),
'description' => 'between:1,65000',
'first_date' => 'date',
'apply_rules' => [new IsBoolean()],
'active' => [new IsBoolean()],
'repeat_until' => 'nullable|date',
'nr_of_repetitions' => 'nullable|numeric|between:1,31',
'repetitions.*.type' => 'in:daily,weekly,ndom,monthly,yearly',
'repetitions.*.moment' => 'between:0,10',
'repetitions.*.skip' => 'nullable|numeric|between:0,31',
'repetitions.*.weekend' => 'nullable|numeric|min:1|max:4',
'transactions.*.description' => 'between:1,255',
'transactions.*.amount' => [new IsValidPositiveAmount()],
'transactions.*.foreign_amount' => ['nullable', new IsValidPositiveAmount()],
'transactions.*.currency_id' => 'nullable|numeric|exists:transaction_currencies,id',
'transactions.*.currency_code' => 'nullable|min:3|max:51|exists:transaction_currencies,code',
'transactions.*.foreign_currency_id' => 'nullable|numeric|exists:transaction_currencies,id',
'transactions.*.foreign_currency_code' => 'nullable|min:3|max:51|exists:transaction_currencies,code',
'transactions.*.source_id' => ['numeric', 'nullable', new BelongsUser()],
'transactions.*.source_name' => 'between:1,255|nullable',
'transactions.*.destination_id' => ['numeric', 'nullable', new BelongsUser()],
'transactions.*.destination_name' => 'between:1,255|nullable',
// new and updated fields:
'transactions.*.budget_id' => ['nullable', 'mustExist:budgets,id', new BelongsUser()],
'transactions.*.budget_name' => ['between:1,255', 'nullable', new BelongsUser()],
'transactions.*.category_id' => ['nullable', 'mustExist:categories,id', new BelongsUser()],
'transactions.*.category_name' => 'between:1,255|nullable',
'transactions.*.piggy_bank_id' => ['nullable', 'numeric', 'mustExist:piggy_banks,id', new BelongsUser()],
'transactions.*.piggy_bank_name' => ['between:1,255', 'nullable', new BelongsUser()],
'transactions.*.tags' => 'nullable|between:1,255',
];
}
/**
* Configure the validator instance.
*/
public function withValidator(Validator $validator): void
{
$validator->after(
function (Validator $validator): void {
// $this->validateOneRecurrenceTransaction($validator);
// $this->validateOneRepetitionUpdate($validator);
/** @var Recurrence $recurrence */
$recurrence = $this->route()->parameter('recurrence');
$this->validateTransactionId($recurrence, $validator);
$this->validateRecurrenceRepetition($validator);
$this->validateRepetitionMoment($validator);
$this->validateForeignCurrencyInformation($validator);
$this->valUpdateAccountInfo($validator);
}
);
}
/**
* Returns the repetition data as it is found in the submitted data.
*/
@@ -165,15 +100,15 @@ class UpdateRequest extends FormRequest
}
if (array_key_exists('moment', $repetition)) {
$current['moment'] = (string) $repetition['moment'];
$current['moment'] = (string)$repetition['moment'];
}
if (array_key_exists('skip', $repetition)) {
$current['skip'] = (int) $repetition['skip'];
$current['skip'] = (int)$repetition['skip'];
}
if (array_key_exists('weekend', $repetition)) {
$current['weekend'] = (int) $repetition['weekend'];
$current['weekend'] = (int)$repetition['weekend'];
}
$return[] = $current;
}
@@ -206,4 +141,73 @@ class UpdateRequest extends FormRequest
return $return;
}
/**
* The rules that the incoming request must be matched against.
*/
public function rules(): array
{
/** @var Recurrence $recurrence */
$recurrence = $this->route()->parameter('recurrence');
return [
'title' => sprintf('min:1|max:255|uniqueObjectForUser:recurrences,title,%d', $recurrence->id),
'description' => 'min:1|max:32768',
'first_date' => 'date',
'apply_rules' => [new IsBoolean()],
'active' => [new IsBoolean()],
'repeat_until' => 'nullable|date',
'nr_of_repetitions' => 'nullable|numeric|min:1|max:31',
'repetitions.*.type' => 'in:daily,weekly,ndom,monthly,yearly',
'repetitions.*.moment' => 'min:0|max:10|numeric',
'repetitions.*.skip' => 'nullable|numeric|min:0|max:31',
'repetitions.*.weekend' => 'nullable|numeric|min:1|max:4',
'transactions.*.description' => ['min:1', 'max:255'],
'transactions.*.amount' => [new IsValidPositiveAmount()],
'transactions.*.foreign_amount' => ['nullable', new IsValidPositiveAmount()],
'transactions.*.currency_id' => 'nullable|numeric|exists:transaction_currencies,id',
'transactions.*.currency_code' => 'nullable|min:3|max:51|exists:transaction_currencies,code',
'transactions.*.foreign_currency_id' => 'nullable|numeric|exists:transaction_currencies,id',
'transactions.*.foreign_currency_code' => 'nullable|min:3|max:51|exists:transaction_currencies,code',
'transactions.*.source_id' => ['numeric', 'nullable', new BelongsUser()],
'transactions.*.source_name' => 'min:1|max:255|nullable',
'transactions.*.destination_id' => ['numeric', 'nullable', new BelongsUser()],
'transactions.*.destination_name' => 'min:1|max:255|nullable',
// new and updated fields:
'transactions.*.budget_id' => ['nullable', 'mustExist:budgets,id', new BelongsUser()],
'transactions.*.budget_name' => ['min:1', 'max:255', 'nullable', new BelongsUser()],
'transactions.*.category_id' => ['nullable', 'mustExist:categories,id', new BelongsUser()],
'transactions.*.category_name' => 'min:1|max:255|nullable',
'transactions.*.piggy_bank_id' => ['nullable', 'numeric', 'mustExist:piggy_banks,id', new BelongsUser()],
'transactions.*.piggy_bank_name' => ['min:1', 'max:255', 'nullable', new BelongsUser()],
'transactions.*.tags' => 'nullable|min:1|max:255',
];
}
/**
* Configure the validator instance.
*/
public function withValidator(Validator $validator): void
{
$validator->after(
function (Validator $validator): void {
// $this->validateOneRecurrenceTransaction($validator);
// $this->validateOneRepetitionUpdate($validator);
/** @var Recurrence $recurrence */
$recurrence = $this->route()->parameter('recurrence');
$this->validateTransactionId($recurrence, $validator);
$this->validateRecurrenceRepetition($validator);
$this->validateRepetitionMoment($validator);
$this->validateForeignCurrencyInformation($validator);
$this->valUpdateAccountInfo($validator);
}
);
if ($validator->fails()) {
Log::channel('audit')->error(sprintf('Validation errors in %s', __CLASS__), $validator->errors()->toArray());
}
}
}

View File

@@ -24,10 +24,12 @@ declare(strict_types=1);
namespace FireflyIII\Api\V1\Requests\Models\Rule;
use FireflyIII\Rules\IsBoolean;
use FireflyIII\Rules\IsValidActionExpression;
use FireflyIII\Support\Request\ChecksLogin;
use FireflyIII\Support\Request\ConvertsDataTypes;
use FireflyIII\Support\Request\GetRuleConfiguration;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Support\Facades\Log;
use Illuminate\Validation\Validator;
/**
@@ -56,13 +58,48 @@ class StoreRequest extends FormRequest
'active' => ['active', 'boolean'],
];
$data = $this->getAllData($fields);
$data['triggers'] = $this->getRuleTriggers();
$data['actions'] = $this->getRuleActions();
return $data;
}
private function getRuleTriggers(): array
{
$triggers = $this->get('triggers');
$return = [];
if (is_array($triggers)) {
foreach ($triggers as $trigger) {
$return[] = [
'type' => $trigger['type'],
'value' => $trigger['value'],
'active' => $this->convertBoolean((string)($trigger['active'] ?? 'true')),
'stop_processing' => $this->convertBoolean((string)($trigger['stop_processing'] ?? 'false')),
];
}
}
return $return;
}
private function getRuleActions(): array
{
$actions = $this->get('actions');
$return = [];
if (is_array($actions)) {
foreach ($actions as $action) {
$return[] = [
'type' => $action['type'],
'value' => $action['value'],
'active' => $this->convertBoolean((string)($action['active'] ?? 'true')),
'stop_processing' => $this->convertBoolean((string)($action['stop_processing'] ?? 'false')),
];
}
}
return $return;
}
/**
* The rules that the incoming request must be matched against.
*/
@@ -76,17 +113,17 @@ class StoreRequest extends FormRequest
$contextActions = implode(',', config('firefly.context-rule-actions'));
return [
'title' => 'required|between:1,100|uniqueObjectForUser:rules,title',
'description' => 'between:1,5000|nullable',
'title' => 'required|min:1|max:100|uniqueObjectForUser:rules,title',
'description' => 'min:1|max:32768|nullable',
'rule_group_id' => 'belongsToUser:rule_groups|required_without:rule_group_title',
'rule_group_title' => 'nullable|between:1,255|required_without:rule_group_id|belongsToUser:rule_groups,title',
'rule_group_title' => 'nullable|min:1|max:255|required_without:rule_group_id|belongsToUser:rule_groups,title',
'trigger' => 'required|in:store-journal,update-journal',
'triggers.*.type' => 'required|in:'.implode(',', $validTriggers),
'triggers.*.value' => 'required_if:actions.*.type,'.$contextTriggers.'|min:1|ruleTriggerValue|max:1024',
'triggers.*.stop_processing' => [new IsBoolean()],
'triggers.*.active' => [new IsBoolean()],
'actions.*.type' => 'required|in:'.implode(',', $validActions),
'actions.*.value' => 'required_if:actions.*.type,'.$contextActions.'|ruleActionValue',
'actions.*.value' => [sprintf('required_if:actions.*.type,%s', $contextActions), new IsValidActionExpression(), 'ruleActionValue'],
'actions.*.stop_processing' => [new IsBoolean()],
'actions.*.active' => [new IsBoolean()],
'strict' => [new IsBoolean()],
@@ -108,6 +145,9 @@ class StoreRequest extends FormRequest
$this->atLeastOneActiveAction($validator);
}
);
if ($validator->fails()) {
Log::channel('audit')->error(sprintf('Validation errors in %s', __CLASS__), $validator->errors()->toArray());
}
}
/**
@@ -193,40 +233,4 @@ class StoreRequest extends FormRequest
$validator->errors()->add(sprintf('actions.%d.active', $inactiveIndex), (string)trans('validation.at_least_one_active_action'));
}
}
private function getRuleTriggers(): array
{
$triggers = $this->get('triggers');
$return = [];
if (is_array($triggers)) {
foreach ($triggers as $trigger) {
$return[] = [
'type' => $trigger['type'],
'value' => $trigger['value'],
'active' => $this->convertBoolean((string)($trigger['active'] ?? 'true')),
'stop_processing' => $this->convertBoolean((string)($trigger['stop_processing'] ?? 'false')),
];
}
}
return $return;
}
private function getRuleActions(): array
{
$actions = $this->get('actions');
$return = [];
if (is_array($actions)) {
foreach ($actions as $action) {
$return[] = [
'type' => $action['type'],
'value' => $action['value'],
'active' => $this->convertBoolean((string)($action['active'] ?? 'true')),
'stop_processing' => $this->convertBoolean((string)($action['stop_processing'] ?? 'false')),
];
}
}
return $return;
}
}

View File

@@ -47,16 +47,6 @@ class TestRequest extends FormRequest
];
}
public function rules(): array
{
return [
'start' => 'date',
'end' => 'date|after_or_equal:start',
'accounts' => '',
'accounts.*' => 'required|exists:accounts,id|belongsToUser:accounts',
];
}
private function getPage(): int
{
return 0 === (int)$this->query('page') ? 1 : (int)$this->query('page');
@@ -81,4 +71,14 @@ class TestRequest extends FormRequest
{
return $this->get('accounts');
}
public function rules(): array
{
return [
'start' => 'date',
'end' => 'date|after_or_equal:start',
'accounts' => '',
'accounts.*' => 'required|exists:accounts,id|belongsToUser:accounts',
];
}
}

View File

@@ -46,16 +46,6 @@ class TriggerRequest extends FormRequest
];
}
public function rules(): array
{
return [
'start' => 'date',
'end' => 'date|after_or_equal:start',
'accounts' => '',
'accounts.*' => 'exists:accounts,id|belongsToUser:accounts',
];
}
private function getDate(string $field): ?Carbon
{
$value = $this->query($field);
@@ -75,4 +65,14 @@ class TriggerRequest extends FormRequest
{
return $this->get('accounts') ?? [];
}
public function rules(): array
{
return [
'start' => 'date',
'end' => 'date|after_or_equal:start',
'accounts' => '',
'accounts.*' => 'exists:accounts,id|belongsToUser:accounts',
];
}
}

View File

@@ -25,10 +25,12 @@ namespace FireflyIII\Api\V1\Requests\Models\Rule;
use FireflyIII\Models\Rule;
use FireflyIII\Rules\IsBoolean;
use FireflyIII\Rules\IsValidActionExpression;
use FireflyIII\Support\Request\ChecksLogin;
use FireflyIII\Support\Request\ConvertsDataTypes;
use FireflyIII\Support\Request\GetRuleConfiguration;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Support\Facades\Log;
use Illuminate\Validation\Validator;
/**
@@ -69,6 +71,50 @@ class UpdateRequest extends FormRequest
return $return;
}
private function getRuleTriggers(): ?array
{
if (!$this->has('triggers')) {
return null;
}
$triggers = $this->get('triggers');
$return = [];
if (is_array($triggers)) {
foreach ($triggers as $trigger) {
$active = array_key_exists('active', $trigger) ? $trigger['active'] : true;
$stopProcessing = array_key_exists('stop_processing', $trigger) ? $trigger['stop_processing'] : false;
$return[] = [
'type' => $trigger['type'],
'value' => $trigger['value'],
'active' => $active,
'stop_processing' => $stopProcessing,
];
}
}
return $return;
}
private function getRuleActions(): ?array
{
if (!$this->has('actions')) {
return null;
}
$actions = $this->get('actions');
$return = [];
if (is_array($actions)) {
foreach ($actions as $action) {
$return[] = [
'type' => $action['type'],
'value' => $action['value'],
'active' => $this->convertBoolean((string)($action['active'] ?? 'false')),
'stop_processing' => $this->convertBoolean((string)($action['stop_processing'] ?? 'false')),
];
}
}
return $return;
}
/**
* The rules that the incoming request must be matched against.
*/
@@ -85,23 +131,23 @@ class UpdateRequest extends FormRequest
$contextActions = implode(',', config('firefly.context-rule-actions'));
return [
'title' => sprintf('between:1,100|uniqueObjectForUser:rules,title,%d', $rule->id),
'description' => 'between:1,5000|nullable',
'title' => sprintf('min:1|max:100|uniqueObjectForUser:rules,title,%d', $rule->id),
'description' => 'min:1|max:32768|nullable',
'rule_group_id' => 'belongsToUser:rule_groups',
'rule_group_title' => 'nullable|between:1,255|belongsToUser:rule_groups,title',
'rule_group_title' => 'nullable|min:1|max:255|belongsToUser:rule_groups,title',
'trigger' => 'in:store-journal,update-journal',
'triggers.*.type' => 'required|in:'.implode(',', $validTriggers),
'triggers.*.value' => 'required_if:actions.*.type,'.$contextTriggers.'|min:1|ruleTriggerValue|max:1024',
'triggers.*.stop_processing' => [new IsBoolean()],
'triggers.*.active' => [new IsBoolean()],
'actions.*.type' => 'required|in:'.implode(',', $validActions),
'actions.*.value' => 'required_if:actions.*.type,'.$contextActions.'|ruleActionValue',
'actions.*.value' => [sprintf('required_if:actions.*.type,%s', $contextActions), new IsValidActionExpression(), 'ruleActionValue'],
'actions.*.stop_processing' => [new IsBoolean()],
'actions.*.active' => [new IsBoolean()],
'strict' => [new IsBoolean()],
'stop_processing' => [new IsBoolean()],
'active' => [new IsBoolean()],
'order' => 'numeric|between:1,1337',
'order' => 'numeric|min:1|max:2048',
];
}
@@ -118,6 +164,9 @@ class UpdateRequest extends FormRequest
$this->atLeastOneValidAction($validator);
}
);
if ($validator->fails()) {
Log::channel('audit')->error(sprintf('Validation errors in %s', __CLASS__), $validator->errors()->toArray());
}
}
/**
@@ -200,48 +249,4 @@ class UpdateRequest extends FormRequest
$validator->errors()->add(sprintf('actions.%d.active', $inactiveIndex), (string)trans('validation.at_least_one_active_action'));
}
}
private function getRuleTriggers(): ?array
{
if (!$this->has('triggers')) {
return null;
}
$triggers = $this->get('triggers');
$return = [];
if (is_array($triggers)) {
foreach ($triggers as $trigger) {
$active = array_key_exists('active', $trigger) ? $trigger['active'] : true;
$stopProcessing = array_key_exists('stop_processing', $trigger) ? $trigger['stop_processing'] : false;
$return[] = [
'type' => $trigger['type'],
'value' => $trigger['value'],
'active' => $active,
'stop_processing' => $stopProcessing,
];
}
}
return $return;
}
private function getRuleActions(): ?array
{
if (!$this->has('actions')) {
return null;
}
$actions = $this->get('actions');
$return = [];
if (is_array($actions)) {
foreach ($actions as $action) {
$return[] = [
'type' => $action['type'],
'value' => $action['value'],
'active' => $this->convertBoolean((string)($action['active'] ?? 'false')),
'stop_processing' => $this->convertBoolean((string)($action['stop_processing'] ?? 'false')),
];
}
}
return $return;
}
}

View File

@@ -0,0 +1,42 @@
<?php
/**
* ValidateExpressionRequest.php
* Copyright (c) 2024 Michael Thomas
*
* This file is part of Firefly III (https://github.com/firefly-iii).
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
declare(strict_types=1);
namespace FireflyIII\Api\V1\Requests\Models\Rule;
use FireflyIII\Rules\IsValidActionExpression;
use FireflyIII\Support\Request\ChecksLogin;
use Illuminate\Foundation\Http\FormRequest;
/**
* Class ValidateExpressionRequest
*/
class ValidateExpressionRequest extends FormRequest
{
use ChecksLogin;
public function rules(): array
{
return ['expression' => ['required', new IsValidActionExpression()]];
}
}

View File

@@ -64,8 +64,8 @@ class StoreRequest extends FormRequest
public function rules(): array
{
return [
'title' => 'required|between:1,100|uniqueObjectForUser:rule_groups,title',
'description' => 'between:1,5000|nullable',
'title' => 'required|min:1|max:100|uniqueObjectForUser:rule_groups,title',
'description' => 'min:1|max:32768|nullable',
'active' => [new IsBoolean()],
];
}

View File

@@ -46,16 +46,6 @@ class TestRequest extends FormRequest
];
}
public function rules(): array
{
return [
'start' => 'date',
'end' => 'date|after_or_equal:start',
'accounts' => '',
'accounts.*' => 'exists:accounts,id|belongsToUser:accounts',
];
}
private function getDate(string $field): ?Carbon
{
$value = $this->query($field);
@@ -75,4 +65,14 @@ class TestRequest extends FormRequest
{
return $this->get('accounts');
}
public function rules(): array
{
return [
'start' => 'date',
'end' => 'date|after_or_equal:start',
'accounts' => '',
'accounts.*' => 'exists:accounts,id|belongsToUser:accounts',
];
}
}

View File

@@ -46,14 +46,6 @@ class TriggerRequest extends FormRequest
];
}
public function rules(): array
{
return [
'start' => 'date',
'end' => 'date|after_or_equal:start',
];
}
private function getDate(string $field): ?Carbon
{
$value = $this->query($field);
@@ -71,6 +63,18 @@ class TriggerRequest extends FormRequest
private function getAccounts(): array
{
if (null === $this->get('accounts')) {
return [];
}
return $this->get('accounts');
}
public function rules(): array
{
return [
'start' => 'date',
'end' => 'date|after_or_equal:start',
];
}
}

View File

@@ -62,8 +62,8 @@ class UpdateRequest extends FormRequest
$ruleGroup = $this->route()->parameter('ruleGroup');
return [
'title' => 'between:1,100|uniqueObjectForUser:rule_groups,title,'.$ruleGroup->id,
'description' => 'between:1,5000|nullable',
'title' => 'min:1|max:100|uniqueObjectForUser:rule_groups,title,'.$ruleGroup->id,
'description' => 'min:1|max:32768|nullable',
'active' => [new IsBoolean()],
];
}

View File

@@ -60,7 +60,7 @@ class StoreRequest extends FormRequest
{
$rules = [
'tag' => 'required|min:1|uniqueObjectForUser:tags,tag|max:1024',
'description' => 'min:1|nullable|max:65536',
'description' => 'min:1|nullable|max:32768',
'date' => 'date|nullable',
];

View File

@@ -66,7 +66,7 @@ class UpdateRequest extends FormRequest
// TODO check if uniqueObjectForUser is obsolete
$rules = [
'tag' => 'min:1|max:1024|uniqueObjectForUser:tags,tag,'.$tag->id,
'description' => 'min:1|nullable|max:65536',
'description' => 'min:1|nullable|max:32768',
'date' => 'date|nullable',
];

View File

@@ -28,6 +28,7 @@ use FireflyIII\Rules\BelongsUser;
use FireflyIII\Rules\IsBoolean;
use FireflyIII\Rules\IsDateOrTime;
use FireflyIII\Rules\IsValidPositiveAmount;
use FireflyIII\Rules\IsValidZeroOrMoreAmount;
use FireflyIII\Support\NullArrayObject;
use FireflyIII\Support\Request\AppendsLocationData;
use FireflyIII\Support\Request\ChecksLogin;
@@ -36,6 +37,7 @@ use FireflyIII\Validation\CurrencyValidation;
use FireflyIII\Validation\GroupValidation;
use FireflyIII\Validation\TransactionValidation;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Support\Facades\Log;
use Illuminate\Validation\Validator;
/**
@@ -67,131 +69,6 @@ class StoreRequest extends FormRequest
// TODO include location and ability to process it.
}
/**
* The rules that the incoming request must be matched against.
*/
public function rules(): array
{
app('log')->debug('Collect rules of TransactionStoreRequest');
$validProtocols = config('firefly.valid_url_protocols');
return [
// basic fields for group:
'group_title' => 'between:1,1000|nullable',
'error_if_duplicate_hash' => [new IsBoolean()],
'apply_rules' => [new IsBoolean()],
// transaction rules (in array for splits):
'transactions.*.type' => 'required|in:withdrawal,deposit,transfer,opening-balance,reconciliation',
'transactions.*.date' => ['required', new IsDateOrTime()],
'transactions.*.order' => 'numeric|min:0',
// currency info
'transactions.*.currency_id' => 'numeric|exists:transaction_currencies,id|nullable',
'transactions.*.currency_code' => 'min:3|max:51|exists:transaction_currencies,code|nullable',
'transactions.*.foreign_currency_id' => 'numeric|exists:transaction_currencies,id|nullable',
'transactions.*.foreign_currency_code' => 'min:3|max:51|exists:transaction_currencies,code|nullable',
// amount
'transactions.*.amount' => ['required', new IsValidPositiveAmount()],
'transactions.*.foreign_amount' => ['nullable', new IsValidPositiveAmount()],
// description
'transactions.*.description' => 'nullable|between:1,1000',
// source of transaction
'transactions.*.source_id' => ['numeric', 'nullable', new BelongsUser()],
'transactions.*.source_name' => 'between:1,255|nullable',
'transactions.*.source_iban' => 'between:1,255|nullable|iban',
'transactions.*.source_number' => 'between:1,255|nullable',
'transactions.*.source_bic' => 'between:1,255|nullable|bic',
// destination of transaction
'transactions.*.destination_id' => ['numeric', 'nullable', new BelongsUser()],
'transactions.*.destination_name' => 'between:1,255|nullable',
'transactions.*.destination_iban' => 'between:1,255|nullable|iban',
'transactions.*.destination_number' => 'between:1,255|nullable',
'transactions.*.destination_bic' => 'between:1,255|nullable|bic',
// budget, category, bill and piggy
'transactions.*.budget_id' => ['mustExist:budgets,id', new BelongsUser()],
'transactions.*.budget_name' => ['between:1,255', 'nullable', new BelongsUser()],
'transactions.*.category_id' => ['mustExist:categories,id', new BelongsUser(), 'nullable'],
'transactions.*.category_name' => 'between:1,255|nullable',
'transactions.*.bill_id' => ['numeric', 'nullable', 'mustExist:bills,id', new BelongsUser()],
'transactions.*.bill_name' => ['between:1,255', 'nullable', new BelongsUser()],
'transactions.*.piggy_bank_id' => ['numeric', 'nullable', 'mustExist:piggy_banks,id', new BelongsUser()],
'transactions.*.piggy_bank_name' => ['between:1,255', 'nullable', new BelongsUser()],
// other interesting fields
'transactions.*.reconciled' => [new IsBoolean()],
'transactions.*.notes' => 'min:1|max:50000|nullable',
'transactions.*.tags' => 'between:0,255',
'transactions.*.tags.*' => 'between:0,255',
// meta info fields
'transactions.*.internal_reference' => 'min:1|max:255|nullable',
'transactions.*.external_id' => 'min:1|max:255|nullable',
'transactions.*.recurrence_id' => 'min:1|max:255|nullable',
'transactions.*.bunq_payment_id' => 'min:1|max:255|nullable',
'transactions.*.external_url' => sprintf('min:1|max:255|nullable|url:%s', $validProtocols),
// SEPA fields:
'transactions.*.sepa_cc' => 'min:1|max:255|nullable',
'transactions.*.sepa_ct_op' => 'min:1|max:255|nullable',
'transactions.*.sepa_ct_id' => 'min:1|max:255|nullable',
'transactions.*.sepa_db' => 'min:1|max:255|nullable',
'transactions.*.sepa_country' => 'min:1|max:255|nullable',
'transactions.*.sepa_ep' => 'min:1|max:255|nullable',
'transactions.*.sepa_ci' => 'min:1|max:255|nullable',
'transactions.*.sepa_batch_id' => 'min:1|max:255|nullable',
// dates
'transactions.*.interest_date' => 'date|nullable',
'transactions.*.book_date' => 'date|nullable',
'transactions.*.process_date' => 'date|nullable',
'transactions.*.due_date' => 'date|nullable',
'transactions.*.payment_date' => 'date|nullable',
'transactions.*.invoice_date' => 'date|nullable',
];
}
/**
* Configure the validator instance.
*/
public function withValidator(Validator $validator): void
{
$validator->after(
function (Validator $validator): void {
// must be valid array.
$this->validateTransactionArray($validator);
// must submit at least one transaction.
app('log')->debug('Now going to validateOneTransaction');
$this->validateOneTransaction($validator);
app('log')->debug('Now done with validateOneTransaction');
// all journals must have a description
$this->validateDescriptions($validator);
// all transaction types must be equal:
$this->validateTransactionTypes($validator);
// validate foreign currency info
$this->validateForeignCurrencyInformation($validator);
// validate all account info
$this->validateAccountInformation($validator);
// validate source/destination is equal, depending on the transaction journal type.
$this->validateEqualAccounts($validator);
// the group must have a description if > 1 journal.
$this->validateGroupDescription($validator);
}
);
}
/**
* Get transaction data.
*/
@@ -286,4 +163,132 @@ class StoreRequest extends FormRequest
return $return;
}
/**
* The rules that the incoming request must be matched against.
*/
public function rules(): array
{
app('log')->debug('Collect rules of TransactionStoreRequest');
$validProtocols = config('firefly.valid_url_protocols');
return [
// basic fields for group:
'group_title' => 'min:1|max:1000|nullable',
'error_if_duplicate_hash' => [new IsBoolean()],
'apply_rules' => [new IsBoolean()],
// transaction rules (in array for splits):
'transactions.*.type' => 'required|in:withdrawal,deposit,transfer,opening-balance,reconciliation',
'transactions.*.date' => ['required', new IsDateOrTime()],
'transactions.*.order' => 'numeric|min:0',
// currency info
'transactions.*.currency_id' => 'numeric|exists:transaction_currencies,id|nullable',
'transactions.*.currency_code' => 'min:3|max:51|exists:transaction_currencies,code|nullable',
'transactions.*.foreign_currency_id' => 'numeric|exists:transaction_currencies,id|nullable',
'transactions.*.foreign_currency_code' => 'min:3|max:51|exists:transaction_currencies,code|nullable',
// amount
'transactions.*.amount' => ['required', new IsValidPositiveAmount()],
'transactions.*.foreign_amount' => ['nullable', new IsValidZeroOrMoreAmount()],
// description
'transactions.*.description' => 'nullable|min:1|max:1000',
// source of transaction
'transactions.*.source_id' => ['numeric', 'nullable', new BelongsUser()],
'transactions.*.source_name' => 'min:1|max:255|nullable',
'transactions.*.source_iban' => 'min:1|max:255|nullable|iban',
'transactions.*.source_number' => 'min:1|max:255|nullable',
'transactions.*.source_bic' => 'min:1|max:255|nullable|bic',
// destination of transaction
'transactions.*.destination_id' => ['numeric', 'nullable', new BelongsUser()],
'transactions.*.destination_name' => 'min:1|max:255|nullable',
'transactions.*.destination_iban' => 'min:1|max:255|nullable|iban',
'transactions.*.destination_number' => 'min:1|max:255|nullable',
'transactions.*.destination_bic' => 'min:1|max:255|nullable|bic',
// budget, category, bill and piggy
'transactions.*.budget_id' => ['mustExist:budgets,id', new BelongsUser()],
'transactions.*.budget_name' => ['min:1', 'max:255', 'nullable', new BelongsUser()],
'transactions.*.category_id' => ['mustExist:categories,id', new BelongsUser(), 'nullable'],
'transactions.*.category_name' => 'min:1|max:255|nullable',
'transactions.*.bill_id' => ['numeric', 'nullable', 'mustExist:bills,id', new BelongsUser()],
'transactions.*.bill_name' => ['min:1', 'max:255', 'nullable', new BelongsUser()],
'transactions.*.piggy_bank_id' => ['numeric', 'nullable', 'mustExist:piggy_banks,id', new BelongsUser()],
'transactions.*.piggy_bank_name' => ['min:1', 'max:255', 'nullable', new BelongsUser()],
// other interesting fields
'transactions.*.reconciled' => [new IsBoolean()],
'transactions.*.notes' => 'min:1|max:32768|nullable',
'transactions.*.tags' => 'min:0|max:255',
'transactions.*.tags.*' => 'min:0|max:255',
// meta info fields
'transactions.*.internal_reference' => 'min:1|max:255|nullable',
'transactions.*.external_id' => 'min:1|max:255|nullable',
'transactions.*.recurrence_id' => 'min:1|max:255|nullable',
'transactions.*.bunq_payment_id' => 'min:1|max:255|nullable',
'transactions.*.external_url' => sprintf('min:1|max:255|nullable|url:%s', $validProtocols),
// SEPA fields:
'transactions.*.sepa_cc' => 'min:1|max:255|nullable',
'transactions.*.sepa_ct_op' => 'min:1|max:255|nullable',
'transactions.*.sepa_ct_id' => 'min:1|max:255|nullable',
'transactions.*.sepa_db' => 'min:1|max:255|nullable',
'transactions.*.sepa_country' => 'min:1|max:255|nullable',
'transactions.*.sepa_ep' => 'min:1|max:255|nullable',
'transactions.*.sepa_ci' => 'min:1|max:255|nullable',
'transactions.*.sepa_batch_id' => 'min:1|max:255|nullable',
// dates
'transactions.*.interest_date' => 'date|nullable',
'transactions.*.book_date' => 'date|nullable',
'transactions.*.process_date' => 'date|nullable',
'transactions.*.due_date' => 'date|nullable',
'transactions.*.payment_date' => 'date|nullable',
'transactions.*.invoice_date' => 'date|nullable',
];
}
/**
* Configure the validator instance.
*/
public function withValidator(Validator $validator): void
{
$validator->after(
function (Validator $validator): void {
// must be valid array.
$this->validateTransactionArray($validator);
// must submit at least one transaction.
app('log')->debug('Now going to validateOneTransaction');
$this->validateOneTransaction($validator);
app('log')->debug('Now done with validateOneTransaction');
// all journals must have a description
$this->validateDescriptions($validator);
// all transaction types must be equal:
$this->validateTransactionTypes($validator);
// validate foreign currency info
$this->validateForeignCurrencyInformation($validator);
// validate all account info
$this->validateAccountInformation($validator);
// validate source/destination is equal, depending on the transaction journal type.
$this->validateEqualAccounts($validator);
// the group must have a description if > 1 journal.
$this->validateGroupDescription($validator);
}
);
if ($validator->fails()) {
Log::channel('audit')->error(sprintf('Validation errors in %s', __CLASS__), $validator->errors()->toArray());
}
}
}

View File

@@ -36,6 +36,7 @@ use FireflyIII\Support\Request\ConvertsDataTypes;
use FireflyIII\Validation\GroupValidation;
use FireflyIII\Validation\TransactionValidation;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Support\Facades\Log;
use Illuminate\Validation\Validator;
/**
@@ -89,124 +90,6 @@ class UpdateRequest extends FormRequest
return $data;
}
/**
* The rules that the incoming request must be matched against.
*/
public function rules(): array
{
app('log')->debug(sprintf('Now in %s', __METHOD__));
$validProtocols = config('firefly.valid_url_protocols');
return [
// basic fields for group:
'group_title' => 'between:1,1000|nullable',
'apply_rules' => [new IsBoolean()],
// transaction rules (in array for splits):
'transactions.*.type' => 'in:withdrawal,deposit,transfer,opening-balance,reconciliation',
'transactions.*.date' => [new IsDateOrTime()],
'transactions.*.order' => 'numeric|min:0',
// group id:
'transactions.*.transaction_journal_id' => ['nullable', 'numeric', new BelongsUser()],
// currency info
'transactions.*.currency_id' => 'numeric|exists:transaction_currencies,id|nullable',
'transactions.*.currency_code' => 'min:3|max:51|exists:transaction_currencies,code|nullable',
'transactions.*.foreign_currency_id' => 'nullable|numeric|exists:transaction_currencies,id',
'transactions.*.foreign_currency_code' => 'nullable|min:3|max:51|exists:transaction_currencies,code',
// amount
'transactions.*.amount' => ['nullable', new IsValidPositiveAmount()],
'transactions.*.foreign_amount' => ['nullable', new IsValidZeroOrMoreAmount()],
// description
'transactions.*.description' => 'nullable|between:1,1000',
// source of transaction
'transactions.*.source_id' => ['numeric', 'nullable', new BelongsUser()],
'transactions.*.source_name' => 'between:1,255|nullable',
// destination of transaction
'transactions.*.destination_id' => ['numeric', 'nullable', new BelongsUser()],
'transactions.*.destination_name' => 'between:1,255|nullable',
// budget, category, bill and piggy
'transactions.*.budget_id' => ['mustExist:budgets,id', new BelongsUser(), 'nullable'],
'transactions.*.budget_name' => ['between:1,255', 'nullable', new BelongsUser()],
'transactions.*.category_id' => ['mustExist:categories,id', new BelongsUser(), 'nullable'],
'transactions.*.category_name' => 'between:1,255|nullable',
'transactions.*.bill_id' => ['numeric', 'nullable', 'mustExist:bills,id', new BelongsUser()],
'transactions.*.bill_name' => ['between:1,255', 'nullable', new BelongsUser()],
// other interesting fields
'transactions.*.reconciled' => [new IsBoolean()],
'transactions.*.notes' => 'min:1|max:50000|nullable',
'transactions.*.tags' => 'between:0,255|nullable',
'transactions.*.tags.*' => 'between:0,255',
// meta info fields
'transactions.*.internal_reference' => 'min:1|max:255|nullable',
'transactions.*.external_id' => 'min:1|max:255|nullable',
'transactions.*.recurrence_id' => 'min:1|max:255|nullable',
'transactions.*.bunq_payment_id' => 'min:1|max:255|nullable',
'transactions.*.external_url' => sprintf('min:1|max:255|nullable|url:%s', $validProtocols),
// SEPA fields:
'transactions.*.sepa_cc' => 'min:1|max:255|nullable',
'transactions.*.sepa_ct_op' => 'min:1|max:255|nullable',
'transactions.*.sepa_ct_id' => 'min:1|max:255|nullable',
'transactions.*.sepa_db' => 'min:1|max:255|nullable',
'transactions.*.sepa_country' => 'min:1|max:255|nullable',
'transactions.*.sepa_ep' => 'min:1|max:255|nullable',
'transactions.*.sepa_ci' => 'min:1|max:255|nullable',
'transactions.*.sepa_batch_id' => 'min:1|max:255|nullable',
// dates
'transactions.*.interest_date' => 'date|nullable',
'transactions.*.book_date' => 'date|nullable',
'transactions.*.process_date' => 'date|nullable',
'transactions.*.due_date' => 'date|nullable',
'transactions.*.payment_date' => 'date|nullable',
'transactions.*.invoice_date' => 'date|nullable',
];
}
/**
* Configure the validator instance.
*/
public function withValidator(Validator $validator): void
{
app('log')->debug('Now in withValidator');
/** @var TransactionGroup $transactionGroup */
$transactionGroup = $this->route()->parameter('transactionGroup');
$validator->after(
function (Validator $validator) use ($transactionGroup): void {
// if more than one, verify that there are journal ID's present.
$this->validateJournalIds($validator, $transactionGroup);
// all transaction types must be equal:
$this->validateTransactionTypesForUpdate($validator);
// user wants to update a reconciled transaction.
// source, destination, amount + foreign_amount cannot be changed
// and must be omitted from the request.
$this->preventUpdateReconciled($validator, $transactionGroup);
// validate source/destination is equal, depending on the transaction journal type.
$this->validateEqualAccountsForUpdate($validator, $transactionGroup);
// see method:
// $this->preventNoAccountInfo($validator, );
// validate that the currency fits the source and/or destination account.
// validate all account info
$this->validateAccountInformationUpdate($validator, $transactionGroup);
}
);
}
/**
* Get transaction data.
*
@@ -254,7 +137,7 @@ class UpdateRequest extends FormRequest
{
foreach ($this->integerFields as $fieldName) {
if (array_key_exists($fieldName, $transaction)) {
$current[$fieldName] = $this->integerFromValue((string) $transaction[$fieldName]);
$current[$fieldName] = $this->integerFromValue((string)$transaction[$fieldName]);
}
}
@@ -269,7 +152,7 @@ class UpdateRequest extends FormRequest
{
foreach ($this->stringFields as $fieldName) {
if (array_key_exists($fieldName, $transaction)) {
$current[$fieldName] = $this->clearString((string) $transaction[$fieldName]);
$current[$fieldName] = $this->clearString((string)$transaction[$fieldName]);
}
}
@@ -284,7 +167,7 @@ class UpdateRequest extends FormRequest
{
foreach ($this->textareaFields as $fieldName) {
if (array_key_exists($fieldName, $transaction)) {
$current[$fieldName] = $this->clearStringKeepNewlines((string) $transaction[$fieldName]); // keep newlines
$current[$fieldName] = $this->clearStringKeepNewlines((string)$transaction[$fieldName]); // keep newlines
}
}
@@ -300,8 +183,8 @@ class UpdateRequest extends FormRequest
foreach ($this->dateFields as $fieldName) {
app('log')->debug(sprintf('Now at date field %s', $fieldName));
if (array_key_exists($fieldName, $transaction)) {
app('log')->debug(sprintf('New value: "%s"', (string) $transaction[$fieldName]));
$current[$fieldName] = $this->dateFromValue((string) $transaction[$fieldName]);
app('log')->debug(sprintf('New value: "%s"', (string)$transaction[$fieldName]));
$current[$fieldName] = $this->dateFromValue((string)$transaction[$fieldName]);
}
}
@@ -316,7 +199,7 @@ class UpdateRequest extends FormRequest
{
foreach ($this->booleanFields as $fieldName) {
if (array_key_exists($fieldName, $transaction)) {
$current[$fieldName] = $this->convertBoolean((string) $transaction[$fieldName]);
$current[$fieldName] = $this->convertBoolean((string)$transaction[$fieldName]);
}
}
@@ -351,11 +234,132 @@ class UpdateRequest extends FormRequest
$current[$fieldName] = sprintf('%.12f', $value);
}
if (!is_float($value)) {
$current[$fieldName] = (string) $value;
$current[$fieldName] = (string)$value;
}
}
}
return $current;
}
/**
* The rules that the incoming request must be matched against.
*/
public function rules(): array
{
app('log')->debug(sprintf('Now in %s', __METHOD__));
$validProtocols = config('firefly.valid_url_protocols');
return [
// basic fields for group:
'group_title' => 'min:1|max:1000|nullable',
'apply_rules' => [new IsBoolean()],
// transaction rules (in array for splits):
'transactions.*.type' => 'in:withdrawal,deposit,transfer,opening-balance,reconciliation',
'transactions.*.date' => [new IsDateOrTime()],
'transactions.*.order' => 'numeric|min:0',
// group id:
'transactions.*.transaction_journal_id' => ['nullable', 'numeric', new BelongsUser()],
// currency info
'transactions.*.currency_id' => 'numeric|exists:transaction_currencies,id|nullable',
'transactions.*.currency_code' => 'min:3|max:51|exists:transaction_currencies,code|nullable',
'transactions.*.foreign_currency_id' => 'nullable|numeric|exists:transaction_currencies,id',
'transactions.*.foreign_currency_code' => 'nullable|min:3|max:51|exists:transaction_currencies,code',
// amount
'transactions.*.amount' => [new IsValidPositiveAmount()],
'transactions.*.foreign_amount' => ['nullable', new IsValidZeroOrMoreAmount()],
// description
'transactions.*.description' => 'nullable|min:1|max:1000',
// source of transaction
'transactions.*.source_id' => ['numeric', 'nullable', new BelongsUser()],
'transactions.*.source_name' => 'min:1|max:255|nullable',
// destination of transaction
'transactions.*.destination_id' => ['numeric', 'nullable', new BelongsUser()],
'transactions.*.destination_name' => 'min:1|max:255|nullable',
// budget, category, bill and piggy
'transactions.*.budget_id' => ['mustExist:budgets,id', new BelongsUser(), 'nullable'],
'transactions.*.budget_name' => ['min:1', 'max:255', 'nullable', new BelongsUser()],
'transactions.*.category_id' => ['mustExist:categories,id', new BelongsUser(), 'nullable'],
'transactions.*.category_name' => 'min:1|max:255|nullable',
'transactions.*.bill_id' => ['numeric', 'nullable', 'mustExist:bills,id', new BelongsUser()],
'transactions.*.bill_name' => ['min:1', 'max:255', 'nullable', new BelongsUser()],
// other interesting fields
'transactions.*.reconciled' => [new IsBoolean()],
'transactions.*.notes' => 'min:1|max:32768|nullable',
'transactions.*.tags' => 'min:0|max:255|nullable',
'transactions.*.tags.*' => 'min:0|max:255',
// meta info fields
'transactions.*.internal_reference' => 'min:1|max:255|nullable',
'transactions.*.external_id' => 'min:1|max:255|nullable',
'transactions.*.recurrence_id' => 'min:1|max:255|nullable',
'transactions.*.bunq_payment_id' => 'min:1|max:255|nullable',
'transactions.*.external_url' => sprintf('min:1|max:255|nullable|url:%s', $validProtocols),
// SEPA fields:
'transactions.*.sepa_cc' => 'min:1|max:255|nullable',
'transactions.*.sepa_ct_op' => 'min:1|max:255|nullable',
'transactions.*.sepa_ct_id' => 'min:1|max:255|nullable',
'transactions.*.sepa_db' => 'min:1|max:255|nullable',
'transactions.*.sepa_country' => 'min:1|max:255|nullable',
'transactions.*.sepa_ep' => 'min:1|max:255|nullable',
'transactions.*.sepa_ci' => 'min:1|max:255|nullable',
'transactions.*.sepa_batch_id' => 'min:1|max:255|nullable',
// dates
'transactions.*.interest_date' => 'date|nullable',
'transactions.*.book_date' => 'date|nullable',
'transactions.*.process_date' => 'date|nullable',
'transactions.*.due_date' => 'date|nullable',
'transactions.*.payment_date' => 'date|nullable',
'transactions.*.invoice_date' => 'date|nullable',
];
}
/**
* Configure the validator instance.
*/
public function withValidator(Validator $validator): void
{
app('log')->debug('Now in withValidator');
/** @var TransactionGroup $transactionGroup */
$transactionGroup = $this->route()->parameter('transactionGroup');
$validator->after(
function (Validator $validator) use ($transactionGroup): void {
// if more than one, verify that there are journal ID's present.
$this->validateJournalIds($validator, $transactionGroup);
// all transaction types must be equal:
$this->validateTransactionTypesForUpdate($validator);
// user wants to update a reconciled transaction.
// source, destination, amount + foreign_amount cannot be changed
// and must be omitted from the request.
$this->preventUpdateReconciled($validator, $transactionGroup);
// validate source/destination is equal, depending on the transaction journal type.
$this->validateEqualAccountsForUpdate($validator, $transactionGroup);
// see method:
// $this->preventNoAccountInfo($validator, );
// validate that the currency fits the source and/or destination account.
// validate all account info
$this->validateAccountInformationUpdate($validator, $transactionGroup);
}
);
if ($validator->fails()) {
Log::channel('audit')->error(sprintf('Validation errors in %s', __CLASS__), $validator->errors()->toArray());
}
}
}

View File

@@ -66,10 +66,10 @@ class StoreRequest extends FormRequest
public function rules(): array
{
return [
'name' => 'required|between:1,255|unique:transaction_currencies,name',
'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:12',
'name' => 'required|min:1|max:255|unique:transaction_currencies,name',
'code' => 'required|min:3|max:32|unique:transaction_currencies,code',
'symbol' => 'required|min:1|max:32|unique:transaction_currencies,symbol',
'decimal_places' => 'numeric|min:0|max:12',
'enabled' => [new IsBoolean()],
'default' => [new IsBoolean()],
];

View File

@@ -42,7 +42,7 @@ class UpdateRequest extends FormRequest
*/
public function getAll(): array
{
// return nothing that isn't explicitely in the array:
// return nothing that isn't explicitly in the array:
$fields = [
'name' => ['name', 'convertString'],
'code' => ['code', 'convertString'],
@@ -64,10 +64,10 @@ class UpdateRequest extends FormRequest
$currency = $this->route()->parameter('currency_code');
return [
'name' => sprintf('between:1,255|unique:transaction_currencies,name,%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:12',
'name' => sprintf('min:1|max:255|unique:transaction_currencies,name,%d', $currency->id),
'code' => sprintf('min:3|max:32|unique:transaction_currencies,code,%d', $currency->id),
'symbol' => sprintf('min:1|max:32|unique:transaction_currencies,symbol,%d', $currency->id),
'decimal_places' => 'numeric|min:0|max:12',
'enabled' => [new IsBoolean()],
'default' => [new IsBoolean()],
];

View File

@@ -29,6 +29,7 @@ use FireflyIII\Support\Request\ChecksLogin;
use FireflyIII\Support\Request\ConvertsDataTypes;
use FireflyIII\User;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Support\Facades\Log;
use Illuminate\Validation\Validator;
/**
@@ -63,7 +64,7 @@ class StoreRequest extends FormRequest
'link_type_name' => 'exists:link_types,name|required_without:link_type_id',
'inward_id' => 'required|belongsToUser:transaction_journals,id|different:outward_id',
'outward_id' => 'required|belongsToUser:transaction_journals,id|different:inward_id',
'notes' => 'between:0,65000',
'notes' => 'min:1|max:32768|nullable',
];
}
@@ -77,6 +78,9 @@ class StoreRequest extends FormRequest
$this->validateExistingLink($validator);
}
);
if ($validator->fails()) {
Log::channel('audit')->error(sprintf('Validation errors in %s', __CLASS__), $validator->errors()->toArray());
}
}
private function validateExistingLink(Validator $validator): void

View File

@@ -29,6 +29,7 @@ use FireflyIII\Repositories\LinkType\LinkTypeRepositoryInterface;
use FireflyIII\Support\Request\ChecksLogin;
use FireflyIII\Support\Request\ConvertsDataTypes;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Support\Facades\Log;
use Illuminate\Validation\Validator;
/**
@@ -63,7 +64,7 @@ class UpdateRequest extends FormRequest
'link_type_name' => 'exists:link_types,name',
'inward_id' => 'belongsToUser:transaction_journals,id|different:outward_id',
'outward_id' => 'belongsToUser:transaction_journals,id|different:inward_id',
'notes' => 'between:0,65000',
'notes' => 'min:1|max:32768|nullable',
];
}
@@ -77,6 +78,9 @@ class UpdateRequest extends FormRequest
$this->validateUpdate($validator);
}
);
if ($validator->fails()) {
Log::channel('audit')->error(sprintf('Validation errors in %s', __CLASS__), $validator->errors()->toArray());
}
}
private function validateUpdate(Validator $validator): void

View File

@@ -72,7 +72,7 @@ class CreateRequest extends FormRequest
$validProtocols = config('firefly.valid_url_protocols');
return [
'title' => 'required|between:1,512|uniqueObjectForUser:webhooks,title',
'title' => 'required|min:1|max:255|uniqueObjectForUser:webhooks,title',
'active' => [new IsBoolean()],
'trigger' => sprintf('required|in:%s', $triggers),
'response' => sprintf('required|in:%s', $responses),

View File

@@ -85,7 +85,7 @@ class UpdateRequest extends FormRequest
$webhook = $this->route()->parameter('webhook');
return [
'title' => sprintf('between:1,512|uniqueObjectForUser:webhooks,title,%d', $webhook->id),
'title' => sprintf('min:1|max:255|uniqueObjectForUser:webhooks,title,%d', $webhook->id),
'active' => [new IsBoolean()],
'trigger' => sprintf('in:%s', $triggers),
'response' => sprintf('in:%s', $responses),

View File

@@ -65,7 +65,7 @@ class UpdateRequest extends FormRequest
return ['value' => ['required', new IsBoolean()]];
}
if ('configuration.permission_update_check' === $name) {
return ['value' => 'required|numeric|between:-1,1'];
return ['value' => 'required|numeric|min:-1|max:1'];
}
if ('configuration.last_update_check' === $name) {
return ['value' => 'required|numeric|min:464272080'];

View File

@@ -29,6 +29,7 @@ use FireflyIII\Support\Request\ChecksLogin;
use FireflyIII\Support\Request\ConvertsDataTypes;
use FireflyIII\User;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Support\Facades\Log;
use Illuminate\Validation\Validator;
/**
@@ -97,5 +98,8 @@ class UserUpdateRequest extends FormRequest
}
}
);
if ($validator->fails()) {
Log::channel('audit')->error(sprintf('Validation errors in %s', __CLASS__), $validator->errors()->toArray());
}
}
}

View File

@@ -72,7 +72,7 @@ class CategoryController extends Controller
$filtered = $result->map(
static function (Category $item) {
return [
'id' => (string) $item->id,
'id' => (string)$item->id,
'name' => $item->name,
];
}

View File

@@ -72,10 +72,10 @@ class TagController extends Controller
$filtered = $result->map(
static function (Tag $item) {
return [
'id' => (string) $item->id,
'name' => $item->tag,
'value' => (string) $item->id,
'label' => $item->tag,
'id' => (string)$item->id,
'name' => $item->tag,
'value' => (string)$item->id,
'label' => $item->tag,
];
}
);

View File

@@ -126,23 +126,23 @@ class AccountController extends Controller
$currency = $default;
}
$currentSet = [
'label' => $account->name,
'label' => $account->name,
// the currency that belongs to the account.
'currency_id' => (string)$currency->id,
'currency_code' => $currency->code,
'currency_symbol' => $currency->symbol,
'currency_decimal_places' => $currency->decimal_places,
'currency_id' => (string)$currency->id,
'currency_code' => $currency->code,
'currency_symbol' => $currency->symbol,
'currency_decimal_places' => $currency->decimal_places,
// the default currency of the user (could be the same!)
'native_currency_id' => (string)$default->id,
'native_currency_code' => $default->code,
'native_currency_symbol' => $default->symbol,
'native_currency_decimal_places' => $default->decimal_places,
'start' => $start->toAtomString(),
'end' => $end->toAtomString(),
'period' => '1D',
'entries' => [],
'native_entries' => [],
'native_currency_id' => (string)$default->id,
'native_currency_code' => $default->code,
'native_currency_symbol' => $default->symbol,
'native_currency_decimal_places' => $default->decimal_places,
'start' => $start->toAtomString(),
'end' => $end->toAtomString(),
'period' => '1D',
'entries' => [],
'native_entries' => [],
];
$currentStart = clone $start;
$range = app('steam')->balanceInRange($account, $start, clone $end, $currency);

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