@fiado/type-kit 3.239.0 → 3.240.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.
|
@@ -27,6 +27,7 @@ describe('ValidationDtos (shapes mínimos de endpoints privados)', () => {
|
|
|
27
27
|
storeId: 'store_001',
|
|
28
28
|
retailerId: 'ret_001',
|
|
29
29
|
zoneId: null,
|
|
30
|
+
zoneName: null,
|
|
30
31
|
code: 'MTY-001',
|
|
31
32
|
name: 'Sucursal Centro',
|
|
32
33
|
status: StoreStatusEnum.ACTIVE,
|
|
@@ -41,6 +42,7 @@ describe('ValidationDtos (shapes mínimos de endpoints privados)', () => {
|
|
|
41
42
|
cognitoSub: '5f7c8a90-1234-4abc-9def-0123456789ab',
|
|
42
43
|
retailerId: 'ret_001',
|
|
43
44
|
homeStoreId: 'store_001',
|
|
45
|
+
displayName: 'Vendedor Uno',
|
|
44
46
|
employmentType: EmploymentTypeEnum.EMPLOYEE,
|
|
45
47
|
commissionTier: 'TIER_A',
|
|
46
48
|
status: RetailUserStatusEnum.ACTIVE,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { SaleTypeEnum } from '../enums/SaleTypeEnum';
|
|
1
2
|
/**
|
|
2
3
|
* Emitido al cerrar una venta (flujo 09). Se escribe al outbox transaccional en la MISMA
|
|
3
4
|
* `TransactWriteItems` del cierre; drena a la cola Central + datalake. Solo identificadores
|
|
@@ -11,7 +12,23 @@ export interface SaleCompletedV1 {
|
|
|
11
12
|
retailCustomerId: string;
|
|
12
13
|
sku: string;
|
|
13
14
|
imei: string | null;
|
|
15
|
+
/**
|
|
16
|
+
* Lo COBRADO en caja al cerrar (contrato histórico — La Central y comisión F4 lo asumen así).
|
|
17
|
+
* En contado == precio del equipo; en CREDIT es SOLO el enganche: desambiguar con `type` +
|
|
18
|
+
* `equipmentPriceCents`, NUNCA redefinir este campo.
|
|
19
|
+
*/
|
|
14
20
|
amountCents: number;
|
|
21
|
+
/**
|
|
22
|
+
* Eje financiero (aditivos 2026-07-28, opcionales para consumidores/eventos previos):
|
|
23
|
+
* sin `type` un crédito con $1,300 de enganche era indistinguible de un contado de $1,300.
|
|
24
|
+
*/
|
|
25
|
+
type?: SaleTypeEnum;
|
|
26
|
+
/** Precio de lista del equipo; en contado coincide con `amountCents`. */
|
|
27
|
+
equipmentPriceCents?: number;
|
|
28
|
+
/** Enganche cobrado (solo `type=CREDIT`). */
|
|
29
|
+
downPaymentCents?: number;
|
|
30
|
+
/** Puntero al crédito SOFOM en loan-credit (solo `type=CREDIT`). */
|
|
31
|
+
creditId?: string;
|
|
15
32
|
soldAt: string;
|
|
16
33
|
occurredAt: string;
|
|
17
34
|
}
|
package/package.json
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import type { SaleTypeEnum } from '../enums/SaleTypeEnum';
|
|
2
|
+
|
|
1
3
|
/**
|
|
2
4
|
* Emitido al cerrar una venta (flujo 09). Se escribe al outbox transaccional en la MISMA
|
|
3
5
|
* `TransactWriteItems` del cierre; drena a la cola Central + datalake. Solo identificadores
|
|
@@ -11,7 +13,23 @@ export interface SaleCompletedV1 {
|
|
|
11
13
|
retailCustomerId: string;
|
|
12
14
|
sku: string;
|
|
13
15
|
imei: string | null;
|
|
16
|
+
/**
|
|
17
|
+
* Lo COBRADO en caja al cerrar (contrato histórico — La Central y comisión F4 lo asumen así).
|
|
18
|
+
* En contado == precio del equipo; en CREDIT es SOLO el enganche: desambiguar con `type` +
|
|
19
|
+
* `equipmentPriceCents`, NUNCA redefinir este campo.
|
|
20
|
+
*/
|
|
14
21
|
amountCents: number;
|
|
22
|
+
/**
|
|
23
|
+
* Eje financiero (aditivos 2026-07-28, opcionales para consumidores/eventos previos):
|
|
24
|
+
* sin `type` un crédito con $1,300 de enganche era indistinguible de un contado de $1,300.
|
|
25
|
+
*/
|
|
26
|
+
type?: SaleTypeEnum;
|
|
27
|
+
/** Precio de lista del equipo; en contado coincide con `amountCents`. */
|
|
28
|
+
equipmentPriceCents?: number;
|
|
29
|
+
/** Enganche cobrado (solo `type=CREDIT`). */
|
|
30
|
+
downPaymentCents?: number;
|
|
31
|
+
/** Puntero al crédito SOFOM en loan-credit (solo `type=CREDIT`). */
|
|
32
|
+
creditId?: string;
|
|
15
33
|
soldAt: string;
|
|
16
34
|
occurredAt: string;
|
|
17
35
|
}
|