@tomei/finance 0.16.0 → 0.17.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.
Files changed (75) hide show
  1. package/.commitlintrc.json +23 -23
  2. package/LICENSE +21 -21
  3. package/configs/config.js +348 -348
  4. package/dist/document/document.js +2 -2
  5. package/dist/document/document.js.map +1 -1
  6. package/dist/enum/quick-book-client-scopes.enum.d.ts +0 -1
  7. package/dist/enum/quick-book-client-scopes.enum.js +1 -34
  8. package/dist/enum/quick-book-client-scopes.enum.js.map +1 -1
  9. package/dist/interfaces/account-system.interface.d.ts +1 -0
  10. package/dist/interfaces/account-system.interface.d.ts.map +1 -1
  11. package/dist/journal-entry/journal-entry.d.ts.map +1 -1
  12. package/dist/journal-entry/journal-entry.js +2 -2
  13. package/dist/journal-entry/journal-entry.js.map +1 -1
  14. package/dist/ledger-transaction/ledger-transaction.d.ts.map +1 -1
  15. package/dist/ledger-transaction/ledger-transaction.js +2 -2
  16. package/dist/ledger-transaction/ledger-transaction.js.map +1 -1
  17. package/dist/tsconfig.tsbuildinfo +1 -1
  18. package/invoice-template/assets/css/style.css.map +12 -12
  19. package/invoice-template/assets/css/style.min.css +1 -1
  20. package/invoice-template/assets/img/arrow_bg.svg +11 -11
  21. package/invoice-template/assets/img/coffy_shop_img.svg +18 -18
  22. package/invoice-template/assets/img/logo_accent.svg +3 -3
  23. package/invoice-template/assets/img/logo_white.svg +4 -4
  24. package/invoice-template/assets/img/sign.svg +12 -12
  25. package/invoice-template/assets/img/tomei-logo.svg +9 -9
  26. package/invoice-template/assets/js/html2canvas.min.js +10379 -10379
  27. package/invoice-template/assets/js/jquery.min.js +1 -1
  28. package/invoice-template/assets/sass/common/_color_variable.scss +12 -12
  29. package/invoice-template/assets/sass/common/_typography.scss +178 -178
  30. package/invoice-template/assets/sass/style.scss +12 -12
  31. package/migrations/add-discount-collumn-to-document-related-table.js +90 -90
  32. package/migrations/finance-account-migration.js +97 -97
  33. package/migrations/finance-company-migration.js +29 -29
  34. package/migrations/finance-customer-migration.js +51 -51
  35. package/migrations/finance-document-item-migration.js +111 -111
  36. package/migrations/finance-document-migration.js +122 -122
  37. package/migrations/finance-document-tag-migration.js +46 -46
  38. package/migrations/finance-journal-entry-migration.js +59 -59
  39. package/migrations/finance-ledger-transaction-migration.js +89 -89
  40. package/migrations/finance-payment-item-migration.js +52 -52
  41. package/migrations/finance-payment-method-migration.js +31 -31
  42. package/migrations/finance-payment-method-type-migration.js +55 -55
  43. package/migrations/finance-payment-migration.js +96 -96
  44. package/migrations/finance-post-history-migration.js +45 -45
  45. package/migrations/finance-tag-group-migration.js +53 -53
  46. package/migrations/finance-tag-migration.js +63 -63
  47. package/migrations/finance-tax-migration.js +52 -52
  48. package/migrations/refactor-finance-document-migration.js +71 -71
  49. package/migrations/update-document-item.migration.js +87 -87
  50. package/package.json +79 -79
  51. package/receipt-template/default/assets/css/style.css +2629 -2629
  52. package/receipt-template/default/assets/css/style.css.map +12 -12
  53. package/receipt-template/default/assets/css/style.min.css +1 -1
  54. package/receipt-template/default/assets/img/arrow_bg.svg +11 -11
  55. package/receipt-template/default/assets/img/coffy_shop_img.svg +18 -18
  56. package/receipt-template/default/assets/img/logo.svg +4 -4
  57. package/receipt-template/default/assets/img/logo_accent.svg +3 -3
  58. package/receipt-template/default/assets/img/logo_white.svg +4 -4
  59. package/receipt-template/default/assets/img/sign.svg +12 -12
  60. package/receipt-template/default/assets/img/tomei-logo.svg +9 -9
  61. package/receipt-template/default/assets/js/html2canvas.min.js +10379 -10379
  62. package/receipt-template/default/assets/js/jquery.min.js +1 -1
  63. package/receipt-template/default/assets/js/main.js +48 -48
  64. package/receipt-template/default/assets/sass/common/_color_variable.scss +12 -12
  65. package/receipt-template/default/assets/sass/common/_invoice.scss +1801 -1801
  66. package/receipt-template/default/assets/sass/common/_normalize.scss +350 -350
  67. package/receipt-template/default/assets/sass/common/_typography.scss +178 -178
  68. package/receipt-template/default/assets/sass/style.scss +12 -12
  69. package/receipt-template/default/index.html +291 -291
  70. package/scripts/postinstall.js +300 -300
  71. package/dist/enum/quick-book-client-scopes.enum.d.ts.map +0 -1
  72. package/dist/helpers/chrome-browser-pool.d.ts +0 -17
  73. package/dist/helpers/chrome-browser-pool.d.ts.map +0 -1
  74. package/dist/helpers/chrome-browser-pool.js +0 -109
  75. package/dist/helpers/chrome-browser-pool.js.map +0 -1
@@ -1,87 +1,87 @@
1
- 'use strict';
2
-
3
- module.exports = {
4
- up: async (queryInterface, Sequelize) => {
5
- const transaction = await queryInterface.sequelize.transaction();
6
- try {
7
- await queryInterface.addColumn(
8
- 'finance_DocumentItem',
9
- 'AccSystemRefId',
10
- {
11
- allowNull: false,
12
- type: Sequelize.STRING(30),
13
- defaultValue: 'REF',
14
- },
15
- { transaction },
16
- );
17
- await queryInterface.addColumn(
18
- 'finance_DocumentItem',
19
- 'PostedToAccSystemYN',
20
- {
21
- allowNull: false,
22
- type: Sequelize.CHAR(1),
23
- defaultValue: 'N',
24
- },
25
- { transaction },
26
- );
27
- await queryInterface.addColumn(
28
- 'finance_DocumentItem',
29
- 'PostedById',
30
- {
31
- allowNull: true,
32
- type: Sequelize.STRING(30),
33
- },
34
- { transaction },
35
- );
36
- await queryInterface.addColumn(
37
- 'finance_DocumentItem',
38
- 'PostedDateTime',
39
- {
40
- allowNull: true,
41
- type: Sequelize.DATE,
42
- },
43
- { transaction },
44
- );
45
-
46
- await transaction.commit();
47
- } catch (error) {
48
- await transaction.rollback();
49
- throw error;
50
- }
51
- },
52
-
53
- down: async (queryInterface) => {
54
- const transaction = await queryInterface.sequelize.transaction();
55
- try {
56
- await queryInterface.removeColumn(
57
- 'finance_DocumentItem',
58
- 'AccSystemRefId',
59
- {
60
- transaction: t,
61
- },
62
- );
63
- await queryInterface.removeColumn(
64
- 'finance_DocumentItem',
65
- 'PostedToAccSystemYN',
66
- {
67
- transaction: t,
68
- },
69
- );
70
- await queryInterface.removeColumn('finance_DocumentItem', 'PostedById', {
71
- transaction: t,
72
- });
73
- await queryInterface.removeColumn(
74
- 'finance_DocumentItem',
75
- 'PostedDateTime',
76
- {
77
- transaction: t,
78
- },
79
- );
80
-
81
- await transaction.commit();
82
- } catch (error) {
83
- await transaction.rollback();
84
- throw error;
85
- }
86
- },
87
- };
1
+ 'use strict';
2
+
3
+ module.exports = {
4
+ up: async (queryInterface, Sequelize) => {
5
+ const transaction = await queryInterface.sequelize.transaction();
6
+ try {
7
+ await queryInterface.addColumn(
8
+ 'finance_DocumentItem',
9
+ 'AccSystemRefId',
10
+ {
11
+ allowNull: false,
12
+ type: Sequelize.STRING(30),
13
+ defaultValue: 'REF',
14
+ },
15
+ { transaction },
16
+ );
17
+ await queryInterface.addColumn(
18
+ 'finance_DocumentItem',
19
+ 'PostedToAccSystemYN',
20
+ {
21
+ allowNull: false,
22
+ type: Sequelize.CHAR(1),
23
+ defaultValue: 'N',
24
+ },
25
+ { transaction },
26
+ );
27
+ await queryInterface.addColumn(
28
+ 'finance_DocumentItem',
29
+ 'PostedById',
30
+ {
31
+ allowNull: true,
32
+ type: Sequelize.STRING(30),
33
+ },
34
+ { transaction },
35
+ );
36
+ await queryInterface.addColumn(
37
+ 'finance_DocumentItem',
38
+ 'PostedDateTime',
39
+ {
40
+ allowNull: true,
41
+ type: Sequelize.DATE,
42
+ },
43
+ { transaction },
44
+ );
45
+
46
+ await transaction.commit();
47
+ } catch (error) {
48
+ await transaction.rollback();
49
+ throw error;
50
+ }
51
+ },
52
+
53
+ down: async (queryInterface) => {
54
+ const transaction = await queryInterface.sequelize.transaction();
55
+ try {
56
+ await queryInterface.removeColumn(
57
+ 'finance_DocumentItem',
58
+ 'AccSystemRefId',
59
+ {
60
+ transaction: t,
61
+ },
62
+ );
63
+ await queryInterface.removeColumn(
64
+ 'finance_DocumentItem',
65
+ 'PostedToAccSystemYN',
66
+ {
67
+ transaction: t,
68
+ },
69
+ );
70
+ await queryInterface.removeColumn('finance_DocumentItem', 'PostedById', {
71
+ transaction: t,
72
+ });
73
+ await queryInterface.removeColumn(
74
+ 'finance_DocumentItem',
75
+ 'PostedDateTime',
76
+ {
77
+ transaction: t,
78
+ },
79
+ );
80
+
81
+ await transaction.commit();
82
+ } catch (error) {
83
+ await transaction.rollback();
84
+ throw error;
85
+ }
86
+ },
87
+ };
package/package.json CHANGED
@@ -1,79 +1,79 @@
1
- {
2
- "name": "@tomei/finance",
3
- "version": "0.16.0",
4
- "description": "NestJS package for finance module",
5
- "main": "dist/index.js",
6
- "scripts": {
7
- "start:dev": "tsc -w",
8
- "build": "tsc",
9
- "postinstall": "node scripts/postinstall.js",
10
- "test:package": "node test-package.js",
11
- "prepare": "husky install",
12
- "format": "prettier --write \"src/**/*.ts\"",
13
- "lint": "npx eslint . --fix",
14
- "test": "jest",
15
- "test:watch": "jest --watch",
16
- "test:cov": "jest --coverage",
17
- "test:e2e": "jest --config ./test/jest-e2e.json"
18
- },
19
- "keywords": [
20
- "tomei",
21
- "finance"
22
- ],
23
- "author": "Fadhil Muhammad <fadhil@tomei.com.my>",
24
- "license": "ISC",
25
- "repository": {
26
- "type": "git",
27
- "url": "https://gitlab.com/tomei-package/finance.git"
28
- },
29
- "publishConfig": {
30
- "access": "public"
31
- },
32
- "peerDependencies": {
33
- "@nestjs/common": "^10.4.20",
34
- "@nestjs/swagger": "^8.1.1",
35
- "@paralleldrive/cuid2": "^2.2.2",
36
- "@tomei/activity-history": "^0.4.4",
37
- "@tomei/config": "^0.3.22",
38
- "@tomei/general": "^0.21.10",
39
- "@tomei/media": "^0.10.0",
40
- "@tomei/sso": "^0.65.0",
41
- "axios": "^1.12.2",
42
- "dotenv": "^16.6.1",
43
- "intuit-oauth": "^4.2.0",
44
- "puppeteer": "^24.22.3",
45
- "sequelize": "^6.37.7",
46
- "sequelize-typescript": "^2.1.6"
47
- },
48
- "devDependencies": {
49
- "@commitlint/cli": "^19.8.1",
50
- "@commitlint/config-conventional": "^19.8.1",
51
- "@eslint/js": "^9.36.0",
52
- "@types/multer": "^1.4.13",
53
- "@types/node": "^22.18.8",
54
- "@types/sequelize": "^4.28.20",
55
- "@typescript-eslint/eslint-plugin": "^8.45.0",
56
- "eslint": "^9.36.0",
57
- "eslint-config-prettier": "^9.1.2",
58
- "eslint-plugin-import": "^2.32.0",
59
- "eslint-plugin-prettier": "^5.5.4",
60
- "globals": "^15.15.0",
61
- "husky": "^9.1.7",
62
- "lint-staged": "^15.5.2",
63
- "prettier": "^3.6.2",
64
- "ts-node": "^10.9.2",
65
- "tsc-watch": "^6.3.1",
66
- "tsconfig-paths": "^4.2.0",
67
- "typescript": "^5.9.3",
68
- "typescript-eslint": "^8.45.0"
69
- },
70
- "lint-staged": {
71
- "*/**/*.{js,ts,tsx}": [
72
- "npm run lint",
73
- "npm run eslint",
74
- "npm run format",
75
- "npm run build",
76
- "git add ."
77
- ]
78
- }
79
- }
1
+ {
2
+ "name": "@tomei/finance",
3
+ "version": "0.17.0",
4
+ "description": "NestJS package for finance module",
5
+ "main": "dist/index.js",
6
+ "scripts": {
7
+ "start:dev": "tsc -w",
8
+ "build": "tsc",
9
+ "postinstall": "node scripts/postinstall.js",
10
+ "test:package": "node test-package.js",
11
+ "prepare": "husky install",
12
+ "format": "prettier --write \"src/**/*.ts\"",
13
+ "lint": "npx eslint . --fix",
14
+ "test": "jest",
15
+ "test:watch": "jest --watch",
16
+ "test:cov": "jest --coverage",
17
+ "test:e2e": "jest --config ./test/jest-e2e.json"
18
+ },
19
+ "keywords": [
20
+ "tomei",
21
+ "finance"
22
+ ],
23
+ "author": "Fadhil Muhammad <fadhil@tomei.com.my>",
24
+ "license": "ISC",
25
+ "repository": {
26
+ "type": "git",
27
+ "url": "https://gitlab.com/tomei-package/finance.git"
28
+ },
29
+ "publishConfig": {
30
+ "access": "public"
31
+ },
32
+ "peerDependencies": {
33
+ "@nestjs/common": "^10.4.20",
34
+ "@nestjs/swagger": "^8.1.1",
35
+ "@paralleldrive/cuid2": "^2.2.2",
36
+ "@tomei/activity-history": "^0.4.4",
37
+ "@tomei/config": "^0.3.22",
38
+ "@tomei/general": "^0.21.10",
39
+ "@tomei/media": "^0.10.0",
40
+ "@tomei/sso": "^0.65.0",
41
+ "axios": "^1.12.2",
42
+ "dotenv": "^16.6.1",
43
+ "intuit-oauth": "^4.2.0",
44
+ "puppeteer": "^24.22.3",
45
+ "sequelize": "^6.37.7",
46
+ "sequelize-typescript": "^2.1.6"
47
+ },
48
+ "devDependencies": {
49
+ "@commitlint/cli": "^19.8.1",
50
+ "@commitlint/config-conventional": "^19.8.1",
51
+ "@eslint/js": "^9.36.0",
52
+ "@types/multer": "^1.4.13",
53
+ "@types/node": "^22.18.8",
54
+ "@types/sequelize": "^4.28.20",
55
+ "@typescript-eslint/eslint-plugin": "^8.45.0",
56
+ "eslint": "^9.36.0",
57
+ "eslint-config-prettier": "^9.1.2",
58
+ "eslint-plugin-import": "^2.32.0",
59
+ "eslint-plugin-prettier": "^5.5.4",
60
+ "globals": "^15.15.0",
61
+ "husky": "^9.1.7",
62
+ "lint-staged": "^15.5.2",
63
+ "prettier": "^3.6.2",
64
+ "ts-node": "^10.9.2",
65
+ "tsc-watch": "^6.3.1",
66
+ "tsconfig-paths": "^4.2.0",
67
+ "typescript": "^5.9.3",
68
+ "typescript-eslint": "^8.45.0"
69
+ },
70
+ "lint-staged": {
71
+ "*/**/*.{js,ts,tsx}": [
72
+ "npm run lint",
73
+ "npm run eslint",
74
+ "npm run format",
75
+ "npm run build",
76
+ "git add ."
77
+ ]
78
+ }
79
+ }