@nicefer/types 1.0.94 → 1.0.96

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/dist/countries.js CHANGED
@@ -6,17 +6,20 @@ exports.Countries = [
6
6
  {
7
7
  id: 'HN',
8
8
  name: 'Honduras',
9
- code: 504
9
+ code: 504,
10
+ ccy: 'HNL'
10
11
  },
11
12
  {
12
13
  id: 'SV',
13
14
  name: 'El Salvador',
14
- code: 503
15
+ code: 503,
16
+ ccy: 'USD'
15
17
  },
16
18
  {
17
19
  id: 'US',
18
20
  name: 'Estados Unidos',
19
- code: 1
21
+ code: 1,
22
+ ccy: 'USD'
20
23
  },
21
24
  ];
22
25
  exports.Regions = {
package/dist/orders.js CHANGED
@@ -6,3 +6,4 @@ Object.defineProperty(exports, "__esModule", { value: true });
6
6
  ;
7
7
  ;
8
8
  ;
9
+ ;
@@ -1,6 +1,8 @@
1
+ import { PaymentInDB } from "./payments";
1
2
  export interface Country {
2
3
  id: 'HN' | 'US' | 'SV';
3
4
  name: string;
5
+ ccy: PaymentInDB['ccy'];
4
6
  code: number | null | undefined;
5
7
  }
6
8
  export interface City {
@@ -1,7 +1,7 @@
1
1
  import { PaymentIntent } from "@stripe/stripe-js";
2
2
  import { DeliveryMethod, ProductWithVariantInBag } from "./bag";
3
3
  import { UserAddressInDB } from "./users";
4
- import { PaymentInDB } from "./payments";
4
+ import { Country } from "./countries";
5
5
  export interface OrderDiscount {
6
6
  id: string;
7
7
  name: string;
@@ -33,6 +33,7 @@ export interface OrderInDB {
33
33
  id: string;
34
34
  customerName: string;
35
35
  customerId: string;
36
+ customerCountry: Country;
36
37
  products: ProductWithVariantInBag[];
37
38
  /**
38
39
  * Indicará qué productos de {@link products} fueron preparados y cuantas unidades.
@@ -43,7 +44,6 @@ export interface OrderInDB {
43
44
  totalPrice: number;
44
45
  shippingPrice: number;
45
46
  discounts?: OrderDiscountApplied[];
46
- ccy: PaymentInDB['ccy'];
47
47
  status: 'pending' | 'payment_error' | 'processing' | 'prepared' | 'shipped' | 'delivered' | 'canceled';
48
48
  orderDate: string;
49
49
  /**
@@ -92,3 +92,9 @@ export interface OrderReady {
92
92
  subtotalWithDiscount: number;
93
93
  totalPrice: number;
94
94
  }
95
+ /**
96
+ * Ordenes listas para que el usuario decida pagar
97
+ */
98
+ export interface OrdersReady {
99
+ [warehouseId: string]: OrderReady;
100
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nicefer/types",
3
- "version": "1.0.94",
3
+ "version": "1.0.96",
4
4
  "description": "Tipos compartidos para Nicefer",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.js",