@kosdev-code/kos-freestyle-sdk 2.0.41 → 2.1.1
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/{extension-utils-yKcm_im8.cjs → extension-utils-BkIqcOpm.cjs} +2 -2
- package/{extension-utils-yKcm_im8.cjs.map → extension-utils-BkIqcOpm.cjs.map} +1 -1
- package/{extension-utils-COesmx4N.js → extension-utils-DVFjFeTF.js} +2 -2
- package/{extension-utils-COesmx4N.js.map → extension-utils-DVFjFeTF.js.map} +1 -1
- package/freestyle-registration-manager-B1nEQ5f5.cjs +2 -0
- package/freestyle-registration-manager-B1nEQ5f5.cjs.map +1 -0
- package/{freestyle-registration-manager-D57Lznu_.js → freestyle-registration-manager-CClN6mVr.js} +259 -290
- package/freestyle-registration-manager-CClN6mVr.js.map +1 -0
- package/index.cjs +1 -1
- package/index.js +3 -3
- package/models/models/cartridge-agitator/cartridge-agitator-model.d.ts +5 -8
- package/models/models/cartridge-agitator/cartridge-agitator-model.d.ts.map +1 -1
- package/models/models/freestyle-nozzle/freestyle-nozzle-model.d.ts +5 -1
- package/models/models/freestyle-nozzle/freestyle-nozzle-model.d.ts.map +1 -1
- package/models/models/remote-tray/remote-tray-container-model.d.ts +5 -14
- package/models/models/remote-tray/remote-tray-container-model.d.ts.map +1 -1
- package/models/utils/freestyle-registration-manager.d.ts +3 -3
- package/models.cjs +1 -1
- package/models.js +2 -2
- package/package.json +4 -4
- package/ui.cjs +1 -1
- package/ui.js +2 -2
- package/{use-nutrition-info-Bb4itG4D.cjs → use-nutrition-info-CMWSDZ59.cjs} +2 -2
- package/{use-nutrition-info-Bb4itG4D.cjs.map → use-nutrition-info-CMWSDZ59.cjs.map} +1 -1
- package/{use-nutrition-info-Ca9_UnOV.js → use-nutrition-info-DTdUdYAE.js} +2 -2
- package/{use-nutrition-info-Ca9_UnOV.js.map → use-nutrition-info-DTdUdYAE.js.map} +1 -1
- package/freestyle-registration-manager-D57Lznu_.js.map +0 -1
- package/freestyle-registration-manager-Dx8XJMpl.cjs +0 -2
- package/freestyle-registration-manager-Dx8XJMpl.cjs.map +0 -1
package/{freestyle-registration-manager-D57Lznu_.js → freestyle-registration-manager-CClN6mVr.js}
RENAMED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var o = (e, t, r) => (
|
|
4
|
-
import { kosModel as f, KosModelRegistrationFactory as b, KosModelContainer as
|
|
1
|
+
var Fe = Object.defineProperty;
|
|
2
|
+
var Le = (e, t, r) => t in e ? Fe(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r;
|
|
3
|
+
var o = (e, t, r) => (Le(e, typeof t != "symbol" ? t + "" : t, r), r);
|
|
4
|
+
import { kosModel as f, KosModelRegistrationFactory as b, KosModelContainer as Ge, kosChild as de, resolveServiceUrl as L, ServiceFactory as G, createPropKey as j, kosStateProp as J, kosFuture as U, kosModelEffect as k, kosFutureAware as je, kosLoggerAware as ue, EventBus as M, SingletonKosModelRegistrationFactory as ee, kosParentAware as ce, KosFeatureFlags as x, kosConfigProperty as p, getKosModelSync as v, kosContainerAware as Ue, KosContextManager as Be, KosLog as $, FutureManager as He, kosAction as w, FetchError as xe, KOS_MODEL_ID as m, MultipleFutureHandler as Ke, kosTopicHandler as Ye, DependencyLifecycle as qe, modelTypeEventTopicFactory as Ve, RegistrationManager as h, registerCoreModels as We, Trouble as Ze, ExtensionManager as K, EXTENSION_TROUBLE_DATA_MAPPER as Y } from "@kosdev-code/kos-ui-sdk";
|
|
5
5
|
import { PourState as u, Assembly as ge, KosModelRegistry as Qe, registerDispenseModels as Xe, Nozzle as Je, Pump as ke, Holder as et, PumpContainer as tt, PumpIndex as rt } from "@kosdev-code/kos-dispense-sdk";
|
|
6
6
|
var at = Object.getOwnPropertyDescriptor, ot = (e, t, r, s) => {
|
|
7
7
|
for (var a = s > 1 ? void 0 : s ? at(t, r) : t, i = e.length - 1, n; i >= 0; i--)
|
|
8
8
|
(n = e[i]) && (a = n(a) || a);
|
|
9
9
|
return a;
|
|
10
10
|
};
|
|
11
|
-
const
|
|
12
|
-
let
|
|
11
|
+
const he = "carb-agitator-model";
|
|
12
|
+
let V = class {
|
|
13
13
|
constructor(e, t, r) {
|
|
14
14
|
o(this, "id");
|
|
15
15
|
o(this, "name");
|
|
@@ -25,25 +25,25 @@ let q = class {
|
|
|
25
25
|
this.logger.debug(`loading carb-agitator ${this.id}`);
|
|
26
26
|
}
|
|
27
27
|
};
|
|
28
|
-
|
|
29
|
-
f(
|
|
30
|
-
],
|
|
31
|
-
const
|
|
32
|
-
class:
|
|
33
|
-
type:
|
|
28
|
+
V = ot([
|
|
29
|
+
f(he)
|
|
30
|
+
], V);
|
|
31
|
+
const pe = new b({
|
|
32
|
+
class: V,
|
|
33
|
+
type: he
|
|
34
34
|
});
|
|
35
|
-
var st = Object.defineProperty, it = Object.getOwnPropertyDescriptor,
|
|
35
|
+
var st = Object.defineProperty, it = Object.getOwnPropertyDescriptor, ye = (e, t, r, s) => {
|
|
36
36
|
for (var a = s > 1 ? void 0 : s ? it(t, r) : t, i = e.length - 1, n; i >= 0; i--)
|
|
37
37
|
(n = e[i]) && (a = (s ? n(t, r, a) : n(a)) || a);
|
|
38
38
|
return s && a && st(t, r, a), a;
|
|
39
39
|
};
|
|
40
|
-
const
|
|
40
|
+
const fe = "cartridge-agitator-container-model";
|
|
41
41
|
let S = class {
|
|
42
42
|
constructor(e, t, r) {
|
|
43
43
|
o(this, "id");
|
|
44
44
|
o(this, "logger");
|
|
45
45
|
o(this, "_models");
|
|
46
|
-
this.id = e, this.logger = r.logger, this._models = new
|
|
46
|
+
this.id = e, this.logger = r.logger, this._models = new Ge({
|
|
47
47
|
parentId: e
|
|
48
48
|
});
|
|
49
49
|
}
|
|
@@ -74,45 +74,42 @@ let S = class {
|
|
|
74
74
|
);
|
|
75
75
|
}
|
|
76
76
|
};
|
|
77
|
-
|
|
78
|
-
|
|
77
|
+
ye([
|
|
78
|
+
de
|
|
79
79
|
], S.prototype, "_models", 2);
|
|
80
|
-
S =
|
|
81
|
-
f(
|
|
80
|
+
S = ye([
|
|
81
|
+
f(fe)
|
|
82
82
|
], S);
|
|
83
|
-
const { URL:
|
|
84
|
-
basePath: `${
|
|
83
|
+
const { URL: me } = L("CARTRIDGE_AGITATOR_SERVICE"), { postModel: nt } = G.build({
|
|
84
|
+
basePath: `${me}/api/ext/freestyle/freestyle/ice`
|
|
85
85
|
}), lt = async (e, t) => {
|
|
86
86
|
const r = await nt({
|
|
87
87
|
model: {},
|
|
88
88
|
tracker: t,
|
|
89
|
-
urlOverride: `${
|
|
89
|
+
urlOverride: `${me}/api/handle/${e}/test`
|
|
90
90
|
});
|
|
91
91
|
if (!(r != null && r.data))
|
|
92
92
|
throw new Error("No response from server");
|
|
93
93
|
return r.data;
|
|
94
94
|
};
|
|
95
|
-
var dt = Object.defineProperty, ut = Object.getOwnPropertyDescriptor,
|
|
95
|
+
var dt = Object.defineProperty, ut = Object.getOwnPropertyDescriptor, B = (e, t, r, s) => {
|
|
96
96
|
for (var a = s > 1 ? void 0 : s ? ut(t, r) : t, i = e.length - 1, n; i >= 0; i--)
|
|
97
97
|
(n = e[i]) && (a = (s ? n(t, r, a) : n(a)) || a);
|
|
98
98
|
return s && a && dt(t, r, a), a;
|
|
99
99
|
};
|
|
100
|
-
const
|
|
100
|
+
const Pe = "cartridge-agitator-model";
|
|
101
101
|
class R {
|
|
102
102
|
}
|
|
103
103
|
o(R, "TOPIC_AGITATION_STARTED", "/kos/events/ddk/agitation-started"), o(R, "TOPIC_AGITATION_ENDED", "/kos/events/ddk/agitation-ended");
|
|
104
|
-
const
|
|
105
|
-
let
|
|
106
|
-
constructor(e, t
|
|
104
|
+
const ct = j("statePath");
|
|
105
|
+
let T = class {
|
|
106
|
+
constructor(e, t) {
|
|
107
107
|
o(this, "id");
|
|
108
|
-
o(this, "futureHandler");
|
|
109
|
-
o(this, "logger");
|
|
110
|
-
o(this, "disposer");
|
|
111
108
|
o(this, "agitating");
|
|
112
109
|
o(this, "path");
|
|
113
110
|
o(this, "statePath");
|
|
114
111
|
o(this, "name");
|
|
115
|
-
this.id = e, this.
|
|
112
|
+
this.id = e, this.path = t.path, this.name = t.name, this.statePath = t.statePath;
|
|
116
113
|
}
|
|
117
114
|
get isAgitating() {
|
|
118
115
|
return !!this.agitating.value;
|
|
@@ -122,53 +119,46 @@ let O = class {
|
|
|
122
119
|
throw new Error("No tracker provided");
|
|
123
120
|
return this.logger.info(`agitating cartridge-agitator ${this.id}`), lt(this.path, e);
|
|
124
121
|
}
|
|
125
|
-
|
|
126
|
-
async init() {
|
|
127
|
-
this.logger.debug(`initializing cartridge-agitator ${this.id}`);
|
|
128
|
-
}
|
|
129
|
-
unload() {
|
|
122
|
+
handleAgitation() {
|
|
130
123
|
var e;
|
|
131
|
-
(
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
var e;
|
|
138
|
-
this.isAgitating ? (this.logger.info(`agitating cartridge-agitator ${this.id}`), w.publish(R.TOPIC_AGITATION_STARTED, {
|
|
139
|
-
path: this.path,
|
|
140
|
-
futureId: (e = this.futureHandler.future) == null ? void 0 : e.futureId
|
|
141
|
-
})) : w.publish(R.TOPIC_AGITATION_ENDED, {
|
|
142
|
-
path: this.path
|
|
143
|
-
});
|
|
144
|
-
},
|
|
145
|
-
{}
|
|
146
|
-
);
|
|
124
|
+
this.isAgitating ? (this.logger.info(`agitating cartridge-agitator ${this.id}`), M.publish(R.TOPIC_AGITATION_STARTED, {
|
|
125
|
+
path: this.path,
|
|
126
|
+
futureId: (e = this.future) == null ? void 0 : e.futureId
|
|
127
|
+
})) : M.publish(R.TOPIC_AGITATION_ENDED, {
|
|
128
|
+
path: this.path
|
|
129
|
+
});
|
|
147
130
|
}
|
|
148
131
|
};
|
|
149
|
-
|
|
150
|
-
J({ path:
|
|
151
|
-
],
|
|
152
|
-
|
|
132
|
+
B([
|
|
133
|
+
J({ path: ct, attribute: "agitating" })
|
|
134
|
+
], T.prototype, "agitating", 2);
|
|
135
|
+
B([
|
|
153
136
|
U()
|
|
154
|
-
],
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
137
|
+
], T.prototype, "testAgitate", 1);
|
|
138
|
+
B([
|
|
139
|
+
k({
|
|
140
|
+
dependencies: (e) => [e.isAgitating]
|
|
141
|
+
})
|
|
142
|
+
], T.prototype, "handleAgitation", 1);
|
|
143
|
+
T = B([
|
|
144
|
+
f(Pe),
|
|
145
|
+
je(),
|
|
146
|
+
ue()
|
|
147
|
+
], T);
|
|
148
|
+
const be = new b({
|
|
149
|
+
class: T,
|
|
150
|
+
type: Pe
|
|
151
|
+
}), te = new ee({
|
|
162
152
|
class: S,
|
|
163
|
-
type:
|
|
153
|
+
type: fe
|
|
164
154
|
});
|
|
165
|
-
te.addRelatedModel(
|
|
166
|
-
var
|
|
155
|
+
te.addRelatedModel(be);
|
|
156
|
+
var gt = Object.defineProperty, ht = Object.getOwnPropertyDescriptor, _e = (e, t, r, s) => {
|
|
167
157
|
for (var a = s > 1 ? void 0 : s ? ht(t, r) : t, i = e.length - 1, n; i >= 0; i--)
|
|
168
158
|
(n = e[i]) && (a = (s ? n(t, r, a) : n(a)) || a);
|
|
169
|
-
return s && a &&
|
|
159
|
+
return s && a && gt(t, r, a), a;
|
|
170
160
|
};
|
|
171
|
-
const
|
|
161
|
+
const ve = "freestyle-assembly-model", pt = "iceAgitator", yt = "carbAgitator", ft = "remoteTrays";
|
|
172
162
|
let D = class {
|
|
173
163
|
constructor(e, t, r) {
|
|
174
164
|
o(this, "id");
|
|
@@ -230,35 +220,35 @@ let D = class {
|
|
|
230
220
|
}
|
|
231
221
|
// -------------------LIFECYCLE----------------------------
|
|
232
222
|
get supportsRemoteTrays() {
|
|
233
|
-
return
|
|
223
|
+
return x.isFeatureEnabled(ft);
|
|
234
224
|
}
|
|
235
225
|
get supportsIce() {
|
|
236
|
-
return
|
|
226
|
+
return x.isFeatureEnabled(pt);
|
|
237
227
|
}
|
|
238
228
|
get supportsCarb() {
|
|
239
|
-
return
|
|
229
|
+
return x.isFeatureEnabled(yt);
|
|
240
230
|
}
|
|
241
231
|
async init() {
|
|
242
232
|
this.logger.debug(`initializing freestyle-assembly ${this.id}`);
|
|
243
233
|
}
|
|
244
234
|
};
|
|
245
|
-
|
|
246
|
-
|
|
235
|
+
_e([
|
|
236
|
+
de
|
|
247
237
|
], D.prototype, "_remoteTrays", 2);
|
|
248
|
-
D =
|
|
249
|
-
|
|
250
|
-
f(
|
|
238
|
+
D = _e([
|
|
239
|
+
ce(),
|
|
240
|
+
f(ve)
|
|
251
241
|
], D);
|
|
252
|
-
const
|
|
242
|
+
const W = new ee({
|
|
253
243
|
class: D,
|
|
254
|
-
type:
|
|
244
|
+
type: ve
|
|
255
245
|
});
|
|
256
|
-
var mt = Object.defineProperty,
|
|
257
|
-
for (var a = s > 1 ? void 0 : s ?
|
|
246
|
+
var mt = Object.defineProperty, Pt = Object.getOwnPropertyDescriptor, Ie = (e, t, r, s) => {
|
|
247
|
+
for (var a = s > 1 ? void 0 : s ? Pt(t, r) : t, i = e.length - 1, n; i >= 0; i--)
|
|
258
248
|
(n = e[i]) && (a = (s ? n(t, r, a) : n(a)) || a);
|
|
259
249
|
return s && a && mt(t, r, a), a;
|
|
260
250
|
};
|
|
261
|
-
const
|
|
251
|
+
const Te = "remote-tray-model";
|
|
262
252
|
j("holderPath");
|
|
263
253
|
const bt = j("configPath");
|
|
264
254
|
let z = class {
|
|
@@ -278,7 +268,7 @@ let z = class {
|
|
|
278
268
|
/**
|
|
279
269
|
* Gets the troubles from the associated holder model.
|
|
280
270
|
* Propagates trouble states from the holder to this remote tray.
|
|
281
|
-
*
|
|
271
|
+
*
|
|
282
272
|
* @returns Array of trouble models from the holder, or empty array if no holder
|
|
283
273
|
*/
|
|
284
274
|
get troubles() {
|
|
@@ -288,7 +278,7 @@ let z = class {
|
|
|
288
278
|
/**
|
|
289
279
|
* Gets the highest priority trouble status.
|
|
290
280
|
* Currently returns empty string as troubles are managed by the holder.
|
|
291
|
-
*
|
|
281
|
+
*
|
|
292
282
|
* @returns Empty string (trouble status handled by holder)
|
|
293
283
|
*/
|
|
294
284
|
get troubleStatus() {
|
|
@@ -296,7 +286,7 @@ let z = class {
|
|
|
296
286
|
}
|
|
297
287
|
/**
|
|
298
288
|
* Gets troubles grouped by type from the associated holder.
|
|
299
|
-
*
|
|
289
|
+
*
|
|
300
290
|
* @returns Record of troubles grouped by type from the holder, or empty object if no holder
|
|
301
291
|
*/
|
|
302
292
|
get troublesByType() {
|
|
@@ -306,7 +296,7 @@ let z = class {
|
|
|
306
296
|
/**
|
|
307
297
|
* Updates the model with new configuration options.
|
|
308
298
|
* Can be used to modify the holder path, config path, or name after initialization.
|
|
309
|
-
*
|
|
299
|
+
*
|
|
310
300
|
* @param _options - New configuration options for the remote tray
|
|
311
301
|
*/
|
|
312
302
|
updateModel(e) {
|
|
@@ -314,7 +304,7 @@ let z = class {
|
|
|
314
304
|
/**
|
|
315
305
|
* Gets the associated holder model for this remote tray.
|
|
316
306
|
* Uses synchronous model lookup to retrieve the holder by path.
|
|
317
|
-
*
|
|
307
|
+
*
|
|
318
308
|
* @returns The HolderModel instance referenced by holderPath, or undefined if not found
|
|
319
309
|
*/
|
|
320
310
|
get holder() {
|
|
@@ -323,7 +313,7 @@ let z = class {
|
|
|
323
313
|
/**
|
|
324
314
|
* Determines if the remote tray is currently active.
|
|
325
315
|
* Active state is based on the remoteTrayEnabled configuration property.
|
|
326
|
-
*
|
|
316
|
+
*
|
|
327
317
|
* @returns true if the tray is enabled, false otherwise
|
|
328
318
|
*/
|
|
329
319
|
get active() {
|
|
@@ -334,7 +324,7 @@ let z = class {
|
|
|
334
324
|
* Initializes the remote tray model.
|
|
335
325
|
* Called during the model lifecycle initialization phase.
|
|
336
326
|
* Sets up initial state and prepares the model for use.
|
|
337
|
-
*
|
|
327
|
+
*
|
|
338
328
|
* @returns Promise that resolves when initialization is complete
|
|
339
329
|
*/
|
|
340
330
|
async init() {
|
|
@@ -344,88 +334,57 @@ let z = class {
|
|
|
344
334
|
* Loads the remote tray configuration and associated data.
|
|
345
335
|
* Called during the model lifecycle load phase.
|
|
346
336
|
* Typically loads configuration settings and establishes holder references.
|
|
347
|
-
*
|
|
337
|
+
*
|
|
348
338
|
* @returns Promise that resolves when loading is complete
|
|
349
339
|
*/
|
|
350
340
|
async load() {
|
|
351
341
|
this.logger.debug(`loading remote-tray ${this.id}`);
|
|
352
342
|
}
|
|
353
343
|
};
|
|
354
|
-
|
|
344
|
+
Ie([
|
|
355
345
|
p({
|
|
356
346
|
path: bt,
|
|
357
347
|
attribute: "enabled"
|
|
358
348
|
})
|
|
359
349
|
], z.prototype, "remoteTrayEnabled", 2);
|
|
360
|
-
z =
|
|
361
|
-
f(
|
|
350
|
+
z = Ie([
|
|
351
|
+
f(Te)
|
|
362
352
|
], z);
|
|
363
|
-
const
|
|
353
|
+
const A = new b({
|
|
364
354
|
class: z,
|
|
365
|
-
type:
|
|
355
|
+
type: Te
|
|
366
356
|
});
|
|
367
|
-
var
|
|
368
|
-
for (var a = s > 1 ? void 0 : s ?
|
|
369
|
-
(n = e[i]) && (a =
|
|
370
|
-
return
|
|
357
|
+
var _t = Object.getOwnPropertyDescriptor, vt = (e, t, r, s) => {
|
|
358
|
+
for (var a = s > 1 ? void 0 : s ? _t(t, r) : t, i = e.length - 1, n; i >= 0; i--)
|
|
359
|
+
(n = e[i]) && (a = n(a) || a);
|
|
360
|
+
return a;
|
|
371
361
|
};
|
|
372
362
|
const Oe = "remote-tray-container-model";
|
|
373
|
-
let
|
|
374
|
-
constructor(e
|
|
363
|
+
let Z = class {
|
|
364
|
+
constructor(e) {
|
|
375
365
|
o(this, "id");
|
|
376
|
-
|
|
377
|
-
o(this, "_models");
|
|
378
|
-
this.id = e, this.logger = r.logger, this._models = new de({
|
|
379
|
-
parentId: e
|
|
380
|
-
});
|
|
381
|
-
}
|
|
382
|
-
getModel(e) {
|
|
383
|
-
return this._models.getModel(e);
|
|
384
|
-
}
|
|
385
|
-
get models() {
|
|
386
|
-
return this._models;
|
|
387
|
-
}
|
|
388
|
-
get data() {
|
|
389
|
-
return this._models.data;
|
|
390
|
-
}
|
|
391
|
-
updateModel(e) {
|
|
392
|
-
}
|
|
393
|
-
addModel(e) {
|
|
394
|
-
this._models.addModel(e);
|
|
395
|
-
}
|
|
396
|
-
removeModel(e) {
|
|
397
|
-
this._models.removeModel(e);
|
|
398
|
-
}
|
|
399
|
-
// -------------------LIFECYCLE----------------------------
|
|
400
|
-
async init() {
|
|
401
|
-
this.logger.debug(
|
|
402
|
-
`initializing remote-tray-container container ${this.id}`
|
|
403
|
-
);
|
|
404
|
-
}
|
|
405
|
-
async load() {
|
|
406
|
-
this.logger.debug(`loading remote-tray-container container ${this.id}`);
|
|
366
|
+
this.id = e;
|
|
407
367
|
}
|
|
408
368
|
};
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
class: N,
|
|
369
|
+
Z = vt([
|
|
370
|
+
f(Oe),
|
|
371
|
+
ue(),
|
|
372
|
+
Ue()
|
|
373
|
+
], Z);
|
|
374
|
+
const re = new ee({
|
|
375
|
+
class: Z,
|
|
417
376
|
type: Oe
|
|
418
377
|
});
|
|
419
|
-
re.addRelatedModel(
|
|
378
|
+
re.addRelatedModel(A);
|
|
420
379
|
var It = Object.getOwnPropertyDescriptor, Tt = (e, t, r, s) => {
|
|
421
380
|
for (var a = s > 1 ? void 0 : s ? It(t, r) : t, i = e.length - 1, n; i >= 0; i--)
|
|
422
381
|
(n = e[i]) && (a = n(a) || a);
|
|
423
382
|
return a;
|
|
424
383
|
};
|
|
425
|
-
const
|
|
384
|
+
const Ae = "freestyle-holder-model";
|
|
426
385
|
function Ot(e) {
|
|
427
|
-
const t =
|
|
428
|
-
|
|
386
|
+
const t = Be.getContext(e), r = t == null ? void 0 : t.get(
|
|
387
|
+
W.type
|
|
429
388
|
);
|
|
430
389
|
if (!r) {
|
|
431
390
|
$.error("Freestyle assembly not found");
|
|
@@ -433,14 +392,14 @@ function Ot(e) {
|
|
|
433
392
|
}
|
|
434
393
|
return r;
|
|
435
394
|
}
|
|
436
|
-
async function
|
|
395
|
+
async function At(e, t) {
|
|
437
396
|
if (!e || !t)
|
|
438
397
|
return;
|
|
439
398
|
const r = await e[t]();
|
|
440
399
|
if (r != null && r.tracker)
|
|
441
|
-
return
|
|
400
|
+
return He.getFuture(r.tracker);
|
|
442
401
|
}
|
|
443
|
-
let
|
|
402
|
+
let Q = class {
|
|
444
403
|
constructor(e, t, r) {
|
|
445
404
|
o(this, "id");
|
|
446
405
|
o(this, "logger");
|
|
@@ -463,13 +422,13 @@ let W = class {
|
|
|
463
422
|
this.logger.error("Agitator not found");
|
|
464
423
|
return;
|
|
465
424
|
}
|
|
466
|
-
return this.future = await
|
|
425
|
+
return this.future = await At(
|
|
467
426
|
e.defaultCartridgeAgitator,
|
|
468
427
|
"testAgitate"
|
|
469
428
|
), this.future;
|
|
470
429
|
}
|
|
471
430
|
get isRemote() {
|
|
472
|
-
const e = `${
|
|
431
|
+
const e = `${A.type}-${this.holder.path}`, t = v(e);
|
|
473
432
|
return t != null && t.model ? !!t.model.remoteTrayEnabled.value : !1;
|
|
474
433
|
}
|
|
475
434
|
// -------------------LIFECYCLE----------------------------
|
|
@@ -480,14 +439,14 @@ let W = class {
|
|
|
480
439
|
this.logger.debug(`loading freestyle-holder ${this.id}`);
|
|
481
440
|
}
|
|
482
441
|
};
|
|
483
|
-
|
|
484
|
-
f(
|
|
485
|
-
],
|
|
442
|
+
Q = Tt([
|
|
443
|
+
f(Ae)
|
|
444
|
+
], Q);
|
|
486
445
|
const se = new b({
|
|
487
|
-
class:
|
|
488
|
-
type:
|
|
489
|
-
}), { URL:
|
|
490
|
-
basePath: `${
|
|
446
|
+
class: Q,
|
|
447
|
+
type: Ae
|
|
448
|
+
}), { URL: Et } = L("FREESTYLE-NOZZLE_SERVICE"), { getOne: $t } = G.build({
|
|
449
|
+
basePath: `${Et}/api/freestyle-nozzle`
|
|
491
450
|
}), C = $.createLogger({
|
|
492
451
|
name: "freestyle-nozzle-service",
|
|
493
452
|
group: "Services"
|
|
@@ -502,7 +461,7 @@ class ie extends Error {
|
|
|
502
461
|
super(t), this.name = "InvalidRequestError";
|
|
503
462
|
}
|
|
504
463
|
}
|
|
505
|
-
const
|
|
464
|
+
const wt = async (e, t, r, s = "http://localhost:8081") => {
|
|
506
465
|
if (C.debug("sending GET for freestyle-nozzle"), !t)
|
|
507
466
|
throw C.error("Invalid freestyle-nozzle request: beverageId is required"), new ie("No beverageId provided");
|
|
508
467
|
if (!r || r.length === 0)
|
|
@@ -518,20 +477,19 @@ const Mt = async (e, t, r, s = "http://localhost:8081") => {
|
|
|
518
477
|
throw new Ct(a.data.error);
|
|
519
478
|
return a.data;
|
|
520
479
|
};
|
|
521
|
-
var
|
|
522
|
-
for (var a = s > 1 ? void 0 : s ?
|
|
523
|
-
(n = e[i]) && (a = n(a) || a);
|
|
524
|
-
return a;
|
|
480
|
+
var Mt = Object.defineProperty, St = Object.getOwnPropertyDescriptor, Ee = (e, t, r, s) => {
|
|
481
|
+
for (var a = s > 1 ? void 0 : s ? St(t, r) : t, i = e.length - 1, n; i >= 0; i--)
|
|
482
|
+
(n = e[i]) && (a = (s ? n(t, r, a) : n(a)) || a);
|
|
483
|
+
return s && a && Mt(t, r, a), a;
|
|
525
484
|
};
|
|
526
|
-
const
|
|
527
|
-
let
|
|
485
|
+
const $e = "freestyle-nozzle-model";
|
|
486
|
+
let N = class {
|
|
528
487
|
constructor(e, t, r) {
|
|
529
488
|
o(this, "id");
|
|
530
489
|
o(this, "logger");
|
|
531
490
|
o(this, "nozzleModel");
|
|
532
491
|
o(this, "_cupSizes");
|
|
533
492
|
o(this, "_nutritionInfo");
|
|
534
|
-
o(this, "_disposer", null);
|
|
535
493
|
this.id = e, this.logger = r.logger, this.nozzleModel = t.companionParent, this._cupSizes = [100];
|
|
536
494
|
}
|
|
537
495
|
set cupSizes(e) {
|
|
@@ -540,66 +498,77 @@ let Z = class {
|
|
|
540
498
|
get nutritionInfo() {
|
|
541
499
|
return this._nutritionInfo;
|
|
542
500
|
}
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
501
|
+
get selectedPourable() {
|
|
502
|
+
return this.nozzleModel.selectedPourable;
|
|
503
|
+
}
|
|
504
|
+
async handleBeverageSelection() {
|
|
505
|
+
if (this.nozzleModel.selectedPourable.beverage && this._cupSizes.length) {
|
|
506
|
+
this.logger.debug(
|
|
507
|
+
`selected beverage: ${this.nozzleModel.selectedPourable.beverage.rawId}. Volume: ${this._cupSizes.join(", ")}`
|
|
508
|
+
);
|
|
509
|
+
const e = this.nozzleModel.selectedPourable.beverage.rawId, t = this.nozzleModel.urlPrefix;
|
|
510
|
+
try {
|
|
511
|
+
const r = await wt(
|
|
512
|
+
t,
|
|
513
|
+
e,
|
|
514
|
+
this._cupSizes
|
|
549
515
|
);
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
this._cupSizes
|
|
556
|
-
);
|
|
557
|
-
M(() => {
|
|
558
|
-
this._nutritionInfo = r;
|
|
559
|
-
});
|
|
560
|
-
} catch (r) {
|
|
561
|
-
this.logger.error(`Error fetching nutrition info: ${r}`);
|
|
562
|
-
}
|
|
516
|
+
w(() => {
|
|
517
|
+
this._nutritionInfo = r;
|
|
518
|
+
});
|
|
519
|
+
} catch (r) {
|
|
520
|
+
this.logger.error(`Error fetching nutrition info: ${r}`);
|
|
563
521
|
}
|
|
564
|
-
}
|
|
522
|
+
}
|
|
523
|
+
}
|
|
524
|
+
// -------------------LIFECYCLE----------------------------
|
|
525
|
+
async init() {
|
|
526
|
+
this.logger.debug(`initializing freestyle-nozzle ${this.id}`);
|
|
565
527
|
}
|
|
566
528
|
unload() {
|
|
567
|
-
this.logger.debug(`unloading freestyle-nozzle ${this.id}`)
|
|
529
|
+
this.logger.debug(`unloading freestyle-nozzle ${this.id}`);
|
|
568
530
|
}
|
|
569
531
|
async load() {
|
|
570
532
|
this.logger.debug(`loading freestyle-nozzle ${this.id}`);
|
|
571
533
|
}
|
|
572
534
|
};
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
535
|
+
Ee([
|
|
536
|
+
k({
|
|
537
|
+
dependencies: (e) => [
|
|
538
|
+
e.selectedPourable.beverage
|
|
539
|
+
]
|
|
540
|
+
})
|
|
541
|
+
], N.prototype, "handleBeverageSelection", 1);
|
|
542
|
+
N = Ee([
|
|
543
|
+
ce(),
|
|
544
|
+
f($e)
|
|
545
|
+
], N);
|
|
577
546
|
const ne = new b({
|
|
578
|
-
class:
|
|
579
|
-
type:
|
|
580
|
-
}), { URL:
|
|
581
|
-
basePath: `${
|
|
582
|
-
}),
|
|
547
|
+
class: N,
|
|
548
|
+
type: $e
|
|
549
|
+
}), { URL: Ce } = L("PUMP_SERVICE"), { postModel: Rt } = G.build({
|
|
550
|
+
basePath: `${Ce}/api/ext/freestyle/microCalibration`
|
|
551
|
+
}), q = $.createLogger({
|
|
583
552
|
name: "freestyle-pump-service",
|
|
584
553
|
group: "Services"
|
|
585
554
|
}), Dt = async (e, t) => {
|
|
586
555
|
var r, s, a, i, n;
|
|
587
|
-
|
|
556
|
+
q.debug(
|
|
588
557
|
`replacePump - sending POST request to /api/ext/freestyle/microCalibration/cal/${e}/code/${t}`
|
|
589
558
|
);
|
|
590
559
|
try {
|
|
591
560
|
const l = await Rt({
|
|
592
561
|
model: {},
|
|
593
|
-
urlOverride: `${
|
|
562
|
+
urlOverride: `${Ce}/api/ext/freestyle/microCalibration/cal/${e}/code/${t}`
|
|
594
563
|
});
|
|
595
|
-
return
|
|
564
|
+
return q.debug("replacePump - response:", l), ((l == null ? void 0 : l.status) === 200 || (l == null ? void 0 : l.status) === 499) && ((r = l.data) != null && r.error) ? [l.data.error || "unknownError", l.data] : [void 0, l == null ? void 0 : l.data];
|
|
596
565
|
} catch (l) {
|
|
597
|
-
if (
|
|
566
|
+
if (q.error(
|
|
598
567
|
`replacePump - sending POST request to /api/cal/${e}/code/${t}`,
|
|
599
568
|
l
|
|
600
|
-
), l instanceof
|
|
601
|
-
const
|
|
602
|
-
return [
|
|
569
|
+
), l instanceof xe) {
|
|
570
|
+
const O = ((a = (s = l.payload) == null ? void 0 : s.data) == null ? void 0 : a.error) || ((i = l.payload) == null ? void 0 : i.error) || "unknownError";
|
|
571
|
+
return [O, ((n = l.payload) == null ? void 0 : n.data) || { error: O }];
|
|
603
572
|
}
|
|
604
573
|
}
|
|
605
574
|
return ["unknownError", { error: "unknownError" }];
|
|
@@ -609,8 +578,8 @@ var zt = Object.getOwnPropertyDescriptor, Nt = (e, t, r, s) => {
|
|
|
609
578
|
(n = e[i]) && (a = n(a) || a);
|
|
610
579
|
return a;
|
|
611
580
|
};
|
|
612
|
-
const
|
|
613
|
-
let
|
|
581
|
+
const we = "freestyle-pump-model";
|
|
582
|
+
let X = class {
|
|
614
583
|
constructor(e, t, r) {
|
|
615
584
|
o(this, "id");
|
|
616
585
|
o(this, "logger");
|
|
@@ -623,26 +592,26 @@ let Q = class {
|
|
|
623
592
|
return t && this.logger.error(`Failed to replace the pump, ${this.pump.id}`, t), [t, r];
|
|
624
593
|
}
|
|
625
594
|
};
|
|
626
|
-
|
|
627
|
-
f(
|
|
628
|
-
],
|
|
595
|
+
X = Nt([
|
|
596
|
+
f(we)
|
|
597
|
+
], X);
|
|
629
598
|
const le = new b({
|
|
630
|
-
class:
|
|
631
|
-
type:
|
|
632
|
-
}), { URL: I } = L("ICE_AGITATOR_SERVICE"), { getAll: Me, postModel:
|
|
599
|
+
class: X,
|
|
600
|
+
type: we
|
|
601
|
+
}), { URL: I } = L("ICE_AGITATOR_SERVICE"), { getAll: Me, postModel: H } = G.build({
|
|
633
602
|
basePath: `${I}/api/ext/freestyle/ice`
|
|
634
|
-
}),
|
|
603
|
+
}), Se = $.createLogger({
|
|
635
604
|
name: "ice-agitator-service",
|
|
636
605
|
group: "Services"
|
|
637
|
-
}), Ft = async (e) => (
|
|
606
|
+
}), Ft = async (e) => (Se.debug("sending GET for ice types"), await Me({
|
|
638
607
|
urlOverride: `${I}/api/handle/${e}/types`
|
|
639
|
-
})), Lt = async (e, t) => (
|
|
608
|
+
})), Lt = async (e, t) => (Se.debug("sending POST for ice types"), await H({
|
|
640
609
|
urlOverride: `${I}/api/handle/${e}/type/${t}`,
|
|
641
610
|
model: {}
|
|
642
611
|
})), Gt = async (e) => await Me({
|
|
643
612
|
urlOverride: `${I}/api/kos/config/details/${e}/4`
|
|
644
613
|
}), jt = async (e, t) => {
|
|
645
|
-
const r = await
|
|
614
|
+
const r = await H({
|
|
646
615
|
model: {},
|
|
647
616
|
tracker: t,
|
|
648
617
|
urlOverride: `${I}/api/handle/${e}/pour`
|
|
@@ -651,7 +620,7 @@ const le = new b({
|
|
|
651
620
|
throw new Error("No response from server");
|
|
652
621
|
return r == null ? void 0 : r.data;
|
|
653
622
|
}, Ut = async (e, t) => {
|
|
654
|
-
const r = await
|
|
623
|
+
const r = await H({
|
|
655
624
|
model: {},
|
|
656
625
|
tracker: t,
|
|
657
626
|
urlOverride: `${I}/api/handle/${e}/test/agitation`
|
|
@@ -660,7 +629,7 @@ const le = new b({
|
|
|
660
629
|
throw new Error("No response from server");
|
|
661
630
|
return r == null ? void 0 : r.data;
|
|
662
631
|
}, Bt = async (e, t) => {
|
|
663
|
-
const r = await
|
|
632
|
+
const r = await H({
|
|
664
633
|
model: {},
|
|
665
634
|
tracker: t,
|
|
666
635
|
urlOverride: `${I}/api/handle/${e}/test/gate`
|
|
@@ -669,7 +638,7 @@ const le = new b({
|
|
|
669
638
|
throw new Error("No response from server");
|
|
670
639
|
return r == null ? void 0 : r.data;
|
|
671
640
|
};
|
|
672
|
-
var Ht = Object.defineProperty, xt = Object.getOwnPropertyDescriptor,
|
|
641
|
+
var Ht = Object.defineProperty, xt = Object.getOwnPropertyDescriptor, c = (e, t, r, s) => {
|
|
673
642
|
for (var a = s > 1 ? void 0 : s ? xt(t, r) : t, i = e.length - 1, n; i >= 0; i--)
|
|
674
643
|
(n = e[i]) && (a = (s ? n(t, r, a) : n(a)) || a);
|
|
675
644
|
return s && a && Ht(t, r, a), a;
|
|
@@ -677,7 +646,7 @@ var Ht = Object.defineProperty, xt = Object.getOwnPropertyDescriptor, g = (e, t,
|
|
|
677
646
|
class F {
|
|
678
647
|
}
|
|
679
648
|
o(F, "TOPIC_AGITATION_STARTED", "/kos/events/ddk/ice-agitation-started"), o(F, "TOPIC_AGITATION_ENDED", "/kos/events/ddk/ice-agitation-ended");
|
|
680
|
-
const
|
|
649
|
+
const Re = "ice-agitator-model", De = j("statePath");
|
|
681
650
|
let d = class {
|
|
682
651
|
constructor(e, t, r) {
|
|
683
652
|
o(this, "id");
|
|
@@ -742,7 +711,7 @@ let d = class {
|
|
|
742
711
|
return this.currentState === u.IDLE;
|
|
743
712
|
}
|
|
744
713
|
updateIfCurrent(e, t) {
|
|
745
|
-
this.currentState === e &&
|
|
714
|
+
this.currentState === e && w(() => {
|
|
746
715
|
this.currentState = t;
|
|
747
716
|
});
|
|
748
717
|
}
|
|
@@ -764,7 +733,7 @@ let d = class {
|
|
|
764
733
|
* */
|
|
765
734
|
async cancelIceDispense() {
|
|
766
735
|
var e;
|
|
767
|
-
this.currentState === u.POURING || this.currentState === u.POUR_STARTING ? (this.currentState = u.POUR_CANCELING, await ((e = this.pourFuture) == null ? void 0 : e.cancelFuture()),
|
|
736
|
+
this.currentState === u.POURING || this.currentState === u.POUR_STARTING ? (this.currentState = u.POUR_CANCELING, await ((e = this.pourFuture) == null ? void 0 : e.cancelFuture()), w(() => {
|
|
768
737
|
this.currentState = u.IDLE;
|
|
769
738
|
})) : this.logger.warn(
|
|
770
739
|
`Cannot cancel ice dispense in state ${this.currentState}`
|
|
@@ -782,10 +751,10 @@ let d = class {
|
|
|
782
751
|
}
|
|
783
752
|
handleAgitationChange() {
|
|
784
753
|
var e;
|
|
785
|
-
this.isAgitating ? (this.logger.info(`agitating ice-agitator ${this.id}`),
|
|
754
|
+
this.isAgitating ? (this.logger.info(`agitating ice-agitator ${this.id}`), M.publish(F.TOPIC_AGITATION_STARTED, {
|
|
786
755
|
path: this.path,
|
|
787
756
|
futureId: (e = this.futureHandler.future) == null ? void 0 : e.futureId
|
|
788
|
-
})) :
|
|
757
|
+
})) : M.publish(F.TOPIC_AGITATION_ENDED, {
|
|
789
758
|
path: this.path
|
|
790
759
|
});
|
|
791
760
|
}
|
|
@@ -798,18 +767,18 @@ let d = class {
|
|
|
798
767
|
async load() {
|
|
799
768
|
this.logger.debug(`loading ice-agitator ${this.id}`);
|
|
800
769
|
const e = await Ft(this.path);
|
|
801
|
-
(e == null ? void 0 : e.status) === 200 &&
|
|
770
|
+
(e == null ? void 0 : e.status) === 200 && w(() => {
|
|
802
771
|
this._allIceTypes = e.data || [];
|
|
803
772
|
});
|
|
804
773
|
}
|
|
805
774
|
};
|
|
806
|
-
|
|
775
|
+
c([
|
|
807
776
|
p({
|
|
808
777
|
path: m,
|
|
809
778
|
attribute: "settings.volWithoutIceMl"
|
|
810
779
|
})
|
|
811
780
|
], d.prototype, "volWithoutIceMl", 2);
|
|
812
|
-
|
|
781
|
+
c([
|
|
813
782
|
p({
|
|
814
783
|
path: m,
|
|
815
784
|
attribute: "settings.durationSec",
|
|
@@ -818,49 +787,49 @@ g([
|
|
|
818
787
|
}
|
|
819
788
|
})
|
|
820
789
|
], d.prototype, "durationSec", 2);
|
|
821
|
-
|
|
790
|
+
c([
|
|
822
791
|
p({
|
|
823
792
|
path: m,
|
|
824
793
|
attribute: "enableIceChuteClear"
|
|
825
794
|
})
|
|
826
795
|
], d.prototype, "enableIceChuteClear", 2);
|
|
827
|
-
|
|
796
|
+
c([
|
|
828
797
|
p({
|
|
829
798
|
path: m,
|
|
830
799
|
attribute: "iceChuteClearDurationMs"
|
|
831
800
|
})
|
|
832
801
|
], d.prototype, "iceChuteClearDurationMs", 2);
|
|
833
|
-
|
|
802
|
+
c([
|
|
834
803
|
p({
|
|
835
804
|
path: m,
|
|
836
805
|
attribute: "iceChuteClearIntervalSec"
|
|
837
806
|
})
|
|
838
807
|
], d.prototype, "iceChuteClearIntervalSec", 2);
|
|
839
|
-
|
|
808
|
+
c([
|
|
840
809
|
p({
|
|
841
810
|
path: m,
|
|
842
811
|
attribute: "iceChuteClearRetryIntervalSec"
|
|
843
812
|
})
|
|
844
813
|
], d.prototype, "iceChuteClearRetryIntervalSec", 2);
|
|
845
|
-
|
|
814
|
+
c([
|
|
846
815
|
p({
|
|
847
816
|
path: m,
|
|
848
817
|
attribute: "maxDispenseSec"
|
|
849
818
|
})
|
|
850
819
|
], d.prototype, "maxDispenseSec", 2);
|
|
851
|
-
|
|
820
|
+
c([
|
|
852
821
|
p({
|
|
853
822
|
path: m,
|
|
854
823
|
attribute: "type"
|
|
855
824
|
})
|
|
856
825
|
], d.prototype, "type", 2);
|
|
857
|
-
|
|
826
|
+
c([
|
|
858
827
|
p({
|
|
859
828
|
path: m,
|
|
860
829
|
attribute: "settings.dilutionOffset"
|
|
861
830
|
})
|
|
862
831
|
], d.prototype, "dilutionOffset", 2);
|
|
863
|
-
|
|
832
|
+
c([
|
|
864
833
|
p({
|
|
865
834
|
path: m,
|
|
866
835
|
attribute: "settings.inactivitySec",
|
|
@@ -869,34 +838,34 @@ g([
|
|
|
869
838
|
}
|
|
870
839
|
})
|
|
871
840
|
], d.prototype, "inactivitySec", 2);
|
|
872
|
-
|
|
873
|
-
J({ path:
|
|
841
|
+
c([
|
|
842
|
+
J({ path: De, attribute: "agitating" })
|
|
874
843
|
], d.prototype, "agitating", 2);
|
|
875
|
-
|
|
876
|
-
J({ path:
|
|
844
|
+
c([
|
|
845
|
+
J({ path: De, attribute: "iceChuteOpen" })
|
|
877
846
|
], d.prototype, "iceChuteOpen", 2);
|
|
878
|
-
|
|
847
|
+
c([
|
|
879
848
|
U({ alias: "pour" })
|
|
880
849
|
], d.prototype, "pourIce", 1);
|
|
881
|
-
|
|
850
|
+
c([
|
|
882
851
|
U({ alias: "agitate" })
|
|
883
852
|
], d.prototype, "testAgitate", 1);
|
|
884
|
-
|
|
853
|
+
c([
|
|
885
854
|
U({
|
|
886
855
|
alias: "gate"
|
|
887
856
|
})
|
|
888
857
|
], d.prototype, "testGate", 1);
|
|
889
|
-
|
|
890
|
-
|
|
858
|
+
c([
|
|
859
|
+
k({
|
|
891
860
|
dependencies: (e) => [e.isAgitating]
|
|
892
861
|
})
|
|
893
862
|
], d.prototype, "handleAgitationChange", 1);
|
|
894
|
-
d =
|
|
895
|
-
f(
|
|
863
|
+
d = c([
|
|
864
|
+
f(Re)
|
|
896
865
|
], d);
|
|
897
|
-
const
|
|
866
|
+
const ze = new b({
|
|
898
867
|
class: d,
|
|
899
|
-
type:
|
|
868
|
+
type: Re
|
|
900
869
|
});
|
|
901
870
|
var Kt = Object.defineProperty, Yt = Object.getOwnPropertyDescriptor, ae = (e, t, r, s) => {
|
|
902
871
|
for (var a = s > 1 ? void 0 : s ? Yt(t, r) : t, i = e.length - 1, n; i >= 0; i--)
|
|
@@ -907,7 +876,7 @@ const oe = "agitation-required-trouble-model", qt = (e) => {
|
|
|
907
876
|
if (e.data.agitationRequired)
|
|
908
877
|
return oe;
|
|
909
878
|
}, Vt = "InsufficientAgitationTrouble";
|
|
910
|
-
let
|
|
879
|
+
let E = class {
|
|
911
880
|
constructor(e, t, r) {
|
|
912
881
|
o(this, "id");
|
|
913
882
|
o(this, "logger");
|
|
@@ -953,54 +922,54 @@ ae([
|
|
|
953
922
|
path: "app:kosdev.ddk:app",
|
|
954
923
|
attribute: "ncui.agitateBeforePour"
|
|
955
924
|
})
|
|
956
|
-
],
|
|
925
|
+
], E.prototype, "agitateBeforePour", 2);
|
|
957
926
|
ae([
|
|
958
927
|
Ye({
|
|
959
928
|
topic: Ve(ge.type),
|
|
960
929
|
lifecycle: qe.INIT
|
|
961
930
|
})
|
|
962
|
-
],
|
|
963
|
-
|
|
931
|
+
], E.prototype, "updateHolder", 1);
|
|
932
|
+
E = ae([
|
|
964
933
|
f(oe)
|
|
965
|
-
],
|
|
934
|
+
], E);
|
|
966
935
|
const Wt = new b({
|
|
967
|
-
class:
|
|
936
|
+
class: E,
|
|
968
937
|
type: oe
|
|
969
938
|
}), Zt = ["iceAgitator", "carbAgitator"], Qt = {
|
|
970
|
-
iceAgitator:
|
|
971
|
-
carbAgitator:
|
|
939
|
+
iceAgitator: ze.factory,
|
|
940
|
+
carbAgitator: pe.factory
|
|
972
941
|
}, Xt = $.createLogger({ name: "freestyle-assembly-data-mapper" }), rr = async (e) => {
|
|
973
942
|
const t = te.instance().options({}).build(), r = re.instance().options({}).build(), s = e.assemblies.reduce((n, l) => {
|
|
974
|
-
var
|
|
975
|
-
return Zt.forEach((
|
|
976
|
-
var
|
|
977
|
-
const
|
|
978
|
-
if (
|
|
979
|
-
const
|
|
980
|
-
n[
|
|
981
|
-
name:
|
|
982
|
-
path:
|
|
983
|
-
statePath: ((
|
|
943
|
+
var O;
|
|
944
|
+
return Zt.forEach((g) => {
|
|
945
|
+
var _;
|
|
946
|
+
const P = l[g];
|
|
947
|
+
if (P) {
|
|
948
|
+
const Ne = Qt[g](P.path);
|
|
949
|
+
n[g] = Ne({
|
|
950
|
+
name: P.name,
|
|
951
|
+
path: P.path,
|
|
952
|
+
statePath: ((_ = P.state) == null ? void 0 : _.path) || ""
|
|
984
953
|
});
|
|
985
954
|
}
|
|
986
|
-
}), (
|
|
987
|
-
var
|
|
988
|
-
const
|
|
989
|
-
|
|
955
|
+
}), (O = l.cartridgeAgitators) == null || O.forEach((g) => {
|
|
956
|
+
var _;
|
|
957
|
+
const P = be.instance(
|
|
958
|
+
g.path
|
|
990
959
|
).options({
|
|
991
|
-
name:
|
|
992
|
-
path:
|
|
993
|
-
statePath: ((
|
|
960
|
+
name: g.name,
|
|
961
|
+
path: g.path,
|
|
962
|
+
statePath: ((_ = g.state) == null ? void 0 : _.path) || ""
|
|
994
963
|
}).build();
|
|
995
|
-
t.addModel(
|
|
996
|
-
}), l.remoteTrays && l.remoteTrays.forEach((
|
|
997
|
-
Xt.info(`Found remote tray ${
|
|
998
|
-
const
|
|
999
|
-
holderPath:
|
|
1000
|
-
configPath:
|
|
1001
|
-
name:
|
|
964
|
+
t.addModel(P);
|
|
965
|
+
}), l.remoteTrays && l.remoteTrays.forEach((g) => {
|
|
966
|
+
Xt.info(`Found remote tray ${g.name} with path ${g.path}`);
|
|
967
|
+
const P = `${A.type}-${g.holderPath}`, _ = A.instance(P).options({
|
|
968
|
+
holderPath: g.holderPath,
|
|
969
|
+
configPath: g.path,
|
|
970
|
+
name: g.name
|
|
1002
971
|
}).build();
|
|
1003
|
-
r.addModel(
|
|
972
|
+
r.addModel(_);
|
|
1004
973
|
}), n;
|
|
1005
974
|
}, {}), a = !!s.iceAgitator, i = !!s.carbAgitator;
|
|
1006
975
|
return {
|
|
@@ -1010,19 +979,19 @@ const Wt = new b({
|
|
|
1010
979
|
supportsCarb: i,
|
|
1011
980
|
supportsIce: a
|
|
1012
981
|
};
|
|
1013
|
-
}, Jt = (e) => () => (We(e)(), Xe(e)(), ne.register(),
|
|
982
|
+
}, Jt = (e) => () => (We(e)(), Xe(e)(), ne.register(), W.register(), ze.register(), pe.register(), te.register(), le.register(), se.register(), A.register(), re.register(), h.companion.register(e)(
|
|
1014
983
|
Je.type,
|
|
1015
984
|
ne.type
|
|
1016
985
|
), h.companion.register(e)(
|
|
1017
986
|
ge.type,
|
|
1018
|
-
|
|
987
|
+
W.type
|
|
1019
988
|
), Wt.register(), h.companion.register(e)(
|
|
1020
989
|
Ze.type,
|
|
1021
990
|
qt
|
|
1022
991
|
), h.companion.register(e)(ke.type, le.type), h.companion.register(e)(
|
|
1023
992
|
et.type,
|
|
1024
993
|
se.type
|
|
1025
|
-
),
|
|
994
|
+
), K[Y].register(
|
|
1026
995
|
"EnjoyByTrouble",
|
|
1027
996
|
async (t) => {
|
|
1028
997
|
if (t.data.enjoyByDate) {
|
|
@@ -1035,7 +1004,7 @@ const Wt = new b({
|
|
|
1035
1004
|
}
|
|
1036
1005
|
return {};
|
|
1037
1006
|
}
|
|
1038
|
-
),
|
|
1007
|
+
), K[Y].register(
|
|
1039
1008
|
"SuperPumpRequiredTrouble",
|
|
1040
1009
|
// This is the trouble type
|
|
1041
1010
|
async (t) => {
|
|
@@ -1049,7 +1018,7 @@ const Wt = new b({
|
|
|
1049
1018
|
).map((i) => i.name).join(", ")
|
|
1050
1019
|
} : {};
|
|
1051
1020
|
}
|
|
1052
|
-
),
|
|
1021
|
+
), K[Y].register(
|
|
1053
1022
|
"MicroPumpAirDetectTrouble",
|
|
1054
1023
|
async (t) => {
|
|
1055
1024
|
if (t.ifaces.includes("container"))
|
|
@@ -1086,26 +1055,26 @@ y.legacy = h.model.registerLegacyModel(y);
|
|
|
1086
1055
|
const ar = y;
|
|
1087
1056
|
export {
|
|
1088
1057
|
Vt as A,
|
|
1089
|
-
|
|
1090
|
-
|
|
1058
|
+
pe as C,
|
|
1059
|
+
W as F,
|
|
1091
1060
|
F as I,
|
|
1092
1061
|
ar as K,
|
|
1093
1062
|
Ct as N,
|
|
1094
1063
|
re as R,
|
|
1095
1064
|
te as a,
|
|
1096
1065
|
R as b,
|
|
1097
|
-
|
|
1066
|
+
be as c,
|
|
1098
1067
|
se as d,
|
|
1099
1068
|
ne as e,
|
|
1100
1069
|
le as f,
|
|
1101
|
-
|
|
1070
|
+
ze as g,
|
|
1102
1071
|
Wt as h,
|
|
1103
|
-
|
|
1072
|
+
A as i,
|
|
1104
1073
|
ie as j,
|
|
1105
|
-
|
|
1074
|
+
wt as k,
|
|
1106
1075
|
Dt as l,
|
|
1107
1076
|
rr as m,
|
|
1108
1077
|
pt as n,
|
|
1109
1078
|
Jt as r
|
|
1110
1079
|
};
|
|
1111
|
-
//# sourceMappingURL=freestyle-registration-manager-
|
|
1080
|
+
//# sourceMappingURL=freestyle-registration-manager-CClN6mVr.js.map
|