@chift/chift-nodejs 1.0.7 → 1.0.9

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 (58) hide show
  1. package/.eslintcache +1 -0
  2. package/.github/workflows/ci.yml +2 -1
  3. package/CHANGELOG.md +28 -0
  4. package/coverage/clover.xml +1645 -0
  5. package/coverage/coverage-final.json +19 -0
  6. package/coverage/lcov-report/base.css +224 -0
  7. package/coverage/lcov-report/block-navigation.js +87 -0
  8. package/coverage/lcov-report/favicon.png +0 -0
  9. package/coverage/lcov-report/index.html +146 -0
  10. package/coverage/lcov-report/prettify.css +1 -0
  11. package/coverage/lcov-report/prettify.js +2 -0
  12. package/coverage/lcov-report/sort-arrow-sprite.png +0 -0
  13. package/coverage/lcov-report/sorter.js +196 -0
  14. package/coverage/lcov-report/src/helpers/index.html +131 -0
  15. package/coverage/lcov-report/src/helpers/openapi.ts.html +151 -0
  16. package/coverage/lcov-report/src/helpers/settings.ts.html +94 -0
  17. package/coverage/lcov-report/src/index.html +116 -0
  18. package/coverage/lcov-report/src/index.ts.html +88 -0
  19. package/coverage/lcov-report/src/modules/accounting.ts.html +1156 -0
  20. package/coverage/lcov-report/src/modules/api.ts.html +190 -0
  21. package/coverage/lcov-report/src/modules/consumer.ts.html +616 -0
  22. package/coverage/lcov-report/src/modules/consumers.ts.html +331 -0
  23. package/coverage/lcov-report/src/modules/custom.ts.html +193 -0
  24. package/coverage/lcov-report/src/modules/datastores.ts.html +142 -0
  25. package/coverage/lcov-report/src/modules/ecommerce.ts.html +331 -0
  26. package/coverage/lcov-report/src/modules/flow.ts.html +589 -0
  27. package/coverage/lcov-report/src/modules/index.html +326 -0
  28. package/coverage/lcov-report/src/modules/integrations.ts.html +151 -0
  29. package/coverage/lcov-report/src/modules/internalApi.ts.html +586 -0
  30. package/coverage/lcov-report/src/modules/invoicing.ts.html +391 -0
  31. package/coverage/lcov-report/src/modules/pos.ts.html +421 -0
  32. package/coverage/lcov-report/src/modules/sync.ts.html +316 -0
  33. package/coverage/lcov-report/src/modules/syncs.ts.html +169 -0
  34. package/coverage/lcov-report/src/modules/webhooks.ts.html +343 -0
  35. package/coverage/lcov.info +1976 -0
  36. package/dist/src/modules/accounting.d.ts +6 -6
  37. package/dist/src/modules/accounting.js +11 -17
  38. package/dist/src/modules/api.d.ts +27909 -1622
  39. package/dist/src/modules/consumer.d.ts +46 -320
  40. package/dist/src/modules/consumer.js +0 -10
  41. package/dist/src/modules/consumers.d.ts +230 -1620
  42. package/dist/src/modules/ecommerce.d.ts +0 -8
  43. package/dist/src/modules/ecommerce.js +0 -28
  44. package/dist/src/modules/flow.js +1 -1
  45. package/dist/src/modules/pos.d.ts +1 -3
  46. package/dist/src/modules/pos.js +0 -7
  47. package/dist/src/modules/sync.d.ts +184 -1296
  48. package/dist/src/modules/syncs.d.ts +27677 -8
  49. package/dist/src/modules/syncs.js +0 -10
  50. package/dist/test/modules/accounting.test.js +11 -0
  51. package/dist/test/modules/ecommerce.test.js +7 -34
  52. package/dist/test/modules/flow.test.d.ts +1 -0
  53. package/dist/test/modules/flow.test.js +69 -0
  54. package/dist/test/modules/pos.test.js +5 -10
  55. package/package.json +1 -1
  56. package/src/modules/accounting.ts +95 -22
  57. package/src/modules/integrations.ts +4 -2
  58. package/test/modules/accounting.test.ts +31 -0
@@ -31,25 +31,25 @@ declare const accountingFactory: {
31
31
  getAnalyticAccountWithMultiplePlans(analytic_account_id: string, analytic_plan: string): RequestData<components['schemas']['AnalyticAccountItemOutMultiAnalyticPlans']>;
32
32
  updateAnalyticAccountWithMultiplePlans(analytic_account_id: string, analytic_plan: string, analyticAccount: components['schemas']['AnalyticAccountItemUpdate']): RequestData<components['schemas']['AnalyticAccountItemOutMultiAnalyticPlans']>;
33
33
  getAnalyticAccountsWithMultiplePlans(): RequestData<components['schemas']['AnalyticAccountItemOutMultiAnalyticPlans'][]>;
34
+ getAnalyticLinesOfAccount(analytic_account_id: string): RequestData<components['schemas']['AnalyticAccountLineItemOut'][]>;
34
35
  getJournalEntries(params: getJournalEntriesParams): RequestData<components['schemas']['JournalEntryMonoAnalyticPlan'][]>;
35
36
  getJournalEntriesWithMultiplePlans(params: getJournalEntriesWithMultiplePlansParams): RequestData<components['schemas']['JournalEntryMultiAnalyticPlan'][]>;
36
37
  getPaymentsByInvoiceId(invoice_id: string): RequestData<components['schemas']['Payment'][]>;
37
38
  getJournals(): RequestData<components['schemas']['Journal'][]>;
38
39
  getVatCodes(): RequestData<components['schemas']['app__routers__accounting__VatCode'][]>;
39
40
  getMiscOperations(params: getMiscOperationsParams): RequestData<components['schemas']['MiscellaneousOperationOut'][]>;
40
- createMiscOperation(operation: components['schemas']['MiscellaneousOperationIn'], params: operations['accounting_create_miscellaneous_operation']['parameters']['query']): RequestData<components['schemas']['MiscellaneousOperationOut']>;
41
- getMiscOperation(operation_id: string, params: operations['accounting_get_miscellaneous_operation']['parameters']['query']): RequestData<components['schemas']['MiscellaneousOperationOut']>;
41
+ createMiscOperation(operation: components['schemas']['MiscellaneousOperationIn']): RequestData<components['schemas']['MiscellaneousOperationOut']>;
42
+ getMiscOperation(operation_id: string): RequestData<components['schemas']['MiscellaneousOperationOut']>;
42
43
  attachPDF(invoice_id: string, attachment: components['schemas']['AttachmentItem'], params: operations['accounting_add_attachment']['parameters']['query']): RequestData<operations['accounting_add_attachment']['responses'][201]>;
43
44
  getChartOfAccounts(params: getChartOfAccountsParams): RequestData<components['schemas']['AccountItem'][]>;
44
- getBalanceOfAccounts(filter: components['schemas']['AccountBalanceFilter'], params: operations['accounting_get_accounts_balances']['parameters']['query']): RequestData<components['schemas']['AccountBalance'][]>;
45
- getEmployees(params: operations['accounting_get_employees']['parameters']['query']): RequestData<components['schemas']['EmployeeItem'][]>;
45
+ getBalanceOfAccounts(filter: components['schemas']['AccountBalanceFilter']): RequestData<components['schemas']['AccountBalance'][]>;
46
+ getEmployees(): RequestData<components['schemas']['EmployeeItem'][]>;
46
47
  getOutstandings(params: getOutstandingsParams): RequestData<components['schemas']['OutstandingItem'][]>;
47
48
  /**
48
49
  * @deprecated replaced by createFinancialEntry
49
50
  */
50
51
  createFinancialEntryOld(financial_entry: components['schemas']['FinancialEntryItemInOld'], params: operations['accounting_create_financial_entry']['parameters']['query']): RequestData<components['schemas']['FinancialEntryItemOutOld']>;
51
52
  createFinancialEntry(financial_entry: components['schemas']['FinancialEntryItemIn'], params: operations['accounting_create_financial_entries']['parameters']['query']): RequestData<components['schemas']['FinancialEntryItemOut'][]>;
52
- createJournalEntryOld(journal_entry: components['schemas']['JournalEntryIn']): RequestData<components['schemas']['JournalEntryMultiAnalyticPlan']>;
53
- createJournalEntry(journal_entry: components['schemas']['GenericJournalEntry'], params: operations['accounting_create_generic_journal_entry']['parameters']['query']): RequestData<components['schemas']['JournalEntryMultiAnalyticPlan']>;
53
+ createJournalEntry(journal_entry: components['schemas']['JournalEntryIn']): RequestData<components['schemas']['JournalEntryMultiAnalyticPlan']>;
54
54
  };
55
55
  export { accountingFactory };
@@ -158,6 +158,12 @@ const accountingFactory = {
158
158
  url: '/consumers/{consumer_id}/accounting/analytic-accounts/multi-analytic-plans',
159
159
  };
160
160
  },
161
+ getAnalyticLinesOfAccount(analytic_account_id) {
162
+ return {
163
+ method: 'get',
164
+ url: `/consumers/{consumer_id}/accounting/analytic-account-lines/account/${analytic_account_id}`,
165
+ };
166
+ },
161
167
  getJournalEntries(params) {
162
168
  return {
163
169
  params,
@@ -197,17 +203,15 @@ const accountingFactory = {
197
203
  url: '/consumers/{consumer_id}/accounting/miscellaneous-operation',
198
204
  };
199
205
  },
200
- createMiscOperation(operation, params) {
206
+ createMiscOperation(operation) {
201
207
  return {
202
- params,
203
208
  method: 'post',
204
209
  url: '/consumers/{consumer_id}/accounting/miscellaneous-operation',
205
210
  body: operation,
206
211
  };
207
212
  },
208
- getMiscOperation(operation_id, params) {
213
+ getMiscOperation(operation_id) {
209
214
  return {
210
- params,
211
215
  method: 'get',
212
216
  url: `/consumers/{consumer_id}/accounting/miscellaneous-operation/${operation_id}`,
213
217
  };
@@ -227,17 +231,15 @@ const accountingFactory = {
227
231
  url: '/consumers/{consumer_id}/accounting/chart-of-accounts',
228
232
  };
229
233
  },
230
- getBalanceOfAccounts(filter, params) {
234
+ getBalanceOfAccounts(filter) {
231
235
  return {
232
- params,
233
236
  method: 'post',
234
237
  url: '/consumers/{consumer_id}/accounting/chart-of-accounts/balance',
235
238
  body: filter,
236
239
  };
237
240
  },
238
- getEmployees(params) {
241
+ getEmployees() {
239
242
  return {
240
- params,
241
243
  method: 'get',
242
244
  url: '/consumers/{consumer_id}/accounting/employees',
243
245
  };
@@ -268,20 +270,12 @@ const accountingFactory = {
268
270
  body: financial_entry,
269
271
  };
270
272
  },
271
- createJournalEntryOld(journal_entry) {
273
+ createJournalEntry(journal_entry) {
272
274
  return {
273
275
  method: 'post',
274
276
  url: '/consumers/{consumer_id}/accounting/journal/entries',
275
277
  body: journal_entry,
276
278
  };
277
279
  },
278
- createJournalEntry(journal_entry, params) {
279
- return {
280
- params,
281
- method: 'post',
282
- url: '/consumers/{consumer_id}/accounting/journal-entries',
283
- body: journal_entry,
284
- };
285
- },
286
280
  };
287
281
  exports.accountingFactory = accountingFactory;