@chift/chift-nodejs 1.0.7 → 1.0.8
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/.github/workflows/ci.yml +1 -1
- package/CHANGELOG.md +24 -0
- package/dist/src/modules/accounting.d.ts +21 -18
- package/dist/src/modules/accounting.js +59 -20
- package/dist/src/modules/api.d.ts +465 -90
- package/dist/src/modules/consumer.d.ts +93 -18
- package/dist/src/modules/consumers.d.ts +465 -90
- package/dist/src/modules/sync.d.ts +372 -72
- package/dist/test/modules/accounting.test.js +28 -0
- package/package.json +1 -1
- package/src/modules/accounting.ts +95 -22
- package/test/modules/accounting.test.ts +31 -0
package/.github/workflows/ci.yml
CHANGED
|
@@ -15,7 +15,6 @@ on:
|
|
|
15
15
|
|
|
16
16
|
jobs:
|
|
17
17
|
test:
|
|
18
|
-
if: false
|
|
19
18
|
name: Test
|
|
20
19
|
runs-on: ubuntu-latest
|
|
21
20
|
steps:
|
|
@@ -52,6 +51,7 @@ jobs:
|
|
|
52
51
|
|
|
53
52
|
publish:
|
|
54
53
|
name: Publish
|
|
54
|
+
if: startsWith(github.ref, 'refs/tags/v')
|
|
55
55
|
runs-on: ubuntu-latest
|
|
56
56
|
steps:
|
|
57
57
|
- name: Checkout
|
package/CHANGELOG.md
CHANGED
|
@@ -49,3 +49,27 @@
|
|
|
49
49
|
- [SYNC] Add create sync
|
|
50
50
|
- [SYNC] Add update sync
|
|
51
51
|
- [CONSUMER] Add enable consumer flow
|
|
52
|
+
|
|
53
|
+
## 1.0.8 - 2024-04-04
|
|
54
|
+
|
|
55
|
+
- [ACCOUNTING] Add params to getAnalyticPlans
|
|
56
|
+
- [ACCOUNTING] Add params to getClients
|
|
57
|
+
- [ACCOUNTING] Add params to getClient
|
|
58
|
+
- [ACCOUNTING] Add params to updateClient
|
|
59
|
+
- [ACCOUNTING] Add params to getSuppliers
|
|
60
|
+
- [ACCOUNTING] Add params to getSupplier
|
|
61
|
+
- [ACCOUNTING] Add params to updateSupplier
|
|
62
|
+
- [ACCOUNTING] Add params to createAnalyticAccount
|
|
63
|
+
- [ACCOUNTING] Add params to getAnalyticAccounts
|
|
64
|
+
- [ACCOUNTING] Add params to createAnalyticAccountWithMultiplePlans
|
|
65
|
+
- [ACCOUNTING] Add params to getAnalyticAccount
|
|
66
|
+
- [ACCOUNTING] Add params to updateAnalyticAccount
|
|
67
|
+
- [ACCOUNTING] Add params to getAnalyticAccountWithMultiplePlans
|
|
68
|
+
- [ACCOUNTING] Add params to getAnalyticAccountsWithMultiplePlans
|
|
69
|
+
- [ACCOUNTING] Add params to updateAnalyticAccountWithMultiplePlans
|
|
70
|
+
- [ACCOUNTING] Add params to getPaymentsByInvoiceId
|
|
71
|
+
- [ACCOUNTING] Add params to getJournals
|
|
72
|
+
- [ACCOUNTING] Add params to getVatCodes
|
|
73
|
+
- [ACCOUNTING] Add route getAttachments
|
|
74
|
+
- [ACCOUNTING] Add route matchEntries
|
|
75
|
+
- [ACCOUNTING] Add route getFolders
|
|
@@ -8,38 +8,39 @@ type getInvoicesByTypeWithMultiplePlansParams = Omit<operations['accounting_get_
|
|
|
8
8
|
type getInvoicesByTypeParams = Omit<operations['accounting_get_invoices_by_type']['parameters']['query'], 'page' | 'size'>;
|
|
9
9
|
type getOutstandingsParams = Omit<operations['accounting_get_outstandings']['parameters']['query'], 'page' | 'size'>;
|
|
10
10
|
declare const accountingFactory: {
|
|
11
|
-
getAnalyticPlans(): RequestData<components['schemas']['AnalyticPlanItem'][]>;
|
|
12
|
-
getClients(): RequestData<components['schemas']['ClientItemOut'][]>;
|
|
11
|
+
getAnalyticPlans(params: operations['accounting_get_analytic_plans']['parameters']['query']): RequestData<components['schemas']['AnalyticPlanItem'][]>;
|
|
12
|
+
getClients(params: operations['accounting_get_clients']['parameters']['query']): RequestData<components['schemas']['ClientItemOut'][]>;
|
|
13
13
|
createClient(client: components['schemas']['ClientItemIn'], params: operations['accounting_create_client']['parameters']['query']): RequestData<components['schemas']['ClientItemOut']>;
|
|
14
|
-
getClient(clientId: string): RequestData<components['schemas']['ClientItemOut']>;
|
|
15
|
-
updateClient(clientId: string, client: components['schemas']['ClientItemUpdate']): RequestData<components['schemas']['ClientItemOut']>;
|
|
16
|
-
getSuppliers(): RequestData<components['schemas']['SupplierItemOut'][]>;
|
|
14
|
+
getClient(clientId: string, params: operations['accounting_get_client']['parameters']['query']): RequestData<components['schemas']['ClientItemOut']>;
|
|
15
|
+
updateClient(clientId: string, client: components['schemas']['ClientItemUpdate'], params: operations['accounting_update_client']['parameters']['query']): RequestData<components['schemas']['ClientItemOut']>;
|
|
16
|
+
getSuppliers(params: operations['accounting_get_suppliers']['parameters']['query']): RequestData<components['schemas']['SupplierItemOut'][]>;
|
|
17
17
|
createSupplier(supplier: components['schemas']['SupplierItemIn'], params: operations['accounting_create_supplier']['parameters']['query']): RequestData<components['schemas']['SupplierItemOut']>;
|
|
18
|
-
getSupplier(supplierId: string): RequestData<components['schemas']['SupplierItemOut']>;
|
|
19
|
-
updateSupplier(supplierId: string, supplier: components['schemas']['SupplierItemUpdate']): RequestData<components['schemas']['SupplierItemOut']>;
|
|
18
|
+
getSupplier(supplierId: string, params: operations['accounting_get_supplier']['parameters']['query']): RequestData<components['schemas']['SupplierItemOut']>;
|
|
19
|
+
updateSupplier(supplierId: string, supplier: components['schemas']['SupplierItemUpdate'], params: operations['accounting_update_supplier']['parameters']['query']): RequestData<components['schemas']['SupplierItemOut']>;
|
|
20
20
|
createInvoice(invoice: components['schemas']['InvoiceItemInMonoAnalyticPlan'], params: operations['accounting_create_invoice']['parameters']['query']): RequestData<components['schemas']['InvoiceItemOutMonoAnalyticPlan']>;
|
|
21
21
|
createInvoiceWithMultiplePlans(invoice: components['schemas']['InvoiceItemInMultiAnalyticPlans'], params: operations['accounting_create_invoice_multiple_plans']['parameters']['query']): RequestData<components['schemas']['InvoiceItemOutMultiAnalyticPlans']>;
|
|
22
22
|
getInvoicesByType(invoice_type: components['schemas']['app__routers__accounting__InvoiceType'], params: getInvoicesByTypeParams): RequestData<components['schemas']['InvoiceItemOutMonoAnalyticPlan'][]>;
|
|
23
23
|
getInvoice(invoiceId: string, params: operations['accounting_get_invoice']['parameters']['query']): RequestData<components['schemas']['InvoiceItemOutMonoAnalyticPlan']>;
|
|
24
24
|
getInvoiceWithMultiplePlans(invoiceId: string, params: operations['accounting_get_invoice_multi_analytic_plans']['parameters']['query']): RequestData<components['schemas']['InvoiceItemOutMultiAnalyticPlans']>;
|
|
25
25
|
getInvoicesByTypeWithMultiplePlans(invoice_type: components['schemas']['app__routers__accounting__InvoiceType'], params: getInvoicesByTypeWithMultiplePlansParams): RequestData<components['schemas']['InvoiceItemOutMultiAnalyticPlans'][]>;
|
|
26
|
-
createAnalyticAccount(analyticAccount: components['schemas']['AnalyticAccountItemIn']): RequestData<components['schemas']['AnalyticAccountItemOut']>;
|
|
27
|
-
getAnalyticAccounts(): RequestData<components['schemas']['AnalyticAccountItemOut'][]>;
|
|
28
|
-
createAnalyticAccountWithMultiplePlans(analytic_plan: string, analyticAccount: components['schemas']['AnalyticAccountItemIn']): RequestData<components['schemas']['AnalyticAccountItemOutMultiAnalyticPlans']>;
|
|
29
|
-
getAnalyticAccount(analytic_account_id: string): RequestData<components['schemas']['AnalyticAccountItemOut']>;
|
|
30
|
-
updateAnalyticAccount(analytic_account_id: string, analyticAccount: components['schemas']['AnalyticAccountItemUpdate']): RequestData<components['schemas']['AnalyticAccountItemOut']>;
|
|
31
|
-
getAnalyticAccountWithMultiplePlans(analytic_account_id: string, analytic_plan: string): RequestData<components['schemas']['AnalyticAccountItemOutMultiAnalyticPlans']>;
|
|
32
|
-
updateAnalyticAccountWithMultiplePlans(analytic_account_id: string, analytic_plan: string, analyticAccount: components['schemas']['AnalyticAccountItemUpdate']): RequestData<components['schemas']['AnalyticAccountItemOutMultiAnalyticPlans']>;
|
|
33
|
-
getAnalyticAccountsWithMultiplePlans(): RequestData<components['schemas']['AnalyticAccountItemOutMultiAnalyticPlans'][]>;
|
|
26
|
+
createAnalyticAccount(analyticAccount: components['schemas']['AnalyticAccountItemIn'], params: operations['accounting_create_analytic_account']['parameters']['query']): RequestData<components['schemas']['AnalyticAccountItemOut']>;
|
|
27
|
+
getAnalyticAccounts(params: operations['accounting_get_analytic_accounts']['parameters']['query']): RequestData<components['schemas']['AnalyticAccountItemOut'][]>;
|
|
28
|
+
createAnalyticAccountWithMultiplePlans(analytic_plan: string, analyticAccount: components['schemas']['AnalyticAccountItemIn'], params: operations['accounting_create_analytic_account_multi_plans']['parameters']['query']): RequestData<components['schemas']['AnalyticAccountItemOutMultiAnalyticPlans']>;
|
|
29
|
+
getAnalyticAccount(analytic_account_id: string, params: operations['accounting_get_analytic_account']['parameters']['query']): RequestData<components['schemas']['AnalyticAccountItemOut']>;
|
|
30
|
+
updateAnalyticAccount(analytic_account_id: string, analyticAccount: components['schemas']['AnalyticAccountItemUpdate'], params: operations['accounting_update_analytic_account']['parameters']['query']): RequestData<components['schemas']['AnalyticAccountItemOut']>;
|
|
31
|
+
getAnalyticAccountWithMultiplePlans(analytic_account_id: string, analytic_plan: string, params: operations['accounting_get_analytic_account_multi_plans']['parameters']['query']): RequestData<components['schemas']['AnalyticAccountItemOutMultiAnalyticPlans']>;
|
|
32
|
+
updateAnalyticAccountWithMultiplePlans(analytic_account_id: string, analytic_plan: string, analyticAccount: components['schemas']['AnalyticAccountItemUpdate'], params: operations['accounting_update_analytic_account_multi_plans']['parameters']['query']): RequestData<components['schemas']['AnalyticAccountItemOutMultiAnalyticPlans']>;
|
|
33
|
+
getAnalyticAccountsWithMultiplePlans(params: operations['accounting_get_analytic_accounts_multi_plans']['parameters']['query']): RequestData<components['schemas']['AnalyticAccountItemOutMultiAnalyticPlans'][]>;
|
|
34
34
|
getJournalEntries(params: getJournalEntriesParams): RequestData<components['schemas']['JournalEntryMonoAnalyticPlan'][]>;
|
|
35
35
|
getJournalEntriesWithMultiplePlans(params: getJournalEntriesWithMultiplePlansParams): RequestData<components['schemas']['JournalEntryMultiAnalyticPlan'][]>;
|
|
36
|
-
getPaymentsByInvoiceId(invoice_id: string): RequestData<components['schemas']['Payment'][]>;
|
|
37
|
-
getJournals(): RequestData<components['schemas']['Journal'][]>;
|
|
38
|
-
getVatCodes(): RequestData<components['schemas']['app__routers__accounting__VatCode'][]>;
|
|
36
|
+
getPaymentsByInvoiceId(invoice_id: string, params: operations['accounting_get_payments_by_invoice']['parameters']['query']): RequestData<components['schemas']['Payment'][]>;
|
|
37
|
+
getJournals(params: operations['accounting_get_journals']['parameters']['query']): RequestData<components['schemas']['Journal'][]>;
|
|
38
|
+
getVatCodes(params: operations['accounting_get_vat_codes']['parameters']['query']): RequestData<components['schemas']['app__routers__accounting__VatCode'][]>;
|
|
39
39
|
getMiscOperations(params: getMiscOperationsParams): RequestData<components['schemas']['MiscellaneousOperationOut'][]>;
|
|
40
40
|
createMiscOperation(operation: components['schemas']['MiscellaneousOperationIn'], params: operations['accounting_create_miscellaneous_operation']['parameters']['query']): RequestData<components['schemas']['MiscellaneousOperationOut']>;
|
|
41
41
|
getMiscOperation(operation_id: string, params: operations['accounting_get_miscellaneous_operation']['parameters']['query']): RequestData<components['schemas']['MiscellaneousOperationOut']>;
|
|
42
42
|
attachPDF(invoice_id: string, attachment: components['schemas']['AttachmentItem'], params: operations['accounting_add_attachment']['parameters']['query']): RequestData<operations['accounting_add_attachment']['responses'][201]>;
|
|
43
|
+
getAttachments(params: operations['accounting_get_attachments']['parameters']['query']): RequestData<components['schemas']['AttachmentItem'][]>;
|
|
43
44
|
getChartOfAccounts(params: getChartOfAccountsParams): RequestData<components['schemas']['AccountItem'][]>;
|
|
44
45
|
getBalanceOfAccounts(filter: components['schemas']['AccountBalanceFilter'], params: operations['accounting_get_accounts_balances']['parameters']['query']): RequestData<components['schemas']['AccountBalance'][]>;
|
|
45
46
|
getEmployees(params: operations['accounting_get_employees']['parameters']['query']): RequestData<components['schemas']['EmployeeItem'][]>;
|
|
@@ -51,5 +52,7 @@ declare const accountingFactory: {
|
|
|
51
52
|
createFinancialEntry(financial_entry: components['schemas']['FinancialEntryItemIn'], params: operations['accounting_create_financial_entries']['parameters']['query']): RequestData<components['schemas']['FinancialEntryItemOut'][]>;
|
|
52
53
|
createJournalEntryOld(journal_entry: components['schemas']['JournalEntryIn']): RequestData<components['schemas']['JournalEntryMultiAnalyticPlan']>;
|
|
53
54
|
createJournalEntry(journal_entry: components['schemas']['GenericJournalEntry'], params: operations['accounting_create_generic_journal_entry']['parameters']['query']): RequestData<components['schemas']['JournalEntryMultiAnalyticPlan']>;
|
|
55
|
+
matchEntries(body: components['schemas']['MatchingIn'], params: operations['accounting_match_entries']['parameters']['query']): RequestData<components['schemas']['MatchingOut']>;
|
|
56
|
+
getFolders(): RequestData<components['schemas']['FolderItem'][]>;
|
|
54
57
|
};
|
|
55
58
|
export { accountingFactory };
|
|
@@ -2,61 +2,68 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.accountingFactory = void 0;
|
|
4
4
|
const accountingFactory = {
|
|
5
|
-
getAnalyticPlans() {
|
|
5
|
+
getAnalyticPlans(params) {
|
|
6
6
|
return {
|
|
7
|
+
params,
|
|
7
8
|
method: 'get',
|
|
8
9
|
url: '/consumers/{consumer_id}/accounting/analytic-plans',
|
|
9
10
|
};
|
|
10
11
|
},
|
|
11
|
-
getClients() {
|
|
12
|
+
getClients(params) {
|
|
12
13
|
return {
|
|
14
|
+
params,
|
|
13
15
|
method: 'get',
|
|
14
16
|
url: '/consumers/{consumer_id}/accounting/clients',
|
|
15
17
|
};
|
|
16
18
|
},
|
|
17
19
|
createClient(client, params) {
|
|
18
20
|
return {
|
|
21
|
+
params,
|
|
19
22
|
method: 'post',
|
|
20
23
|
url: '/consumers/{consumer_id}/accounting/clients',
|
|
21
24
|
body: client,
|
|
22
|
-
params: params,
|
|
23
25
|
};
|
|
24
26
|
},
|
|
25
|
-
getClient(clientId) {
|
|
27
|
+
getClient(clientId, params) {
|
|
26
28
|
return {
|
|
29
|
+
params,
|
|
27
30
|
method: 'get',
|
|
28
31
|
url: `/consumers/{consumer_id}/accounting/clients/${clientId}`,
|
|
29
32
|
};
|
|
30
33
|
},
|
|
31
|
-
updateClient(clientId, client) {
|
|
34
|
+
updateClient(clientId, client, params) {
|
|
32
35
|
return {
|
|
36
|
+
params,
|
|
33
37
|
method: 'patch',
|
|
34
38
|
url: `/consumers/{consumer_id}/accounting/clients/${clientId}`,
|
|
35
39
|
body: client,
|
|
36
40
|
};
|
|
37
41
|
},
|
|
38
|
-
getSuppliers() {
|
|
42
|
+
getSuppliers(params) {
|
|
39
43
|
return {
|
|
44
|
+
params,
|
|
40
45
|
method: 'get',
|
|
41
46
|
url: '/consumers/{consumer_id}/accounting/suppliers',
|
|
42
47
|
};
|
|
43
48
|
},
|
|
44
49
|
createSupplier(supplier, params) {
|
|
45
50
|
return {
|
|
51
|
+
params,
|
|
46
52
|
method: 'post',
|
|
47
53
|
url: '/consumers/{consumer_id}/accounting/suppliers',
|
|
48
54
|
body: supplier,
|
|
49
|
-
params: params,
|
|
50
55
|
};
|
|
51
56
|
},
|
|
52
|
-
getSupplier(supplierId) {
|
|
57
|
+
getSupplier(supplierId, params) {
|
|
53
58
|
return {
|
|
59
|
+
params,
|
|
54
60
|
method: 'get',
|
|
55
61
|
url: `/consumers/{consumer_id}/accounting/suppliers/${supplierId}`,
|
|
56
62
|
};
|
|
57
63
|
},
|
|
58
|
-
updateSupplier(supplierId, supplier) {
|
|
64
|
+
updateSupplier(supplierId, supplier, params) {
|
|
59
65
|
return {
|
|
66
|
+
params,
|
|
60
67
|
method: 'patch',
|
|
61
68
|
url: `/consumers/{consumer_id}/accounting/suppliers/${supplierId}`,
|
|
62
69
|
body: supplier,
|
|
@@ -106,54 +113,62 @@ const accountingFactory = {
|
|
|
106
113
|
url: `/consumers/{consumer_id}/accounting/invoices/multi-analytic-plans/type/${invoice_type}`,
|
|
107
114
|
};
|
|
108
115
|
},
|
|
109
|
-
createAnalyticAccount(analyticAccount) {
|
|
116
|
+
createAnalyticAccount(analyticAccount, params) {
|
|
110
117
|
return {
|
|
118
|
+
params,
|
|
111
119
|
method: 'post',
|
|
112
120
|
url: '/consumers/{consumer_id}/accounting/analytic-accounts',
|
|
113
121
|
body: analyticAccount,
|
|
114
122
|
};
|
|
115
123
|
},
|
|
116
|
-
getAnalyticAccounts() {
|
|
124
|
+
getAnalyticAccounts(params) {
|
|
117
125
|
return {
|
|
126
|
+
params,
|
|
118
127
|
method: 'get',
|
|
119
128
|
url: '/consumers/{consumer_id}/accounting/analytic-accounts',
|
|
120
129
|
};
|
|
121
130
|
},
|
|
122
|
-
createAnalyticAccountWithMultiplePlans(analytic_plan, analyticAccount) {
|
|
131
|
+
createAnalyticAccountWithMultiplePlans(analytic_plan, analyticAccount, params) {
|
|
123
132
|
return {
|
|
133
|
+
params,
|
|
124
134
|
method: 'post',
|
|
125
135
|
url: `/consumers/{consumer_id}/accounting/analytic-accounts/multi-analytic-plans/${analytic_plan}`,
|
|
126
136
|
body: analyticAccount,
|
|
127
137
|
};
|
|
128
138
|
},
|
|
129
|
-
getAnalyticAccount(analytic_account_id) {
|
|
139
|
+
getAnalyticAccount(analytic_account_id, params) {
|
|
130
140
|
return {
|
|
141
|
+
params,
|
|
131
142
|
method: 'get',
|
|
132
143
|
url: `/consumers/{consumer_id}/accounting/analytic-accounts/${analytic_account_id}`,
|
|
133
144
|
};
|
|
134
145
|
},
|
|
135
|
-
updateAnalyticAccount(analytic_account_id, analyticAccount) {
|
|
146
|
+
updateAnalyticAccount(analytic_account_id, analyticAccount, params) {
|
|
136
147
|
return {
|
|
148
|
+
params,
|
|
137
149
|
method: 'patch',
|
|
138
150
|
url: `/consumers/{consumer_id}/accounting/analytic-accounts/${analytic_account_id}`,
|
|
139
151
|
body: analyticAccount,
|
|
140
152
|
};
|
|
141
153
|
},
|
|
142
|
-
getAnalyticAccountWithMultiplePlans(analytic_account_id, analytic_plan) {
|
|
154
|
+
getAnalyticAccountWithMultiplePlans(analytic_account_id, analytic_plan, params) {
|
|
143
155
|
return {
|
|
156
|
+
params,
|
|
144
157
|
method: 'get',
|
|
145
158
|
url: `/consumers/{consumer_id}/accounting/analytic-accounts/${analytic_account_id}/multi-analytic-plans/${analytic_plan}`,
|
|
146
159
|
};
|
|
147
160
|
},
|
|
148
|
-
updateAnalyticAccountWithMultiplePlans(analytic_account_id, analytic_plan, analyticAccount) {
|
|
161
|
+
updateAnalyticAccountWithMultiplePlans(analytic_account_id, analytic_plan, analyticAccount, params) {
|
|
149
162
|
return {
|
|
163
|
+
params,
|
|
150
164
|
method: 'patch',
|
|
151
165
|
url: `/consumers/{consumer_id}/accounting/analytic-accounts/${analytic_account_id}/multi-analytic-plans/${analytic_plan}`,
|
|
152
166
|
body: analyticAccount,
|
|
153
167
|
};
|
|
154
168
|
},
|
|
155
|
-
getAnalyticAccountsWithMultiplePlans() {
|
|
169
|
+
getAnalyticAccountsWithMultiplePlans(params) {
|
|
156
170
|
return {
|
|
171
|
+
params,
|
|
157
172
|
method: 'get',
|
|
158
173
|
url: '/consumers/{consumer_id}/accounting/analytic-accounts/multi-analytic-plans',
|
|
159
174
|
};
|
|
@@ -172,20 +187,23 @@ const accountingFactory = {
|
|
|
172
187
|
url: `/consumers/{consumer_id}/accounting/journal/entries/multi-analytic-plans`,
|
|
173
188
|
};
|
|
174
189
|
},
|
|
175
|
-
getPaymentsByInvoiceId(invoice_id) {
|
|
190
|
+
getPaymentsByInvoiceId(invoice_id, params) {
|
|
176
191
|
return {
|
|
192
|
+
params,
|
|
177
193
|
method: 'get',
|
|
178
194
|
url: `/consumers/{consumer_id}/accounting/invoices/id/${invoice_id}/payments`,
|
|
179
195
|
};
|
|
180
196
|
},
|
|
181
|
-
getJournals() {
|
|
197
|
+
getJournals(params) {
|
|
182
198
|
return {
|
|
199
|
+
params,
|
|
183
200
|
method: 'get',
|
|
184
201
|
url: `/consumers/{consumer_id}/accounting/journals`,
|
|
185
202
|
};
|
|
186
203
|
},
|
|
187
|
-
getVatCodes() {
|
|
204
|
+
getVatCodes(params) {
|
|
188
205
|
return {
|
|
206
|
+
params,
|
|
189
207
|
method: 'get',
|
|
190
208
|
url: `/consumers/{consumer_id}/accounting/vat-codes`,
|
|
191
209
|
};
|
|
@@ -220,6 +238,13 @@ const accountingFactory = {
|
|
|
220
238
|
body: attachment,
|
|
221
239
|
};
|
|
222
240
|
},
|
|
241
|
+
getAttachments(params) {
|
|
242
|
+
return {
|
|
243
|
+
params,
|
|
244
|
+
method: 'get',
|
|
245
|
+
url: `/consumers/{consumer_id}/accounting/attachments`,
|
|
246
|
+
};
|
|
247
|
+
},
|
|
223
248
|
getChartOfAccounts(params) {
|
|
224
249
|
return {
|
|
225
250
|
params,
|
|
@@ -283,5 +308,19 @@ const accountingFactory = {
|
|
|
283
308
|
body: journal_entry,
|
|
284
309
|
};
|
|
285
310
|
},
|
|
311
|
+
matchEntries(body, params) {
|
|
312
|
+
return {
|
|
313
|
+
params,
|
|
314
|
+
body,
|
|
315
|
+
method: 'post',
|
|
316
|
+
url: '/consumers/{consumer_id}/accounting/matching',
|
|
317
|
+
};
|
|
318
|
+
},
|
|
319
|
+
getFolders() {
|
|
320
|
+
return {
|
|
321
|
+
method: 'get',
|
|
322
|
+
url: '/consumers/{consumer_id}/accounting/folders',
|
|
323
|
+
};
|
|
324
|
+
},
|
|
286
325
|
};
|
|
287
326
|
exports.accountingFactory = accountingFactory;
|