@bisondesk/commons-sdk 1.0.312 → 1.0.314
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/lib/cjs/constants.js +3 -1
- package/lib/cjs/constants.js.map +1 -1
- package/lib/cjs/exact.js.map +1 -1
- package/lib/cjs/pdf-gen.js.map +1 -1
- package/lib/cjs/tasks.js.map +1 -1
- package/lib/cjs/types.js +6 -1
- package/lib/cjs/types.js.map +1 -1
- package/lib/constants.js +3 -1
- package/lib/constants.js.map +1 -1
- package/lib/esm/constants.js +3 -1
- package/lib/esm/constants.js.map +1 -1
- package/lib/esm/exact.js.map +1 -1
- package/lib/esm/pdf-gen.js.map +1 -1
- package/lib/esm/tasks.js.map +1 -1
- package/lib/esm/types.js +5 -0
- package/lib/esm/types.js.map +1 -1
- package/lib/exact.js.map +1 -1
- package/lib/pdf-gen.js.map +1 -1
- package/lib/tasks.js.map +1 -1
- package/lib/tsconfig.cjs.tsbuildinfo +1 -1
- package/lib/tsconfig.esm.tsbuildinfo +1 -1
- package/lib/types/constants.d.ts +5 -3
- package/lib/types/constants.d.ts.map +1 -1
- package/lib/types/exact.d.ts +12 -0
- package/lib/types/exact.d.ts.map +1 -1
- package/lib/types/pdf-gen.d.ts +4 -0
- package/lib/types/pdf-gen.d.ts.map +1 -1
- package/lib/types/tasks.d.ts +2 -3
- package/lib/types/tasks.d.ts.map +1 -1
- package/lib/types/types.d.ts +19 -3
- package/lib/types/types.d.ts.map +1 -1
- package/lib/types.js +6 -1
- package/lib/types.js.map +1 -1
- package/package.json +1 -1
- package/src/constants.ts +3 -1
- package/src/exact.ts +15 -0
- package/src/pdf-gen.ts +5 -0
- package/src/tasks.ts +2 -3
- package/src/types.ts +21 -4
- package/tsconfig.tsbuildinfo +1 -1
package/lib/types/types.d.ts
CHANGED
|
@@ -17,6 +17,10 @@ export type NextList<T, M = {}> = {
|
|
|
17
17
|
meta: M;
|
|
18
18
|
totalCount?: number;
|
|
19
19
|
};
|
|
20
|
+
export type NextRequest = {
|
|
21
|
+
limit?: number;
|
|
22
|
+
nextToken?: string;
|
|
23
|
+
};
|
|
20
24
|
export type PaginatedRequest = {
|
|
21
25
|
limit?: number;
|
|
22
26
|
offset?: number;
|
|
@@ -127,9 +131,21 @@ export type VatValidationRequest = {
|
|
|
127
131
|
defaultCountry?: string;
|
|
128
132
|
input: string;
|
|
129
133
|
};
|
|
130
|
-
export type
|
|
131
|
-
|
|
132
|
-
|
|
134
|
+
export type CurrencyListResponse = {
|
|
135
|
+
currencies: Record<string, {
|
|
136
|
+
label: string;
|
|
137
|
+
}>;
|
|
138
|
+
};
|
|
139
|
+
export type CurrencyConversionRequest = {
|
|
133
140
|
sourceCurrency: string;
|
|
141
|
+
targetCurrency?: string;
|
|
134
142
|
};
|
|
143
|
+
export type CurrencyConversionResponse = {
|
|
144
|
+
sourceCurrency: string;
|
|
145
|
+
rates: Record<string, string>;
|
|
146
|
+
};
|
|
147
|
+
export declare enum TransactionType {
|
|
148
|
+
sale = "sale",
|
|
149
|
+
purchase = "purchase"
|
|
150
|
+
}
|
|
135
151
|
//# sourceMappingURL=types.d.ts.map
|
package/lib/types/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"/","sources":["types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AACxD,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAEtD,MAAM,MAAM,aAAa,CAAC,CAAC,EAAE,CAAC,GAAG,EAAE,IAAI;IACrC,OAAO,EAAE,CAAC,EAAE,CAAC;IACb,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,IAAI,EAAE,CAAC,CAAC;IACR,UAAU,EAAE,MAAM,CAAC;CACpB,CAAC;AAEF,MAAM,MAA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ED
|
@@ -1,8 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.Region = void 0;
|
|
3
|
+
exports.TransactionType = exports.Region = void 0;
|
|
4
4
|
var Region;
|
|
5
5
|
(function (Region) {
|
|
6
6
|
Region["euWest1"] = "eu-west-1";
|
|
7
7
|
})(Region = exports.Region || (exports.Region = {}));
|
|
8
|
+
var TransactionType;
|
|
9
|
+
(function (TransactionType) {
|
|
10
|
+
TransactionType["sale"] = "sale";
|
|
11
|
+
TransactionType["purchase"] = "purchase";
|
|
12
|
+
})(TransactionType = exports.TransactionType || (exports.TransactionType = {}));
|
|
8
13
|
//# sourceMappingURL=types.js.map
|
package/lib/types.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"/","sources":["types.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"/","sources":["types.ts"],"names":[],"mappings":";;;AAkDA,IAAY,MAEX;AAFD,WAAY,MAAM;IAChB,+BAAqB,CAAA;AACvB,CAAC,EAFW,MAAM,GAAN,cAAM,KAAN,cAAM,QAEjB;AA8GD,IAAY,eAGX;AAHD,WAAY,eAAe;IACzB,gCAAa,CAAA;IACb,wCAAqB,CAAA;AACvB,CAAC,EAHW,eAAe,GAAf,uBAAe,KAAf,uBAAe,QAG1B","sourcesContent":["import { AppRoles, TopLevelActions } from './constants';\nimport { LocationValue } from './locations';\nexport { GPSCoord, LocationValue } from './locations';\n\nexport type PaginatedList<T, M = {}> = {\n results: T[];\n nextToken?: undefined;\n meta: M;\n totalCount: number;\n};\n\nexport type PaginationRequest = {\n limit: number;\n offset: number;\n};\n\nexport type NextList<T, M = {}> = {\n results: T[];\n nextToken?: string;\n meta: M;\n totalCount?: number;\n};\n\nexport type NextRequest = {\n limit?: number;\n nextToken?: string;\n};\n\nexport type PaginatedRequest = {\n limit?: number;\n offset?: number;\n};\nexport type Requester = {\n lang: string;\n roles: AppRoles[];\n actions: TopLevelActions[];\n tenantId: string;\n tenantLang: string;\n userAgent?: string;\n source?: string;\n userId: string;\n isApi: boolean;\n};\n\nexport type Option = {\n value: string | number;\n label: string;\n color?: string;\n};\n\nexport enum Region {\n euWest1 = 'eu-west-1',\n}\n\nexport type ErrorResponse = {\n message?: string;\n data?: unknown;\n};\n\nexport type MultiLangValue = { key?: string } & { [languageCode: string]: string };\n\nexport type CognitoInfo = {\n userPoolId: string;\n appClientId: string;\n region: Region;\n};\n\nexport type SearchPermissions = {\n users: string[];\n roles: AppRoles[];\n};\n\nexport type PhoneNumberValue = {\n country: string;\n e164: string;\n international: string;\n national: string;\n};\n\nexport type PhoneNumberRawValue = {\n defaultCountry?: string;\n input: string;\n};\n\nexport type LinkValue = {\n text?: string;\n url: string;\n};\n\nexport type Document = {\n type: string; // passport, driving_license, ...\n displayName: string;\n file: AttachmentValue;\n};\n\nexport type AttachmentValue = {\n contentType: string;\n fileName: string;\n id: string;\n previewSrc?: string;\n size: number;\n uploadedAt: string;\n uploadedBy: string;\n url: string;\n descriptions?: string | MultiLangValue;\n};\n\nexport type VatLayerResponseLog = {\n response: VatLayerResponse;\n raw: any;\n};\n\nexport type VatLayerResponse = {\n vatNumber: string;\n viesStatus: 'ok' | 'failure';\n} & (\n | { formatValid: boolean; viesValid: false; validAt?: undefined; countryCode?: string }\n | {\n formatValid: true;\n viesValid: boolean;\n validAt: string;\n countryCode: string;\n name: string;\n addressLines: string[];\n }\n);\n\nexport type VatValidationResponse = {\n vatNumber: string;\n formatValid?: boolean;\n viesStatus: 'ok' | 'failure';\n countryCode?: string;\n} & (\n | { viesValid: false; validAt?: undefined }\n | {\n viesValid: true;\n validAt: string;\n name?: string;\n normalizedAddress?: LocationValue;\n officialAddress?: string[];\n }\n);\n\nexport type VatValidationRequest = {\n defaultCountry?: string;\n input: string;\n};\n\nexport type CurrencyListResponse = {\n currencies: Record<string, { label: string }>;\n};\n\nexport type CurrencyConversionRequest = {\n sourceCurrency: string;\n targetCurrency?: string;\n};\n\nexport type CurrencyConversionResponse = {\n sourceCurrency: string;\n rates: Record<string, string>;\n};\n\nexport enum TransactionType {\n sale = 'sale',\n purchase = 'purchase',\n}\n"]}
|
package/package.json
CHANGED
package/src/constants.ts
CHANGED
|
@@ -9,16 +9,17 @@ export enum AppRoles {
|
|
|
9
9
|
Manager = 'manager',
|
|
10
10
|
ParkLogistics = 'park_logistics',
|
|
11
11
|
AppManager = 'app_manager',
|
|
12
|
+
SeniorAccountant = 'senior_accountant',
|
|
12
13
|
}
|
|
13
14
|
|
|
14
15
|
export enum TopLevelActions {
|
|
15
16
|
AdministrationAll = 'admin:*',
|
|
16
17
|
DocumentsBrowse = 'docs:finance:browse',
|
|
17
18
|
LeadsAll = 'leads:*',
|
|
19
|
+
BrowseDocumentDrafts = 'docs:drafts:browse',
|
|
18
20
|
LeasingDebtorsView = 'leasing:debtors:view',
|
|
19
21
|
LeasingOverduesView = 'leasing:overdues:view',
|
|
20
22
|
LeasingContractsExport = 'leasing:contracts:export',
|
|
21
|
-
LeasingContractsRsExport = 'leasing:contracts:rs:export-rs', // rs stands for rental solutions
|
|
22
23
|
LeasingDebtorsExport = 'leasing:debtors:export',
|
|
23
24
|
MarketBrowse = 'market:browse',
|
|
24
25
|
MarketInsights = 'insights:market',
|
|
@@ -64,6 +65,7 @@ export enum BusinessEntityIds {
|
|
|
64
65
|
Vehicles = 'vehicles',
|
|
65
66
|
VehiclesPriceLists = 'vehicles_price_lists',
|
|
66
67
|
Debtors = 'debtors',
|
|
68
|
+
DocumentDrafts = 'document_drafts',
|
|
67
69
|
}
|
|
68
70
|
|
|
69
71
|
//
|
package/src/exact.ts
CHANGED
|
@@ -14,3 +14,18 @@ export type ExactClientAccount = {
|
|
|
14
14
|
exactTld: string;
|
|
15
15
|
authenticated: boolean;
|
|
16
16
|
};
|
|
17
|
+
|
|
18
|
+
// TODO remove once exact-sdk is correctly published
|
|
19
|
+
export type GlAccount = {
|
|
20
|
+
id: string;
|
|
21
|
+
code: number;
|
|
22
|
+
description: string;
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
export type Journal = {
|
|
26
|
+
code: string;
|
|
27
|
+
type: string;
|
|
28
|
+
glAccountCode: string;
|
|
29
|
+
glAccountDescription: string;
|
|
30
|
+
description: string;
|
|
31
|
+
};
|
package/src/pdf-gen.ts
CHANGED
package/src/tasks.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { BusinessEntityIds } from './constants';
|
|
2
|
+
import { NextRequest } from './types';
|
|
2
3
|
|
|
3
4
|
export enum TaskPriority {
|
|
4
5
|
Normal = 30,
|
|
@@ -57,8 +58,6 @@ export type TaskNotificationData = {
|
|
|
57
58
|
};
|
|
58
59
|
|
|
59
60
|
export type TasksQuery = {
|
|
60
|
-
limit?: number;
|
|
61
|
-
nextToken?: string;
|
|
62
61
|
assignee?: string;
|
|
63
62
|
showDone?: boolean;
|
|
64
|
-
};
|
|
63
|
+
} & NextRequest;
|
package/src/types.ts
CHANGED
|
@@ -21,11 +21,15 @@ export type NextList<T, M = {}> = {
|
|
|
21
21
|
totalCount?: number;
|
|
22
22
|
};
|
|
23
23
|
|
|
24
|
+
export type NextRequest = {
|
|
25
|
+
limit?: number;
|
|
26
|
+
nextToken?: string;
|
|
27
|
+
};
|
|
28
|
+
|
|
24
29
|
export type PaginatedRequest = {
|
|
25
30
|
limit?: number;
|
|
26
31
|
offset?: number;
|
|
27
32
|
};
|
|
28
|
-
|
|
29
33
|
export type Requester = {
|
|
30
34
|
lang: string;
|
|
31
35
|
roles: AppRoles[];
|
|
@@ -142,8 +146,21 @@ export type VatValidationRequest = {
|
|
|
142
146
|
input: string;
|
|
143
147
|
};
|
|
144
148
|
|
|
145
|
-
export type
|
|
146
|
-
|
|
147
|
-
|
|
149
|
+
export type CurrencyListResponse = {
|
|
150
|
+
currencies: Record<string, { label: string }>;
|
|
151
|
+
};
|
|
152
|
+
|
|
153
|
+
export type CurrencyConversionRequest = {
|
|
154
|
+
sourceCurrency: string;
|
|
155
|
+
targetCurrency?: string;
|
|
156
|
+
};
|
|
157
|
+
|
|
158
|
+
export type CurrencyConversionResponse = {
|
|
148
159
|
sourceCurrency: string;
|
|
160
|
+
rates: Record<string, string>;
|
|
149
161
|
};
|
|
162
|
+
|
|
163
|
+
export enum TransactionType {
|
|
164
|
+
sale = 'sale',
|
|
165
|
+
purchase = 'purchase',
|
|
166
|
+
}
|