@technova-tech/olive-proto-lib 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/accounts/accounts.js +11726 -0
- package/admin/admin.js +6902 -0
- package/audit/audit.js +984 -0
- package/bills/bills.js +2363 -0
- package/business/business.js +16432 -0
- package/google/protobuf/any.js +113 -0
- package/google/protobuf/struct.js +357 -0
- package/image/recognition.js +456 -0
- package/index.js +46 -0
- package/package.json +31 -0
- package/pos/transactions.js +2084 -0
- package/pos.v1/auth.js +1179 -0
- package/pos.v1/card-transactions.js +2473 -0
- package/pos.v1/eod.js +2416 -0
- package/pos.v1/merchants.js +1552 -0
- package/pos.v1/terminal-transactions.js +3792 -0
- package/pos.v1/terminal-types.js +3888 -0
- package/pos.v1/terminals.js +32605 -0
- package/pos.v1/transactions.js +2918 -0
- package/shared/response.js +233 -0
- package/storage/storage.js +476 -0
- package/terminal/terminal.js +12583 -0
- package/transfer/transfer.js +3609 -0
- package/types/accounts/accounts.d.ts +3943 -0
- package/types/admin/admin.d.ts +2348 -0
- package/types/audit/audit.d.ts +323 -0
- package/types/bills/bills.d.ts +731 -0
- package/types/business/business.d.ts +7630 -0
- package/types/google/protobuf/any.d.ts +27 -0
- package/types/google/protobuf/struct.d.ts +175 -0
- package/types/image/recognition.d.ts +147 -0
- package/types/index.d.ts +43 -0
- package/types/pos/transactions.d.ts +667 -0
- package/types/pos.v1/auth.d.ts +374 -0
- package/types/pos.v1/card-transactions.d.ts +808 -0
- package/types/pos.v1/eod.d.ts +819 -0
- package/types/pos.v1/merchants.d.ts +566 -0
- package/types/pos.v1/terminal-transactions.d.ts +1342 -0
- package/types/pos.v1/terminal-types.d.ts +1215 -0
- package/types/pos.v1/terminals.d.ts +11142 -0
- package/types/pos.v1/transactions.d.ts +1057 -0
- package/types/shared/response.d.ts +65 -0
- package/types/storage/storage.d.ts +153 -0
- package/types/terminal/terminal.d.ts +5482 -0
- package/types/transfer/transfer.d.ts +1148 -0
- package/types/users/users.d.ts +4336 -0
- package/types/verifications/verifications.d.ts +2952 -0
- package/users/users.js +12683 -0
- package/verifications/verifications.js +8194 -0
|
@@ -0,0 +1,3888 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
24
|
+
};
|
|
25
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
+
exports.com = void 0;
|
|
27
|
+
const pb_1 = __importStar(require("google-protobuf"));
|
|
28
|
+
const grpc_1 = __importStar(require("@grpc/grpc-js"));
|
|
29
|
+
var com;
|
|
30
|
+
(function (com) {
|
|
31
|
+
var pkg;
|
|
32
|
+
(function (pkg) {
|
|
33
|
+
var posv1;
|
|
34
|
+
(function (posv1) {
|
|
35
|
+
var terminalTypes;
|
|
36
|
+
(function (terminalTypes) {
|
|
37
|
+
class AddTerminalTypeRequest extends pb_1.Message {
|
|
38
|
+
#one_of_decls = [];
|
|
39
|
+
constructor(data) {
|
|
40
|
+
super();
|
|
41
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [11, 12], this.#one_of_decls);
|
|
42
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
43
|
+
if ("deviceType" in data && data.deviceType != undefined) {
|
|
44
|
+
this.deviceType = data.deviceType;
|
|
45
|
+
}
|
|
46
|
+
if ("manufacturer" in data && data.manufacturer != undefined) {
|
|
47
|
+
this.manufacturer = data.manufacturer;
|
|
48
|
+
}
|
|
49
|
+
if ("model" in data && data.model != undefined) {
|
|
50
|
+
this.model = data.model;
|
|
51
|
+
}
|
|
52
|
+
if ("price" in data && data.price != undefined) {
|
|
53
|
+
this.price = data.price;
|
|
54
|
+
}
|
|
55
|
+
if ("description" in data && data.description != undefined) {
|
|
56
|
+
this.description = data.description;
|
|
57
|
+
}
|
|
58
|
+
if ("technicalSpecifications" in data && data.technicalSpecifications != undefined) {
|
|
59
|
+
this.technicalSpecifications = data.technicalSpecifications;
|
|
60
|
+
}
|
|
61
|
+
if ("stockQuantity" in data && data.stockQuantity != undefined) {
|
|
62
|
+
this.stockQuantity = data.stockQuantity;
|
|
63
|
+
}
|
|
64
|
+
if ("minimumStock" in data && data.minimumStock != undefined) {
|
|
65
|
+
this.minimumStock = data.minimumStock;
|
|
66
|
+
}
|
|
67
|
+
if ("category" in data && data.category != undefined) {
|
|
68
|
+
this.category = data.category;
|
|
69
|
+
}
|
|
70
|
+
if ("firmwareVersion" in data && data.firmwareVersion != undefined) {
|
|
71
|
+
this.firmwareVersion = data.firmwareVersion;
|
|
72
|
+
}
|
|
73
|
+
if ("features" in data && data.features != undefined) {
|
|
74
|
+
this.features = data.features;
|
|
75
|
+
}
|
|
76
|
+
if ("compatibleSoftware" in data && data.compatibleSoftware != undefined) {
|
|
77
|
+
this.compatibleSoftware = data.compatibleSoftware;
|
|
78
|
+
}
|
|
79
|
+
if ("warrantyMonths" in data && data.warrantyMonths != undefined) {
|
|
80
|
+
this.warrantyMonths = data.warrantyMonths;
|
|
81
|
+
}
|
|
82
|
+
if ("createdBy" in data && data.createdBy != undefined) {
|
|
83
|
+
this.createdBy = data.createdBy;
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
get deviceType() {
|
|
88
|
+
return pb_1.Message.getFieldWithDefault(this, 1, "");
|
|
89
|
+
}
|
|
90
|
+
set deviceType(value) {
|
|
91
|
+
pb_1.Message.setField(this, 1, value);
|
|
92
|
+
}
|
|
93
|
+
get manufacturer() {
|
|
94
|
+
return pb_1.Message.getFieldWithDefault(this, 2, "");
|
|
95
|
+
}
|
|
96
|
+
set manufacturer(value) {
|
|
97
|
+
pb_1.Message.setField(this, 2, value);
|
|
98
|
+
}
|
|
99
|
+
get model() {
|
|
100
|
+
return pb_1.Message.getFieldWithDefault(this, 3, "");
|
|
101
|
+
}
|
|
102
|
+
set model(value) {
|
|
103
|
+
pb_1.Message.setField(this, 3, value);
|
|
104
|
+
}
|
|
105
|
+
get price() {
|
|
106
|
+
return pb_1.Message.getFieldWithDefault(this, 4, 0);
|
|
107
|
+
}
|
|
108
|
+
set price(value) {
|
|
109
|
+
pb_1.Message.setField(this, 4, value);
|
|
110
|
+
}
|
|
111
|
+
get description() {
|
|
112
|
+
return pb_1.Message.getFieldWithDefault(this, 5, "");
|
|
113
|
+
}
|
|
114
|
+
set description(value) {
|
|
115
|
+
pb_1.Message.setField(this, 5, value);
|
|
116
|
+
}
|
|
117
|
+
get technicalSpecifications() {
|
|
118
|
+
return pb_1.Message.getFieldWithDefault(this, 6, "");
|
|
119
|
+
}
|
|
120
|
+
set technicalSpecifications(value) {
|
|
121
|
+
pb_1.Message.setField(this, 6, value);
|
|
122
|
+
}
|
|
123
|
+
get stockQuantity() {
|
|
124
|
+
return pb_1.Message.getFieldWithDefault(this, 7, 0);
|
|
125
|
+
}
|
|
126
|
+
set stockQuantity(value) {
|
|
127
|
+
pb_1.Message.setField(this, 7, value);
|
|
128
|
+
}
|
|
129
|
+
get minimumStock() {
|
|
130
|
+
return pb_1.Message.getFieldWithDefault(this, 8, 0);
|
|
131
|
+
}
|
|
132
|
+
set minimumStock(value) {
|
|
133
|
+
pb_1.Message.setField(this, 8, value);
|
|
134
|
+
}
|
|
135
|
+
get category() {
|
|
136
|
+
return pb_1.Message.getFieldWithDefault(this, 9, "");
|
|
137
|
+
}
|
|
138
|
+
set category(value) {
|
|
139
|
+
pb_1.Message.setField(this, 9, value);
|
|
140
|
+
}
|
|
141
|
+
get firmwareVersion() {
|
|
142
|
+
return pb_1.Message.getFieldWithDefault(this, 10, "");
|
|
143
|
+
}
|
|
144
|
+
set firmwareVersion(value) {
|
|
145
|
+
pb_1.Message.setField(this, 10, value);
|
|
146
|
+
}
|
|
147
|
+
get features() {
|
|
148
|
+
return pb_1.Message.getFieldWithDefault(this, 11, []);
|
|
149
|
+
}
|
|
150
|
+
set features(value) {
|
|
151
|
+
pb_1.Message.setField(this, 11, value);
|
|
152
|
+
}
|
|
153
|
+
get compatibleSoftware() {
|
|
154
|
+
return pb_1.Message.getFieldWithDefault(this, 12, []);
|
|
155
|
+
}
|
|
156
|
+
set compatibleSoftware(value) {
|
|
157
|
+
pb_1.Message.setField(this, 12, value);
|
|
158
|
+
}
|
|
159
|
+
get warrantyMonths() {
|
|
160
|
+
return pb_1.Message.getFieldWithDefault(this, 13, 0);
|
|
161
|
+
}
|
|
162
|
+
set warrantyMonths(value) {
|
|
163
|
+
pb_1.Message.setField(this, 13, value);
|
|
164
|
+
}
|
|
165
|
+
get createdBy() {
|
|
166
|
+
return pb_1.Message.getFieldWithDefault(this, 14, "");
|
|
167
|
+
}
|
|
168
|
+
set createdBy(value) {
|
|
169
|
+
pb_1.Message.setField(this, 14, value);
|
|
170
|
+
}
|
|
171
|
+
static fromObject(data) {
|
|
172
|
+
const message = new AddTerminalTypeRequest({});
|
|
173
|
+
if (data.deviceType != null) {
|
|
174
|
+
message.deviceType = data.deviceType;
|
|
175
|
+
}
|
|
176
|
+
if (data.manufacturer != null) {
|
|
177
|
+
message.manufacturer = data.manufacturer;
|
|
178
|
+
}
|
|
179
|
+
if (data.model != null) {
|
|
180
|
+
message.model = data.model;
|
|
181
|
+
}
|
|
182
|
+
if (data.price != null) {
|
|
183
|
+
message.price = data.price;
|
|
184
|
+
}
|
|
185
|
+
if (data.description != null) {
|
|
186
|
+
message.description = data.description;
|
|
187
|
+
}
|
|
188
|
+
if (data.technicalSpecifications != null) {
|
|
189
|
+
message.technicalSpecifications = data.technicalSpecifications;
|
|
190
|
+
}
|
|
191
|
+
if (data.stockQuantity != null) {
|
|
192
|
+
message.stockQuantity = data.stockQuantity;
|
|
193
|
+
}
|
|
194
|
+
if (data.minimumStock != null) {
|
|
195
|
+
message.minimumStock = data.minimumStock;
|
|
196
|
+
}
|
|
197
|
+
if (data.category != null) {
|
|
198
|
+
message.category = data.category;
|
|
199
|
+
}
|
|
200
|
+
if (data.firmwareVersion != null) {
|
|
201
|
+
message.firmwareVersion = data.firmwareVersion;
|
|
202
|
+
}
|
|
203
|
+
if (data.features != null) {
|
|
204
|
+
message.features = data.features;
|
|
205
|
+
}
|
|
206
|
+
if (data.compatibleSoftware != null) {
|
|
207
|
+
message.compatibleSoftware = data.compatibleSoftware;
|
|
208
|
+
}
|
|
209
|
+
if (data.warrantyMonths != null) {
|
|
210
|
+
message.warrantyMonths = data.warrantyMonths;
|
|
211
|
+
}
|
|
212
|
+
if (data.createdBy != null) {
|
|
213
|
+
message.createdBy = data.createdBy;
|
|
214
|
+
}
|
|
215
|
+
return message;
|
|
216
|
+
}
|
|
217
|
+
toObject() {
|
|
218
|
+
const data = {};
|
|
219
|
+
if (this.deviceType != null) {
|
|
220
|
+
data.deviceType = this.deviceType;
|
|
221
|
+
}
|
|
222
|
+
if (this.manufacturer != null) {
|
|
223
|
+
data.manufacturer = this.manufacturer;
|
|
224
|
+
}
|
|
225
|
+
if (this.model != null) {
|
|
226
|
+
data.model = this.model;
|
|
227
|
+
}
|
|
228
|
+
if (this.price != null) {
|
|
229
|
+
data.price = this.price;
|
|
230
|
+
}
|
|
231
|
+
if (this.description != null) {
|
|
232
|
+
data.description = this.description;
|
|
233
|
+
}
|
|
234
|
+
if (this.technicalSpecifications != null) {
|
|
235
|
+
data.technicalSpecifications = this.technicalSpecifications;
|
|
236
|
+
}
|
|
237
|
+
if (this.stockQuantity != null) {
|
|
238
|
+
data.stockQuantity = this.stockQuantity;
|
|
239
|
+
}
|
|
240
|
+
if (this.minimumStock != null) {
|
|
241
|
+
data.minimumStock = this.minimumStock;
|
|
242
|
+
}
|
|
243
|
+
if (this.category != null) {
|
|
244
|
+
data.category = this.category;
|
|
245
|
+
}
|
|
246
|
+
if (this.firmwareVersion != null) {
|
|
247
|
+
data.firmwareVersion = this.firmwareVersion;
|
|
248
|
+
}
|
|
249
|
+
if (this.features != null) {
|
|
250
|
+
data.features = this.features;
|
|
251
|
+
}
|
|
252
|
+
if (this.compatibleSoftware != null) {
|
|
253
|
+
data.compatibleSoftware = this.compatibleSoftware;
|
|
254
|
+
}
|
|
255
|
+
if (this.warrantyMonths != null) {
|
|
256
|
+
data.warrantyMonths = this.warrantyMonths;
|
|
257
|
+
}
|
|
258
|
+
if (this.createdBy != null) {
|
|
259
|
+
data.createdBy = this.createdBy;
|
|
260
|
+
}
|
|
261
|
+
return data;
|
|
262
|
+
}
|
|
263
|
+
serialize(w) {
|
|
264
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
265
|
+
if (this.deviceType.length)
|
|
266
|
+
writer.writeString(1, this.deviceType);
|
|
267
|
+
if (this.manufacturer.length)
|
|
268
|
+
writer.writeString(2, this.manufacturer);
|
|
269
|
+
if (this.model.length)
|
|
270
|
+
writer.writeString(3, this.model);
|
|
271
|
+
if (this.price != 0)
|
|
272
|
+
writer.writeDouble(4, this.price);
|
|
273
|
+
if (this.description.length)
|
|
274
|
+
writer.writeString(5, this.description);
|
|
275
|
+
if (this.technicalSpecifications.length)
|
|
276
|
+
writer.writeString(6, this.technicalSpecifications);
|
|
277
|
+
if (this.stockQuantity != 0)
|
|
278
|
+
writer.writeInt32(7, this.stockQuantity);
|
|
279
|
+
if (this.minimumStock != 0)
|
|
280
|
+
writer.writeInt32(8, this.minimumStock);
|
|
281
|
+
if (this.category.length)
|
|
282
|
+
writer.writeString(9, this.category);
|
|
283
|
+
if (this.firmwareVersion.length)
|
|
284
|
+
writer.writeString(10, this.firmwareVersion);
|
|
285
|
+
if (this.features.length)
|
|
286
|
+
writer.writeRepeatedString(11, this.features);
|
|
287
|
+
if (this.compatibleSoftware.length)
|
|
288
|
+
writer.writeRepeatedString(12, this.compatibleSoftware);
|
|
289
|
+
if (this.warrantyMonths != 0)
|
|
290
|
+
writer.writeInt32(13, this.warrantyMonths);
|
|
291
|
+
if (this.createdBy.length)
|
|
292
|
+
writer.writeString(14, this.createdBy);
|
|
293
|
+
if (!w)
|
|
294
|
+
return writer.getResultBuffer();
|
|
295
|
+
}
|
|
296
|
+
static deserialize(bytes) {
|
|
297
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new AddTerminalTypeRequest();
|
|
298
|
+
while (reader.nextField()) {
|
|
299
|
+
if (reader.isEndGroup())
|
|
300
|
+
break;
|
|
301
|
+
switch (reader.getFieldNumber()) {
|
|
302
|
+
case 1:
|
|
303
|
+
message.deviceType = reader.readString();
|
|
304
|
+
break;
|
|
305
|
+
case 2:
|
|
306
|
+
message.manufacturer = reader.readString();
|
|
307
|
+
break;
|
|
308
|
+
case 3:
|
|
309
|
+
message.model = reader.readString();
|
|
310
|
+
break;
|
|
311
|
+
case 4:
|
|
312
|
+
message.price = reader.readDouble();
|
|
313
|
+
break;
|
|
314
|
+
case 5:
|
|
315
|
+
message.description = reader.readString();
|
|
316
|
+
break;
|
|
317
|
+
case 6:
|
|
318
|
+
message.technicalSpecifications = reader.readString();
|
|
319
|
+
break;
|
|
320
|
+
case 7:
|
|
321
|
+
message.stockQuantity = reader.readInt32();
|
|
322
|
+
break;
|
|
323
|
+
case 8:
|
|
324
|
+
message.minimumStock = reader.readInt32();
|
|
325
|
+
break;
|
|
326
|
+
case 9:
|
|
327
|
+
message.category = reader.readString();
|
|
328
|
+
break;
|
|
329
|
+
case 10:
|
|
330
|
+
message.firmwareVersion = reader.readString();
|
|
331
|
+
break;
|
|
332
|
+
case 11:
|
|
333
|
+
pb_1.Message.addToRepeatedField(message, 11, reader.readString());
|
|
334
|
+
break;
|
|
335
|
+
case 12:
|
|
336
|
+
pb_1.Message.addToRepeatedField(message, 12, reader.readString());
|
|
337
|
+
break;
|
|
338
|
+
case 13:
|
|
339
|
+
message.warrantyMonths = reader.readInt32();
|
|
340
|
+
break;
|
|
341
|
+
case 14:
|
|
342
|
+
message.createdBy = reader.readString();
|
|
343
|
+
break;
|
|
344
|
+
default: reader.skipField();
|
|
345
|
+
}
|
|
346
|
+
}
|
|
347
|
+
return message;
|
|
348
|
+
}
|
|
349
|
+
serializeBinary() {
|
|
350
|
+
return this.serialize();
|
|
351
|
+
}
|
|
352
|
+
static deserializeBinary(bytes) {
|
|
353
|
+
return AddTerminalTypeRequest.deserialize(bytes);
|
|
354
|
+
}
|
|
355
|
+
}
|
|
356
|
+
terminalTypes.AddTerminalTypeRequest = AddTerminalTypeRequest;
|
|
357
|
+
class GetTerminalTypesRequest extends pb_1.Message {
|
|
358
|
+
#one_of_decls = [];
|
|
359
|
+
constructor(data) {
|
|
360
|
+
super();
|
|
361
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
362
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
363
|
+
if ("status" in data && data.status != undefined) {
|
|
364
|
+
this.status = data.status;
|
|
365
|
+
}
|
|
366
|
+
if ("category" in data && data.category != undefined) {
|
|
367
|
+
this.category = data.category;
|
|
368
|
+
}
|
|
369
|
+
if ("manufacturer" in data && data.manufacturer != undefined) {
|
|
370
|
+
this.manufacturer = data.manufacturer;
|
|
371
|
+
}
|
|
372
|
+
if ("deviceType" in data && data.deviceType != undefined) {
|
|
373
|
+
this.deviceType = data.deviceType;
|
|
374
|
+
}
|
|
375
|
+
if ("priceMin" in data && data.priceMin != undefined) {
|
|
376
|
+
this.priceMin = data.priceMin;
|
|
377
|
+
}
|
|
378
|
+
if ("priceMax" in data && data.priceMax != undefined) {
|
|
379
|
+
this.priceMax = data.priceMax;
|
|
380
|
+
}
|
|
381
|
+
if ("inStock" in data && data.inStock != undefined) {
|
|
382
|
+
this.inStock = data.inStock;
|
|
383
|
+
}
|
|
384
|
+
}
|
|
385
|
+
}
|
|
386
|
+
get status() {
|
|
387
|
+
return pb_1.Message.getFieldWithDefault(this, 1, "");
|
|
388
|
+
}
|
|
389
|
+
set status(value) {
|
|
390
|
+
pb_1.Message.setField(this, 1, value);
|
|
391
|
+
}
|
|
392
|
+
get category() {
|
|
393
|
+
return pb_1.Message.getFieldWithDefault(this, 2, "");
|
|
394
|
+
}
|
|
395
|
+
set category(value) {
|
|
396
|
+
pb_1.Message.setField(this, 2, value);
|
|
397
|
+
}
|
|
398
|
+
get manufacturer() {
|
|
399
|
+
return pb_1.Message.getFieldWithDefault(this, 3, "");
|
|
400
|
+
}
|
|
401
|
+
set manufacturer(value) {
|
|
402
|
+
pb_1.Message.setField(this, 3, value);
|
|
403
|
+
}
|
|
404
|
+
get deviceType() {
|
|
405
|
+
return pb_1.Message.getFieldWithDefault(this, 4, "");
|
|
406
|
+
}
|
|
407
|
+
set deviceType(value) {
|
|
408
|
+
pb_1.Message.setField(this, 4, value);
|
|
409
|
+
}
|
|
410
|
+
get priceMin() {
|
|
411
|
+
return pb_1.Message.getFieldWithDefault(this, 5, 0);
|
|
412
|
+
}
|
|
413
|
+
set priceMin(value) {
|
|
414
|
+
pb_1.Message.setField(this, 5, value);
|
|
415
|
+
}
|
|
416
|
+
get priceMax() {
|
|
417
|
+
return pb_1.Message.getFieldWithDefault(this, 6, 0);
|
|
418
|
+
}
|
|
419
|
+
set priceMax(value) {
|
|
420
|
+
pb_1.Message.setField(this, 6, value);
|
|
421
|
+
}
|
|
422
|
+
get inStock() {
|
|
423
|
+
return pb_1.Message.getFieldWithDefault(this, 7, false);
|
|
424
|
+
}
|
|
425
|
+
set inStock(value) {
|
|
426
|
+
pb_1.Message.setField(this, 7, value);
|
|
427
|
+
}
|
|
428
|
+
static fromObject(data) {
|
|
429
|
+
const message = new GetTerminalTypesRequest({});
|
|
430
|
+
if (data.status != null) {
|
|
431
|
+
message.status = data.status;
|
|
432
|
+
}
|
|
433
|
+
if (data.category != null) {
|
|
434
|
+
message.category = data.category;
|
|
435
|
+
}
|
|
436
|
+
if (data.manufacturer != null) {
|
|
437
|
+
message.manufacturer = data.manufacturer;
|
|
438
|
+
}
|
|
439
|
+
if (data.deviceType != null) {
|
|
440
|
+
message.deviceType = data.deviceType;
|
|
441
|
+
}
|
|
442
|
+
if (data.priceMin != null) {
|
|
443
|
+
message.priceMin = data.priceMin;
|
|
444
|
+
}
|
|
445
|
+
if (data.priceMax != null) {
|
|
446
|
+
message.priceMax = data.priceMax;
|
|
447
|
+
}
|
|
448
|
+
if (data.inStock != null) {
|
|
449
|
+
message.inStock = data.inStock;
|
|
450
|
+
}
|
|
451
|
+
return message;
|
|
452
|
+
}
|
|
453
|
+
toObject() {
|
|
454
|
+
const data = {};
|
|
455
|
+
if (this.status != null) {
|
|
456
|
+
data.status = this.status;
|
|
457
|
+
}
|
|
458
|
+
if (this.category != null) {
|
|
459
|
+
data.category = this.category;
|
|
460
|
+
}
|
|
461
|
+
if (this.manufacturer != null) {
|
|
462
|
+
data.manufacturer = this.manufacturer;
|
|
463
|
+
}
|
|
464
|
+
if (this.deviceType != null) {
|
|
465
|
+
data.deviceType = this.deviceType;
|
|
466
|
+
}
|
|
467
|
+
if (this.priceMin != null) {
|
|
468
|
+
data.priceMin = this.priceMin;
|
|
469
|
+
}
|
|
470
|
+
if (this.priceMax != null) {
|
|
471
|
+
data.priceMax = this.priceMax;
|
|
472
|
+
}
|
|
473
|
+
if (this.inStock != null) {
|
|
474
|
+
data.inStock = this.inStock;
|
|
475
|
+
}
|
|
476
|
+
return data;
|
|
477
|
+
}
|
|
478
|
+
serialize(w) {
|
|
479
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
480
|
+
if (this.status.length)
|
|
481
|
+
writer.writeString(1, this.status);
|
|
482
|
+
if (this.category.length)
|
|
483
|
+
writer.writeString(2, this.category);
|
|
484
|
+
if (this.manufacturer.length)
|
|
485
|
+
writer.writeString(3, this.manufacturer);
|
|
486
|
+
if (this.deviceType.length)
|
|
487
|
+
writer.writeString(4, this.deviceType);
|
|
488
|
+
if (this.priceMin != 0)
|
|
489
|
+
writer.writeDouble(5, this.priceMin);
|
|
490
|
+
if (this.priceMax != 0)
|
|
491
|
+
writer.writeDouble(6, this.priceMax);
|
|
492
|
+
if (this.inStock != false)
|
|
493
|
+
writer.writeBool(7, this.inStock);
|
|
494
|
+
if (!w)
|
|
495
|
+
return writer.getResultBuffer();
|
|
496
|
+
}
|
|
497
|
+
static deserialize(bytes) {
|
|
498
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new GetTerminalTypesRequest();
|
|
499
|
+
while (reader.nextField()) {
|
|
500
|
+
if (reader.isEndGroup())
|
|
501
|
+
break;
|
|
502
|
+
switch (reader.getFieldNumber()) {
|
|
503
|
+
case 1:
|
|
504
|
+
message.status = reader.readString();
|
|
505
|
+
break;
|
|
506
|
+
case 2:
|
|
507
|
+
message.category = reader.readString();
|
|
508
|
+
break;
|
|
509
|
+
case 3:
|
|
510
|
+
message.manufacturer = reader.readString();
|
|
511
|
+
break;
|
|
512
|
+
case 4:
|
|
513
|
+
message.deviceType = reader.readString();
|
|
514
|
+
break;
|
|
515
|
+
case 5:
|
|
516
|
+
message.priceMin = reader.readDouble();
|
|
517
|
+
break;
|
|
518
|
+
case 6:
|
|
519
|
+
message.priceMax = reader.readDouble();
|
|
520
|
+
break;
|
|
521
|
+
case 7:
|
|
522
|
+
message.inStock = reader.readBool();
|
|
523
|
+
break;
|
|
524
|
+
default: reader.skipField();
|
|
525
|
+
}
|
|
526
|
+
}
|
|
527
|
+
return message;
|
|
528
|
+
}
|
|
529
|
+
serializeBinary() {
|
|
530
|
+
return this.serialize();
|
|
531
|
+
}
|
|
532
|
+
static deserializeBinary(bytes) {
|
|
533
|
+
return GetTerminalTypesRequest.deserialize(bytes);
|
|
534
|
+
}
|
|
535
|
+
}
|
|
536
|
+
terminalTypes.GetTerminalTypesRequest = GetTerminalTypesRequest;
|
|
537
|
+
class GetTerminalTypeByIdRequest extends pb_1.Message {
|
|
538
|
+
#one_of_decls = [];
|
|
539
|
+
constructor(data) {
|
|
540
|
+
super();
|
|
541
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
542
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
543
|
+
if ("id" in data && data.id != undefined) {
|
|
544
|
+
this.id = data.id;
|
|
545
|
+
}
|
|
546
|
+
}
|
|
547
|
+
}
|
|
548
|
+
get id() {
|
|
549
|
+
return pb_1.Message.getFieldWithDefault(this, 1, "");
|
|
550
|
+
}
|
|
551
|
+
set id(value) {
|
|
552
|
+
pb_1.Message.setField(this, 1, value);
|
|
553
|
+
}
|
|
554
|
+
static fromObject(data) {
|
|
555
|
+
const message = new GetTerminalTypeByIdRequest({});
|
|
556
|
+
if (data.id != null) {
|
|
557
|
+
message.id = data.id;
|
|
558
|
+
}
|
|
559
|
+
return message;
|
|
560
|
+
}
|
|
561
|
+
toObject() {
|
|
562
|
+
const data = {};
|
|
563
|
+
if (this.id != null) {
|
|
564
|
+
data.id = this.id;
|
|
565
|
+
}
|
|
566
|
+
return data;
|
|
567
|
+
}
|
|
568
|
+
serialize(w) {
|
|
569
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
570
|
+
if (this.id.length)
|
|
571
|
+
writer.writeString(1, this.id);
|
|
572
|
+
if (!w)
|
|
573
|
+
return writer.getResultBuffer();
|
|
574
|
+
}
|
|
575
|
+
static deserialize(bytes) {
|
|
576
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new GetTerminalTypeByIdRequest();
|
|
577
|
+
while (reader.nextField()) {
|
|
578
|
+
if (reader.isEndGroup())
|
|
579
|
+
break;
|
|
580
|
+
switch (reader.getFieldNumber()) {
|
|
581
|
+
case 1:
|
|
582
|
+
message.id = reader.readString();
|
|
583
|
+
break;
|
|
584
|
+
default: reader.skipField();
|
|
585
|
+
}
|
|
586
|
+
}
|
|
587
|
+
return message;
|
|
588
|
+
}
|
|
589
|
+
serializeBinary() {
|
|
590
|
+
return this.serialize();
|
|
591
|
+
}
|
|
592
|
+
static deserializeBinary(bytes) {
|
|
593
|
+
return GetTerminalTypeByIdRequest.deserialize(bytes);
|
|
594
|
+
}
|
|
595
|
+
}
|
|
596
|
+
terminalTypes.GetTerminalTypeByIdRequest = GetTerminalTypeByIdRequest;
|
|
597
|
+
class UpdateTerminalTypeRequest extends pb_1.Message {
|
|
598
|
+
#one_of_decls = [];
|
|
599
|
+
constructor(data) {
|
|
600
|
+
super();
|
|
601
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [9, 10], this.#one_of_decls);
|
|
602
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
603
|
+
if ("id" in data && data.id != undefined) {
|
|
604
|
+
this.id = data.id;
|
|
605
|
+
}
|
|
606
|
+
if ("price" in data && data.price != undefined) {
|
|
607
|
+
this.price = data.price;
|
|
608
|
+
}
|
|
609
|
+
if ("status" in data && data.status != undefined) {
|
|
610
|
+
this.status = data.status;
|
|
611
|
+
}
|
|
612
|
+
if ("description" in data && data.description != undefined) {
|
|
613
|
+
this.description = data.description;
|
|
614
|
+
}
|
|
615
|
+
if ("technicalSpecifications" in data && data.technicalSpecifications != undefined) {
|
|
616
|
+
this.technicalSpecifications = data.technicalSpecifications;
|
|
617
|
+
}
|
|
618
|
+
if ("stockQuantity" in data && data.stockQuantity != undefined) {
|
|
619
|
+
this.stockQuantity = data.stockQuantity;
|
|
620
|
+
}
|
|
621
|
+
if ("minimumStock" in data && data.minimumStock != undefined) {
|
|
622
|
+
this.minimumStock = data.minimumStock;
|
|
623
|
+
}
|
|
624
|
+
if ("firmwareVersion" in data && data.firmwareVersion != undefined) {
|
|
625
|
+
this.firmwareVersion = data.firmwareVersion;
|
|
626
|
+
}
|
|
627
|
+
if ("features" in data && data.features != undefined) {
|
|
628
|
+
this.features = data.features;
|
|
629
|
+
}
|
|
630
|
+
if ("compatibleSoftware" in data && data.compatibleSoftware != undefined) {
|
|
631
|
+
this.compatibleSoftware = data.compatibleSoftware;
|
|
632
|
+
}
|
|
633
|
+
if ("warrantyMonths" in data && data.warrantyMonths != undefined) {
|
|
634
|
+
this.warrantyMonths = data.warrantyMonths;
|
|
635
|
+
}
|
|
636
|
+
if ("discontinuedReason" in data && data.discontinuedReason != undefined) {
|
|
637
|
+
this.discontinuedReason = data.discontinuedReason;
|
|
638
|
+
}
|
|
639
|
+
if ("updatedBy" in data && data.updatedBy != undefined) {
|
|
640
|
+
this.updatedBy = data.updatedBy;
|
|
641
|
+
}
|
|
642
|
+
}
|
|
643
|
+
}
|
|
644
|
+
get id() {
|
|
645
|
+
return pb_1.Message.getFieldWithDefault(this, 1, "");
|
|
646
|
+
}
|
|
647
|
+
set id(value) {
|
|
648
|
+
pb_1.Message.setField(this, 1, value);
|
|
649
|
+
}
|
|
650
|
+
get price() {
|
|
651
|
+
return pb_1.Message.getFieldWithDefault(this, 2, 0);
|
|
652
|
+
}
|
|
653
|
+
set price(value) {
|
|
654
|
+
pb_1.Message.setField(this, 2, value);
|
|
655
|
+
}
|
|
656
|
+
get status() {
|
|
657
|
+
return pb_1.Message.getFieldWithDefault(this, 3, "");
|
|
658
|
+
}
|
|
659
|
+
set status(value) {
|
|
660
|
+
pb_1.Message.setField(this, 3, value);
|
|
661
|
+
}
|
|
662
|
+
get description() {
|
|
663
|
+
return pb_1.Message.getFieldWithDefault(this, 4, "");
|
|
664
|
+
}
|
|
665
|
+
set description(value) {
|
|
666
|
+
pb_1.Message.setField(this, 4, value);
|
|
667
|
+
}
|
|
668
|
+
get technicalSpecifications() {
|
|
669
|
+
return pb_1.Message.getFieldWithDefault(this, 5, "");
|
|
670
|
+
}
|
|
671
|
+
set technicalSpecifications(value) {
|
|
672
|
+
pb_1.Message.setField(this, 5, value);
|
|
673
|
+
}
|
|
674
|
+
get stockQuantity() {
|
|
675
|
+
return pb_1.Message.getFieldWithDefault(this, 6, 0);
|
|
676
|
+
}
|
|
677
|
+
set stockQuantity(value) {
|
|
678
|
+
pb_1.Message.setField(this, 6, value);
|
|
679
|
+
}
|
|
680
|
+
get minimumStock() {
|
|
681
|
+
return pb_1.Message.getFieldWithDefault(this, 7, 0);
|
|
682
|
+
}
|
|
683
|
+
set minimumStock(value) {
|
|
684
|
+
pb_1.Message.setField(this, 7, value);
|
|
685
|
+
}
|
|
686
|
+
get firmwareVersion() {
|
|
687
|
+
return pb_1.Message.getFieldWithDefault(this, 8, "");
|
|
688
|
+
}
|
|
689
|
+
set firmwareVersion(value) {
|
|
690
|
+
pb_1.Message.setField(this, 8, value);
|
|
691
|
+
}
|
|
692
|
+
get features() {
|
|
693
|
+
return pb_1.Message.getFieldWithDefault(this, 9, []);
|
|
694
|
+
}
|
|
695
|
+
set features(value) {
|
|
696
|
+
pb_1.Message.setField(this, 9, value);
|
|
697
|
+
}
|
|
698
|
+
get compatibleSoftware() {
|
|
699
|
+
return pb_1.Message.getFieldWithDefault(this, 10, []);
|
|
700
|
+
}
|
|
701
|
+
set compatibleSoftware(value) {
|
|
702
|
+
pb_1.Message.setField(this, 10, value);
|
|
703
|
+
}
|
|
704
|
+
get warrantyMonths() {
|
|
705
|
+
return pb_1.Message.getFieldWithDefault(this, 11, 0);
|
|
706
|
+
}
|
|
707
|
+
set warrantyMonths(value) {
|
|
708
|
+
pb_1.Message.setField(this, 11, value);
|
|
709
|
+
}
|
|
710
|
+
get discontinuedReason() {
|
|
711
|
+
return pb_1.Message.getFieldWithDefault(this, 12, "");
|
|
712
|
+
}
|
|
713
|
+
set discontinuedReason(value) {
|
|
714
|
+
pb_1.Message.setField(this, 12, value);
|
|
715
|
+
}
|
|
716
|
+
get updatedBy() {
|
|
717
|
+
return pb_1.Message.getFieldWithDefault(this, 13, "");
|
|
718
|
+
}
|
|
719
|
+
set updatedBy(value) {
|
|
720
|
+
pb_1.Message.setField(this, 13, value);
|
|
721
|
+
}
|
|
722
|
+
static fromObject(data) {
|
|
723
|
+
const message = new UpdateTerminalTypeRequest({});
|
|
724
|
+
if (data.id != null) {
|
|
725
|
+
message.id = data.id;
|
|
726
|
+
}
|
|
727
|
+
if (data.price != null) {
|
|
728
|
+
message.price = data.price;
|
|
729
|
+
}
|
|
730
|
+
if (data.status != null) {
|
|
731
|
+
message.status = data.status;
|
|
732
|
+
}
|
|
733
|
+
if (data.description != null) {
|
|
734
|
+
message.description = data.description;
|
|
735
|
+
}
|
|
736
|
+
if (data.technicalSpecifications != null) {
|
|
737
|
+
message.technicalSpecifications = data.technicalSpecifications;
|
|
738
|
+
}
|
|
739
|
+
if (data.stockQuantity != null) {
|
|
740
|
+
message.stockQuantity = data.stockQuantity;
|
|
741
|
+
}
|
|
742
|
+
if (data.minimumStock != null) {
|
|
743
|
+
message.minimumStock = data.minimumStock;
|
|
744
|
+
}
|
|
745
|
+
if (data.firmwareVersion != null) {
|
|
746
|
+
message.firmwareVersion = data.firmwareVersion;
|
|
747
|
+
}
|
|
748
|
+
if (data.features != null) {
|
|
749
|
+
message.features = data.features;
|
|
750
|
+
}
|
|
751
|
+
if (data.compatibleSoftware != null) {
|
|
752
|
+
message.compatibleSoftware = data.compatibleSoftware;
|
|
753
|
+
}
|
|
754
|
+
if (data.warrantyMonths != null) {
|
|
755
|
+
message.warrantyMonths = data.warrantyMonths;
|
|
756
|
+
}
|
|
757
|
+
if (data.discontinuedReason != null) {
|
|
758
|
+
message.discontinuedReason = data.discontinuedReason;
|
|
759
|
+
}
|
|
760
|
+
if (data.updatedBy != null) {
|
|
761
|
+
message.updatedBy = data.updatedBy;
|
|
762
|
+
}
|
|
763
|
+
return message;
|
|
764
|
+
}
|
|
765
|
+
toObject() {
|
|
766
|
+
const data = {};
|
|
767
|
+
if (this.id != null) {
|
|
768
|
+
data.id = this.id;
|
|
769
|
+
}
|
|
770
|
+
if (this.price != null) {
|
|
771
|
+
data.price = this.price;
|
|
772
|
+
}
|
|
773
|
+
if (this.status != null) {
|
|
774
|
+
data.status = this.status;
|
|
775
|
+
}
|
|
776
|
+
if (this.description != null) {
|
|
777
|
+
data.description = this.description;
|
|
778
|
+
}
|
|
779
|
+
if (this.technicalSpecifications != null) {
|
|
780
|
+
data.technicalSpecifications = this.technicalSpecifications;
|
|
781
|
+
}
|
|
782
|
+
if (this.stockQuantity != null) {
|
|
783
|
+
data.stockQuantity = this.stockQuantity;
|
|
784
|
+
}
|
|
785
|
+
if (this.minimumStock != null) {
|
|
786
|
+
data.minimumStock = this.minimumStock;
|
|
787
|
+
}
|
|
788
|
+
if (this.firmwareVersion != null) {
|
|
789
|
+
data.firmwareVersion = this.firmwareVersion;
|
|
790
|
+
}
|
|
791
|
+
if (this.features != null) {
|
|
792
|
+
data.features = this.features;
|
|
793
|
+
}
|
|
794
|
+
if (this.compatibleSoftware != null) {
|
|
795
|
+
data.compatibleSoftware = this.compatibleSoftware;
|
|
796
|
+
}
|
|
797
|
+
if (this.warrantyMonths != null) {
|
|
798
|
+
data.warrantyMonths = this.warrantyMonths;
|
|
799
|
+
}
|
|
800
|
+
if (this.discontinuedReason != null) {
|
|
801
|
+
data.discontinuedReason = this.discontinuedReason;
|
|
802
|
+
}
|
|
803
|
+
if (this.updatedBy != null) {
|
|
804
|
+
data.updatedBy = this.updatedBy;
|
|
805
|
+
}
|
|
806
|
+
return data;
|
|
807
|
+
}
|
|
808
|
+
serialize(w) {
|
|
809
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
810
|
+
if (this.id.length)
|
|
811
|
+
writer.writeString(1, this.id);
|
|
812
|
+
if (this.price != 0)
|
|
813
|
+
writer.writeDouble(2, this.price);
|
|
814
|
+
if (this.status.length)
|
|
815
|
+
writer.writeString(3, this.status);
|
|
816
|
+
if (this.description.length)
|
|
817
|
+
writer.writeString(4, this.description);
|
|
818
|
+
if (this.technicalSpecifications.length)
|
|
819
|
+
writer.writeString(5, this.technicalSpecifications);
|
|
820
|
+
if (this.stockQuantity != 0)
|
|
821
|
+
writer.writeInt32(6, this.stockQuantity);
|
|
822
|
+
if (this.minimumStock != 0)
|
|
823
|
+
writer.writeInt32(7, this.minimumStock);
|
|
824
|
+
if (this.firmwareVersion.length)
|
|
825
|
+
writer.writeString(8, this.firmwareVersion);
|
|
826
|
+
if (this.features.length)
|
|
827
|
+
writer.writeRepeatedString(9, this.features);
|
|
828
|
+
if (this.compatibleSoftware.length)
|
|
829
|
+
writer.writeRepeatedString(10, this.compatibleSoftware);
|
|
830
|
+
if (this.warrantyMonths != 0)
|
|
831
|
+
writer.writeInt32(11, this.warrantyMonths);
|
|
832
|
+
if (this.discontinuedReason.length)
|
|
833
|
+
writer.writeString(12, this.discontinuedReason);
|
|
834
|
+
if (this.updatedBy.length)
|
|
835
|
+
writer.writeString(13, this.updatedBy);
|
|
836
|
+
if (!w)
|
|
837
|
+
return writer.getResultBuffer();
|
|
838
|
+
}
|
|
839
|
+
static deserialize(bytes) {
|
|
840
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new UpdateTerminalTypeRequest();
|
|
841
|
+
while (reader.nextField()) {
|
|
842
|
+
if (reader.isEndGroup())
|
|
843
|
+
break;
|
|
844
|
+
switch (reader.getFieldNumber()) {
|
|
845
|
+
case 1:
|
|
846
|
+
message.id = reader.readString();
|
|
847
|
+
break;
|
|
848
|
+
case 2:
|
|
849
|
+
message.price = reader.readDouble();
|
|
850
|
+
break;
|
|
851
|
+
case 3:
|
|
852
|
+
message.status = reader.readString();
|
|
853
|
+
break;
|
|
854
|
+
case 4:
|
|
855
|
+
message.description = reader.readString();
|
|
856
|
+
break;
|
|
857
|
+
case 5:
|
|
858
|
+
message.technicalSpecifications = reader.readString();
|
|
859
|
+
break;
|
|
860
|
+
case 6:
|
|
861
|
+
message.stockQuantity = reader.readInt32();
|
|
862
|
+
break;
|
|
863
|
+
case 7:
|
|
864
|
+
message.minimumStock = reader.readInt32();
|
|
865
|
+
break;
|
|
866
|
+
case 8:
|
|
867
|
+
message.firmwareVersion = reader.readString();
|
|
868
|
+
break;
|
|
869
|
+
case 9:
|
|
870
|
+
pb_1.Message.addToRepeatedField(message, 9, reader.readString());
|
|
871
|
+
break;
|
|
872
|
+
case 10:
|
|
873
|
+
pb_1.Message.addToRepeatedField(message, 10, reader.readString());
|
|
874
|
+
break;
|
|
875
|
+
case 11:
|
|
876
|
+
message.warrantyMonths = reader.readInt32();
|
|
877
|
+
break;
|
|
878
|
+
case 12:
|
|
879
|
+
message.discontinuedReason = reader.readString();
|
|
880
|
+
break;
|
|
881
|
+
case 13:
|
|
882
|
+
message.updatedBy = reader.readString();
|
|
883
|
+
break;
|
|
884
|
+
default: reader.skipField();
|
|
885
|
+
}
|
|
886
|
+
}
|
|
887
|
+
return message;
|
|
888
|
+
}
|
|
889
|
+
serializeBinary() {
|
|
890
|
+
return this.serialize();
|
|
891
|
+
}
|
|
892
|
+
static deserializeBinary(bytes) {
|
|
893
|
+
return UpdateTerminalTypeRequest.deserialize(bytes);
|
|
894
|
+
}
|
|
895
|
+
}
|
|
896
|
+
terminalTypes.UpdateTerminalTypeRequest = UpdateTerminalTypeRequest;
|
|
897
|
+
class DiscontinueTypeRequest extends pb_1.Message {
|
|
898
|
+
#one_of_decls = [];
|
|
899
|
+
constructor(data) {
|
|
900
|
+
super();
|
|
901
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
902
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
903
|
+
if ("id" in data && data.id != undefined) {
|
|
904
|
+
this.id = data.id;
|
|
905
|
+
}
|
|
906
|
+
if ("reason" in data && data.reason != undefined) {
|
|
907
|
+
this.reason = data.reason;
|
|
908
|
+
}
|
|
909
|
+
if ("discontinuedBy" in data && data.discontinuedBy != undefined) {
|
|
910
|
+
this.discontinuedBy = data.discontinuedBy;
|
|
911
|
+
}
|
|
912
|
+
}
|
|
913
|
+
}
|
|
914
|
+
get id() {
|
|
915
|
+
return pb_1.Message.getFieldWithDefault(this, 1, "");
|
|
916
|
+
}
|
|
917
|
+
set id(value) {
|
|
918
|
+
pb_1.Message.setField(this, 1, value);
|
|
919
|
+
}
|
|
920
|
+
get reason() {
|
|
921
|
+
return pb_1.Message.getFieldWithDefault(this, 2, "");
|
|
922
|
+
}
|
|
923
|
+
set reason(value) {
|
|
924
|
+
pb_1.Message.setField(this, 2, value);
|
|
925
|
+
}
|
|
926
|
+
get discontinuedBy() {
|
|
927
|
+
return pb_1.Message.getFieldWithDefault(this, 3, "");
|
|
928
|
+
}
|
|
929
|
+
set discontinuedBy(value) {
|
|
930
|
+
pb_1.Message.setField(this, 3, value);
|
|
931
|
+
}
|
|
932
|
+
static fromObject(data) {
|
|
933
|
+
const message = new DiscontinueTypeRequest({});
|
|
934
|
+
if (data.id != null) {
|
|
935
|
+
message.id = data.id;
|
|
936
|
+
}
|
|
937
|
+
if (data.reason != null) {
|
|
938
|
+
message.reason = data.reason;
|
|
939
|
+
}
|
|
940
|
+
if (data.discontinuedBy != null) {
|
|
941
|
+
message.discontinuedBy = data.discontinuedBy;
|
|
942
|
+
}
|
|
943
|
+
return message;
|
|
944
|
+
}
|
|
945
|
+
toObject() {
|
|
946
|
+
const data = {};
|
|
947
|
+
if (this.id != null) {
|
|
948
|
+
data.id = this.id;
|
|
949
|
+
}
|
|
950
|
+
if (this.reason != null) {
|
|
951
|
+
data.reason = this.reason;
|
|
952
|
+
}
|
|
953
|
+
if (this.discontinuedBy != null) {
|
|
954
|
+
data.discontinuedBy = this.discontinuedBy;
|
|
955
|
+
}
|
|
956
|
+
return data;
|
|
957
|
+
}
|
|
958
|
+
serialize(w) {
|
|
959
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
960
|
+
if (this.id.length)
|
|
961
|
+
writer.writeString(1, this.id);
|
|
962
|
+
if (this.reason.length)
|
|
963
|
+
writer.writeString(2, this.reason);
|
|
964
|
+
if (this.discontinuedBy.length)
|
|
965
|
+
writer.writeString(3, this.discontinuedBy);
|
|
966
|
+
if (!w)
|
|
967
|
+
return writer.getResultBuffer();
|
|
968
|
+
}
|
|
969
|
+
static deserialize(bytes) {
|
|
970
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new DiscontinueTypeRequest();
|
|
971
|
+
while (reader.nextField()) {
|
|
972
|
+
if (reader.isEndGroup())
|
|
973
|
+
break;
|
|
974
|
+
switch (reader.getFieldNumber()) {
|
|
975
|
+
case 1:
|
|
976
|
+
message.id = reader.readString();
|
|
977
|
+
break;
|
|
978
|
+
case 2:
|
|
979
|
+
message.reason = reader.readString();
|
|
980
|
+
break;
|
|
981
|
+
case 3:
|
|
982
|
+
message.discontinuedBy = reader.readString();
|
|
983
|
+
break;
|
|
984
|
+
default: reader.skipField();
|
|
985
|
+
}
|
|
986
|
+
}
|
|
987
|
+
return message;
|
|
988
|
+
}
|
|
989
|
+
serializeBinary() {
|
|
990
|
+
return this.serialize();
|
|
991
|
+
}
|
|
992
|
+
static deserializeBinary(bytes) {
|
|
993
|
+
return DiscontinueTypeRequest.deserialize(bytes);
|
|
994
|
+
}
|
|
995
|
+
}
|
|
996
|
+
terminalTypes.DiscontinueTypeRequest = DiscontinueTypeRequest;
|
|
997
|
+
class UpdateStockRequest extends pb_1.Message {
|
|
998
|
+
#one_of_decls = [];
|
|
999
|
+
constructor(data) {
|
|
1000
|
+
super();
|
|
1001
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
1002
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
1003
|
+
if ("id" in data && data.id != undefined) {
|
|
1004
|
+
this.id = data.id;
|
|
1005
|
+
}
|
|
1006
|
+
if ("quantity" in data && data.quantity != undefined) {
|
|
1007
|
+
this.quantity = data.quantity;
|
|
1008
|
+
}
|
|
1009
|
+
if ("updatedBy" in data && data.updatedBy != undefined) {
|
|
1010
|
+
this.updatedBy = data.updatedBy;
|
|
1011
|
+
}
|
|
1012
|
+
}
|
|
1013
|
+
}
|
|
1014
|
+
get id() {
|
|
1015
|
+
return pb_1.Message.getFieldWithDefault(this, 1, "");
|
|
1016
|
+
}
|
|
1017
|
+
set id(value) {
|
|
1018
|
+
pb_1.Message.setField(this, 1, value);
|
|
1019
|
+
}
|
|
1020
|
+
get quantity() {
|
|
1021
|
+
return pb_1.Message.getFieldWithDefault(this, 2, 0);
|
|
1022
|
+
}
|
|
1023
|
+
set quantity(value) {
|
|
1024
|
+
pb_1.Message.setField(this, 2, value);
|
|
1025
|
+
}
|
|
1026
|
+
get updatedBy() {
|
|
1027
|
+
return pb_1.Message.getFieldWithDefault(this, 3, "");
|
|
1028
|
+
}
|
|
1029
|
+
set updatedBy(value) {
|
|
1030
|
+
pb_1.Message.setField(this, 3, value);
|
|
1031
|
+
}
|
|
1032
|
+
static fromObject(data) {
|
|
1033
|
+
const message = new UpdateStockRequest({});
|
|
1034
|
+
if (data.id != null) {
|
|
1035
|
+
message.id = data.id;
|
|
1036
|
+
}
|
|
1037
|
+
if (data.quantity != null) {
|
|
1038
|
+
message.quantity = data.quantity;
|
|
1039
|
+
}
|
|
1040
|
+
if (data.updatedBy != null) {
|
|
1041
|
+
message.updatedBy = data.updatedBy;
|
|
1042
|
+
}
|
|
1043
|
+
return message;
|
|
1044
|
+
}
|
|
1045
|
+
toObject() {
|
|
1046
|
+
const data = {};
|
|
1047
|
+
if (this.id != null) {
|
|
1048
|
+
data.id = this.id;
|
|
1049
|
+
}
|
|
1050
|
+
if (this.quantity != null) {
|
|
1051
|
+
data.quantity = this.quantity;
|
|
1052
|
+
}
|
|
1053
|
+
if (this.updatedBy != null) {
|
|
1054
|
+
data.updatedBy = this.updatedBy;
|
|
1055
|
+
}
|
|
1056
|
+
return data;
|
|
1057
|
+
}
|
|
1058
|
+
serialize(w) {
|
|
1059
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
1060
|
+
if (this.id.length)
|
|
1061
|
+
writer.writeString(1, this.id);
|
|
1062
|
+
if (this.quantity != 0)
|
|
1063
|
+
writer.writeInt32(2, this.quantity);
|
|
1064
|
+
if (this.updatedBy.length)
|
|
1065
|
+
writer.writeString(3, this.updatedBy);
|
|
1066
|
+
if (!w)
|
|
1067
|
+
return writer.getResultBuffer();
|
|
1068
|
+
}
|
|
1069
|
+
static deserialize(bytes) {
|
|
1070
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new UpdateStockRequest();
|
|
1071
|
+
while (reader.nextField()) {
|
|
1072
|
+
if (reader.isEndGroup())
|
|
1073
|
+
break;
|
|
1074
|
+
switch (reader.getFieldNumber()) {
|
|
1075
|
+
case 1:
|
|
1076
|
+
message.id = reader.readString();
|
|
1077
|
+
break;
|
|
1078
|
+
case 2:
|
|
1079
|
+
message.quantity = reader.readInt32();
|
|
1080
|
+
break;
|
|
1081
|
+
case 3:
|
|
1082
|
+
message.updatedBy = reader.readString();
|
|
1083
|
+
break;
|
|
1084
|
+
default: reader.skipField();
|
|
1085
|
+
}
|
|
1086
|
+
}
|
|
1087
|
+
return message;
|
|
1088
|
+
}
|
|
1089
|
+
serializeBinary() {
|
|
1090
|
+
return this.serialize();
|
|
1091
|
+
}
|
|
1092
|
+
static deserializeBinary(bytes) {
|
|
1093
|
+
return UpdateStockRequest.deserialize(bytes);
|
|
1094
|
+
}
|
|
1095
|
+
}
|
|
1096
|
+
terminalTypes.UpdateStockRequest = UpdateStockRequest;
|
|
1097
|
+
class ReserveStockRequest extends pb_1.Message {
|
|
1098
|
+
#one_of_decls = [];
|
|
1099
|
+
constructor(data) {
|
|
1100
|
+
super();
|
|
1101
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
1102
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
1103
|
+
if ("deviceType" in data && data.deviceType != undefined) {
|
|
1104
|
+
this.deviceType = data.deviceType;
|
|
1105
|
+
}
|
|
1106
|
+
if ("quantity" in data && data.quantity != undefined) {
|
|
1107
|
+
this.quantity = data.quantity;
|
|
1108
|
+
}
|
|
1109
|
+
if ("reservedBy" in data && data.reservedBy != undefined) {
|
|
1110
|
+
this.reservedBy = data.reservedBy;
|
|
1111
|
+
}
|
|
1112
|
+
}
|
|
1113
|
+
}
|
|
1114
|
+
get deviceType() {
|
|
1115
|
+
return pb_1.Message.getFieldWithDefault(this, 1, "");
|
|
1116
|
+
}
|
|
1117
|
+
set deviceType(value) {
|
|
1118
|
+
pb_1.Message.setField(this, 1, value);
|
|
1119
|
+
}
|
|
1120
|
+
get quantity() {
|
|
1121
|
+
return pb_1.Message.getFieldWithDefault(this, 2, 0);
|
|
1122
|
+
}
|
|
1123
|
+
set quantity(value) {
|
|
1124
|
+
pb_1.Message.setField(this, 2, value);
|
|
1125
|
+
}
|
|
1126
|
+
get reservedBy() {
|
|
1127
|
+
return pb_1.Message.getFieldWithDefault(this, 3, "");
|
|
1128
|
+
}
|
|
1129
|
+
set reservedBy(value) {
|
|
1130
|
+
pb_1.Message.setField(this, 3, value);
|
|
1131
|
+
}
|
|
1132
|
+
static fromObject(data) {
|
|
1133
|
+
const message = new ReserveStockRequest({});
|
|
1134
|
+
if (data.deviceType != null) {
|
|
1135
|
+
message.deviceType = data.deviceType;
|
|
1136
|
+
}
|
|
1137
|
+
if (data.quantity != null) {
|
|
1138
|
+
message.quantity = data.quantity;
|
|
1139
|
+
}
|
|
1140
|
+
if (data.reservedBy != null) {
|
|
1141
|
+
message.reservedBy = data.reservedBy;
|
|
1142
|
+
}
|
|
1143
|
+
return message;
|
|
1144
|
+
}
|
|
1145
|
+
toObject() {
|
|
1146
|
+
const data = {};
|
|
1147
|
+
if (this.deviceType != null) {
|
|
1148
|
+
data.deviceType = this.deviceType;
|
|
1149
|
+
}
|
|
1150
|
+
if (this.quantity != null) {
|
|
1151
|
+
data.quantity = this.quantity;
|
|
1152
|
+
}
|
|
1153
|
+
if (this.reservedBy != null) {
|
|
1154
|
+
data.reservedBy = this.reservedBy;
|
|
1155
|
+
}
|
|
1156
|
+
return data;
|
|
1157
|
+
}
|
|
1158
|
+
serialize(w) {
|
|
1159
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
1160
|
+
if (this.deviceType.length)
|
|
1161
|
+
writer.writeString(1, this.deviceType);
|
|
1162
|
+
if (this.quantity != 0)
|
|
1163
|
+
writer.writeInt32(2, this.quantity);
|
|
1164
|
+
if (this.reservedBy.length)
|
|
1165
|
+
writer.writeString(3, this.reservedBy);
|
|
1166
|
+
if (!w)
|
|
1167
|
+
return writer.getResultBuffer();
|
|
1168
|
+
}
|
|
1169
|
+
static deserialize(bytes) {
|
|
1170
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new ReserveStockRequest();
|
|
1171
|
+
while (reader.nextField()) {
|
|
1172
|
+
if (reader.isEndGroup())
|
|
1173
|
+
break;
|
|
1174
|
+
switch (reader.getFieldNumber()) {
|
|
1175
|
+
case 1:
|
|
1176
|
+
message.deviceType = reader.readString();
|
|
1177
|
+
break;
|
|
1178
|
+
case 2:
|
|
1179
|
+
message.quantity = reader.readInt32();
|
|
1180
|
+
break;
|
|
1181
|
+
case 3:
|
|
1182
|
+
message.reservedBy = reader.readString();
|
|
1183
|
+
break;
|
|
1184
|
+
default: reader.skipField();
|
|
1185
|
+
}
|
|
1186
|
+
}
|
|
1187
|
+
return message;
|
|
1188
|
+
}
|
|
1189
|
+
serializeBinary() {
|
|
1190
|
+
return this.serialize();
|
|
1191
|
+
}
|
|
1192
|
+
static deserializeBinary(bytes) {
|
|
1193
|
+
return ReserveStockRequest.deserialize(bytes);
|
|
1194
|
+
}
|
|
1195
|
+
}
|
|
1196
|
+
terminalTypes.ReserveStockRequest = ReserveStockRequest;
|
|
1197
|
+
class ReleaseStockRequest extends pb_1.Message {
|
|
1198
|
+
#one_of_decls = [];
|
|
1199
|
+
constructor(data) {
|
|
1200
|
+
super();
|
|
1201
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
1202
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
1203
|
+
if ("deviceType" in data && data.deviceType != undefined) {
|
|
1204
|
+
this.deviceType = data.deviceType;
|
|
1205
|
+
}
|
|
1206
|
+
if ("quantity" in data && data.quantity != undefined) {
|
|
1207
|
+
this.quantity = data.quantity;
|
|
1208
|
+
}
|
|
1209
|
+
if ("releasedBy" in data && data.releasedBy != undefined) {
|
|
1210
|
+
this.releasedBy = data.releasedBy;
|
|
1211
|
+
}
|
|
1212
|
+
}
|
|
1213
|
+
}
|
|
1214
|
+
get deviceType() {
|
|
1215
|
+
return pb_1.Message.getFieldWithDefault(this, 1, "");
|
|
1216
|
+
}
|
|
1217
|
+
set deviceType(value) {
|
|
1218
|
+
pb_1.Message.setField(this, 1, value);
|
|
1219
|
+
}
|
|
1220
|
+
get quantity() {
|
|
1221
|
+
return pb_1.Message.getFieldWithDefault(this, 2, 0);
|
|
1222
|
+
}
|
|
1223
|
+
set quantity(value) {
|
|
1224
|
+
pb_1.Message.setField(this, 2, value);
|
|
1225
|
+
}
|
|
1226
|
+
get releasedBy() {
|
|
1227
|
+
return pb_1.Message.getFieldWithDefault(this, 3, "");
|
|
1228
|
+
}
|
|
1229
|
+
set releasedBy(value) {
|
|
1230
|
+
pb_1.Message.setField(this, 3, value);
|
|
1231
|
+
}
|
|
1232
|
+
static fromObject(data) {
|
|
1233
|
+
const message = new ReleaseStockRequest({});
|
|
1234
|
+
if (data.deviceType != null) {
|
|
1235
|
+
message.deviceType = data.deviceType;
|
|
1236
|
+
}
|
|
1237
|
+
if (data.quantity != null) {
|
|
1238
|
+
message.quantity = data.quantity;
|
|
1239
|
+
}
|
|
1240
|
+
if (data.releasedBy != null) {
|
|
1241
|
+
message.releasedBy = data.releasedBy;
|
|
1242
|
+
}
|
|
1243
|
+
return message;
|
|
1244
|
+
}
|
|
1245
|
+
toObject() {
|
|
1246
|
+
const data = {};
|
|
1247
|
+
if (this.deviceType != null) {
|
|
1248
|
+
data.deviceType = this.deviceType;
|
|
1249
|
+
}
|
|
1250
|
+
if (this.quantity != null) {
|
|
1251
|
+
data.quantity = this.quantity;
|
|
1252
|
+
}
|
|
1253
|
+
if (this.releasedBy != null) {
|
|
1254
|
+
data.releasedBy = this.releasedBy;
|
|
1255
|
+
}
|
|
1256
|
+
return data;
|
|
1257
|
+
}
|
|
1258
|
+
serialize(w) {
|
|
1259
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
1260
|
+
if (this.deviceType.length)
|
|
1261
|
+
writer.writeString(1, this.deviceType);
|
|
1262
|
+
if (this.quantity != 0)
|
|
1263
|
+
writer.writeInt32(2, this.quantity);
|
|
1264
|
+
if (this.releasedBy.length)
|
|
1265
|
+
writer.writeString(3, this.releasedBy);
|
|
1266
|
+
if (!w)
|
|
1267
|
+
return writer.getResultBuffer();
|
|
1268
|
+
}
|
|
1269
|
+
static deserialize(bytes) {
|
|
1270
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new ReleaseStockRequest();
|
|
1271
|
+
while (reader.nextField()) {
|
|
1272
|
+
if (reader.isEndGroup())
|
|
1273
|
+
break;
|
|
1274
|
+
switch (reader.getFieldNumber()) {
|
|
1275
|
+
case 1:
|
|
1276
|
+
message.deviceType = reader.readString();
|
|
1277
|
+
break;
|
|
1278
|
+
case 2:
|
|
1279
|
+
message.quantity = reader.readInt32();
|
|
1280
|
+
break;
|
|
1281
|
+
case 3:
|
|
1282
|
+
message.releasedBy = reader.readString();
|
|
1283
|
+
break;
|
|
1284
|
+
default: reader.skipField();
|
|
1285
|
+
}
|
|
1286
|
+
}
|
|
1287
|
+
return message;
|
|
1288
|
+
}
|
|
1289
|
+
serializeBinary() {
|
|
1290
|
+
return this.serialize();
|
|
1291
|
+
}
|
|
1292
|
+
static deserializeBinary(bytes) {
|
|
1293
|
+
return ReleaseStockRequest.deserialize(bytes);
|
|
1294
|
+
}
|
|
1295
|
+
}
|
|
1296
|
+
terminalTypes.ReleaseStockRequest = ReleaseStockRequest;
|
|
1297
|
+
class CheckAvailabilityRequest extends pb_1.Message {
|
|
1298
|
+
#one_of_decls = [];
|
|
1299
|
+
constructor(data) {
|
|
1300
|
+
super();
|
|
1301
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
1302
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
1303
|
+
if ("deviceType" in data && data.deviceType != undefined) {
|
|
1304
|
+
this.deviceType = data.deviceType;
|
|
1305
|
+
}
|
|
1306
|
+
if ("quantity" in data && data.quantity != undefined) {
|
|
1307
|
+
this.quantity = data.quantity;
|
|
1308
|
+
}
|
|
1309
|
+
}
|
|
1310
|
+
}
|
|
1311
|
+
get deviceType() {
|
|
1312
|
+
return pb_1.Message.getFieldWithDefault(this, 1, "");
|
|
1313
|
+
}
|
|
1314
|
+
set deviceType(value) {
|
|
1315
|
+
pb_1.Message.setField(this, 1, value);
|
|
1316
|
+
}
|
|
1317
|
+
get quantity() {
|
|
1318
|
+
return pb_1.Message.getFieldWithDefault(this, 2, 0);
|
|
1319
|
+
}
|
|
1320
|
+
set quantity(value) {
|
|
1321
|
+
pb_1.Message.setField(this, 2, value);
|
|
1322
|
+
}
|
|
1323
|
+
static fromObject(data) {
|
|
1324
|
+
const message = new CheckAvailabilityRequest({});
|
|
1325
|
+
if (data.deviceType != null) {
|
|
1326
|
+
message.deviceType = data.deviceType;
|
|
1327
|
+
}
|
|
1328
|
+
if (data.quantity != null) {
|
|
1329
|
+
message.quantity = data.quantity;
|
|
1330
|
+
}
|
|
1331
|
+
return message;
|
|
1332
|
+
}
|
|
1333
|
+
toObject() {
|
|
1334
|
+
const data = {};
|
|
1335
|
+
if (this.deviceType != null) {
|
|
1336
|
+
data.deviceType = this.deviceType;
|
|
1337
|
+
}
|
|
1338
|
+
if (this.quantity != null) {
|
|
1339
|
+
data.quantity = this.quantity;
|
|
1340
|
+
}
|
|
1341
|
+
return data;
|
|
1342
|
+
}
|
|
1343
|
+
serialize(w) {
|
|
1344
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
1345
|
+
if (this.deviceType.length)
|
|
1346
|
+
writer.writeString(1, this.deviceType);
|
|
1347
|
+
if (this.quantity != 0)
|
|
1348
|
+
writer.writeInt32(2, this.quantity);
|
|
1349
|
+
if (!w)
|
|
1350
|
+
return writer.getResultBuffer();
|
|
1351
|
+
}
|
|
1352
|
+
static deserialize(bytes) {
|
|
1353
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new CheckAvailabilityRequest();
|
|
1354
|
+
while (reader.nextField()) {
|
|
1355
|
+
if (reader.isEndGroup())
|
|
1356
|
+
break;
|
|
1357
|
+
switch (reader.getFieldNumber()) {
|
|
1358
|
+
case 1:
|
|
1359
|
+
message.deviceType = reader.readString();
|
|
1360
|
+
break;
|
|
1361
|
+
case 2:
|
|
1362
|
+
message.quantity = reader.readInt32();
|
|
1363
|
+
break;
|
|
1364
|
+
default: reader.skipField();
|
|
1365
|
+
}
|
|
1366
|
+
}
|
|
1367
|
+
return message;
|
|
1368
|
+
}
|
|
1369
|
+
serializeBinary() {
|
|
1370
|
+
return this.serialize();
|
|
1371
|
+
}
|
|
1372
|
+
static deserializeBinary(bytes) {
|
|
1373
|
+
return CheckAvailabilityRequest.deserialize(bytes);
|
|
1374
|
+
}
|
|
1375
|
+
}
|
|
1376
|
+
terminalTypes.CheckAvailabilityRequest = CheckAvailabilityRequest;
|
|
1377
|
+
class GetSpecificationsRequest extends pb_1.Message {
|
|
1378
|
+
#one_of_decls = [];
|
|
1379
|
+
constructor(data) {
|
|
1380
|
+
super();
|
|
1381
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
1382
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
1383
|
+
if ("deviceType" in data && data.deviceType != undefined) {
|
|
1384
|
+
this.deviceType = data.deviceType;
|
|
1385
|
+
}
|
|
1386
|
+
}
|
|
1387
|
+
}
|
|
1388
|
+
get deviceType() {
|
|
1389
|
+
return pb_1.Message.getFieldWithDefault(this, 1, "");
|
|
1390
|
+
}
|
|
1391
|
+
set deviceType(value) {
|
|
1392
|
+
pb_1.Message.setField(this, 1, value);
|
|
1393
|
+
}
|
|
1394
|
+
static fromObject(data) {
|
|
1395
|
+
const message = new GetSpecificationsRequest({});
|
|
1396
|
+
if (data.deviceType != null) {
|
|
1397
|
+
message.deviceType = data.deviceType;
|
|
1398
|
+
}
|
|
1399
|
+
return message;
|
|
1400
|
+
}
|
|
1401
|
+
toObject() {
|
|
1402
|
+
const data = {};
|
|
1403
|
+
if (this.deviceType != null) {
|
|
1404
|
+
data.deviceType = this.deviceType;
|
|
1405
|
+
}
|
|
1406
|
+
return data;
|
|
1407
|
+
}
|
|
1408
|
+
serialize(w) {
|
|
1409
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
1410
|
+
if (this.deviceType.length)
|
|
1411
|
+
writer.writeString(1, this.deviceType);
|
|
1412
|
+
if (!w)
|
|
1413
|
+
return writer.getResultBuffer();
|
|
1414
|
+
}
|
|
1415
|
+
static deserialize(bytes) {
|
|
1416
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new GetSpecificationsRequest();
|
|
1417
|
+
while (reader.nextField()) {
|
|
1418
|
+
if (reader.isEndGroup())
|
|
1419
|
+
break;
|
|
1420
|
+
switch (reader.getFieldNumber()) {
|
|
1421
|
+
case 1:
|
|
1422
|
+
message.deviceType = reader.readString();
|
|
1423
|
+
break;
|
|
1424
|
+
default: reader.skipField();
|
|
1425
|
+
}
|
|
1426
|
+
}
|
|
1427
|
+
return message;
|
|
1428
|
+
}
|
|
1429
|
+
serializeBinary() {
|
|
1430
|
+
return this.serialize();
|
|
1431
|
+
}
|
|
1432
|
+
static deserializeBinary(bytes) {
|
|
1433
|
+
return GetSpecificationsRequest.deserialize(bytes);
|
|
1434
|
+
}
|
|
1435
|
+
}
|
|
1436
|
+
terminalTypes.GetSpecificationsRequest = GetSpecificationsRequest;
|
|
1437
|
+
class GetAvailableTypesRequest extends pb_1.Message {
|
|
1438
|
+
#one_of_decls = [];
|
|
1439
|
+
constructor(data) {
|
|
1440
|
+
super();
|
|
1441
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
1442
|
+
if (!Array.isArray(data) && typeof data == "object") { }
|
|
1443
|
+
}
|
|
1444
|
+
static fromObject(data) {
|
|
1445
|
+
const message = new GetAvailableTypesRequest({});
|
|
1446
|
+
return message;
|
|
1447
|
+
}
|
|
1448
|
+
toObject() {
|
|
1449
|
+
const data = {};
|
|
1450
|
+
return data;
|
|
1451
|
+
}
|
|
1452
|
+
serialize(w) {
|
|
1453
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
1454
|
+
if (!w)
|
|
1455
|
+
return writer.getResultBuffer();
|
|
1456
|
+
}
|
|
1457
|
+
static deserialize(bytes) {
|
|
1458
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new GetAvailableTypesRequest();
|
|
1459
|
+
while (reader.nextField()) {
|
|
1460
|
+
if (reader.isEndGroup())
|
|
1461
|
+
break;
|
|
1462
|
+
switch (reader.getFieldNumber()) {
|
|
1463
|
+
default: reader.skipField();
|
|
1464
|
+
}
|
|
1465
|
+
}
|
|
1466
|
+
return message;
|
|
1467
|
+
}
|
|
1468
|
+
serializeBinary() {
|
|
1469
|
+
return this.serialize();
|
|
1470
|
+
}
|
|
1471
|
+
static deserializeBinary(bytes) {
|
|
1472
|
+
return GetAvailableTypesRequest.deserialize(bytes);
|
|
1473
|
+
}
|
|
1474
|
+
}
|
|
1475
|
+
terminalTypes.GetAvailableTypesRequest = GetAvailableTypesRequest;
|
|
1476
|
+
class GetStatsRequest extends pb_1.Message {
|
|
1477
|
+
#one_of_decls = [];
|
|
1478
|
+
constructor(data) {
|
|
1479
|
+
super();
|
|
1480
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
1481
|
+
if (!Array.isArray(data) && typeof data == "object") { }
|
|
1482
|
+
}
|
|
1483
|
+
static fromObject(data) {
|
|
1484
|
+
const message = new GetStatsRequest({});
|
|
1485
|
+
return message;
|
|
1486
|
+
}
|
|
1487
|
+
toObject() {
|
|
1488
|
+
const data = {};
|
|
1489
|
+
return data;
|
|
1490
|
+
}
|
|
1491
|
+
serialize(w) {
|
|
1492
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
1493
|
+
if (!w)
|
|
1494
|
+
return writer.getResultBuffer();
|
|
1495
|
+
}
|
|
1496
|
+
static deserialize(bytes) {
|
|
1497
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new GetStatsRequest();
|
|
1498
|
+
while (reader.nextField()) {
|
|
1499
|
+
if (reader.isEndGroup())
|
|
1500
|
+
break;
|
|
1501
|
+
switch (reader.getFieldNumber()) {
|
|
1502
|
+
default: reader.skipField();
|
|
1503
|
+
}
|
|
1504
|
+
}
|
|
1505
|
+
return message;
|
|
1506
|
+
}
|
|
1507
|
+
serializeBinary() {
|
|
1508
|
+
return this.serialize();
|
|
1509
|
+
}
|
|
1510
|
+
static deserializeBinary(bytes) {
|
|
1511
|
+
return GetStatsRequest.deserialize(bytes);
|
|
1512
|
+
}
|
|
1513
|
+
}
|
|
1514
|
+
terminalTypes.GetStatsRequest = GetStatsRequest;
|
|
1515
|
+
class GetLowStockRequest extends pb_1.Message {
|
|
1516
|
+
#one_of_decls = [];
|
|
1517
|
+
constructor(data) {
|
|
1518
|
+
super();
|
|
1519
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
1520
|
+
if (!Array.isArray(data) && typeof data == "object") { }
|
|
1521
|
+
}
|
|
1522
|
+
static fromObject(data) {
|
|
1523
|
+
const message = new GetLowStockRequest({});
|
|
1524
|
+
return message;
|
|
1525
|
+
}
|
|
1526
|
+
toObject() {
|
|
1527
|
+
const data = {};
|
|
1528
|
+
return data;
|
|
1529
|
+
}
|
|
1530
|
+
serialize(w) {
|
|
1531
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
1532
|
+
if (!w)
|
|
1533
|
+
return writer.getResultBuffer();
|
|
1534
|
+
}
|
|
1535
|
+
static deserialize(bytes) {
|
|
1536
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new GetLowStockRequest();
|
|
1537
|
+
while (reader.nextField()) {
|
|
1538
|
+
if (reader.isEndGroup())
|
|
1539
|
+
break;
|
|
1540
|
+
switch (reader.getFieldNumber()) {
|
|
1541
|
+
default: reader.skipField();
|
|
1542
|
+
}
|
|
1543
|
+
}
|
|
1544
|
+
return message;
|
|
1545
|
+
}
|
|
1546
|
+
serializeBinary() {
|
|
1547
|
+
return this.serialize();
|
|
1548
|
+
}
|
|
1549
|
+
static deserializeBinary(bytes) {
|
|
1550
|
+
return GetLowStockRequest.deserialize(bytes);
|
|
1551
|
+
}
|
|
1552
|
+
}
|
|
1553
|
+
terminalTypes.GetLowStockRequest = GetLowStockRequest;
|
|
1554
|
+
class TerminalTypeData extends pb_1.Message {
|
|
1555
|
+
#one_of_decls = [];
|
|
1556
|
+
constructor(data) {
|
|
1557
|
+
super();
|
|
1558
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [12, 13], this.#one_of_decls);
|
|
1559
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
1560
|
+
if ("id" in data && data.id != undefined) {
|
|
1561
|
+
this.id = data.id;
|
|
1562
|
+
}
|
|
1563
|
+
if ("deviceType" in data && data.deviceType != undefined) {
|
|
1564
|
+
this.deviceType = data.deviceType;
|
|
1565
|
+
}
|
|
1566
|
+
if ("manufacturer" in data && data.manufacturer != undefined) {
|
|
1567
|
+
this.manufacturer = data.manufacturer;
|
|
1568
|
+
}
|
|
1569
|
+
if ("model" in data && data.model != undefined) {
|
|
1570
|
+
this.model = data.model;
|
|
1571
|
+
}
|
|
1572
|
+
if ("price" in data && data.price != undefined) {
|
|
1573
|
+
this.price = data.price;
|
|
1574
|
+
}
|
|
1575
|
+
if ("status" in data && data.status != undefined) {
|
|
1576
|
+
this.status = data.status;
|
|
1577
|
+
}
|
|
1578
|
+
if ("stockQuantity" in data && data.stockQuantity != undefined) {
|
|
1579
|
+
this.stockQuantity = data.stockQuantity;
|
|
1580
|
+
}
|
|
1581
|
+
if ("reservedStock" in data && data.reservedStock != undefined) {
|
|
1582
|
+
this.reservedStock = data.reservedStock;
|
|
1583
|
+
}
|
|
1584
|
+
if ("minimumStock" in data && data.minimumStock != undefined) {
|
|
1585
|
+
this.minimumStock = data.minimumStock;
|
|
1586
|
+
}
|
|
1587
|
+
if ("category" in data && data.category != undefined) {
|
|
1588
|
+
this.category = data.category;
|
|
1589
|
+
}
|
|
1590
|
+
if ("description" in data && data.description != undefined) {
|
|
1591
|
+
this.description = data.description;
|
|
1592
|
+
}
|
|
1593
|
+
if ("features" in data && data.features != undefined) {
|
|
1594
|
+
this.features = data.features;
|
|
1595
|
+
}
|
|
1596
|
+
if ("compatibleSoftware" in data && data.compatibleSoftware != undefined) {
|
|
1597
|
+
this.compatibleSoftware = data.compatibleSoftware;
|
|
1598
|
+
}
|
|
1599
|
+
if ("technicalSpecifications" in data && data.technicalSpecifications != undefined) {
|
|
1600
|
+
this.technicalSpecifications = data.technicalSpecifications;
|
|
1601
|
+
}
|
|
1602
|
+
if ("firmwareVersion" in data && data.firmwareVersion != undefined) {
|
|
1603
|
+
this.firmwareVersion = data.firmwareVersion;
|
|
1604
|
+
}
|
|
1605
|
+
if ("warrantyMonths" in data && data.warrantyMonths != undefined) {
|
|
1606
|
+
this.warrantyMonths = data.warrantyMonths;
|
|
1607
|
+
}
|
|
1608
|
+
if ("discontinuedReason" in data && data.discontinuedReason != undefined) {
|
|
1609
|
+
this.discontinuedReason = data.discontinuedReason;
|
|
1610
|
+
}
|
|
1611
|
+
if ("discontinuedAt" in data && data.discontinuedAt != undefined) {
|
|
1612
|
+
this.discontinuedAt = data.discontinuedAt;
|
|
1613
|
+
}
|
|
1614
|
+
if ("createdAt" in data && data.createdAt != undefined) {
|
|
1615
|
+
this.createdAt = data.createdAt;
|
|
1616
|
+
}
|
|
1617
|
+
if ("updatedAt" in data && data.updatedAt != undefined) {
|
|
1618
|
+
this.updatedAt = data.updatedAt;
|
|
1619
|
+
}
|
|
1620
|
+
}
|
|
1621
|
+
}
|
|
1622
|
+
get id() {
|
|
1623
|
+
return pb_1.Message.getFieldWithDefault(this, 1, "");
|
|
1624
|
+
}
|
|
1625
|
+
set id(value) {
|
|
1626
|
+
pb_1.Message.setField(this, 1, value);
|
|
1627
|
+
}
|
|
1628
|
+
get deviceType() {
|
|
1629
|
+
return pb_1.Message.getFieldWithDefault(this, 2, "");
|
|
1630
|
+
}
|
|
1631
|
+
set deviceType(value) {
|
|
1632
|
+
pb_1.Message.setField(this, 2, value);
|
|
1633
|
+
}
|
|
1634
|
+
get manufacturer() {
|
|
1635
|
+
return pb_1.Message.getFieldWithDefault(this, 3, "");
|
|
1636
|
+
}
|
|
1637
|
+
set manufacturer(value) {
|
|
1638
|
+
pb_1.Message.setField(this, 3, value);
|
|
1639
|
+
}
|
|
1640
|
+
get model() {
|
|
1641
|
+
return pb_1.Message.getFieldWithDefault(this, 4, "");
|
|
1642
|
+
}
|
|
1643
|
+
set model(value) {
|
|
1644
|
+
pb_1.Message.setField(this, 4, value);
|
|
1645
|
+
}
|
|
1646
|
+
get price() {
|
|
1647
|
+
return pb_1.Message.getFieldWithDefault(this, 5, 0);
|
|
1648
|
+
}
|
|
1649
|
+
set price(value) {
|
|
1650
|
+
pb_1.Message.setField(this, 5, value);
|
|
1651
|
+
}
|
|
1652
|
+
get status() {
|
|
1653
|
+
return pb_1.Message.getFieldWithDefault(this, 6, "");
|
|
1654
|
+
}
|
|
1655
|
+
set status(value) {
|
|
1656
|
+
pb_1.Message.setField(this, 6, value);
|
|
1657
|
+
}
|
|
1658
|
+
get stockQuantity() {
|
|
1659
|
+
return pb_1.Message.getFieldWithDefault(this, 7, 0);
|
|
1660
|
+
}
|
|
1661
|
+
set stockQuantity(value) {
|
|
1662
|
+
pb_1.Message.setField(this, 7, value);
|
|
1663
|
+
}
|
|
1664
|
+
get reservedStock() {
|
|
1665
|
+
return pb_1.Message.getFieldWithDefault(this, 8, 0);
|
|
1666
|
+
}
|
|
1667
|
+
set reservedStock(value) {
|
|
1668
|
+
pb_1.Message.setField(this, 8, value);
|
|
1669
|
+
}
|
|
1670
|
+
get minimumStock() {
|
|
1671
|
+
return pb_1.Message.getFieldWithDefault(this, 9, 0);
|
|
1672
|
+
}
|
|
1673
|
+
set minimumStock(value) {
|
|
1674
|
+
pb_1.Message.setField(this, 9, value);
|
|
1675
|
+
}
|
|
1676
|
+
get category() {
|
|
1677
|
+
return pb_1.Message.getFieldWithDefault(this, 10, "");
|
|
1678
|
+
}
|
|
1679
|
+
set category(value) {
|
|
1680
|
+
pb_1.Message.setField(this, 10, value);
|
|
1681
|
+
}
|
|
1682
|
+
get description() {
|
|
1683
|
+
return pb_1.Message.getFieldWithDefault(this, 11, "");
|
|
1684
|
+
}
|
|
1685
|
+
set description(value) {
|
|
1686
|
+
pb_1.Message.setField(this, 11, value);
|
|
1687
|
+
}
|
|
1688
|
+
get features() {
|
|
1689
|
+
return pb_1.Message.getFieldWithDefault(this, 12, []);
|
|
1690
|
+
}
|
|
1691
|
+
set features(value) {
|
|
1692
|
+
pb_1.Message.setField(this, 12, value);
|
|
1693
|
+
}
|
|
1694
|
+
get compatibleSoftware() {
|
|
1695
|
+
return pb_1.Message.getFieldWithDefault(this, 13, []);
|
|
1696
|
+
}
|
|
1697
|
+
set compatibleSoftware(value) {
|
|
1698
|
+
pb_1.Message.setField(this, 13, value);
|
|
1699
|
+
}
|
|
1700
|
+
get technicalSpecifications() {
|
|
1701
|
+
return pb_1.Message.getFieldWithDefault(this, 14, "");
|
|
1702
|
+
}
|
|
1703
|
+
set technicalSpecifications(value) {
|
|
1704
|
+
pb_1.Message.setField(this, 14, value);
|
|
1705
|
+
}
|
|
1706
|
+
get firmwareVersion() {
|
|
1707
|
+
return pb_1.Message.getFieldWithDefault(this, 15, "");
|
|
1708
|
+
}
|
|
1709
|
+
set firmwareVersion(value) {
|
|
1710
|
+
pb_1.Message.setField(this, 15, value);
|
|
1711
|
+
}
|
|
1712
|
+
get warrantyMonths() {
|
|
1713
|
+
return pb_1.Message.getFieldWithDefault(this, 16, 0);
|
|
1714
|
+
}
|
|
1715
|
+
set warrantyMonths(value) {
|
|
1716
|
+
pb_1.Message.setField(this, 16, value);
|
|
1717
|
+
}
|
|
1718
|
+
get discontinuedReason() {
|
|
1719
|
+
return pb_1.Message.getFieldWithDefault(this, 17, "");
|
|
1720
|
+
}
|
|
1721
|
+
set discontinuedReason(value) {
|
|
1722
|
+
pb_1.Message.setField(this, 17, value);
|
|
1723
|
+
}
|
|
1724
|
+
get discontinuedAt() {
|
|
1725
|
+
return pb_1.Message.getFieldWithDefault(this, 18, "");
|
|
1726
|
+
}
|
|
1727
|
+
set discontinuedAt(value) {
|
|
1728
|
+
pb_1.Message.setField(this, 18, value);
|
|
1729
|
+
}
|
|
1730
|
+
get createdAt() {
|
|
1731
|
+
return pb_1.Message.getFieldWithDefault(this, 19, "");
|
|
1732
|
+
}
|
|
1733
|
+
set createdAt(value) {
|
|
1734
|
+
pb_1.Message.setField(this, 19, value);
|
|
1735
|
+
}
|
|
1736
|
+
get updatedAt() {
|
|
1737
|
+
return pb_1.Message.getFieldWithDefault(this, 20, "");
|
|
1738
|
+
}
|
|
1739
|
+
set updatedAt(value) {
|
|
1740
|
+
pb_1.Message.setField(this, 20, value);
|
|
1741
|
+
}
|
|
1742
|
+
static fromObject(data) {
|
|
1743
|
+
const message = new TerminalTypeData({});
|
|
1744
|
+
if (data.id != null) {
|
|
1745
|
+
message.id = data.id;
|
|
1746
|
+
}
|
|
1747
|
+
if (data.deviceType != null) {
|
|
1748
|
+
message.deviceType = data.deviceType;
|
|
1749
|
+
}
|
|
1750
|
+
if (data.manufacturer != null) {
|
|
1751
|
+
message.manufacturer = data.manufacturer;
|
|
1752
|
+
}
|
|
1753
|
+
if (data.model != null) {
|
|
1754
|
+
message.model = data.model;
|
|
1755
|
+
}
|
|
1756
|
+
if (data.price != null) {
|
|
1757
|
+
message.price = data.price;
|
|
1758
|
+
}
|
|
1759
|
+
if (data.status != null) {
|
|
1760
|
+
message.status = data.status;
|
|
1761
|
+
}
|
|
1762
|
+
if (data.stockQuantity != null) {
|
|
1763
|
+
message.stockQuantity = data.stockQuantity;
|
|
1764
|
+
}
|
|
1765
|
+
if (data.reservedStock != null) {
|
|
1766
|
+
message.reservedStock = data.reservedStock;
|
|
1767
|
+
}
|
|
1768
|
+
if (data.minimumStock != null) {
|
|
1769
|
+
message.minimumStock = data.minimumStock;
|
|
1770
|
+
}
|
|
1771
|
+
if (data.category != null) {
|
|
1772
|
+
message.category = data.category;
|
|
1773
|
+
}
|
|
1774
|
+
if (data.description != null) {
|
|
1775
|
+
message.description = data.description;
|
|
1776
|
+
}
|
|
1777
|
+
if (data.features != null) {
|
|
1778
|
+
message.features = data.features;
|
|
1779
|
+
}
|
|
1780
|
+
if (data.compatibleSoftware != null) {
|
|
1781
|
+
message.compatibleSoftware = data.compatibleSoftware;
|
|
1782
|
+
}
|
|
1783
|
+
if (data.technicalSpecifications != null) {
|
|
1784
|
+
message.technicalSpecifications = data.technicalSpecifications;
|
|
1785
|
+
}
|
|
1786
|
+
if (data.firmwareVersion != null) {
|
|
1787
|
+
message.firmwareVersion = data.firmwareVersion;
|
|
1788
|
+
}
|
|
1789
|
+
if (data.warrantyMonths != null) {
|
|
1790
|
+
message.warrantyMonths = data.warrantyMonths;
|
|
1791
|
+
}
|
|
1792
|
+
if (data.discontinuedReason != null) {
|
|
1793
|
+
message.discontinuedReason = data.discontinuedReason;
|
|
1794
|
+
}
|
|
1795
|
+
if (data.discontinuedAt != null) {
|
|
1796
|
+
message.discontinuedAt = data.discontinuedAt;
|
|
1797
|
+
}
|
|
1798
|
+
if (data.createdAt != null) {
|
|
1799
|
+
message.createdAt = data.createdAt;
|
|
1800
|
+
}
|
|
1801
|
+
if (data.updatedAt != null) {
|
|
1802
|
+
message.updatedAt = data.updatedAt;
|
|
1803
|
+
}
|
|
1804
|
+
return message;
|
|
1805
|
+
}
|
|
1806
|
+
toObject() {
|
|
1807
|
+
const data = {};
|
|
1808
|
+
if (this.id != null) {
|
|
1809
|
+
data.id = this.id;
|
|
1810
|
+
}
|
|
1811
|
+
if (this.deviceType != null) {
|
|
1812
|
+
data.deviceType = this.deviceType;
|
|
1813
|
+
}
|
|
1814
|
+
if (this.manufacturer != null) {
|
|
1815
|
+
data.manufacturer = this.manufacturer;
|
|
1816
|
+
}
|
|
1817
|
+
if (this.model != null) {
|
|
1818
|
+
data.model = this.model;
|
|
1819
|
+
}
|
|
1820
|
+
if (this.price != null) {
|
|
1821
|
+
data.price = this.price;
|
|
1822
|
+
}
|
|
1823
|
+
if (this.status != null) {
|
|
1824
|
+
data.status = this.status;
|
|
1825
|
+
}
|
|
1826
|
+
if (this.stockQuantity != null) {
|
|
1827
|
+
data.stockQuantity = this.stockQuantity;
|
|
1828
|
+
}
|
|
1829
|
+
if (this.reservedStock != null) {
|
|
1830
|
+
data.reservedStock = this.reservedStock;
|
|
1831
|
+
}
|
|
1832
|
+
if (this.minimumStock != null) {
|
|
1833
|
+
data.minimumStock = this.minimumStock;
|
|
1834
|
+
}
|
|
1835
|
+
if (this.category != null) {
|
|
1836
|
+
data.category = this.category;
|
|
1837
|
+
}
|
|
1838
|
+
if (this.description != null) {
|
|
1839
|
+
data.description = this.description;
|
|
1840
|
+
}
|
|
1841
|
+
if (this.features != null) {
|
|
1842
|
+
data.features = this.features;
|
|
1843
|
+
}
|
|
1844
|
+
if (this.compatibleSoftware != null) {
|
|
1845
|
+
data.compatibleSoftware = this.compatibleSoftware;
|
|
1846
|
+
}
|
|
1847
|
+
if (this.technicalSpecifications != null) {
|
|
1848
|
+
data.technicalSpecifications = this.technicalSpecifications;
|
|
1849
|
+
}
|
|
1850
|
+
if (this.firmwareVersion != null) {
|
|
1851
|
+
data.firmwareVersion = this.firmwareVersion;
|
|
1852
|
+
}
|
|
1853
|
+
if (this.warrantyMonths != null) {
|
|
1854
|
+
data.warrantyMonths = this.warrantyMonths;
|
|
1855
|
+
}
|
|
1856
|
+
if (this.discontinuedReason != null) {
|
|
1857
|
+
data.discontinuedReason = this.discontinuedReason;
|
|
1858
|
+
}
|
|
1859
|
+
if (this.discontinuedAt != null) {
|
|
1860
|
+
data.discontinuedAt = this.discontinuedAt;
|
|
1861
|
+
}
|
|
1862
|
+
if (this.createdAt != null) {
|
|
1863
|
+
data.createdAt = this.createdAt;
|
|
1864
|
+
}
|
|
1865
|
+
if (this.updatedAt != null) {
|
|
1866
|
+
data.updatedAt = this.updatedAt;
|
|
1867
|
+
}
|
|
1868
|
+
return data;
|
|
1869
|
+
}
|
|
1870
|
+
serialize(w) {
|
|
1871
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
1872
|
+
if (this.id.length)
|
|
1873
|
+
writer.writeString(1, this.id);
|
|
1874
|
+
if (this.deviceType.length)
|
|
1875
|
+
writer.writeString(2, this.deviceType);
|
|
1876
|
+
if (this.manufacturer.length)
|
|
1877
|
+
writer.writeString(3, this.manufacturer);
|
|
1878
|
+
if (this.model.length)
|
|
1879
|
+
writer.writeString(4, this.model);
|
|
1880
|
+
if (this.price != 0)
|
|
1881
|
+
writer.writeDouble(5, this.price);
|
|
1882
|
+
if (this.status.length)
|
|
1883
|
+
writer.writeString(6, this.status);
|
|
1884
|
+
if (this.stockQuantity != 0)
|
|
1885
|
+
writer.writeInt32(7, this.stockQuantity);
|
|
1886
|
+
if (this.reservedStock != 0)
|
|
1887
|
+
writer.writeInt32(8, this.reservedStock);
|
|
1888
|
+
if (this.minimumStock != 0)
|
|
1889
|
+
writer.writeInt32(9, this.minimumStock);
|
|
1890
|
+
if (this.category.length)
|
|
1891
|
+
writer.writeString(10, this.category);
|
|
1892
|
+
if (this.description.length)
|
|
1893
|
+
writer.writeString(11, this.description);
|
|
1894
|
+
if (this.features.length)
|
|
1895
|
+
writer.writeRepeatedString(12, this.features);
|
|
1896
|
+
if (this.compatibleSoftware.length)
|
|
1897
|
+
writer.writeRepeatedString(13, this.compatibleSoftware);
|
|
1898
|
+
if (this.technicalSpecifications.length)
|
|
1899
|
+
writer.writeString(14, this.technicalSpecifications);
|
|
1900
|
+
if (this.firmwareVersion.length)
|
|
1901
|
+
writer.writeString(15, this.firmwareVersion);
|
|
1902
|
+
if (this.warrantyMonths != 0)
|
|
1903
|
+
writer.writeInt32(16, this.warrantyMonths);
|
|
1904
|
+
if (this.discontinuedReason.length)
|
|
1905
|
+
writer.writeString(17, this.discontinuedReason);
|
|
1906
|
+
if (this.discontinuedAt.length)
|
|
1907
|
+
writer.writeString(18, this.discontinuedAt);
|
|
1908
|
+
if (this.createdAt.length)
|
|
1909
|
+
writer.writeString(19, this.createdAt);
|
|
1910
|
+
if (this.updatedAt.length)
|
|
1911
|
+
writer.writeString(20, this.updatedAt);
|
|
1912
|
+
if (!w)
|
|
1913
|
+
return writer.getResultBuffer();
|
|
1914
|
+
}
|
|
1915
|
+
static deserialize(bytes) {
|
|
1916
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new TerminalTypeData();
|
|
1917
|
+
while (reader.nextField()) {
|
|
1918
|
+
if (reader.isEndGroup())
|
|
1919
|
+
break;
|
|
1920
|
+
switch (reader.getFieldNumber()) {
|
|
1921
|
+
case 1:
|
|
1922
|
+
message.id = reader.readString();
|
|
1923
|
+
break;
|
|
1924
|
+
case 2:
|
|
1925
|
+
message.deviceType = reader.readString();
|
|
1926
|
+
break;
|
|
1927
|
+
case 3:
|
|
1928
|
+
message.manufacturer = reader.readString();
|
|
1929
|
+
break;
|
|
1930
|
+
case 4:
|
|
1931
|
+
message.model = reader.readString();
|
|
1932
|
+
break;
|
|
1933
|
+
case 5:
|
|
1934
|
+
message.price = reader.readDouble();
|
|
1935
|
+
break;
|
|
1936
|
+
case 6:
|
|
1937
|
+
message.status = reader.readString();
|
|
1938
|
+
break;
|
|
1939
|
+
case 7:
|
|
1940
|
+
message.stockQuantity = reader.readInt32();
|
|
1941
|
+
break;
|
|
1942
|
+
case 8:
|
|
1943
|
+
message.reservedStock = reader.readInt32();
|
|
1944
|
+
break;
|
|
1945
|
+
case 9:
|
|
1946
|
+
message.minimumStock = reader.readInt32();
|
|
1947
|
+
break;
|
|
1948
|
+
case 10:
|
|
1949
|
+
message.category = reader.readString();
|
|
1950
|
+
break;
|
|
1951
|
+
case 11:
|
|
1952
|
+
message.description = reader.readString();
|
|
1953
|
+
break;
|
|
1954
|
+
case 12:
|
|
1955
|
+
pb_1.Message.addToRepeatedField(message, 12, reader.readString());
|
|
1956
|
+
break;
|
|
1957
|
+
case 13:
|
|
1958
|
+
pb_1.Message.addToRepeatedField(message, 13, reader.readString());
|
|
1959
|
+
break;
|
|
1960
|
+
case 14:
|
|
1961
|
+
message.technicalSpecifications = reader.readString();
|
|
1962
|
+
break;
|
|
1963
|
+
case 15:
|
|
1964
|
+
message.firmwareVersion = reader.readString();
|
|
1965
|
+
break;
|
|
1966
|
+
case 16:
|
|
1967
|
+
message.warrantyMonths = reader.readInt32();
|
|
1968
|
+
break;
|
|
1969
|
+
case 17:
|
|
1970
|
+
message.discontinuedReason = reader.readString();
|
|
1971
|
+
break;
|
|
1972
|
+
case 18:
|
|
1973
|
+
message.discontinuedAt = reader.readString();
|
|
1974
|
+
break;
|
|
1975
|
+
case 19:
|
|
1976
|
+
message.createdAt = reader.readString();
|
|
1977
|
+
break;
|
|
1978
|
+
case 20:
|
|
1979
|
+
message.updatedAt = reader.readString();
|
|
1980
|
+
break;
|
|
1981
|
+
default: reader.skipField();
|
|
1982
|
+
}
|
|
1983
|
+
}
|
|
1984
|
+
return message;
|
|
1985
|
+
}
|
|
1986
|
+
serializeBinary() {
|
|
1987
|
+
return this.serialize();
|
|
1988
|
+
}
|
|
1989
|
+
static deserializeBinary(bytes) {
|
|
1990
|
+
return TerminalTypeData.deserialize(bytes);
|
|
1991
|
+
}
|
|
1992
|
+
}
|
|
1993
|
+
terminalTypes.TerminalTypeData = TerminalTypeData;
|
|
1994
|
+
class StockData extends pb_1.Message {
|
|
1995
|
+
#one_of_decls = [];
|
|
1996
|
+
constructor(data) {
|
|
1997
|
+
super();
|
|
1998
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
1999
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
2000
|
+
if ("id" in data && data.id != undefined) {
|
|
2001
|
+
this.id = data.id;
|
|
2002
|
+
}
|
|
2003
|
+
if ("deviceType" in data && data.deviceType != undefined) {
|
|
2004
|
+
this.deviceType = data.deviceType;
|
|
2005
|
+
}
|
|
2006
|
+
if ("stockQuantity" in data && data.stockQuantity != undefined) {
|
|
2007
|
+
this.stockQuantity = data.stockQuantity;
|
|
2008
|
+
}
|
|
2009
|
+
if ("reservedStock" in data && data.reservedStock != undefined) {
|
|
2010
|
+
this.reservedStock = data.reservedStock;
|
|
2011
|
+
}
|
|
2012
|
+
if ("availableStock" in data && data.availableStock != undefined) {
|
|
2013
|
+
this.availableStock = data.availableStock;
|
|
2014
|
+
}
|
|
2015
|
+
}
|
|
2016
|
+
}
|
|
2017
|
+
get id() {
|
|
2018
|
+
return pb_1.Message.getFieldWithDefault(this, 1, "");
|
|
2019
|
+
}
|
|
2020
|
+
set id(value) {
|
|
2021
|
+
pb_1.Message.setField(this, 1, value);
|
|
2022
|
+
}
|
|
2023
|
+
get deviceType() {
|
|
2024
|
+
return pb_1.Message.getFieldWithDefault(this, 2, "");
|
|
2025
|
+
}
|
|
2026
|
+
set deviceType(value) {
|
|
2027
|
+
pb_1.Message.setField(this, 2, value);
|
|
2028
|
+
}
|
|
2029
|
+
get stockQuantity() {
|
|
2030
|
+
return pb_1.Message.getFieldWithDefault(this, 3, 0);
|
|
2031
|
+
}
|
|
2032
|
+
set stockQuantity(value) {
|
|
2033
|
+
pb_1.Message.setField(this, 3, value);
|
|
2034
|
+
}
|
|
2035
|
+
get reservedStock() {
|
|
2036
|
+
return pb_1.Message.getFieldWithDefault(this, 4, 0);
|
|
2037
|
+
}
|
|
2038
|
+
set reservedStock(value) {
|
|
2039
|
+
pb_1.Message.setField(this, 4, value);
|
|
2040
|
+
}
|
|
2041
|
+
get availableStock() {
|
|
2042
|
+
return pb_1.Message.getFieldWithDefault(this, 5, 0);
|
|
2043
|
+
}
|
|
2044
|
+
set availableStock(value) {
|
|
2045
|
+
pb_1.Message.setField(this, 5, value);
|
|
2046
|
+
}
|
|
2047
|
+
static fromObject(data) {
|
|
2048
|
+
const message = new StockData({});
|
|
2049
|
+
if (data.id != null) {
|
|
2050
|
+
message.id = data.id;
|
|
2051
|
+
}
|
|
2052
|
+
if (data.deviceType != null) {
|
|
2053
|
+
message.deviceType = data.deviceType;
|
|
2054
|
+
}
|
|
2055
|
+
if (data.stockQuantity != null) {
|
|
2056
|
+
message.stockQuantity = data.stockQuantity;
|
|
2057
|
+
}
|
|
2058
|
+
if (data.reservedStock != null) {
|
|
2059
|
+
message.reservedStock = data.reservedStock;
|
|
2060
|
+
}
|
|
2061
|
+
if (data.availableStock != null) {
|
|
2062
|
+
message.availableStock = data.availableStock;
|
|
2063
|
+
}
|
|
2064
|
+
return message;
|
|
2065
|
+
}
|
|
2066
|
+
toObject() {
|
|
2067
|
+
const data = {};
|
|
2068
|
+
if (this.id != null) {
|
|
2069
|
+
data.id = this.id;
|
|
2070
|
+
}
|
|
2071
|
+
if (this.deviceType != null) {
|
|
2072
|
+
data.deviceType = this.deviceType;
|
|
2073
|
+
}
|
|
2074
|
+
if (this.stockQuantity != null) {
|
|
2075
|
+
data.stockQuantity = this.stockQuantity;
|
|
2076
|
+
}
|
|
2077
|
+
if (this.reservedStock != null) {
|
|
2078
|
+
data.reservedStock = this.reservedStock;
|
|
2079
|
+
}
|
|
2080
|
+
if (this.availableStock != null) {
|
|
2081
|
+
data.availableStock = this.availableStock;
|
|
2082
|
+
}
|
|
2083
|
+
return data;
|
|
2084
|
+
}
|
|
2085
|
+
serialize(w) {
|
|
2086
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
2087
|
+
if (this.id.length)
|
|
2088
|
+
writer.writeString(1, this.id);
|
|
2089
|
+
if (this.deviceType.length)
|
|
2090
|
+
writer.writeString(2, this.deviceType);
|
|
2091
|
+
if (this.stockQuantity != 0)
|
|
2092
|
+
writer.writeInt32(3, this.stockQuantity);
|
|
2093
|
+
if (this.reservedStock != 0)
|
|
2094
|
+
writer.writeInt32(4, this.reservedStock);
|
|
2095
|
+
if (this.availableStock != 0)
|
|
2096
|
+
writer.writeInt32(5, this.availableStock);
|
|
2097
|
+
if (!w)
|
|
2098
|
+
return writer.getResultBuffer();
|
|
2099
|
+
}
|
|
2100
|
+
static deserialize(bytes) {
|
|
2101
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new StockData();
|
|
2102
|
+
while (reader.nextField()) {
|
|
2103
|
+
if (reader.isEndGroup())
|
|
2104
|
+
break;
|
|
2105
|
+
switch (reader.getFieldNumber()) {
|
|
2106
|
+
case 1:
|
|
2107
|
+
message.id = reader.readString();
|
|
2108
|
+
break;
|
|
2109
|
+
case 2:
|
|
2110
|
+
message.deviceType = reader.readString();
|
|
2111
|
+
break;
|
|
2112
|
+
case 3:
|
|
2113
|
+
message.stockQuantity = reader.readInt32();
|
|
2114
|
+
break;
|
|
2115
|
+
case 4:
|
|
2116
|
+
message.reservedStock = reader.readInt32();
|
|
2117
|
+
break;
|
|
2118
|
+
case 5:
|
|
2119
|
+
message.availableStock = reader.readInt32();
|
|
2120
|
+
break;
|
|
2121
|
+
default: reader.skipField();
|
|
2122
|
+
}
|
|
2123
|
+
}
|
|
2124
|
+
return message;
|
|
2125
|
+
}
|
|
2126
|
+
serializeBinary() {
|
|
2127
|
+
return this.serialize();
|
|
2128
|
+
}
|
|
2129
|
+
static deserializeBinary(bytes) {
|
|
2130
|
+
return StockData.deserialize(bytes);
|
|
2131
|
+
}
|
|
2132
|
+
}
|
|
2133
|
+
terminalTypes.StockData = StockData;
|
|
2134
|
+
class AvailabilityData extends pb_1.Message {
|
|
2135
|
+
#one_of_decls = [];
|
|
2136
|
+
constructor(data) {
|
|
2137
|
+
super();
|
|
2138
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
2139
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
2140
|
+
if ("deviceType" in data && data.deviceType != undefined) {
|
|
2141
|
+
this.deviceType = data.deviceType;
|
|
2142
|
+
}
|
|
2143
|
+
if ("quantity" in data && data.quantity != undefined) {
|
|
2144
|
+
this.quantity = data.quantity;
|
|
2145
|
+
}
|
|
2146
|
+
if ("available" in data && data.available != undefined) {
|
|
2147
|
+
this.available = data.available;
|
|
2148
|
+
}
|
|
2149
|
+
}
|
|
2150
|
+
}
|
|
2151
|
+
get deviceType() {
|
|
2152
|
+
return pb_1.Message.getFieldWithDefault(this, 1, "");
|
|
2153
|
+
}
|
|
2154
|
+
set deviceType(value) {
|
|
2155
|
+
pb_1.Message.setField(this, 1, value);
|
|
2156
|
+
}
|
|
2157
|
+
get quantity() {
|
|
2158
|
+
return pb_1.Message.getFieldWithDefault(this, 2, 0);
|
|
2159
|
+
}
|
|
2160
|
+
set quantity(value) {
|
|
2161
|
+
pb_1.Message.setField(this, 2, value);
|
|
2162
|
+
}
|
|
2163
|
+
get available() {
|
|
2164
|
+
return pb_1.Message.getFieldWithDefault(this, 3, false);
|
|
2165
|
+
}
|
|
2166
|
+
set available(value) {
|
|
2167
|
+
pb_1.Message.setField(this, 3, value);
|
|
2168
|
+
}
|
|
2169
|
+
static fromObject(data) {
|
|
2170
|
+
const message = new AvailabilityData({});
|
|
2171
|
+
if (data.deviceType != null) {
|
|
2172
|
+
message.deviceType = data.deviceType;
|
|
2173
|
+
}
|
|
2174
|
+
if (data.quantity != null) {
|
|
2175
|
+
message.quantity = data.quantity;
|
|
2176
|
+
}
|
|
2177
|
+
if (data.available != null) {
|
|
2178
|
+
message.available = data.available;
|
|
2179
|
+
}
|
|
2180
|
+
return message;
|
|
2181
|
+
}
|
|
2182
|
+
toObject() {
|
|
2183
|
+
const data = {};
|
|
2184
|
+
if (this.deviceType != null) {
|
|
2185
|
+
data.deviceType = this.deviceType;
|
|
2186
|
+
}
|
|
2187
|
+
if (this.quantity != null) {
|
|
2188
|
+
data.quantity = this.quantity;
|
|
2189
|
+
}
|
|
2190
|
+
if (this.available != null) {
|
|
2191
|
+
data.available = this.available;
|
|
2192
|
+
}
|
|
2193
|
+
return data;
|
|
2194
|
+
}
|
|
2195
|
+
serialize(w) {
|
|
2196
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
2197
|
+
if (this.deviceType.length)
|
|
2198
|
+
writer.writeString(1, this.deviceType);
|
|
2199
|
+
if (this.quantity != 0)
|
|
2200
|
+
writer.writeInt32(2, this.quantity);
|
|
2201
|
+
if (this.available != false)
|
|
2202
|
+
writer.writeBool(3, this.available);
|
|
2203
|
+
if (!w)
|
|
2204
|
+
return writer.getResultBuffer();
|
|
2205
|
+
}
|
|
2206
|
+
static deserialize(bytes) {
|
|
2207
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new AvailabilityData();
|
|
2208
|
+
while (reader.nextField()) {
|
|
2209
|
+
if (reader.isEndGroup())
|
|
2210
|
+
break;
|
|
2211
|
+
switch (reader.getFieldNumber()) {
|
|
2212
|
+
case 1:
|
|
2213
|
+
message.deviceType = reader.readString();
|
|
2214
|
+
break;
|
|
2215
|
+
case 2:
|
|
2216
|
+
message.quantity = reader.readInt32();
|
|
2217
|
+
break;
|
|
2218
|
+
case 3:
|
|
2219
|
+
message.available = reader.readBool();
|
|
2220
|
+
break;
|
|
2221
|
+
default: reader.skipField();
|
|
2222
|
+
}
|
|
2223
|
+
}
|
|
2224
|
+
return message;
|
|
2225
|
+
}
|
|
2226
|
+
serializeBinary() {
|
|
2227
|
+
return this.serialize();
|
|
2228
|
+
}
|
|
2229
|
+
static deserializeBinary(bytes) {
|
|
2230
|
+
return AvailabilityData.deserialize(bytes);
|
|
2231
|
+
}
|
|
2232
|
+
}
|
|
2233
|
+
terminalTypes.AvailabilityData = AvailabilityData;
|
|
2234
|
+
class SpecificationsData extends pb_1.Message {
|
|
2235
|
+
#one_of_decls = [];
|
|
2236
|
+
constructor(data) {
|
|
2237
|
+
super();
|
|
2238
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [5, 6], this.#one_of_decls);
|
|
2239
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
2240
|
+
if ("deviceType" in data && data.deviceType != undefined) {
|
|
2241
|
+
this.deviceType = data.deviceType;
|
|
2242
|
+
}
|
|
2243
|
+
if ("manufacturer" in data && data.manufacturer != undefined) {
|
|
2244
|
+
this.manufacturer = data.manufacturer;
|
|
2245
|
+
}
|
|
2246
|
+
if ("model" in data && data.model != undefined) {
|
|
2247
|
+
this.model = data.model;
|
|
2248
|
+
}
|
|
2249
|
+
if ("description" in data && data.description != undefined) {
|
|
2250
|
+
this.description = data.description;
|
|
2251
|
+
}
|
|
2252
|
+
if ("features" in data && data.features != undefined) {
|
|
2253
|
+
this.features = data.features;
|
|
2254
|
+
}
|
|
2255
|
+
if ("compatibleSoftware" in data && data.compatibleSoftware != undefined) {
|
|
2256
|
+
this.compatibleSoftware = data.compatibleSoftware;
|
|
2257
|
+
}
|
|
2258
|
+
if ("technicalSpecifications" in data && data.technicalSpecifications != undefined) {
|
|
2259
|
+
this.technicalSpecifications = data.technicalSpecifications;
|
|
2260
|
+
}
|
|
2261
|
+
if ("firmwareVersion" in data && data.firmwareVersion != undefined) {
|
|
2262
|
+
this.firmwareVersion = data.firmwareVersion;
|
|
2263
|
+
}
|
|
2264
|
+
if ("warrantyMonths" in data && data.warrantyMonths != undefined) {
|
|
2265
|
+
this.warrantyMonths = data.warrantyMonths;
|
|
2266
|
+
}
|
|
2267
|
+
if ("category" in data && data.category != undefined) {
|
|
2268
|
+
this.category = data.category;
|
|
2269
|
+
}
|
|
2270
|
+
}
|
|
2271
|
+
}
|
|
2272
|
+
get deviceType() {
|
|
2273
|
+
return pb_1.Message.getFieldWithDefault(this, 1, "");
|
|
2274
|
+
}
|
|
2275
|
+
set deviceType(value) {
|
|
2276
|
+
pb_1.Message.setField(this, 1, value);
|
|
2277
|
+
}
|
|
2278
|
+
get manufacturer() {
|
|
2279
|
+
return pb_1.Message.getFieldWithDefault(this, 2, "");
|
|
2280
|
+
}
|
|
2281
|
+
set manufacturer(value) {
|
|
2282
|
+
pb_1.Message.setField(this, 2, value);
|
|
2283
|
+
}
|
|
2284
|
+
get model() {
|
|
2285
|
+
return pb_1.Message.getFieldWithDefault(this, 3, "");
|
|
2286
|
+
}
|
|
2287
|
+
set model(value) {
|
|
2288
|
+
pb_1.Message.setField(this, 3, value);
|
|
2289
|
+
}
|
|
2290
|
+
get description() {
|
|
2291
|
+
return pb_1.Message.getFieldWithDefault(this, 4, "");
|
|
2292
|
+
}
|
|
2293
|
+
set description(value) {
|
|
2294
|
+
pb_1.Message.setField(this, 4, value);
|
|
2295
|
+
}
|
|
2296
|
+
get features() {
|
|
2297
|
+
return pb_1.Message.getFieldWithDefault(this, 5, []);
|
|
2298
|
+
}
|
|
2299
|
+
set features(value) {
|
|
2300
|
+
pb_1.Message.setField(this, 5, value);
|
|
2301
|
+
}
|
|
2302
|
+
get compatibleSoftware() {
|
|
2303
|
+
return pb_1.Message.getFieldWithDefault(this, 6, []);
|
|
2304
|
+
}
|
|
2305
|
+
set compatibleSoftware(value) {
|
|
2306
|
+
pb_1.Message.setField(this, 6, value);
|
|
2307
|
+
}
|
|
2308
|
+
get technicalSpecifications() {
|
|
2309
|
+
return pb_1.Message.getFieldWithDefault(this, 7, "");
|
|
2310
|
+
}
|
|
2311
|
+
set technicalSpecifications(value) {
|
|
2312
|
+
pb_1.Message.setField(this, 7, value);
|
|
2313
|
+
}
|
|
2314
|
+
get firmwareVersion() {
|
|
2315
|
+
return pb_1.Message.getFieldWithDefault(this, 8, "");
|
|
2316
|
+
}
|
|
2317
|
+
set firmwareVersion(value) {
|
|
2318
|
+
pb_1.Message.setField(this, 8, value);
|
|
2319
|
+
}
|
|
2320
|
+
get warrantyMonths() {
|
|
2321
|
+
return pb_1.Message.getFieldWithDefault(this, 9, 0);
|
|
2322
|
+
}
|
|
2323
|
+
set warrantyMonths(value) {
|
|
2324
|
+
pb_1.Message.setField(this, 9, value);
|
|
2325
|
+
}
|
|
2326
|
+
get category() {
|
|
2327
|
+
return pb_1.Message.getFieldWithDefault(this, 10, "");
|
|
2328
|
+
}
|
|
2329
|
+
set category(value) {
|
|
2330
|
+
pb_1.Message.setField(this, 10, value);
|
|
2331
|
+
}
|
|
2332
|
+
static fromObject(data) {
|
|
2333
|
+
const message = new SpecificationsData({});
|
|
2334
|
+
if (data.deviceType != null) {
|
|
2335
|
+
message.deviceType = data.deviceType;
|
|
2336
|
+
}
|
|
2337
|
+
if (data.manufacturer != null) {
|
|
2338
|
+
message.manufacturer = data.manufacturer;
|
|
2339
|
+
}
|
|
2340
|
+
if (data.model != null) {
|
|
2341
|
+
message.model = data.model;
|
|
2342
|
+
}
|
|
2343
|
+
if (data.description != null) {
|
|
2344
|
+
message.description = data.description;
|
|
2345
|
+
}
|
|
2346
|
+
if (data.features != null) {
|
|
2347
|
+
message.features = data.features;
|
|
2348
|
+
}
|
|
2349
|
+
if (data.compatibleSoftware != null) {
|
|
2350
|
+
message.compatibleSoftware = data.compatibleSoftware;
|
|
2351
|
+
}
|
|
2352
|
+
if (data.technicalSpecifications != null) {
|
|
2353
|
+
message.technicalSpecifications = data.technicalSpecifications;
|
|
2354
|
+
}
|
|
2355
|
+
if (data.firmwareVersion != null) {
|
|
2356
|
+
message.firmwareVersion = data.firmwareVersion;
|
|
2357
|
+
}
|
|
2358
|
+
if (data.warrantyMonths != null) {
|
|
2359
|
+
message.warrantyMonths = data.warrantyMonths;
|
|
2360
|
+
}
|
|
2361
|
+
if (data.category != null) {
|
|
2362
|
+
message.category = data.category;
|
|
2363
|
+
}
|
|
2364
|
+
return message;
|
|
2365
|
+
}
|
|
2366
|
+
toObject() {
|
|
2367
|
+
const data = {};
|
|
2368
|
+
if (this.deviceType != null) {
|
|
2369
|
+
data.deviceType = this.deviceType;
|
|
2370
|
+
}
|
|
2371
|
+
if (this.manufacturer != null) {
|
|
2372
|
+
data.manufacturer = this.manufacturer;
|
|
2373
|
+
}
|
|
2374
|
+
if (this.model != null) {
|
|
2375
|
+
data.model = this.model;
|
|
2376
|
+
}
|
|
2377
|
+
if (this.description != null) {
|
|
2378
|
+
data.description = this.description;
|
|
2379
|
+
}
|
|
2380
|
+
if (this.features != null) {
|
|
2381
|
+
data.features = this.features;
|
|
2382
|
+
}
|
|
2383
|
+
if (this.compatibleSoftware != null) {
|
|
2384
|
+
data.compatibleSoftware = this.compatibleSoftware;
|
|
2385
|
+
}
|
|
2386
|
+
if (this.technicalSpecifications != null) {
|
|
2387
|
+
data.technicalSpecifications = this.technicalSpecifications;
|
|
2388
|
+
}
|
|
2389
|
+
if (this.firmwareVersion != null) {
|
|
2390
|
+
data.firmwareVersion = this.firmwareVersion;
|
|
2391
|
+
}
|
|
2392
|
+
if (this.warrantyMonths != null) {
|
|
2393
|
+
data.warrantyMonths = this.warrantyMonths;
|
|
2394
|
+
}
|
|
2395
|
+
if (this.category != null) {
|
|
2396
|
+
data.category = this.category;
|
|
2397
|
+
}
|
|
2398
|
+
return data;
|
|
2399
|
+
}
|
|
2400
|
+
serialize(w) {
|
|
2401
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
2402
|
+
if (this.deviceType.length)
|
|
2403
|
+
writer.writeString(1, this.deviceType);
|
|
2404
|
+
if (this.manufacturer.length)
|
|
2405
|
+
writer.writeString(2, this.manufacturer);
|
|
2406
|
+
if (this.model.length)
|
|
2407
|
+
writer.writeString(3, this.model);
|
|
2408
|
+
if (this.description.length)
|
|
2409
|
+
writer.writeString(4, this.description);
|
|
2410
|
+
if (this.features.length)
|
|
2411
|
+
writer.writeRepeatedString(5, this.features);
|
|
2412
|
+
if (this.compatibleSoftware.length)
|
|
2413
|
+
writer.writeRepeatedString(6, this.compatibleSoftware);
|
|
2414
|
+
if (this.technicalSpecifications.length)
|
|
2415
|
+
writer.writeString(7, this.technicalSpecifications);
|
|
2416
|
+
if (this.firmwareVersion.length)
|
|
2417
|
+
writer.writeString(8, this.firmwareVersion);
|
|
2418
|
+
if (this.warrantyMonths != 0)
|
|
2419
|
+
writer.writeInt32(9, this.warrantyMonths);
|
|
2420
|
+
if (this.category.length)
|
|
2421
|
+
writer.writeString(10, this.category);
|
|
2422
|
+
if (!w)
|
|
2423
|
+
return writer.getResultBuffer();
|
|
2424
|
+
}
|
|
2425
|
+
static deserialize(bytes) {
|
|
2426
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new SpecificationsData();
|
|
2427
|
+
while (reader.nextField()) {
|
|
2428
|
+
if (reader.isEndGroup())
|
|
2429
|
+
break;
|
|
2430
|
+
switch (reader.getFieldNumber()) {
|
|
2431
|
+
case 1:
|
|
2432
|
+
message.deviceType = reader.readString();
|
|
2433
|
+
break;
|
|
2434
|
+
case 2:
|
|
2435
|
+
message.manufacturer = reader.readString();
|
|
2436
|
+
break;
|
|
2437
|
+
case 3:
|
|
2438
|
+
message.model = reader.readString();
|
|
2439
|
+
break;
|
|
2440
|
+
case 4:
|
|
2441
|
+
message.description = reader.readString();
|
|
2442
|
+
break;
|
|
2443
|
+
case 5:
|
|
2444
|
+
pb_1.Message.addToRepeatedField(message, 5, reader.readString());
|
|
2445
|
+
break;
|
|
2446
|
+
case 6:
|
|
2447
|
+
pb_1.Message.addToRepeatedField(message, 6, reader.readString());
|
|
2448
|
+
break;
|
|
2449
|
+
case 7:
|
|
2450
|
+
message.technicalSpecifications = reader.readString();
|
|
2451
|
+
break;
|
|
2452
|
+
case 8:
|
|
2453
|
+
message.firmwareVersion = reader.readString();
|
|
2454
|
+
break;
|
|
2455
|
+
case 9:
|
|
2456
|
+
message.warrantyMonths = reader.readInt32();
|
|
2457
|
+
break;
|
|
2458
|
+
case 10:
|
|
2459
|
+
message.category = reader.readString();
|
|
2460
|
+
break;
|
|
2461
|
+
default: reader.skipField();
|
|
2462
|
+
}
|
|
2463
|
+
}
|
|
2464
|
+
return message;
|
|
2465
|
+
}
|
|
2466
|
+
serializeBinary() {
|
|
2467
|
+
return this.serialize();
|
|
2468
|
+
}
|
|
2469
|
+
static deserializeBinary(bytes) {
|
|
2470
|
+
return SpecificationsData.deserialize(bytes);
|
|
2471
|
+
}
|
|
2472
|
+
}
|
|
2473
|
+
terminalTypes.SpecificationsData = SpecificationsData;
|
|
2474
|
+
class StatsData extends pb_1.Message {
|
|
2475
|
+
#one_of_decls = [];
|
|
2476
|
+
constructor(data) {
|
|
2477
|
+
super();
|
|
2478
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [8], this.#one_of_decls);
|
|
2479
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
2480
|
+
if ("totalTypes" in data && data.totalTypes != undefined) {
|
|
2481
|
+
this.totalTypes = data.totalTypes;
|
|
2482
|
+
}
|
|
2483
|
+
if ("activeTypes" in data && data.activeTypes != undefined) {
|
|
2484
|
+
this.activeTypes = data.activeTypes;
|
|
2485
|
+
}
|
|
2486
|
+
if ("discontinuedTypes" in data && data.discontinuedTypes != undefined) {
|
|
2487
|
+
this.discontinuedTypes = data.discontinuedTypes;
|
|
2488
|
+
}
|
|
2489
|
+
if ("lowStockTypes" in data && data.lowStockTypes != undefined) {
|
|
2490
|
+
this.lowStockTypes = data.lowStockTypes;
|
|
2491
|
+
}
|
|
2492
|
+
if ("totalStock" in data && data.totalStock != undefined) {
|
|
2493
|
+
this.totalStock = data.totalStock;
|
|
2494
|
+
}
|
|
2495
|
+
if ("reservedStock" in data && data.reservedStock != undefined) {
|
|
2496
|
+
this.reservedStock = data.reservedStock;
|
|
2497
|
+
}
|
|
2498
|
+
if ("availableStock" in data && data.availableStock != undefined) {
|
|
2499
|
+
this.availableStock = data.availableStock;
|
|
2500
|
+
}
|
|
2501
|
+
if ("categoryStats" in data && data.categoryStats != undefined) {
|
|
2502
|
+
this.categoryStats = data.categoryStats;
|
|
2503
|
+
}
|
|
2504
|
+
}
|
|
2505
|
+
}
|
|
2506
|
+
get totalTypes() {
|
|
2507
|
+
return pb_1.Message.getFieldWithDefault(this, 1, 0);
|
|
2508
|
+
}
|
|
2509
|
+
set totalTypes(value) {
|
|
2510
|
+
pb_1.Message.setField(this, 1, value);
|
|
2511
|
+
}
|
|
2512
|
+
get activeTypes() {
|
|
2513
|
+
return pb_1.Message.getFieldWithDefault(this, 2, 0);
|
|
2514
|
+
}
|
|
2515
|
+
set activeTypes(value) {
|
|
2516
|
+
pb_1.Message.setField(this, 2, value);
|
|
2517
|
+
}
|
|
2518
|
+
get discontinuedTypes() {
|
|
2519
|
+
return pb_1.Message.getFieldWithDefault(this, 3, 0);
|
|
2520
|
+
}
|
|
2521
|
+
set discontinuedTypes(value) {
|
|
2522
|
+
pb_1.Message.setField(this, 3, value);
|
|
2523
|
+
}
|
|
2524
|
+
get lowStockTypes() {
|
|
2525
|
+
return pb_1.Message.getFieldWithDefault(this, 4, 0);
|
|
2526
|
+
}
|
|
2527
|
+
set lowStockTypes(value) {
|
|
2528
|
+
pb_1.Message.setField(this, 4, value);
|
|
2529
|
+
}
|
|
2530
|
+
get totalStock() {
|
|
2531
|
+
return pb_1.Message.getFieldWithDefault(this, 5, 0);
|
|
2532
|
+
}
|
|
2533
|
+
set totalStock(value) {
|
|
2534
|
+
pb_1.Message.setField(this, 5, value);
|
|
2535
|
+
}
|
|
2536
|
+
get reservedStock() {
|
|
2537
|
+
return pb_1.Message.getFieldWithDefault(this, 6, 0);
|
|
2538
|
+
}
|
|
2539
|
+
set reservedStock(value) {
|
|
2540
|
+
pb_1.Message.setField(this, 6, value);
|
|
2541
|
+
}
|
|
2542
|
+
get availableStock() {
|
|
2543
|
+
return pb_1.Message.getFieldWithDefault(this, 7, 0);
|
|
2544
|
+
}
|
|
2545
|
+
set availableStock(value) {
|
|
2546
|
+
pb_1.Message.setField(this, 7, value);
|
|
2547
|
+
}
|
|
2548
|
+
get categoryStats() {
|
|
2549
|
+
return pb_1.Message.getRepeatedWrapperField(this, CategoryStats, 8);
|
|
2550
|
+
}
|
|
2551
|
+
set categoryStats(value) {
|
|
2552
|
+
pb_1.Message.setRepeatedWrapperField(this, 8, value);
|
|
2553
|
+
}
|
|
2554
|
+
static fromObject(data) {
|
|
2555
|
+
const message = new StatsData({});
|
|
2556
|
+
if (data.totalTypes != null) {
|
|
2557
|
+
message.totalTypes = data.totalTypes;
|
|
2558
|
+
}
|
|
2559
|
+
if (data.activeTypes != null) {
|
|
2560
|
+
message.activeTypes = data.activeTypes;
|
|
2561
|
+
}
|
|
2562
|
+
if (data.discontinuedTypes != null) {
|
|
2563
|
+
message.discontinuedTypes = data.discontinuedTypes;
|
|
2564
|
+
}
|
|
2565
|
+
if (data.lowStockTypes != null) {
|
|
2566
|
+
message.lowStockTypes = data.lowStockTypes;
|
|
2567
|
+
}
|
|
2568
|
+
if (data.totalStock != null) {
|
|
2569
|
+
message.totalStock = data.totalStock;
|
|
2570
|
+
}
|
|
2571
|
+
if (data.reservedStock != null) {
|
|
2572
|
+
message.reservedStock = data.reservedStock;
|
|
2573
|
+
}
|
|
2574
|
+
if (data.availableStock != null) {
|
|
2575
|
+
message.availableStock = data.availableStock;
|
|
2576
|
+
}
|
|
2577
|
+
if (data.categoryStats != null) {
|
|
2578
|
+
message.categoryStats = data.categoryStats.map(item => CategoryStats.fromObject(item));
|
|
2579
|
+
}
|
|
2580
|
+
return message;
|
|
2581
|
+
}
|
|
2582
|
+
toObject() {
|
|
2583
|
+
const data = {};
|
|
2584
|
+
if (this.totalTypes != null) {
|
|
2585
|
+
data.totalTypes = this.totalTypes;
|
|
2586
|
+
}
|
|
2587
|
+
if (this.activeTypes != null) {
|
|
2588
|
+
data.activeTypes = this.activeTypes;
|
|
2589
|
+
}
|
|
2590
|
+
if (this.discontinuedTypes != null) {
|
|
2591
|
+
data.discontinuedTypes = this.discontinuedTypes;
|
|
2592
|
+
}
|
|
2593
|
+
if (this.lowStockTypes != null) {
|
|
2594
|
+
data.lowStockTypes = this.lowStockTypes;
|
|
2595
|
+
}
|
|
2596
|
+
if (this.totalStock != null) {
|
|
2597
|
+
data.totalStock = this.totalStock;
|
|
2598
|
+
}
|
|
2599
|
+
if (this.reservedStock != null) {
|
|
2600
|
+
data.reservedStock = this.reservedStock;
|
|
2601
|
+
}
|
|
2602
|
+
if (this.availableStock != null) {
|
|
2603
|
+
data.availableStock = this.availableStock;
|
|
2604
|
+
}
|
|
2605
|
+
if (this.categoryStats != null) {
|
|
2606
|
+
data.categoryStats = this.categoryStats.map((item) => item.toObject());
|
|
2607
|
+
}
|
|
2608
|
+
return data;
|
|
2609
|
+
}
|
|
2610
|
+
serialize(w) {
|
|
2611
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
2612
|
+
if (this.totalTypes != 0)
|
|
2613
|
+
writer.writeInt32(1, this.totalTypes);
|
|
2614
|
+
if (this.activeTypes != 0)
|
|
2615
|
+
writer.writeInt32(2, this.activeTypes);
|
|
2616
|
+
if (this.discontinuedTypes != 0)
|
|
2617
|
+
writer.writeInt32(3, this.discontinuedTypes);
|
|
2618
|
+
if (this.lowStockTypes != 0)
|
|
2619
|
+
writer.writeInt32(4, this.lowStockTypes);
|
|
2620
|
+
if (this.totalStock != 0)
|
|
2621
|
+
writer.writeInt32(5, this.totalStock);
|
|
2622
|
+
if (this.reservedStock != 0)
|
|
2623
|
+
writer.writeInt32(6, this.reservedStock);
|
|
2624
|
+
if (this.availableStock != 0)
|
|
2625
|
+
writer.writeInt32(7, this.availableStock);
|
|
2626
|
+
if (this.categoryStats.length)
|
|
2627
|
+
writer.writeRepeatedMessage(8, this.categoryStats, (item) => item.serialize(writer));
|
|
2628
|
+
if (!w)
|
|
2629
|
+
return writer.getResultBuffer();
|
|
2630
|
+
}
|
|
2631
|
+
static deserialize(bytes) {
|
|
2632
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new StatsData();
|
|
2633
|
+
while (reader.nextField()) {
|
|
2634
|
+
if (reader.isEndGroup())
|
|
2635
|
+
break;
|
|
2636
|
+
switch (reader.getFieldNumber()) {
|
|
2637
|
+
case 1:
|
|
2638
|
+
message.totalTypes = reader.readInt32();
|
|
2639
|
+
break;
|
|
2640
|
+
case 2:
|
|
2641
|
+
message.activeTypes = reader.readInt32();
|
|
2642
|
+
break;
|
|
2643
|
+
case 3:
|
|
2644
|
+
message.discontinuedTypes = reader.readInt32();
|
|
2645
|
+
break;
|
|
2646
|
+
case 4:
|
|
2647
|
+
message.lowStockTypes = reader.readInt32();
|
|
2648
|
+
break;
|
|
2649
|
+
case 5:
|
|
2650
|
+
message.totalStock = reader.readInt32();
|
|
2651
|
+
break;
|
|
2652
|
+
case 6:
|
|
2653
|
+
message.reservedStock = reader.readInt32();
|
|
2654
|
+
break;
|
|
2655
|
+
case 7:
|
|
2656
|
+
message.availableStock = reader.readInt32();
|
|
2657
|
+
break;
|
|
2658
|
+
case 8:
|
|
2659
|
+
reader.readMessage(message.categoryStats, () => pb_1.Message.addToRepeatedWrapperField(message, 8, CategoryStats.deserialize(reader), CategoryStats));
|
|
2660
|
+
break;
|
|
2661
|
+
default: reader.skipField();
|
|
2662
|
+
}
|
|
2663
|
+
}
|
|
2664
|
+
return message;
|
|
2665
|
+
}
|
|
2666
|
+
serializeBinary() {
|
|
2667
|
+
return this.serialize();
|
|
2668
|
+
}
|
|
2669
|
+
static deserializeBinary(bytes) {
|
|
2670
|
+
return StatsData.deserialize(bytes);
|
|
2671
|
+
}
|
|
2672
|
+
}
|
|
2673
|
+
terminalTypes.StatsData = StatsData;
|
|
2674
|
+
class CategoryStats extends pb_1.Message {
|
|
2675
|
+
#one_of_decls = [];
|
|
2676
|
+
constructor(data) {
|
|
2677
|
+
super();
|
|
2678
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
2679
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
2680
|
+
if ("category" in data && data.category != undefined) {
|
|
2681
|
+
this.category = data.category;
|
|
2682
|
+
}
|
|
2683
|
+
if ("typeCount" in data && data.typeCount != undefined) {
|
|
2684
|
+
this.typeCount = data.typeCount;
|
|
2685
|
+
}
|
|
2686
|
+
if ("totalStock" in data && data.totalStock != undefined) {
|
|
2687
|
+
this.totalStock = data.totalStock;
|
|
2688
|
+
}
|
|
2689
|
+
if ("availableStock" in data && data.availableStock != undefined) {
|
|
2690
|
+
this.availableStock = data.availableStock;
|
|
2691
|
+
}
|
|
2692
|
+
}
|
|
2693
|
+
}
|
|
2694
|
+
get category() {
|
|
2695
|
+
return pb_1.Message.getFieldWithDefault(this, 1, "");
|
|
2696
|
+
}
|
|
2697
|
+
set category(value) {
|
|
2698
|
+
pb_1.Message.setField(this, 1, value);
|
|
2699
|
+
}
|
|
2700
|
+
get typeCount() {
|
|
2701
|
+
return pb_1.Message.getFieldWithDefault(this, 2, 0);
|
|
2702
|
+
}
|
|
2703
|
+
set typeCount(value) {
|
|
2704
|
+
pb_1.Message.setField(this, 2, value);
|
|
2705
|
+
}
|
|
2706
|
+
get totalStock() {
|
|
2707
|
+
return pb_1.Message.getFieldWithDefault(this, 3, 0);
|
|
2708
|
+
}
|
|
2709
|
+
set totalStock(value) {
|
|
2710
|
+
pb_1.Message.setField(this, 3, value);
|
|
2711
|
+
}
|
|
2712
|
+
get availableStock() {
|
|
2713
|
+
return pb_1.Message.getFieldWithDefault(this, 4, 0);
|
|
2714
|
+
}
|
|
2715
|
+
set availableStock(value) {
|
|
2716
|
+
pb_1.Message.setField(this, 4, value);
|
|
2717
|
+
}
|
|
2718
|
+
static fromObject(data) {
|
|
2719
|
+
const message = new CategoryStats({});
|
|
2720
|
+
if (data.category != null) {
|
|
2721
|
+
message.category = data.category;
|
|
2722
|
+
}
|
|
2723
|
+
if (data.typeCount != null) {
|
|
2724
|
+
message.typeCount = data.typeCount;
|
|
2725
|
+
}
|
|
2726
|
+
if (data.totalStock != null) {
|
|
2727
|
+
message.totalStock = data.totalStock;
|
|
2728
|
+
}
|
|
2729
|
+
if (data.availableStock != null) {
|
|
2730
|
+
message.availableStock = data.availableStock;
|
|
2731
|
+
}
|
|
2732
|
+
return message;
|
|
2733
|
+
}
|
|
2734
|
+
toObject() {
|
|
2735
|
+
const data = {};
|
|
2736
|
+
if (this.category != null) {
|
|
2737
|
+
data.category = this.category;
|
|
2738
|
+
}
|
|
2739
|
+
if (this.typeCount != null) {
|
|
2740
|
+
data.typeCount = this.typeCount;
|
|
2741
|
+
}
|
|
2742
|
+
if (this.totalStock != null) {
|
|
2743
|
+
data.totalStock = this.totalStock;
|
|
2744
|
+
}
|
|
2745
|
+
if (this.availableStock != null) {
|
|
2746
|
+
data.availableStock = this.availableStock;
|
|
2747
|
+
}
|
|
2748
|
+
return data;
|
|
2749
|
+
}
|
|
2750
|
+
serialize(w) {
|
|
2751
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
2752
|
+
if (this.category.length)
|
|
2753
|
+
writer.writeString(1, this.category);
|
|
2754
|
+
if (this.typeCount != 0)
|
|
2755
|
+
writer.writeInt32(2, this.typeCount);
|
|
2756
|
+
if (this.totalStock != 0)
|
|
2757
|
+
writer.writeInt32(3, this.totalStock);
|
|
2758
|
+
if (this.availableStock != 0)
|
|
2759
|
+
writer.writeInt32(4, this.availableStock);
|
|
2760
|
+
if (!w)
|
|
2761
|
+
return writer.getResultBuffer();
|
|
2762
|
+
}
|
|
2763
|
+
static deserialize(bytes) {
|
|
2764
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new CategoryStats();
|
|
2765
|
+
while (reader.nextField()) {
|
|
2766
|
+
if (reader.isEndGroup())
|
|
2767
|
+
break;
|
|
2768
|
+
switch (reader.getFieldNumber()) {
|
|
2769
|
+
case 1:
|
|
2770
|
+
message.category = reader.readString();
|
|
2771
|
+
break;
|
|
2772
|
+
case 2:
|
|
2773
|
+
message.typeCount = reader.readInt32();
|
|
2774
|
+
break;
|
|
2775
|
+
case 3:
|
|
2776
|
+
message.totalStock = reader.readInt32();
|
|
2777
|
+
break;
|
|
2778
|
+
case 4:
|
|
2779
|
+
message.availableStock = reader.readInt32();
|
|
2780
|
+
break;
|
|
2781
|
+
default: reader.skipField();
|
|
2782
|
+
}
|
|
2783
|
+
}
|
|
2784
|
+
return message;
|
|
2785
|
+
}
|
|
2786
|
+
serializeBinary() {
|
|
2787
|
+
return this.serialize();
|
|
2788
|
+
}
|
|
2789
|
+
static deserializeBinary(bytes) {
|
|
2790
|
+
return CategoryStats.deserialize(bytes);
|
|
2791
|
+
}
|
|
2792
|
+
}
|
|
2793
|
+
terminalTypes.CategoryStats = CategoryStats;
|
|
2794
|
+
class TerminalTypeResponse extends pb_1.Message {
|
|
2795
|
+
#one_of_decls = [];
|
|
2796
|
+
constructor(data) {
|
|
2797
|
+
super();
|
|
2798
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
2799
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
2800
|
+
if ("success" in data && data.success != undefined) {
|
|
2801
|
+
this.success = data.success;
|
|
2802
|
+
}
|
|
2803
|
+
if ("message" in data && data.message != undefined) {
|
|
2804
|
+
this.message = data.message;
|
|
2805
|
+
}
|
|
2806
|
+
if ("data" in data && data.data != undefined) {
|
|
2807
|
+
this.data = data.data;
|
|
2808
|
+
}
|
|
2809
|
+
if ("error" in data && data.error != undefined) {
|
|
2810
|
+
this.error = data.error;
|
|
2811
|
+
}
|
|
2812
|
+
}
|
|
2813
|
+
}
|
|
2814
|
+
get success() {
|
|
2815
|
+
return pb_1.Message.getFieldWithDefault(this, 1, false);
|
|
2816
|
+
}
|
|
2817
|
+
set success(value) {
|
|
2818
|
+
pb_1.Message.setField(this, 1, value);
|
|
2819
|
+
}
|
|
2820
|
+
get message() {
|
|
2821
|
+
return pb_1.Message.getFieldWithDefault(this, 2, "");
|
|
2822
|
+
}
|
|
2823
|
+
set message(value) {
|
|
2824
|
+
pb_1.Message.setField(this, 2, value);
|
|
2825
|
+
}
|
|
2826
|
+
get data() {
|
|
2827
|
+
return pb_1.Message.getWrapperField(this, TerminalTypeData, 3);
|
|
2828
|
+
}
|
|
2829
|
+
set data(value) {
|
|
2830
|
+
pb_1.Message.setWrapperField(this, 3, value);
|
|
2831
|
+
}
|
|
2832
|
+
get hasData() {
|
|
2833
|
+
return pb_1.Message.getField(this, 3) != null;
|
|
2834
|
+
}
|
|
2835
|
+
get error() {
|
|
2836
|
+
return pb_1.Message.getFieldWithDefault(this, 4, "");
|
|
2837
|
+
}
|
|
2838
|
+
set error(value) {
|
|
2839
|
+
pb_1.Message.setField(this, 4, value);
|
|
2840
|
+
}
|
|
2841
|
+
static fromObject(data) {
|
|
2842
|
+
const message = new TerminalTypeResponse({});
|
|
2843
|
+
if (data.success != null) {
|
|
2844
|
+
message.success = data.success;
|
|
2845
|
+
}
|
|
2846
|
+
if (data.message != null) {
|
|
2847
|
+
message.message = data.message;
|
|
2848
|
+
}
|
|
2849
|
+
if (data.data != null) {
|
|
2850
|
+
message.data = TerminalTypeData.fromObject(data.data);
|
|
2851
|
+
}
|
|
2852
|
+
if (data.error != null) {
|
|
2853
|
+
message.error = data.error;
|
|
2854
|
+
}
|
|
2855
|
+
return message;
|
|
2856
|
+
}
|
|
2857
|
+
toObject() {
|
|
2858
|
+
const data = {};
|
|
2859
|
+
if (this.success != null) {
|
|
2860
|
+
data.success = this.success;
|
|
2861
|
+
}
|
|
2862
|
+
if (this.message != null) {
|
|
2863
|
+
data.message = this.message;
|
|
2864
|
+
}
|
|
2865
|
+
if (this.data != null) {
|
|
2866
|
+
data.data = this.data.toObject();
|
|
2867
|
+
}
|
|
2868
|
+
if (this.error != null) {
|
|
2869
|
+
data.error = this.error;
|
|
2870
|
+
}
|
|
2871
|
+
return data;
|
|
2872
|
+
}
|
|
2873
|
+
serialize(w) {
|
|
2874
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
2875
|
+
if (this.success != false)
|
|
2876
|
+
writer.writeBool(1, this.success);
|
|
2877
|
+
if (this.message.length)
|
|
2878
|
+
writer.writeString(2, this.message);
|
|
2879
|
+
if (this.hasData)
|
|
2880
|
+
writer.writeMessage(3, this.data, () => this.data.serialize(writer));
|
|
2881
|
+
if (this.error.length)
|
|
2882
|
+
writer.writeString(4, this.error);
|
|
2883
|
+
if (!w)
|
|
2884
|
+
return writer.getResultBuffer();
|
|
2885
|
+
}
|
|
2886
|
+
static deserialize(bytes) {
|
|
2887
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new TerminalTypeResponse();
|
|
2888
|
+
while (reader.nextField()) {
|
|
2889
|
+
if (reader.isEndGroup())
|
|
2890
|
+
break;
|
|
2891
|
+
switch (reader.getFieldNumber()) {
|
|
2892
|
+
case 1:
|
|
2893
|
+
message.success = reader.readBool();
|
|
2894
|
+
break;
|
|
2895
|
+
case 2:
|
|
2896
|
+
message.message = reader.readString();
|
|
2897
|
+
break;
|
|
2898
|
+
case 3:
|
|
2899
|
+
reader.readMessage(message.data, () => message.data = TerminalTypeData.deserialize(reader));
|
|
2900
|
+
break;
|
|
2901
|
+
case 4:
|
|
2902
|
+
message.error = reader.readString();
|
|
2903
|
+
break;
|
|
2904
|
+
default: reader.skipField();
|
|
2905
|
+
}
|
|
2906
|
+
}
|
|
2907
|
+
return message;
|
|
2908
|
+
}
|
|
2909
|
+
serializeBinary() {
|
|
2910
|
+
return this.serialize();
|
|
2911
|
+
}
|
|
2912
|
+
static deserializeBinary(bytes) {
|
|
2913
|
+
return TerminalTypeResponse.deserialize(bytes);
|
|
2914
|
+
}
|
|
2915
|
+
}
|
|
2916
|
+
terminalTypes.TerminalTypeResponse = TerminalTypeResponse;
|
|
2917
|
+
class TerminalTypesResponse extends pb_1.Message {
|
|
2918
|
+
#one_of_decls = [];
|
|
2919
|
+
constructor(data) {
|
|
2920
|
+
super();
|
|
2921
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [3], this.#one_of_decls);
|
|
2922
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
2923
|
+
if ("success" in data && data.success != undefined) {
|
|
2924
|
+
this.success = data.success;
|
|
2925
|
+
}
|
|
2926
|
+
if ("message" in data && data.message != undefined) {
|
|
2927
|
+
this.message = data.message;
|
|
2928
|
+
}
|
|
2929
|
+
if ("data" in data && data.data != undefined) {
|
|
2930
|
+
this.data = data.data;
|
|
2931
|
+
}
|
|
2932
|
+
if ("count" in data && data.count != undefined) {
|
|
2933
|
+
this.count = data.count;
|
|
2934
|
+
}
|
|
2935
|
+
if ("error" in data && data.error != undefined) {
|
|
2936
|
+
this.error = data.error;
|
|
2937
|
+
}
|
|
2938
|
+
}
|
|
2939
|
+
}
|
|
2940
|
+
get success() {
|
|
2941
|
+
return pb_1.Message.getFieldWithDefault(this, 1, false);
|
|
2942
|
+
}
|
|
2943
|
+
set success(value) {
|
|
2944
|
+
pb_1.Message.setField(this, 1, value);
|
|
2945
|
+
}
|
|
2946
|
+
get message() {
|
|
2947
|
+
return pb_1.Message.getFieldWithDefault(this, 2, "");
|
|
2948
|
+
}
|
|
2949
|
+
set message(value) {
|
|
2950
|
+
pb_1.Message.setField(this, 2, value);
|
|
2951
|
+
}
|
|
2952
|
+
get data() {
|
|
2953
|
+
return pb_1.Message.getRepeatedWrapperField(this, TerminalTypeData, 3);
|
|
2954
|
+
}
|
|
2955
|
+
set data(value) {
|
|
2956
|
+
pb_1.Message.setRepeatedWrapperField(this, 3, value);
|
|
2957
|
+
}
|
|
2958
|
+
get count() {
|
|
2959
|
+
return pb_1.Message.getFieldWithDefault(this, 4, 0);
|
|
2960
|
+
}
|
|
2961
|
+
set count(value) {
|
|
2962
|
+
pb_1.Message.setField(this, 4, value);
|
|
2963
|
+
}
|
|
2964
|
+
get error() {
|
|
2965
|
+
return pb_1.Message.getFieldWithDefault(this, 5, "");
|
|
2966
|
+
}
|
|
2967
|
+
set error(value) {
|
|
2968
|
+
pb_1.Message.setField(this, 5, value);
|
|
2969
|
+
}
|
|
2970
|
+
static fromObject(data) {
|
|
2971
|
+
const message = new TerminalTypesResponse({});
|
|
2972
|
+
if (data.success != null) {
|
|
2973
|
+
message.success = data.success;
|
|
2974
|
+
}
|
|
2975
|
+
if (data.message != null) {
|
|
2976
|
+
message.message = data.message;
|
|
2977
|
+
}
|
|
2978
|
+
if (data.data != null) {
|
|
2979
|
+
message.data = data.data.map(item => TerminalTypeData.fromObject(item));
|
|
2980
|
+
}
|
|
2981
|
+
if (data.count != null) {
|
|
2982
|
+
message.count = data.count;
|
|
2983
|
+
}
|
|
2984
|
+
if (data.error != null) {
|
|
2985
|
+
message.error = data.error;
|
|
2986
|
+
}
|
|
2987
|
+
return message;
|
|
2988
|
+
}
|
|
2989
|
+
toObject() {
|
|
2990
|
+
const data = {};
|
|
2991
|
+
if (this.success != null) {
|
|
2992
|
+
data.success = this.success;
|
|
2993
|
+
}
|
|
2994
|
+
if (this.message != null) {
|
|
2995
|
+
data.message = this.message;
|
|
2996
|
+
}
|
|
2997
|
+
if (this.data != null) {
|
|
2998
|
+
data.data = this.data.map((item) => item.toObject());
|
|
2999
|
+
}
|
|
3000
|
+
if (this.count != null) {
|
|
3001
|
+
data.count = this.count;
|
|
3002
|
+
}
|
|
3003
|
+
if (this.error != null) {
|
|
3004
|
+
data.error = this.error;
|
|
3005
|
+
}
|
|
3006
|
+
return data;
|
|
3007
|
+
}
|
|
3008
|
+
serialize(w) {
|
|
3009
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
3010
|
+
if (this.success != false)
|
|
3011
|
+
writer.writeBool(1, this.success);
|
|
3012
|
+
if (this.message.length)
|
|
3013
|
+
writer.writeString(2, this.message);
|
|
3014
|
+
if (this.data.length)
|
|
3015
|
+
writer.writeRepeatedMessage(3, this.data, (item) => item.serialize(writer));
|
|
3016
|
+
if (this.count != 0)
|
|
3017
|
+
writer.writeInt32(4, this.count);
|
|
3018
|
+
if (this.error.length)
|
|
3019
|
+
writer.writeString(5, this.error);
|
|
3020
|
+
if (!w)
|
|
3021
|
+
return writer.getResultBuffer();
|
|
3022
|
+
}
|
|
3023
|
+
static deserialize(bytes) {
|
|
3024
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new TerminalTypesResponse();
|
|
3025
|
+
while (reader.nextField()) {
|
|
3026
|
+
if (reader.isEndGroup())
|
|
3027
|
+
break;
|
|
3028
|
+
switch (reader.getFieldNumber()) {
|
|
3029
|
+
case 1:
|
|
3030
|
+
message.success = reader.readBool();
|
|
3031
|
+
break;
|
|
3032
|
+
case 2:
|
|
3033
|
+
message.message = reader.readString();
|
|
3034
|
+
break;
|
|
3035
|
+
case 3:
|
|
3036
|
+
reader.readMessage(message.data, () => pb_1.Message.addToRepeatedWrapperField(message, 3, TerminalTypeData.deserialize(reader), TerminalTypeData));
|
|
3037
|
+
break;
|
|
3038
|
+
case 4:
|
|
3039
|
+
message.count = reader.readInt32();
|
|
3040
|
+
break;
|
|
3041
|
+
case 5:
|
|
3042
|
+
message.error = reader.readString();
|
|
3043
|
+
break;
|
|
3044
|
+
default: reader.skipField();
|
|
3045
|
+
}
|
|
3046
|
+
}
|
|
3047
|
+
return message;
|
|
3048
|
+
}
|
|
3049
|
+
serializeBinary() {
|
|
3050
|
+
return this.serialize();
|
|
3051
|
+
}
|
|
3052
|
+
static deserializeBinary(bytes) {
|
|
3053
|
+
return TerminalTypesResponse.deserialize(bytes);
|
|
3054
|
+
}
|
|
3055
|
+
}
|
|
3056
|
+
terminalTypes.TerminalTypesResponse = TerminalTypesResponse;
|
|
3057
|
+
class StockResponse extends pb_1.Message {
|
|
3058
|
+
#one_of_decls = [];
|
|
3059
|
+
constructor(data) {
|
|
3060
|
+
super();
|
|
3061
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
3062
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
3063
|
+
if ("success" in data && data.success != undefined) {
|
|
3064
|
+
this.success = data.success;
|
|
3065
|
+
}
|
|
3066
|
+
if ("message" in data && data.message != undefined) {
|
|
3067
|
+
this.message = data.message;
|
|
3068
|
+
}
|
|
3069
|
+
if ("data" in data && data.data != undefined) {
|
|
3070
|
+
this.data = data.data;
|
|
3071
|
+
}
|
|
3072
|
+
if ("error" in data && data.error != undefined) {
|
|
3073
|
+
this.error = data.error;
|
|
3074
|
+
}
|
|
3075
|
+
}
|
|
3076
|
+
}
|
|
3077
|
+
get success() {
|
|
3078
|
+
return pb_1.Message.getFieldWithDefault(this, 1, false);
|
|
3079
|
+
}
|
|
3080
|
+
set success(value) {
|
|
3081
|
+
pb_1.Message.setField(this, 1, value);
|
|
3082
|
+
}
|
|
3083
|
+
get message() {
|
|
3084
|
+
return pb_1.Message.getFieldWithDefault(this, 2, "");
|
|
3085
|
+
}
|
|
3086
|
+
set message(value) {
|
|
3087
|
+
pb_1.Message.setField(this, 2, value);
|
|
3088
|
+
}
|
|
3089
|
+
get data() {
|
|
3090
|
+
return pb_1.Message.getWrapperField(this, StockData, 3);
|
|
3091
|
+
}
|
|
3092
|
+
set data(value) {
|
|
3093
|
+
pb_1.Message.setWrapperField(this, 3, value);
|
|
3094
|
+
}
|
|
3095
|
+
get hasData() {
|
|
3096
|
+
return pb_1.Message.getField(this, 3) != null;
|
|
3097
|
+
}
|
|
3098
|
+
get error() {
|
|
3099
|
+
return pb_1.Message.getFieldWithDefault(this, 4, "");
|
|
3100
|
+
}
|
|
3101
|
+
set error(value) {
|
|
3102
|
+
pb_1.Message.setField(this, 4, value);
|
|
3103
|
+
}
|
|
3104
|
+
static fromObject(data) {
|
|
3105
|
+
const message = new StockResponse({});
|
|
3106
|
+
if (data.success != null) {
|
|
3107
|
+
message.success = data.success;
|
|
3108
|
+
}
|
|
3109
|
+
if (data.message != null) {
|
|
3110
|
+
message.message = data.message;
|
|
3111
|
+
}
|
|
3112
|
+
if (data.data != null) {
|
|
3113
|
+
message.data = StockData.fromObject(data.data);
|
|
3114
|
+
}
|
|
3115
|
+
if (data.error != null) {
|
|
3116
|
+
message.error = data.error;
|
|
3117
|
+
}
|
|
3118
|
+
return message;
|
|
3119
|
+
}
|
|
3120
|
+
toObject() {
|
|
3121
|
+
const data = {};
|
|
3122
|
+
if (this.success != null) {
|
|
3123
|
+
data.success = this.success;
|
|
3124
|
+
}
|
|
3125
|
+
if (this.message != null) {
|
|
3126
|
+
data.message = this.message;
|
|
3127
|
+
}
|
|
3128
|
+
if (this.data != null) {
|
|
3129
|
+
data.data = this.data.toObject();
|
|
3130
|
+
}
|
|
3131
|
+
if (this.error != null) {
|
|
3132
|
+
data.error = this.error;
|
|
3133
|
+
}
|
|
3134
|
+
return data;
|
|
3135
|
+
}
|
|
3136
|
+
serialize(w) {
|
|
3137
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
3138
|
+
if (this.success != false)
|
|
3139
|
+
writer.writeBool(1, this.success);
|
|
3140
|
+
if (this.message.length)
|
|
3141
|
+
writer.writeString(2, this.message);
|
|
3142
|
+
if (this.hasData)
|
|
3143
|
+
writer.writeMessage(3, this.data, () => this.data.serialize(writer));
|
|
3144
|
+
if (this.error.length)
|
|
3145
|
+
writer.writeString(4, this.error);
|
|
3146
|
+
if (!w)
|
|
3147
|
+
return writer.getResultBuffer();
|
|
3148
|
+
}
|
|
3149
|
+
static deserialize(bytes) {
|
|
3150
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new StockResponse();
|
|
3151
|
+
while (reader.nextField()) {
|
|
3152
|
+
if (reader.isEndGroup())
|
|
3153
|
+
break;
|
|
3154
|
+
switch (reader.getFieldNumber()) {
|
|
3155
|
+
case 1:
|
|
3156
|
+
message.success = reader.readBool();
|
|
3157
|
+
break;
|
|
3158
|
+
case 2:
|
|
3159
|
+
message.message = reader.readString();
|
|
3160
|
+
break;
|
|
3161
|
+
case 3:
|
|
3162
|
+
reader.readMessage(message.data, () => message.data = StockData.deserialize(reader));
|
|
3163
|
+
break;
|
|
3164
|
+
case 4:
|
|
3165
|
+
message.error = reader.readString();
|
|
3166
|
+
break;
|
|
3167
|
+
default: reader.skipField();
|
|
3168
|
+
}
|
|
3169
|
+
}
|
|
3170
|
+
return message;
|
|
3171
|
+
}
|
|
3172
|
+
serializeBinary() {
|
|
3173
|
+
return this.serialize();
|
|
3174
|
+
}
|
|
3175
|
+
static deserializeBinary(bytes) {
|
|
3176
|
+
return StockResponse.deserialize(bytes);
|
|
3177
|
+
}
|
|
3178
|
+
}
|
|
3179
|
+
terminalTypes.StockResponse = StockResponse;
|
|
3180
|
+
class AvailabilityResponse extends pb_1.Message {
|
|
3181
|
+
#one_of_decls = [];
|
|
3182
|
+
constructor(data) {
|
|
3183
|
+
super();
|
|
3184
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
3185
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
3186
|
+
if ("success" in data && data.success != undefined) {
|
|
3187
|
+
this.success = data.success;
|
|
3188
|
+
}
|
|
3189
|
+
if ("message" in data && data.message != undefined) {
|
|
3190
|
+
this.message = data.message;
|
|
3191
|
+
}
|
|
3192
|
+
if ("data" in data && data.data != undefined) {
|
|
3193
|
+
this.data = data.data;
|
|
3194
|
+
}
|
|
3195
|
+
if ("error" in data && data.error != undefined) {
|
|
3196
|
+
this.error = data.error;
|
|
3197
|
+
}
|
|
3198
|
+
}
|
|
3199
|
+
}
|
|
3200
|
+
get success() {
|
|
3201
|
+
return pb_1.Message.getFieldWithDefault(this, 1, false);
|
|
3202
|
+
}
|
|
3203
|
+
set success(value) {
|
|
3204
|
+
pb_1.Message.setField(this, 1, value);
|
|
3205
|
+
}
|
|
3206
|
+
get message() {
|
|
3207
|
+
return pb_1.Message.getFieldWithDefault(this, 2, "");
|
|
3208
|
+
}
|
|
3209
|
+
set message(value) {
|
|
3210
|
+
pb_1.Message.setField(this, 2, value);
|
|
3211
|
+
}
|
|
3212
|
+
get data() {
|
|
3213
|
+
return pb_1.Message.getWrapperField(this, AvailabilityData, 3);
|
|
3214
|
+
}
|
|
3215
|
+
set data(value) {
|
|
3216
|
+
pb_1.Message.setWrapperField(this, 3, value);
|
|
3217
|
+
}
|
|
3218
|
+
get hasData() {
|
|
3219
|
+
return pb_1.Message.getField(this, 3) != null;
|
|
3220
|
+
}
|
|
3221
|
+
get error() {
|
|
3222
|
+
return pb_1.Message.getFieldWithDefault(this, 4, "");
|
|
3223
|
+
}
|
|
3224
|
+
set error(value) {
|
|
3225
|
+
pb_1.Message.setField(this, 4, value);
|
|
3226
|
+
}
|
|
3227
|
+
static fromObject(data) {
|
|
3228
|
+
const message = new AvailabilityResponse({});
|
|
3229
|
+
if (data.success != null) {
|
|
3230
|
+
message.success = data.success;
|
|
3231
|
+
}
|
|
3232
|
+
if (data.message != null) {
|
|
3233
|
+
message.message = data.message;
|
|
3234
|
+
}
|
|
3235
|
+
if (data.data != null) {
|
|
3236
|
+
message.data = AvailabilityData.fromObject(data.data);
|
|
3237
|
+
}
|
|
3238
|
+
if (data.error != null) {
|
|
3239
|
+
message.error = data.error;
|
|
3240
|
+
}
|
|
3241
|
+
return message;
|
|
3242
|
+
}
|
|
3243
|
+
toObject() {
|
|
3244
|
+
const data = {};
|
|
3245
|
+
if (this.success != null) {
|
|
3246
|
+
data.success = this.success;
|
|
3247
|
+
}
|
|
3248
|
+
if (this.message != null) {
|
|
3249
|
+
data.message = this.message;
|
|
3250
|
+
}
|
|
3251
|
+
if (this.data != null) {
|
|
3252
|
+
data.data = this.data.toObject();
|
|
3253
|
+
}
|
|
3254
|
+
if (this.error != null) {
|
|
3255
|
+
data.error = this.error;
|
|
3256
|
+
}
|
|
3257
|
+
return data;
|
|
3258
|
+
}
|
|
3259
|
+
serialize(w) {
|
|
3260
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
3261
|
+
if (this.success != false)
|
|
3262
|
+
writer.writeBool(1, this.success);
|
|
3263
|
+
if (this.message.length)
|
|
3264
|
+
writer.writeString(2, this.message);
|
|
3265
|
+
if (this.hasData)
|
|
3266
|
+
writer.writeMessage(3, this.data, () => this.data.serialize(writer));
|
|
3267
|
+
if (this.error.length)
|
|
3268
|
+
writer.writeString(4, this.error);
|
|
3269
|
+
if (!w)
|
|
3270
|
+
return writer.getResultBuffer();
|
|
3271
|
+
}
|
|
3272
|
+
static deserialize(bytes) {
|
|
3273
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new AvailabilityResponse();
|
|
3274
|
+
while (reader.nextField()) {
|
|
3275
|
+
if (reader.isEndGroup())
|
|
3276
|
+
break;
|
|
3277
|
+
switch (reader.getFieldNumber()) {
|
|
3278
|
+
case 1:
|
|
3279
|
+
message.success = reader.readBool();
|
|
3280
|
+
break;
|
|
3281
|
+
case 2:
|
|
3282
|
+
message.message = reader.readString();
|
|
3283
|
+
break;
|
|
3284
|
+
case 3:
|
|
3285
|
+
reader.readMessage(message.data, () => message.data = AvailabilityData.deserialize(reader));
|
|
3286
|
+
break;
|
|
3287
|
+
case 4:
|
|
3288
|
+
message.error = reader.readString();
|
|
3289
|
+
break;
|
|
3290
|
+
default: reader.skipField();
|
|
3291
|
+
}
|
|
3292
|
+
}
|
|
3293
|
+
return message;
|
|
3294
|
+
}
|
|
3295
|
+
serializeBinary() {
|
|
3296
|
+
return this.serialize();
|
|
3297
|
+
}
|
|
3298
|
+
static deserializeBinary(bytes) {
|
|
3299
|
+
return AvailabilityResponse.deserialize(bytes);
|
|
3300
|
+
}
|
|
3301
|
+
}
|
|
3302
|
+
terminalTypes.AvailabilityResponse = AvailabilityResponse;
|
|
3303
|
+
class SpecificationsResponse extends pb_1.Message {
|
|
3304
|
+
#one_of_decls = [];
|
|
3305
|
+
constructor(data) {
|
|
3306
|
+
super();
|
|
3307
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
3308
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
3309
|
+
if ("success" in data && data.success != undefined) {
|
|
3310
|
+
this.success = data.success;
|
|
3311
|
+
}
|
|
3312
|
+
if ("message" in data && data.message != undefined) {
|
|
3313
|
+
this.message = data.message;
|
|
3314
|
+
}
|
|
3315
|
+
if ("data" in data && data.data != undefined) {
|
|
3316
|
+
this.data = data.data;
|
|
3317
|
+
}
|
|
3318
|
+
if ("error" in data && data.error != undefined) {
|
|
3319
|
+
this.error = data.error;
|
|
3320
|
+
}
|
|
3321
|
+
}
|
|
3322
|
+
}
|
|
3323
|
+
get success() {
|
|
3324
|
+
return pb_1.Message.getFieldWithDefault(this, 1, false);
|
|
3325
|
+
}
|
|
3326
|
+
set success(value) {
|
|
3327
|
+
pb_1.Message.setField(this, 1, value);
|
|
3328
|
+
}
|
|
3329
|
+
get message() {
|
|
3330
|
+
return pb_1.Message.getFieldWithDefault(this, 2, "");
|
|
3331
|
+
}
|
|
3332
|
+
set message(value) {
|
|
3333
|
+
pb_1.Message.setField(this, 2, value);
|
|
3334
|
+
}
|
|
3335
|
+
get data() {
|
|
3336
|
+
return pb_1.Message.getWrapperField(this, SpecificationsData, 3);
|
|
3337
|
+
}
|
|
3338
|
+
set data(value) {
|
|
3339
|
+
pb_1.Message.setWrapperField(this, 3, value);
|
|
3340
|
+
}
|
|
3341
|
+
get hasData() {
|
|
3342
|
+
return pb_1.Message.getField(this, 3) != null;
|
|
3343
|
+
}
|
|
3344
|
+
get error() {
|
|
3345
|
+
return pb_1.Message.getFieldWithDefault(this, 4, "");
|
|
3346
|
+
}
|
|
3347
|
+
set error(value) {
|
|
3348
|
+
pb_1.Message.setField(this, 4, value);
|
|
3349
|
+
}
|
|
3350
|
+
static fromObject(data) {
|
|
3351
|
+
const message = new SpecificationsResponse({});
|
|
3352
|
+
if (data.success != null) {
|
|
3353
|
+
message.success = data.success;
|
|
3354
|
+
}
|
|
3355
|
+
if (data.message != null) {
|
|
3356
|
+
message.message = data.message;
|
|
3357
|
+
}
|
|
3358
|
+
if (data.data != null) {
|
|
3359
|
+
message.data = SpecificationsData.fromObject(data.data);
|
|
3360
|
+
}
|
|
3361
|
+
if (data.error != null) {
|
|
3362
|
+
message.error = data.error;
|
|
3363
|
+
}
|
|
3364
|
+
return message;
|
|
3365
|
+
}
|
|
3366
|
+
toObject() {
|
|
3367
|
+
const data = {};
|
|
3368
|
+
if (this.success != null) {
|
|
3369
|
+
data.success = this.success;
|
|
3370
|
+
}
|
|
3371
|
+
if (this.message != null) {
|
|
3372
|
+
data.message = this.message;
|
|
3373
|
+
}
|
|
3374
|
+
if (this.data != null) {
|
|
3375
|
+
data.data = this.data.toObject();
|
|
3376
|
+
}
|
|
3377
|
+
if (this.error != null) {
|
|
3378
|
+
data.error = this.error;
|
|
3379
|
+
}
|
|
3380
|
+
return data;
|
|
3381
|
+
}
|
|
3382
|
+
serialize(w) {
|
|
3383
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
3384
|
+
if (this.success != false)
|
|
3385
|
+
writer.writeBool(1, this.success);
|
|
3386
|
+
if (this.message.length)
|
|
3387
|
+
writer.writeString(2, this.message);
|
|
3388
|
+
if (this.hasData)
|
|
3389
|
+
writer.writeMessage(3, this.data, () => this.data.serialize(writer));
|
|
3390
|
+
if (this.error.length)
|
|
3391
|
+
writer.writeString(4, this.error);
|
|
3392
|
+
if (!w)
|
|
3393
|
+
return writer.getResultBuffer();
|
|
3394
|
+
}
|
|
3395
|
+
static deserialize(bytes) {
|
|
3396
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new SpecificationsResponse();
|
|
3397
|
+
while (reader.nextField()) {
|
|
3398
|
+
if (reader.isEndGroup())
|
|
3399
|
+
break;
|
|
3400
|
+
switch (reader.getFieldNumber()) {
|
|
3401
|
+
case 1:
|
|
3402
|
+
message.success = reader.readBool();
|
|
3403
|
+
break;
|
|
3404
|
+
case 2:
|
|
3405
|
+
message.message = reader.readString();
|
|
3406
|
+
break;
|
|
3407
|
+
case 3:
|
|
3408
|
+
reader.readMessage(message.data, () => message.data = SpecificationsData.deserialize(reader));
|
|
3409
|
+
break;
|
|
3410
|
+
case 4:
|
|
3411
|
+
message.error = reader.readString();
|
|
3412
|
+
break;
|
|
3413
|
+
default: reader.skipField();
|
|
3414
|
+
}
|
|
3415
|
+
}
|
|
3416
|
+
return message;
|
|
3417
|
+
}
|
|
3418
|
+
serializeBinary() {
|
|
3419
|
+
return this.serialize();
|
|
3420
|
+
}
|
|
3421
|
+
static deserializeBinary(bytes) {
|
|
3422
|
+
return SpecificationsResponse.deserialize(bytes);
|
|
3423
|
+
}
|
|
3424
|
+
}
|
|
3425
|
+
terminalTypes.SpecificationsResponse = SpecificationsResponse;
|
|
3426
|
+
class StatsResponse extends pb_1.Message {
|
|
3427
|
+
#one_of_decls = [];
|
|
3428
|
+
constructor(data) {
|
|
3429
|
+
super();
|
|
3430
|
+
pb_1.Message.initialize(this, Array.isArray(data) ? data : [], 0, -1, [], this.#one_of_decls);
|
|
3431
|
+
if (!Array.isArray(data) && typeof data == "object") {
|
|
3432
|
+
if ("success" in data && data.success != undefined) {
|
|
3433
|
+
this.success = data.success;
|
|
3434
|
+
}
|
|
3435
|
+
if ("message" in data && data.message != undefined) {
|
|
3436
|
+
this.message = data.message;
|
|
3437
|
+
}
|
|
3438
|
+
if ("data" in data && data.data != undefined) {
|
|
3439
|
+
this.data = data.data;
|
|
3440
|
+
}
|
|
3441
|
+
if ("error" in data && data.error != undefined) {
|
|
3442
|
+
this.error = data.error;
|
|
3443
|
+
}
|
|
3444
|
+
}
|
|
3445
|
+
}
|
|
3446
|
+
get success() {
|
|
3447
|
+
return pb_1.Message.getFieldWithDefault(this, 1, false);
|
|
3448
|
+
}
|
|
3449
|
+
set success(value) {
|
|
3450
|
+
pb_1.Message.setField(this, 1, value);
|
|
3451
|
+
}
|
|
3452
|
+
get message() {
|
|
3453
|
+
return pb_1.Message.getFieldWithDefault(this, 2, "");
|
|
3454
|
+
}
|
|
3455
|
+
set message(value) {
|
|
3456
|
+
pb_1.Message.setField(this, 2, value);
|
|
3457
|
+
}
|
|
3458
|
+
get data() {
|
|
3459
|
+
return pb_1.Message.getWrapperField(this, StatsData, 3);
|
|
3460
|
+
}
|
|
3461
|
+
set data(value) {
|
|
3462
|
+
pb_1.Message.setWrapperField(this, 3, value);
|
|
3463
|
+
}
|
|
3464
|
+
get hasData() {
|
|
3465
|
+
return pb_1.Message.getField(this, 3) != null;
|
|
3466
|
+
}
|
|
3467
|
+
get error() {
|
|
3468
|
+
return pb_1.Message.getFieldWithDefault(this, 4, "");
|
|
3469
|
+
}
|
|
3470
|
+
set error(value) {
|
|
3471
|
+
pb_1.Message.setField(this, 4, value);
|
|
3472
|
+
}
|
|
3473
|
+
static fromObject(data) {
|
|
3474
|
+
const message = new StatsResponse({});
|
|
3475
|
+
if (data.success != null) {
|
|
3476
|
+
message.success = data.success;
|
|
3477
|
+
}
|
|
3478
|
+
if (data.message != null) {
|
|
3479
|
+
message.message = data.message;
|
|
3480
|
+
}
|
|
3481
|
+
if (data.data != null) {
|
|
3482
|
+
message.data = StatsData.fromObject(data.data);
|
|
3483
|
+
}
|
|
3484
|
+
if (data.error != null) {
|
|
3485
|
+
message.error = data.error;
|
|
3486
|
+
}
|
|
3487
|
+
return message;
|
|
3488
|
+
}
|
|
3489
|
+
toObject() {
|
|
3490
|
+
const data = {};
|
|
3491
|
+
if (this.success != null) {
|
|
3492
|
+
data.success = this.success;
|
|
3493
|
+
}
|
|
3494
|
+
if (this.message != null) {
|
|
3495
|
+
data.message = this.message;
|
|
3496
|
+
}
|
|
3497
|
+
if (this.data != null) {
|
|
3498
|
+
data.data = this.data.toObject();
|
|
3499
|
+
}
|
|
3500
|
+
if (this.error != null) {
|
|
3501
|
+
data.error = this.error;
|
|
3502
|
+
}
|
|
3503
|
+
return data;
|
|
3504
|
+
}
|
|
3505
|
+
serialize(w) {
|
|
3506
|
+
const writer = w || new pb_1.BinaryWriter();
|
|
3507
|
+
if (this.success != false)
|
|
3508
|
+
writer.writeBool(1, this.success);
|
|
3509
|
+
if (this.message.length)
|
|
3510
|
+
writer.writeString(2, this.message);
|
|
3511
|
+
if (this.hasData)
|
|
3512
|
+
writer.writeMessage(3, this.data, () => this.data.serialize(writer));
|
|
3513
|
+
if (this.error.length)
|
|
3514
|
+
writer.writeString(4, this.error);
|
|
3515
|
+
if (!w)
|
|
3516
|
+
return writer.getResultBuffer();
|
|
3517
|
+
}
|
|
3518
|
+
static deserialize(bytes) {
|
|
3519
|
+
const reader = bytes instanceof pb_1.BinaryReader ? bytes : new pb_1.BinaryReader(bytes), message = new StatsResponse();
|
|
3520
|
+
while (reader.nextField()) {
|
|
3521
|
+
if (reader.isEndGroup())
|
|
3522
|
+
break;
|
|
3523
|
+
switch (reader.getFieldNumber()) {
|
|
3524
|
+
case 1:
|
|
3525
|
+
message.success = reader.readBool();
|
|
3526
|
+
break;
|
|
3527
|
+
case 2:
|
|
3528
|
+
message.message = reader.readString();
|
|
3529
|
+
break;
|
|
3530
|
+
case 3:
|
|
3531
|
+
reader.readMessage(message.data, () => message.data = StatsData.deserialize(reader));
|
|
3532
|
+
break;
|
|
3533
|
+
case 4:
|
|
3534
|
+
message.error = reader.readString();
|
|
3535
|
+
break;
|
|
3536
|
+
default: reader.skipField();
|
|
3537
|
+
}
|
|
3538
|
+
}
|
|
3539
|
+
return message;
|
|
3540
|
+
}
|
|
3541
|
+
serializeBinary() {
|
|
3542
|
+
return this.serialize();
|
|
3543
|
+
}
|
|
3544
|
+
static deserializeBinary(bytes) {
|
|
3545
|
+
return StatsResponse.deserialize(bytes);
|
|
3546
|
+
}
|
|
3547
|
+
}
|
|
3548
|
+
terminalTypes.StatsResponse = StatsResponse;
|
|
3549
|
+
class UnimplementedTerminalTypeServiceService {
|
|
3550
|
+
static definition = {
|
|
3551
|
+
AddTerminalType: {
|
|
3552
|
+
path: "/com.pkg.posv1.terminalTypes.TerminalTypeService/AddTerminalType",
|
|
3553
|
+
requestStream: false,
|
|
3554
|
+
responseStream: false,
|
|
3555
|
+
requestSerialize: (message) => Buffer.from(message.serialize()),
|
|
3556
|
+
requestDeserialize: (bytes) => AddTerminalTypeRequest.deserialize(new Uint8Array(bytes)),
|
|
3557
|
+
responseSerialize: (message) => Buffer.from(message.serialize()),
|
|
3558
|
+
responseDeserialize: (bytes) => TerminalTypeResponse.deserialize(new Uint8Array(bytes))
|
|
3559
|
+
},
|
|
3560
|
+
GetTerminalTypes: {
|
|
3561
|
+
path: "/com.pkg.posv1.terminalTypes.TerminalTypeService/GetTerminalTypes",
|
|
3562
|
+
requestStream: false,
|
|
3563
|
+
responseStream: false,
|
|
3564
|
+
requestSerialize: (message) => Buffer.from(message.serialize()),
|
|
3565
|
+
requestDeserialize: (bytes) => GetTerminalTypesRequest.deserialize(new Uint8Array(bytes)),
|
|
3566
|
+
responseSerialize: (message) => Buffer.from(message.serialize()),
|
|
3567
|
+
responseDeserialize: (bytes) => TerminalTypesResponse.deserialize(new Uint8Array(bytes))
|
|
3568
|
+
},
|
|
3569
|
+
GetTerminalTypeById: {
|
|
3570
|
+
path: "/com.pkg.posv1.terminalTypes.TerminalTypeService/GetTerminalTypeById",
|
|
3571
|
+
requestStream: false,
|
|
3572
|
+
responseStream: false,
|
|
3573
|
+
requestSerialize: (message) => Buffer.from(message.serialize()),
|
|
3574
|
+
requestDeserialize: (bytes) => GetTerminalTypeByIdRequest.deserialize(new Uint8Array(bytes)),
|
|
3575
|
+
responseSerialize: (message) => Buffer.from(message.serialize()),
|
|
3576
|
+
responseDeserialize: (bytes) => TerminalTypeResponse.deserialize(new Uint8Array(bytes))
|
|
3577
|
+
},
|
|
3578
|
+
UpdateTerminalType: {
|
|
3579
|
+
path: "/com.pkg.posv1.terminalTypes.TerminalTypeService/UpdateTerminalType",
|
|
3580
|
+
requestStream: false,
|
|
3581
|
+
responseStream: false,
|
|
3582
|
+
requestSerialize: (message) => Buffer.from(message.serialize()),
|
|
3583
|
+
requestDeserialize: (bytes) => UpdateTerminalTypeRequest.deserialize(new Uint8Array(bytes)),
|
|
3584
|
+
responseSerialize: (message) => Buffer.from(message.serialize()),
|
|
3585
|
+
responseDeserialize: (bytes) => TerminalTypeResponse.deserialize(new Uint8Array(bytes))
|
|
3586
|
+
},
|
|
3587
|
+
DiscontinueType: {
|
|
3588
|
+
path: "/com.pkg.posv1.terminalTypes.TerminalTypeService/DiscontinueType",
|
|
3589
|
+
requestStream: false,
|
|
3590
|
+
responseStream: false,
|
|
3591
|
+
requestSerialize: (message) => Buffer.from(message.serialize()),
|
|
3592
|
+
requestDeserialize: (bytes) => DiscontinueTypeRequest.deserialize(new Uint8Array(bytes)),
|
|
3593
|
+
responseSerialize: (message) => Buffer.from(message.serialize()),
|
|
3594
|
+
responseDeserialize: (bytes) => TerminalTypeResponse.deserialize(new Uint8Array(bytes))
|
|
3595
|
+
},
|
|
3596
|
+
UpdateStock: {
|
|
3597
|
+
path: "/com.pkg.posv1.terminalTypes.TerminalTypeService/UpdateStock",
|
|
3598
|
+
requestStream: false,
|
|
3599
|
+
responseStream: false,
|
|
3600
|
+
requestSerialize: (message) => Buffer.from(message.serialize()),
|
|
3601
|
+
requestDeserialize: (bytes) => UpdateStockRequest.deserialize(new Uint8Array(bytes)),
|
|
3602
|
+
responseSerialize: (message) => Buffer.from(message.serialize()),
|
|
3603
|
+
responseDeserialize: (bytes) => StockResponse.deserialize(new Uint8Array(bytes))
|
|
3604
|
+
},
|
|
3605
|
+
ReserveStock: {
|
|
3606
|
+
path: "/com.pkg.posv1.terminalTypes.TerminalTypeService/ReserveStock",
|
|
3607
|
+
requestStream: false,
|
|
3608
|
+
responseStream: false,
|
|
3609
|
+
requestSerialize: (message) => Buffer.from(message.serialize()),
|
|
3610
|
+
requestDeserialize: (bytes) => ReserveStockRequest.deserialize(new Uint8Array(bytes)),
|
|
3611
|
+
responseSerialize: (message) => Buffer.from(message.serialize()),
|
|
3612
|
+
responseDeserialize: (bytes) => StockResponse.deserialize(new Uint8Array(bytes))
|
|
3613
|
+
},
|
|
3614
|
+
ReleaseStock: {
|
|
3615
|
+
path: "/com.pkg.posv1.terminalTypes.TerminalTypeService/ReleaseStock",
|
|
3616
|
+
requestStream: false,
|
|
3617
|
+
responseStream: false,
|
|
3618
|
+
requestSerialize: (message) => Buffer.from(message.serialize()),
|
|
3619
|
+
requestDeserialize: (bytes) => ReleaseStockRequest.deserialize(new Uint8Array(bytes)),
|
|
3620
|
+
responseSerialize: (message) => Buffer.from(message.serialize()),
|
|
3621
|
+
responseDeserialize: (bytes) => StockResponse.deserialize(new Uint8Array(bytes))
|
|
3622
|
+
},
|
|
3623
|
+
GetAvailableTypes: {
|
|
3624
|
+
path: "/com.pkg.posv1.terminalTypes.TerminalTypeService/GetAvailableTypes",
|
|
3625
|
+
requestStream: false,
|
|
3626
|
+
responseStream: false,
|
|
3627
|
+
requestSerialize: (message) => Buffer.from(message.serialize()),
|
|
3628
|
+
requestDeserialize: (bytes) => GetAvailableTypesRequest.deserialize(new Uint8Array(bytes)),
|
|
3629
|
+
responseSerialize: (message) => Buffer.from(message.serialize()),
|
|
3630
|
+
responseDeserialize: (bytes) => TerminalTypesResponse.deserialize(new Uint8Array(bytes))
|
|
3631
|
+
},
|
|
3632
|
+
CheckAvailability: {
|
|
3633
|
+
path: "/com.pkg.posv1.terminalTypes.TerminalTypeService/CheckAvailability",
|
|
3634
|
+
requestStream: false,
|
|
3635
|
+
responseStream: false,
|
|
3636
|
+
requestSerialize: (message) => Buffer.from(message.serialize()),
|
|
3637
|
+
requestDeserialize: (bytes) => CheckAvailabilityRequest.deserialize(new Uint8Array(bytes)),
|
|
3638
|
+
responseSerialize: (message) => Buffer.from(message.serialize()),
|
|
3639
|
+
responseDeserialize: (bytes) => AvailabilityResponse.deserialize(new Uint8Array(bytes))
|
|
3640
|
+
},
|
|
3641
|
+
GetSpecifications: {
|
|
3642
|
+
path: "/com.pkg.posv1.terminalTypes.TerminalTypeService/GetSpecifications",
|
|
3643
|
+
requestStream: false,
|
|
3644
|
+
responseStream: false,
|
|
3645
|
+
requestSerialize: (message) => Buffer.from(message.serialize()),
|
|
3646
|
+
requestDeserialize: (bytes) => GetSpecificationsRequest.deserialize(new Uint8Array(bytes)),
|
|
3647
|
+
responseSerialize: (message) => Buffer.from(message.serialize()),
|
|
3648
|
+
responseDeserialize: (bytes) => SpecificationsResponse.deserialize(new Uint8Array(bytes))
|
|
3649
|
+
},
|
|
3650
|
+
GetStats: {
|
|
3651
|
+
path: "/com.pkg.posv1.terminalTypes.TerminalTypeService/GetStats",
|
|
3652
|
+
requestStream: false,
|
|
3653
|
+
responseStream: false,
|
|
3654
|
+
requestSerialize: (message) => Buffer.from(message.serialize()),
|
|
3655
|
+
requestDeserialize: (bytes) => GetStatsRequest.deserialize(new Uint8Array(bytes)),
|
|
3656
|
+
responseSerialize: (message) => Buffer.from(message.serialize()),
|
|
3657
|
+
responseDeserialize: (bytes) => StatsResponse.deserialize(new Uint8Array(bytes))
|
|
3658
|
+
},
|
|
3659
|
+
GetLowStock: {
|
|
3660
|
+
path: "/com.pkg.posv1.terminalTypes.TerminalTypeService/GetLowStock",
|
|
3661
|
+
requestStream: false,
|
|
3662
|
+
responseStream: false,
|
|
3663
|
+
requestSerialize: (message) => Buffer.from(message.serialize()),
|
|
3664
|
+
requestDeserialize: (bytes) => GetLowStockRequest.deserialize(new Uint8Array(bytes)),
|
|
3665
|
+
responseSerialize: (message) => Buffer.from(message.serialize()),
|
|
3666
|
+
responseDeserialize: (bytes) => TerminalTypesResponse.deserialize(new Uint8Array(bytes))
|
|
3667
|
+
}
|
|
3668
|
+
};
|
|
3669
|
+
}
|
|
3670
|
+
terminalTypes.UnimplementedTerminalTypeServiceService = UnimplementedTerminalTypeServiceService;
|
|
3671
|
+
class TerminalTypeServiceClient extends grpc_1.makeGenericClientConstructor(UnimplementedTerminalTypeServiceService.definition, "TerminalTypeService", {}) {
|
|
3672
|
+
constructor(address, credentials, options) {
|
|
3673
|
+
super(address, credentials, options);
|
|
3674
|
+
}
|
|
3675
|
+
AddTerminalType = (message, metadata, options) => {
|
|
3676
|
+
if (!metadata) {
|
|
3677
|
+
metadata = new grpc_1.Metadata;
|
|
3678
|
+
}
|
|
3679
|
+
if (!options) {
|
|
3680
|
+
options = {};
|
|
3681
|
+
}
|
|
3682
|
+
return new Promise((resolve, reject) => super.AddTerminalType(message, metadata, options, (error, response) => {
|
|
3683
|
+
if (error) {
|
|
3684
|
+
reject(error);
|
|
3685
|
+
}
|
|
3686
|
+
else {
|
|
3687
|
+
resolve(response);
|
|
3688
|
+
}
|
|
3689
|
+
}));
|
|
3690
|
+
};
|
|
3691
|
+
GetTerminalTypes = (message, metadata, options) => {
|
|
3692
|
+
if (!metadata) {
|
|
3693
|
+
metadata = new grpc_1.Metadata;
|
|
3694
|
+
}
|
|
3695
|
+
if (!options) {
|
|
3696
|
+
options = {};
|
|
3697
|
+
}
|
|
3698
|
+
return new Promise((resolve, reject) => super.GetTerminalTypes(message, metadata, options, (error, response) => {
|
|
3699
|
+
if (error) {
|
|
3700
|
+
reject(error);
|
|
3701
|
+
}
|
|
3702
|
+
else {
|
|
3703
|
+
resolve(response);
|
|
3704
|
+
}
|
|
3705
|
+
}));
|
|
3706
|
+
};
|
|
3707
|
+
GetTerminalTypeById = (message, metadata, options) => {
|
|
3708
|
+
if (!metadata) {
|
|
3709
|
+
metadata = new grpc_1.Metadata;
|
|
3710
|
+
}
|
|
3711
|
+
if (!options) {
|
|
3712
|
+
options = {};
|
|
3713
|
+
}
|
|
3714
|
+
return new Promise((resolve, reject) => super.GetTerminalTypeById(message, metadata, options, (error, response) => {
|
|
3715
|
+
if (error) {
|
|
3716
|
+
reject(error);
|
|
3717
|
+
}
|
|
3718
|
+
else {
|
|
3719
|
+
resolve(response);
|
|
3720
|
+
}
|
|
3721
|
+
}));
|
|
3722
|
+
};
|
|
3723
|
+
UpdateTerminalType = (message, metadata, options) => {
|
|
3724
|
+
if (!metadata) {
|
|
3725
|
+
metadata = new grpc_1.Metadata;
|
|
3726
|
+
}
|
|
3727
|
+
if (!options) {
|
|
3728
|
+
options = {};
|
|
3729
|
+
}
|
|
3730
|
+
return new Promise((resolve, reject) => super.UpdateTerminalType(message, metadata, options, (error, response) => {
|
|
3731
|
+
if (error) {
|
|
3732
|
+
reject(error);
|
|
3733
|
+
}
|
|
3734
|
+
else {
|
|
3735
|
+
resolve(response);
|
|
3736
|
+
}
|
|
3737
|
+
}));
|
|
3738
|
+
};
|
|
3739
|
+
DiscontinueType = (message, metadata, options) => {
|
|
3740
|
+
if (!metadata) {
|
|
3741
|
+
metadata = new grpc_1.Metadata;
|
|
3742
|
+
}
|
|
3743
|
+
if (!options) {
|
|
3744
|
+
options = {};
|
|
3745
|
+
}
|
|
3746
|
+
return new Promise((resolve, reject) => super.DiscontinueType(message, metadata, options, (error, response) => {
|
|
3747
|
+
if (error) {
|
|
3748
|
+
reject(error);
|
|
3749
|
+
}
|
|
3750
|
+
else {
|
|
3751
|
+
resolve(response);
|
|
3752
|
+
}
|
|
3753
|
+
}));
|
|
3754
|
+
};
|
|
3755
|
+
UpdateStock = (message, metadata, options) => {
|
|
3756
|
+
if (!metadata) {
|
|
3757
|
+
metadata = new grpc_1.Metadata;
|
|
3758
|
+
}
|
|
3759
|
+
if (!options) {
|
|
3760
|
+
options = {};
|
|
3761
|
+
}
|
|
3762
|
+
return new Promise((resolve, reject) => super.UpdateStock(message, metadata, options, (error, response) => {
|
|
3763
|
+
if (error) {
|
|
3764
|
+
reject(error);
|
|
3765
|
+
}
|
|
3766
|
+
else {
|
|
3767
|
+
resolve(response);
|
|
3768
|
+
}
|
|
3769
|
+
}));
|
|
3770
|
+
};
|
|
3771
|
+
ReserveStock = (message, metadata, options) => {
|
|
3772
|
+
if (!metadata) {
|
|
3773
|
+
metadata = new grpc_1.Metadata;
|
|
3774
|
+
}
|
|
3775
|
+
if (!options) {
|
|
3776
|
+
options = {};
|
|
3777
|
+
}
|
|
3778
|
+
return new Promise((resolve, reject) => super.ReserveStock(message, metadata, options, (error, response) => {
|
|
3779
|
+
if (error) {
|
|
3780
|
+
reject(error);
|
|
3781
|
+
}
|
|
3782
|
+
else {
|
|
3783
|
+
resolve(response);
|
|
3784
|
+
}
|
|
3785
|
+
}));
|
|
3786
|
+
};
|
|
3787
|
+
ReleaseStock = (message, metadata, options) => {
|
|
3788
|
+
if (!metadata) {
|
|
3789
|
+
metadata = new grpc_1.Metadata;
|
|
3790
|
+
}
|
|
3791
|
+
if (!options) {
|
|
3792
|
+
options = {};
|
|
3793
|
+
}
|
|
3794
|
+
return new Promise((resolve, reject) => super.ReleaseStock(message, metadata, options, (error, response) => {
|
|
3795
|
+
if (error) {
|
|
3796
|
+
reject(error);
|
|
3797
|
+
}
|
|
3798
|
+
else {
|
|
3799
|
+
resolve(response);
|
|
3800
|
+
}
|
|
3801
|
+
}));
|
|
3802
|
+
};
|
|
3803
|
+
GetAvailableTypes = (message, metadata, options) => {
|
|
3804
|
+
if (!metadata) {
|
|
3805
|
+
metadata = new grpc_1.Metadata;
|
|
3806
|
+
}
|
|
3807
|
+
if (!options) {
|
|
3808
|
+
options = {};
|
|
3809
|
+
}
|
|
3810
|
+
return new Promise((resolve, reject) => super.GetAvailableTypes(message, metadata, options, (error, response) => {
|
|
3811
|
+
if (error) {
|
|
3812
|
+
reject(error);
|
|
3813
|
+
}
|
|
3814
|
+
else {
|
|
3815
|
+
resolve(response);
|
|
3816
|
+
}
|
|
3817
|
+
}));
|
|
3818
|
+
};
|
|
3819
|
+
CheckAvailability = (message, metadata, options) => {
|
|
3820
|
+
if (!metadata) {
|
|
3821
|
+
metadata = new grpc_1.Metadata;
|
|
3822
|
+
}
|
|
3823
|
+
if (!options) {
|
|
3824
|
+
options = {};
|
|
3825
|
+
}
|
|
3826
|
+
return new Promise((resolve, reject) => super.CheckAvailability(message, metadata, options, (error, response) => {
|
|
3827
|
+
if (error) {
|
|
3828
|
+
reject(error);
|
|
3829
|
+
}
|
|
3830
|
+
else {
|
|
3831
|
+
resolve(response);
|
|
3832
|
+
}
|
|
3833
|
+
}));
|
|
3834
|
+
};
|
|
3835
|
+
GetSpecifications = (message, metadata, options) => {
|
|
3836
|
+
if (!metadata) {
|
|
3837
|
+
metadata = new grpc_1.Metadata;
|
|
3838
|
+
}
|
|
3839
|
+
if (!options) {
|
|
3840
|
+
options = {};
|
|
3841
|
+
}
|
|
3842
|
+
return new Promise((resolve, reject) => super.GetSpecifications(message, metadata, options, (error, response) => {
|
|
3843
|
+
if (error) {
|
|
3844
|
+
reject(error);
|
|
3845
|
+
}
|
|
3846
|
+
else {
|
|
3847
|
+
resolve(response);
|
|
3848
|
+
}
|
|
3849
|
+
}));
|
|
3850
|
+
};
|
|
3851
|
+
GetStats = (message, metadata, options) => {
|
|
3852
|
+
if (!metadata) {
|
|
3853
|
+
metadata = new grpc_1.Metadata;
|
|
3854
|
+
}
|
|
3855
|
+
if (!options) {
|
|
3856
|
+
options = {};
|
|
3857
|
+
}
|
|
3858
|
+
return new Promise((resolve, reject) => super.GetStats(message, metadata, options, (error, response) => {
|
|
3859
|
+
if (error) {
|
|
3860
|
+
reject(error);
|
|
3861
|
+
}
|
|
3862
|
+
else {
|
|
3863
|
+
resolve(response);
|
|
3864
|
+
}
|
|
3865
|
+
}));
|
|
3866
|
+
};
|
|
3867
|
+
GetLowStock = (message, metadata, options) => {
|
|
3868
|
+
if (!metadata) {
|
|
3869
|
+
metadata = new grpc_1.Metadata;
|
|
3870
|
+
}
|
|
3871
|
+
if (!options) {
|
|
3872
|
+
options = {};
|
|
3873
|
+
}
|
|
3874
|
+
return new Promise((resolve, reject) => super.GetLowStock(message, metadata, options, (error, response) => {
|
|
3875
|
+
if (error) {
|
|
3876
|
+
reject(error);
|
|
3877
|
+
}
|
|
3878
|
+
else {
|
|
3879
|
+
resolve(response);
|
|
3880
|
+
}
|
|
3881
|
+
}));
|
|
3882
|
+
};
|
|
3883
|
+
}
|
|
3884
|
+
terminalTypes.TerminalTypeServiceClient = TerminalTypeServiceClient;
|
|
3885
|
+
})(terminalTypes = posv1.terminalTypes || (posv1.terminalTypes = {}));
|
|
3886
|
+
})(posv1 = pkg.posv1 || (pkg.posv1 = {}));
|
|
3887
|
+
})(pkg = com.pkg || (com.pkg = {}));
|
|
3888
|
+
})(com || (exports.com = com = {}));
|