@elaraai/e3-ui 1.0.93 → 1.0.95
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/src/allocation/adapters.d.ts +159 -0
- package/dist/src/allocation/adapters.d.ts.map +1 -0
- package/dist/src/allocation/adapters.js +241 -0
- package/dist/src/allocation/adapters.js.map +1 -0
- package/dist/src/allocation/functions.d.ts +664 -0
- package/dist/src/allocation/functions.d.ts.map +1 -0
- package/dist/src/allocation/functions.js +782 -0
- package/dist/src/allocation/functions.js.map +1 -0
- package/dist/src/allocation/index.d.ts +2985 -0
- package/dist/src/allocation/index.d.ts.map +1 -0
- package/dist/src/allocation/index.js +499 -0
- package/dist/src/allocation/index.js.map +1 -0
- package/dist/src/allocation/types.d.ts +832 -0
- package/dist/src/allocation/types.d.ts.map +1 -0
- package/dist/src/allocation/types.js +360 -0
- package/dist/src/allocation/types.js.map +1 -0
- package/dist/src/bind/func.d.ts +14 -0
- package/dist/src/bind/func.d.ts.map +1 -1
- package/dist/src/bind/func.js +22 -1
- package/dist/src/bind/func.js.map +1 -1
- package/dist/src/calendar/index.d.ts +510 -1639
- package/dist/src/calendar/index.d.ts.map +1 -1
- package/dist/src/calendar/index.js +56 -29
- package/dist/src/calendar/index.js.map +1 -1
- package/dist/src/flowchart/canvas.d.ts +9 -21
- package/dist/src/flowchart/canvas.d.ts.map +1 -1
- package/dist/src/flowchart/canvas.js +10 -22
- package/dist/src/flowchart/canvas.js.map +1 -1
- package/dist/src/flowchart/flowchart.d.ts +19 -13
- package/dist/src/flowchart/flowchart.d.ts.map +1 -1
- package/dist/src/flowchart/flowchart.js.map +1 -1
- package/dist/src/flowchart/index.d.ts +44 -21
- package/dist/src/flowchart/index.d.ts.map +1 -1
- package/dist/src/flowchart/index.js +43 -20
- package/dist/src/flowchart/index.js.map +1 -1
- package/dist/src/flowchart/library.d.ts +166 -81
- package/dist/src/flowchart/library.d.ts.map +1 -1
- package/dist/src/flowchart/library.js +232 -105
- package/dist/src/flowchart/library.js.map +1 -1
- package/dist/src/flowchart/over.d.ts +9 -16
- package/dist/src/flowchart/over.d.ts.map +1 -1
- package/dist/src/flowchart/over.js +9 -16
- package/dist/src/flowchart/over.js.map +1 -1
- package/dist/src/flowchart/payload.d.ts +710 -508
- package/dist/src/flowchart/payload.d.ts.map +1 -1
- package/dist/src/flowchart/payload.js +128 -74
- package/dist/src/flowchart/payload.js.map +1 -1
- package/dist/src/flowchart/window.d.ts +132 -347
- package/dist/src/flowchart/window.d.ts.map +1 -1
- package/dist/src/flowchart/window.js +48 -55
- package/dist/src/flowchart/window.js.map +1 -1
- package/dist/src/index.d.ts +11 -7
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +14 -6
- package/dist/src/index.js.map +1 -1
- package/dist/src/internal.d.ts +18 -7
- package/dist/src/internal.d.ts.map +1 -1
- package/dist/src/internal.js +28 -9
- package/dist/src/internal.js.map +1 -1
- package/dist/src/plan/event-rows.d.ts +26 -10
- package/dist/src/plan/event-rows.d.ts.map +1 -1
- package/dist/src/plan/event-rows.js +39 -13
- package/dist/src/plan/event-rows.js.map +1 -1
- package/dist/src/plan/ir.d.ts +244 -815
- package/dist/src/plan/ir.d.ts.map +1 -1
- package/dist/src/plan/ir.js +8 -6
- package/dist/src/plan/ir.js.map +1 -1
- package/dist/src/plan/library.d.ts +3 -0
- package/dist/src/plan/library.d.ts.map +1 -1
- package/dist/src/plan/library.js +1 -1
- package/dist/src/plan/library.js.map +1 -1
- package/dist/src/plan/ordered-source.d.ts +1 -0
- package/dist/src/plan/ordered-source.d.ts.map +1 -1
- package/dist/src/plan/plan.d.ts +559 -1667
- package/dist/src/plan/plan.d.ts.map +1 -1
- package/dist/src/plan/plan.js +123 -45
- package/dist/src/plan/plan.js.map +1 -1
- package/dist/src/plan/root.d.ts +16 -20
- package/dist/src/plan/root.d.ts.map +1 -1
- package/dist/src/plan/root.js +23 -33
- package/dist/src/plan/root.js.map +1 -1
- package/dist/src/roster/coverage.d.ts +17 -231
- package/dist/src/roster/coverage.d.ts.map +1 -1
- package/dist/src/roster/coverage.js +94 -90
- package/dist/src/roster/coverage.js.map +1 -1
- package/dist/src/roster/fit.d.ts +59 -0
- package/dist/src/roster/fit.d.ts.map +1 -0
- package/dist/src/roster/fit.js +155 -0
- package/dist/src/roster/fit.js.map +1 -0
- package/dist/src/roster/index.d.ts +2862 -3662
- package/dist/src/roster/index.d.ts.map +1 -1
- package/dist/src/roster/index.js +383 -81
- package/dist/src/roster/index.js.map +1 -1
- package/dist/src/roster/library.d.ts +37 -92
- package/dist/src/roster/library.d.ts.map +1 -1
- package/dist/src/roster/library.js +25 -64
- package/dist/src/roster/library.js.map +1 -1
- package/dist/src/roster/lists.d.ts +195 -0
- package/dist/src/roster/lists.d.ts.map +1 -0
- package/dist/src/roster/lists.js +233 -0
- package/dist/src/roster/lists.js.map +1 -0
- package/dist/src/roster/rules.d.ts +17 -260
- package/dist/src/roster/rules.d.ts.map +1 -1
- package/dist/src/roster/rules.js +135 -132
- package/dist/src/roster/rules.js.map +1 -1
- package/dist/src/roster/targets.d.ts +115 -0
- package/dist/src/roster/targets.d.ts.map +1 -0
- package/dist/src/roster/targets.js +213 -0
- package/dist/src/roster/targets.js.map +1 -0
- package/dist/src/roster/times.d.ts +251 -0
- package/dist/src/roster/times.d.ts.map +1 -0
- package/dist/src/roster/times.js +174 -0
- package/dist/src/roster/times.js.map +1 -0
- package/dist/src/roster/types.d.ts +828 -183
- package/dist/src/roster/types.d.ts.map +1 -1
- package/dist/src/roster/types.js +224 -97
- package/dist/src/roster/types.js.map +1 -1
- package/dist/src/schedule/accessor.d.ts +28 -0
- package/dist/src/schedule/accessor.d.ts.map +1 -0
- package/dist/src/schedule/accessor.js +39 -0
- package/dist/src/schedule/accessor.js.map +1 -0
- package/dist/src/schedule/events.d.ts +170 -42
- package/dist/src/schedule/events.d.ts.map +1 -1
- package/dist/src/schedule/events.js +431 -171
- package/dist/src/schedule/events.js.map +1 -1
- package/dist/src/schedule/index.d.ts +41 -4
- package/dist/src/schedule/index.d.ts.map +1 -1
- package/dist/src/schedule/index.js +35 -3
- package/dist/src/schedule/index.js.map +1 -1
- package/dist/src/schedule/library.d.ts +13 -3
- package/dist/src/schedule/library.d.ts.map +1 -1
- package/dist/src/schedule/library.js +11 -4
- package/dist/src/schedule/library.js.map +1 -1
- package/dist/src/schedule/periods.d.ts +115 -0
- package/dist/src/schedule/periods.d.ts.map +1 -0
- package/dist/src/schedule/periods.js +215 -0
- package/dist/src/schedule/periods.js.map +1 -0
- package/dist/src/schedule/record-window.d.ts +25 -3
- package/dist/src/schedule/record-window.d.ts.map +1 -1
- package/dist/src/schedule/record-window.js +31 -18
- package/dist/src/schedule/record-window.js.map +1 -1
- package/dist/src/schedule/resources.d.ts +82 -4
- package/dist/src/schedule/resources.d.ts.map +1 -1
- package/dist/src/schedule/resources.js +44 -14
- package/dist/src/schedule/resources.js.map +1 -1
- package/dist/src/schedule/session.d.ts +69 -0
- package/dist/src/schedule/session.d.ts.map +1 -0
- package/dist/src/schedule/session.js +121 -0
- package/dist/src/schedule/session.js.map +1 -0
- package/dist/src/schedule/templates.d.ts +14 -2
- package/dist/src/schedule/templates.d.ts.map +1 -1
- package/dist/src/schedule/templates.js +5 -3
- package/dist/src/schedule/templates.js.map +1 -1
- package/dist/src/schedule/types.d.ts +1671 -37
- package/dist/src/schedule/types.d.ts.map +1 -1
- package/dist/src/schedule/types.js +196 -5
- package/dist/src/schedule/types.js.map +1 -1
- package/dist/src/schedule/window.d.ts +14 -0
- package/dist/src/schedule/window.d.ts.map +1 -1
- package/dist/src/schedule/window.js +14 -4
- package/dist/src/schedule/window.js.map +1 -1
- package/dist/src/schedule/words.d.ts +22 -0
- package/dist/src/schedule/words.d.ts.map +1 -0
- package/dist/src/schedule/words.js +25 -0
- package/dist/src/schedule/words.js.map +1 -0
- package/dist/src/sheet/index.d.ts +61 -27
- package/dist/src/sheet/index.d.ts.map +1 -1
- package/dist/src/sheet/index.js +59 -25
- package/dist/src/sheet/index.js.map +1 -1
- package/dist/src/sheet/library.d.ts +21 -3
- package/dist/src/sheet/library.d.ts.map +1 -1
- package/dist/src/sheet/library.js +23 -6
- package/dist/src/sheet/library.js.map +1 -1
- package/dist/src/sheet/registers.d.ts +100 -85
- package/dist/src/sheet/registers.d.ts.map +1 -1
- package/dist/src/sheet/registers.js +100 -85
- package/dist/src/sheet/registers.js.map +1 -1
- package/dist/src/sheet/root.d.ts +8 -12
- package/dist/src/sheet/root.d.ts.map +1 -1
- package/dist/src/sheet/root.js +6 -40
- package/dist/src/sheet/root.js.map +1 -1
- package/dist/src/sheet/sheet.d.ts +598 -2349
- package/dist/src/sheet/sheet.d.ts.map +1 -1
- package/dist/src/sheet/sheet.js +124 -37
- package/dist/src/sheet/sheet.js.map +1 -1
- package/dist/src/sheet/sub-rows.d.ts +74 -28
- package/dist/src/sheet/sub-rows.d.ts.map +1 -1
- package/dist/src/sheet/sub-rows.js +74 -28
- package/dist/src/sheet/sub-rows.js.map +1 -1
- package/dist/src/sheet/templates.d.ts +98 -34
- package/dist/src/sheet/templates.d.ts.map +1 -1
- package/dist/src/sheet/templates.js +102 -58
- package/dist/src/sheet/templates.js.map +1 -1
- package/dist/src/sheet/types.d.ts +289 -1359
- package/dist/src/sheet/types.d.ts.map +1 -1
- package/dist/src/sheet/types.js +20 -26
- package/dist/src/sheet/types.js.map +1 -1
- package/dist/src/sheet/views.d.ts +10 -11
- package/dist/src/sheet/views.d.ts.map +1 -1
- package/dist/src/sheet/views.js +15 -20
- package/dist/src/sheet/views.js.map +1 -1
- package/dist/src/{roster/visibility.d.ts → utils/key-visibility.d.ts} +42 -7
- package/dist/src/utils/key-visibility.d.ts.map +1 -0
- package/dist/src/utils/key-visibility.js +36 -0
- package/dist/src/utils/key-visibility.js.map +1 -0
- package/dist/src/utils/ordered-source.d.ts +1 -0
- package/dist/src/utils/ordered-source.d.ts.map +1 -1
- package/dist/src/utils/ordered-source.js +8 -3
- package/dist/src/utils/ordered-source.js.map +1 -1
- package/dist/src/utils/record-sources.d.ts +107 -0
- package/dist/src/utils/record-sources.d.ts.map +1 -0
- package/dist/src/utils/record-sources.js +132 -0
- package/dist/src/utils/record-sources.js.map +1 -0
- package/dist/test/allocation/allocation.examples.d.ts +2902 -0
- package/dist/test/allocation/allocation.examples.d.ts.map +1 -0
- package/dist/test/allocation/allocation.examples.js +643 -0
- package/dist/test/allocation/allocation.examples.js.map +1 -0
- package/dist/test/allocation/fit.examples.d.ts +546 -0
- package/dist/test/allocation/fit.examples.d.ts.map +1 -0
- package/dist/test/allocation/fit.examples.js +171 -0
- package/dist/test/allocation/fit.examples.js.map +1 -0
- package/dist/test/allocation/kiln-yard.d.ts +181 -0
- package/dist/test/allocation/kiln-yard.d.ts.map +1 -0
- package/dist/test/allocation/kiln-yard.js +228 -0
- package/dist/test/allocation/kiln-yard.js.map +1 -0
- package/dist/test/bind/data/data.examples.d.ts +651 -1
- package/dist/test/bind/data/data.examples.d.ts.map +1 -1
- package/dist/test/bind/data/data.examples.js +140 -2
- package/dist/test/bind/data/data.examples.js.map +1 -1
- package/dist/test/bind/func/func.examples.d.ts +10 -1
- package/dist/test/bind/func/func.examples.d.ts.map +1 -1
- package/dist/test/bind/func/func.examples.js +8 -1
- package/dist/test/bind/func/func.examples.js.map +1 -1
- package/dist/test/bind/record/record.examples.d.ts +633 -1
- package/dist/test/bind/record/record.examples.d.ts.map +1 -1
- package/dist/test/bind/record/record.examples.js +26 -2
- package/dist/test/bind/record/record.examples.js.map +1 -1
- package/dist/test/calendar/calendar-records.examples.d.ts.map +1 -1
- package/dist/test/calendar/calendar-records.examples.js +18 -14
- package/dist/test/calendar/calendar-records.examples.js.map +1 -1
- package/dist/test/calendar/calendar.examples.d.ts +521 -16
- package/dist/test/calendar/calendar.examples.d.ts.map +1 -1
- package/dist/test/calendar/calendar.examples.js +182 -135
- package/dist/test/calendar/calendar.examples.js.map +1 -1
- package/dist/test/examples-package.d.ts +75 -0
- package/dist/test/examples-package.d.ts.map +1 -0
- package/dist/test/examples-package.js +263 -0
- package/dist/test/examples-package.js.map +1 -0
- package/dist/test/flowchart/flowchart.examples.d.ts +211 -19
- package/dist/test/flowchart/flowchart.examples.d.ts.map +1 -1
- package/dist/test/flowchart/flowchart.examples.js +102 -75
- package/dist/test/flowchart/flowchart.examples.js.map +1 -1
- package/dist/test/plan/plan-events.examples.d.ts +1439 -209
- package/dist/test/plan/plan-events.examples.d.ts.map +1 -1
- package/dist/test/plan/plan-events.examples.js +199 -59
- package/dist/test/plan/plan-events.examples.js.map +1 -1
- package/dist/test/plan/plan-records.examples.d.ts +420 -0
- package/dist/test/plan/plan-records.examples.d.ts.map +1 -1
- package/dist/test/plan/plan-records.examples.js +70 -19
- package/dist/test/plan/plan-records.examples.js.map +1 -1
- package/dist/test/plan/plan-windows.examples.d.ts +636 -55
- package/dist/test/plan/plan-windows.examples.d.ts.map +1 -1
- package/dist/test/plan/plan-windows.examples.js +69 -33
- package/dist/test/plan/plan-windows.examples.js.map +1 -1
- package/dist/test/plan/plan.examples.d.ts +153 -31
- package/dist/test/plan/plan.examples.d.ts.map +1 -1
- package/dist/test/plan/plan.examples.js +178 -101
- package/dist/test/plan/plan.examples.js.map +1 -1
- package/dist/test/roster/domain.examples.d.ts +467 -250
- package/dist/test/roster/domain.examples.d.ts.map +1 -1
- package/dist/test/roster/domain.examples.js +92 -29
- package/dist/test/roster/domain.examples.js.map +1 -1
- package/dist/test/roster/roster-records.examples.d.ts +430 -586
- package/dist/test/roster/roster-records.examples.d.ts.map +1 -1
- package/dist/test/roster/roster-records.examples.js +102 -43
- package/dist/test/roster/roster-records.examples.js.map +1 -1
- package/dist/test/roster/roster.examples.d.ts +2319 -606
- package/dist/test/roster/roster.examples.d.ts.map +1 -1
- package/dist/test/roster/roster.examples.js +456 -148
- package/dist/test/roster/roster.examples.js.map +1 -1
- package/dist/test/roster/warehouse.d.ts +172 -63
- package/dist/test/roster/warehouse.d.ts.map +1 -1
- package/dist/test/roster/warehouse.js +172 -39
- package/dist/test/roster/warehouse.js.map +1 -1
- package/dist/test/schedule/schedule.examples.d.ts +3499 -0
- package/dist/test/schedule/schedule.examples.d.ts.map +1 -0
- package/dist/test/schedule/schedule.examples.js +192 -0
- package/dist/test/schedule/schedule.examples.js.map +1 -0
- package/dist/test/sheet/sheet-records.examples.d.ts.map +1 -1
- package/dist/test/sheet/sheet-records.examples.js +22 -18
- package/dist/test/sheet/sheet-records.examples.js.map +1 -1
- package/dist/test/sheet/sheet.examples.d.ts +715 -26
- package/dist/test/sheet/sheet.examples.d.ts.map +1 -1
- package/dist/test/sheet/sheet.examples.js +204 -130
- package/dist/test/sheet/sheet.examples.js.map +1 -1
- package/package.json +17 -10
- package/dist/src/roster/people.d.ts +0 -50
- package/dist/src/roster/people.d.ts.map +0 -1
- package/dist/src/roster/people.js +0 -32
- package/dist/src/roster/people.js.map +0 -1
- package/dist/src/roster/visibility.d.ts.map +0 -1
- package/dist/src/roster/visibility.js +0 -25
- package/dist/src/roster/visibility.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plan-events.examples.d.ts","sourceRoot":"","sources":["../../../test/plan/plan-events.examples.tsx"],"names":[],"mappings":"AAAA;;;GAGG;AACH,sCAAsC;AAEtC,OAAO,EACH,SAAS,EACT,YAAY,EACZ,QAAQ,EAER,SAAS,EAET,QAAQ,EACR,UAAU,
|
|
1
|
+
{"version":3,"file":"plan-events.examples.d.ts","sourceRoot":"","sources":["../../../test/plan/plan-events.examples.tsx"],"names":[],"mappings":"AAAA;;;GAGG;AACH,sCAAsC;AAEtC,OAAO,EACH,SAAS,EACT,YAAY,EACZ,QAAQ,EAER,SAAS,EAET,WAAW,EACX,QAAQ,EACR,UAAU,EAEV,UAAU,EACV,UAAU,EACV,WAAW,EAIX,OAAO,EACV,MAAM,eAAe,CAAC;AAyBvB,oEAAoE;AACpE,eAAO,MAAM,UAAU;;;;EAAiF,CAAC;AAEzG,qCAAqC;AACrC,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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAyCG;AACH,eAAO,MAAM,cAAc,6CAkGzB,CAAC"}
|
|
@@ -4,7 +4,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "@elaraai/e3-ui/jsx-runtime";
|
|
|
4
4
|
* Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
|
|
5
5
|
*/
|
|
6
6
|
/** @jsxImportSource @elaraai/e3-ui */
|
|
7
|
-
import { ArrayType, DateTimeType, DictType, East, FloatType, FunctionType, NullType, OptionType, StringType, StructType, VariantType, example, none, some, variant, } from "@elaraai/east";
|
|
7
|
+
import { ArrayType, DateTimeType, DictType, East, FloatType, FunctionType, IntegerType, NullType, OptionType, PatchType, StringType, StructType, VariantType, example, none, some, variant, } from "@elaraai/east";
|
|
8
8
|
import { Chart, EventStateType, Format, Reactive, SegmentGroup, Slice, Text, UIComponentType, VStack } from "@elaraai/east-ui";
|
|
9
9
|
import { Data, Plan, Record, Schedule } from "@elaraai/e3-ui";
|
|
10
10
|
import e3 from "@elaraai/e3";
|
|
@@ -16,8 +16,10 @@ import e3 from "@elaraai/e3";
|
|
|
16
16
|
// presses in two halls and four crews; thirty print jobs over four weeks from
|
|
17
17
|
// Monday 5 October 2026, eight of them waiting in the backlog; plate changes
|
|
18
18
|
// and services; early and late shifts; each press's utilisation and the sheets
|
|
19
|
-
// printed each day; templates for every kind
|
|
20
|
-
//
|
|
19
|
+
// printed each day; templates for every kind, each a record of its own
|
|
20
|
+
// (#1344); and the customers its library lists (#1195). Its one rail narrows
|
|
21
|
+
// the jobs, the shifts, the presses, the customers and each templates record,
|
|
22
|
+
// a source apiece. The smallest builder reads the presses and the customers
|
|
21
23
|
// beside a jobs record of its own. A measure is stored as its readings from
|
|
22
24
|
// the window's first day, which the series turn into cells and points, as the
|
|
23
25
|
// Plan's other examples store theirs.
|
|
@@ -64,6 +66,8 @@ export const planPrintPresses = e3.record("plan_print_presses", DictType(StringT
|
|
|
64
66
|
["b2", { name: "Press B2", hall: "Hall B", sheets_per_hour: 12000.0 }],
|
|
65
67
|
["b3", { name: "Press B3", hall: "Hall B", sheets_per_hour: 6000.0 }],
|
|
66
68
|
]));
|
|
69
|
+
/** The presses' patch door: the works edits its presses elsewhere, and a Plan reads them live. */
|
|
70
|
+
export const planPrintPressesPatch = e3.mutation.patch(planPrintPresses);
|
|
67
71
|
/** The crews: two in each hall. */
|
|
68
72
|
export const planPrintCrews = e3.record("plan_print_crews", DictType(StringType, PrintCrew), new Map([
|
|
69
73
|
["c1", { name: "Crew 1", hall: "Hall A" }],
|
|
@@ -151,6 +155,23 @@ export const planPrintShifts = e3.record("plan_print_shifts", DictType(StringTyp
|
|
|
151
155
|
]));
|
|
152
156
|
/** The shifts' patch door. */
|
|
153
157
|
export const planPrintShiftsPatch = e3.mutation.patch(planPrintShifts);
|
|
158
|
+
/** A crew roster the works has locked for the week: Crew 1's two early shifts. */
|
|
159
|
+
export const planLockedShifts = e3.record("plan_locked_shifts", DictType(StringType, PrintShift), new Map([
|
|
160
|
+
["SH-01", { title: "Early", start: new Date("2026-10-05T06:00:00Z"), end: new Date("2026-10-05T14:00:00Z"), crew: "c1", state: variant("confirmed", null) }],
|
|
161
|
+
["SH-02", { title: "Early", start: new Date("2026-10-07T06:00:00Z"), end: new Date("2026-10-07T14:00:00Z"), crew: "c1", state: variant("confirmed", null) }],
|
|
162
|
+
]));
|
|
163
|
+
/**
|
|
164
|
+
* The locked roster's patch door, a checked one: it takes any change to a
|
|
165
|
+
* shift, and refuses one that takes a shift off the roster, naming why — what
|
|
166
|
+
* a Save that deletes one is answered.
|
|
167
|
+
*/
|
|
168
|
+
export const planLockedShiftsPatch = e3.mutation.reduce("patch", planLockedShifts, East.function([DictType(StringType, PrintShift), PatchType(DictType(StringType, PrintShift))], DictType(StringType, PrintShift), ($, roster, patch) => {
|
|
169
|
+
const next = $.let(East.applyPatch(roster, patch));
|
|
170
|
+
$.for(roster, ($2, _shift, key) => {
|
|
171
|
+
$2.if(next.has(key).not(), ($3) => { $3.error("the crew roster is locked for the week"); });
|
|
172
|
+
});
|
|
173
|
+
return next;
|
|
174
|
+
}));
|
|
154
175
|
/** The customers the jobs are printed for, by account, in three districts: what the print works' library lists. A Plan never writes them. */
|
|
155
176
|
export const planPrintCustomers = e3.record("plan_print_customers", DictType(StringType, PrintCustomer), new Map([
|
|
156
177
|
["alder-finch", { name: "Alder & Finch", district: "Old Town", trade: "Retail" }],
|
|
@@ -170,6 +191,8 @@ export const planPrintCustomers = e3.record("plan_print_customers", DictType(Str
|
|
|
170
191
|
["northwind", { name: "Northwind Outfitters", district: "North Quay", trade: "Retail" }],
|
|
171
192
|
["orchard-market", { name: "Orchard Street Market", district: "Old Town", trade: "Markets" }],
|
|
172
193
|
]));
|
|
194
|
+
/** The customers' patch door: the works edits its customers elsewhere, and a Plan reads them live. */
|
|
195
|
+
export const planPrintCustomersPatch = e3.mutation.patch(planPrintCustomers);
|
|
173
196
|
/**
|
|
174
197
|
* Each press's utilisation (%): a reading a day from 5 October, as the
|
|
175
198
|
* dataflow measures it, idle at the weekends. Press B2's 97 on the 20th is
|
|
@@ -371,6 +394,35 @@ export const planLinkDeliveries = e3.record("plan_link_deliveries", DictType(Str
|
|
|
371
394
|
/** The deliveries' patch door. */
|
|
372
395
|
export const planLinkDeliveriesPatch = e3.mutation.patch(planLinkDeliveries);
|
|
373
396
|
// ============================================================================
|
|
397
|
+
// Jobs of the Plan's specs' own: a kind in lanes, and a resource by its case
|
|
398
|
+
// ============================================================================
|
|
399
|
+
/** A job in a lane, with a status: one record the Plan's specs draw as tiles, as bars and as marks. */
|
|
400
|
+
export const PrintLaneJob = StructType({
|
|
401
|
+
title: StringType,
|
|
402
|
+
start: DateTimeType,
|
|
403
|
+
end: DateTimeType,
|
|
404
|
+
press: OptionType(StringType),
|
|
405
|
+
lane: StringType,
|
|
406
|
+
status: VariantType({ fine: NullType, late: NullType }),
|
|
407
|
+
});
|
|
408
|
+
/** Three lane jobs in the first week: two on Press A1 in its AM and PM lanes, one late; one late on Press A2. */
|
|
409
|
+
export const planRowsLaneJobs = e3.record("plan_rows_lane_jobs", DictType(StringType, PrintLaneJob), new Map([
|
|
410
|
+
["L-1", { title: "Proofs", start: new Date("2026-10-06T06:00:00Z"), end: new Date("2026-10-06T08:00:00Z"), press: some("a1"), lane: "pm", status: variant("fine", null) }],
|
|
411
|
+
["L-2", { title: "Plates", start: new Date("2026-10-06T09:00:00Z"), end: new Date("2026-10-06T10:00:00Z"), press: some("a1"), lane: "am", status: variant("late", null) }],
|
|
412
|
+
["L-3", { title: "Wash-up", start: new Date("2026-10-07T06:00:00Z"), end: new Date("2026-10-07T07:00:00Z"), press: some("a2"), lane: "am", status: variant("late", null) }],
|
|
413
|
+
]));
|
|
414
|
+
/** The lane jobs' patch door. */
|
|
415
|
+
export const planRowsLaneJobsPatch = e3.mutation.patch(planRowsLaneJobs);
|
|
416
|
+
/** A job on a press or in a bay — a resource field whose case names the kind. */
|
|
417
|
+
export const PrintOnJob = StructType({ title: StringType, start: DateTimeType, end: DateTimeType, on: VariantType({ press: StringType, bay: StringType }) });
|
|
418
|
+
/** One job on Press A1, and one in Bay A1: two kinds of resource with the same key. */
|
|
419
|
+
export const planRowsOnJobs = e3.record("plan_rows_on_jobs", DictType(StringType, PrintOnJob), new Map([
|
|
420
|
+
["O-1", { title: "On the press", start: new Date("2026-10-06T06:00:00Z"), end: new Date("2026-10-06T08:00:00Z"), on: variant("press", "a1") }],
|
|
421
|
+
["O-2", { title: "In the bay", start: new Date("2026-10-06T09:00:00Z"), end: new Date("2026-10-06T10:00:00Z"), on: variant("bay", "a1") }],
|
|
422
|
+
]));
|
|
423
|
+
/** The press-or-bay jobs' patch door. */
|
|
424
|
+
export const planRowsOnJobsPatch = e3.mutation.patch(planRowsOnJobs);
|
|
425
|
+
// ============================================================================
|
|
374
426
|
// The print works' finishing and dispatch records (#1200)
|
|
375
427
|
// ============================================================================
|
|
376
428
|
/** The parent of the shared folder and binder, held in a record like every other resource. */
|
|
@@ -413,6 +465,71 @@ export const planPrintDeliveries = e3.record("plan_print_deliveries", DictType(S
|
|
|
413
465
|
/** The print works' deliveries commit through their own patch door. */
|
|
414
466
|
export const planPrintDeliveriesPatch = e3.mutation.patch(planPrintDeliveries);
|
|
415
467
|
// ============================================================================
|
|
468
|
+
// The print works' templates, each a record of its own (#1344)
|
|
469
|
+
// ============================================================================
|
|
470
|
+
/** A job template: its name and group, how long the job it creates runs, and that job's fields. */
|
|
471
|
+
export const PrintJobTemplate = StructType({
|
|
472
|
+
name: StringType, group: StringType, hours: FloatType,
|
|
473
|
+
values: StructType({ title: StringType, state: EventStateType, sheets: FloatType, customer: StringType, stock: PrintJob.fields.stock, due: OptionType(DateTimeType) }),
|
|
474
|
+
});
|
|
475
|
+
/** A stop template: a stop is one instant, so it runs no time. */
|
|
476
|
+
export const PrintStopTemplate = StructType({ name: StringType, group: StringType, values: StructType({ title: StringType, kind: PrintStop.fields.kind }) });
|
|
477
|
+
/** A shift template: the hour a shift dropped on a day starts at, eight hours long. */
|
|
478
|
+
export const PrintShiftTemplate = StructType({ name: StringType, group: StringType, hour: IntegerType, values: StructType({ title: StringType, state: EventStateType }) });
|
|
479
|
+
/** A plates template: plates are made at one instant. */
|
|
480
|
+
export const PrintPlatesTemplate = StructType({ name: StringType, group: StringType, values: StructType({ title: StringType }) });
|
|
481
|
+
/** A bindery template: how long the bindery job it creates runs. */
|
|
482
|
+
export const PrintBindingTemplate = StructType({ name: StringType, group: StringType, hours: FloatType, values: StructType({ title: StringType, state: EventStateType }) });
|
|
483
|
+
/** A delivery template: the hour a delivery dropped on a day leaves at. */
|
|
484
|
+
export const PrintDeliveryTemplate = StructType({
|
|
485
|
+
name: StringType, group: StringType, hour: IntegerType,
|
|
486
|
+
values: StructType({ title: StringType, lane: StringType, status: PrintDispatchStatus, pallets: FloatType }),
|
|
487
|
+
});
|
|
488
|
+
/** The job templates. A Plan never writes them: the library lists them, and a drop creates a job from one. */
|
|
489
|
+
export const planPrintJobTemplates = e3.record("plan_print_job_templates", DictType(StringType, PrintJobTemplate), new Map([
|
|
490
|
+
["board", { name: "Board run", group: "Jobs", hours: 8.0, values: { title: "Board run", state: variant("proposed", variant("added", null)), sheets: 24000.0, customer: "", stock: variant("board", null), due: none } }],
|
|
491
|
+
["brochure", { name: "Brochure run", group: "Jobs", hours: 6.0, values: { title: "Brochure run", state: variant("proposed", variant("added", null)), sheets: 40000.0, customer: "", stock: variant("coated", null), due: none } }],
|
|
492
|
+
["catalogue", { name: "Catalogue run", group: "Jobs", hours: 12.0, values: { title: "Catalogue run", state: variant("proposed", variant("added", null)), sheets: 96000.0, customer: "", stock: variant("coated", null), due: none } }],
|
|
493
|
+
["poster", { name: "Poster run", group: "Jobs", hours: 4.0, values: { title: "Poster run", state: variant("proposed", variant("added", null)), sheets: 20000.0, customer: "", stock: variant("uncoated", null), due: none } }],
|
|
494
|
+
]));
|
|
495
|
+
/** The stop templates. */
|
|
496
|
+
export const planPrintStopTemplates = e3.record("plan_print_stop_templates", DictType(StringType, PrintStopTemplate), new Map([
|
|
497
|
+
["plates", { name: "Plate change", group: "Stops", values: { title: "Plate change", kind: variant("plate_change", null) } }],
|
|
498
|
+
["service", { name: "Service", group: "Stops", values: { title: "Service", kind: variant("service", null) } }],
|
|
499
|
+
]));
|
|
500
|
+
/** The shift templates: early, late and night. */
|
|
501
|
+
export const planPrintShiftTemplates = e3.record("plan_print_shift_templates", DictType(StringType, PrintShiftTemplate), new Map([
|
|
502
|
+
["early", { name: "Early shift", group: "Shifts", hour: 6n, values: { title: "Early", state: variant("confirmed", null) } }],
|
|
503
|
+
["late", { name: "Late shift", group: "Shifts", hour: 14n, values: { title: "Late", state: variant("confirmed", null) } }],
|
|
504
|
+
["night", { name: "Night shift", group: "Shifts", hour: 22n, values: { title: "Night", state: variant("proposed", variant("added", null)) } }],
|
|
505
|
+
]));
|
|
506
|
+
/** The plates templates. */
|
|
507
|
+
export const planPrintPlatesTemplates = e3.record("plan_print_plates_templates", DictType(StringType, PrintPlatesTemplate), new Map([
|
|
508
|
+
["plates", { name: "Job plates", group: "Plate room", values: { title: "Job plates" } }],
|
|
509
|
+
]));
|
|
510
|
+
/** The bindery templates. */
|
|
511
|
+
export const planPrintBindingTemplates = e3.record("plan_print_binding_templates", DictType(StringType, PrintBindingTemplate), new Map([
|
|
512
|
+
["fold", { name: "Fold sections", group: "Bindery", hours: 8.0, values: { title: "Fold sections", state: variant("confirmed", null) } }],
|
|
513
|
+
]));
|
|
514
|
+
/** The delivery templates. */
|
|
515
|
+
export const planPrintDeliveryTemplates = e3.record("plan_print_delivery_templates", DictType(StringType, PrintDeliveryTemplate), new Map([
|
|
516
|
+
["delivery", { name: "Morning delivery", group: "Dispatch", hour: 10n, values: { title: "Delivery", lane: "AM", status: variant("queued", null), pallets: 1.0 } }],
|
|
517
|
+
]));
|
|
518
|
+
// The rail narrows each record through its own indexes (#1344): the jobs and the shifts over their interval
|
|
519
|
+
// indexes — on their own, and after a job's stock — so a narrowing keeps every event overlapping the window once;
|
|
520
|
+
// the presses by hall, the customers by district, and each templates record by its group.
|
|
521
|
+
export const planPrintJobsByTime = e3.recordIndex("plan_print_jobs_by_time", planPrintJobs, { interval: { from: "start", to: "end" } });
|
|
522
|
+
export const planPrintJobsByStockTime = e3.recordIndex("plan_print_jobs_by_stock_time", planPrintJobs, { on: ["stock"], interval: { from: "start", to: "end" } });
|
|
523
|
+
export const planPrintShiftsByTime = e3.recordIndex("plan_print_shifts_by_time", planPrintShifts, { interval: { from: "start", to: "end" } });
|
|
524
|
+
export const planPrintPressesByHall = e3.recordIndex("plan_print_presses_by_hall", planPrintPresses, { on: ["hall"] });
|
|
525
|
+
export const planPrintCustomersByDistrict = e3.recordIndex("plan_print_customers_by_district", planPrintCustomers, { on: ["district"] });
|
|
526
|
+
export const planPrintJobTemplatesByGroup = e3.recordIndex("plan_print_job_templates_by_group", planPrintJobTemplates, { on: ["group"] });
|
|
527
|
+
export const planPrintStopTemplatesByGroup = e3.recordIndex("plan_print_stop_templates_by_group", planPrintStopTemplates, { on: ["group"] });
|
|
528
|
+
export const planPrintShiftTemplatesByGroup = e3.recordIndex("plan_print_shift_templates_by_group", planPrintShiftTemplates, { on: ["group"] });
|
|
529
|
+
export const planPrintPlatesTemplatesByGroup = e3.recordIndex("plan_print_plates_templates_by_group", planPrintPlatesTemplates, { on: ["group"] });
|
|
530
|
+
export const planPrintBindingTemplatesByGroup = e3.recordIndex("plan_print_binding_templates_by_group", planPrintBindingTemplates, { on: ["group"] });
|
|
531
|
+
export const planPrintDeliveryTemplatesByGroup = e3.recordIndex("plan_print_delivery_templates_by_group", planPrintDeliveryTemplates, { on: ["group"] });
|
|
532
|
+
// ============================================================================
|
|
416
533
|
// planPrintWorks — the print works (§3.3)
|
|
417
534
|
// ============================================================================
|
|
418
535
|
/**
|
|
@@ -421,15 +538,24 @@ export const planPrintDeliveriesPatch = e3.mutation.patch(planPrintDeliveries);
|
|
|
421
538
|
* draw as bars, stops and plates as marks
|
|
422
539
|
* at their instants, shifts as chips — a utilisation heat row under each
|
|
423
540
|
* press, and a pinned chart of the sheets printed each day. Each
|
|
424
|
-
* kind
|
|
425
|
-
* templates, the backlog, the series a viewer shows and hides, and the
|
|
541
|
+
* kind's templates are a record of its own. Its library (#1195) lists every
|
|
542
|
+
* kind's templates, the backlog, the series a viewer shows and hides, and the
|
|
426
543
|
* customers, a card apiece that sets the customer of the job it is dropped
|
|
427
544
|
* on. Its inspector (#1197) shows what is selected: a job through the form
|
|
428
545
|
* its customer, stock and sheets are hinted for, and a stop through the
|
|
429
546
|
* stop kind's own inspector, which chooses a plate change or a service on a
|
|
430
|
-
* segment.
|
|
431
|
-
*
|
|
432
|
-
*
|
|
547
|
+
* segment. One rail narrows it (`Slice.bindRecords`, #1344): the jobs and the
|
|
548
|
+
* shifts each through their interval index, every event overlapping the
|
|
549
|
+
* window once, the jobs by their stock too, their backlog with them; the
|
|
550
|
+
* presses by hall, on the canvas and in the Choosers; the customers by
|
|
551
|
+
* district, in their tab; and each templates record, in the Events tab. Its
|
|
552
|
+
* summary names each source a narrowing hides rows of, in its own words, and
|
|
553
|
+
* folded, its Filters popover heads each source's fields with its count
|
|
554
|
+
* (#1358). The window is the jobs' and the shifts' range together: the
|
|
555
|
+
* toolbar's dates, the resolution and the horizon brush write both. Links
|
|
556
|
+
* connect the plates,
|
|
557
|
+
* printing, binding and dispatch. Delivery readiness holds Save for an
|
|
558
|
+
* invalid pallet count, while the drop veto explains a press in service.
|
|
433
559
|
*/
|
|
434
560
|
export const planPrintWorks = example({
|
|
435
561
|
keywords: [
|
|
@@ -440,16 +566,54 @@ export const planPrintWorks = example({
|
|
|
440
566
|
"Plan.library", "customers", "Schedule.patch", "inspector", "selection", "kind's own inspector", "update",
|
|
441
567
|
"Record.bind", "Data.bind", "e3.record", "e3.input", "#1191", "#1195", "#1197", "#1200", "parent", "rollup", "collapsed", "meta", "value",
|
|
442
568
|
"buckets", "lane", "status", "ready", "overlaps", "allow", "canDrop", "Schedule.Types.Candidate",
|
|
443
|
-
"variant resource", "bay", "van", "Slice", "
|
|
569
|
+
"variant resource", "bay", "van", "Slice", "Slice.bindRecords", "sources", "Data.bindPaged", "recordIndex", "interval",
|
|
570
|
+
"window", "range", "brush", "resolution", "Schedule.templates", "templates record", "Plan.eventRef", "Plan.over", "#1344",
|
|
444
571
|
],
|
|
445
|
-
description: "The print works from plates to dispatch — jobs, stops and shifts on grouped presses and crews, nested bindery resources, deliveries in AM/PM lanes on a bay or a van, status and readiness, links between event kinds, utilisation and paper stock
|
|
572
|
+
description: "The print works from plates to dispatch — jobs, stops and shifts on grouped presses and crews, nested bindery resources, deliveries in AM/PM lanes on a bay or a van, status and readiness, links between event kinds, utilisation and paper stock; one Slice.bindRecords rail — the jobs and the shifts through their interval indexes, their range the one window, the presses, the customers and each kind's templates record — and the shared library, inspector and Save session",
|
|
446
573
|
fn: East.function([], UIComponentType, (_$) => (_jsx(Reactive, { children: $ => {
|
|
447
|
-
|
|
574
|
+
// What the Plan reads whole binds with Data.bind, which keeps it loaded beside its pages; the event
|
|
575
|
+
// records it writes bind with Record.bind, and it reads the jobs' and the shifts' events through their
|
|
576
|
+
// pages alone.
|
|
577
|
+
const presses = $.let(Data.bind(planPrintPresses));
|
|
448
578
|
const crews = $.let(Record.bind(planPrintCrews, []));
|
|
449
579
|
const jobs = $.let(Record.bind(planPrintJobs, [planPrintJobsPatch]));
|
|
450
580
|
const stops = $.let(Record.bind(planPrintStops, [planPrintStopsPatch]));
|
|
451
581
|
const shifts = $.let(Record.bind(planPrintShifts, [planPrintShiftsPatch]));
|
|
452
|
-
const customers = $.let(
|
|
582
|
+
const customers = $.let(Data.bind(planPrintCustomers));
|
|
583
|
+
const jobTemplates = $.let(Data.bind(planPrintJobTemplates));
|
|
584
|
+
const stopTemplates = $.let(Data.bind(planPrintStopTemplates));
|
|
585
|
+
const shiftTemplates = $.let(Data.bind(planPrintShiftTemplates));
|
|
586
|
+
const platesTemplates = $.let(Data.bind(planPrintPlatesTemplates));
|
|
587
|
+
const bindingTemplates = $.let(Data.bind(planPrintBindingTemplates));
|
|
588
|
+
const deliveryTemplates = $.let(Data.bind(planPrintDeliveryTemplates));
|
|
589
|
+
// One rail over the records, a source each (#1344): the jobs and the shifts through their interval
|
|
590
|
+
// indexes, their range the one window the toolbar's dates, the resolution and the brush write; the
|
|
591
|
+
// presses, the customers and each templates record by its fields.
|
|
592
|
+
const slice = $.let(Slice.bindRecords("ex.planPrintWorks", {
|
|
593
|
+
job: { source: Data.bindPaged(planPrintJobs, { indexes: [planPrintJobsByTime, planPrintJobsByStockTime] }), icon: { prefix: "fas", name: "file-lines" },
|
|
594
|
+
fields: { stock: { label: "Stock" }, start: { label: "Dates" } }, range: "start" },
|
|
595
|
+
shift: { source: Data.bindPaged(planPrintShifts, { indexes: [planPrintShiftsByTime] }), icon: { prefix: "fas", name: "user-clock" },
|
|
596
|
+
fields: { start: { label: "Dates" } }, range: "start" },
|
|
597
|
+
presses: { source: Data.bindPaged(planPrintPresses, { indexes: [planPrintPressesByHall] }), icon: { prefix: "fas", name: "print" },
|
|
598
|
+
fields: { hall: { label: "Hall", hints: ["Hall A", "Hall B"] } } },
|
|
599
|
+
customers: { source: Data.bindPaged(planPrintCustomers, { indexes: [planPrintCustomersByDistrict] }), icon: { prefix: "fas", name: "building" },
|
|
600
|
+
fields: { district: { label: "District", hints: ["North Quay", "Old Town", "Riverside"] } } },
|
|
601
|
+
jobTemplates: { source: Data.bindPaged(planPrintJobTemplates, { indexes: [planPrintJobTemplatesByGroup] }), icon: { prefix: "fas", name: "layer-group" },
|
|
602
|
+
fields: { group: { label: "Job templates", hints: ["Jobs"] } } },
|
|
603
|
+
stopTemplates: { source: Data.bindPaged(planPrintStopTemplates, { indexes: [planPrintStopTemplatesByGroup] }), icon: { prefix: "fas", name: "layer-group" },
|
|
604
|
+
fields: { group: { label: "Stop templates", hints: ["Stops"] } } },
|
|
605
|
+
shiftTemplates: { source: Data.bindPaged(planPrintShiftTemplates, { indexes: [planPrintShiftTemplatesByGroup] }), icon: { prefix: "fas", name: "layer-group" },
|
|
606
|
+
fields: { group: { label: "Shift templates", hints: ["Shifts"] } } },
|
|
607
|
+
platesTemplates: { source: Data.bindPaged(planPrintPlatesTemplates, { indexes: [planPrintPlatesTemplatesByGroup] }), icon: { prefix: "fas", name: "layer-group" },
|
|
608
|
+
fields: { group: { label: "Plates templates", hints: ["Plate room"] } } },
|
|
609
|
+
bindingTemplates: { source: Data.bindPaged(planPrintBindingTemplates, { indexes: [planPrintBindingTemplatesByGroup] }), icon: { prefix: "fas", name: "layer-group" },
|
|
610
|
+
fields: { group: { label: "Bindery templates", hints: ["Bindery"] } } },
|
|
611
|
+
deliveryTemplates: { source: Data.bindPaged(planPrintDeliveryTemplates, { indexes: [planPrintDeliveryTemplatesByGroup] }), icon: { prefix: "fas", name: "layer-group" },
|
|
612
|
+
fields: { group: { label: "Delivery templates", hints: ["Dispatch"] } } },
|
|
613
|
+
}));
|
|
614
|
+
// A kind narrowed through its source reads one event by its key through the record's own entries.
|
|
615
|
+
const jobEntries = $.let(Data.bindPaged(planPrintJobs));
|
|
616
|
+
const shiftEntries = $.let(Data.bindPaged(planPrintShifts));
|
|
453
617
|
const setters = $.let(Record.bind(planLinkSetters, []));
|
|
454
618
|
const lines = $.let(Record.bind(planLinkLines, []));
|
|
455
619
|
const bindery = $.let(Record.bind(planPrintBindery, []));
|
|
@@ -466,17 +630,6 @@ export const planPrintWorks = example({
|
|
|
466
630
|
const first = $.const(new Date("2026-10-05T00:00:00Z"), DateTimeType);
|
|
467
631
|
const parentLine = $.const(some("bindery"), OptionType(StringType));
|
|
468
632
|
const topLine = $.const(none, OptionType(StringType));
|
|
469
|
-
// The Slice's domain is the scheduled jobs. It owns the visible time window;
|
|
470
|
-
// Schedule reads every event kind over that window and keeps the backlog separate.
|
|
471
|
-
const scope = $.const(jobs.read().toArray((_$2, job) => job.start)
|
|
472
|
-
.filter((_$2, at) => at.hasTag("some"))
|
|
473
|
-
.map((_$2, at) => ({ at: at.unwrap("some") })));
|
|
474
|
-
const slice = $.let(Slice.bind("ex.planPrintWorks.time", scope, {
|
|
475
|
-
fields: { at: { label: "Job start", format: { date: "MMM DD" } } },
|
|
476
|
-
range: "at",
|
|
477
|
-
initial: { at: { from: first, to: new Date("2026-11-02T00:00:00Z") } },
|
|
478
|
-
view: { resolution: some(variant("day", null)) },
|
|
479
|
-
}));
|
|
480
633
|
// A press's readings as heat cells, one a day.
|
|
481
634
|
const daily = $.const(East.function([ArrayType(FloatType)], ArrayType(Plan.Types.HeatCell), (_$2, readings) => East.Array.generate(readings.size(), Plan.Types.HeatCell, (_$3, i) => ({
|
|
482
635
|
at: Plan.at.time(first.addDays(i)), value: some(readings.get(i)), label: none,
|
|
@@ -511,7 +664,7 @@ export const planPrintWorks = example({
|
|
|
511
664
|
}));
|
|
512
665
|
return (_jsxs(VStack, { gap: "3", align: "stretch", children: [_jsx(Text, { children: stop.title }), _jsx(SegmentGroup, { value: stop.kind.getTag(), onChange: setKind, size: "sm", items: [SegmentGroup.Item("plate_change", "Plate change"), SegmentGroup.Item("service", "Service")] })] }));
|
|
513
666
|
}));
|
|
514
|
-
return (_jsx(Plan, { id: "printWorks", axis: axis, date: first, canDrop: canDrop, slice: { slice
|
|
667
|
+
return (_jsx(Plan, { id: "printWorks", axis: axis, date: first, canDrop: canDrop, slice: { slice }, resources: {
|
|
515
668
|
presses: Schedule.resources(presses.read(), {
|
|
516
669
|
name: "Presses", icon: "print",
|
|
517
670
|
label: p => p.name, group: p => p.hall,
|
|
@@ -548,55 +701,40 @@ export const planPrintWorks = example({
|
|
|
548
701
|
stock: Schedule.field.select({ labels: { coated: "Coated", uncoated: "Uncoated", board: "Board" } }),
|
|
549
702
|
sheets: Schedule.field.number({ label: "Sheets", step: 1000.0, min: 0.0 }),
|
|
550
703
|
},
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
values: { title: "Catalogue run", state: variant("proposed", variant("added", null)), sheets: 96000.0,
|
|
557
|
-
customer: "", stock: variant("coated", null), due: none } },
|
|
558
|
-
{ key: "poster", name: "Poster run", group: "Jobs", duration: variant("hours", 4.0),
|
|
559
|
-
values: { title: "Poster run", state: variant("proposed", variant("added", null)), sheets: 20000.0,
|
|
560
|
-
customer: "", stock: variant("uncoated", null), due: none } },
|
|
561
|
-
{ key: "board", name: "Board run", group: "Jobs", duration: variant("hours", 8.0),
|
|
562
|
-
values: { title: "Board run", state: variant("proposed", variant("added", null)), sheets: 24000.0,
|
|
563
|
-
customer: "", stock: variant("board", null), due: none } },
|
|
564
|
-
],
|
|
704
|
+
// Narrowed through its source of the slice (`job`): one job is read by its key here.
|
|
705
|
+
entries: jobEntries,
|
|
706
|
+
templates: Schedule.templates(jobTemplates.read(), {
|
|
707
|
+
name: t => t.name, group: t => some(t.group), duration: t => variant("hours", t.hours), values: t => t.values, source: "jobTemplates",
|
|
708
|
+
}),
|
|
565
709
|
}),
|
|
566
710
|
stop: Schedule.events(stops, {
|
|
567
711
|
name: "Stop", icon: "screwdriver-wrench", draw: "marks",
|
|
568
712
|
title: "title", at: "at",
|
|
569
713
|
resource: { field: "press", of: "presses" },
|
|
570
714
|
inspector: inspectStop,
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
values: { title: "Plate change", kind: variant("plate_change", null) } },
|
|
574
|
-
{ key: "service", name: "Service", group: "Stops",
|
|
575
|
-
values: { title: "Service", kind: variant("service", null) } },
|
|
576
|
-
],
|
|
715
|
+
// A stop is one instant: its templates give no duration.
|
|
716
|
+
templates: Schedule.templates(stopTemplates.read(), { name: t => t.name, group: t => some(t.group), values: t => t.values, source: "stopTemplates" }),
|
|
577
717
|
}),
|
|
578
718
|
shift: Schedule.events(shifts, {
|
|
579
719
|
name: "Crew shift", icon: "user-clock", draw: "cards",
|
|
580
720
|
title: "title", start: "start", end: "end",
|
|
581
721
|
resource: { field: "crew", of: "crews" }, state: "state",
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
{ key: "night", name: "Night shift", group: "Shifts", at: { hour: 22n, minute: 0n }, duration: variant("hours", 8.0),
|
|
588
|
-
values: { title: "Night", state: variant("proposed", variant("added", null)) } },
|
|
589
|
-
],
|
|
722
|
+
entries: shiftEntries,
|
|
723
|
+
templates: Schedule.templates(shiftTemplates.read(), {
|
|
724
|
+
name: t => t.name, group: t => some(t.group), at: t => some({ hour: t.hour, minute: 0n }), duration: () => variant("hours", 8.0),
|
|
725
|
+
values: t => t.values, source: "shiftTemplates",
|
|
726
|
+
}),
|
|
590
727
|
}),
|
|
591
728
|
plate: Schedule.events(plates, {
|
|
592
729
|
name: "Plates", icon: "clone", title: "title", at: "at", resource: { field: "setter", of: "setters" },
|
|
593
|
-
templates:
|
|
730
|
+
templates: Schedule.templates(platesTemplates.read(), { name: t => t.name, group: t => some(t.group), values: t => t.values, source: "platesTemplates" }),
|
|
594
731
|
}),
|
|
595
732
|
binding: Schedule.events(bindings, {
|
|
596
733
|
name: "Bindery job", icon: "book-open", draw: "cards", title: "title", start: "start", end: "end",
|
|
597
734
|
resource: { field: "line", of: "lines" }, state: "state", overlaps: "allow",
|
|
598
|
-
templates:
|
|
599
|
-
|
|
735
|
+
templates: Schedule.templates(bindingTemplates.read(), {
|
|
736
|
+
name: t => t.name, group: t => some(t.group), duration: t => variant("hours", t.hours), values: t => t.values, source: "bindingTemplates",
|
|
737
|
+
}),
|
|
600
738
|
}),
|
|
601
739
|
delivery: Schedule.events(deliveries, {
|
|
602
740
|
name: "Delivery", icon: "truck", draw: "buckets", title: "title", at: "at",
|
|
@@ -608,8 +746,9 @@ export const planPrintWorks = example({
|
|
|
608
746
|
} },
|
|
609
747
|
ready: d => d.pallets.lessEqual(0.0).ifElse(() => variant("invalid", [{ field: "pallets", message: "Pallets must be positive" }]), () => variant("ready", null)),
|
|
610
748
|
fields: { pallets: Schedule.field.number({ label: "Pallets", min: 0.0, step: 1.0 }) },
|
|
611
|
-
templates:
|
|
612
|
-
|
|
749
|
+
templates: Schedule.templates(deliveryTemplates.read(), {
|
|
750
|
+
name: t => t.name, group: t => some(t.group), at: t => some({ hour: t.hour, minute: 0n }), values: t => t.values, source: "deliveryTemplates",
|
|
751
|
+
}),
|
|
613
752
|
}),
|
|
614
753
|
}, rows: [
|
|
615
754
|
Plan.chart({
|
|
@@ -629,11 +768,12 @@ export const planPrintWorks = example({
|
|
|
629
768
|
Plan.library.events(),
|
|
630
769
|
Plan.library.backlog(),
|
|
631
770
|
Plan.library.series(),
|
|
632
|
-
// The customers, by district: a card dropped on a job sets its customer.
|
|
771
|
+
// The customers, by district: a card dropped on a job sets its customer. The tab follows the
|
|
772
|
+
// rail's `customers` source, by its rows' keys.
|
|
633
773
|
Plan.library.tab(customers.read(), {
|
|
634
774
|
name: "Customers", icon: "building",
|
|
635
775
|
label: c => c.name, meta: c => some(c.trade), group: c => c.district,
|
|
636
|
-
drop: c => Schedule.patch(PrintJob, { customer: c.name }),
|
|
776
|
+
drop: c => Schedule.patch(PrintJob, { customer: c.name }), source: "customers",
|
|
637
777
|
}),
|
|
638
778
|
], inspector: true }));
|
|
639
779
|
} }))),
|