@fatehan/tsrp 1.6.78 → 1.6.79
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/fatehan/devices/fleet.d.ts +2 -0
- package/dist/fatehan/devices/fleet.d.ts.map +1 -1
- package/dist/fatehan/devices/fleet.js +24 -0
- package/dist/fatehan/devices/maintenance.d.ts +91 -1
- package/dist/fatehan/devices/maintenance.d.ts.map +1 -1
- package/dist/fatehan/devices/maintenance.js +931 -1
- package/dist/fatehan/services/api.d.ts +1 -0
- package/dist/fatehan/services/api.d.ts.map +1 -1
- package/dist/fatehan/services/api.js +14 -0
- package/package.json +1 -1
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire";
|
|
8
8
|
import Long from "long";
|
|
9
9
|
import { Timestamp } from "../google/protobuf/timestamp";
|
|
10
|
-
import { FleetDocument, Issue, Vendor } from "./fleet";
|
|
10
|
+
import { FleetDocument, Issue, ServiceProgram, Vendor } from "./fleet";
|
|
11
11
|
export const protobufPackage = "com.fatehan.devices";
|
|
12
12
|
export var MaintenanceStatus;
|
|
13
13
|
(function (MaintenanceStatus) {
|
|
@@ -33,6 +33,21 @@ export var MaintenanceLineItem_Kind;
|
|
|
33
33
|
MaintenanceLineItem_Kind[MaintenanceLineItem_Kind["LABOUR"] = 1] = "LABOUR";
|
|
34
34
|
MaintenanceLineItem_Kind[MaintenanceLineItem_Kind["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
35
35
|
})(MaintenanceLineItem_Kind || (MaintenanceLineItem_Kind = {}));
|
|
36
|
+
export var Maintenance_Source;
|
|
37
|
+
(function (Maintenance_Source) {
|
|
38
|
+
Maintenance_Source[Maintenance_Source["MANUAL"] = 0] = "MANUAL";
|
|
39
|
+
Maintenance_Source[Maintenance_Source["PROGRAM"] = 1] = "PROGRAM";
|
|
40
|
+
Maintenance_Source[Maintenance_Source["SCHEDULED"] = 2] = "SCHEDULED";
|
|
41
|
+
Maintenance_Source[Maintenance_Source["ISSUE"] = 3] = "ISSUE";
|
|
42
|
+
Maintenance_Source[Maintenance_Source["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
43
|
+
})(Maintenance_Source || (Maintenance_Source = {}));
|
|
44
|
+
export var MaintenanceService_SafetyClass;
|
|
45
|
+
(function (MaintenanceService_SafetyClass) {
|
|
46
|
+
MaintenanceService_SafetyClass[MaintenanceService_SafetyClass["NORMAL"] = 0] = "NORMAL";
|
|
47
|
+
MaintenanceService_SafetyClass[MaintenanceService_SafetyClass["CRITICAL"] = 1] = "CRITICAL";
|
|
48
|
+
MaintenanceService_SafetyClass[MaintenanceService_SafetyClass["LEGAL"] = 2] = "LEGAL";
|
|
49
|
+
MaintenanceService_SafetyClass[MaintenanceService_SafetyClass["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
50
|
+
})(MaintenanceService_SafetyClass || (MaintenanceService_SafetyClass = {}));
|
|
36
51
|
function createBaseMaintenanceLineItem() {
|
|
37
52
|
return {
|
|
38
53
|
id: Long.UZERO,
|
|
@@ -215,6 +230,13 @@ function createBaseMaintenance() {
|
|
|
215
230
|
openIssues: [],
|
|
216
231
|
issues: [],
|
|
217
232
|
files: [],
|
|
233
|
+
estimatedCost: undefined,
|
|
234
|
+
acceptedAt: undefined,
|
|
235
|
+
source: 0,
|
|
236
|
+
program: undefined,
|
|
237
|
+
deviceName: undefined,
|
|
238
|
+
submittedAt: undefined,
|
|
239
|
+
assigneeName: undefined,
|
|
218
240
|
};
|
|
219
241
|
}
|
|
220
242
|
export const Maintenance = {
|
|
@@ -372,6 +394,27 @@ export const Maintenance = {
|
|
|
372
394
|
for (const v of message.files) {
|
|
373
395
|
FleetDocument.encode(v, writer.uint32(394).fork()).join();
|
|
374
396
|
}
|
|
397
|
+
if (message.estimatedCost !== undefined) {
|
|
398
|
+
writer.uint32(401).double(message.estimatedCost);
|
|
399
|
+
}
|
|
400
|
+
if (message.acceptedAt !== undefined) {
|
|
401
|
+
Timestamp.encode(toTimestamp(message.acceptedAt), writer.uint32(410).fork()).join();
|
|
402
|
+
}
|
|
403
|
+
if (message.source !== 0) {
|
|
404
|
+
writer.uint32(416).int32(message.source);
|
|
405
|
+
}
|
|
406
|
+
if (message.program !== undefined) {
|
|
407
|
+
ServiceProgram.encode(message.program, writer.uint32(426).fork()).join();
|
|
408
|
+
}
|
|
409
|
+
if (message.deviceName !== undefined) {
|
|
410
|
+
writer.uint32(434).string(message.deviceName);
|
|
411
|
+
}
|
|
412
|
+
if (message.submittedAt !== undefined) {
|
|
413
|
+
Timestamp.encode(toTimestamp(message.submittedAt), writer.uint32(442).fork()).join();
|
|
414
|
+
}
|
|
415
|
+
if (message.assigneeName !== undefined) {
|
|
416
|
+
writer.uint32(450).string(message.assigneeName);
|
|
417
|
+
}
|
|
375
418
|
return writer;
|
|
376
419
|
},
|
|
377
420
|
decode(input, length) {
|
|
@@ -745,6 +788,55 @@ export const Maintenance = {
|
|
|
745
788
|
message.files.push(FleetDocument.decode(reader, reader.uint32()));
|
|
746
789
|
continue;
|
|
747
790
|
}
|
|
791
|
+
case 50: {
|
|
792
|
+
if (tag !== 401) {
|
|
793
|
+
break;
|
|
794
|
+
}
|
|
795
|
+
message.estimatedCost = reader.double();
|
|
796
|
+
continue;
|
|
797
|
+
}
|
|
798
|
+
case 51: {
|
|
799
|
+
if (tag !== 410) {
|
|
800
|
+
break;
|
|
801
|
+
}
|
|
802
|
+
message.acceptedAt = fromTimestamp(Timestamp.decode(reader, reader.uint32()));
|
|
803
|
+
continue;
|
|
804
|
+
}
|
|
805
|
+
case 52: {
|
|
806
|
+
if (tag !== 416) {
|
|
807
|
+
break;
|
|
808
|
+
}
|
|
809
|
+
message.source = reader.int32();
|
|
810
|
+
continue;
|
|
811
|
+
}
|
|
812
|
+
case 53: {
|
|
813
|
+
if (tag !== 426) {
|
|
814
|
+
break;
|
|
815
|
+
}
|
|
816
|
+
message.program = ServiceProgram.decode(reader, reader.uint32());
|
|
817
|
+
continue;
|
|
818
|
+
}
|
|
819
|
+
case 54: {
|
|
820
|
+
if (tag !== 434) {
|
|
821
|
+
break;
|
|
822
|
+
}
|
|
823
|
+
message.deviceName = reader.string();
|
|
824
|
+
continue;
|
|
825
|
+
}
|
|
826
|
+
case 55: {
|
|
827
|
+
if (tag !== 442) {
|
|
828
|
+
break;
|
|
829
|
+
}
|
|
830
|
+
message.submittedAt = fromTimestamp(Timestamp.decode(reader, reader.uint32()));
|
|
831
|
+
continue;
|
|
832
|
+
}
|
|
833
|
+
case 56: {
|
|
834
|
+
if (tag !== 450) {
|
|
835
|
+
break;
|
|
836
|
+
}
|
|
837
|
+
message.assigneeName = reader.string();
|
|
838
|
+
continue;
|
|
839
|
+
}
|
|
748
840
|
}
|
|
749
841
|
if ((tag & 7) === 4 || tag === 0) {
|
|
750
842
|
break;
|
|
@@ -845,6 +937,15 @@ export const Maintenance = {
|
|
|
845
937
|
message.openIssues = object.openIssues?.map((e) => Issue.fromPartial(e)) || [];
|
|
846
938
|
message.issues = object.issues?.map((e) => Issue.fromPartial(e)) || [];
|
|
847
939
|
message.files = object.files?.map((e) => FleetDocument.fromPartial(e)) || [];
|
|
940
|
+
message.estimatedCost = object.estimatedCost ?? undefined;
|
|
941
|
+
message.acceptedAt = object.acceptedAt ?? undefined;
|
|
942
|
+
message.source = object.source ?? 0;
|
|
943
|
+
message.program = (object.program !== undefined && object.program !== null)
|
|
944
|
+
? ServiceProgram.fromPartial(object.program)
|
|
945
|
+
: undefined;
|
|
946
|
+
message.deviceName = object.deviceName ?? undefined;
|
|
947
|
+
message.submittedAt = object.submittedAt ?? undefined;
|
|
948
|
+
message.assigneeName = object.assigneeName ?? undefined;
|
|
848
949
|
return message;
|
|
849
950
|
},
|
|
850
951
|
};
|
|
@@ -868,6 +969,20 @@ function createBaseMaintenanceService() {
|
|
|
868
969
|
notifyRoleIds: [],
|
|
869
970
|
isActive: false,
|
|
870
971
|
description: undefined,
|
|
972
|
+
safetyClass: 0,
|
|
973
|
+
triggerReportKeywords: undefined,
|
|
974
|
+
triggerDocType: undefined,
|
|
975
|
+
requireVisit: false,
|
|
976
|
+
defaultVendorId: undefined,
|
|
977
|
+
estimate: undefined,
|
|
978
|
+
nearNotifyDriver: false,
|
|
979
|
+
nearNotifyManager: false,
|
|
980
|
+
dueDailyReminder: false,
|
|
981
|
+
dueMarkVehicle: false,
|
|
982
|
+
overdueSteps: [],
|
|
983
|
+
templateId: undefined,
|
|
984
|
+
defaultVendor: undefined,
|
|
985
|
+
programIds: [],
|
|
871
986
|
};
|
|
872
987
|
}
|
|
873
988
|
export const MaintenanceService = {
|
|
@@ -928,6 +1043,50 @@ export const MaintenanceService = {
|
|
|
928
1043
|
if (message.description !== undefined) {
|
|
929
1044
|
writer.uint32(146).string(message.description);
|
|
930
1045
|
}
|
|
1046
|
+
if (message.safetyClass !== 0) {
|
|
1047
|
+
writer.uint32(152).int32(message.safetyClass);
|
|
1048
|
+
}
|
|
1049
|
+
if (message.triggerReportKeywords !== undefined) {
|
|
1050
|
+
writer.uint32(162).string(message.triggerReportKeywords);
|
|
1051
|
+
}
|
|
1052
|
+
if (message.triggerDocType !== undefined) {
|
|
1053
|
+
writer.uint32(168).int32(message.triggerDocType);
|
|
1054
|
+
}
|
|
1055
|
+
if (message.requireVisit !== false) {
|
|
1056
|
+
writer.uint32(176).bool(message.requireVisit);
|
|
1057
|
+
}
|
|
1058
|
+
if (message.defaultVendorId !== undefined) {
|
|
1059
|
+
writer.uint32(184).uint64(message.defaultVendorId.toString());
|
|
1060
|
+
}
|
|
1061
|
+
if (message.estimate !== undefined) {
|
|
1062
|
+
writer.uint32(193).double(message.estimate);
|
|
1063
|
+
}
|
|
1064
|
+
if (message.nearNotifyDriver !== false) {
|
|
1065
|
+
writer.uint32(200).bool(message.nearNotifyDriver);
|
|
1066
|
+
}
|
|
1067
|
+
if (message.nearNotifyManager !== false) {
|
|
1068
|
+
writer.uint32(208).bool(message.nearNotifyManager);
|
|
1069
|
+
}
|
|
1070
|
+
if (message.dueDailyReminder !== false) {
|
|
1071
|
+
writer.uint32(216).bool(message.dueDailyReminder);
|
|
1072
|
+
}
|
|
1073
|
+
if (message.dueMarkVehicle !== false) {
|
|
1074
|
+
writer.uint32(224).bool(message.dueMarkVehicle);
|
|
1075
|
+
}
|
|
1076
|
+
for (const v of message.overdueSteps) {
|
|
1077
|
+
MaintenanceAlertStep.encode(v, writer.uint32(234).fork()).join();
|
|
1078
|
+
}
|
|
1079
|
+
if (message.templateId !== undefined) {
|
|
1080
|
+
writer.uint32(240).uint64(message.templateId.toString());
|
|
1081
|
+
}
|
|
1082
|
+
if (message.defaultVendor !== undefined) {
|
|
1083
|
+
Vendor.encode(message.defaultVendor, writer.uint32(250).fork()).join();
|
|
1084
|
+
}
|
|
1085
|
+
writer.uint32(258).fork();
|
|
1086
|
+
for (const v of message.programIds) {
|
|
1087
|
+
writer.uint64(v.toString());
|
|
1088
|
+
}
|
|
1089
|
+
writer.join();
|
|
931
1090
|
return writer;
|
|
932
1091
|
},
|
|
933
1092
|
decode(input, length) {
|
|
@@ -1070,6 +1229,111 @@ export const MaintenanceService = {
|
|
|
1070
1229
|
message.description = reader.string();
|
|
1071
1230
|
continue;
|
|
1072
1231
|
}
|
|
1232
|
+
case 19: {
|
|
1233
|
+
if (tag !== 152) {
|
|
1234
|
+
break;
|
|
1235
|
+
}
|
|
1236
|
+
message.safetyClass = reader.int32();
|
|
1237
|
+
continue;
|
|
1238
|
+
}
|
|
1239
|
+
case 20: {
|
|
1240
|
+
if (tag !== 162) {
|
|
1241
|
+
break;
|
|
1242
|
+
}
|
|
1243
|
+
message.triggerReportKeywords = reader.string();
|
|
1244
|
+
continue;
|
|
1245
|
+
}
|
|
1246
|
+
case 21: {
|
|
1247
|
+
if (tag !== 168) {
|
|
1248
|
+
break;
|
|
1249
|
+
}
|
|
1250
|
+
message.triggerDocType = reader.int32();
|
|
1251
|
+
continue;
|
|
1252
|
+
}
|
|
1253
|
+
case 22: {
|
|
1254
|
+
if (tag !== 176) {
|
|
1255
|
+
break;
|
|
1256
|
+
}
|
|
1257
|
+
message.requireVisit = reader.bool();
|
|
1258
|
+
continue;
|
|
1259
|
+
}
|
|
1260
|
+
case 23: {
|
|
1261
|
+
if (tag !== 184) {
|
|
1262
|
+
break;
|
|
1263
|
+
}
|
|
1264
|
+
message.defaultVendorId = Long.fromString(reader.uint64().toString(), true);
|
|
1265
|
+
continue;
|
|
1266
|
+
}
|
|
1267
|
+
case 24: {
|
|
1268
|
+
if (tag !== 193) {
|
|
1269
|
+
break;
|
|
1270
|
+
}
|
|
1271
|
+
message.estimate = reader.double();
|
|
1272
|
+
continue;
|
|
1273
|
+
}
|
|
1274
|
+
case 25: {
|
|
1275
|
+
if (tag !== 200) {
|
|
1276
|
+
break;
|
|
1277
|
+
}
|
|
1278
|
+
message.nearNotifyDriver = reader.bool();
|
|
1279
|
+
continue;
|
|
1280
|
+
}
|
|
1281
|
+
case 26: {
|
|
1282
|
+
if (tag !== 208) {
|
|
1283
|
+
break;
|
|
1284
|
+
}
|
|
1285
|
+
message.nearNotifyManager = reader.bool();
|
|
1286
|
+
continue;
|
|
1287
|
+
}
|
|
1288
|
+
case 27: {
|
|
1289
|
+
if (tag !== 216) {
|
|
1290
|
+
break;
|
|
1291
|
+
}
|
|
1292
|
+
message.dueDailyReminder = reader.bool();
|
|
1293
|
+
continue;
|
|
1294
|
+
}
|
|
1295
|
+
case 28: {
|
|
1296
|
+
if (tag !== 224) {
|
|
1297
|
+
break;
|
|
1298
|
+
}
|
|
1299
|
+
message.dueMarkVehicle = reader.bool();
|
|
1300
|
+
continue;
|
|
1301
|
+
}
|
|
1302
|
+
case 29: {
|
|
1303
|
+
if (tag !== 234) {
|
|
1304
|
+
break;
|
|
1305
|
+
}
|
|
1306
|
+
message.overdueSteps.push(MaintenanceAlertStep.decode(reader, reader.uint32()));
|
|
1307
|
+
continue;
|
|
1308
|
+
}
|
|
1309
|
+
case 30: {
|
|
1310
|
+
if (tag !== 240) {
|
|
1311
|
+
break;
|
|
1312
|
+
}
|
|
1313
|
+
message.templateId = Long.fromString(reader.uint64().toString(), true);
|
|
1314
|
+
continue;
|
|
1315
|
+
}
|
|
1316
|
+
case 31: {
|
|
1317
|
+
if (tag !== 250) {
|
|
1318
|
+
break;
|
|
1319
|
+
}
|
|
1320
|
+
message.defaultVendor = Vendor.decode(reader, reader.uint32());
|
|
1321
|
+
continue;
|
|
1322
|
+
}
|
|
1323
|
+
case 32: {
|
|
1324
|
+
if (tag === 256) {
|
|
1325
|
+
message.programIds.push(Long.fromString(reader.uint64().toString(), true));
|
|
1326
|
+
continue;
|
|
1327
|
+
}
|
|
1328
|
+
if (tag === 258) {
|
|
1329
|
+
const end2 = reader.uint32() + reader.pos;
|
|
1330
|
+
while (reader.pos < end2) {
|
|
1331
|
+
message.programIds.push(Long.fromString(reader.uint64().toString(), true));
|
|
1332
|
+
}
|
|
1333
|
+
continue;
|
|
1334
|
+
}
|
|
1335
|
+
break;
|
|
1336
|
+
}
|
|
1073
1337
|
}
|
|
1074
1338
|
if ((tag & 7) === 4 || tag === 0) {
|
|
1075
1339
|
break;
|
|
@@ -1116,6 +1380,672 @@ export const MaintenanceService = {
|
|
|
1116
1380
|
message.notifyRoleIds = object.notifyRoleIds?.map((e) => Long.fromValue(e)) || [];
|
|
1117
1381
|
message.isActive = object.isActive ?? false;
|
|
1118
1382
|
message.description = object.description ?? undefined;
|
|
1383
|
+
message.safetyClass = object.safetyClass ?? 0;
|
|
1384
|
+
message.triggerReportKeywords = object.triggerReportKeywords ?? undefined;
|
|
1385
|
+
message.triggerDocType = object.triggerDocType ?? undefined;
|
|
1386
|
+
message.requireVisit = object.requireVisit ?? false;
|
|
1387
|
+
message.defaultVendorId = (object.defaultVendorId !== undefined && object.defaultVendorId !== null)
|
|
1388
|
+
? Long.fromValue(object.defaultVendorId)
|
|
1389
|
+
: undefined;
|
|
1390
|
+
message.estimate = object.estimate ?? undefined;
|
|
1391
|
+
message.nearNotifyDriver = object.nearNotifyDriver ?? false;
|
|
1392
|
+
message.nearNotifyManager = object.nearNotifyManager ?? false;
|
|
1393
|
+
message.dueDailyReminder = object.dueDailyReminder ?? false;
|
|
1394
|
+
message.dueMarkVehicle = object.dueMarkVehicle ?? false;
|
|
1395
|
+
message.overdueSteps = object.overdueSteps?.map((e) => MaintenanceAlertStep.fromPartial(e)) || [];
|
|
1396
|
+
message.templateId = (object.templateId !== undefined && object.templateId !== null)
|
|
1397
|
+
? Long.fromValue(object.templateId)
|
|
1398
|
+
: undefined;
|
|
1399
|
+
message.defaultVendor = (object.defaultVendor !== undefined && object.defaultVendor !== null)
|
|
1400
|
+
? Vendor.fromPartial(object.defaultVendor)
|
|
1401
|
+
: undefined;
|
|
1402
|
+
message.programIds = object.programIds?.map((e) => Long.fromValue(e)) || [];
|
|
1403
|
+
return message;
|
|
1404
|
+
},
|
|
1405
|
+
};
|
|
1406
|
+
function createBaseMaintenanceAlertStep() {
|
|
1407
|
+
return { km: 0, mapRed: false, smsManager: false, stopDriver: false };
|
|
1408
|
+
}
|
|
1409
|
+
export const MaintenanceAlertStep = {
|
|
1410
|
+
encode(message, writer = new BinaryWriter()) {
|
|
1411
|
+
if (message.km !== 0) {
|
|
1412
|
+
writer.uint32(8).uint32(message.km);
|
|
1413
|
+
}
|
|
1414
|
+
if (message.mapRed !== false) {
|
|
1415
|
+
writer.uint32(16).bool(message.mapRed);
|
|
1416
|
+
}
|
|
1417
|
+
if (message.smsManager !== false) {
|
|
1418
|
+
writer.uint32(24).bool(message.smsManager);
|
|
1419
|
+
}
|
|
1420
|
+
if (message.stopDriver !== false) {
|
|
1421
|
+
writer.uint32(32).bool(message.stopDriver);
|
|
1422
|
+
}
|
|
1423
|
+
return writer;
|
|
1424
|
+
},
|
|
1425
|
+
decode(input, length) {
|
|
1426
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
1427
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
1428
|
+
const message = createBaseMaintenanceAlertStep();
|
|
1429
|
+
while (reader.pos < end) {
|
|
1430
|
+
const tag = reader.uint32();
|
|
1431
|
+
switch (tag >>> 3) {
|
|
1432
|
+
case 1: {
|
|
1433
|
+
if (tag !== 8) {
|
|
1434
|
+
break;
|
|
1435
|
+
}
|
|
1436
|
+
message.km = reader.uint32();
|
|
1437
|
+
continue;
|
|
1438
|
+
}
|
|
1439
|
+
case 2: {
|
|
1440
|
+
if (tag !== 16) {
|
|
1441
|
+
break;
|
|
1442
|
+
}
|
|
1443
|
+
message.mapRed = reader.bool();
|
|
1444
|
+
continue;
|
|
1445
|
+
}
|
|
1446
|
+
case 3: {
|
|
1447
|
+
if (tag !== 24) {
|
|
1448
|
+
break;
|
|
1449
|
+
}
|
|
1450
|
+
message.smsManager = reader.bool();
|
|
1451
|
+
continue;
|
|
1452
|
+
}
|
|
1453
|
+
case 4: {
|
|
1454
|
+
if (tag !== 32) {
|
|
1455
|
+
break;
|
|
1456
|
+
}
|
|
1457
|
+
message.stopDriver = reader.bool();
|
|
1458
|
+
continue;
|
|
1459
|
+
}
|
|
1460
|
+
}
|
|
1461
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
1462
|
+
break;
|
|
1463
|
+
}
|
|
1464
|
+
reader.skip(tag & 7);
|
|
1465
|
+
}
|
|
1466
|
+
return message;
|
|
1467
|
+
},
|
|
1468
|
+
create(base) {
|
|
1469
|
+
return MaintenanceAlertStep.fromPartial(base ?? {});
|
|
1470
|
+
},
|
|
1471
|
+
fromPartial(object) {
|
|
1472
|
+
const message = createBaseMaintenanceAlertStep();
|
|
1473
|
+
message.km = object.km ?? 0;
|
|
1474
|
+
message.mapRed = object.mapRed ?? false;
|
|
1475
|
+
message.smsManager = object.smsManager ?? false;
|
|
1476
|
+
message.stopDriver = object.stopDriver ?? false;
|
|
1477
|
+
return message;
|
|
1478
|
+
},
|
|
1479
|
+
};
|
|
1480
|
+
function createBaseProgramVehicle() {
|
|
1481
|
+
return { deviceId: Long.UZERO, name: "", plate: undefined, odometer: undefined, entryCount: 0, next: undefined };
|
|
1482
|
+
}
|
|
1483
|
+
export const ProgramVehicle = {
|
|
1484
|
+
encode(message, writer = new BinaryWriter()) {
|
|
1485
|
+
if (!message.deviceId.equals(Long.UZERO)) {
|
|
1486
|
+
writer.uint32(8).uint64(message.deviceId.toString());
|
|
1487
|
+
}
|
|
1488
|
+
if (message.name !== "") {
|
|
1489
|
+
writer.uint32(18).string(message.name);
|
|
1490
|
+
}
|
|
1491
|
+
if (message.plate !== undefined) {
|
|
1492
|
+
writer.uint32(26).string(message.plate);
|
|
1493
|
+
}
|
|
1494
|
+
if (message.odometer !== undefined) {
|
|
1495
|
+
writer.uint32(32).uint64(message.odometer.toString());
|
|
1496
|
+
}
|
|
1497
|
+
if (message.entryCount !== 0) {
|
|
1498
|
+
writer.uint32(40).uint32(message.entryCount);
|
|
1499
|
+
}
|
|
1500
|
+
if (message.next !== undefined) {
|
|
1501
|
+
Maintenance.encode(message.next, writer.uint32(50).fork()).join();
|
|
1502
|
+
}
|
|
1503
|
+
return writer;
|
|
1504
|
+
},
|
|
1505
|
+
decode(input, length) {
|
|
1506
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
1507
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
1508
|
+
const message = createBaseProgramVehicle();
|
|
1509
|
+
while (reader.pos < end) {
|
|
1510
|
+
const tag = reader.uint32();
|
|
1511
|
+
switch (tag >>> 3) {
|
|
1512
|
+
case 1: {
|
|
1513
|
+
if (tag !== 8) {
|
|
1514
|
+
break;
|
|
1515
|
+
}
|
|
1516
|
+
message.deviceId = Long.fromString(reader.uint64().toString(), true);
|
|
1517
|
+
continue;
|
|
1518
|
+
}
|
|
1519
|
+
case 2: {
|
|
1520
|
+
if (tag !== 18) {
|
|
1521
|
+
break;
|
|
1522
|
+
}
|
|
1523
|
+
message.name = reader.string();
|
|
1524
|
+
continue;
|
|
1525
|
+
}
|
|
1526
|
+
case 3: {
|
|
1527
|
+
if (tag !== 26) {
|
|
1528
|
+
break;
|
|
1529
|
+
}
|
|
1530
|
+
message.plate = reader.string();
|
|
1531
|
+
continue;
|
|
1532
|
+
}
|
|
1533
|
+
case 4: {
|
|
1534
|
+
if (tag !== 32) {
|
|
1535
|
+
break;
|
|
1536
|
+
}
|
|
1537
|
+
message.odometer = Long.fromString(reader.uint64().toString(), true);
|
|
1538
|
+
continue;
|
|
1539
|
+
}
|
|
1540
|
+
case 5: {
|
|
1541
|
+
if (tag !== 40) {
|
|
1542
|
+
break;
|
|
1543
|
+
}
|
|
1544
|
+
message.entryCount = reader.uint32();
|
|
1545
|
+
continue;
|
|
1546
|
+
}
|
|
1547
|
+
case 6: {
|
|
1548
|
+
if (tag !== 50) {
|
|
1549
|
+
break;
|
|
1550
|
+
}
|
|
1551
|
+
message.next = Maintenance.decode(reader, reader.uint32());
|
|
1552
|
+
continue;
|
|
1553
|
+
}
|
|
1554
|
+
}
|
|
1555
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
1556
|
+
break;
|
|
1557
|
+
}
|
|
1558
|
+
reader.skip(tag & 7);
|
|
1559
|
+
}
|
|
1560
|
+
return message;
|
|
1561
|
+
},
|
|
1562
|
+
create(base) {
|
|
1563
|
+
return ProgramVehicle.fromPartial(base ?? {});
|
|
1564
|
+
},
|
|
1565
|
+
fromPartial(object) {
|
|
1566
|
+
const message = createBaseProgramVehicle();
|
|
1567
|
+
message.deviceId = (object.deviceId !== undefined && object.deviceId !== null)
|
|
1568
|
+
? Long.fromValue(object.deviceId)
|
|
1569
|
+
: Long.UZERO;
|
|
1570
|
+
message.name = object.name ?? "";
|
|
1571
|
+
message.plate = object.plate ?? undefined;
|
|
1572
|
+
message.odometer = (object.odometer !== undefined && object.odometer !== null)
|
|
1573
|
+
? Long.fromValue(object.odometer)
|
|
1574
|
+
: undefined;
|
|
1575
|
+
message.entryCount = object.entryCount ?? 0;
|
|
1576
|
+
message.next = (object.next !== undefined && object.next !== null)
|
|
1577
|
+
? Maintenance.fromPartial(object.next)
|
|
1578
|
+
: undefined;
|
|
1579
|
+
return message;
|
|
1580
|
+
},
|
|
1581
|
+
};
|
|
1582
|
+
function createBaseProgramVehicleList() {
|
|
1583
|
+
return { data: [] };
|
|
1584
|
+
}
|
|
1585
|
+
export const ProgramVehicleList = {
|
|
1586
|
+
encode(message, writer = new BinaryWriter()) {
|
|
1587
|
+
for (const v of message.data) {
|
|
1588
|
+
ProgramVehicle.encode(v, writer.uint32(10).fork()).join();
|
|
1589
|
+
}
|
|
1590
|
+
return writer;
|
|
1591
|
+
},
|
|
1592
|
+
decode(input, length) {
|
|
1593
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
1594
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
1595
|
+
const message = createBaseProgramVehicleList();
|
|
1596
|
+
while (reader.pos < end) {
|
|
1597
|
+
const tag = reader.uint32();
|
|
1598
|
+
switch (tag >>> 3) {
|
|
1599
|
+
case 1: {
|
|
1600
|
+
if (tag !== 10) {
|
|
1601
|
+
break;
|
|
1602
|
+
}
|
|
1603
|
+
message.data.push(ProgramVehicle.decode(reader, reader.uint32()));
|
|
1604
|
+
continue;
|
|
1605
|
+
}
|
|
1606
|
+
}
|
|
1607
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
1608
|
+
break;
|
|
1609
|
+
}
|
|
1610
|
+
reader.skip(tag & 7);
|
|
1611
|
+
}
|
|
1612
|
+
return message;
|
|
1613
|
+
},
|
|
1614
|
+
create(base) {
|
|
1615
|
+
return ProgramVehicleList.fromPartial(base ?? {});
|
|
1616
|
+
},
|
|
1617
|
+
fromPartial(object) {
|
|
1618
|
+
const message = createBaseProgramVehicleList();
|
|
1619
|
+
message.data = object.data?.map((e) => ProgramVehicle.fromPartial(e)) || [];
|
|
1620
|
+
return message;
|
|
1621
|
+
},
|
|
1622
|
+
};
|
|
1623
|
+
function createBaseProgramAssignPreview() {
|
|
1624
|
+
return { rows: [], annualEstimate: 0, dueWithin30Days: 0, skippedDeviceIds: [] };
|
|
1625
|
+
}
|
|
1626
|
+
export const ProgramAssignPreview = {
|
|
1627
|
+
encode(message, writer = new BinaryWriter()) {
|
|
1628
|
+
for (const v of message.rows) {
|
|
1629
|
+
ProgramAssignPreview_Row.encode(v, writer.uint32(10).fork()).join();
|
|
1630
|
+
}
|
|
1631
|
+
if (message.annualEstimate !== 0) {
|
|
1632
|
+
writer.uint32(17).double(message.annualEstimate);
|
|
1633
|
+
}
|
|
1634
|
+
if (message.dueWithin30Days !== 0) {
|
|
1635
|
+
writer.uint32(24).uint32(message.dueWithin30Days);
|
|
1636
|
+
}
|
|
1637
|
+
writer.uint32(34).fork();
|
|
1638
|
+
for (const v of message.skippedDeviceIds) {
|
|
1639
|
+
writer.uint64(v.toString());
|
|
1640
|
+
}
|
|
1641
|
+
writer.join();
|
|
1642
|
+
return writer;
|
|
1643
|
+
},
|
|
1644
|
+
decode(input, length) {
|
|
1645
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
1646
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
1647
|
+
const message = createBaseProgramAssignPreview();
|
|
1648
|
+
while (reader.pos < end) {
|
|
1649
|
+
const tag = reader.uint32();
|
|
1650
|
+
switch (tag >>> 3) {
|
|
1651
|
+
case 1: {
|
|
1652
|
+
if (tag !== 10) {
|
|
1653
|
+
break;
|
|
1654
|
+
}
|
|
1655
|
+
message.rows.push(ProgramAssignPreview_Row.decode(reader, reader.uint32()));
|
|
1656
|
+
continue;
|
|
1657
|
+
}
|
|
1658
|
+
case 2: {
|
|
1659
|
+
if (tag !== 17) {
|
|
1660
|
+
break;
|
|
1661
|
+
}
|
|
1662
|
+
message.annualEstimate = reader.double();
|
|
1663
|
+
continue;
|
|
1664
|
+
}
|
|
1665
|
+
case 3: {
|
|
1666
|
+
if (tag !== 24) {
|
|
1667
|
+
break;
|
|
1668
|
+
}
|
|
1669
|
+
message.dueWithin30Days = reader.uint32();
|
|
1670
|
+
continue;
|
|
1671
|
+
}
|
|
1672
|
+
case 4: {
|
|
1673
|
+
if (tag === 32) {
|
|
1674
|
+
message.skippedDeviceIds.push(Long.fromString(reader.uint64().toString(), true));
|
|
1675
|
+
continue;
|
|
1676
|
+
}
|
|
1677
|
+
if (tag === 34) {
|
|
1678
|
+
const end2 = reader.uint32() + reader.pos;
|
|
1679
|
+
while (reader.pos < end2) {
|
|
1680
|
+
message.skippedDeviceIds.push(Long.fromString(reader.uint64().toString(), true));
|
|
1681
|
+
}
|
|
1682
|
+
continue;
|
|
1683
|
+
}
|
|
1684
|
+
break;
|
|
1685
|
+
}
|
|
1686
|
+
}
|
|
1687
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
1688
|
+
break;
|
|
1689
|
+
}
|
|
1690
|
+
reader.skip(tag & 7);
|
|
1691
|
+
}
|
|
1692
|
+
return message;
|
|
1693
|
+
},
|
|
1694
|
+
create(base) {
|
|
1695
|
+
return ProgramAssignPreview.fromPartial(base ?? {});
|
|
1696
|
+
},
|
|
1697
|
+
fromPartial(object) {
|
|
1698
|
+
const message = createBaseProgramAssignPreview();
|
|
1699
|
+
message.rows = object.rows?.map((e) => ProgramAssignPreview_Row.fromPartial(e)) || [];
|
|
1700
|
+
message.annualEstimate = object.annualEstimate ?? 0;
|
|
1701
|
+
message.dueWithin30Days = object.dueWithin30Days ?? 0;
|
|
1702
|
+
message.skippedDeviceIds = object.skippedDeviceIds?.map((e) => Long.fromValue(e)) || [];
|
|
1703
|
+
return message;
|
|
1704
|
+
},
|
|
1705
|
+
};
|
|
1706
|
+
function createBaseProgramAssignPreview_Row() {
|
|
1707
|
+
return {
|
|
1708
|
+
deviceId: Long.UZERO,
|
|
1709
|
+
deviceName: "",
|
|
1710
|
+
serviceId: Long.UZERO,
|
|
1711
|
+
serviceName: "",
|
|
1712
|
+
dueMileage: undefined,
|
|
1713
|
+
expiresAt: undefined,
|
|
1714
|
+
estimate: undefined,
|
|
1715
|
+
hasHistory: false,
|
|
1716
|
+
odometer: undefined,
|
|
1717
|
+
};
|
|
1718
|
+
}
|
|
1719
|
+
export const ProgramAssignPreview_Row = {
|
|
1720
|
+
encode(message, writer = new BinaryWriter()) {
|
|
1721
|
+
if (!message.deviceId.equals(Long.UZERO)) {
|
|
1722
|
+
writer.uint32(8).uint64(message.deviceId.toString());
|
|
1723
|
+
}
|
|
1724
|
+
if (message.deviceName !== "") {
|
|
1725
|
+
writer.uint32(18).string(message.deviceName);
|
|
1726
|
+
}
|
|
1727
|
+
if (!message.serviceId.equals(Long.UZERO)) {
|
|
1728
|
+
writer.uint32(24).uint64(message.serviceId.toString());
|
|
1729
|
+
}
|
|
1730
|
+
if (message.serviceName !== "") {
|
|
1731
|
+
writer.uint32(34).string(message.serviceName);
|
|
1732
|
+
}
|
|
1733
|
+
if (message.dueMileage !== undefined) {
|
|
1734
|
+
writer.uint32(40).uint64(message.dueMileage.toString());
|
|
1735
|
+
}
|
|
1736
|
+
if (message.expiresAt !== undefined) {
|
|
1737
|
+
Timestamp.encode(toTimestamp(message.expiresAt), writer.uint32(50).fork()).join();
|
|
1738
|
+
}
|
|
1739
|
+
if (message.estimate !== undefined) {
|
|
1740
|
+
writer.uint32(57).double(message.estimate);
|
|
1741
|
+
}
|
|
1742
|
+
if (message.hasHistory !== false) {
|
|
1743
|
+
writer.uint32(64).bool(message.hasHistory);
|
|
1744
|
+
}
|
|
1745
|
+
if (message.odometer !== undefined) {
|
|
1746
|
+
writer.uint32(72).uint64(message.odometer.toString());
|
|
1747
|
+
}
|
|
1748
|
+
return writer;
|
|
1749
|
+
},
|
|
1750
|
+
decode(input, length) {
|
|
1751
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
1752
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
1753
|
+
const message = createBaseProgramAssignPreview_Row();
|
|
1754
|
+
while (reader.pos < end) {
|
|
1755
|
+
const tag = reader.uint32();
|
|
1756
|
+
switch (tag >>> 3) {
|
|
1757
|
+
case 1: {
|
|
1758
|
+
if (tag !== 8) {
|
|
1759
|
+
break;
|
|
1760
|
+
}
|
|
1761
|
+
message.deviceId = Long.fromString(reader.uint64().toString(), true);
|
|
1762
|
+
continue;
|
|
1763
|
+
}
|
|
1764
|
+
case 2: {
|
|
1765
|
+
if (tag !== 18) {
|
|
1766
|
+
break;
|
|
1767
|
+
}
|
|
1768
|
+
message.deviceName = reader.string();
|
|
1769
|
+
continue;
|
|
1770
|
+
}
|
|
1771
|
+
case 3: {
|
|
1772
|
+
if (tag !== 24) {
|
|
1773
|
+
break;
|
|
1774
|
+
}
|
|
1775
|
+
message.serviceId = Long.fromString(reader.uint64().toString(), true);
|
|
1776
|
+
continue;
|
|
1777
|
+
}
|
|
1778
|
+
case 4: {
|
|
1779
|
+
if (tag !== 34) {
|
|
1780
|
+
break;
|
|
1781
|
+
}
|
|
1782
|
+
message.serviceName = reader.string();
|
|
1783
|
+
continue;
|
|
1784
|
+
}
|
|
1785
|
+
case 5: {
|
|
1786
|
+
if (tag !== 40) {
|
|
1787
|
+
break;
|
|
1788
|
+
}
|
|
1789
|
+
message.dueMileage = Long.fromString(reader.uint64().toString(), true);
|
|
1790
|
+
continue;
|
|
1791
|
+
}
|
|
1792
|
+
case 6: {
|
|
1793
|
+
if (tag !== 50) {
|
|
1794
|
+
break;
|
|
1795
|
+
}
|
|
1796
|
+
message.expiresAt = fromTimestamp(Timestamp.decode(reader, reader.uint32()));
|
|
1797
|
+
continue;
|
|
1798
|
+
}
|
|
1799
|
+
case 7: {
|
|
1800
|
+
if (tag !== 57) {
|
|
1801
|
+
break;
|
|
1802
|
+
}
|
|
1803
|
+
message.estimate = reader.double();
|
|
1804
|
+
continue;
|
|
1805
|
+
}
|
|
1806
|
+
case 8: {
|
|
1807
|
+
if (tag !== 64) {
|
|
1808
|
+
break;
|
|
1809
|
+
}
|
|
1810
|
+
message.hasHistory = reader.bool();
|
|
1811
|
+
continue;
|
|
1812
|
+
}
|
|
1813
|
+
case 9: {
|
|
1814
|
+
if (tag !== 72) {
|
|
1815
|
+
break;
|
|
1816
|
+
}
|
|
1817
|
+
message.odometer = Long.fromString(reader.uint64().toString(), true);
|
|
1818
|
+
continue;
|
|
1819
|
+
}
|
|
1820
|
+
}
|
|
1821
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
1822
|
+
break;
|
|
1823
|
+
}
|
|
1824
|
+
reader.skip(tag & 7);
|
|
1825
|
+
}
|
|
1826
|
+
return message;
|
|
1827
|
+
},
|
|
1828
|
+
create(base) {
|
|
1829
|
+
return ProgramAssignPreview_Row.fromPartial(base ?? {});
|
|
1830
|
+
},
|
|
1831
|
+
fromPartial(object) {
|
|
1832
|
+
const message = createBaseProgramAssignPreview_Row();
|
|
1833
|
+
message.deviceId = (object.deviceId !== undefined && object.deviceId !== null)
|
|
1834
|
+
? Long.fromValue(object.deviceId)
|
|
1835
|
+
: Long.UZERO;
|
|
1836
|
+
message.deviceName = object.deviceName ?? "";
|
|
1837
|
+
message.serviceId = (object.serviceId !== undefined && object.serviceId !== null)
|
|
1838
|
+
? Long.fromValue(object.serviceId)
|
|
1839
|
+
: Long.UZERO;
|
|
1840
|
+
message.serviceName = object.serviceName ?? "";
|
|
1841
|
+
message.dueMileage = (object.dueMileage !== undefined && object.dueMileage !== null)
|
|
1842
|
+
? Long.fromValue(object.dueMileage)
|
|
1843
|
+
: undefined;
|
|
1844
|
+
message.expiresAt = object.expiresAt ?? undefined;
|
|
1845
|
+
message.estimate = object.estimate ?? undefined;
|
|
1846
|
+
message.hasHistory = object.hasHistory ?? false;
|
|
1847
|
+
message.odometer = (object.odometer !== undefined && object.odometer !== null)
|
|
1848
|
+
? Long.fromValue(object.odometer)
|
|
1849
|
+
: undefined;
|
|
1850
|
+
return message;
|
|
1851
|
+
},
|
|
1852
|
+
};
|
|
1853
|
+
function createBaseServiceEntryStats() {
|
|
1854
|
+
return {
|
|
1855
|
+
cost: 0,
|
|
1856
|
+
parts: 0,
|
|
1857
|
+
labour: 0,
|
|
1858
|
+
count: 0,
|
|
1859
|
+
programCount: 0,
|
|
1860
|
+
manualCount: 0,
|
|
1861
|
+
costPerKm: 0,
|
|
1862
|
+
costPerKmPrev: 0,
|
|
1863
|
+
planned: 0,
|
|
1864
|
+
inProgress: 0,
|
|
1865
|
+
reported: 0,
|
|
1866
|
+
done: 0,
|
|
1867
|
+
reportedEstimate: 0,
|
|
1868
|
+
reportedActual: 0,
|
|
1869
|
+
};
|
|
1870
|
+
}
|
|
1871
|
+
export const ServiceEntryStats = {
|
|
1872
|
+
encode(message, writer = new BinaryWriter()) {
|
|
1873
|
+
if (message.cost !== 0) {
|
|
1874
|
+
writer.uint32(9).double(message.cost);
|
|
1875
|
+
}
|
|
1876
|
+
if (message.parts !== 0) {
|
|
1877
|
+
writer.uint32(17).double(message.parts);
|
|
1878
|
+
}
|
|
1879
|
+
if (message.labour !== 0) {
|
|
1880
|
+
writer.uint32(25).double(message.labour);
|
|
1881
|
+
}
|
|
1882
|
+
if (message.count !== 0) {
|
|
1883
|
+
writer.uint32(32).uint32(message.count);
|
|
1884
|
+
}
|
|
1885
|
+
if (message.programCount !== 0) {
|
|
1886
|
+
writer.uint32(40).uint32(message.programCount);
|
|
1887
|
+
}
|
|
1888
|
+
if (message.manualCount !== 0) {
|
|
1889
|
+
writer.uint32(48).uint32(message.manualCount);
|
|
1890
|
+
}
|
|
1891
|
+
if (message.costPerKm !== 0) {
|
|
1892
|
+
writer.uint32(57).double(message.costPerKm);
|
|
1893
|
+
}
|
|
1894
|
+
if (message.costPerKmPrev !== 0) {
|
|
1895
|
+
writer.uint32(65).double(message.costPerKmPrev);
|
|
1896
|
+
}
|
|
1897
|
+
if (message.planned !== 0) {
|
|
1898
|
+
writer.uint32(72).uint32(message.planned);
|
|
1899
|
+
}
|
|
1900
|
+
if (message.inProgress !== 0) {
|
|
1901
|
+
writer.uint32(80).uint32(message.inProgress);
|
|
1902
|
+
}
|
|
1903
|
+
if (message.reported !== 0) {
|
|
1904
|
+
writer.uint32(88).uint32(message.reported);
|
|
1905
|
+
}
|
|
1906
|
+
if (message.done !== 0) {
|
|
1907
|
+
writer.uint32(96).uint32(message.done);
|
|
1908
|
+
}
|
|
1909
|
+
if (message.reportedEstimate !== 0) {
|
|
1910
|
+
writer.uint32(105).double(message.reportedEstimate);
|
|
1911
|
+
}
|
|
1912
|
+
if (message.reportedActual !== 0) {
|
|
1913
|
+
writer.uint32(113).double(message.reportedActual);
|
|
1914
|
+
}
|
|
1915
|
+
return writer;
|
|
1916
|
+
},
|
|
1917
|
+
decode(input, length) {
|
|
1918
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
1919
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
1920
|
+
const message = createBaseServiceEntryStats();
|
|
1921
|
+
while (reader.pos < end) {
|
|
1922
|
+
const tag = reader.uint32();
|
|
1923
|
+
switch (tag >>> 3) {
|
|
1924
|
+
case 1: {
|
|
1925
|
+
if (tag !== 9) {
|
|
1926
|
+
break;
|
|
1927
|
+
}
|
|
1928
|
+
message.cost = reader.double();
|
|
1929
|
+
continue;
|
|
1930
|
+
}
|
|
1931
|
+
case 2: {
|
|
1932
|
+
if (tag !== 17) {
|
|
1933
|
+
break;
|
|
1934
|
+
}
|
|
1935
|
+
message.parts = reader.double();
|
|
1936
|
+
continue;
|
|
1937
|
+
}
|
|
1938
|
+
case 3: {
|
|
1939
|
+
if (tag !== 25) {
|
|
1940
|
+
break;
|
|
1941
|
+
}
|
|
1942
|
+
message.labour = reader.double();
|
|
1943
|
+
continue;
|
|
1944
|
+
}
|
|
1945
|
+
case 4: {
|
|
1946
|
+
if (tag !== 32) {
|
|
1947
|
+
break;
|
|
1948
|
+
}
|
|
1949
|
+
message.count = reader.uint32();
|
|
1950
|
+
continue;
|
|
1951
|
+
}
|
|
1952
|
+
case 5: {
|
|
1953
|
+
if (tag !== 40) {
|
|
1954
|
+
break;
|
|
1955
|
+
}
|
|
1956
|
+
message.programCount = reader.uint32();
|
|
1957
|
+
continue;
|
|
1958
|
+
}
|
|
1959
|
+
case 6: {
|
|
1960
|
+
if (tag !== 48) {
|
|
1961
|
+
break;
|
|
1962
|
+
}
|
|
1963
|
+
message.manualCount = reader.uint32();
|
|
1964
|
+
continue;
|
|
1965
|
+
}
|
|
1966
|
+
case 7: {
|
|
1967
|
+
if (tag !== 57) {
|
|
1968
|
+
break;
|
|
1969
|
+
}
|
|
1970
|
+
message.costPerKm = reader.double();
|
|
1971
|
+
continue;
|
|
1972
|
+
}
|
|
1973
|
+
case 8: {
|
|
1974
|
+
if (tag !== 65) {
|
|
1975
|
+
break;
|
|
1976
|
+
}
|
|
1977
|
+
message.costPerKmPrev = reader.double();
|
|
1978
|
+
continue;
|
|
1979
|
+
}
|
|
1980
|
+
case 9: {
|
|
1981
|
+
if (tag !== 72) {
|
|
1982
|
+
break;
|
|
1983
|
+
}
|
|
1984
|
+
message.planned = reader.uint32();
|
|
1985
|
+
continue;
|
|
1986
|
+
}
|
|
1987
|
+
case 10: {
|
|
1988
|
+
if (tag !== 80) {
|
|
1989
|
+
break;
|
|
1990
|
+
}
|
|
1991
|
+
message.inProgress = reader.uint32();
|
|
1992
|
+
continue;
|
|
1993
|
+
}
|
|
1994
|
+
case 11: {
|
|
1995
|
+
if (tag !== 88) {
|
|
1996
|
+
break;
|
|
1997
|
+
}
|
|
1998
|
+
message.reported = reader.uint32();
|
|
1999
|
+
continue;
|
|
2000
|
+
}
|
|
2001
|
+
case 12: {
|
|
2002
|
+
if (tag !== 96) {
|
|
2003
|
+
break;
|
|
2004
|
+
}
|
|
2005
|
+
message.done = reader.uint32();
|
|
2006
|
+
continue;
|
|
2007
|
+
}
|
|
2008
|
+
case 13: {
|
|
2009
|
+
if (tag !== 105) {
|
|
2010
|
+
break;
|
|
2011
|
+
}
|
|
2012
|
+
message.reportedEstimate = reader.double();
|
|
2013
|
+
continue;
|
|
2014
|
+
}
|
|
2015
|
+
case 14: {
|
|
2016
|
+
if (tag !== 113) {
|
|
2017
|
+
break;
|
|
2018
|
+
}
|
|
2019
|
+
message.reportedActual = reader.double();
|
|
2020
|
+
continue;
|
|
2021
|
+
}
|
|
2022
|
+
}
|
|
2023
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
2024
|
+
break;
|
|
2025
|
+
}
|
|
2026
|
+
reader.skip(tag & 7);
|
|
2027
|
+
}
|
|
2028
|
+
return message;
|
|
2029
|
+
},
|
|
2030
|
+
create(base) {
|
|
2031
|
+
return ServiceEntryStats.fromPartial(base ?? {});
|
|
2032
|
+
},
|
|
2033
|
+
fromPartial(object) {
|
|
2034
|
+
const message = createBaseServiceEntryStats();
|
|
2035
|
+
message.cost = object.cost ?? 0;
|
|
2036
|
+
message.parts = object.parts ?? 0;
|
|
2037
|
+
message.labour = object.labour ?? 0;
|
|
2038
|
+
message.count = object.count ?? 0;
|
|
2039
|
+
message.programCount = object.programCount ?? 0;
|
|
2040
|
+
message.manualCount = object.manualCount ?? 0;
|
|
2041
|
+
message.costPerKm = object.costPerKm ?? 0;
|
|
2042
|
+
message.costPerKmPrev = object.costPerKmPrev ?? 0;
|
|
2043
|
+
message.planned = object.planned ?? 0;
|
|
2044
|
+
message.inProgress = object.inProgress ?? 0;
|
|
2045
|
+
message.reported = object.reported ?? 0;
|
|
2046
|
+
message.done = object.done ?? 0;
|
|
2047
|
+
message.reportedEstimate = object.reportedEstimate ?? 0;
|
|
2048
|
+
message.reportedActual = object.reportedActual ?? 0;
|
|
1119
2049
|
return message;
|
|
1120
2050
|
},
|
|
1121
2051
|
};
|