taxtank-core 0.17.16 → 0.19.0
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/bundles/taxtank-core.umd.js +6764 -5446
- package/bundles/taxtank-core.umd.js.map +1 -1
- package/esm2015/lib/collections/account-setup-item.collection.js +2 -2
- package/esm2015/lib/collections/bank.collection.js +15 -0
- package/esm2015/lib/collections/collection-dictionary.js +1 -1
- package/esm2015/lib/collections/collection.js +41 -55
- package/esm2015/lib/collections/depreciation.collection.js +6 -3
- package/esm2015/lib/collections/exportable.collection.js +1 -1
- package/esm2015/lib/collections/property/property.collection.js +3 -3
- package/esm2015/lib/collections/transaction/transaction.collection.js +11 -7
- package/esm2015/lib/collections/vehicle-logbook.collection.js +2 -2
- package/esm2015/lib/db/Enums/chart-accounts-heading-list.enum.js +20 -1
- package/esm2015/lib/db/Enums/chart-accounts-list.enum.js +37 -1
- package/esm2015/lib/db/Enums/chart-accounts-metadata-list.enum.js +4 -1
- package/esm2015/lib/db/Models/abstract-model.js +1 -1
- package/esm2015/lib/db/Models/bank/bank.js +1 -1
- package/esm2015/lib/forms/abstract.form.js +18 -3
- package/esm2015/lib/forms/bank/bank-account-add-manual.form.js +19 -0
- package/esm2015/lib/forms/bank/bank-account-loan.form.js +20 -0
- package/esm2015/lib/forms/bank/bank-account-migrate.form.js +15 -0
- package/esm2015/lib/forms/bank/bank-account-properties.form.js +15 -0
- package/esm2015/lib/forms/bank/bank-account-property.form.js +13 -0
- package/esm2015/lib/forms/bank/bank-account.form.js +53 -0
- package/esm2015/lib/forms/bank/bank-login.form.js +19 -0
- package/esm2015/lib/forms/client/client-income-types.form.js +2 -8
- package/esm2015/lib/forms/index.js +9 -1
- package/esm2015/lib/forms/login/login.form.js +1 -1
- package/esm2015/lib/forms/register/register-client.form.js +4 -3
- package/esm2015/lib/forms/register/register-firm.form.js +2 -9
- package/esm2015/lib/forms/report/my-tax/index.js +14 -0
- package/esm2015/lib/forms/report/my-tax/my-tax-business-or-losses.form.js +10 -0
- package/esm2015/lib/forms/report/my-tax/my-tax-deductions.form.js +75 -0
- package/esm2015/lib/forms/report/my-tax/my-tax-dividends.form.js +23 -0
- package/esm2015/lib/forms/report/my-tax/my-tax-employee-share-schemes.form.js +14 -0
- package/esm2015/lib/forms/report/my-tax/my-tax-income-statements.form.js +92 -0
- package/esm2015/lib/forms/report/my-tax/my-tax-income-tests.form.js +10 -0
- package/esm2015/lib/forms/report/my-tax/my-tax-interest.form.js +12 -0
- package/esm2015/lib/forms/report/my-tax/my-tax-losses.form.js +10 -0
- package/esm2015/lib/forms/report/my-tax/my-tax-medicare.form.js +33 -0
- package/esm2015/lib/forms/report/my-tax/my-tax-offsets.form.js +10 -0
- package/esm2015/lib/forms/report/my-tax/my-tax-other-income.form.js +38 -0
- package/esm2015/lib/forms/report/my-tax/my-tax-partnerships-and-trusts.form.js +32 -0
- package/esm2015/lib/forms/report/my-tax/my-tax-rent.form.js +13 -0
- package/esm2015/lib/forms/user/password.form.js +6 -6
- package/esm2015/lib/forms/user/reset-password.form.js +1 -1
- package/esm2015/lib/forms/vehicle/vehicle-claim.form.js +2 -2
- package/esm2015/lib/forms/vehicle/vehicle.form.js +6 -12
- package/esm2015/lib/interceptors/basiq.interceptor.js +35 -0
- package/esm2015/lib/interceptors/corelogic-interceptor.js +3 -3
- package/esm2015/lib/interceptors/financial-year-interceptor.js +17 -6
- package/esm2015/lib/interceptors/interceptors.module.js +16 -5
- package/esm2015/lib/interceptors/jwt-interceptor.js +3 -3
- package/esm2015/lib/interceptors/preloader.interceptor.js +3 -3
- package/esm2015/lib/interceptors/user-switcher-interceptor.js +3 -3
- package/esm2015/lib/models/account-setup/account-setup-item.js +4 -2
- package/esm2015/lib/models/bank/bank-account-property.js +6 -2
- package/esm2015/lib/models/bank/bank-account.js +2 -1
- package/esm2015/lib/models/bank/bank-connection.js +18 -3
- package/esm2015/lib/models/bank/bank-login-data.js +6 -0
- package/esm2015/lib/models/bank/bank.js +6 -1
- package/esm2015/lib/models/client/client-portfolio-report.js +3 -2
- package/esm2015/lib/models/endpoint/endpoints.const.js +4 -1
- package/esm2015/lib/models/event/app-event-type.enum.js +39 -38
- package/esm2015/lib/models/loan/loan-payment.js +3 -2
- package/esm2015/lib/models/loan/loan.js +1 -6
- package/esm2015/lib/models/pdf/pdf-settings.js +3 -1
- package/esm2015/lib/models/report/my-tax/ato-links.js +11 -0
- package/esm2015/lib/models/report/my-tax/my-tax-business-or-losses/my-tax-business-or-losses.js +8 -0
- package/esm2015/lib/models/report/my-tax/my-tax-deductions/deduction-clothing-type.enum.js +13 -0
- package/esm2015/lib/models/report/my-tax/my-tax-deductions/deduction-fields.const.js +57 -0
- package/esm2015/lib/models/report/my-tax/my-tax-deductions/deduction-self-education-type.enum.js +10 -0
- package/esm2015/lib/models/report/my-tax/my-tax-deductions/my-tax-deductions.js +72 -0
- package/esm2015/lib/models/report/my-tax/my-tax-dividends/my-tax-dividends.js +18 -0
- package/esm2015/lib/models/report/my-tax/my-tax-employee-share-schemes/my-tax-employee-share-schemes.js +24 -0
- package/esm2015/lib/models/report/my-tax/my-tax-income-statements/my-tax-income-statements.js +68 -0
- package/esm2015/lib/models/report/my-tax/my-tax-income-tests/my-tax-income-tests.js +8 -0
- package/esm2015/lib/models/report/my-tax/my-tax-interest/my-tax-interest.js +11 -0
- package/esm2015/lib/models/report/my-tax/my-tax-losses/my-tax-losses.js +10 -0
- package/esm2015/lib/models/report/my-tax/my-tax-offsets/my-tax-offsets.js +8 -0
- package/esm2015/lib/models/report/my-tax/my-tax-other-income/my-tax-other-income.js +28 -0
- package/esm2015/lib/models/report/my-tax/my-tax-partnerships-and-trusts/my-tax-partnerships-and-trusts.js +31 -0
- package/esm2015/lib/models/report/my-tax/my-tax-rent/my-tax-rent.js +24 -0
- package/esm2015/lib/models/report/property/property-report-item.js +4 -2
- package/esm2015/lib/models/report/vehicle-expense/vehicle-expense.js +4 -2
- package/esm2015/lib/models/tax-summary/report-item-details.js +3 -2
- package/esm2015/lib/models/tax-summary/report-item.js +3 -2
- package/esm2015/lib/models/transaction/transaction.js +2 -1
- package/esm2015/lib/services/account-setup/account-setup.service.js +5 -5
- package/esm2015/lib/services/asset/assets.service.js +3 -3
- package/esm2015/lib/services/auth/auth.service.js +3 -3
- package/esm2015/lib/services/auth/jwt.service.js +3 -3
- package/esm2015/lib/services/bank/bank-account-calculation.service.js +3 -3
- package/esm2015/lib/services/bank/bank-transaction-calculation.service.js +3 -3
- package/esm2015/lib/services/event/event-dispatcher.service.js +3 -3
- package/esm2015/lib/services/event/sse.service.js +7 -4
- package/esm2015/lib/services/export/export-formatter.service.js +3 -3
- package/esm2015/lib/services/header-title/header-title.service.js +3 -3
- package/esm2015/lib/services/http/address/address.service.js +3 -3
- package/esm2015/lib/services/http/bank/bank-account/bank-account.service.js +5 -8
- package/esm2015/lib/services/http/bank/bank-connection/bank-connection.service.js +60 -5
- package/esm2015/lib/services/http/bank/bank-transaction/bank-transaction.service.js +3 -3
- package/esm2015/lib/services/http/bank/bank.service.js +3 -3
- package/esm2015/lib/services/http/bank/basiq/basiq-connections-response.interface.js +2 -0
- package/esm2015/lib/services/http/bank/basiq/basiq-token-response.interface.js +2 -0
- package/esm2015/lib/services/http/bank/basiq/basiq-token.service.js +42 -0
- package/esm2015/lib/services/http/bank/basiq/basiq.service.js +37 -46
- package/esm2015/lib/services/http/chart-accounts/chart-accounts-depreciations/chart-accounts-depreciations.service.js +3 -3
- package/esm2015/lib/services/http/chart-accounts/chart-accounts.service.js +3 -3
- package/esm2015/lib/services/http/chat/chat.service.js +3 -3
- package/esm2015/lib/services/http/chat/message/message.service.js +3 -3
- package/esm2015/lib/services/http/chat/message-document/message-document.service.js +3 -3
- package/esm2015/lib/services/http/depreciation/depreciation-capital-project/depreciation-capital-project.service.js +3 -3
- package/esm2015/lib/services/http/depreciation/depreciation.service.js +3 -3
- package/esm2015/lib/services/http/document/document-folder/document-folder.service.js +3 -3
- package/esm2015/lib/services/http/firm/client-income/client-income-types.service.js +3 -3
- package/esm2015/lib/services/http/firm/client-invite/client-invite.service.js +3 -3
- package/esm2015/lib/services/http/firm/client-movement/client-movement.service.js +3 -3
- package/esm2015/lib/services/http/firm/employee/employee.service.js +3 -3
- package/esm2015/lib/services/http/firm/employee-invite/employee-invite.service.js +3 -3
- package/esm2015/lib/services/http/firm/firm.service.js +3 -3
- package/esm2015/lib/services/http/firm/portfolio-report/client-portfolio-report.service.js +3 -3
- package/esm2015/lib/services/http/income-source/income-source-forecast/income-source-forecast.service.js +3 -3
- package/esm2015/lib/services/http/income-source/income-source.service.js +3 -3
- package/esm2015/lib/services/http/income-source/salary-forecast/salary-forecast.service.js +3 -3
- package/esm2015/lib/services/http/income-source/sole-forecast/sole-forecast.service.js +3 -3
- package/esm2015/lib/services/http/loan/borrowing-expense/borrowing-expense.service.js +3 -3
- package/esm2015/lib/services/http/loan/loan.service.js +3 -3
- package/esm2015/lib/services/http/property/property-category/property-category.service.js +3 -3
- package/esm2015/lib/services/http/property/property-category-movement/property-category-movement.service.js +3 -3
- package/esm2015/lib/services/http/property/property-document/property-document.service.js +3 -3
- package/esm2015/lib/services/http/property/property-sale/property-sale.service.js +3 -3
- package/esm2015/lib/services/http/property/property-sale/tax-exemption/tax-exemption.service.js +3 -3
- package/esm2015/lib/services/http/property/property-share/property-share.service.js +3 -3
- package/esm2015/lib/services/http/property/property.service.js +3 -3
- package/esm2015/lib/services/http/rest/rest.service.js +4 -15
- package/esm2015/lib/services/http/service-notification/service-notification.service.js +3 -3
- package/esm2015/lib/services/http/subscription/service-price.service.js +3 -3
- package/esm2015/lib/services/http/subscription/subscription.service.js +3 -3
- package/esm2015/lib/services/http/tax-review/tax-review-history/tax-review-history.service.js +3 -3
- package/esm2015/lib/services/http/tax-review/tax-review.service.js +3 -3
- package/esm2015/lib/services/http/tax-summary/tax-summary.service.js +3 -3
- package/esm2015/lib/services/http/transaction/transaction-allocation/transaction-allocation.service.js +3 -3
- package/esm2015/lib/services/http/transaction/transaction.service.js +3 -3
- package/esm2015/lib/services/http/user/occupation/occupation.service.js +3 -3
- package/esm2015/lib/services/http/user/user-event-setting/user-event-setting.service.js +3 -3
- package/esm2015/lib/services/http/user/user-event-type/user-event-type.service.js +3 -3
- package/esm2015/lib/services/http/user/user.service.js +4 -17
- package/esm2015/lib/services/http/vehicle/vehicle-claim.service.js +3 -3
- package/esm2015/lib/services/http/vehicle/vehicle-logbook.service.js +3 -3
- package/esm2015/lib/services/http/vehicle/vehicle.service.js +3 -3
- package/esm2015/lib/services/intercom/intercom.service.js +3 -3
- package/esm2015/lib/services/kompassify/kompassify.service.js +3 -3
- package/esm2015/lib/services/pdf/pdf-from-dom-element/file-settings.js +19 -0
- package/esm2015/lib/services/pdf/pdf-from-dom-element/pdf-from-dom-element.service.js +35 -0
- package/esm2015/lib/services/pdf/pdf-from-table/file-settings.js +31 -0
- package/esm2015/lib/services/pdf/pdf-from-table/pdf-from-data-table/pdf-from-data-table.service.js +40 -0
- package/esm2015/lib/services/pdf/pdf-from-table/pdf-from-html-table/pdf-from-html-table.service.js +40 -0
- package/esm2015/lib/services/pdf/pdf-from-table/pdf-from-table.service.js +53 -0
- package/esm2015/lib/services/preloader/preloader.service.js +3 -3
- package/esm2015/lib/services/property/corelogic/corelogic.service.js +3 -3
- package/esm2015/lib/services/property/equity-position-chart/equity-position-chart.service.js +3 -3
- package/esm2015/lib/services/property/property-calculation/property-calculation.service.js +3 -3
- package/esm2015/lib/services/report/property/property-transaction-report.service.js +3 -3
- package/esm2015/lib/services/toast/toast.service.js +3 -3
- package/esm2015/lib/services/transaction/transaction-calculation.service.js +3 -3
- package/esm2015/lib/services/user/user-switcher.service.js +3 -3
- package/esm2015/lib/services/xlsx/xlsx.service.js +3 -3
- package/esm2015/lib/tt-core.module.js +4 -4
- package/esm2015/lib/validators/date-range.validator.js +22 -0
- package/esm2015/lib/validators/index.js +3 -1
- package/esm2015/lib/validators/require-autocomplete.js +14 -0
- package/esm2015/lib/validators/require-select.validator.js +15 -0
- package/esm2015/public-api.js +27 -2
- package/fesm2015/taxtank-core.js +7135 -5965
- package/fesm2015/taxtank-core.js.map +1 -1
- package/lib/collections/bank.collection.d.ts +7 -0
- package/lib/collections/collection-dictionary.d.ts +2 -1
- package/lib/collections/collection.d.ts +18 -31
- package/lib/collections/depreciation.collection.d.ts +3 -2
- package/lib/collections/exportable.collection.d.ts +2 -1
- package/lib/collections/transaction/transaction.collection.d.ts +5 -4
- package/lib/db/Enums/chart-accounts-heading-list.enum.d.ts +20 -1
- package/lib/db/Enums/chart-accounts-list.enum.d.ts +37 -1
- package/lib/db/Enums/chart-accounts-metadata-list.enum.d.ts +4 -1
- package/lib/db/Models/abstract-model.d.ts +1 -0
- package/lib/db/Models/bank/bank.d.ts +4 -0
- package/lib/forms/abstract.form.d.ts +18 -3
- package/lib/forms/bank/bank-account-add-manual.form.d.ts +10 -0
- package/lib/forms/bank/bank-account-loan.form.d.ts +5 -0
- package/lib/forms/bank/bank-account-migrate.form.d.ts +9 -0
- package/lib/forms/bank/bank-account-properties.form.d.ts +8 -0
- package/lib/forms/bank/bank-account-property.form.d.ts +5 -0
- package/lib/forms/bank/bank-account.form.d.ts +21 -0
- package/lib/forms/bank/bank-login.form.d.ts +11 -0
- package/lib/forms/client/client-income-types.form.d.ts +1 -2
- package/lib/forms/index.d.ts +8 -0
- package/lib/forms/login/login.form.d.ts +4 -1
- package/lib/forms/register/register-client.form.d.ts +1 -1
- package/lib/forms/register/register-firm.form.d.ts +2 -2
- package/lib/forms/report/my-tax/index.d.ts +13 -0
- package/lib/forms/report/my-tax/my-tax-business-or-losses.form.d.ts +8 -0
- package/lib/forms/report/my-tax/my-tax-deductions.form.d.ts +5 -0
- package/lib/forms/report/my-tax/my-tax-dividends.form.d.ts +5 -0
- package/lib/forms/report/my-tax/my-tax-employee-share-schemes.form.d.ts +5 -0
- package/lib/forms/report/my-tax/my-tax-income-statements.form.d.ts +7 -0
- package/lib/forms/report/my-tax/my-tax-income-tests.form.d.ts +8 -0
- package/lib/forms/report/my-tax/my-tax-interest.form.d.ts +5 -0
- package/lib/forms/report/my-tax/my-tax-losses.form.d.ts +8 -0
- package/lib/forms/report/my-tax/my-tax-medicare.form.d.ts +9 -0
- package/lib/forms/report/my-tax/my-tax-offsets.form.d.ts +8 -0
- package/lib/forms/report/my-tax/my-tax-other-income.form.d.ts +5 -0
- package/lib/forms/report/my-tax/my-tax-partnerships-and-trusts.form.d.ts +5 -0
- package/lib/forms/report/my-tax/my-tax-rent.form.d.ts +5 -0
- package/lib/forms/user/password.form.d.ts +4 -1
- package/lib/forms/user/reset-password.form.d.ts +3 -1
- package/lib/forms/vehicle/vehicle-claim.form.d.ts +1 -1
- package/lib/forms/vehicle/vehicle.form.d.ts +3 -7
- package/lib/interceptors/basiq.interceptor.d.ts +15 -0
- package/lib/interceptors/financial-year-interceptor.d.ts +2 -0
- package/lib/models/account-setup/account-setup-item.d.ts +2 -1
- package/lib/models/bank/bank-account-property.d.ts +1 -0
- package/lib/models/bank/bank-account.d.ts +2 -0
- package/lib/models/bank/bank-connection.d.ts +8 -1
- package/lib/models/bank/bank-login-data.d.ts +17 -0
- package/lib/models/bank/bank.d.ts +1 -0
- package/lib/models/client/client-portfolio-report.d.ts +2 -1
- package/lib/models/event/app-event-type.enum.d.ts +38 -37
- package/lib/models/loan/loan-payment.d.ts +2 -1
- package/lib/models/loan/loan.d.ts +0 -2
- package/lib/models/report/my-tax/ato-links.d.ts +6 -0
- package/lib/models/report/my-tax/my-tax-business-or-losses/my-tax-business-or-losses.d.ts +7 -0
- package/lib/models/report/my-tax/my-tax-deductions/deduction-clothing-type.enum.d.ts +11 -0
- package/lib/models/report/my-tax/my-tax-deductions/deduction-fields.const.d.ts +8 -0
- package/lib/models/report/my-tax/my-tax-deductions/deduction-self-education-type.enum.d.ts +8 -0
- package/lib/models/report/my-tax/my-tax-deductions/my-tax-deductions.d.ts +39 -0
- package/lib/models/report/my-tax/my-tax-dividends/my-tax-dividends.d.ts +9 -0
- package/lib/models/report/my-tax/my-tax-employee-share-schemes/my-tax-employee-share-schemes.d.ts +10 -0
- package/lib/models/report/my-tax/my-tax-income-statements/my-tax-income-statements.d.ts +30 -0
- package/lib/models/report/my-tax/my-tax-income-tests/my-tax-income-tests.d.ts +7 -0
- package/lib/models/report/my-tax/my-tax-interest/my-tax-interest.d.ts +9 -0
- package/lib/models/report/my-tax/my-tax-losses/my-tax-losses.d.ts +8 -0
- package/lib/models/report/my-tax/my-tax-offsets/my-tax-offsets.d.ts +7 -0
- package/lib/models/report/my-tax/my-tax-other-income/my-tax-other-income.d.ts +13 -0
- package/lib/models/report/my-tax/my-tax-partnerships-and-trusts/my-tax-partnerships-and-trusts.d.ts +17 -0
- package/lib/models/report/my-tax/my-tax-rent/my-tax-rent.d.ts +11 -0
- package/lib/models/report/property/property-report-item.d.ts +2 -1
- package/lib/models/report/vehicle-expense/vehicle-expense.d.ts +2 -1
- package/lib/models/tax-summary/report-item-details.d.ts +2 -1
- package/lib/models/tax-summary/report-item.d.ts +2 -1
- package/lib/models/transaction/transaction.d.ts +3 -1
- package/lib/services/event/sse.service.d.ts +3 -0
- package/lib/services/http/bank/bank-connection/bank-connection.service.d.ts +13 -1
- package/lib/services/http/bank/basiq/basiq-connections-response.interface.d.ts +9 -0
- package/lib/services/http/bank/basiq/basiq-token-response.interface.d.ts +9 -0
- package/lib/services/http/bank/basiq/basiq-token.service.d.ts +17 -0
- package/lib/services/http/bank/basiq/basiq.service.d.ts +20 -11
- package/lib/services/http/rest/rest.service.d.ts +0 -5
- package/lib/services/http/user/user.service.d.ts +0 -1
- package/lib/services/pdf/pdf-from-dom-element/file-settings.d.ts +6 -0
- package/lib/services/pdf/pdf-from-dom-element/pdf-from-dom-element.service.d.ts +13 -0
- package/lib/services/pdf/pdf-from-table/file-settings.d.ts +8 -0
- package/lib/services/pdf/pdf-from-table/pdf-from-data-table/pdf-from-data-table.service.d.ts +19 -0
- package/lib/services/pdf/pdf-from-table/pdf-from-html-table/pdf-from-html-table.service.d.ts +15 -0
- package/lib/services/pdf/pdf-from-table/pdf-from-table.service.d.ts +16 -0
- package/lib/validators/date-range.validator.d.ts +5 -0
- package/lib/validators/index.d.ts +2 -0
- package/lib/validators/require-autocomplete.d.ts +5 -0
- package/lib/validators/require-select.validator.d.ts +5 -0
- package/package.json +2 -1
- package/public-api.d.ts +26 -1
- package/esm2015/lib/models/pdf/pdf-config.js +0 -43
- package/esm2015/lib/services/pdf/pdf.service.js +0 -99
- package/lib/models/pdf/pdf-config.d.ts +0 -8
- package/lib/services/pdf/pdf.service.d.ts +0 -29
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { PdfSettings } from '../../../models/pdf/pdf-settings';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
/**
|
|
5
|
+
* Service to generate and export PDF file from provided HTML elements
|
|
6
|
+
* The file is generated using the html2pdf library in order to get a canvas at the output,
|
|
7
|
+
* in which all the styles that the user sees on the page will be saved
|
|
8
|
+
*/
|
|
9
|
+
export declare class PdfFromDomElementService {
|
|
10
|
+
export(elements: NodeListOf<HTMLElement>, fileSettings: PdfSettings): Observable<unknown>;
|
|
11
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<PdfFromDomElementService, never>;
|
|
12
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<PdfFromDomElementService>;
|
|
13
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { ExportDataTable } from '../../../../models/export/export-data-table';
|
|
2
|
+
import { PdfSettings } from '../../../../models/pdf/pdf-settings';
|
|
3
|
+
import { ExportFormatterService } from '../../../export/export-formatter.service';
|
|
4
|
+
import { PdfFromTableService } from '../pdf-from-table.service';
|
|
5
|
+
import * as i0 from "@angular/core";
|
|
6
|
+
/**
|
|
7
|
+
* Service to generate and export PDF file from provided array-like data tables
|
|
8
|
+
*/
|
|
9
|
+
export declare class PdfFromDataTableService extends PdfFromTableService {
|
|
10
|
+
private formatter;
|
|
11
|
+
constructor(formatter: ExportFormatterService);
|
|
12
|
+
export(dataTables: ExportDataTable[], fileSettings: PdfSettings): void;
|
|
13
|
+
/**
|
|
14
|
+
* Generate PDF file from provided list of data tables
|
|
15
|
+
*/
|
|
16
|
+
private generate;
|
|
17
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<PdfFromDataTableService, never>;
|
|
18
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<PdfFromDataTableService>;
|
|
19
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { PdfSettings } from '../../../../models/pdf/pdf-settings';
|
|
2
|
+
import { PdfFromTableService } from '../pdf-from-table.service';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
/**
|
|
5
|
+
* Service to generate and export PDF file from provided HTML tables
|
|
6
|
+
*/
|
|
7
|
+
export declare class PdfFromHtmlTableService extends PdfFromTableService {
|
|
8
|
+
export(tables: NodeListOf<HTMLTableElement>, fileSettings: PdfSettings): void;
|
|
9
|
+
/**
|
|
10
|
+
* Generate PDF file from provided list of HTML tables
|
|
11
|
+
*/
|
|
12
|
+
private generateFile;
|
|
13
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<PdfFromHtmlTableService, never>;
|
|
14
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<PdfFromHtmlTableService>;
|
|
15
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import jsPDF from 'jspdf';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
/**
|
|
4
|
+
* Service with base functionality to export tables (HTML table, data-table, e.t.c.) as PDF file
|
|
5
|
+
* The file is generated using the jsPDF library to set custom table styles
|
|
6
|
+
*/
|
|
7
|
+
export declare class PdfFromTableService {
|
|
8
|
+
/**
|
|
9
|
+
* Set basic options for PDF table
|
|
10
|
+
*/
|
|
11
|
+
protected setTableOptions(pdf: jsPDF, tableCaption?: string): object;
|
|
12
|
+
protected setDocumentTitle(doc: jsPDF, title?: string): void;
|
|
13
|
+
protected setDocumentLogo(doc: jsPDF): void;
|
|
14
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<PdfFromTableService, never>;
|
|
15
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<PdfFromTableService>;
|
|
16
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "taxtank-core",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.19.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"peerDependencies": {
|
|
6
6
|
"@angular/common": "^12.2.3 || ~13.0.0",
|
|
@@ -15,6 +15,7 @@
|
|
|
15
15
|
"moment-range": "^4.0.2",
|
|
16
16
|
"lodash": "^4.17.21",
|
|
17
17
|
"jspdf": "^2.4.0",
|
|
18
|
+
"html2pdf.js": "^0.10.1",
|
|
18
19
|
"jspdf-autotable": "^3.5.23",
|
|
19
20
|
"xlsx": "^0.17.4",
|
|
20
21
|
"file-saver": "^2.0.5"
|
package/public-api.d.ts
CHANGED
|
@@ -1,9 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Public API Surface of tt-core
|
|
3
|
+
*/
|
|
1
4
|
export * from './lib/tt-core.module';
|
|
2
5
|
/**
|
|
3
6
|
* Collections
|
|
4
7
|
*/
|
|
5
8
|
export * from './lib/collections/collection';
|
|
6
9
|
export * from './lib/collections/account-setup-item.collection';
|
|
10
|
+
export * from './lib/collections/bank.collection';
|
|
7
11
|
export * from './lib/collections/bank-account.collection';
|
|
8
12
|
export * from './lib/collections/bank-transaction.collection';
|
|
9
13
|
export * from './lib/collections/client.collection';
|
|
@@ -38,6 +42,7 @@ export * from './lib/collections/exportable.collection';
|
|
|
38
42
|
/**
|
|
39
43
|
* DB models
|
|
40
44
|
*/
|
|
45
|
+
export * from './lib/db/Models/abstract-model';
|
|
41
46
|
export * from './lib/db/Models/transaction/transaction-base';
|
|
42
47
|
/**
|
|
43
48
|
* DB enums
|
|
@@ -51,6 +56,7 @@ export * from './lib/db/Enums/chart-accounts-category.enum';
|
|
|
51
56
|
export * from './lib/db/Enums/chart-accounts-etp.enum';
|
|
52
57
|
export * from './lib/db/Enums/chart-accounts-heading-list.enum';
|
|
53
58
|
export * from './lib/db/Enums/chart-accounts-heading-taxable.enum';
|
|
59
|
+
export * from './lib/db/Enums/chart-accounts-heading-list.enum';
|
|
54
60
|
export * from './lib/db/Enums/chart-accounts-heading-tax-deductible.enum';
|
|
55
61
|
export * from './lib/db/Enums/chart-accounts-heading-vehicle-list.enum';
|
|
56
62
|
export * from './lib/db/Enums/chart-accounts-list.enum';
|
|
@@ -139,6 +145,7 @@ export * from './lib/models/bank/bank-account-chart-data';
|
|
|
139
145
|
export * from './lib/models/bank/bank-account-property';
|
|
140
146
|
export * from './lib/models/bank/bank-account-types.const';
|
|
141
147
|
export * from './lib/models/bank/bank-connection';
|
|
148
|
+
export * from './lib/models/bank/bank-login-data';
|
|
142
149
|
export * from './lib/models/bank/bank-transaction';
|
|
143
150
|
export * from './lib/models/bank/bank-transaction-chart-data';
|
|
144
151
|
export * from './lib/models/bank/bank-transaction-summary-fields.enum';
|
|
@@ -238,6 +245,22 @@ export * from './lib/models/registration-invite/registration-invite';
|
|
|
238
245
|
export * from './lib/models/report/depreciation/depreciation-lvp-report-item';
|
|
239
246
|
export * from './lib/models/report/depreciation/depreciation-report-item';
|
|
240
247
|
export * from './lib/models/report/depreciation/depreciation-lvp-asset-type.enum';
|
|
248
|
+
export * from './lib/models/report/my-tax/ato-links';
|
|
249
|
+
export * from './lib/models/report/my-tax/my-tax-business-or-losses/my-tax-business-or-losses';
|
|
250
|
+
export * from './lib/models/report/my-tax/my-tax-deductions/my-tax-deductions';
|
|
251
|
+
export * from './lib/models/report/my-tax/my-tax-deductions/deduction-clothing-type.enum';
|
|
252
|
+
export * from './lib/models/report/my-tax/my-tax-deductions/deduction-fields.const';
|
|
253
|
+
export * from './lib/models/report/my-tax/my-tax-deductions/deduction-self-education-type.enum';
|
|
254
|
+
export * from './lib/models/report/my-tax/my-tax-dividends/my-tax-dividends';
|
|
255
|
+
export * from './lib/models/report/my-tax/my-tax-employee-share-schemes/my-tax-employee-share-schemes';
|
|
256
|
+
export * from './lib/models/report/my-tax/my-tax-income-statements/my-tax-income-statements';
|
|
257
|
+
export * from './lib/models/report/my-tax/my-tax-income-tests/my-tax-income-tests';
|
|
258
|
+
export * from './lib/models/report/my-tax/my-tax-interest/my-tax-interest';
|
|
259
|
+
export * from './lib/models/report/my-tax/my-tax-losses/my-tax-losses';
|
|
260
|
+
export * from './lib/models/report/my-tax/my-tax-offsets/my-tax-offsets';
|
|
261
|
+
export * from './lib/models/report/my-tax/my-tax-other-income/my-tax-other-income';
|
|
262
|
+
export * from './lib/models/report/my-tax/my-tax-partnerships-and-trusts/my-tax-partnerships-and-trusts';
|
|
263
|
+
export * from './lib/models/report/my-tax/my-tax-rent/my-tax-rent';
|
|
241
264
|
export * from './lib/models/report/property/property-report-item';
|
|
242
265
|
export * from './lib/models/report/property/property-report-item-transaction';
|
|
243
266
|
export * from './lib/models/report/vehicle-expense/vehicle-expense';
|
|
@@ -320,7 +343,9 @@ export * from './lib/services/intercom/intercom.service';
|
|
|
320
343
|
export * from './lib/services/kompassify/kompassify.service';
|
|
321
344
|
export * from './lib/services/http/loan/loan.service';
|
|
322
345
|
export * from './lib/services/http/service-notification/service-notification.service';
|
|
323
|
-
export * from './lib/services/pdf/pdf.service';
|
|
346
|
+
export * from './lib/services/pdf/pdf-from-dom-element/pdf-from-dom-element.service';
|
|
347
|
+
export * from './lib/services/pdf/pdf-from-table/pdf-from-html-table/pdf-from-html-table.service';
|
|
348
|
+
export * from './lib/services/pdf/pdf-from-table/pdf-from-data-table/pdf-from-data-table.service';
|
|
324
349
|
export * from './lib/services/preloader/preloader.service';
|
|
325
350
|
export * from './lib/services/report/property/property-transaction-report.service';
|
|
326
351
|
export * from './lib/services/property/corelogic/corelogic.service';
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Configuration file with the settings to generate PDF file
|
|
3
|
-
*/
|
|
4
|
-
export const PDF_CONFIG = {
|
|
5
|
-
text: {
|
|
6
|
-
fontSize: 12,
|
|
7
|
-
fontName: 'helvetica',
|
|
8
|
-
fontStyle: '',
|
|
9
|
-
fontWeight: 'bold',
|
|
10
|
-
positionX: 14,
|
|
11
|
-
positionY: 10,
|
|
12
|
-
colorWhite: '#ffffff',
|
|
13
|
-
colorBlack: '#000000',
|
|
14
|
-
colorPrimary: '#00b7f0'
|
|
15
|
-
},
|
|
16
|
-
logo: {
|
|
17
|
-
src: '/assets/img/icons/logo.png',
|
|
18
|
-
width: 30,
|
|
19
|
-
height: 7,
|
|
20
|
-
positionX: 42,
|
|
21
|
-
positionY: 6
|
|
22
|
-
},
|
|
23
|
-
// coords for file section title (group, table, e.t.c.)
|
|
24
|
-
contentTitleCoords: {
|
|
25
|
-
marginTop: 15
|
|
26
|
-
},
|
|
27
|
-
contentCoords: {
|
|
28
|
-
marginTop: 15,
|
|
29
|
-
marginLeft: 14
|
|
30
|
-
},
|
|
31
|
-
table: {
|
|
32
|
-
headStyles: {
|
|
33
|
-
fillColor: '#00b7f0',
|
|
34
|
-
lineWidth: .2,
|
|
35
|
-
halign: 'center'
|
|
36
|
-
},
|
|
37
|
-
footStyles: {
|
|
38
|
-
fillColor: '#ffffff',
|
|
39
|
-
textColor: '#000000'
|
|
40
|
-
},
|
|
41
|
-
}
|
|
42
|
-
};
|
|
43
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicGRmLWNvbmZpZy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL3R0LWNvcmUvc3JjL2xpYi9tb2RlbHMvcGRmL3BkZi1jb25maWcudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7O0dBRUc7QUFDSCxNQUFNLENB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
|
3
|
-
import autoTable from 'jspdf-autotable';
|
|
4
|
-
import { PDF_CONFIG } from '../../models/pdf/pdf-config';
|
|
5
|
-
import * as i0 from "@angular/core";
|
|
6
|
-
import * as i1 from "../export/export-formatter.service";
|
|
7
|
-
/**
|
|
8
|
-
* @TODO vik refactor
|
|
9
|
-
* Service to work with PDF (generate, download, e.t.c.)
|
|
10
|
-
*/
|
|
11
|
-
export class PdfService {
|
|
12
|
-
constructor(formatter) {
|
|
13
|
-
this.formatter = formatter;
|
|
14
|
-
}
|
|
15
|
-
/**
|
|
16
|
-
* Export file from provided HTML tables
|
|
17
|
-
*/
|
|
18
|
-
exportTables(tables, fileSettings) {
|
|
19
|
-
const document = this.generateFromTables(tables, fileSettings);
|
|
20
|
-
document.save(`${fileSettings.filename}.pdf`);
|
|
21
|
-
}
|
|
22
|
-
/**
|
|
23
|
-
* Export file from provided array-like table data
|
|
24
|
-
*/
|
|
25
|
-
exportFromDataTables(dataTables, fileSettings) {
|
|
26
|
-
const document = this.generateFromDataTables(dataTables, fileSettings.title);
|
|
27
|
-
document.save(`${fileSettings.filename}.pdf`);
|
|
28
|
-
}
|
|
29
|
-
/**
|
|
30
|
-
* Generate file from array-like table data
|
|
31
|
-
*/
|
|
32
|
-
generateFromDataTables(dataTables, title) {
|
|
33
|
-
const pdf = new jsPDF();
|
|
34
|
-
this.setDocumentTitle(pdf, title);
|
|
35
|
-
this.setDocumentLogo(pdf);
|
|
36
|
-
dataTables.forEach((dataTable) => {
|
|
37
|
-
autoTable(pdf, Object.assign({ head: [dataTable.header], body: this.formatter.format(dataTable.body), foot: this.formatter.format(dataTable.footer) }, this.setTableOptions(pdf, dataTable.caption)));
|
|
38
|
-
});
|
|
39
|
-
return pdf;
|
|
40
|
-
}
|
|
41
|
-
generateFromTables(tables, fileSettings) {
|
|
42
|
-
const pdf = new jsPDF(fileSettings.orientation);
|
|
43
|
-
this.setDocumentTitle(pdf, fileSettings.title);
|
|
44
|
-
this.setDocumentLogo(pdf);
|
|
45
|
-
tables.forEach((table) => {
|
|
46
|
-
// Add table caption if not provided
|
|
47
|
-
if (!table.caption) {
|
|
48
|
-
table.createCaption();
|
|
49
|
-
table.caption.innerText = '';
|
|
50
|
-
}
|
|
51
|
-
autoTable(pdf, Object.assign({ html: table }, this.setTableOptions(pdf, table.caption.innerText)));
|
|
52
|
-
});
|
|
53
|
-
return pdf;
|
|
54
|
-
}
|
|
55
|
-
/**
|
|
56
|
-
* Set basic options for PDF table
|
|
57
|
-
*/
|
|
58
|
-
setTableOptions(pdf, tableCaption = '') {
|
|
59
|
-
const lastTableCoords = pdf['lastAutoTable'].finalY || PDF_CONFIG.contentCoords.marginTop;
|
|
60
|
-
// get caption height based on caption content height
|
|
61
|
-
const captionHeight = pdf.getTextDimensions(pdf.splitTextToSize(tableCaption, pdf.internal.pageSize.width)).h;
|
|
62
|
-
pdf.text(tableCaption, PDF_CONFIG.contentCoords.marginLeft, lastTableCoords + PDF_CONFIG.contentCoords.marginTop);
|
|
63
|
-
return {
|
|
64
|
-
headStyles: {
|
|
65
|
-
fillColor: PDF_CONFIG.text.colorPrimary,
|
|
66
|
-
},
|
|
67
|
-
footStyles: {
|
|
68
|
-
fillColor: PDF_CONFIG.text.colorWhite,
|
|
69
|
-
textColor: PDF_CONFIG.text.colorBlack
|
|
70
|
-
},
|
|
71
|
-
startY: lastTableCoords + captionHeight + PDF_CONFIG.contentTitleCoords.marginTop,
|
|
72
|
-
didParseCell: (data) => {
|
|
73
|
-
// Align last column content to right
|
|
74
|
-
if (data.table.columns.length > 1 && (data.column.index === data.table.columns.length - 1)) {
|
|
75
|
-
data.cell.styles.halign = 'right';
|
|
76
|
-
}
|
|
77
|
-
}
|
|
78
|
-
};
|
|
79
|
-
}
|
|
80
|
-
setDocumentTitle(doc, title) {
|
|
81
|
-
doc.setFontSize(PDF_CONFIG.text.fontSize)
|
|
82
|
-
.setFont(PDF_CONFIG.text.fontName, PDF_CONFIG.text.fontStyle, PDF_CONFIG.text.fontWeight)
|
|
83
|
-
.text(title, PDF_CONFIG.text.positionX, PDF_CONFIG.text.positionY);
|
|
84
|
-
}
|
|
85
|
-
setDocumentLogo(doc) {
|
|
86
|
-
const logo = new Image();
|
|
87
|
-
logo.src = PDF_CONFIG.logo.src;
|
|
88
|
-
doc.addImage(logo, 'PNG', doc.internal.pageSize.width - PDF_CONFIG.logo.positionX, PDF_CONFIG.logo.positionY, PDF_CONFIG.logo.width, PDF_CONFIG.logo.height);
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
PdfService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PdfService, deps: [{ token: i1.ExportFormatterService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
92
|
-
PdfService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PdfService, providedIn: 'root' });
|
|
93
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PdfService, decorators: [{
|
|
94
|
-
type: Injectable,
|
|
95
|
-
args: [{
|
|
96
|
-
providedIn: 'root'
|
|
97
|
-
}]
|
|
98
|
-
}], ctorParameters: function () { return [{ type: i1.ExportFormatterService }]; } });
|
|
99
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicGRmLnNlcnZpY2UuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy90dC1jb3JlL3NyYy9saWIvc2VydmljZXMvcGRmL3BkZi5zZXJ2aWNlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxVQUFVLEVBQUUsTUFBTSxlQUFlLENBQUM7QUFDM0MsT0FBTyxLQUFLLE1BQU0sT0FBTyxDQUFDO0FBQzFCLE9BQU8sU0FBUyxNQUFNLGlCQUFpQixDQUF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vLnNyYztcbiAgICBkb2MuYWRkSW1hZ2UoXG4gICAgICBsb2dvLFxuICAgICAgJ1BORycsXG4gICAgICBkb2MuaW50ZXJuYWwucGFnZVNpemUud2lkdGggLSBQREZfQ09ORklHLmxvZ28ucG9zaXRpb25YLFxuICAgICAgUERGX0NPTkZJRy5sb2dvLnBvc2l0aW9uWSxcbiAgICAgIFBERl9DT05GSUcubG9nby53aWR0aCxcbiAgICAgIFBERl9DT05GSUcubG9nby5oZWlnaHRcbiAgICApXG4gIH1cbn1cbiJdfQ==
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import { ExportDataTable } from '../../models/export/export-data-table';
|
|
2
|
-
import { PdfSettings } from '../../models/pdf/pdf-settings';
|
|
3
|
-
import { ExportFormatterService } from '../export/export-formatter.service';
|
|
4
|
-
import * as i0 from "@angular/core";
|
|
5
|
-
export declare class PdfService {
|
|
6
|
-
private formatter;
|
|
7
|
-
constructor(formatter: ExportFormatterService);
|
|
8
|
-
/**
|
|
9
|
-
* Export file from provided HTML tables
|
|
10
|
-
*/
|
|
11
|
-
exportTables(tables: NodeListOf<HTMLTableElement>, fileSettings: PdfSettings): void;
|
|
12
|
-
/**
|
|
13
|
-
* Export file from provided array-like table data
|
|
14
|
-
*/
|
|
15
|
-
exportFromDataTables(dataTables: ExportDataTable[], fileSettings: PdfSettings): void;
|
|
16
|
-
/**
|
|
17
|
-
* Generate file from array-like table data
|
|
18
|
-
*/
|
|
19
|
-
private generateFromDataTables;
|
|
20
|
-
private generateFromTables;
|
|
21
|
-
/**
|
|
22
|
-
* Set basic options for PDF table
|
|
23
|
-
*/
|
|
24
|
-
private setTableOptions;
|
|
25
|
-
private setDocumentTitle;
|
|
26
|
-
private setDocumentLogo;
|
|
27
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<PdfService, never>;
|
|
28
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<PdfService>;
|
|
29
|
-
}
|