@infrab4a/connect 5.6.0-beta.2 → 5.6.0-beta.4

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/index.cjs.js CHANGED
@@ -7761,14 +7761,20 @@ class ProductGroupHasuraGraphQLRepository extends withCrudHasuraGraphQL(withHasu
7761
7761
  authOptions,
7762
7762
  interceptors,
7763
7763
  fields: [
7764
- 'id',
7764
+ {
7765
+ id: {
7766
+ columnName: 'id',
7767
+ to: (value) => +value,
7768
+ from: (value) => value.toString(),
7769
+ },
7770
+ },
7765
7771
  'name',
7766
7772
  'description',
7767
7773
  { markupMin: { columnName: 'markup_min' } },
7768
7774
  { markupWithoutCompetitor: { columnName: 'markup_without_competitor' } },
7769
7775
  { discountCompetitor: { columnName: 'discount_competitor' } },
7770
7776
  { subscriberDiscountPercentage: { columnName: 'subscriber_discount_percentage' } },
7771
- { automaticPriceAdjustment: { columnName: 'automatic_price_adjustment' } },
7777
+ { dynamicPrecification: { columnName: 'dynamic_precification' } },
7772
7778
  { createdAt: { columnName: 'created_at' } },
7773
7779
  { updatedAt: { columnName: 'updated_at' } },
7774
7780
  ],
@@ -8638,7 +8644,13 @@ class ProductPriceLogHasuraGraphQLRepository extends withCrudHasuraGraphQL(withH
8638
8644
  authOptions,
8639
8645
  interceptors,
8640
8646
  fields: [
8641
- 'id',
8647
+ {
8648
+ id: {
8649
+ columnName: 'id',
8650
+ to: (value) => +value,
8651
+ from: (value) => value.toString(),
8652
+ },
8653
+ },
8642
8654
  { productId: { columnName: 'product_id' } },
8643
8655
  { productEAN: { columnName: 'product_ean' } },
8644
8656
  { productSKU: { columnName: 'product_sku' } },
@@ -9785,6 +9797,7 @@ class MercadoPagoCardAxiosAdapter {
9785
9797
  limiteRange: 'day',
9786
9798
  card,
9787
9799
  gatewayInfo: {
9800
+ gateway: exports.PaymentProviders.MERCADOPAGO,
9788
9801
  status: data.status,
9789
9802
  statusDetail: data.status_detail,
9790
9803
  },
@@ -10800,6 +10813,7 @@ class PagarmeV5CardAxiosAdapter {
10800
10813
  card,
10801
10814
  orderBlockedRepository: this.orderBlockedRepository,
10802
10815
  gatewayInfo: {
10816
+ gateway: exports.PaymentProviders.PAGARME,
10803
10817
  status: charge.status,
10804
10818
  statusDetail: charge.last_transaction?.status,
10805
10819
  },
package/index.esm.js CHANGED
@@ -7737,14 +7737,20 @@ class ProductGroupHasuraGraphQLRepository extends withCrudHasuraGraphQL(withHasu
7737
7737
  authOptions,
7738
7738
  interceptors,
7739
7739
  fields: [
7740
- 'id',
7740
+ {
7741
+ id: {
7742
+ columnName: 'id',
7743
+ to: (value) => +value,
7744
+ from: (value) => value.toString(),
7745
+ },
7746
+ },
7741
7747
  'name',
7742
7748
  'description',
7743
7749
  { markupMin: { columnName: 'markup_min' } },
7744
7750
  { markupWithoutCompetitor: { columnName: 'markup_without_competitor' } },
7745
7751
  { discountCompetitor: { columnName: 'discount_competitor' } },
7746
7752
  { subscriberDiscountPercentage: { columnName: 'subscriber_discount_percentage' } },
7747
- { automaticPriceAdjustment: { columnName: 'automatic_price_adjustment' } },
7753
+ { dynamicPrecification: { columnName: 'dynamic_precification' } },
7748
7754
  { createdAt: { columnName: 'created_at' } },
7749
7755
  { updatedAt: { columnName: 'updated_at' } },
7750
7756
  ],
@@ -8614,7 +8620,13 @@ class ProductPriceLogHasuraGraphQLRepository extends withCrudHasuraGraphQL(withH
8614
8620
  authOptions,
8615
8621
  interceptors,
8616
8622
  fields: [
8617
- 'id',
8623
+ {
8624
+ id: {
8625
+ columnName: 'id',
8626
+ to: (value) => +value,
8627
+ from: (value) => value.toString(),
8628
+ },
8629
+ },
8618
8630
  { productId: { columnName: 'product_id' } },
8619
8631
  { productEAN: { columnName: 'product_ean' } },
8620
8632
  { productSKU: { columnName: 'product_sku' } },
@@ -9761,6 +9773,7 @@ class MercadoPagoCardAxiosAdapter {
9761
9773
  limiteRange: 'day',
9762
9774
  card,
9763
9775
  gatewayInfo: {
9776
+ gateway: PaymentProviders.MERCADOPAGO,
9764
9777
  status: data.status,
9765
9778
  statusDetail: data.status_detail,
9766
9779
  },
@@ -10776,6 +10789,7 @@ class PagarmeV5CardAxiosAdapter {
10776
10789
  card,
10777
10790
  orderBlockedRepository: this.orderBlockedRepository,
10778
10791
  gatewayInfo: {
10792
+ gateway: PaymentProviders.PAGARME,
10779
10793
  status: charge.status,
10780
10794
  statusDetail: charge.last_transaction?.status,
10781
10795
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@infrab4a/connect",
3
- "version": "5.6.0-beta.2",
3
+ "version": "5.6.0-beta.4",
4
4
  "publishConfig": {
5
5
  "registry": "https://registry.npmjs.org"
6
6
  },
@@ -7,6 +7,6 @@ export declare class ProductGroup extends BaseModel<ProductGroup> {
7
7
  markupWithoutCompetitor?: number;
8
8
  discountCompetitor?: number;
9
9
  subscriberDiscountPercentage?: number;
10
- automaticPriceAdjustment: boolean;
10
+ dynamicPrecification: boolean;
11
11
  static get identifiersFields(): GenericIdentifier[];
12
12
  }
@@ -19,7 +19,11 @@ export declare class OrderBlocked extends BaseModel<OrderBlocked> {
19
19
  type: OrderBlockedType;
20
20
  card?: any;
21
21
  checkout: Checkout;
22
- gatewayInfo?: any;
22
+ gatewayInfo?: {
23
+ gateway?: string;
24
+ status?: string;
25
+ statusDetail?: string;
26
+ };
23
27
  date: Date;
24
28
  static get identifiersFields(): GenericIdentifier[];
25
29
  }
@@ -7,7 +7,11 @@ type CreateBlockedOrderParams = {
7
7
  type: string;
8
8
  limiteRange: string;
9
9
  card?: PaymentCardInfo;
10
- gatewayInfo?: any;
10
+ gatewayInfo?: {
11
+ gateway?: string;
12
+ status?: string;
13
+ statusDetail?: string;
14
+ };
11
15
  };
12
16
  export interface OrderBlockedRepository extends CrudRepository<OrderBlocked> {
13
17
  createBlockedOrderOrPayment(params: CreateBlockedOrderParams): Promise<OrderBlocked>;
@@ -16,6 +16,7 @@ export declare class User extends BaseModel<User> {
16
16
  officePosition?: OfficePosition;
17
17
  isSubscriber?: boolean;
18
18
  subscriptionPlan?: string;
19
+ subscriptionDate?: string;
19
20
  badgeId?: number;
20
21
  badgeMultiplier?: number;
21
22
  dateCreated?: Date;
@@ -6,6 +6,7 @@ interface BlockedOrderParams {
6
6
  card: PaymentCardInfo;
7
7
  orderBlockedRepository: OrderBlockedRepository;
8
8
  gatewayInfo?: {
9
+ gateway: string;
9
10
  status: string;
10
11
  statusDetail: string;
11
12
  };