swoop-common 2.2.189 → 2.2.191

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.
@@ -112,9 +112,19 @@ export declare class ComponentService {
112
112
  * @throws ApiError
113
113
  */
114
114
  static componentCreditEntryAdd(componentId: ComponentId, requestBody: CreditEntry): CancelablePromise<CreditEntry>;
115
+ /**
116
+ * Update Credit Entry
117
+ * Update an existing credit entry and refresh the corresponding Google Sheet row
118
+ * @param componentId Id of a component
119
+ * @param entryId The ID of the credit entry to delete
120
+ * @param requestBody
121
+ * @returns CreditEntry Credit entry updated successfully
122
+ * @throws ApiError
123
+ */
124
+ static componentCreditEntryUpdate(componentId: ComponentId, entryId: CreditEntryId, requestBody: CreditEntry): CancelablePromise<CreditEntry>;
115
125
  /**
116
126
  * Delete Credit Entry
117
- * Soft-delete a credit entry and mark the corresponding Google Sheet row as DELETED
127
+ * Delete a credit entry and remove the corresponding Google Sheet row
118
128
  * @param componentId Id of a component
119
129
  * @param entryId The ID of the credit entry to delete
120
130
  * @returns void
@@ -257,9 +257,36 @@ export class ComponentService {
257
257
  },
258
258
  });
259
259
  }
260
+ /**
261
+ * Update Credit Entry
262
+ * Update an existing credit entry and refresh the corresponding Google Sheet row
263
+ * @param componentId Id of a component
264
+ * @param entryId The ID of the credit entry to delete
265
+ * @param requestBody
266
+ * @returns CreditEntry Credit entry updated successfully
267
+ * @throws ApiError
268
+ */
269
+ static componentCreditEntryUpdate(componentId, entryId, requestBody) {
270
+ return __request(OpenAPI, {
271
+ method: 'PUT',
272
+ url: '/component/{componentId}/credit-entries/{entryId}',
273
+ path: {
274
+ 'componentId': componentId,
275
+ 'entryId': entryId,
276
+ },
277
+ body: requestBody,
278
+ mediaType: 'application/json',
279
+ errors: {
280
+ 400: `Invalid request body`,
281
+ 401: `Unauthorized - Missing or invalid Authorization header`,
282
+ 404: `If the component or credit entry does not exist`,
283
+ 500: `Internal Server Error`,
284
+ },
285
+ });
286
+ }
260
287
  /**
261
288
  * Delete Credit Entry
262
- * Soft-delete a credit entry and mark the corresponding Google Sheet row as DELETED
289
+ * Delete a credit entry and remove the corresponding Google Sheet row
263
290
  * @param componentId Id of a component
264
291
  * @param entryId The ID of the credit entry to delete
265
292
  * @returns void
@@ -367,9 +367,19 @@ export declare class CoreService {
367
367
  * @throws ApiError
368
368
  */
369
369
  componentCreditEntryAdd(componentId: ComponentId, requestBody: CreditEntry): CancelablePromise<CreditEntry>;
370
+ /**
371
+ * Update Credit Entry
372
+ * Update an existing credit entry and refresh the corresponding Google Sheet row
373
+ * @param componentId Id of a component
374
+ * @param entryId The ID of the credit entry to delete
375
+ * @param requestBody
376
+ * @returns CreditEntry Credit entry updated successfully
377
+ * @throws ApiError
378
+ */
379
+ componentCreditEntryUpdate(componentId: ComponentId, entryId: CreditEntryId, requestBody: CreditEntry): CancelablePromise<CreditEntry>;
370
380
  /**
371
381
  * Delete Credit Entry
372
- * Soft-delete a credit entry and mark the corresponding Google Sheet row as DELETED
382
+ * Delete a credit entry and remove the corresponding Google Sheet row
373
383
  * @param componentId Id of a component
374
384
  * @param entryId The ID of the credit entry to delete
375
385
  * @returns void
@@ -835,9 +835,36 @@ export class CoreService {
835
835
  },
836
836
  });
837
837
  }
838
+ /**
839
+ * Update Credit Entry
840
+ * Update an existing credit entry and refresh the corresponding Google Sheet row
841
+ * @param componentId Id of a component
842
+ * @param entryId The ID of the credit entry to delete
843
+ * @param requestBody
844
+ * @returns CreditEntry Credit entry updated successfully
845
+ * @throws ApiError
846
+ */
847
+ componentCreditEntryUpdate(componentId, entryId, requestBody) {
848
+ return __request(OpenAPI, {
849
+ method: 'PUT',
850
+ url: '/component/{componentId}/credit-entries/{entryId}',
851
+ path: {
852
+ 'componentId': componentId,
853
+ 'entryId': entryId,
854
+ },
855
+ body: requestBody,
856
+ mediaType: 'application/json',
857
+ errors: {
858
+ 400: `Invalid request body`,
859
+ 401: `Unauthorized - Missing or invalid Authorization header`,
860
+ 404: `If the component or credit entry does not exist`,
861
+ 500: `Internal Server Error`,
862
+ },
863
+ });
864
+ }
838
865
  /**
839
866
  * Delete Credit Entry
840
- * Soft-delete a credit entry and mark the corresponding Google Sheet row as DELETED
867
+ * Delete a credit entry and remove the corresponding Google Sheet row
841
868
  * @param componentId Id of a component
842
869
  * @param entryId The ID of the credit entry to delete
843
870
  * @returns void
@@ -2,4 +2,5 @@ export type Country = {
2
2
  country_id?: number;
3
3
  title?: string;
4
4
  alias?: string;
5
+ continentCode?: string | null;
5
6
  };
@@ -3,4 +3,5 @@ export type Country_jsonld = (HydraItemBaseSchema & {
3
3
  country_id?: number;
4
4
  title?: string;
5
5
  alias?: string;
6
+ continentCode?: string | null;
6
7
  });
@@ -1,4 +1,5 @@
1
1
  import type { Address } from './Address';
2
+ import type { Country } from './Country';
2
3
  import type { EmergencyDetails } from './EmergencyDetails';
3
4
  import type { Passport } from './Passport';
4
5
  export type Customer = {
@@ -22,6 +23,7 @@ export type Customer = {
22
23
  specialOccasion?: string | null;
23
24
  roomType?: string | null;
24
25
  roomNotes?: string | null;
26
+ country?: (Country | null);
25
27
  address?: (Address | null);
26
28
  passport?: (Passport | null);
27
29
  emergencyDetails?: (EmergencyDetails | null);
@@ -1,4 +1,5 @@
1
1
  import type { Address_jsonld } from './Address_jsonld';
2
+ import type { Country_jsonld } from './Country_jsonld';
2
3
  import type { EmergencyDetails_jsonld } from './EmergencyDetails_jsonld';
3
4
  import type { HydraItemBaseSchema } from './HydraItemBaseSchema';
4
5
  import type { Passport_jsonld } from './Passport_jsonld';
@@ -23,6 +24,7 @@ export type Customer_jsonld = (HydraItemBaseSchema & {
23
24
  specialOccasion?: string | null;
24
25
  roomType?: string | null;
25
26
  roomNotes?: string | null;
27
+ country?: (Country_jsonld | null);
26
28
  address?: (Address_jsonld | null);
27
29
  passport?: (Passport_jsonld | null);
28
30
  emergencyDetails?: (EmergencyDetails_jsonld | null);
@@ -16,4 +16,5 @@ export type Enquiry = {
16
16
  bookingGroups?: Array<BookingGroup>;
17
17
  startDate?: string | null;
18
18
  bookedDate?: string | null;
19
+ enquiryRef?: string | null;
19
20
  };
@@ -17,4 +17,5 @@ export type Enquiry_jsonld = (HydraItemBaseSchema & {
17
17
  bookingGroups?: Array<BookingGroup>;
18
18
  startDate?: string | null;
19
19
  bookedDate?: string | null;
20
+ enquiryRef?: string | null;
20
21
  });
@@ -37,8 +37,10 @@ export const FormComponentPicker = ({ selectedComponent, onChange, templateIds,
37
37
  ? `${activityData.type} - ${selected.name}`
38
38
  : selected.name;
39
39
  }, [selected, selectedComponent, label]);
40
+ const aboveLabel = label + " Component";
40
41
  return (React.createElement(Paper, { component: "form", sx: { display: "flex", flexDirection: "column", gap: 1, p: 2, mb: 1 }, noValidate: true, autoComplete: "off" },
41
42
  React.createElement(Box, { sx: { position: "relative" } },
43
+ React.createElement("p", { className: "text-lg" }, aboveLabel),
42
44
  React.createElement(Button, { disabled: !enabled, onClick: () => {
43
45
  get(templateIds)
44
46
  .then((comp) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "swoop-common",
3
- "version": "2.2.189",
3
+ "version": "2.2.191",
4
4
  "main": "dist/api/index.js",
5
5
  "types": "dist/api/index.d.ts",
6
6
  "exports": {