@things-factory/accounting 7.0.6 → 7.1.3
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/client/activities/activity-book-edit.ts +1 -1
- package/client/activities/activity-book-view.ts +1 -1
- package/client/activities/activity-expense-edit.ts +1 -1
- package/client/activities/activity-expense-view.ts +1 -1
- package/client/bootstrap.ts +10 -1
- package/client/components/accounting-category-selector.ts +136 -0
- package/client/components/accounting-category-view.ts +75 -0
- package/client/grist-editors/grist-editor-accounting-category-object.ts +83 -0
- package/client/grist-editors/grist-renderer-accounting-category-object.ts +13 -0
- package/client/pages/account/account-importer.ts +19 -8
- package/client/pages/account/account-list-page.ts +38 -8
- package/client/pages/accounting-category/accounting-category-importer.ts +19 -8
- package/client/pages/accounting-category/accounting-category-list-page.ts +36 -6
- package/client/pages/accounting-category/accounting-category-tree-page.ts +338 -0
- package/client/pages/accounting-document/accounting-document-importer.ts +90 -0
- package/client/pages/accounting-document/accounting-document-list-page.ts +398 -0
- package/client/pages/financial-statement/financial-statement-importer.ts +19 -8
- package/client/pages/financial-statement/financial-statement-list-page.ts +5 -6
- package/client/pages/fiscal-month/fiscal-month-importer.ts +90 -0
- package/client/pages/fiscal-month/fiscal-month-list-page.ts +398 -0
- package/client/pages/fiscal-quarter/fiscal-quarter-importer.ts +90 -0
- package/client/pages/fiscal-quarter/fiscal-quarter-list-page.ts +398 -0
- package/client/pages/fiscal-year/fiscal-year-importer.ts +90 -0
- package/client/pages/fiscal-year/fiscal-year-list-page.ts +398 -0
- package/client/pages/income-statement/income-statement-importer.ts +19 -8
- package/client/pages/income-statement/income-statement-list-page.ts +5 -6
- package/client/pages/{ledger/ledger-importer.ts → payment/payment-importer.ts} +13 -9
- package/client/pages/{ledger/ledger-list-page.ts → payment/payment-list-page.ts} +118 -58
- package/client/pages/transaction/transaction-importer.ts +19 -8
- package/client/pages/transaction/transaction-list-page.ts +5 -6
- package/client/route.ts +16 -8
- package/client/types/accounting-category.ts +23 -0
- package/client/types/index.ts +1 -0
- package/dist-client/activities/activity-book-edit.js +1 -1
- package/dist-client/activities/activity-book-edit.js.map +1 -1
- package/dist-client/activities/activity-book-view.js +1 -1
- package/dist-client/activities/activity-book-view.js.map +1 -1
- package/dist-client/activities/activity-expense-edit.js +1 -1
- package/dist-client/activities/activity-expense-edit.js.map +1 -1
- package/dist-client/activities/activity-expense-view.js +1 -1
- package/dist-client/activities/activity-expense-view.js.map +1 -1
- package/dist-client/bootstrap.js +7 -1
- package/dist-client/bootstrap.js.map +1 -1
- package/dist-client/components/accounting-category-selector.d.ts +16 -0
- package/dist-client/components/accounting-category-selector.js +134 -0
- package/dist-client/components/accounting-category-selector.js.map +1 -0
- package/dist-client/components/accounting-category-view.d.ts +14 -0
- package/dist-client/components/accounting-category-view.js +81 -0
- package/dist-client/components/accounting-category-view.js.map +1 -0
- package/dist-client/grist-editors/grist-editor-accounting-category-object.d.ts +11 -0
- package/dist-client/grist-editors/grist-editor-accounting-category-object.js +71 -0
- package/dist-client/grist-editors/grist-editor-accounting-category-object.js.map +1 -0
- package/dist-client/grist-editors/grist-renderer-accounting-category-object.d.ts +2 -0
- package/dist-client/grist-editors/grist-renderer-accounting-category-object.js +9 -0
- package/dist-client/grist-editors/grist-renderer-accounting-category-object.js.map +1 -0
- package/dist-client/pages/account/account-importer.d.ts +0 -1
- package/dist-client/pages/account/account-importer.js +12 -5
- package/dist-client/pages/account/account-importer.js.map +1 -1
- package/dist-client/pages/account/account-list-page.js +38 -8
- package/dist-client/pages/account/account-list-page.js.map +1 -1
- package/dist-client/pages/accounting-category/accounting-category-importer.d.ts +0 -1
- package/dist-client/pages/accounting-category/accounting-category-importer.js +12 -5
- package/dist-client/pages/accounting-category/accounting-category-importer.js.map +1 -1
- package/dist-client/pages/accounting-category/accounting-category-list-page.js +36 -6
- package/dist-client/pages/accounting-category/accounting-category-list-page.js.map +1 -1
- package/dist-client/pages/accounting-category/accounting-category-tree-page.d.ts +46 -0
- package/dist-client/pages/accounting-category/accounting-category-tree-page.js +329 -0
- package/dist-client/pages/accounting-category/accounting-category-tree-page.js.map +1 -0
- package/dist-client/pages/accounting-document/accounting-document-importer.d.ts +23 -0
- package/dist-client/pages/accounting-document/accounting-document-importer.js +93 -0
- package/dist-client/pages/accounting-document/accounting-document-importer.js.map +1 -0
- package/dist-client/pages/accounting-document/accounting-document-list-page.d.ts +66 -0
- package/dist-client/pages/accounting-document/accounting-document-list-page.js +370 -0
- package/dist-client/pages/accounting-document/accounting-document-list-page.js.map +1 -0
- package/dist-client/pages/financial-statement/financial-statement-importer.d.ts +0 -1
- package/dist-client/pages/financial-statement/financial-statement-importer.js +12 -5
- package/dist-client/pages/financial-statement/financial-statement-importer.js.map +1 -1
- package/dist-client/pages/financial-statement/financial-statement-list-page.js +5 -6
- package/dist-client/pages/financial-statement/financial-statement-list-page.js.map +1 -1
- package/dist-client/pages/fiscal-month/fiscal-month-importer.d.ts +23 -0
- package/dist-client/pages/fiscal-month/fiscal-month-importer.js +93 -0
- package/dist-client/pages/fiscal-month/fiscal-month-importer.js.map +1 -0
- package/dist-client/pages/fiscal-month/fiscal-month-list-page.d.ts +66 -0
- package/dist-client/pages/fiscal-month/fiscal-month-list-page.js +370 -0
- package/dist-client/pages/fiscal-month/fiscal-month-list-page.js.map +1 -0
- package/dist-client/pages/fiscal-quarter/fiscal-quarter-importer.d.ts +23 -0
- package/dist-client/pages/fiscal-quarter/fiscal-quarter-importer.js +93 -0
- package/dist-client/pages/fiscal-quarter/fiscal-quarter-importer.js.map +1 -0
- package/dist-client/pages/fiscal-quarter/fiscal-quarter-list-page.d.ts +66 -0
- package/dist-client/pages/fiscal-quarter/fiscal-quarter-list-page.js +370 -0
- package/dist-client/pages/fiscal-quarter/fiscal-quarter-list-page.js.map +1 -0
- package/dist-client/pages/fiscal-year/fiscal-year-importer.d.ts +23 -0
- package/dist-client/pages/fiscal-year/fiscal-year-importer.js +93 -0
- package/dist-client/pages/fiscal-year/fiscal-year-importer.js.map +1 -0
- package/dist-client/pages/fiscal-year/fiscal-year-list-page.d.ts +66 -0
- package/dist-client/pages/fiscal-year/fiscal-year-list-page.js +370 -0
- package/dist-client/pages/fiscal-year/fiscal-year-list-page.js.map +1 -0
- package/dist-client/pages/income-statement/income-statement-importer.d.ts +0 -1
- package/dist-client/pages/income-statement/income-statement-importer.js +12 -5
- package/dist-client/pages/income-statement/income-statement-importer.js.map +1 -1
- package/dist-client/pages/income-statement/income-statement-list-page.js +5 -6
- package/dist-client/pages/income-statement/income-statement-list-page.js.map +1 -1
- package/dist-client/pages/{ledger/ledger-importer.d.ts → payment/payment-importer.d.ts} +2 -2
- package/dist-client/pages/{ledger/ledger-importer.js → payment/payment-importer.js} +11 -11
- package/dist-client/pages/payment/payment-importer.js.map +1 -0
- package/dist-client/pages/{ledger/ledger-list-page.d.ts → payment/payment-list-page.d.ts} +12 -8
- package/dist-client/pages/{ledger/ledger-list-page.js → payment/payment-list-page.js} +114 -68
- package/dist-client/pages/payment/payment-list-page.js.map +1 -0
- package/dist-client/pages/transaction/transaction-importer.d.ts +0 -1
- package/dist-client/pages/transaction/transaction-importer.js +12 -5
- package/dist-client/pages/transaction/transaction-importer.js.map +1 -1
- package/dist-client/pages/transaction/transaction-list-page.js +5 -6
- package/dist-client/pages/transaction/transaction-list-page.js.map +1 -1
- package/dist-client/route.d.ts +1 -1
- package/dist-client/route.js +9 -3
- package/dist-client/route.js.map +1 -1
- package/dist-client/tsconfig.tsbuildinfo +1 -1
- package/dist-client/types/accounting-category.d.ts +16 -0
- package/dist-client/types/accounting-category.js +3 -0
- package/dist-client/types/accounting-category.js.map +1 -0
- package/dist-client/types/index.d.ts +1 -0
- package/dist-client/types/index.js +2 -0
- package/dist-client/types/index.js.map +1 -0
- package/dist-server/activities/activity-book.js +31 -19
- package/dist-server/activities/activity-book.js.map +1 -1
- package/dist-server/controllers/index.d.ts +1 -0
- package/dist-server/controllers/index.js +4 -0
- package/dist-server/controllers/index.js.map +1 -1
- package/dist-server/controllers/summary-statements.d.ts +4 -0
- package/dist-server/controllers/summary-statements.js +149 -0
- package/dist-server/controllers/summary-statements.js.map +1 -0
- package/dist-server/index.d.ts +2 -0
- package/dist-server/index.js +2 -0
- package/dist-server/index.js.map +1 -1
- package/dist-server/migrations/1725200507196-seed-fiscal-entities.d.ts +5 -0
- package/dist-server/migrations/1725200507196-seed-fiscal-entities.js +95 -0
- package/dist-server/migrations/1725200507196-seed-fiscal-entities.js.map +1 -0
- package/dist-server/migrations/1725201467183-seed-accounts.d.ts +5 -0
- package/dist-server/migrations/1725201467183-seed-accounts.js +318 -0
- package/dist-server/migrations/1725201467183-seed-accounts.js.map +1 -0
- package/dist-server/service/account/account-history.d.ts +4 -1
- package/dist-server/service/account/account-history.js +17 -7
- package/dist-server/service/account/account-history.js.map +1 -1
- package/dist-server/service/account/account-mutation.js +13 -9
- package/dist-server/service/account/account-mutation.js.map +1 -1
- package/dist-server/service/account/account-query.js +3 -1
- package/dist-server/service/account/account-query.js.map +1 -1
- package/dist-server/service/account/account.d.ts +1 -1
- package/dist-server/service/account/account.js +16 -5
- package/dist-server/service/account/account.js.map +1 -1
- package/dist-server/service/account/index.d.ts +1 -2
- package/dist-server/service/accounting-category/accounting-category-history.d.ts +26 -0
- package/dist-server/service/accounting-category/accounting-category-history.js +136 -0
- package/dist-server/service/accounting-category/accounting-category-history.js.map +1 -0
- package/dist-server/service/accounting-category/accounting-category-mutation.js +12 -8
- package/dist-server/service/accounting-category/accounting-category-mutation.js.map +1 -1
- package/dist-server/service/accounting-category/accounting-category-query.d.ts +1 -0
- package/dist-server/service/accounting-category/accounting-category-query.js +24 -1
- package/dist-server/service/accounting-category/accounting-category-query.js.map +1 -1
- package/dist-server/service/accounting-category/accounting-category-type.d.ts +2 -0
- package/dist-server/service/accounting-category/accounting-category-type.js +8 -0
- package/dist-server/service/accounting-category/accounting-category-type.js.map +1 -1
- package/dist-server/service/accounting-category/accounting-category.d.ts +2 -0
- package/dist-server/service/accounting-category/accounting-category.js +20 -3
- package/dist-server/service/accounting-category/accounting-category.js.map +1 -1
- package/dist-server/service/accounting-category/event-subscriber.d.ts +7 -0
- package/dist-server/service/accounting-category/event-subscriber.js +21 -0
- package/dist-server/service/accounting-category/event-subscriber.js.map +1 -0
- package/dist-server/service/accounting-category/index.d.ts +2 -1
- package/dist-server/service/accounting-category/index.js +4 -2
- package/dist-server/service/accounting-category/index.js.map +1 -1
- package/dist-server/service/accounting-document/accounting-document-history.d.ts +26 -0
- package/dist-server/service/accounting-document/accounting-document-history.js +129 -0
- package/dist-server/service/accounting-document/accounting-document-history.js.map +1 -0
- package/dist-server/service/accounting-document/accounting-document-mutation.d.ts +10 -0
- package/dist-server/service/accounting-document/accounting-document-mutation.js +128 -0
- package/dist-server/service/accounting-document/accounting-document-mutation.js.map +1 -0
- package/dist-server/service/accounting-document/accounting-document-query.d.ts +11 -0
- package/dist-server/service/accounting-document/accounting-document-query.js +79 -0
- package/dist-server/service/accounting-document/accounting-document-query.js.map +1 -0
- package/dist-server/service/accounting-document/accounting-document-type.d.ts +20 -0
- package/dist-server/service/accounting-document/accounting-document-type.js +74 -0
- package/dist-server/service/accounting-document/accounting-document-type.js.map +1 -0
- package/dist-server/service/accounting-document/accounting-document.d.ts +21 -0
- package/dist-server/service/accounting-document/accounting-document.js +104 -0
- package/dist-server/service/accounting-document/accounting-document.js.map +1 -0
- package/dist-server/service/accounting-document/event-subscriber.d.ts +7 -0
- package/dist-server/service/accounting-document/event-subscriber.js +21 -0
- package/dist-server/service/accounting-document/event-subscriber.js.map +1 -0
- package/dist-server/service/accounting-document/index.d.ts +7 -0
- package/dist-server/service/accounting-document/index.js +12 -0
- package/dist-server/service/accounting-document/index.js.map +1 -0
- package/dist-server/service/common-type.d.ts +5 -0
- package/dist-server/service/common-type.js +15 -0
- package/dist-server/service/common-type.js.map +1 -0
- package/dist-server/service/financial-statement/financial-statement-history.d.ts +9 -6
- package/dist-server/service/financial-statement/financial-statement-history.js +33 -23
- package/dist-server/service/financial-statement/financial-statement-history.js.map +1 -1
- package/dist-server/service/financial-statement/financial-statement-line-item.d.ts +19 -0
- package/dist-server/service/financial-statement/financial-statement-line-item.js +94 -0
- package/dist-server/service/financial-statement/financial-statement-line-item.js.map +1 -0
- package/dist-server/service/financial-statement/financial-statement-mutation.js +12 -8
- package/dist-server/service/financial-statement/financial-statement-mutation.js.map +1 -1
- package/dist-server/service/financial-statement/financial-statement-query.js +3 -1
- package/dist-server/service/financial-statement/financial-statement-query.js.map +1 -1
- package/dist-server/service/financial-statement/financial-statement.d.ts +2 -0
- package/dist-server/service/financial-statement/financial-statement.js +45 -24
- package/dist-server/service/financial-statement/financial-statement.js.map +1 -1
- package/dist-server/service/financial-statement/index.d.ts +2 -2
- package/dist-server/service/financial-statement/index.js +2 -1
- package/dist-server/service/financial-statement/index.js.map +1 -1
- package/dist-server/service/fiscal-month/fiscal-month-mutation.d.ts +10 -0
- package/dist-server/service/fiscal-month/fiscal-month-mutation.js +134 -0
- package/dist-server/service/fiscal-month/fiscal-month-mutation.js.map +1 -0
- package/dist-server/service/fiscal-month/fiscal-month-query.d.ts +11 -0
- package/dist-server/service/fiscal-month/fiscal-month-query.js +83 -0
- package/dist-server/service/fiscal-month/fiscal-month-query.js.map +1 -0
- package/dist-server/service/fiscal-month/fiscal-month-type.d.ts +26 -0
- package/dist-server/service/fiscal-month/fiscal-month-type.js +98 -0
- package/dist-server/service/fiscal-month/fiscal-month-type.js.map +1 -0
- package/dist-server/service/fiscal-month/fiscal-month.d.ts +22 -0
- package/dist-server/service/fiscal-month/fiscal-month.js +99 -0
- package/dist-server/service/fiscal-month/fiscal-month.js.map +1 -0
- package/dist-server/service/fiscal-month/index.d.ts +6 -0
- package/dist-server/service/fiscal-month/index.js +10 -0
- package/dist-server/service/fiscal-month/index.js.map +1 -0
- package/dist-server/service/fiscal-quarter/fiscal-quarter-mutation.d.ts +10 -0
- package/dist-server/service/fiscal-quarter/fiscal-quarter-mutation.js +134 -0
- package/dist-server/service/fiscal-quarter/fiscal-quarter-mutation.js.map +1 -0
- package/dist-server/service/fiscal-quarter/fiscal-quarter-query.d.ts +11 -0
- package/dist-server/service/fiscal-quarter/fiscal-quarter-query.js +85 -0
- package/dist-server/service/fiscal-quarter/fiscal-quarter-query.js.map +1 -0
- package/dist-server/service/fiscal-quarter/fiscal-quarter-type.d.ts +24 -0
- package/dist-server/service/fiscal-quarter/fiscal-quarter-type.js +90 -0
- package/dist-server/service/fiscal-quarter/fiscal-quarter-type.js.map +1 -0
- package/dist-server/service/fiscal-quarter/fiscal-quarter.d.ts +21 -0
- package/dist-server/service/fiscal-quarter/fiscal-quarter.js +94 -0
- package/dist-server/service/fiscal-quarter/fiscal-quarter.js.map +1 -0
- package/dist-server/service/fiscal-quarter/index.d.ts +6 -0
- package/dist-server/service/fiscal-quarter/index.js +10 -0
- package/dist-server/service/fiscal-quarter/index.js.map +1 -0
- package/dist-server/service/fiscal-year/fiscal-year-mutation.d.ts +10 -0
- package/dist-server/service/fiscal-year/fiscal-year-mutation.js +134 -0
- package/dist-server/service/fiscal-year/fiscal-year-mutation.js.map +1 -0
- package/dist-server/service/fiscal-year/fiscal-year-query.d.ts +11 -0
- package/dist-server/service/fiscal-year/fiscal-year-query.js +81 -0
- package/dist-server/service/fiscal-year/fiscal-year-query.js.map +1 -0
- package/dist-server/service/fiscal-year/fiscal-year-type.d.ts +22 -0
- package/dist-server/service/fiscal-year/fiscal-year-type.js +82 -0
- package/dist-server/service/fiscal-year/fiscal-year-type.js.map +1 -0
- package/dist-server/service/fiscal-year/fiscal-year.d.ts +20 -0
- package/dist-server/service/fiscal-year/fiscal-year.js +89 -0
- package/dist-server/service/fiscal-year/fiscal-year.js.map +1 -0
- package/dist-server/service/fiscal-year/index.d.ts +6 -0
- package/dist-server/service/fiscal-year/index.js +10 -0
- package/dist-server/service/fiscal-year/index.js.map +1 -0
- package/dist-server/service/income-statement/income-statement-history.d.ts +9 -5
- package/dist-server/service/income-statement/income-statement-history.js +38 -23
- package/dist-server/service/income-statement/income-statement-history.js.map +1 -1
- package/dist-server/service/income-statement/income-statement-line-item.d.ts +19 -0
- package/dist-server/service/income-statement/income-statement-line-item.js +96 -0
- package/dist-server/service/income-statement/income-statement-line-item.js.map +1 -0
- package/dist-server/service/income-statement/income-statement-mutation.js +12 -8
- package/dist-server/service/income-statement/income-statement-mutation.js.map +1 -1
- package/dist-server/service/income-statement/income-statement-query.js +3 -1
- package/dist-server/service/income-statement/income-statement-query.js.map +1 -1
- package/dist-server/service/income-statement/income-statement.d.ts +2 -0
- package/dist-server/service/income-statement/income-statement.js +46 -26
- package/dist-server/service/income-statement/income-statement.js.map +1 -1
- package/dist-server/service/income-statement/index.d.ts +2 -2
- package/dist-server/service/income-statement/index.js +2 -1
- package/dist-server/service/income-statement/index.js.map +1 -1
- package/dist-server/service/index.d.ts +7 -2
- package/dist-server/service/index.js +29 -3
- package/dist-server/service/index.js.map +1 -1
- package/dist-server/service/payment/event-subscriber.d.ts +7 -0
- package/dist-server/service/payment/event-subscriber.js +21 -0
- package/dist-server/service/payment/event-subscriber.js.map +1 -0
- package/dist-server/service/payment/index.d.ts +8 -0
- package/dist-server/service/payment/index.js +12 -0
- package/dist-server/service/payment/index.js.map +1 -0
- package/dist-server/service/payment/payment-history.d.ts +30 -0
- package/dist-server/service/payment/payment-history.js +143 -0
- package/dist-server/service/payment/payment-history.js.map +1 -0
- package/dist-server/service/payment/payment-mutation.d.ts +10 -0
- package/dist-server/service/payment/payment-mutation.js +134 -0
- package/dist-server/service/payment/payment-mutation.js.map +1 -0
- package/dist-server/service/payment/payment-query.d.ts +11 -0
- package/dist-server/service/payment/payment-query.js +81 -0
- package/dist-server/service/payment/payment-query.js.map +1 -0
- package/dist-server/service/payment/payment-type.d.ts +24 -0
- package/dist-server/service/payment/payment-type.js +90 -0
- package/dist-server/service/payment/payment-type.js.map +1 -0
- package/dist-server/service/payment/payment.d.ts +30 -0
- package/dist-server/service/payment/payment.js +146 -0
- package/dist-server/service/payment/payment.js.map +1 -0
- package/dist-server/service/transaction/transaction-history.d.ts +15 -3
- package/dist-server/service/transaction/transaction-history.js +64 -8
- package/dist-server/service/transaction/transaction-history.js.map +1 -1
- package/dist-server/service/transaction/transaction-mutation.js +13 -9
- package/dist-server/service/transaction/transaction-mutation.js.map +1 -1
- package/dist-server/service/transaction/transaction-query.js +3 -1
- package/dist-server/service/transaction/transaction-query.js.map +1 -1
- package/dist-server/service/transaction/transaction.d.ts +31 -6
- package/dist-server/service/transaction/transaction.js +138 -27
- package/dist-server/service/transaction/transaction.js.map +1 -1
- package/dist-server/tsconfig.tsbuildinfo +1 -1
- package/helps/accounting/accounting-document.md +160 -0
- package/helps/accounting/contract.md +160 -0
- package/helps/accounting/fiscal-month.md +160 -0
- package/helps/accounting/fiscal-quarter.md +160 -0
- package/helps/accounting/fiscal-year.md +160 -0
- package/helps/accounting/payment.md +160 -0
- package/package.json +9 -8
- package/server/activities/activity-book.ts +31 -19
- package/server/controllers/index.ts +1 -0
- package/server/controllers/summary-statements.ts +166 -0
- package/server/index.ts +2 -0
- package/server/migrations/1725200507196-seed-fiscal-entities.ts +106 -0
- package/server/migrations/1725201467183-seed-accounts.ts +339 -0
- package/server/service/account/account-history.ts +15 -7
- package/server/service/account/account-mutation.ts +13 -10
- package/server/service/account/account-query.ts +3 -1
- package/server/service/account/account.ts +16 -5
- package/server/service/accounting-category/accounting-category-history.ts +123 -0
- package/server/service/accounting-category/accounting-category-mutation.ts +12 -9
- package/server/service/accounting-category/accounting-category-query.ts +24 -1
- package/server/service/accounting-category/accounting-category-type.ts +6 -0
- package/server/service/accounting-category/accounting-category.ts +23 -3
- package/server/service/accounting-category/event-subscriber.ts +20 -0
- package/server/service/accounting-category/index.ts +4 -2
- package/server/service/accounting-document/accounting-document-history.ts +117 -0
- package/server/service/accounting-document/accounting-document-mutation.ts +137 -0
- package/server/service/accounting-document/accounting-document-query.ts +48 -0
- package/server/service/accounting-document/accounting-document-type.ts +52 -0
- package/server/service/accounting-document/accounting-document.ts +93 -0
- package/server/service/accounting-document/event-subscriber.ts +17 -0
- package/server/service/accounting-document/index.ts +9 -0
- package/server/service/common-type.ts +12 -0
- package/server/service/financial-statement/financial-statement-history.ts +28 -19
- package/server/service/financial-statement/financial-statement-line-item.ts +82 -0
- package/server/service/financial-statement/financial-statement-mutation.ts +12 -9
- package/server/service/financial-statement/financial-statement-query.ts +3 -1
- package/server/service/financial-statement/financial-statement.ts +52 -36
- package/server/service/financial-statement/index.ts +2 -1
- package/server/service/fiscal-month/fiscal-month-mutation.ts +145 -0
- package/server/service/fiscal-month/fiscal-month-query.ts +58 -0
- package/server/service/fiscal-month/fiscal-month-type.ts +66 -0
- package/server/service/fiscal-month/fiscal-month.ts +84 -0
- package/server/service/fiscal-month/index.ts +7 -0
- package/server/service/fiscal-quarter/fiscal-quarter-mutation.ts +148 -0
- package/server/service/fiscal-quarter/fiscal-quarter-query.ts +60 -0
- package/server/service/fiscal-quarter/fiscal-quarter-type.ts +60 -0
- package/server/service/fiscal-quarter/fiscal-quarter.ts +80 -0
- package/server/service/fiscal-quarter/index.ts +7 -0
- package/server/service/fiscal-year/fiscal-year-mutation.ts +145 -0
- package/server/service/fiscal-year/fiscal-year-query.ts +53 -0
- package/server/service/fiscal-year/fiscal-year-type.ts +54 -0
- package/server/service/fiscal-year/fiscal-year.ts +76 -0
- package/server/service/fiscal-year/index.ts +7 -0
- package/server/service/income-statement/income-statement-history.ts +31 -18
- package/server/service/income-statement/income-statement-line-item.ts +84 -0
- package/server/service/income-statement/income-statement-mutation.ts +12 -10
- package/server/service/income-statement/income-statement-query.ts +3 -4
- package/server/service/income-statement/income-statement.ts +54 -39
- package/server/service/income-statement/index.ts +2 -1
- package/server/service/index.ts +49 -3
- package/server/service/payment/event-subscriber.ts +17 -0
- package/server/service/payment/index.ts +9 -0
- package/server/service/payment/payment-history.ts +126 -0
- package/server/service/payment/payment-mutation.ts +139 -0
- package/server/service/payment/payment-query.ts +50 -0
- package/server/service/payment/payment-type.ts +64 -0
- package/server/service/payment/payment.ts +123 -0
- package/server/service/transaction/transaction-history.ts +54 -10
- package/server/service/transaction/transaction-mutation.ts +13 -10
- package/server/service/transaction/transaction-query.ts +3 -4
- package/server/service/transaction/transaction.ts +144 -29
- package/things-factory.config.js +3 -2
- package/translations/en.json +9 -1
- package/translations/ja.json +9 -1
- package/translations/ko.json +9 -1
- package/translations/ms.json +9 -1
- package/translations/zh.json +9 -1
- package/client/pages/main.ts +0 -24
- package/dist-client/pages/ledger/ledger-importer.js.map +0 -1
- package/dist-client/pages/ledger/ledger-list-page.js.map +0 -1
- package/dist-client/pages/main.d.ts +0 -1
- package/dist-client/pages/main.js +0 -27
- package/dist-client/pages/main.js.map +0 -1
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.AccountingDocumentList = exports.AccountingDocumentPatch = exports.NewAccountingDocument = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const type_graphql_1 = require("type-graphql");
|
|
6
|
+
const shell_1 = require("@things-factory/shell");
|
|
7
|
+
const accounting_document_1 = require("./accounting-document");
|
|
8
|
+
let NewAccountingDocument = class NewAccountingDocument {
|
|
9
|
+
};
|
|
10
|
+
exports.NewAccountingDocument = NewAccountingDocument;
|
|
11
|
+
tslib_1.__decorate([
|
|
12
|
+
(0, type_graphql_1.Field)(type => shell_1.ObjectRef),
|
|
13
|
+
tslib_1.__metadata("design:type", shell_1.ObjectRef)
|
|
14
|
+
], NewAccountingDocument.prototype, "transaction", void 0);
|
|
15
|
+
tslib_1.__decorate([
|
|
16
|
+
(0, type_graphql_1.Field)({ nullable: false }),
|
|
17
|
+
tslib_1.__metadata("design:type", String)
|
|
18
|
+
], NewAccountingDocument.prototype, "documentType", void 0);
|
|
19
|
+
tslib_1.__decorate([
|
|
20
|
+
(0, type_graphql_1.Field)({ nullable: false }),
|
|
21
|
+
tslib_1.__metadata("design:type", String)
|
|
22
|
+
], NewAccountingDocument.prototype, "documentUrl", void 0);
|
|
23
|
+
tslib_1.__decorate([
|
|
24
|
+
(0, type_graphql_1.Field)({ nullable: true }),
|
|
25
|
+
tslib_1.__metadata("design:type", String)
|
|
26
|
+
], NewAccountingDocument.prototype, "description", void 0);
|
|
27
|
+
exports.NewAccountingDocument = NewAccountingDocument = tslib_1.__decorate([
|
|
28
|
+
(0, type_graphql_1.InputType)()
|
|
29
|
+
], NewAccountingDocument);
|
|
30
|
+
let AccountingDocumentPatch = class AccountingDocumentPatch {
|
|
31
|
+
};
|
|
32
|
+
exports.AccountingDocumentPatch = AccountingDocumentPatch;
|
|
33
|
+
tslib_1.__decorate([
|
|
34
|
+
(0, type_graphql_1.Field)(type => type_graphql_1.ID, { nullable: true }),
|
|
35
|
+
tslib_1.__metadata("design:type", String)
|
|
36
|
+
], AccountingDocumentPatch.prototype, "id", void 0);
|
|
37
|
+
tslib_1.__decorate([
|
|
38
|
+
(0, type_graphql_1.Field)(type => shell_1.ObjectRef),
|
|
39
|
+
tslib_1.__metadata("design:type", shell_1.ObjectRef)
|
|
40
|
+
], AccountingDocumentPatch.prototype, "transaction", void 0);
|
|
41
|
+
tslib_1.__decorate([
|
|
42
|
+
(0, type_graphql_1.Field)({ nullable: false }),
|
|
43
|
+
tslib_1.__metadata("design:type", String)
|
|
44
|
+
], AccountingDocumentPatch.prototype, "documentType", void 0);
|
|
45
|
+
tslib_1.__decorate([
|
|
46
|
+
(0, type_graphql_1.Field)({ nullable: false }),
|
|
47
|
+
tslib_1.__metadata("design:type", String)
|
|
48
|
+
], AccountingDocumentPatch.prototype, "documentUrl", void 0);
|
|
49
|
+
tslib_1.__decorate([
|
|
50
|
+
(0, type_graphql_1.Field)({ nullable: true }),
|
|
51
|
+
tslib_1.__metadata("design:type", String)
|
|
52
|
+
], AccountingDocumentPatch.prototype, "description", void 0);
|
|
53
|
+
tslib_1.__decorate([
|
|
54
|
+
(0, type_graphql_1.Field)({ nullable: true }),
|
|
55
|
+
tslib_1.__metadata("design:type", String)
|
|
56
|
+
], AccountingDocumentPatch.prototype, "cuFlag", void 0);
|
|
57
|
+
exports.AccountingDocumentPatch = AccountingDocumentPatch = tslib_1.__decorate([
|
|
58
|
+
(0, type_graphql_1.InputType)()
|
|
59
|
+
], AccountingDocumentPatch);
|
|
60
|
+
let AccountingDocumentList = class AccountingDocumentList {
|
|
61
|
+
};
|
|
62
|
+
exports.AccountingDocumentList = AccountingDocumentList;
|
|
63
|
+
tslib_1.__decorate([
|
|
64
|
+
(0, type_graphql_1.Field)(type => [accounting_document_1.AccountingDocument]),
|
|
65
|
+
tslib_1.__metadata("design:type", Array)
|
|
66
|
+
], AccountingDocumentList.prototype, "items", void 0);
|
|
67
|
+
tslib_1.__decorate([
|
|
68
|
+
(0, type_graphql_1.Field)(type => type_graphql_1.Int),
|
|
69
|
+
tslib_1.__metadata("design:type", Number)
|
|
70
|
+
], AccountingDocumentList.prototype, "total", void 0);
|
|
71
|
+
exports.AccountingDocumentList = AccountingDocumentList = tslib_1.__decorate([
|
|
72
|
+
(0, type_graphql_1.ObjectType)()
|
|
73
|
+
], AccountingDocumentList);
|
|
74
|
+
//# sourceMappingURL=accounting-document-type.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"accounting-document-type.js","sourceRoot":"","sources":["../../../server/service/accounting-document/accounting-document-type.ts"],"names":[],"mappings":";;;;AAEA,+CAAsF;AAEtF,iDAA+D;AAE/D,+DAA0D;AAGnD,IAAM,qBAAqB,GAA3B,MAAM,qBAAqB;CAYjC,CAAA;AAZY,sDAAqB;AAEhC;IADC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,iBAAS,CAAC;sCACZ,iBAAS;0DAAA;AAGtB;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC;;2DACP;AAGpB;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC;;0DACR;AAGnB;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;0DACN;gCAXT,qBAAqB;IADjC,IAAA,wBAAS,GAAE;GACC,qBAAqB,CAYjC;AAGM,IAAM,uBAAuB,GAA7B,MAAM,uBAAuB;CAkBnC,CAAA;AAlBY,0DAAuB;AAElC;IADC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,iBAAE,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;mDAC3B;AAGX;IADC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,iBAAS,CAAC;sCACZ,iBAAS;4DAAA;AAGtB;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC;;6DACP;AAGpB;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC;;4DACR;AAGnB;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;4DACN;AAGpB;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;uDACX;kCAjBJ,uBAAuB;IADnC,IAAA,wBAAS,GAAE;GACC,uBAAuB,CAkBnC;AAGM,IAAM,sBAAsB,GAA5B,MAAM,sBAAsB;CAMlC,CAAA;AANY,wDAAsB;AAEjC;IADC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,CAAC,wCAAkB,CAAC,CAAC;;qDACT;AAG3B;IADC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,kBAAG,CAAC;;qDACN;iCALF,sBAAsB;IADlC,IAAA,yBAAU,GAAE;GACA,sBAAsB,CAMlC","sourcesContent":["import type { FileUpload } from 'graphql-upload/GraphQLUpload.js'\nimport GraphQLUpload from 'graphql-upload/GraphQLUpload.js'\nimport { ObjectType, Field, InputType, Int, ID, registerEnumType } from 'type-graphql'\n\nimport { ObjectRef, ScalarObject } from '@things-factory/shell'\n\nimport { AccountingDocument } from './accounting-document'\n\n@InputType()\nexport class NewAccountingDocument {\n @Field(type => ObjectRef)\n transaction: ObjectRef\n\n @Field({ nullable: false })\n documentType: string // 문서의 유형 (예: 계약서, 인보이스 등)\n\n @Field({ nullable: false })\n documentUrl: string // 문서의 URL 또는 파일 경로\n\n @Field({ nullable: true })\n description?: string // 문서에 대한 설명\n}\n\n@InputType()\nexport class AccountingDocumentPatch {\n @Field(type => ID, { nullable: true })\n id?: string\n\n @Field(type => ObjectRef)\n transaction: ObjectRef\n\n @Field({ nullable: false })\n documentType: string // 문서의 유형 (예: 계약서, 인보이스 등)\n\n @Field({ nullable: false })\n documentUrl: string // 문서의 URL 또는 파일 경로\n\n @Field({ nullable: true })\n description?: string // 문서에 대한 설명\n\n @Field({ nullable: true })\n cuFlag?: string\n}\n\n@ObjectType()\nexport class AccountingDocumentList {\n @Field(type => [AccountingDocument])\n items: AccountingDocument[]\n\n @Field(type => Int)\n total: number\n}\n"]}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Domain } from '@things-factory/shell';
|
|
2
|
+
import { User } from '@things-factory/auth-base';
|
|
3
|
+
import { Transaction } from '../transaction/transaction';
|
|
4
|
+
export declare class AccountingDocument {
|
|
5
|
+
readonly id: string;
|
|
6
|
+
version?: number;
|
|
7
|
+
domain?: Domain;
|
|
8
|
+
domainId?: string;
|
|
9
|
+
transaction: Transaction;
|
|
10
|
+
transactionId: string;
|
|
11
|
+
documentType: string;
|
|
12
|
+
documentUrl: string;
|
|
13
|
+
description?: string;
|
|
14
|
+
createdAt?: Date;
|
|
15
|
+
updatedAt?: Date;
|
|
16
|
+
deletedAt?: Date;
|
|
17
|
+
creator?: User;
|
|
18
|
+
creatorId?: string;
|
|
19
|
+
updater?: User;
|
|
20
|
+
updaterId?: string;
|
|
21
|
+
}
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.AccountingDocument = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const typeorm_1 = require("typeorm");
|
|
6
|
+
const type_graphql_1 = require("type-graphql");
|
|
7
|
+
const shell_1 = require("@things-factory/shell");
|
|
8
|
+
const auth_base_1 = require("@things-factory/auth-base");
|
|
9
|
+
const transaction_1 = require("../transaction/transaction");
|
|
10
|
+
let AccountingDocument = class AccountingDocument {
|
|
11
|
+
constructor() {
|
|
12
|
+
this.version = 1;
|
|
13
|
+
}
|
|
14
|
+
};
|
|
15
|
+
exports.AccountingDocument = AccountingDocument;
|
|
16
|
+
tslib_1.__decorate([
|
|
17
|
+
(0, typeorm_1.PrimaryGeneratedColumn)('uuid'),
|
|
18
|
+
(0, type_graphql_1.Field)(type => type_graphql_1.ID),
|
|
19
|
+
tslib_1.__metadata("design:type", String)
|
|
20
|
+
], AccountingDocument.prototype, "id", void 0);
|
|
21
|
+
tslib_1.__decorate([
|
|
22
|
+
(0, typeorm_1.VersionColumn)(),
|
|
23
|
+
(0, type_graphql_1.Field)({ nullable: true }),
|
|
24
|
+
tslib_1.__metadata("design:type", Number)
|
|
25
|
+
], AccountingDocument.prototype, "version", void 0);
|
|
26
|
+
tslib_1.__decorate([
|
|
27
|
+
(0, typeorm_1.ManyToOne)(type => shell_1.Domain),
|
|
28
|
+
(0, type_graphql_1.Field)({ nullable: true }),
|
|
29
|
+
tslib_1.__metadata("design:type", shell_1.Domain)
|
|
30
|
+
], AccountingDocument.prototype, "domain", void 0);
|
|
31
|
+
tslib_1.__decorate([
|
|
32
|
+
(0, typeorm_1.RelationId)((accountingDocument) => accountingDocument.domain),
|
|
33
|
+
tslib_1.__metadata("design:type", String)
|
|
34
|
+
], AccountingDocument.prototype, "domainId", void 0);
|
|
35
|
+
tslib_1.__decorate([
|
|
36
|
+
(0, typeorm_1.ManyToOne)(type => transaction_1.Transaction, transaction => transaction.documents),
|
|
37
|
+
(0, type_graphql_1.Field)(type => transaction_1.Transaction),
|
|
38
|
+
tslib_1.__metadata("design:type", transaction_1.Transaction)
|
|
39
|
+
], AccountingDocument.prototype, "transaction", void 0);
|
|
40
|
+
tslib_1.__decorate([
|
|
41
|
+
(0, typeorm_1.RelationId)((accountingDocument) => accountingDocument.transaction),
|
|
42
|
+
tslib_1.__metadata("design:type", String)
|
|
43
|
+
], AccountingDocument.prototype, "transactionId", void 0);
|
|
44
|
+
tslib_1.__decorate([
|
|
45
|
+
(0, typeorm_1.Column)(),
|
|
46
|
+
(0, type_graphql_1.Field)({ nullable: false }),
|
|
47
|
+
tslib_1.__metadata("design:type", String)
|
|
48
|
+
], AccountingDocument.prototype, "documentType", void 0);
|
|
49
|
+
tslib_1.__decorate([
|
|
50
|
+
(0, typeorm_1.Column)(),
|
|
51
|
+
(0, type_graphql_1.Field)({ nullable: false }),
|
|
52
|
+
tslib_1.__metadata("design:type", String)
|
|
53
|
+
], AccountingDocument.prototype, "documentUrl", void 0);
|
|
54
|
+
tslib_1.__decorate([
|
|
55
|
+
(0, typeorm_1.Column)({ nullable: true }),
|
|
56
|
+
(0, type_graphql_1.Field)({ nullable: true }),
|
|
57
|
+
tslib_1.__metadata("design:type", String)
|
|
58
|
+
], AccountingDocument.prototype, "description", void 0);
|
|
59
|
+
tslib_1.__decorate([
|
|
60
|
+
(0, typeorm_1.CreateDateColumn)(),
|
|
61
|
+
(0, type_graphql_1.Field)({ nullable: true }),
|
|
62
|
+
tslib_1.__metadata("design:type", Date)
|
|
63
|
+
], AccountingDocument.prototype, "createdAt", void 0);
|
|
64
|
+
tslib_1.__decorate([
|
|
65
|
+
(0, typeorm_1.UpdateDateColumn)(),
|
|
66
|
+
(0, type_graphql_1.Field)({ nullable: true }),
|
|
67
|
+
tslib_1.__metadata("design:type", Date)
|
|
68
|
+
], AccountingDocument.prototype, "updatedAt", void 0);
|
|
69
|
+
tslib_1.__decorate([
|
|
70
|
+
(0, typeorm_1.DeleteDateColumn)(),
|
|
71
|
+
(0, type_graphql_1.Field)({ nullable: true }),
|
|
72
|
+
tslib_1.__metadata("design:type", Date)
|
|
73
|
+
], AccountingDocument.prototype, "deletedAt", void 0);
|
|
74
|
+
tslib_1.__decorate([
|
|
75
|
+
(0, typeorm_1.ManyToOne)(type => auth_base_1.User, { nullable: true }),
|
|
76
|
+
(0, type_graphql_1.Field)(type => auth_base_1.User, { nullable: true }),
|
|
77
|
+
tslib_1.__metadata("design:type", auth_base_1.User)
|
|
78
|
+
], AccountingDocument.prototype, "creator", void 0);
|
|
79
|
+
tslib_1.__decorate([
|
|
80
|
+
(0, typeorm_1.RelationId)((accountingDocument) => accountingDocument.creator),
|
|
81
|
+
tslib_1.__metadata("design:type", String)
|
|
82
|
+
], AccountingDocument.prototype, "creatorId", void 0);
|
|
83
|
+
tslib_1.__decorate([
|
|
84
|
+
(0, typeorm_1.ManyToOne)(type => auth_base_1.User, { nullable: true }),
|
|
85
|
+
(0, type_graphql_1.Field)(type => auth_base_1.User, { nullable: true }),
|
|
86
|
+
tslib_1.__metadata("design:type", auth_base_1.User)
|
|
87
|
+
], AccountingDocument.prototype, "updater", void 0);
|
|
88
|
+
tslib_1.__decorate([
|
|
89
|
+
(0, typeorm_1.RelationId)((accountingDocument) => accountingDocument.updater),
|
|
90
|
+
tslib_1.__metadata("design:type", String)
|
|
91
|
+
], AccountingDocument.prototype, "updaterId", void 0);
|
|
92
|
+
exports.AccountingDocument = AccountingDocument = tslib_1.__decorate([
|
|
93
|
+
(0, type_graphql_1.ObjectType)({ description: 'Entity for AccountingDocument' }),
|
|
94
|
+
(0, typeorm_1.Entity)(),
|
|
95
|
+
(0, typeorm_1.Index)('ix_accounting_document_0', (accountingDocument) => [
|
|
96
|
+
accountingDocument.domain,
|
|
97
|
+
accountingDocument.transaction,
|
|
98
|
+
accountingDocument.createdAt
|
|
99
|
+
], {
|
|
100
|
+
unique: false,
|
|
101
|
+
where: '"deleted_at" IS NULL'
|
|
102
|
+
})
|
|
103
|
+
], AccountingDocument);
|
|
104
|
+
//# sourceMappingURL=accounting-document.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"accounting-document.js","sourceRoot":"","sources":["../../../server/service/accounting-document/accounting-document.ts"],"names":[],"mappings":";;;;AAAA,qCAWgB;AAChB,+CAAoD;AAEpD,iDAA8C;AAC9C,yDAAgD;AAChD,4DAAwD;AAgBjD,IAAM,kBAAkB,GAAxB,MAAM,kBAAkB;IAAxB;QAOL,YAAO,GAAY,CAAC,CAAA;IAqDtB,CAAC;CAAA,CAAA;AA5DY,gDAAkB;AAGpB;IAFR,IAAA,gCAAsB,EAAC,MAAM,CAAC;IAC9B,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,iBAAE,CAAC;;8CACC;AAInB;IAFC,IAAA,uBAAa,GAAE;IACf,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;mDACN;AAIpB;IAFC,IAAA,mBAAS,EAAC,IAAI,CAAC,EAAE,CAAC,cAAM,CAAC;IACzB,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;sCACjB,cAAM;kDAAA;AAGf;IADC,IAAA,oBAAU,EAAC,CAAC,kBAAsC,EAAE,EAAE,CAAC,kBAAkB,CAAC,MAAM,CAAC;;oDACjE;AAIjB;IAFC,IAAA,mBAAS,EAAC,IAAI,CAAC,EAAE,CAAC,yBAAW,EAAE,WAAW,CAAC,EAAE,CAAC,WAAW,CAAC,SAAS,CAAC;IACpE,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,yBAAW,CAAC;sCACd,yBAAW;uDAAA;AAGxB;IADC,IAAA,oBAAU,EAAC,CAAC,kBAAsC,EAAE,EAAE,CAAC,kBAAkB,CAAC,WAAW,CAAC;;yDAClE;AAIrB;IAFC,IAAA,gBAAM,GAAE;IACR,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC;;wDACP;AAIpB;IAFC,IAAA,gBAAM,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B;IAd9B,IAAA,yBAAU,EAAC,EAAE,WAAW,EAAE,+BAA+B,EAAE,CAAC;IAC5D,IAAA,gBAAM,GAAE;IACR,IAAA,eAAK,EACJ,0BAA0B,EAC1B,CAAC,kBAAsC,EAAE,EAAE,CAAC;QAC1C,kBAAkB,CAAC,MAAM;QACzB,kBAAkB,CAAC,WAAW;QAC9B,kBAAkB,CAAC,SAAS;KAC7B,EACD;QACE,MAAM,EAAE,KAAK;QACb,KAAK,EAAE,sBAAsB;KAC9B,CACF;GACY,kBAAkB,CA4D9B","sourcesContent":["import {\n CreateDateColumn,\n UpdateDateColumn,\n DeleteDateColumn,\n Entity,\n Index,\n Column,\n ManyToOne,\n PrimaryGeneratedColumn,\n RelationId,\n VersionColumn\n} from 'typeorm'\nimport { ObjectType, Field, ID } from 'type-graphql'\n\nimport { Domain } from '@things-factory/shell'\nimport { User } from '@things-factory/auth-base'\nimport { Transaction } from '../transaction/transaction'\n\n@ObjectType({ description: 'Entity for AccountingDocument' })\n@Entity()\n@Index(\n 'ix_accounting_document_0',\n (accountingDocument: AccountingDocument) => [\n accountingDocument.domain,\n accountingDocument.transaction,\n accountingDocument.createdAt\n ],\n {\n unique: false,\n where: '\"deleted_at\" IS NULL'\n }\n)\nexport class AccountingDocument {\n @PrimaryGeneratedColumn('uuid')\n @Field(type => ID)\n readonly id: string\n\n @VersionColumn()\n @Field({ nullable: true })\n version?: number = 1\n\n @ManyToOne(type => Domain)\n @Field({ nullable: true })\n domain?: Domain\n\n @RelationId((accountingDocument: AccountingDocument) => accountingDocument.domain)\n domainId?: string\n\n @ManyToOne(type => Transaction, transaction => transaction.documents)\n @Field(type => Transaction)\n transaction: Transaction\n\n @RelationId((accountingDocument: AccountingDocument) => accountingDocument.transaction)\n transactionId: string\n\n @Column()\n @Field({ nullable: false })\n documentType: string // 문서의 유형 (예: 계약서, 인보이스 등)\n\n @Column()\n @Field({ nullable: false })\n documentUrl: string // 문서의 URL 또는 파일 경로\n\n @Column({ nullable: true })\n @Field({ nullable: true })\n description?: string // 문서에 대한 설명\n\n @CreateDateColumn()\n @Field({ nullable: true })\n createdAt?: Date\n\n @UpdateDateColumn()\n @Field({ nullable: true })\n updatedAt?: Date\n\n @DeleteDateColumn()\n @Field({ nullable: true })\n deletedAt?: Date\n\n @ManyToOne(type => User, { nullable: true })\n @Field(type => User, { nullable: true })\n creator?: User\n\n @RelationId((accountingDocument: AccountingDocument) => accountingDocument.creator)\n creatorId?: string\n\n @ManyToOne(type => User, { nullable: true })\n @Field(type => User, { nullable: true })\n updater?: User\n\n @RelationId((accountingDocument: AccountingDocument) => accountingDocument.updater)\n updaterId?: string\n}\n"]}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { HistoryEntitySubscriber } from '@operato/typeorm-history';
|
|
2
|
+
import { AccountingDocument } from './accounting-document';
|
|
3
|
+
import { AccountingDocumentHistory } from './accounting-document-history';
|
|
4
|
+
export declare class AccountingDocumentHistoryEntitySubscriber extends HistoryEntitySubscriber<AccountingDocument, AccountingDocumentHistory> {
|
|
5
|
+
get entity(): typeof AccountingDocument;
|
|
6
|
+
get historyEntity(): typeof AccountingDocumentHistory;
|
|
7
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.AccountingDocumentHistoryEntitySubscriber = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const typeorm_1 = require("typeorm");
|
|
6
|
+
const typeorm_history_1 = require("@operato/typeorm-history");
|
|
7
|
+
const accounting_document_1 = require("./accounting-document");
|
|
8
|
+
const accounting_document_history_1 = require("./accounting-document-history");
|
|
9
|
+
let AccountingDocumentHistoryEntitySubscriber = class AccountingDocumentHistoryEntitySubscriber extends typeorm_history_1.HistoryEntitySubscriber {
|
|
10
|
+
get entity() {
|
|
11
|
+
return accounting_document_1.AccountingDocument;
|
|
12
|
+
}
|
|
13
|
+
get historyEntity() {
|
|
14
|
+
return accounting_document_history_1.AccountingDocumentHistory;
|
|
15
|
+
}
|
|
16
|
+
};
|
|
17
|
+
exports.AccountingDocumentHistoryEntitySubscriber = AccountingDocumentHistoryEntitySubscriber;
|
|
18
|
+
exports.AccountingDocumentHistoryEntitySubscriber = AccountingDocumentHistoryEntitySubscriber = tslib_1.__decorate([
|
|
19
|
+
(0, typeorm_1.EventSubscriber)()
|
|
20
|
+
], AccountingDocumentHistoryEntitySubscriber);
|
|
21
|
+
//# sourceMappingURL=event-subscriber.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"event-subscriber.js","sourceRoot":"","sources":["../../../server/service/accounting-document/event-subscriber.ts"],"names":[],"mappings":";;;;AAAA,qCAAyC;AAEzC,8DAAkE;AAElE,+DAA0D;AAC1D,+EAAyE;AAGlE,IAAM,yCAAyC,GAA/C,MAAM,yCAA0C,SAAQ,yCAAsE;IACnI,IAAW,MAAM;QACf,OAAO,wCAAkB,CAAA;IAC3B,CAAC;IAED,IAAW,aAAa;QACtB,OAAO,uDAAyB,CAAA;IAClC,CAAC;CACF,CAAA;AARY,8FAAyC;oDAAzC,yCAAyC;IADrD,IAAA,yBAAe,GAAE;GACL,yCAAyC,CAQrD","sourcesContent":["import { EventSubscriber } from 'typeorm'\n\nimport { HistoryEntitySubscriber } from '@operato/typeorm-history'\n\nimport { AccountingDocument } from './accounting-document'\nimport { AccountingDocumentHistory } from './accounting-document-history'\n\n@EventSubscriber()\nexport class AccountingDocumentHistoryEntitySubscriber extends HistoryEntitySubscriber<AccountingDocument, AccountingDocumentHistory> {\n public get entity() {\n return AccountingDocument\n }\n\n public get historyEntity() {\n return AccountingDocumentHistory\n }\n}\n"]}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { AccountingDocument } from './accounting-document';
|
|
2
|
+
import { AccountingDocumentHistoryEntitySubscriber } from './event-subscriber';
|
|
3
|
+
import { AccountingDocumentQuery } from './accounting-document-query';
|
|
4
|
+
import { AccountingDocumentMutation } from './accounting-document-mutation';
|
|
5
|
+
export declare const entities: (typeof AccountingDocument)[];
|
|
6
|
+
export declare const resolvers: (typeof AccountingDocumentQuery | typeof AccountingDocumentMutation)[];
|
|
7
|
+
export declare const subscribers: (typeof AccountingDocumentHistoryEntitySubscriber)[];
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.subscribers = exports.resolvers = exports.entities = void 0;
|
|
4
|
+
const accounting_document_1 = require("./accounting-document");
|
|
5
|
+
const accounting_document_history_1 = require("./accounting-document-history");
|
|
6
|
+
const event_subscriber_1 = require("./event-subscriber");
|
|
7
|
+
const accounting_document_query_1 = require("./accounting-document-query");
|
|
8
|
+
const accounting_document_mutation_1 = require("./accounting-document-mutation");
|
|
9
|
+
exports.entities = [accounting_document_1.AccountingDocument, accounting_document_history_1.AccountingDocumentHistory];
|
|
10
|
+
exports.resolvers = [accounting_document_query_1.AccountingDocumentQuery, accounting_document_mutation_1.AccountingDocumentMutation];
|
|
11
|
+
exports.subscribers = [event_subscriber_1.AccountingDocumentHistoryEntitySubscriber];
|
|
12
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../server/service/accounting-document/index.ts"],"names":[],"mappings":";;;AAAA,+DAA0D;AAC1D,+EAAyE;AACzE,yDAA8E;AAC9E,2EAAqE;AACrE,iFAA2E;AAE9D,QAAA,QAAQ,GAAG,CAAC,wCAAkB,EAAE,uDAAyB,CAAC,CAAA;AAC1D,QAAA,SAAS,GAAG,CAAC,mDAAuB,EAAE,yDAA0B,CAAC,CAAA;AACjE,QAAA,WAAW,GAAG,CAAC,4DAAyC,CAAC,CAAA","sourcesContent":["import { AccountingDocument } from './accounting-document'\nimport { AccountingDocumentHistory } from './accounting-document-history'\nimport { AccountingDocumentHistoryEntitySubscriber } from './event-subscriber'\nimport { AccountingDocumentQuery } from './accounting-document-query'\nimport { AccountingDocumentMutation } from './accounting-document-mutation'\n\nexport const entities = [AccountingDocument, AccountingDocumentHistory]\nexport const resolvers = [AccountingDocumentQuery, AccountingDocumentMutation]\nexport const subscribers = [AccountingDocumentHistoryEntitySubscriber]\n"]}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.FiscalStatus = void 0;
|
|
4
|
+
const type_graphql_1 = require("type-graphql");
|
|
5
|
+
var FiscalStatus;
|
|
6
|
+
(function (FiscalStatus) {
|
|
7
|
+
FiscalStatus["OPEN"] = "OPEN";
|
|
8
|
+
FiscalStatus["CLOSED"] = "CLOSED";
|
|
9
|
+
FiscalStatus["FINALIZED"] = "FINALIZED";
|
|
10
|
+
})(FiscalStatus || (exports.FiscalStatus = FiscalStatus = {}));
|
|
11
|
+
(0, type_graphql_1.registerEnumType)(FiscalStatus, {
|
|
12
|
+
name: 'FiscalStatus',
|
|
13
|
+
description: 'The status of a fiscal period (OPEN, CLOSED, FINALIZED)'
|
|
14
|
+
});
|
|
15
|
+
//# sourceMappingURL=common-type.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"common-type.js","sourceRoot":"","sources":["../../server/service/common-type.ts"],"names":[],"mappings":";;;AAAA,+CAA+C;AAE/C,IAAY,YAIX;AAJD,WAAY,YAAY;IACtB,6BAAa,CAAA;IACb,iCAAiB,CAAA;IACjB,uCAAuB,CAAA;AACzB,CAAC,EAJW,YAAY,4BAAZ,YAAY,QAIvB;AAED,IAAA,+BAAgB,EAAC,YAAY,EAAE;IAC7B,IAAI,EAAE,cAAc;IACpB,WAAW,EAAE,yDAAyD;CACvE,CAAC,CAAA","sourcesContent":["import { registerEnumType } from 'type-graphql'\n\nexport enum FiscalStatus {\n OPEN = 'OPEN',\n CLOSED = 'CLOSED',\n FINALIZED = 'FINALIZED'\n}\n\nregisterEnumType(FiscalStatus, {\n name: 'FiscalStatus',\n description: 'The status of a fiscal period (OPEN, CLOSED, FINALIZED)'\n})\n"]}
|
|
@@ -1,17 +1,20 @@
|
|
|
1
1
|
import { HistoryActionType, HistoryEntityInterface } from '@operato/typeorm-history';
|
|
2
2
|
import { User } from '@things-factory/auth-base';
|
|
3
3
|
import { Domain } from '@things-factory/shell';
|
|
4
|
-
import { FinancialStatement
|
|
4
|
+
import { FinancialStatement } from './financial-statement';
|
|
5
|
+
import { FinancialStatementLineItem } from './financial-statement-line-item';
|
|
5
6
|
export declare class FinancialStatementHistory implements HistoryEntityInterface<FinancialStatement> {
|
|
6
7
|
readonly id: string;
|
|
7
8
|
version?: number;
|
|
8
9
|
domain?: Domain;
|
|
9
10
|
domainId?: string;
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
11
|
+
year?: number;
|
|
12
|
+
quarter?: number;
|
|
13
|
+
month?: number;
|
|
14
|
+
asset?: number;
|
|
15
|
+
liability?: number;
|
|
16
|
+
equity?: number;
|
|
17
|
+
lineItems?: FinancialStatementLineItem[];
|
|
15
18
|
createdAt?: Date;
|
|
16
19
|
updatedAt?: Date;
|
|
17
20
|
deletedAt?: Date;
|
|
@@ -8,7 +8,7 @@ const typeorm_history_1 = require("@operato/typeorm-history");
|
|
|
8
8
|
const auth_base_1 = require("@things-factory/auth-base");
|
|
9
9
|
const env_1 = require("@things-factory/env");
|
|
10
10
|
const shell_1 = require("@things-factory/shell");
|
|
11
|
-
const
|
|
11
|
+
const financial_statement_line_item_1 = require("./financial-statement-line-item");
|
|
12
12
|
const ORMCONFIG = env_1.config.get('ormconfig', {});
|
|
13
13
|
const DATABASE_TYPE = ORMCONFIG.type;
|
|
14
14
|
let FinancialStatementHistory = class FinancialStatementHistory {
|
|
@@ -29,38 +29,48 @@ tslib_1.__decorate([
|
|
|
29
29
|
], FinancialStatementHistory.prototype, "version", void 0);
|
|
30
30
|
tslib_1.__decorate([
|
|
31
31
|
(0, typeorm_1.ManyToOne)(type => shell_1.Domain),
|
|
32
|
-
(0, type_graphql_1.Field)(
|
|
32
|
+
(0, type_graphql_1.Field)({ nullable: true }),
|
|
33
33
|
tslib_1.__metadata("design:type", shell_1.Domain)
|
|
34
34
|
], FinancialStatementHistory.prototype, "domain", void 0);
|
|
35
35
|
tslib_1.__decorate([
|
|
36
|
-
(0, typeorm_1.RelationId)((
|
|
36
|
+
(0, typeorm_1.RelationId)((financialStatementHistory) => financialStatementHistory.domain),
|
|
37
37
|
tslib_1.__metadata("design:type", String)
|
|
38
38
|
], FinancialStatementHistory.prototype, "domainId", void 0);
|
|
39
39
|
tslib_1.__decorate([
|
|
40
|
-
(0, typeorm_1.Column)(),
|
|
41
|
-
(0, type_graphql_1.Field)(),
|
|
42
|
-
tslib_1.__metadata("design:type",
|
|
43
|
-
], FinancialStatementHistory.prototype, "
|
|
40
|
+
(0, typeorm_1.Column)({ nullable: true }),
|
|
41
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'Fiscal year of the financial statement' }),
|
|
42
|
+
tslib_1.__metadata("design:type", Number)
|
|
43
|
+
], FinancialStatementHistory.prototype, "year", void 0);
|
|
44
44
|
tslib_1.__decorate([
|
|
45
45
|
(0, typeorm_1.Column)({ nullable: true }),
|
|
46
|
-
(0, type_graphql_1.Field)({ nullable: true }),
|
|
47
|
-
tslib_1.__metadata("design:type",
|
|
48
|
-
], FinancialStatementHistory.prototype, "
|
|
46
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'Fiscal quarter of the financial statement' }),
|
|
47
|
+
tslib_1.__metadata("design:type", Number)
|
|
48
|
+
], FinancialStatementHistory.prototype, "quarter", void 0);
|
|
49
49
|
tslib_1.__decorate([
|
|
50
50
|
(0, typeorm_1.Column)({ nullable: true }),
|
|
51
|
-
(0, type_graphql_1.Field)({ nullable: true }),
|
|
52
|
-
tslib_1.__metadata("design:type",
|
|
53
|
-
], FinancialStatementHistory.prototype, "
|
|
51
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'Fiscal month of the financial statement' }),
|
|
52
|
+
tslib_1.__metadata("design:type", Number)
|
|
53
|
+
], FinancialStatementHistory.prototype, "month", void 0);
|
|
54
54
|
tslib_1.__decorate([
|
|
55
55
|
(0, typeorm_1.Column)({ nullable: true }),
|
|
56
|
-
(0, type_graphql_1.Field)({ nullable: true }),
|
|
57
|
-
tslib_1.__metadata("design:type",
|
|
58
|
-
], FinancialStatementHistory.prototype, "
|
|
56
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'Total assets recorded in the financial statement' }),
|
|
57
|
+
tslib_1.__metadata("design:type", Number)
|
|
58
|
+
], FinancialStatementHistory.prototype, "asset", void 0);
|
|
59
59
|
tslib_1.__decorate([
|
|
60
60
|
(0, typeorm_1.Column)({ nullable: true }),
|
|
61
|
-
(0, type_graphql_1.Field)({ nullable: true }),
|
|
62
|
-
tslib_1.__metadata("design:type",
|
|
63
|
-
], FinancialStatementHistory.prototype, "
|
|
61
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'Total liabilities recorded in the financial statement' }),
|
|
62
|
+
tslib_1.__metadata("design:type", Number)
|
|
63
|
+
], FinancialStatementHistory.prototype, "liability", void 0);
|
|
64
|
+
tslib_1.__decorate([
|
|
65
|
+
(0, typeorm_1.Column)({ nullable: true }),
|
|
66
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'Total equity recorded in the financial statement' }),
|
|
67
|
+
tslib_1.__metadata("design:type", Number)
|
|
68
|
+
], FinancialStatementHistory.prototype, "equity", void 0);
|
|
69
|
+
tslib_1.__decorate([
|
|
70
|
+
(0, typeorm_1.OneToMany)(type => financial_statement_line_item_1.FinancialStatementLineItem, lineItem => lineItem.statement),
|
|
71
|
+
(0, type_graphql_1.Field)(type => [financial_statement_line_item_1.FinancialStatementLineItem], { nullable: true }),
|
|
72
|
+
tslib_1.__metadata("design:type", Array)
|
|
73
|
+
], FinancialStatementHistory.prototype, "lineItems", void 0);
|
|
64
74
|
tslib_1.__decorate([
|
|
65
75
|
(0, typeorm_1.Column)({ nullable: true }),
|
|
66
76
|
(0, type_graphql_1.Field)({ nullable: true }),
|
|
@@ -78,20 +88,20 @@ tslib_1.__decorate([
|
|
|
78
88
|
], FinancialStatementHistory.prototype, "deletedAt", void 0);
|
|
79
89
|
tslib_1.__decorate([
|
|
80
90
|
(0, typeorm_1.ManyToOne)(type => auth_base_1.User, { nullable: true }),
|
|
81
|
-
(0, type_graphql_1.Field)(
|
|
91
|
+
(0, type_graphql_1.Field)({ nullable: true }),
|
|
82
92
|
tslib_1.__metadata("design:type", auth_base_1.User)
|
|
83
93
|
], FinancialStatementHistory.prototype, "creator", void 0);
|
|
84
94
|
tslib_1.__decorate([
|
|
85
|
-
(0, typeorm_1.RelationId)((
|
|
95
|
+
(0, typeorm_1.RelationId)((financialStatementHistory) => financialStatementHistory.creator),
|
|
86
96
|
tslib_1.__metadata("design:type", String)
|
|
87
97
|
], FinancialStatementHistory.prototype, "creatorId", void 0);
|
|
88
98
|
tslib_1.__decorate([
|
|
89
99
|
(0, typeorm_1.ManyToOne)(type => auth_base_1.User, { nullable: true }),
|
|
90
|
-
(0, type_graphql_1.Field)(
|
|
100
|
+
(0, type_graphql_1.Field)({ nullable: true }),
|
|
91
101
|
tslib_1.__metadata("design:type", auth_base_1.User)
|
|
92
102
|
], FinancialStatementHistory.prototype, "updater", void 0);
|
|
93
103
|
tslib_1.__decorate([
|
|
94
|
-
(0, typeorm_1.RelationId)((
|
|
104
|
+
(0, typeorm_1.RelationId)((financialStatementHistory) => financialStatementHistory.updater),
|
|
95
105
|
tslib_1.__metadata("design:type", String)
|
|
96
106
|
], FinancialStatementHistory.prototype, "updaterId", void 0);
|
|
97
107
|
tslib_1.__decorate([
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"financial-statement-history.js","sourceRoot":"","sources":["../../../server/service/financial-statement/financial-statement-history.ts"],"names":[],"mappings":";;;;AAAA,+CAAoD;AACpD,
|
|
1
|
+
{"version":3,"file":"financial-statement-history.js","sourceRoot":"","sources":["../../../server/service/financial-statement/financial-statement-history.ts"],"names":[],"mappings":";;;;AAAA,+CAAoD;AACpD,qCAAyG;AAEzG,8DAKiC;AACjC,yDAAsD;AACtD,6CAA4C;AAC5C,iDAA8C;AAG9C,mFAA4E;AAE5E,MAAM,SAAS,GAAG,YAAM,CAAC,GAAG,CAAC,WAAW,EAAE,EAAE,CAAC,CAAA;AAC7C,MAAM,aAAa,GAAG,SAAS,CAAC,IAAI,CAAA;AAqB7B,IAAM,yBAAyB,GAA/B,MAAM,yBAAyB;IAA/B;QAOL,YAAO,GAAY,CAAC,CAAA;IA6EtB,CAAC;CAAA,CAAA;AApFY,8DAAyB;AAG3B;IAFR,IAAA,gCAAsB,EAAC,MAAM,CAAC;IAC9B,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,iBAAE,CAAC;;qDACC;AAInB;IAFC,IAAA,gBAAM,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC;IACtC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;0DACN;AAIpB;IAFC,IAAA,mBAAS,EAAC,IAAI,CAAC,EAAE,CAAC,cAAM,CAAC;IACzB,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;sCACjB,cAAM;yDAAA;AAGf;IADC,IAAA,oBAAU,EAAC,CAAC,yBAAoD,EAAE,EAAE,CAAC,yBAAyB,CAAC,MAAM,CAAC;;2DACtF;AAIjB;IAFC,IAAA,gBAAM,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;IAC1B,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,WAAW,EAAE,wCAAwC,EAAE,CAAC;;uDACpE;AAIb;IAFC,IAAA,gBAAM,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;IAC1B,IAAA,oBA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BAAoD,EAAE,EAAE,CAAC;QACxD,yBAAyB,CAAC,UAAU;QACpC,yBAAyB,CAAC,OAAO;KAClC,EACD,EAAE,MAAM,EAAE,IAAI,EAAE,CACjB;IACA,IAAA,eAAK,EACJ,kCAAkC,EAClC,CAAC,yBAAoD,EAAE,EAAE,CAAC;QACxD,yBAAyB,CAAC,MAAM;QAChC,yBAAyB,CAAC,UAAU;QACpC,yBAAyB,CAAC,OAAO;KAClC,EACD,EAAE,MAAM,EAAE,IAAI,EAAE,CACjB;IACA,IAAA,yBAAU,EAAC,EAAE,WAAW,EAAE,sCAAsC,EAAE,CAAC;GACvD,yBAAyB,CAoFrC","sourcesContent":["import { Field, ID, ObjectType } from 'type-graphql'\nimport { Column, Entity, Index, ManyToOne, OneToMany, PrimaryGeneratedColumn, RelationId } from 'typeorm'\n\nimport {\n HistoryActionColumn,\n HistoryActionType,\n HistoryEntityInterface,\n HistoryOriginalIdColumn\n} from '@operato/typeorm-history'\nimport { Role, User } from '@things-factory/auth-base'\nimport { config } from '@things-factory/env'\nimport { Domain } from '@things-factory/shell'\n\nimport { FinancialStatement } from './financial-statement'\nimport { FinancialStatementLineItem } from './financial-statement-line-item'\n\nconst ORMCONFIG = config.get('ormconfig', {})\nconst DATABASE_TYPE = ORMCONFIG.type\n\n@Entity()\n@Index(\n 'ix_financial-statement_history_0',\n (financialStatementHistory: FinancialStatementHistory) => [\n financialStatementHistory.originalId,\n financialStatementHistory.version\n ],\n { unique: true }\n)\n@Index(\n 'ix_financial-statement_history_1',\n (financialStatementHistory: FinancialStatementHistory) => [\n financialStatementHistory.domain,\n financialStatementHistory.originalId,\n financialStatementHistory.version\n ],\n { unique: true }\n)\n@ObjectType({ description: 'History Entity of FinancialStatement' })\nexport class FinancialStatementHistory implements HistoryEntityInterface<FinancialStatement> {\n @PrimaryGeneratedColumn('uuid')\n @Field(type => ID)\n readonly id: string\n\n @Column({ nullable: true, default: 1 })\n @Field({ nullable: true })\n version?: number = 1\n\n @ManyToOne(type => Domain)\n @Field({ nullable: true })\n domain?: Domain\n\n @RelationId((financialStatementHistory: FinancialStatementHistory) => financialStatementHistory.domain)\n domainId?: string\n\n @Column({ nullable: true })\n @Field({ nullable: true, description: 'Fiscal year of the financial statement' })\n year?: number // 회계 연도\n\n @Column({ nullable: true })\n @Field({ nullable: true, description: 'Fiscal quarter of the financial statement' })\n quarter?: number // 회계 분기\n\n @Column({ nullable: true })\n @Field({ nullable: true, description: 'Fiscal month of the financial statement' })\n month?: number // 회계 월\n\n @Column({ nullable: true })\n @Field({ nullable: true, description: 'Total assets recorded in the financial statement' })\n asset?: number // 재무제표에 기록된 총자산\n\n @Column({ nullable: true })\n @Field({ nullable: true, description: 'Total liabilities recorded in the financial statement' })\n liability?: number // 재무제표에 기록된 총부채\n\n @Column({ nullable: true })\n @Field({ nullable: true, description: 'Total equity recorded in the financial statement' })\n equity?: number // 재무제표에 기록된 총자본\n\n @OneToMany(type => FinancialStatementLineItem, lineItem => lineItem.statement)\n @Field(type => [FinancialStatementLineItem], { nullable: true })\n lineItems?: FinancialStatementLineItem[] // 계정별 브레이크다운\n\n @Column({ nullable: true })\n @Field({ nullable: true })\n createdAt?: Date\n\n @Column({ nullable: true })\n @Field({ nullable: true })\n updatedAt?: Date\n\n @Column({ nullable: true })\n @Field({ nullable: true })\n deletedAt?: Date\n\n @ManyToOne(type => User, { nullable: true })\n @Field({ nullable: true })\n creator?: User\n\n @RelationId((financialStatementHistory: FinancialStatementHistory) => financialStatementHistory.creator)\n creatorId?: string\n\n @ManyToOne(type => User, { nullable: true })\n @Field({ nullable: true })\n updater?: User\n\n @RelationId((financialStatementHistory: FinancialStatementHistory) => financialStatementHistory.updater)\n updaterId?: string\n\n @HistoryOriginalIdColumn()\n public originalId!: string\n\n @HistoryActionColumn({\n nullable: false,\n type:\n DATABASE_TYPE == 'postgres' || DATABASE_TYPE == 'mysql' || DATABASE_TYPE == 'mariadb'\n ? 'enum'\n : DATABASE_TYPE == 'oracle'\n ? 'varchar2'\n : 'smallint',\n enum: HistoryActionType\n })\n public action!: HistoryActionType\n}\n"]}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { User } from '@things-factory/auth-base';
|
|
2
|
+
import { Account } from '../account/account';
|
|
3
|
+
import { FinancialStatement } from './financial-statement';
|
|
4
|
+
export declare class FinancialStatementLineItem {
|
|
5
|
+
readonly id: string;
|
|
6
|
+
statement: FinancialStatement;
|
|
7
|
+
statementId: string;
|
|
8
|
+
account: Account;
|
|
9
|
+
accountId: string;
|
|
10
|
+
amount: number;
|
|
11
|
+
description?: string;
|
|
12
|
+
createdAt?: Date;
|
|
13
|
+
updatedAt?: Date;
|
|
14
|
+
deletedAt?: Date;
|
|
15
|
+
creator?: User;
|
|
16
|
+
creatorId?: string;
|
|
17
|
+
updater?: User;
|
|
18
|
+
updaterId?: string;
|
|
19
|
+
}
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.FinancialStatementLineItem = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const typeorm_1 = require("typeorm");
|
|
6
|
+
const type_graphql_1 = require("type-graphql");
|
|
7
|
+
const auth_base_1 = require("@things-factory/auth-base");
|
|
8
|
+
const account_1 = require("../account/account");
|
|
9
|
+
const financial_statement_1 = require("./financial-statement");
|
|
10
|
+
let FinancialStatementLineItem = class FinancialStatementLineItem {
|
|
11
|
+
};
|
|
12
|
+
exports.FinancialStatementLineItem = FinancialStatementLineItem;
|
|
13
|
+
tslib_1.__decorate([
|
|
14
|
+
(0, typeorm_1.PrimaryGeneratedColumn)('uuid'),
|
|
15
|
+
(0, type_graphql_1.Field)(type => type_graphql_1.ID),
|
|
16
|
+
tslib_1.__metadata("design:type", String)
|
|
17
|
+
], FinancialStatementLineItem.prototype, "id", void 0);
|
|
18
|
+
tslib_1.__decorate([
|
|
19
|
+
(0, typeorm_1.ManyToOne)(type => financial_statement_1.FinancialStatement, statement => statement.lineItems),
|
|
20
|
+
(0, type_graphql_1.Field)(type => financial_statement_1.FinancialStatement, { description: 'The financial statement this line item is associated with' }),
|
|
21
|
+
tslib_1.__metadata("design:type", financial_statement_1.FinancialStatement // 연결된 재무제표
|
|
22
|
+
)
|
|
23
|
+
], FinancialStatementLineItem.prototype, "statement", void 0);
|
|
24
|
+
tslib_1.__decorate([
|
|
25
|
+
(0, typeorm_1.RelationId)((lineItem) => lineItem.statement),
|
|
26
|
+
tslib_1.__metadata("design:type", String)
|
|
27
|
+
], FinancialStatementLineItem.prototype, "statementId", void 0);
|
|
28
|
+
tslib_1.__decorate([
|
|
29
|
+
(0, typeorm_1.ManyToOne)(type => account_1.Account),
|
|
30
|
+
(0, type_graphql_1.Field)(type => account_1.Account, { description: 'The financial account associated with this line item' }),
|
|
31
|
+
tslib_1.__metadata("design:type", account_1.Account // 라인 아이템과 연결된 계정
|
|
32
|
+
)
|
|
33
|
+
], FinancialStatementLineItem.prototype, "account", void 0);
|
|
34
|
+
tslib_1.__decorate([
|
|
35
|
+
(0, typeorm_1.RelationId)((lineItem) => lineItem.account),
|
|
36
|
+
tslib_1.__metadata("design:type", String)
|
|
37
|
+
], FinancialStatementLineItem.prototype, "accountId", void 0);
|
|
38
|
+
tslib_1.__decorate([
|
|
39
|
+
(0, typeorm_1.Column)({ nullable: false }),
|
|
40
|
+
(0, type_graphql_1.Field)({ nullable: false, description: 'The monetary amount related to the financial account for this line item' }),
|
|
41
|
+
tslib_1.__metadata("design:type", Number)
|
|
42
|
+
], FinancialStatementLineItem.prototype, "amount", void 0);
|
|
43
|
+
tslib_1.__decorate([
|
|
44
|
+
(0, typeorm_1.Column)({ nullable: true }),
|
|
45
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'Optional description or notes for this line item' }),
|
|
46
|
+
tslib_1.__metadata("design:type", String)
|
|
47
|
+
], FinancialStatementLineItem.prototype, "description", void 0);
|
|
48
|
+
tslib_1.__decorate([
|
|
49
|
+
(0, typeorm_1.CreateDateColumn)(),
|
|
50
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'The date and time when this line item was created' }),
|
|
51
|
+
tslib_1.__metadata("design:type", Date // 라인 아이템이 생성된 날짜 및 시간
|
|
52
|
+
)
|
|
53
|
+
], FinancialStatementLineItem.prototype, "createdAt", void 0);
|
|
54
|
+
tslib_1.__decorate([
|
|
55
|
+
(0, typeorm_1.UpdateDateColumn)(),
|
|
56
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'The date and time when this line item was last updated' }),
|
|
57
|
+
tslib_1.__metadata("design:type", Date // 라인 아이템이 마지막으로 업데이트된 날짜 및 시간
|
|
58
|
+
)
|
|
59
|
+
], FinancialStatementLineItem.prototype, "updatedAt", void 0);
|
|
60
|
+
tslib_1.__decorate([
|
|
61
|
+
(0, typeorm_1.DeleteDateColumn)(),
|
|
62
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'The date and time when this line item was deleted' }),
|
|
63
|
+
tslib_1.__metadata("design:type", Date // 라인 아이템이 삭제된 날짜 및 시간
|
|
64
|
+
)
|
|
65
|
+
], FinancialStatementLineItem.prototype, "deletedAt", void 0);
|
|
66
|
+
tslib_1.__decorate([
|
|
67
|
+
(0, typeorm_1.ManyToOne)(type => auth_base_1.User, { nullable: true }),
|
|
68
|
+
(0, type_graphql_1.Field)(type => auth_base_1.User, { nullable: true, description: 'The user who created this line item' }),
|
|
69
|
+
tslib_1.__metadata("design:type", auth_base_1.User // 라인 아이템을 생성한 사용자
|
|
70
|
+
)
|
|
71
|
+
], FinancialStatementLineItem.prototype, "creator", void 0);
|
|
72
|
+
tslib_1.__decorate([
|
|
73
|
+
(0, typeorm_1.RelationId)((lineItem) => lineItem.creator),
|
|
74
|
+
tslib_1.__metadata("design:type", String)
|
|
75
|
+
], FinancialStatementLineItem.prototype, "creatorId", void 0);
|
|
76
|
+
tslib_1.__decorate([
|
|
77
|
+
(0, typeorm_1.ManyToOne)(type => auth_base_1.User, { nullable: true }),
|
|
78
|
+
(0, type_graphql_1.Field)(type => auth_base_1.User, { nullable: true, description: 'The user who last updated this line item' }),
|
|
79
|
+
tslib_1.__metadata("design:type", auth_base_1.User // 라인 아이템을 마지막으로 업데이트한 사용자
|
|
80
|
+
)
|
|
81
|
+
], FinancialStatementLineItem.prototype, "updater", void 0);
|
|
82
|
+
tslib_1.__decorate([
|
|
83
|
+
(0, typeorm_1.RelationId)((lineItem) => lineItem.updater),
|
|
84
|
+
tslib_1.__metadata("design:type", String)
|
|
85
|
+
], FinancialStatementLineItem.prototype, "updaterId", void 0);
|
|
86
|
+
exports.FinancialStatementLineItem = FinancialStatementLineItem = tslib_1.__decorate([
|
|
87
|
+
(0, type_graphql_1.ObjectType)({ description: 'Line item for a financial statement, representing the breakdown of financial accounts' }),
|
|
88
|
+
(0, typeorm_1.Entity)(),
|
|
89
|
+
(0, typeorm_1.Index)('ix_financial_statement_line_item_0', (lineItem) => [lineItem.statement, lineItem.account], {
|
|
90
|
+
unique: false,
|
|
91
|
+
where: '"deleted_at" IS NULL'
|
|
92
|
+
})
|
|
93
|
+
], FinancialStatementLineItem);
|
|
94
|
+
//# sourceMappingURL=financial-statement-line-item.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"financial-statement-line-item.js","sourceRoot":"","sources":["../../../server/service/financial-statement/financial-statement-line-item.ts"],"names":[],"mappings":";;;;AAAA,qCAWgB;AAChB,+CAAoD;AAGpD,yDAAgD;AAChD,gDAA4C;AAC5C,+DAA0D;AAYnD,IAAM,0BAA0B,GAAhC,MAAM,0BAA0B;CAoDtC,CAAA;AApDY,gEAA0B;AAG5B;IAFR,IAAA,gCAAsB,EAAC,MAAM,CAAC;IAC9B,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,iBAAE,CAAC;;sDACC;AAInB;IAFC,IAAA,mBAAS,EAAC,IAAI,CAAC,EAAE,CAAC,wCAAkB,EAAE,SAAS,CAAC,EAAE,CAAC,SAAS,CAAC,SA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DeleteDateColumn,\n Entity,\n Index,\n Column,\n RelationId,\n ManyToOne,\n PrimaryGeneratedColumn,\n VersionColumn\n} from 'typeorm'\nimport { ObjectType, Field, ID } from 'type-graphql'\n\nimport { Domain } from '@things-factory/shell'\nimport { User } from '@things-factory/auth-base'\nimport { Account } from '../account/account'\nimport { FinancialStatement } from './financial-statement'\n\n@ObjectType({ description: 'Line item for a financial statement, representing the breakdown of financial accounts' })\n@Entity()\n@Index(\n 'ix_financial_statement_line_item_0',\n (lineItem: FinancialStatementLineItem) => [lineItem.statement, lineItem.account],\n {\n unique: false,\n where: '\"deleted_at\" IS NULL'\n }\n)\nexport class FinancialStatementLineItem {\n @PrimaryGeneratedColumn('uuid')\n @Field(type => ID)\n readonly id: string // 고유 식별자 (UUID)\n\n @ManyToOne(type => FinancialStatement, statement => statement.lineItems)\n @Field(type => FinancialStatement, { description: 'The financial statement this line item is associated with' })\n statement: FinancialStatement // 연결된 재무제표\n\n @RelationId((lineItem: FinancialStatementLineItem) => lineItem.statement)\n statementId: string // 재무제표의 ID\n\n @ManyToOne(type => Account)\n @Field(type => Account, { description: 'The financial account associated with this line item' })\n account: Account // 라인 아이템과 연결된 계정\n\n @RelationId((lineItem: FinancialStatementLineItem) => lineItem.account)\n accountId: string // 계정의 ID\n\n @Column({ nullable: false })\n @Field({ nullable: false, description: 'The monetary amount related to the financial account for this line item' })\n amount: number // 계정에 대한 금액\n\n @Column({ nullable: true })\n @Field({ nullable: true, description: 'Optional description or notes for this line item' })\n description?: string // 라인 아이템에 대한 선택적 설명 또는 메모\n\n @CreateDateColumn()\n @Field({ nullable: true, description: 'The date and time when this line item was created' })\n createdAt?: Date // 라인 아이템이 생성된 날짜 및 시간\n\n @UpdateDateColumn()\n @Field({ nullable: true, description: 'The date and time when this line item was last updated' })\n updatedAt?: Date // 라인 아이템이 마지막으로 업데이트된 날짜 및 시간\n\n @DeleteDateColumn()\n @Field({ nullable: true, description: 'The date and time when this line item was deleted' })\n deletedAt?: Date // 라인 아이템이 삭제된 날짜 및 시간\n\n @ManyToOne(type => User, { nullable: true })\n @Field(type => User, { nullable: true, description: 'The user who created this line item' })\n creator?: User // 라인 아이템을 생성한 사용자\n\n @RelationId((lineItem: FinancialStatementLineItem) => lineItem.creator)\n creatorId?: string // 생성자의 ID\n\n @ManyToOne(type => User, { nullable: true })\n @Field(type => User, { nullable: true, description: 'The user who last updated this line item' })\n updater?: User // 라인 아이템을 마지막으로 업데이트한 사용자\n\n @RelationId((lineItem: FinancialStatementLineItem) => lineItem.updater)\n updaterId?: string // 업데이트한 사용자의 ID\n}\n"]}
|