@zauru-sdk/graphql 6.11.0 → 6.12.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.
@@ -183,6 +183,7 @@ export declare const getPaymentMethodsStringQuery: (config: {
183
183
  onlyActives: boolean;
184
184
  }) => string;
185
185
  export declare const getPaymentTermByIdStringQuery: (id: number) => string;
186
+ export declare const getPaymentByIdStringQuery: (id: number) => string;
186
187
  export declare const getInvoicesStringQuery: (options?: GetInvoicesOptions) => string;
187
188
  export declare const getInvoicesByAgencyIdStringQuery: (id: number, filters: {
188
189
  tag_id?: string;
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getCasesStringQuery = exports.getInvoicesByAgencyIdStringQuery = exports.getInvoicesStringQuery = exports.getPaymentTermByIdStringQuery = exports.getPaymentMethodsStringQuery = exports.getPaymentTermsStringQuery = exports.getSuggestedPricesStringQuery = exports.getCurrenciesStringQuery = exports.getInvoiceFormSubmissionsByInvoiceIdStringQuery = exports.getCaseFormSubmissionsByCaseIdStringQuery = exports.getLastInvoiceFormSubmissionStringQuery = exports.getInvoiceFormSubmissionsByAgencyIdStringQuery = exports.getFormSubmissionByIdStringQuery = exports.getMyCaseFormSubmissionsStringQuery = exports.getFormsByDocumentTypeStringQuery = exports.getFormsStringQuery = exports.getFormByNameStringQuery = exports.getAllFormsStringQuery = exports.getItemByNameStringQuery = exports.getBundleByNameStringQuery = exports.getBundlesByItemCategoryIdStringQuery = exports.getEmployeesByAgencyIdStringQuery = exports.getEmployeesStringQuery = exports.getEmployeeProfileStringQuery = exports.getConsolidatesBetweenDatesStringQuery = exports.getItemsBySuperCategoryStringQuery = exports.getItemsStringQuery = exports.getItemsByCategoryStringQuery = exports.getItemCategoryByIdStringQuery = exports.getSuperCategoryByIdStringQuery = exports.getPayeeByIdStringQuery = exports.getClientCategoriesStringQuery = exports.getProviderCategoriesStringQuery = exports.getPayeeCategoriesStringQuery = exports.getPayeeCategoriesByNotesMatchStringQuery = exports.getPayeeCategoryByIdStringQuery = exports.getWebAppRowsByWebAppTableIdStringQuery = exports.getWebAppRowStringQuery = exports.getAgenciesStringQuery = exports.getProvidersStringQuery = exports.getPayeesStringQuery = exports.getPurchaseOrdersBetweenDatesStringQuery = exports.getSerialsStringQuery = exports.getLotStocksByAgencyIdStringQuery = exports.getLotsByNameStringQuery = exports.getBookingByPurchaseOrderAndReferenceStringQuery = exports.getShipmentsStringQuery = exports.getPurchaseOrderStringQuery = exports.getPurchaseOrderByIdNumberStringQuery = exports.getLast100ReceptionsStringQuery = void 0;
4
- exports.getProductionWorkOrderStringQuery = exports.getPrintTemplatesStringQuery = void 0;
3
+ exports.getInvoicesByAgencyIdStringQuery = exports.getInvoicesStringQuery = exports.getPaymentByIdStringQuery = exports.getPaymentTermByIdStringQuery = exports.getPaymentMethodsStringQuery = exports.getPaymentTermsStringQuery = exports.getSuggestedPricesStringQuery = exports.getCurrenciesStringQuery = exports.getInvoiceFormSubmissionsByInvoiceIdStringQuery = exports.getCaseFormSubmissionsByCaseIdStringQuery = exports.getLastInvoiceFormSubmissionStringQuery = exports.getInvoiceFormSubmissionsByAgencyIdStringQuery = exports.getFormSubmissionByIdStringQuery = exports.getMyCaseFormSubmissionsStringQuery = exports.getFormsByDocumentTypeStringQuery = exports.getFormsStringQuery = exports.getFormByNameStringQuery = exports.getAllFormsStringQuery = exports.getItemByNameStringQuery = exports.getBundleByNameStringQuery = exports.getBundlesByItemCategoryIdStringQuery = exports.getEmployeesByAgencyIdStringQuery = exports.getEmployeesStringQuery = exports.getEmployeeProfileStringQuery = exports.getConsolidatesBetweenDatesStringQuery = exports.getItemsBySuperCategoryStringQuery = exports.getItemsStringQuery = exports.getItemsByCategoryStringQuery = exports.getItemCategoryByIdStringQuery = exports.getSuperCategoryByIdStringQuery = exports.getPayeeByIdStringQuery = exports.getClientCategoriesStringQuery = exports.getProviderCategoriesStringQuery = exports.getPayeeCategoriesStringQuery = exports.getPayeeCategoriesByNotesMatchStringQuery = exports.getPayeeCategoryByIdStringQuery = exports.getWebAppRowsByWebAppTableIdStringQuery = exports.getWebAppRowStringQuery = exports.getAgenciesStringQuery = exports.getProvidersStringQuery = exports.getPayeesStringQuery = exports.getPurchaseOrdersBetweenDatesStringQuery = exports.getSerialsStringQuery = exports.getLotStocksByAgencyIdStringQuery = exports.getLotsByNameStringQuery = exports.getBookingByPurchaseOrderAndReferenceStringQuery = exports.getShipmentsStringQuery = exports.getPurchaseOrderStringQuery = exports.getPurchaseOrderByIdNumberStringQuery = exports.getLast100ReceptionsStringQuery = void 0;
4
+ exports.getProductionWorkOrderStringQuery = exports.getPrintTemplatesStringQuery = exports.getCasesStringQuery = void 0;
5
5
  const getLast100ReceptionsStringQuery = (agency_id) => {
6
6
  const conditions = ["voided: {_eq: false}"];
7
7
  if (agency_id) {
@@ -1765,6 +1765,56 @@ query getPaymentTermById {
1765
1765
  }
1766
1766
  `;
1767
1767
  exports.getPaymentTermByIdStringQuery = getPaymentTermByIdStringQuery;
1768
+ const getPaymentByIdStringQuery = (id) => {
1769
+ const paymentId = requirePositiveInt(id, "payment id");
1770
+ return `
1771
+ query getPaymentById {
1772
+ payments(where: { id: { _eq: ${paymentId} } }, limit: 1) {
1773
+ id
1774
+ zid
1775
+ id_number
1776
+ draft
1777
+ payee_id
1778
+ date
1779
+ agency_id
1780
+ payment_method_id
1781
+ reference
1782
+ charger_id
1783
+ receipt
1784
+ amount
1785
+ voided
1786
+ memo
1787
+ created_at
1788
+ updated_at
1789
+ creator_id
1790
+ entity_id
1791
+ payment_details_count
1792
+ confirmed_at
1793
+ confirmer_id
1794
+ pos
1795
+ draft_number
1796
+ voider_id
1797
+ exchange_rate
1798
+ currency_id
1799
+ voided_at
1800
+ payment_details {
1801
+ id
1802
+ payment_id
1803
+ invoice_id
1804
+ credit_note_id
1805
+ amount
1806
+ reference
1807
+ created_at
1808
+ updated_at
1809
+ entity_id
1810
+ contract_id
1811
+ contract_recurrence
1812
+ }
1813
+ }
1814
+ }
1815
+ `;
1816
+ };
1817
+ exports.getPaymentByIdStringQuery = getPaymentByIdStringQuery;
1768
1818
  const getInvoicesStringQuery = (options) => {
1769
1819
  const conditions = [];
1770
1820
  const rawLimit = options?.limit != null ? Number(options.limit) : 500;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zauru-sdk/graphql",
3
- "version": "6.11.0",
3
+ "version": "6.12.0",
4
4
  "description": "Queries de uso común para las aplicación de Zauru.",
5
5
  "main": "./dist/esm/index.js",
6
6
  "module": "./dist/esm/index.js",
@@ -23,5 +23,5 @@
23
23
  "tsx": "^4.23.15",
24
24
  "typescript": "^5.1.6"
25
25
  },
26
- "gitHead": "9acaa9221f755ad34df00b631f59bf8b569712ba"
26
+ "gitHead": "c8dd0d32d207bb10ce9ab3f5be040bb3b2e482c1"
27
27
  }