@tomei/finance 0.17.0 → 0.18.1-dev.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.commitlintrc.json +23 -23
- package/CHANGELOG.md +17 -0
- package/LICENSE +21 -21
- package/MIGRATION.md +43 -0
- package/configs/config.js +348 -348
- package/dist/document/document.d.ts +3 -0
- package/dist/document/document.d.ts.map +1 -1
- package/dist/document/document.js +5 -0
- package/dist/document/document.js.map +1 -1
- package/dist/document/interfaces/document-attr.interface.d.ts +3 -1
- package/dist/document/interfaces/document-attr.interface.d.ts.map +1 -1
- package/dist/document/interfaces/document-attr.interface.js.map +1 -1
- package/dist/enum/index.d.ts +2 -1
- package/dist/enum/index.d.ts.map +1 -1
- package/dist/enum/index.js +3 -1
- package/dist/enum/index.js.map +1 -1
- package/dist/enum/posting-status.enum.d.ts +7 -0
- package/dist/enum/posting-status.enum.d.ts.map +1 -0
- package/dist/enum/posting-status.enum.js +11 -0
- package/dist/enum/posting-status.enum.js.map +1 -0
- package/dist/finance-company/finance-company.d.ts +6 -2
- package/dist/finance-company/finance-company.d.ts.map +1 -1
- package/dist/finance-company/finance-company.js +48 -16
- package/dist/finance-company/finance-company.js.map +1 -1
- package/dist/index.d.ts +3 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +5 -1
- package/dist/index.js.map +1 -1
- package/dist/models/document.entity.d.ts +3 -0
- package/dist/models/document.entity.d.ts.map +1 -1
- package/dist/models/document.entity.js +20 -0
- package/dist/models/document.entity.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/invoice-template/assets/css/style.css.map +12 -12
- package/invoice-template/assets/css/style.min.css +1 -1
- package/invoice-template/assets/img/arrow_bg.svg +11 -11
- package/invoice-template/assets/img/coffy_shop_img.svg +18 -18
- package/invoice-template/assets/img/logo_accent.svg +3 -3
- package/invoice-template/assets/img/logo_white.svg +4 -4
- package/invoice-template/assets/img/sign.svg +12 -12
- package/invoice-template/assets/img/tomei-logo.svg +9 -9
- package/invoice-template/assets/js/html2canvas.min.js +10379 -10379
- package/invoice-template/assets/js/jquery.min.js +1 -1
- package/invoice-template/assets/sass/common/_color_variable.scss +12 -12
- package/invoice-template/assets/sass/common/_typography.scss +178 -178
- package/invoice-template/assets/sass/style.scss +12 -12
- package/migrations/add-discount-collumn-to-document-related-table.js +90 -90
- package/migrations/finance-account-migration.js +97 -97
- package/migrations/finance-company-migration.js +29 -29
- package/migrations/finance-customer-migration.js +51 -51
- package/migrations/finance-document-item-migration.js +111 -111
- package/migrations/finance-document-migration.js +122 -122
- package/migrations/finance-document-tag-migration.js +46 -46
- package/migrations/finance-journal-entry-migration.js +59 -59
- package/migrations/finance-ledger-transaction-migration.js +89 -89
- package/migrations/finance-payment-item-migration.js +52 -52
- package/migrations/finance-payment-method-migration.js +31 -31
- package/migrations/finance-payment-method-type-migration.js +55 -55
- package/migrations/finance-payment-migration.js +96 -96
- package/migrations/finance-post-history-migration.js +45 -45
- package/migrations/finance-tag-group-migration.js +53 -53
- package/migrations/finance-tag-migration.js +63 -63
- package/migrations/finance-tax-migration.js +52 -52
- package/migrations/refactor-finance-document-migration.js +71 -71
- package/migrations/update-document-item.migration.js +87 -87
- package/package.json +81 -79
- package/receipt-template/default/assets/css/style.css +2629 -2629
- package/receipt-template/default/assets/css/style.css.map +12 -12
- package/receipt-template/default/assets/css/style.min.css +1 -1
- package/receipt-template/default/assets/img/arrow_bg.svg +11 -11
- package/receipt-template/default/assets/img/coffy_shop_img.svg +18 -18
- package/receipt-template/default/assets/img/logo.svg +4 -4
- package/receipt-template/default/assets/img/logo_accent.svg +3 -3
- package/receipt-template/default/assets/img/logo_white.svg +4 -4
- package/receipt-template/default/assets/img/sign.svg +12 -12
- package/receipt-template/default/assets/img/tomei-logo.svg +9 -9
- package/receipt-template/default/assets/js/html2canvas.min.js +10379 -10379
- package/receipt-template/default/assets/js/jquery.min.js +1 -1
- package/receipt-template/default/assets/js/main.js +48 -48
- package/receipt-template/default/assets/sass/common/_color_variable.scss +12 -12
- package/receipt-template/default/assets/sass/common/_invoice.scss +1801 -1801
- package/receipt-template/default/assets/sass/common/_normalize.scss +350 -350
- package/receipt-template/default/assets/sass/common/_typography.scss +178 -178
- package/receipt-template/default/assets/sass/style.scss +12 -12
- package/receipt-template/default/index.html +291 -291
- package/scripts/postinstall.js +300 -300
- package/dist/enum/quick-book-client-scopes.enum.d.ts +0 -13
- package/dist/enum/quick-book-client-scopes.enum.js +0 -19
- package/dist/enum/quick-book-client-scopes.enum.js.map +0 -1
package/.commitlintrc.json
CHANGED
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
{
|
|
2
|
-
"extends": [
|
|
3
|
-
"@commitlint/config-conventional"
|
|
4
|
-
],
|
|
5
|
-
"rules": {
|
|
6
|
-
"header-max-length": [ 2, "always", 120 ],
|
|
7
|
-
"type-enum": [
|
|
8
|
-
2,
|
|
9
|
-
"always",
|
|
10
|
-
[
|
|
11
|
-
"breaking",
|
|
12
|
-
"feat",
|
|
13
|
-
"fix",
|
|
14
|
-
"refactor",
|
|
15
|
-
"config",
|
|
16
|
-
"test",
|
|
17
|
-
"docs",
|
|
18
|
-
"chore",
|
|
19
|
-
"release"
|
|
20
|
-
]
|
|
21
|
-
]
|
|
22
|
-
}
|
|
23
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"extends": [
|
|
3
|
+
"@commitlint/config-conventional"
|
|
4
|
+
],
|
|
5
|
+
"rules": {
|
|
6
|
+
"header-max-length": [ 2, "always", 120 ],
|
|
7
|
+
"type-enum": [
|
|
8
|
+
2,
|
|
9
|
+
"always",
|
|
10
|
+
[
|
|
11
|
+
"breaking",
|
|
12
|
+
"feat",
|
|
13
|
+
"fix",
|
|
14
|
+
"refactor",
|
|
15
|
+
"config",
|
|
16
|
+
"test",
|
|
17
|
+
"docs",
|
|
18
|
+
"chore",
|
|
19
|
+
"release"
|
|
20
|
+
]
|
|
21
|
+
]
|
|
22
|
+
}
|
|
23
|
+
}
|
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
## [0.16.0] - 2026-02-XX
|
|
2
|
+
|
|
3
|
+
### Added
|
|
4
|
+
- Optional asynchronous invoice posting mode (`ASYNC_OUTBOX`)
|
|
5
|
+
- Invoice lifecycle states to track accounting system synchronization
|
|
6
|
+
- Support for deferred posting to external accounting systems
|
|
7
|
+
|
|
8
|
+
### Changed
|
|
9
|
+
- `issueInvoice()` now supports an opt-in asynchronous posting mode
|
|
10
|
+
- Accounting system integration can be executed outside database transactions
|
|
11
|
+
|
|
12
|
+
### Backward Compatibility
|
|
13
|
+
- Default behavior remains synchronous (`SYNC_LEGACY`)
|
|
14
|
+
- Existing consumers are not affected unless explicitly opted in
|
|
15
|
+
|
|
16
|
+
### Notes
|
|
17
|
+
- Synchronous posting mode will be deprecated in a future `1.0.0` release
|
package/LICENSE
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2019 John Biundo
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2019 John Biundo
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/MIGRATION.md
ADDED
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
# Migration Guide
|
|
2
|
+
|
|
3
|
+
This document describes breaking or opt-in changes introduced in each version
|
|
4
|
+
and how to migrate existing consumers.
|
|
5
|
+
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
## Migration to 0.16.0 — Async Invoice Posting
|
|
9
|
+
|
|
10
|
+
### Summary
|
|
11
|
+
Invoices can now be issued without synchronously posting to external accounting
|
|
12
|
+
systems.
|
|
13
|
+
|
|
14
|
+
## Who should migrate
|
|
15
|
+
Projects that integrate with external accounting systems and require improved
|
|
16
|
+
transaction safety and retry capability.
|
|
17
|
+
|
|
18
|
+
## How to opt in
|
|
19
|
+
|
|
20
|
+
```ts
|
|
21
|
+
await financeCompany.issueInvoice(
|
|
22
|
+
tx,
|
|
23
|
+
invoice,
|
|
24
|
+
loginUser,
|
|
25
|
+
customer,
|
|
26
|
+
undefined,
|
|
27
|
+
tags,
|
|
28
|
+
discount,
|
|
29
|
+
{
|
|
30
|
+
postingMode: 'ASYNC_OUTBOX',
|
|
31
|
+
}
|
|
32
|
+
);
|
|
33
|
+
|
|
34
|
+
## Required Setup
|
|
35
|
+
- Background worker to process outbox events
|
|
36
|
+
- Accounting integration worker enabled
|
|
37
|
+
|
|
38
|
+
## Invoice Status Flow
|
|
39
|
+
ISSUED -> POSTING -> POSTED/POST_FAILED
|
|
40
|
+
|
|
41
|
+
## Rollback Behaviour
|
|
42
|
+
- Local database failures rollback safely
|
|
43
|
+
- Accounting system failures do not corrupt local state
|