You've already forked npm-core-sdk
Latest generation
This commit is contained in:
135
site.ts
135
site.ts
@@ -12,6 +12,7 @@ import type { PartialMessage } from "@protobuf-ts/runtime";
|
||||
import { reflectionMergePartial } from "@protobuf-ts/runtime";
|
||||
import { MessageType } from "@protobuf-ts/runtime";
|
||||
import { Period } from "./shared";
|
||||
import { WMSCommission } from "./slotbooking";
|
||||
import { SegmentationFilter } from "./slotbooking";
|
||||
import { PrjMetadata } from "./metadatadef";
|
||||
import { CommandIdentifierEntry } from "./slotbooking";
|
||||
@@ -914,6 +915,45 @@ export interface UpdateAppointmentRequest {
|
||||
*/
|
||||
CustomFields: CustomField[];
|
||||
}
|
||||
/**
|
||||
* @generated from protobuf message api.WMSUpdateAppointmentRequest
|
||||
*/
|
||||
export interface WMSUpdateAppointmentRequest {
|
||||
/**
|
||||
* @generated from protobuf field: api.RequestProjectHeader Header = 1
|
||||
*/
|
||||
Header?: RequestProjectHeader;
|
||||
/**
|
||||
* @generated from protobuf field: string AppointmentID = 2
|
||||
*/
|
||||
AppointmentID: string;
|
||||
/**
|
||||
* The slots to book for the appointment
|
||||
*
|
||||
* @generated from protobuf field: repeated api.Slot Slots = 3
|
||||
*/
|
||||
Slots: Slot[];
|
||||
/**
|
||||
* The new Commissions for the appointment
|
||||
*
|
||||
* @generated from protobuf field: repeated api.WMSCommission Commissions = 4
|
||||
*/
|
||||
Commissions: WMSCommission[];
|
||||
/**
|
||||
* @generated from protobuf field: string ActorID = 5
|
||||
*/
|
||||
ActorID: string; // actor with which the siteID/project-depositID will be processed
|
||||
/**
|
||||
* time zone, useful only if a WMS send a message
|
||||
*
|
||||
* @generated from protobuf field: string TimeZone = 8
|
||||
*/
|
||||
TimeZone: string;
|
||||
/**
|
||||
* @generated from protobuf field: repeated api.CustomField CustomFields = 9
|
||||
*/
|
||||
CustomFields: CustomField[];
|
||||
}
|
||||
/**
|
||||
* ListUserSites
|
||||
*
|
||||
@@ -3881,6 +3921,100 @@ class UpdateAppointmentRequest$Type extends MessageType<UpdateAppointmentRequest
|
||||
*/
|
||||
export const UpdateAppointmentRequest = new UpdateAppointmentRequest$Type();
|
||||
// @generated message type with reflection information, may provide speed optimized methods
|
||||
class WMSUpdateAppointmentRequest$Type extends MessageType<WMSUpdateAppointmentRequest> {
|
||||
constructor() {
|
||||
super("api.WMSUpdateAppointmentRequest", [
|
||||
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestProjectHeader, options: { "validate.rules": { message: { required: true } } } },
|
||||
{ no: 2, name: "AppointmentID", kind: "scalar", localName: "AppointmentID", jsonName: "AppointmentID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1", maxLen: "192" } }, "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "Your identifier", example: "\"Your_Appointment_ID\"" } } },
|
||||
{ no: 3, name: "Slots", kind: "message", localName: "Slots", jsonName: "Slots", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Slot, options: { "validate.rules": { repeated: { minItems: "1" } }, "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "Appointment slots", example: "[\"John.doe@reflex.com\", \"will.smith@reflex.com\"]" } } },
|
||||
{ no: 4, name: "Commissions", kind: "message", localName: "Commissions", jsonName: "Commissions", repeat: 2 /*RepeatType.UNPACKED*/, T: () => WMSCommission, options: { "validate.rules": { repeated: { minItems: "1" } }, "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "Content of the appointment by project", example: "[\"John.doe@reflex.com\", \"will.smith@reflex.com\"]" } } },
|
||||
{ no: 5, name: "ActorID", kind: "scalar", localName: "ActorID", jsonName: "ActorID", T: 9 /*ScalarType.STRING*/ },
|
||||
{ no: 8, name: "TimeZone", kind: "scalar", localName: "TimeZone", jsonName: "TimeZone", T: 9 /*ScalarType.STRING*/, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "TimeZone is required only when a WMS calls the API" } } },
|
||||
{ no: 9, name: "CustomFields", kind: "message", localName: "CustomFields", jsonName: "CustomFields", repeat: 2 /*RepeatType.UNPACKED*/, T: () => CustomField, options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "A free-form key/value map provided by the client. The API stores and returns these fields as-is. Intended solely for client use; the API does not interpret or validate the content." } } }
|
||||
], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "AppointmentID", "Slots", "Commissions", "ActorID"] } } });
|
||||
}
|
||||
create(value?: PartialMessage<WMSUpdateAppointmentRequest>): WMSUpdateAppointmentRequest {
|
||||
const message = globalThis.Object.create((this.messagePrototype!));
|
||||
message.AppointmentID = "";
|
||||
message.Slots = [];
|
||||
message.Commissions = [];
|
||||
message.ActorID = "";
|
||||
message.TimeZone = "";
|
||||
message.CustomFields = [];
|
||||
if (value !== undefined)
|
||||
reflectionMergePartial<WMSUpdateAppointmentRequest>(this, message, value);
|
||||
return message;
|
||||
}
|
||||
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: WMSUpdateAppointmentRequest): WMSUpdateAppointmentRequest {
|
||||
let message = target ?? this.create(), end = reader.pos + length;
|
||||
while (reader.pos < end) {
|
||||
let [fieldNo, wireType] = reader.tag();
|
||||
switch (fieldNo) {
|
||||
case /* api.RequestProjectHeader Header */ 1:
|
||||
message.Header = RequestProjectHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
||||
break;
|
||||
case /* string AppointmentID */ 2:
|
||||
message.AppointmentID = reader.string();
|
||||
break;
|
||||
case /* repeated api.Slot Slots */ 3:
|
||||
message.Slots.push(Slot.internalBinaryRead(reader, reader.uint32(), options));
|
||||
break;
|
||||
case /* repeated api.WMSCommission Commissions */ 4:
|
||||
message.Commissions.push(WMSCommission.internalBinaryRead(reader, reader.uint32(), options));
|
||||
break;
|
||||
case /* string ActorID */ 5:
|
||||
message.ActorID = reader.string();
|
||||
break;
|
||||
case /* string TimeZone */ 8:
|
||||
message.TimeZone = reader.string();
|
||||
break;
|
||||
case /* repeated api.CustomField CustomFields */ 9:
|
||||
message.CustomFields.push(CustomField.internalBinaryRead(reader, reader.uint32(), options));
|
||||
break;
|
||||
default:
|
||||
let u = options.readUnknownField;
|
||||
if (u === "throw")
|
||||
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
||||
let d = reader.skip(wireType);
|
||||
if (u !== false)
|
||||
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
||||
}
|
||||
}
|
||||
return message;
|
||||
}
|
||||
internalBinaryWrite(message: WMSUpdateAppointmentRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
||||
/* api.RequestProjectHeader Header = 1; */
|
||||
if (message.Header)
|
||||
RequestProjectHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
||||
/* string AppointmentID = 2; */
|
||||
if (message.AppointmentID !== "")
|
||||
writer.tag(2, WireType.LengthDelimited).string(message.AppointmentID);
|
||||
/* repeated api.Slot Slots = 3; */
|
||||
for (let i = 0; i < message.Slots.length; i++)
|
||||
Slot.internalBinaryWrite(message.Slots[i], writer.tag(3, WireType.LengthDelimited).fork(), options).join();
|
||||
/* repeated api.WMSCommission Commissions = 4; */
|
||||
for (let i = 0; i < message.Commissions.length; i++)
|
||||
WMSCommission.internalBinaryWrite(message.Commissions[i], writer.tag(4, WireType.LengthDelimited).fork(), options).join();
|
||||
/* string ActorID = 5; */
|
||||
if (message.ActorID !== "")
|
||||
writer.tag(5, WireType.LengthDelimited).string(message.ActorID);
|
||||
/* string TimeZone = 8; */
|
||||
if (message.TimeZone !== "")
|
||||
writer.tag(8, WireType.LengthDelimited).string(message.TimeZone);
|
||||
/* repeated api.CustomField CustomFields = 9; */
|
||||
for (let i = 0; i < message.CustomFields.length; i++)
|
||||
CustomField.internalBinaryWrite(message.CustomFields[i], writer.tag(9, WireType.LengthDelimited).fork(), options).join();
|
||||
let u = options.writeUnknownFields;
|
||||
if (u !== false)
|
||||
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
||||
return writer;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* @generated MessageType for protobuf message api.WMSUpdateAppointmentRequest
|
||||
*/
|
||||
export const WMSUpdateAppointmentRequest = new WMSUpdateAppointmentRequest$Type();
|
||||
// @generated message type with reflection information, may provide speed optimized methods
|
||||
class ListUserSitesRequest$Type extends MessageType<ListUserSitesRequest> {
|
||||
constructor() {
|
||||
super("api.ListUserSitesRequest", [
|
||||
@@ -5932,6 +6066,7 @@ export const SiteService = new ServiceType("api.SiteService", [
|
||||
{ name: "UpdateAppointment", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Site"], description: "Update an appointment (slots, commissions and emails), if the requested slots are available." }, "api.rscType": "Project", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: UpdateAppointmentRequest, O: BookAppointmentResponse },
|
||||
{ name: "UpdateAppointmentNoReference", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Site"], description: "Update an appointment (slots, commissions and emails) without order references, if the requested slots are available." }, "api.rscType": "Project", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: UpdateAppointmentRequest, O: BookAppointmentResponse },
|
||||
{ name: "ForceUpdateAppointment", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Site"], description: "Update an appointment (slots, commissions and emails) even if the slots are not available." }, "api.rscType": "Project", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: UpdateAppointmentRequest, O: BookAppointmentResponse },
|
||||
{ name: "WMSUpdateAppointment", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Site"], description: "Update an appointment from a wms even if the slots are not available." }, "api.rscType": "Project", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: WMSUpdateAppointmentRequest, O: BookAppointmentResponse },
|
||||
{ name: "RescheduleAppointment", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Site"], description: "Update slot on an appointment." }, "api.rscType": "Project", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: RescheduleAppointmentRequest, O: BookAppointmentResponse },
|
||||
{ name: "ForceRescheduleAppointment", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Site"], description: "Force Update slot on an appointment." }, "api.rscType": "Project", "api.roles": "", "google.api.method_visibility": { restriction: "SDK" } }, I: RescheduleAppointmentRequest, O: BookAppointmentResponse },
|
||||
{ name: "DeleteSettings", options: { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_operation": { tags: ["Site"], description: "Delete the Site in database" }, "api.rscType": "Platform", "api.roles": "Platform.Site-Manage", "google.api.method_visibility": { restriction: "INTERNAL" } }, I: DeleteSettingsRequest, O: DeleteSettingsResult },
|
||||
|
||||
Reference in New Issue
Block a user