sinfactura-types 1.10.232 → 1.10.233
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/product.d.ts +42 -0
- package/package.json +1 -1
package/dist/product.d.ts
CHANGED
|
@@ -240,6 +240,48 @@ declare global {
|
|
|
240
240
|
* field, not that the class is fresh.
|
|
241
241
|
*/
|
|
242
242
|
abcClassifiedAt?: number;
|
|
243
|
+
/**
|
|
244
|
+
* Unix ms of the last movement that CREDITED this product's stock — a
|
|
245
|
+
* receipt, a restock on a return or cancellation, a positive adjustment, or
|
|
246
|
+
* a MercadoLibre sale being retracted.
|
|
247
|
+
*
|
|
248
|
+
* ⚠️ Absence means NO RECORDED INBOUND, not "never received". The three
|
|
249
|
+
* `last*At` stamps are forward-only: nothing backfills them, so a product
|
|
250
|
+
* whose last receipt predates the stamp reads as absent forever. A reader
|
|
251
|
+
* that treats absence as "very old" is right about the aging question and
|
|
252
|
+
* wrong about the audit one — never present it as a date.
|
|
253
|
+
*/
|
|
254
|
+
lastInboundAt?: number;
|
|
255
|
+
/**
|
|
256
|
+
* Unix ms of the last movement that DEBITED this product — a sale, a service
|
|
257
|
+
* part consumed, an edit that increased a line, or a negative adjustment.
|
|
258
|
+
*
|
|
259
|
+
* ⚠️ **This, not `lastMovementAt`, is what a dead-stock report ages on.** A
|
|
260
|
+
* receipt does not make stock young: a product nobody has bought for a year
|
|
261
|
+
* is dead stock whether or not a case of it arrived last week, and bucketing
|
|
262
|
+
* on last movement would file exactly that case as fresh. `lastMovementAt`
|
|
263
|
+
* answers a different question — when did this row's stock last change at
|
|
264
|
+
* all — which is the one an audit or a reconciliation asks.
|
|
265
|
+
*
|
|
266
|
+
* ⚠️ A SERVICE line stamps this while moving no stock. `lastOutboundAt` means
|
|
267
|
+
* "last sold or consumed", not "last decremented", so a service product that
|
|
268
|
+
* carries no stock still records when it was last billed.
|
|
269
|
+
*
|
|
270
|
+
* ⚠️ Forward-only, like its two siblings — see `lastInboundAt`.
|
|
271
|
+
*/
|
|
272
|
+
lastOutboundAt?: number;
|
|
273
|
+
/**
|
|
274
|
+
* Unix ms of the most recent movement in either direction — the max of
|
|
275
|
+
* `lastInboundAt` and `lastOutboundAt` as of the last write.
|
|
276
|
+
*
|
|
277
|
+
* Stored rather than derived so a catalogue-wide "what has moved since X"
|
|
278
|
+
* is one projection instead of a per-row comparison, and so a reader that
|
|
279
|
+
* wants only recency does not have to know which stamps exist.
|
|
280
|
+
*
|
|
281
|
+
* ⚠️ Read the `lastOutboundAt` docblock before reaching for this one: for
|
|
282
|
+
* dead stock it is the WRONG field, and it is the more obvious of the two.
|
|
283
|
+
*/
|
|
284
|
+
lastMovementAt?: number;
|
|
243
285
|
/**
|
|
244
286
|
* Shipping weight, in GRAMS.
|
|
245
287
|
*
|