@icure/cardinal-sdk 2.6.1 → 2.8.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.
Files changed (53) hide show
  1. package/Kotlin-DateTime-library-kotlinx-datetime.mjs +1 -1
  2. package/api/CalendarItemBasicApi.d.mts +36 -0
  3. package/api/CalendarItemBasicInGroupApi.d.mts +16 -0
  4. package/api/FilterApi.d.mts +6 -0
  5. package/api/FilterApi.mjs +1 -0
  6. package/api.d.mts +1 -0
  7. package/api.mjs +1 -0
  8. package/cardinal-sdk-ts.d.mts +1 -1
  9. package/cardinal-sdk-ts.mjs +40387 -39924
  10. package/cardinal-sdk.mjs +83203 -82225
  11. package/filters/MessageFilters.d.mts +1 -1
  12. package/filters/MessageFilters.mjs +1 -1
  13. package/kotlin-kotlin-stdlib.mjs +4 -4
  14. package/kotlinx-coroutines-core.mjs +8 -8
  15. package/model/CalendarItemOccupancy.d.mts +25 -0
  16. package/model/CalendarItemOccupancy.mjs +39 -0
  17. package/model/Document.d.mts +12 -0
  18. package/model/Document.mjs +8 -0
  19. package/model/Group.d.mts +19 -3
  20. package/model/Group.mjs +28 -3
  21. package/model/HealthElement.d.mts +12 -12
  22. package/model/HealthElement.mjs +8 -8
  23. package/model/Receipt.d.mts +24 -0
  24. package/model/Receipt.mjs +16 -0
  25. package/model/User.d.mts +3 -3
  26. package/model/User.mjs +3 -3
  27. package/model/base/CodeStub.d.mts +3 -3
  28. package/model/base/CodeStub.mjs +3 -3
  29. package/model/base/CryptoActor.mjs +2 -2
  30. package/model/base/Identifier.d.mts +5 -0
  31. package/model/base/Identifier.mjs +5 -0
  32. package/model/couchdb/DesignDocument.d.mts +0 -7
  33. package/model/couchdb/DesignDocument.mjs +0 -9
  34. package/model/couchdb/ReplicatorDocument.d.mts +0 -7
  35. package/model/couchdb/ReplicatorDocument.mjs +0 -10
  36. package/model/embed/DataAttachment.d.mts +2 -2
  37. package/model/embed/DataAttachment.mjs +2 -2
  38. package/model/embed/Medication.d.mts +85 -0
  39. package/model/embed/Medication.mjs +85 -0
  40. package/model/embed/Partnership.d.mts +8 -0
  41. package/model/embed/Partnership.mjs +8 -0
  42. package/model/embed/Service.d.mts +30 -0
  43. package/model/embed/Service.mjs +20 -0
  44. package/model/embed/form/template/Field.d.mts +1 -1
  45. package/model/embed/form/template/StructureElement.d.mts +1 -1
  46. package/model/embed/form/template/StructureElement.mjs +7 -7
  47. package/model/filter/FilterOptionGroupWithViews.d.mts +21 -0
  48. package/model/filter/FilterOptionGroupWithViews.mjs +47 -0
  49. package/model/filter/predicate/Predicate.d.mts +1 -1
  50. package/model/filter/predicate/Predicate.mjs +2 -2
  51. package/model.d.mts +2 -0
  52. package/model.mjs +2 -0
  53. package/package.json +1 -1
@@ -367,7 +367,7 @@ function addFormatStructureForDate(structure) {
367
367
  function addFormatStructureForTime(structure) {
368
368
  this.u3z(structure);
369
369
  }
370
- initMetadataForInterface(AbstractWithDateTimeBuilder, 'AbstractWithDateTimeBuilder', VOID, VOID, [AbstractWithDateBuilder, AbstractWithTimeBuilder, WithDate, WithTime]);
370
+ initMetadataForInterface(AbstractWithDateTimeBuilder, 'AbstractWithDateTimeBuilder', VOID, VOID, [AbstractWithDateBuilder, AbstractWithTimeBuilder, WithTime, WithDate]);
371
371
  initMetadataForClass(Builder_0, 'Builder', VOID, VOID, [AbstractDateTimeFormatBuilder, AbstractWithDateTimeBuilder]);
372
372
  initMetadataForClass(LocalDateTimeFormat, 'LocalDateTimeFormat', VOID, AbstractDateTimeFormat);
373
373
  function set_fractionOfSecond(value) {
@@ -1,5 +1,6 @@
1
1
  import { BaseFilterOptions, BaseSortableFilterOptions, FilterOptions, PaginatedListIterator } from '../cardinal-sdk-ts.mjs';
2
2
  import { CalendarItem, EncryptedCalendarItem } from '../model/CalendarItem.mjs';
3
+ import { CalendarItemOccupancy } from '../model/CalendarItemOccupancy.mjs';
3
4
  import { StoredDocumentIdentifier } from '../model/StoredDocumentIdentifier.mjs';
4
5
  import { EntitySubscription } from '../subscription/EntitySubscription.mjs';
5
6
  import { EntitySubscriptionConfiguration } from '../subscription/EntitySubscriptionConfiguration.mjs';
@@ -57,6 +58,41 @@ export interface CalendarItemBasicApi {
57
58
  * @return an iterator that iterates over all calendarItems matching the provided filter.
58
59
  */
59
60
  filterCalendarItemsBySorted(filter: BaseSortableFilterOptions<CalendarItem>): Promise<PaginatedListIterator<EncryptedCalendarItem>>;
61
+ /**
62
+ *
63
+ * Computes the concurrent-occupancy histogram of the calendar items for the current data owner over the
64
+ * period [startDate]..[endDate] (fuzzy date-times, either bound may be null = open).
65
+ *
66
+ * Only calendar items whose whole interval fits within the search range are considered. By default, the
67
+ * range is exactly [startDate]..[endDate], so items starting before [startDate] or ending after [endDate]
68
+ * are ignored. Pass [extensionInDays] to widen the range by that many days on each side, which lets items
69
+ * that start shortly before [startDate] (contributing to the occupancy baseline) or end shortly after
70
+ * [endDate] be taken into account. Items reaching beyond the extended range are still ignored.
71
+ */
72
+ getCalendarItemsOccupancyByPeriodForSelf(startDate: number, endDate: number, extensionInDays: number | undefined): Promise<Array<CalendarItemOccupancy>>;
73
+ /**
74
+ *
75
+ * Computes the concurrent-occupancy histogram of the calendar items of [hcPartyId] over the
76
+ * period [startDate]..[endDate] (fuzzy date-times, either bound may be null = open).
77
+ *
78
+ * Only calendar items whose whole interval fits within the search range are considered. By default, the
79
+ * range is exactly [startDate]..[endDate], so items starting before [startDate] or ending after [endDate]
80
+ * are ignored. Pass [extensionInDays] to widen the range by that many days on each side, which lets items
81
+ * that start shortly before [startDate] (contributing to the occupancy baseline) or end shortly after
82
+ * [endDate] be taken into account. Items reaching beyond the extended range are still ignored.
83
+ */
84
+ getCalendarItemsOccupancyByPeriodForHealthcareParty(startDate: number, endDate: number, hcPartyId: string, extensionInDays: number | undefined): Promise<Array<CalendarItemOccupancy>>;
85
+ /**
86
+ *
87
+ * Computes the concurrent-occupancy histogram of the calendar items of the agenda [agendaId] over the
88
+ * period [startDate]..[endDate] (fuzzy date-times, either bound may be null = open).
89
+ *
90
+ * Only calendar items whose whole interval fits within the search range are considered. By default, the range
91
+ * is exactly [startDate]..[endDate], you can pass a non-null [extensionInDays] to widen it by that many days on each side (e.g.
92
+ * to include items that start before [startDate] but are still open during the period). Items reaching beyond
93
+ * the extended range are ignored.
94
+ */
95
+ getCalendarItemsOccupancyByPeriodAndAgendaId(startDate: number, endDate: number, agendaId: string, extensionInDays: number | undefined): Promise<Array<CalendarItemOccupancy>>;
60
96
  /**
61
97
  *
62
98
  * Deletes a calendarItem. If you don't have write access to the calendarItem the method will fail.
@@ -1,5 +1,6 @@
1
1
  import { BaseFilterOptions, BaseSortableFilterOptions, PaginatedListIterator } from '../cardinal-sdk-ts.mjs';
2
2
  import { CalendarItem, EncryptedCalendarItem } from '../model/CalendarItem.mjs';
3
+ import { CalendarItemOccupancy } from '../model/CalendarItemOccupancy.mjs';
3
4
  import { GroupScoped } from '../model/GroupScoped.mjs';
4
5
  import { StoredDocumentIdentifier } from '../model/StoredDocumentIdentifier.mjs';
5
6
  export interface CalendarItemBasicInGroupApi {
@@ -23,6 +24,21 @@ export interface CalendarItemBasicInGroupApi {
23
24
  * In-group version of [CalendarItemBasicApi.filterCalendarItemsBySorted]
24
25
  */
25
26
  filterCalendarItemsBySorted(groupId: string, filter: BaseSortableFilterOptions<CalendarItem>): Promise<PaginatedListIterator<GroupScoped<EncryptedCalendarItem>>>;
27
+ /**
28
+ *
29
+ * In-group version of [getCalendarItemsOccupancyByPeriodForSelf].
30
+ */
31
+ getCalendarItemsOccupancyByPeriodForSelf(groupId: string, startDate: number, endDate: number, extensionInDays: number | undefined): Promise<Array<CalendarItemOccupancy>>;
32
+ /**
33
+ *
34
+ * In-group version of [getCalendarItemsOccupancyByPeriodForHealthcareParty].
35
+ */
36
+ getCalendarItemsOccupancyByPeriodForHealthcareParty(groupId: string, startDate: number, endDate: number, hcPartyId: string, extensionInDays: number | undefined): Promise<Array<CalendarItemOccupancy>>;
37
+ /**
38
+ *
39
+ * In-group version of [getCalendarItemsOccupancyByPeriodAndAgendaId].
40
+ */
41
+ getCalendarItemsOccupancyByPeriodAndAgendaId(groupId: string, startDate: number, endDate: number, agendaId: string, extensionInDays: number | undefined): Promise<Array<CalendarItemOccupancy>>;
26
42
  /**
27
43
  *
28
44
  * In-group version of [CalendarItemBasicFlavourlessApi.deleteCalendarItemById]
@@ -0,0 +1,6 @@
1
+ import { FilterOptionGroupWithViews } from '../model/filter/FilterOptionGroupWithViews.mjs';
2
+ export interface FilterApi {
3
+ getFilterOptionsDefinitions(): Promise<{
4
+ [key: string]: Array<FilterOptionGroupWithViews>;
5
+ }>;
6
+ }
@@ -0,0 +1 @@
1
+ export {};
package/api.d.mts CHANGED
@@ -45,6 +45,7 @@ export * from './api/HealthElementBasicInGroupApi.mjs';
45
45
  export * from './api/HealthElementInGroupApi.mjs';
46
46
  export * from './api/CalendarItemBasicInGroupApi.mjs';
47
47
  export * from './api/InvoiceFlavouredInGroupApi.mjs';
48
+ export * from './api/FilterApi.mjs';
48
49
  export * from './api/AccessLogFlavouredApi.mjs';
49
50
  export * from './api/MaintenanceTaskApi.mjs';
50
51
  export * from './api/AuthApi.mjs';
package/api.mjs CHANGED
@@ -45,6 +45,7 @@ export * from './api/HealthElementBasicInGroupApi.mjs';
45
45
  export * from './api/HealthElementInGroupApi.mjs';
46
46
  export * from './api/CalendarItemBasicInGroupApi.mjs';
47
47
  export * from './api/InvoiceFlavouredInGroupApi.mjs';
48
+ export * from './api/FilterApi.mjs';
48
49
  export * from './api/AccessLogFlavouredApi.mjs';
49
50
  export * from './api/MaintenanceTaskApi.mjs';
50
51
  export * from './api/AuthApi.mjs';
@@ -568,7 +568,7 @@ export declare namespace InternalMessageFiltersObj {
568
568
  byInvoiceIds(invoiceIds: Array<string>): BaseFilterOptions<model.Message>;
569
569
  byParentIds(parentIds: Array<string>): BaseFilterOptions<model.Message>;
570
570
  lifecycleBetweenForDataOwner(dataOwnerId: string, startTimestamp: Nullable<number>, endTimestamp: Nullable<number>, descending: boolean): BaseFilterOptions<model.Message>;
571
- lifecycleBetweenForDataOwnerInGroupInGroup(dataOwner: model.EntityReferenceInGroup, startTimestamp: Nullable<number>, endTimestamp: Nullable<number>, descending: boolean): BaseFilterOptions<model.Message>;
571
+ lifecycleBetweenForDataOwnerInGroup(dataOwner: model.EntityReferenceInGroup, startTimestamp: Nullable<number>, endTimestamp: Nullable<number>, descending: boolean): BaseFilterOptions<model.Message>;
572
572
  lifecycleBetweenForSelf(startTimestamp: Nullable<number>, endTimestamp: Nullable<number>, descending: boolean): FilterOptions<model.Message>;
573
573
  byCodeForDataOwner(dataOwnerId: string, codeType: string, options: any): BaseSortableFilterOptions<model.Message>;
574
574
  byCodeForDataOwnerInGroup(dataOwner: model.EntityReferenceInGroup, codeType: string, options: any): BaseSortableFilterOptions<model.Message>;