@tomei/finance 0.6.79 → 0.6.80
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.commitlintrc.json +22 -22
- package/.eslintrc.js +72 -72
- package/.gitlab-ci.yml +16 -16
- package/.husky/commit-msg +4 -4
- package/.husky/pre-commit +4 -4
- package/.prettierrc +4 -4
- package/CONTRIBUTING.md +30 -30
- package/LICENSE +21 -21
- package/README.md +13 -13
- package/configs/config.js +348 -348
- package/dist/document/document.d.ts +1 -1
- package/dist/document/document.js +6 -2
- package/dist/document/document.js.map +1 -1
- package/dist/payment-item/payment-item.js +4 -4
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/invoice-template/assets/css/style.css.map +12 -12
- package/invoice-template/assets/css/style.min.css +1 -1
- package/invoice-template/assets/img/arrow_bg.svg +11 -11
- package/invoice-template/assets/img/coffy_shop_img.svg +18 -18
- package/invoice-template/assets/img/logo_accent.svg +3 -3
- package/invoice-template/assets/img/logo_white.svg +4 -4
- package/invoice-template/assets/img/sign.svg +12 -12
- package/invoice-template/assets/img/tomei-logo.svg +9 -9
- package/invoice-template/assets/js/html2canvas.min.js +10379 -10379
- package/invoice-template/assets/js/jquery.min.js +1 -1
- package/invoice-template/assets/sass/common/_color_variable.scss +12 -12
- package/invoice-template/assets/sass/common/_typography.scss +178 -178
- package/invoice-template/assets/sass/style.scss +12 -12
- package/migrations/finance-account-migration.js +97 -97
- package/migrations/finance-company-migration.js +29 -29
- package/migrations/finance-customer-migration.js +51 -51
- package/migrations/finance-document-item-migration.js +111 -111
- package/migrations/finance-document-migration.js +122 -122
- package/migrations/finance-journal-entry-migration.js +59 -59
- package/migrations/finance-ledger-transaction-migration.js +89 -89
- package/migrations/finance-payment-item-migration.js +52 -52
- package/migrations/finance-payment-method-migration.js +31 -31
- package/migrations/finance-payment-method-type-migration.js +55 -55
- package/migrations/finance-payment-migration.js +96 -96
- package/migrations/finance-post-history-migration.js +45 -45
- package/migrations/finance-tax-migration.js +52 -52
- package/migrations/refactor-finance-document-migration.js +71 -71
- package/nest-cli.json +19 -19
- package/package.json +82 -82
- package/sonar-project.properties +12 -12
- package/src/account/account.repository.ts +11 -11
- package/src/account/account.ts +276 -276
- package/src/account/interfaces/account-attr.interface.ts +31 -31
- package/src/account-system-entity/account-system-entity.ts +66 -66
- package/src/account-system-entity/post-history.repository.ts +11 -11
- package/src/config.ts +382 -382
- package/src/customer/customer.ts +299 -299
- package/src/customer/finance-customer.repository.ts +13 -13
- package/src/customer/interfaces/customer.repository.interface.ts +3 -3
- package/src/customer/interfaces/finance-customer-attr.interface.ts +10 -10
- package/src/customer/interfaces/finance-customer.repository.interface.ts +4 -4
- package/src/database.ts +48 -48
- package/src/document/document-item.repository.ts +11 -11
- package/src/document/document.repository.ts +11 -11
- package/src/document/document.ts +17 -13
- package/src/document/interfaces/document-attr.interface.ts +28 -28
- package/src/document/interfaces/document-item-attr.interface.ts +22 -22
- package/src/document/interfaces/document-item.repository.interface.ts +4 -4
- package/src/enum/collect-payment-type.ts +3 -3
- package/src/enum/doc-type.enum.ts +8 -8
- package/src/enum/index.ts +19 -19
- package/src/enum/payment-method.enum.ts +3 -3
- package/src/enum/payment-type.enum.ts +4 -4
- package/src/enum/quick-book-client-scopes.enum.ts +14 -14
- package/src/finance-company/finance-company.repository.ts +11 -11
- package/src/finance-company/finance-company.ts +2229 -2229
- package/src/helpers/login-user.ts +38 -38
- package/src/helpers/typeof.ts +35 -35
- package/src/index.ts +32 -32
- package/src/interfaces/account-system.interface.ts +20 -20
- package/src/interfaces/index.ts +3 -3
- package/src/models/account.entity.ts +206 -206
- package/src/models/customer.entity.ts +93 -93
- package/src/models/document-item.entity.ts +143 -143
- package/src/models/document.entity.ts +211 -211
- package/src/models/finance-company.entity.ts +29 -29
- package/src/models/journal-entry.entity.ts +110 -110
- package/src/models/ledger-transaction.entity.ts +148 -148
- package/src/models/payment-item.entity.ts +60 -60
- package/src/models/payment-method-type.entity.ts +70 -70
- package/src/models/payment-method.entity.ts +51 -51
- package/src/models/payment.entity.ts +165 -165
- package/src/models/post-history.entity.ts +41 -41
- package/src/models/tax.entity.ts +75 -75
- package/src/payment/interfaces/payment-attr.interface.ts +23 -23
- package/src/payment/interfaces/payment-params.interface.ts +8 -8
- package/src/payment/payment.repository.ts +11 -11
- package/src/payment/payment.ts +236 -236
- package/src/payment-item/interfaces/payment-item-attr.interface.ts +10 -10
- package/src/payment-item/payment-item.repository.ts +11 -11
- package/src/payment-item/payment-item.ts +134 -134
- package/src/payment-method/payment-method.repository.ts +11 -11
- package/src/payment-method-type/payment-method-type.repository.ts +11 -11
- package/src/tax/interfaces/tax-attr.interface.ts +10 -10
- package/src/tax/tax.repository.ts +11 -11
- package/src/tax/tax.ts +69 -69
- package/src/test-document.ts +25 -25
- package/src/test.ts +3 -3
- package/tsconfig.build.json +4 -4
- package/tsconfig.json +22 -22
- package/tslint.json +18 -18
package/src/database.ts
CHANGED
|
@@ -1,48 +1,48 @@
|
|
|
1
|
-
import { Sequelize, SequelizeOptions } from 'sequelize-typescript';
|
|
2
|
-
import AccountModel from './models/account.entity';
|
|
3
|
-
import FinanceCustomerModel from './models/customer.entity';
|
|
4
|
-
import DocumentItemModel from './models/document-item.entity';
|
|
5
|
-
import DocumentModel from './models/document.entity';
|
|
6
|
-
import FinanceCompanyModel from './models/finance-company.entity';
|
|
7
|
-
import JournalEntryModel from './models/journal-entry.entity';
|
|
8
|
-
import LedgerTransactionModel from './models/ledger-transaction.entity';
|
|
9
|
-
import PaymentItemModel from './models/payment-item.entity';
|
|
10
|
-
import PaymentMethodTypeModel from './models/payment-method-type.entity';
|
|
11
|
-
import PaymentMethodModel from './models/payment-method.entity';
|
|
12
|
-
import PaymentPaidWithModel from './models/payment-paid-with.entity';
|
|
13
|
-
import PaymentModel from './models/payment.entity';
|
|
14
|
-
import FinancePostHistoryModel from './models/post-history.entity';
|
|
15
|
-
import { MediasModel } from '@tomei/media';
|
|
16
|
-
import ActivityHistoryModel from '@tomei/activity-history/dist/src/models/activity-history.entity';
|
|
17
|
-
import FinanceTaxModel from './models/tax.entity';
|
|
18
|
-
|
|
19
|
-
let sequelize: Sequelize;
|
|
20
|
-
|
|
21
|
-
function init(sequelizeOptions: SequelizeOptions) {
|
|
22
|
-
sequelize = new Sequelize(sequelizeOptions);
|
|
23
|
-
|
|
24
|
-
sequelize.addModels([
|
|
25
|
-
AccountModel,
|
|
26
|
-
FinanceCustomerModel,
|
|
27
|
-
DocumentItemModel,
|
|
28
|
-
DocumentModel,
|
|
29
|
-
FinanceCompanyModel,
|
|
30
|
-
JournalEntryModel,
|
|
31
|
-
LedgerTransactionModel,
|
|
32
|
-
PaymentItemModel,
|
|
33
|
-
PaymentMethodTypeModel,
|
|
34
|
-
PaymentMethodModel,
|
|
35
|
-
PaymentPaidWithModel,
|
|
36
|
-
PaymentModel,
|
|
37
|
-
FinancePostHistoryModel,
|
|
38
|
-
MediasModel,
|
|
39
|
-
ActivityHistoryModel,
|
|
40
|
-
FinanceTaxModel,
|
|
41
|
-
]);
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
function getConnection() {
|
|
45
|
-
return sequelize;
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
export { init, getConnection };
|
|
1
|
+
import { Sequelize, SequelizeOptions } from 'sequelize-typescript';
|
|
2
|
+
import AccountModel from './models/account.entity';
|
|
3
|
+
import FinanceCustomerModel from './models/customer.entity';
|
|
4
|
+
import DocumentItemModel from './models/document-item.entity';
|
|
5
|
+
import DocumentModel from './models/document.entity';
|
|
6
|
+
import FinanceCompanyModel from './models/finance-company.entity';
|
|
7
|
+
import JournalEntryModel from './models/journal-entry.entity';
|
|
8
|
+
import LedgerTransactionModel from './models/ledger-transaction.entity';
|
|
9
|
+
import PaymentItemModel from './models/payment-item.entity';
|
|
10
|
+
import PaymentMethodTypeModel from './models/payment-method-type.entity';
|
|
11
|
+
import PaymentMethodModel from './models/payment-method.entity';
|
|
12
|
+
import PaymentPaidWithModel from './models/payment-paid-with.entity';
|
|
13
|
+
import PaymentModel from './models/payment.entity';
|
|
14
|
+
import FinancePostHistoryModel from './models/post-history.entity';
|
|
15
|
+
import { MediasModel } from '@tomei/media';
|
|
16
|
+
import ActivityHistoryModel from '@tomei/activity-history/dist/src/models/activity-history.entity';
|
|
17
|
+
import FinanceTaxModel from './models/tax.entity';
|
|
18
|
+
|
|
19
|
+
let sequelize: Sequelize;
|
|
20
|
+
|
|
21
|
+
function init(sequelizeOptions: SequelizeOptions) {
|
|
22
|
+
sequelize = new Sequelize(sequelizeOptions);
|
|
23
|
+
|
|
24
|
+
sequelize.addModels([
|
|
25
|
+
AccountModel,
|
|
26
|
+
FinanceCustomerModel,
|
|
27
|
+
DocumentItemModel,
|
|
28
|
+
DocumentModel,
|
|
29
|
+
FinanceCompanyModel,
|
|
30
|
+
JournalEntryModel,
|
|
31
|
+
LedgerTransactionModel,
|
|
32
|
+
PaymentItemModel,
|
|
33
|
+
PaymentMethodTypeModel,
|
|
34
|
+
PaymentMethodModel,
|
|
35
|
+
PaymentPaidWithModel,
|
|
36
|
+
PaymentModel,
|
|
37
|
+
FinancePostHistoryModel,
|
|
38
|
+
MediasModel,
|
|
39
|
+
ActivityHistoryModel,
|
|
40
|
+
FinanceTaxModel,
|
|
41
|
+
]);
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
function getConnection() {
|
|
45
|
+
return sequelize;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
export { init, getConnection };
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { RepositoryBase, IRepositoryBase } from '@tomei/general';
|
|
2
|
-
import DocumentItemModel from '../models/document-item.entity';
|
|
3
|
-
|
|
4
|
-
export class DocumentItemRepository
|
|
5
|
-
extends RepositoryBase<DocumentItemModel>
|
|
6
|
-
implements IRepositoryBase<DocumentItemModel>
|
|
7
|
-
{
|
|
8
|
-
constructor() {
|
|
9
|
-
super(DocumentItemModel);
|
|
10
|
-
}
|
|
11
|
-
}
|
|
1
|
+
import { RepositoryBase, IRepositoryBase } from '@tomei/general';
|
|
2
|
+
import DocumentItemModel from '../models/document-item.entity';
|
|
3
|
+
|
|
4
|
+
export class DocumentItemRepository
|
|
5
|
+
extends RepositoryBase<DocumentItemModel>
|
|
6
|
+
implements IRepositoryBase<DocumentItemModel>
|
|
7
|
+
{
|
|
8
|
+
constructor() {
|
|
9
|
+
super(DocumentItemModel);
|
|
10
|
+
}
|
|
11
|
+
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { RepositoryBase, IRepositoryBase } from '@tomei/general';
|
|
2
|
-
import DocumentModel from '../models/document.entity';
|
|
3
|
-
|
|
4
|
-
export class DocumentRepository
|
|
5
|
-
extends RepositoryBase<DocumentModel>
|
|
6
|
-
implements IRepositoryBase<DocumentModel>
|
|
7
|
-
{
|
|
8
|
-
constructor() {
|
|
9
|
-
super(DocumentModel);
|
|
10
|
-
}
|
|
11
|
-
}
|
|
1
|
+
import { RepositoryBase, IRepositoryBase } from '@tomei/general';
|
|
2
|
+
import DocumentModel from '../models/document.entity';
|
|
3
|
+
|
|
4
|
+
export class DocumentRepository
|
|
5
|
+
extends RepositoryBase<DocumentModel>
|
|
6
|
+
implements IRepositoryBase<DocumentModel>
|
|
7
|
+
{
|
|
8
|
+
constructor() {
|
|
9
|
+
super(DocumentModel);
|
|
10
|
+
}
|
|
11
|
+
}
|
package/src/document/document.ts
CHANGED
|
@@ -627,13 +627,11 @@ export default class Document extends AccountSystemEntity {
|
|
|
627
627
|
<td class="tm_width_4">
|
|
628
628
|
${documentItem.Description}
|
|
629
629
|
</td>
|
|
630
|
-
<td class="tm_width_2">${documentItem.Currency} ${
|
|
631
|
-
|
|
632
|
-
}</td>
|
|
630
|
+
<td class="tm_width_2">${documentItem.Currency} ${documentItem.UnitPrice
|
|
631
|
+
}</td>
|
|
633
632
|
<td class="tm_width_1">${documentItem.Quantity}</td>
|
|
634
|
-
<td class="tm_width_2 tm_text_right">${documentItem.Currency} ${
|
|
635
|
-
|
|
636
|
-
}</td>
|
|
633
|
+
<td class="tm_width_2 tm_text_right">${documentItem.Currency} ${+documentItem.UnitPrice * +documentItem.Quantity
|
|
634
|
+
}</td>
|
|
637
635
|
</tr>
|
|
638
636
|
`;
|
|
639
637
|
});
|
|
@@ -848,13 +846,11 @@ export default class Document extends AccountSystemEntity {
|
|
|
848
846
|
<td class="tm_width_4">
|
|
849
847
|
${documentItem.Description}
|
|
850
848
|
</td>
|
|
851
|
-
<td class="tm_width_2">${documentItem.Currency} ${
|
|
852
|
-
|
|
853
|
-
}</td>
|
|
849
|
+
<td class="tm_width_2">${documentItem.Currency} ${documentItem.UnitPrice
|
|
850
|
+
}</td>
|
|
854
851
|
<td class="tm_width_1">${documentItem.Quantity}</td>
|
|
855
|
-
<td class="tm_width_2 tm_text_right">${documentItem.Currency} ${
|
|
856
|
-
|
|
857
|
-
}</td>
|
|
852
|
+
<td class="tm_width_2 tm_text_right">${documentItem.Currency} ${+documentItem.UnitPrice * +documentItem.Quantity
|
|
853
|
+
}</td>
|
|
858
854
|
</tr>
|
|
859
855
|
`;
|
|
860
856
|
});
|
|
@@ -1150,6 +1146,7 @@ export default class Document extends AccountSystemEntity {
|
|
|
1150
1146
|
page?: number,
|
|
1151
1147
|
row?: number,
|
|
1152
1148
|
search?: IDocumentFindAll,
|
|
1149
|
+
order?: [string, string][]
|
|
1153
1150
|
): Promise<{ count: number; rows: DocumentModel[] }> {
|
|
1154
1151
|
try {
|
|
1155
1152
|
const systemCode =
|
|
@@ -1169,6 +1166,7 @@ export default class Document extends AccountSystemEntity {
|
|
|
1169
1166
|
|
|
1170
1167
|
let options: any = {
|
|
1171
1168
|
transaction: dbTransaction,
|
|
1169
|
+
order: [['CreatedAt', 'DESC']],
|
|
1172
1170
|
};
|
|
1173
1171
|
|
|
1174
1172
|
/*Create an object to store search criteria*/
|
|
@@ -1225,7 +1223,13 @@ export default class Document extends AccountSystemEntity {
|
|
|
1225
1223
|
...options,
|
|
1226
1224
|
limit: row,
|
|
1227
1225
|
offset: row * (page - 1),
|
|
1228
|
-
|
|
1226
|
+
};
|
|
1227
|
+
}
|
|
1228
|
+
|
|
1229
|
+
if (order) {
|
|
1230
|
+
options = {
|
|
1231
|
+
...options,
|
|
1232
|
+
order: order,
|
|
1229
1233
|
};
|
|
1230
1234
|
}
|
|
1231
1235
|
|
|
@@ -1,28 +1,28 @@
|
|
|
1
|
-
import { DocType, DocumentStatus } from '../../enum';
|
|
2
|
-
|
|
3
|
-
export class IDocumentAttr {
|
|
4
|
-
DocNo: string;
|
|
5
|
-
DocType: DocType;
|
|
6
|
-
DocDate: Date;
|
|
7
|
-
CompanyId: string;
|
|
8
|
-
Currency: string;
|
|
9
|
-
Amount: number;
|
|
10
|
-
Description: string;
|
|
11
|
-
Status: DocumentStatus;
|
|
12
|
-
IssuedById: string;
|
|
13
|
-
IssuedToId: string;
|
|
14
|
-
IssuedToType: string;
|
|
15
|
-
RelatedObjectId?: string;
|
|
16
|
-
RelatedObjectType?: string;
|
|
17
|
-
CreatedById: string;
|
|
18
|
-
CreatedAt: Date;
|
|
19
|
-
UpdatedById?: string;
|
|
20
|
-
UpdatedAt?: Date;
|
|
21
|
-
DocPDFFileMediaId?: string;
|
|
22
|
-
DocHTMLFileMediaId?: string;
|
|
23
|
-
AccSystemRefId?: string;
|
|
24
|
-
PostedToAccSystemYN: string;
|
|
25
|
-
PostedById?: string;
|
|
26
|
-
PostedDateTime?: Date;
|
|
27
|
-
UseAccSystemDocYN: string;
|
|
28
|
-
}
|
|
1
|
+
import { DocType, DocumentStatus } from '../../enum';
|
|
2
|
+
|
|
3
|
+
export class IDocumentAttr {
|
|
4
|
+
DocNo: string;
|
|
5
|
+
DocType: DocType;
|
|
6
|
+
DocDate: Date;
|
|
7
|
+
CompanyId: string;
|
|
8
|
+
Currency: string;
|
|
9
|
+
Amount: number;
|
|
10
|
+
Description: string;
|
|
11
|
+
Status: DocumentStatus;
|
|
12
|
+
IssuedById: string;
|
|
13
|
+
IssuedToId: string;
|
|
14
|
+
IssuedToType: string;
|
|
15
|
+
RelatedObjectId?: string;
|
|
16
|
+
RelatedObjectType?: string;
|
|
17
|
+
CreatedById: string;
|
|
18
|
+
CreatedAt: Date;
|
|
19
|
+
UpdatedById?: string;
|
|
20
|
+
UpdatedAt?: Date;
|
|
21
|
+
DocPDFFileMediaId?: string;
|
|
22
|
+
DocHTMLFileMediaId?: string;
|
|
23
|
+
AccSystemRefId?: string;
|
|
24
|
+
PostedToAccSystemYN: string;
|
|
25
|
+
PostedById?: string;
|
|
26
|
+
PostedDateTime?: Date;
|
|
27
|
+
UseAccSystemDocYN: string;
|
|
28
|
+
}
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
export class IDocumentItemAttr {
|
|
2
|
-
DocumentItemId: string;
|
|
3
|
-
DocNo: string;
|
|
4
|
-
Name: string;
|
|
5
|
-
NameBM: string;
|
|
6
|
-
Description?: string;
|
|
7
|
-
ItemId?: string;
|
|
8
|
-
ItemType?: string;
|
|
9
|
-
ItemSKU?: string;
|
|
10
|
-
ItemSerialNo?: string;
|
|
11
|
-
Currency: string;
|
|
12
|
-
UnitPrice?: number;
|
|
13
|
-
Quantity?: number;
|
|
14
|
-
QuantityUOM?: string;
|
|
15
|
-
Amount: number;
|
|
16
|
-
TaxCode?: string;
|
|
17
|
-
TaxAmount?: number;
|
|
18
|
-
TaxRate?: number;
|
|
19
|
-
TaxInclusiveYN?: string;
|
|
20
|
-
DtAccountNo?: string;
|
|
21
|
-
CtAccountNo?: string;
|
|
22
|
-
}
|
|
1
|
+
export class IDocumentItemAttr {
|
|
2
|
+
DocumentItemId: string;
|
|
3
|
+
DocNo: string;
|
|
4
|
+
Name: string;
|
|
5
|
+
NameBM: string;
|
|
6
|
+
Description?: string;
|
|
7
|
+
ItemId?: string;
|
|
8
|
+
ItemType?: string;
|
|
9
|
+
ItemSKU?: string;
|
|
10
|
+
ItemSerialNo?: string;
|
|
11
|
+
Currency: string;
|
|
12
|
+
UnitPrice?: number;
|
|
13
|
+
Quantity?: number;
|
|
14
|
+
QuantityUOM?: string;
|
|
15
|
+
Amount: number;
|
|
16
|
+
TaxCode?: string;
|
|
17
|
+
TaxAmount?: number;
|
|
18
|
+
TaxRate?: number;
|
|
19
|
+
TaxInclusiveYN?: string;
|
|
20
|
+
DtAccountNo?: string;
|
|
21
|
+
CtAccountNo?: string;
|
|
22
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { IRepositoryBase } from '@tomei/general';
|
|
2
|
-
import DocumentItemModel from '../../models/document-item.entity';
|
|
3
|
-
|
|
4
|
-
export type IDocumentItemRepository = IRepositoryBase<DocumentItemModel>;
|
|
1
|
+
import { IRepositoryBase } from '@tomei/general';
|
|
2
|
+
import DocumentItemModel from '../../models/document-item.entity';
|
|
3
|
+
|
|
4
|
+
export type IDocumentItemRepository = IRepositoryBase<DocumentItemModel>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export enum CollectPaymentType {
|
|
2
|
-
MANUAL = 'MANUAL',
|
|
3
|
-
AUTOMATIC = 'AUTOMATIC'
|
|
1
|
+
export enum CollectPaymentType {
|
|
2
|
+
MANUAL = 'MANUAL',
|
|
3
|
+
AUTOMATIC = 'AUTOMATIC'
|
|
4
4
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export enum DocType {
|
|
2
|
-
INVOICE = 'Invoice',
|
|
3
|
-
DEBIT_NOTE = 'Debit Note',
|
|
4
|
-
CREDIT_NOTE = 'Credit Note',
|
|
5
|
-
QUOTATION = 'Quotation',
|
|
6
|
-
PURCHASEORDER = 'Purchase Order',
|
|
7
|
-
RECEIPT = 'Receipt',
|
|
8
|
-
}
|
|
1
|
+
export enum DocType {
|
|
2
|
+
INVOICE = 'Invoice',
|
|
3
|
+
DEBIT_NOTE = 'Debit Note',
|
|
4
|
+
CREDIT_NOTE = 'Credit Note',
|
|
5
|
+
QUOTATION = 'Quotation',
|
|
6
|
+
PURCHASEORDER = 'Purchase Order',
|
|
7
|
+
RECEIPT = 'Receipt',
|
|
8
|
+
}
|
package/src/enum/index.ts
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import { ClientScopes } from './quick-book-client-scopes.enum';
|
|
2
|
-
import { PaymentType } from './payment-type.enum';
|
|
3
|
-
import { PaymentMethod } from './payment-method.enum';
|
|
4
|
-
import { TransactionTypeOptions } from './transaction-type.enum';
|
|
5
|
-
import { DocType } from './doc-type.enum';
|
|
6
|
-
import { DocumentStatus } from './document-status.enum';
|
|
7
|
-
import { PaymentStatus } from './payment-status.enum';
|
|
8
|
-
import { PaymentPaidWithStatus } from './payment-status.enum';
|
|
9
|
-
|
|
10
|
-
export {
|
|
11
|
-
ClientScopes,
|
|
12
|
-
PaymentType,
|
|
13
|
-
PaymentMethod,
|
|
14
|
-
TransactionTypeOptions,
|
|
15
|
-
DocType,
|
|
16
|
-
DocumentStatus,
|
|
17
|
-
PaymentStatus,
|
|
18
|
-
PaymentPaidWithStatus,
|
|
19
|
-
};
|
|
1
|
+
import { ClientScopes } from './quick-book-client-scopes.enum';
|
|
2
|
+
import { PaymentType } from './payment-type.enum';
|
|
3
|
+
import { PaymentMethod } from './payment-method.enum';
|
|
4
|
+
import { TransactionTypeOptions } from './transaction-type.enum';
|
|
5
|
+
import { DocType } from './doc-type.enum';
|
|
6
|
+
import { DocumentStatus } from './document-status.enum';
|
|
7
|
+
import { PaymentStatus } from './payment-status.enum';
|
|
8
|
+
import { PaymentPaidWithStatus } from './payment-status.enum';
|
|
9
|
+
|
|
10
|
+
export {
|
|
11
|
+
ClientScopes,
|
|
12
|
+
PaymentType,
|
|
13
|
+
PaymentMethod,
|
|
14
|
+
TransactionTypeOptions,
|
|
15
|
+
DocType,
|
|
16
|
+
DocumentStatus,
|
|
17
|
+
PaymentStatus,
|
|
18
|
+
PaymentPaidWithStatus,
|
|
19
|
+
};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export enum PaymentMethod {
|
|
2
|
-
Cash = 'Cash', // example
|
|
3
|
-
}
|
|
1
|
+
export enum PaymentMethod {
|
|
2
|
+
Cash = 'Cash', // example
|
|
3
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export enum PaymentType {
|
|
2
|
-
PAYMENT_RECEIVED = 'Payment Received',
|
|
3
|
-
PAYOUT = 'Payout',
|
|
4
|
-
}
|
|
1
|
+
export enum PaymentType {
|
|
2
|
+
PAYMENT_RECEIVED = 'Payment Received',
|
|
3
|
+
PAYOUT = 'Payout',
|
|
4
|
+
}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import * as OAuthClient from 'intuit-oauth';
|
|
2
|
-
export enum ClientScopes {
|
|
3
|
-
ACCOUNTING = OAuthClient.scopes.Accounting,
|
|
4
|
-
PAYMENT = OAuthClient.scopes.Payment,
|
|
5
|
-
PAYROLL = OAuthClient.scopes.Payroll,
|
|
6
|
-
TIMETRACKING = OAuthClient.scopes.TimeTracking,
|
|
7
|
-
BENEFITS = OAuthClient.scopes.Benefits,
|
|
8
|
-
PROFILE = OAuthClient.scopes.Profile,
|
|
9
|
-
EMAIL = OAuthClient.scopes.Email,
|
|
10
|
-
PHONE = OAuthClient.scopes.Phone,
|
|
11
|
-
ADDRESS = OAuthClient.scopes.Address,
|
|
12
|
-
OPENID = OAuthClient.scopes.OpenId,
|
|
13
|
-
INTUIT_NAME = OAuthClient.scopes.Intuit_name,
|
|
14
|
-
}
|
|
1
|
+
import * as OAuthClient from 'intuit-oauth';
|
|
2
|
+
export enum ClientScopes {
|
|
3
|
+
ACCOUNTING = OAuthClient.scopes.Accounting,
|
|
4
|
+
PAYMENT = OAuthClient.scopes.Payment,
|
|
5
|
+
PAYROLL = OAuthClient.scopes.Payroll,
|
|
6
|
+
TIMETRACKING = OAuthClient.scopes.TimeTracking,
|
|
7
|
+
BENEFITS = OAuthClient.scopes.Benefits,
|
|
8
|
+
PROFILE = OAuthClient.scopes.Profile,
|
|
9
|
+
EMAIL = OAuthClient.scopes.Email,
|
|
10
|
+
PHONE = OAuthClient.scopes.Phone,
|
|
11
|
+
ADDRESS = OAuthClient.scopes.Address,
|
|
12
|
+
OPENID = OAuthClient.scopes.OpenId,
|
|
13
|
+
INTUIT_NAME = OAuthClient.scopes.Intuit_name,
|
|
14
|
+
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { RepositoryBase, IRepositoryBase } from '@tomei/general';
|
|
2
|
-
import FinanceCompanyModel from '../models/finance-company.entity';
|
|
3
|
-
|
|
4
|
-
export class FinanceCompanyRepository
|
|
5
|
-
extends RepositoryBase<FinanceCompanyModel>
|
|
6
|
-
implements IRepositoryBase<FinanceCompanyModel>
|
|
7
|
-
{
|
|
8
|
-
constructor() {
|
|
9
|
-
super(FinanceCompanyModel);
|
|
10
|
-
}
|
|
11
|
-
}
|
|
1
|
+
import { RepositoryBase, IRepositoryBase } from '@tomei/general';
|
|
2
|
+
import FinanceCompanyModel from '../models/finance-company.entity';
|
|
3
|
+
|
|
4
|
+
export class FinanceCompanyRepository
|
|
5
|
+
extends RepositoryBase<FinanceCompanyModel>
|
|
6
|
+
implements IRepositoryBase<FinanceCompanyModel>
|
|
7
|
+
{
|
|
8
|
+
constructor() {
|
|
9
|
+
super(FinanceCompanyModel);
|
|
10
|
+
}
|
|
11
|
+
}
|