@things-factory/station 10.1.141 → 10.1.143
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-client/tsconfig.tsbuildinfo +1 -1
- package/dist-server/activities/activity-station-screen-control-withdrawal.js +3 -7
- package/dist-server/activities/activity-station-screen-control-withdrawal.js.map +1 -1
- package/dist-server/service/index.d.ts +0 -1
- package/dist-server/service/index.js +0 -1
- package/dist-server/service/index.js.map +1 -1
- package/dist-server/service/station/index.d.ts +2 -2
- package/dist-server/service/station/station-product.d.ts +4 -31
- package/dist-server/service/station/station-product.js +5 -5
- package/dist-server/service/station/station-product.js.map +1 -1
- package/dist-server/tsconfig.tsbuildinfo +1 -1
- package/package.json +8 -7
- package/dist-server/service/station/deletion-changes.d.ts +0 -14
- package/dist-server/service/station/deletion-changes.js +0 -25
- package/dist-server/service/station/deletion-changes.js.map +0 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@things-factory/station",
|
|
3
|
-
"version": "10.1.
|
|
3
|
+
"version": "10.1.143",
|
|
4
4
|
"main": "dist-server/index.js",
|
|
5
5
|
"browser": "dist-client/index.js",
|
|
6
6
|
"things-factory": true,
|
|
@@ -33,12 +33,13 @@
|
|
|
33
33
|
"@hatiolab/things-scene": "^10.0.0",
|
|
34
34
|
"@operato/i18n": "^10.0.0",
|
|
35
35
|
"@operato/styles": "^10.0.0",
|
|
36
|
-
"@things-factory/auth-base": "^10.1.
|
|
37
|
-
"@things-factory/board-service": "^10.1.
|
|
38
|
-
"@things-factory/
|
|
39
|
-
"@things-factory/
|
|
40
|
-
"@things-factory/
|
|
36
|
+
"@things-factory/auth-base": "^10.1.142",
|
|
37
|
+
"@things-factory/board-service": "^10.1.142",
|
|
38
|
+
"@things-factory/fact-change": "^10.1.142",
|
|
39
|
+
"@things-factory/ops-master": "^10.1.142",
|
|
40
|
+
"@things-factory/shell": "^10.1.142",
|
|
41
|
+
"@things-factory/worklist": "^10.1.142",
|
|
41
42
|
"i18next": "^24.2.1"
|
|
42
43
|
},
|
|
43
|
-
"gitHead": "
|
|
44
|
+
"gitHead": "a013bf8fc8657c56bc5adc351e3c4b6206d46e69"
|
|
44
45
|
}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* **A row as it was, written as history rows at the moment it is deleted.**
|
|
3
|
-
*
|
|
4
|
-
* A deletion is reversible only if what it removed stays readable (ADR-0064, condition ③). An approval
|
|
5
|
-
* record carries the row as it was when the request was raised, which is what the approver saw; the row
|
|
6
|
-
* can change between raising and approving. What the callback actually deletes is written here, from the
|
|
7
|
-
* row it read, one history row per content column with its value as `fromValue` and nothing as `toValue`
|
|
8
|
-
* (chief architect, 2026-09-17).
|
|
9
|
-
*/
|
|
10
|
-
export declare function deletionChanges(snapshot: Record<string, unknown>): {
|
|
11
|
-
field: string;
|
|
12
|
-
fromValue?: string;
|
|
13
|
-
toValue?: string;
|
|
14
|
-
}[];
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.deletionChanges = deletionChanges;
|
|
4
|
-
/**
|
|
5
|
-
* **A row as it was, written as history rows at the moment it is deleted.**
|
|
6
|
-
*
|
|
7
|
-
* A deletion is reversible only if what it removed stays readable (ADR-0064, condition ③). An approval
|
|
8
|
-
* record carries the row as it was when the request was raised, which is what the approver saw; the row
|
|
9
|
-
* can change between raising and approving. What the callback actually deletes is written here, from the
|
|
10
|
-
* row it read, one history row per content column with its value as `fromValue` and nothing as `toValue`
|
|
11
|
-
* (chief architect, 2026-09-17).
|
|
12
|
-
*/
|
|
13
|
-
function deletionChanges(snapshot) {
|
|
14
|
-
return Object.entries(snapshot)
|
|
15
|
-
.filter(([, value]) => value !== undefined && value !== null && value !== '')
|
|
16
|
-
.map(([field, value]) => ({ field, fromValue: textOf(value) }));
|
|
17
|
-
}
|
|
18
|
-
function textOf(value) {
|
|
19
|
-
if (value instanceof Date)
|
|
20
|
-
return value.toISOString();
|
|
21
|
-
if (typeof value === 'object')
|
|
22
|
-
return JSON.stringify(value);
|
|
23
|
-
return String(value);
|
|
24
|
-
}
|
|
25
|
-
//# sourceMappingURL=deletion-changes.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"deletion-changes.js","sourceRoot":"","sources":["../../../server/service/station/deletion-changes.ts"],"names":[],"mappings":";;AASA,0CAIC;AAbD;;;;;;;;GAQG;AACH,SAAgB,eAAe,CAAC,QAAiC;IAC/D,OAAO,MAAM,CAAC,OAAO,CAAC,QAAQ,CAAC;SAC5B,MAAM,CAAC,CAAC,CAAC,EAAE,KAAK,CAAC,EAAE,EAAE,CAAC,KAAK,KAAK,SAAS,IAAI,KAAK,KAAK,IAAI,IAAI,KAAK,KAAK,EAAE,CAAC;SAC5E,GAAG,CAAC,CAAC,CAAC,KAAK,EAAE,KAAK,CAAC,EAAE,EAAE,CAAC,CAAC,EAAE,KAAK,EAAE,SAAS,EAAE,MAAM,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC,CAAA;AACnE,CAAC;AAED,SAAS,MAAM,CAAC,KAAc;IAC5B,IAAI,KAAK,YAAY,IAAI;QAAE,OAAO,KAAK,CAAC,WAAW,EAAE,CAAA;IACrD,IAAI,OAAO,KAAK,KAAK,QAAQ;QAAE,OAAO,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,CAAA;IAC3D,OAAO,MAAM,CAAC,KAAK,CAAC,CAAA;AACtB,CAAC","sourcesContent":["/**\n * **A row as it was, written as history rows at the moment it is deleted.**\n *\n * A deletion is reversible only if what it removed stays readable (ADR-0064, condition ③). An approval\n * record carries the row as it was when the request was raised, which is what the approver saw; the row\n * can change between raising and approving. What the callback actually deletes is written here, from the\n * row it read, one history row per content column with its value as `fromValue` and nothing as `toValue`\n * (chief architect, 2026-09-17).\n */\nexport function deletionChanges(snapshot: Record<string, unknown>): { field: string; fromValue?: string; toValue?: string }[] {\n return Object.entries(snapshot)\n .filter(([, value]) => value !== undefined && value !== null && value !== '')\n .map(([field, value]) => ({ field, fromValue: textOf(value) }))\n}\n\nfunction textOf(value: unknown): string {\n if (value instanceof Date) return value.toISOString()\n if (typeof value === 'object') return JSON.stringify(value)\n return String(value)\n}\n"]}
|