You've already forked npm-core-sdk
Latest generation
This commit is contained in:
@@ -10,9 +10,10 @@ import { UnknownFieldHandler } from "@protobuf-ts/runtime";
|
||||
import type { PartialMessage } from "@protobuf-ts/runtime";
|
||||
import { reflectionMergePartial } from "@protobuf-ts/runtime";
|
||||
import { MessageType } from "@protobuf-ts/runtime";
|
||||
import { ValueType } from "./shared";
|
||||
import { CarrierInformation } from "./slotbooking";
|
||||
import { AppointmentStatusStruct } from "./collabShared";
|
||||
import { Slot } from "./slotbooking";
|
||||
import { CarrierInformation } from "./slotbooking";
|
||||
import { Segmentation } from "./slotbooking";
|
||||
import { QuantityByUnit } from "./slotbooking";
|
||||
import { Commission } from "./collabShared";
|
||||
@@ -74,9 +75,9 @@ export interface AppointmentPayload {
|
||||
/**
|
||||
* Required carrierInformation, some can be obligatory
|
||||
*
|
||||
* @generated from protobuf field: repeated api.CarrierInformation CarrierInformation = 5 [json_name = "CarrierInformation"];
|
||||
* @generated from protobuf field: repeated api.CarrierInformationWithValue CarrierInformation = 5 [json_name = "CarrierInformation"];
|
||||
*/
|
||||
CarrierInformation: CarrierInformation[];
|
||||
CarrierInformation: CarrierInformationWithValue[];
|
||||
/**
|
||||
* The slot booked for the appointment
|
||||
*
|
||||
@@ -120,6 +121,19 @@ export interface AppointmentTriplet {
|
||||
*/
|
||||
LastEvent?: Appointment;
|
||||
}
|
||||
/**
|
||||
* @generated from protobuf message api.CarrierInformationWithValue
|
||||
*/
|
||||
export interface CarrierInformationWithValue {
|
||||
/**
|
||||
* @generated from protobuf field: api.CarrierInformation CarrierInformation = 1 [json_name = "CarrierInformation"];
|
||||
*/
|
||||
CarrierInformation?: CarrierInformation;
|
||||
/**
|
||||
* @generated from protobuf field: api.ValueType Value = 2 [json_name = "Value"];
|
||||
*/
|
||||
Value?: ValueType;
|
||||
}
|
||||
// @generated message type with reflection information, may provide speed optimized methods
|
||||
class Appointment$Type extends MessageType<Appointment> {
|
||||
constructor() {
|
||||
@@ -188,7 +202,7 @@ class AppointmentPayload$Type extends MessageType<AppointmentPayload> {
|
||||
{ no: 2, name: "Commissions", kind: "message", localName: "Commissions", jsonName: "Commissions", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Commission },
|
||||
{ no: 3, name: "QuantitiesByUnits", kind: "message", localName: "QuantitiesByUnits", jsonName: "QuantitiesByUnits", repeat: 2 /*RepeatType.UNPACKED*/, T: () => QuantityByUnit },
|
||||
{ no: 4, name: "Segmentations", kind: "message", localName: "Segmentations", jsonName: "Segmentations", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Segmentation },
|
||||
{ no: 5, name: "CarrierInformation", kind: "message", localName: "CarrierInformation", jsonName: "CarrierInformation", repeat: 2 /*RepeatType.UNPACKED*/, T: () => CarrierInformation },
|
||||
{ no: 5, name: "CarrierInformation", kind: "message", localName: "CarrierInformation", jsonName: "CarrierInformation", repeat: 2 /*RepeatType.UNPACKED*/, T: () => CarrierInformationWithValue },
|
||||
{ no: 6, name: "Slot", kind: "message", localName: "Slot", jsonName: "Slot", T: () => Slot },
|
||||
{ no: 7, name: "Emails", kind: "scalar", localName: "Emails", jsonName: "Emails", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { repeated: { minItems: "1", items: { string: { email: true, ignoreEmpty: true } } } }, "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "Must be a valid email address", example: "[\"John.doe@reflex.com\", \"will.smith@reflex.com\"]" } } },
|
||||
{ no: 8, name: "Status", kind: "message", localName: "Status", jsonName: "Status", T: () => AppointmentStatusStruct, options: { "api.aggSkip": "StatusUpdated", "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_field": { description: "Status of the appointment" } } },
|
||||
@@ -225,8 +239,8 @@ class AppointmentPayload$Type extends MessageType<AppointmentPayload> {
|
||||
case /* repeated api.Segmentation Segmentations = 4 [json_name = "Segmentations"];*/ 4:
|
||||
message.Segmentations.push(Segmentation.internalBinaryRead(reader, reader.uint32(), options));
|
||||
break;
|
||||
case /* repeated api.CarrierInformation CarrierInformation = 5 [json_name = "CarrierInformation"];*/ 5:
|
||||
message.CarrierInformation.push(CarrierInformation.internalBinaryRead(reader, reader.uint32(), options));
|
||||
case /* repeated api.CarrierInformationWithValue CarrierInformation = 5 [json_name = "CarrierInformation"];*/ 5:
|
||||
message.CarrierInformation.push(CarrierInformationWithValue.internalBinaryRead(reader, reader.uint32(), options));
|
||||
break;
|
||||
case /* api.Slot Slot = 6 [json_name = "Slot"];*/ 6:
|
||||
message.Slot = Slot.internalBinaryRead(reader, reader.uint32(), options, message.Slot);
|
||||
@@ -264,9 +278,9 @@ class AppointmentPayload$Type extends MessageType<AppointmentPayload> {
|
||||
/* repeated api.Segmentation Segmentations = 4 [json_name = "Segmentations"]; */
|
||||
for (let i = 0; i < message.Segmentations.length; i++)
|
||||
Segmentation.internalBinaryWrite(message.Segmentations[i], writer.tag(4, WireType.LengthDelimited).fork(), options).join();
|
||||
/* repeated api.CarrierInformation CarrierInformation = 5 [json_name = "CarrierInformation"]; */
|
||||
/* repeated api.CarrierInformationWithValue CarrierInformation = 5 [json_name = "CarrierInformation"]; */
|
||||
for (let i = 0; i < message.CarrierInformation.length; i++)
|
||||
CarrierInformation.internalBinaryWrite(message.CarrierInformation[i], writer.tag(5, WireType.LengthDelimited).fork(), options).join();
|
||||
CarrierInformationWithValue.internalBinaryWrite(message.CarrierInformation[i], writer.tag(5, WireType.LengthDelimited).fork(), options).join();
|
||||
/* api.Slot Slot = 6 [json_name = "Slot"]; */
|
||||
if (message.Slot)
|
||||
Slot.internalBinaryWrite(message.Slot, writer.tag(6, WireType.LengthDelimited).fork(), options).join();
|
||||
@@ -349,3 +363,56 @@ class AppointmentTriplet$Type extends MessageType<AppointmentTriplet> {
|
||||
* @generated MessageType for protobuf message api.AppointmentTriplet
|
||||
*/
|
||||
export const AppointmentTriplet = new AppointmentTriplet$Type();
|
||||
// @generated message type with reflection information, may provide speed optimized methods
|
||||
class CarrierInformationWithValue$Type extends MessageType<CarrierInformationWithValue> {
|
||||
constructor() {
|
||||
super("api.CarrierInformationWithValue", [
|
||||
{ no: 1, name: "CarrierInformation", kind: "message", localName: "CarrierInformation", jsonName: "CarrierInformation", T: () => CarrierInformation },
|
||||
{ no: 2, name: "Value", kind: "message", localName: "Value", jsonName: "Value", T: () => ValueType }
|
||||
]);
|
||||
}
|
||||
create(value?: PartialMessage<CarrierInformationWithValue>): CarrierInformationWithValue {
|
||||
const message = globalThis.Object.create((this.messagePrototype!));
|
||||
if (value !== undefined)
|
||||
reflectionMergePartial<CarrierInformationWithValue>(this, message, value);
|
||||
return message;
|
||||
}
|
||||
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: CarrierInformationWithValue): CarrierInformationWithValue {
|
||||
let message = target ?? this.create(), end = reader.pos + length;
|
||||
while (reader.pos < end) {
|
||||
let [fieldNo, wireType] = reader.tag();
|
||||
switch (fieldNo) {
|
||||
case /* api.CarrierInformation CarrierInformation = 1 [json_name = "CarrierInformation"];*/ 1:
|
||||
message.CarrierInformation = CarrierInformation.internalBinaryRead(reader, reader.uint32(), options, message.CarrierInformation);
|
||||
break;
|
||||
case /* api.ValueType Value = 2 [json_name = "Value"];*/ 2:
|
||||
message.Value = ValueType.internalBinaryRead(reader, reader.uint32(), options, message.Value);
|
||||
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: CarrierInformationWithValue, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
||||
/* api.CarrierInformation CarrierInformation = 1 [json_name = "CarrierInformation"]; */
|
||||
if (message.CarrierInformation)
|
||||
CarrierInformation.internalBinaryWrite(message.CarrierInformation, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
||||
/* api.ValueType Value = 2 [json_name = "Value"]; */
|
||||
if (message.Value)
|
||||
ValueType.internalBinaryWrite(message.Value, writer.tag(2, 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.CarrierInformationWithValue
|
||||
*/
|
||||
export const CarrierInformationWithValue = new CarrierInformationWithValue$Type();
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@reflex-platform/npm-core-sdk",
|
||||
"version": "1.11.0-SNAPSHOT-250522075043",
|
||||
"version": "1.11.0-SNAPSHOT-250522125341",
|
||||
"description": "npm libs from core model proto files",
|
||||
"homepage": "",
|
||||
"main": "index.ts",
|
||||
|
||||
30
site.ts
30
site.ts
@@ -85,7 +85,7 @@ export interface Site {
|
||||
*
|
||||
* @generated from protobuf field: repeated api.Unit Units = 11 [json_name = "Units"];
|
||||
*/
|
||||
Units: Unit[];
|
||||
Units: Unit[]; // après le champs
|
||||
/**
|
||||
* Definition of the opening rules. 2 opening rule definitions cannot overlap.
|
||||
*
|
||||
@@ -192,13 +192,9 @@ export interface CreateSiteResponse {
|
||||
*/
|
||||
export interface GetSiteRequest {
|
||||
/**
|
||||
* @generated from protobuf field: api.RequestOrganisationHeader Header = 1 [json_name = "Header"];
|
||||
* @generated from protobuf field: api.RequestSiteHeader Header = 1 [json_name = "Header"];
|
||||
*/
|
||||
Header?: RequestOrganisationHeader;
|
||||
/**
|
||||
* @generated from protobuf field: string ID = 2 [json_name = "ID"];
|
||||
*/
|
||||
ID: string;
|
||||
Header?: RequestSiteHeader;
|
||||
}
|
||||
/**
|
||||
* @generated from protobuf message api.GetSiteResponse
|
||||
@@ -880,13 +876,11 @@ export const CreateSiteResponse = new CreateSiteResponse$Type();
|
||||
class GetSiteRequest$Type extends MessageType<GetSiteRequest> {
|
||||
constructor() {
|
||||
super("api.GetSiteRequest", [
|
||||
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestOrganisationHeader, options: { "validate.rules": { message: { required: true } } } },
|
||||
{ no: 2, name: "ID", kind: "scalar", localName: "ID", jsonName: "ID", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "1" } } } }
|
||||
], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header", "ID"] } } });
|
||||
{ no: 1, name: "Header", kind: "message", localName: "Header", jsonName: "Header", T: () => RequestSiteHeader, options: { "validate.rules": { message: { required: true } } } }
|
||||
], { "grpc.gateway.protoc_gen_openapiv2.options.openapiv2_schema": { jsonSchema: { required: ["Header"] } } });
|
||||
}
|
||||
create(value?: PartialMessage<GetSiteRequest>): GetSiteRequest {
|
||||
const message = globalThis.Object.create((this.messagePrototype!));
|
||||
message.ID = "";
|
||||
if (value !== undefined)
|
||||
reflectionMergePartial<GetSiteRequest>(this, message, value);
|
||||
return message;
|
||||
@@ -896,11 +890,8 @@ class GetSiteRequest$Type extends MessageType<GetSiteRequest> {
|
||||
while (reader.pos < end) {
|
||||
let [fieldNo, wireType] = reader.tag();
|
||||
switch (fieldNo) {
|
||||
case /* api.RequestOrganisationHeader Header = 1 [json_name = "Header"];*/ 1:
|
||||
message.Header = RequestOrganisationHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
||||
break;
|
||||
case /* string ID = 2 [json_name = "ID"];*/ 2:
|
||||
message.ID = reader.string();
|
||||
case /* api.RequestSiteHeader Header = 1 [json_name = "Header"];*/ 1:
|
||||
message.Header = RequestSiteHeader.internalBinaryRead(reader, reader.uint32(), options, message.Header);
|
||||
break;
|
||||
default:
|
||||
let u = options.readUnknownField;
|
||||
@@ -914,12 +905,9 @@ class GetSiteRequest$Type extends MessageType<GetSiteRequest> {
|
||||
return message;
|
||||
}
|
||||
internalBinaryWrite(message: GetSiteRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
|
||||
/* api.RequestOrganisationHeader Header = 1 [json_name = "Header"]; */
|
||||
/* api.RequestSiteHeader Header = 1 [json_name = "Header"]; */
|
||||
if (message.Header)
|
||||
RequestOrganisationHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
||||
/* string ID = 2 [json_name = "ID"]; */
|
||||
if (message.ID !== "")
|
||||
writer.tag(2, WireType.LengthDelimited).string(message.ID);
|
||||
RequestSiteHeader.internalBinaryWrite(message.Header, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
||||
let u = options.writeUnknownFields;
|
||||
if (u !== false)
|
||||
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
||||
|
||||
@@ -14,6 +14,8 @@ import { TimeRange } from "./shared";
|
||||
import { WeekDay } from "./shared";
|
||||
import { LabelByLanguage } from "./shared";
|
||||
/**
|
||||
* avant la def de la sous structure
|
||||
*
|
||||
* @generated from protobuf message api.Unit
|
||||
*/
|
||||
export interface Unit {
|
||||
|
||||
Reference in New Issue
Block a user