@chevre/domain 22.3.0-alpha.2 → 22.3.0-alpha.20

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 (123) hide show
  1. package/example/src/chevre/aggregateScreeningEventMaxVersion.ts +36 -0
  2. package/example/src/chevre/aggregation/createAggregateEventTasks.ts +1 -1
  3. package/example/src/chevre/importEventsFromCOA.ts +6 -3
  4. package/example/src/chevre/migrateAccountTitleAdditionalProperties.ts +126 -0
  5. package/example/src/chevre/migrateEventSeries2secondary.ts +70 -0
  6. package/example/src/chevre/projectFields.ts +5 -15
  7. package/example/src/chevre/syncEventSeries2secondary.ts +20 -0
  8. package/example/src/chevre/unsetUnnecessaryFields.ts +6 -6
  9. package/example/src/chevre/upsertScreeningEventSeriesByVersion.ts +2 -2
  10. package/lib/chevre/repo/account.d.ts +25 -1
  11. package/lib/chevre/repo/accountTitle.d.ts +4 -4
  12. package/lib/chevre/repo/accountingReport.d.ts +25 -1
  13. package/lib/chevre/repo/action.d.ts +11 -11
  14. package/lib/chevre/repo/action.js +4 -1
  15. package/lib/chevre/repo/additionalProperty.d.ts +28 -0
  16. package/lib/chevre/repo/additionalProperty.js +6 -0
  17. package/lib/chevre/repo/aggregateOffer.d.ts +26 -2
  18. package/lib/chevre/repo/aggregateReservation.d.ts +25 -1
  19. package/lib/chevre/repo/aggregation.d.ts +26 -2
  20. package/lib/chevre/repo/assetTransaction.d.ts +5 -5
  21. package/lib/chevre/repo/authorization.d.ts +25 -1
  22. package/lib/chevre/repo/categoryCode.d.ts +1 -1
  23. package/lib/chevre/repo/comment.d.ts +3 -3
  24. package/lib/chevre/repo/creativeWork.d.ts +5 -5
  25. package/lib/chevre/repo/creativeWork.js +1 -1
  26. package/lib/chevre/repo/customer.d.ts +16 -10
  27. package/lib/chevre/repo/customer.js +40 -13
  28. package/lib/chevre/repo/event.d.ts +37 -127
  29. package/lib/chevre/repo/event.js +206 -386
  30. package/lib/chevre/repo/eventSeries.d.ts +147 -0
  31. package/lib/chevre/repo/eventSeries.js +664 -0
  32. package/lib/chevre/repo/member.d.ts +4 -4
  33. package/lib/chevre/repo/merchantReturnPolicy.d.ts +3 -3
  34. package/lib/chevre/repo/message.d.ts +25 -1
  35. package/lib/chevre/repo/mongoose/schemas/account.d.ts +1 -1
  36. package/lib/chevre/repo/mongoose/schemas/account.js +29 -13
  37. package/lib/chevre/repo/mongoose/schemas/accountTitle.js +1 -1
  38. package/lib/chevre/repo/mongoose/schemas/accountingReport.d.ts +1 -1
  39. package/lib/chevre/repo/mongoose/schemas/accountingReport.js +17 -12
  40. package/lib/chevre/repo/mongoose/schemas/additionalProperty.js +10 -12
  41. package/lib/chevre/repo/mongoose/schemas/creativeWork.d.ts +1 -1
  42. package/lib/chevre/repo/mongoose/schemas/creativeWork.js +21 -23
  43. package/lib/chevre/repo/mongoose/schemas/event.js +5 -12
  44. package/lib/chevre/repo/mongoose/schemas/eventSeries.d.ts +13 -0
  45. package/lib/chevre/repo/mongoose/schemas/eventSeries.js +219 -0
  46. package/lib/chevre/repo/mongoose/schemas/merchantReturnPolicy.d.ts +1 -1
  47. package/lib/chevre/repo/mongoose/schemas/merchantReturnPolicy.js +9 -15
  48. package/lib/chevre/repo/mongoose/schemas/offerItemCondition.d.ts +1 -1
  49. package/lib/chevre/repo/mongoose/schemas/offerItemCondition.js +21 -23
  50. package/lib/chevre/repo/mongoose/schemas/place.d.ts +1 -1
  51. package/lib/chevre/repo/mongoose/schemas/place.js +21 -23
  52. package/lib/chevre/repo/mongoose/schemas/productModel.js +6 -14
  53. package/lib/chevre/repo/mongoose/schemas/trip.js +10 -4
  54. package/lib/chevre/repo/note.d.ts +25 -1
  55. package/lib/chevre/repo/offer.d.ts +8 -8
  56. package/lib/chevre/repo/offerCatalog.d.ts +4 -4
  57. package/lib/chevre/repo/offerCatalogItem.d.ts +25 -1
  58. package/lib/chevre/repo/offerItemCondition.d.ts +28 -0
  59. package/lib/chevre/repo/offerItemCondition.js +8 -1
  60. package/lib/chevre/repo/order.d.ts +5 -5
  61. package/lib/chevre/repo/orderInTransaction.d.ts +27 -3
  62. package/lib/chevre/repo/ownershipInfo.d.ts +5 -5
  63. package/lib/chevre/repo/paymentService.d.ts +25 -1
  64. package/lib/chevre/repo/paymentServiceProvider.d.ts +26 -2
  65. package/lib/chevre/repo/place/movieTheater.d.ts +8 -4
  66. package/lib/chevre/repo/place/movieTheater.js +8 -1
  67. package/lib/chevre/repo/priceSpecification.d.ts +4 -4
  68. package/lib/chevre/repo/product.d.ts +4 -4
  69. package/lib/chevre/repo/productModel.d.ts +28 -0
  70. package/lib/chevre/repo/productModel.js +6 -0
  71. package/lib/chevre/repo/productOffer.d.ts +25 -1
  72. package/lib/chevre/repo/project.d.ts +5 -5
  73. package/lib/chevre/repo/reservation.d.ts +5 -5
  74. package/lib/chevre/repo/reservation.js +6 -28
  75. package/lib/chevre/repo/seller.d.ts +5 -5
  76. package/lib/chevre/repo/serviceOutput.d.ts +25 -1
  77. package/lib/chevre/repo/task.d.ts +8 -8
  78. package/lib/chevre/repo/transaction.d.ts +4 -4
  79. package/lib/chevre/repo/trip.d.ts +28 -0
  80. package/lib/chevre/repo/trip.js +6 -0
  81. package/lib/chevre/repository.d.ts +5 -0
  82. package/lib/chevre/repository.js +15 -2
  83. package/lib/chevre/service/aggregation/event/aggregateOffers.js +2 -2
  84. package/lib/chevre/service/aggregation/event/aggregateScreeningEvent.js +3 -3
  85. package/lib/chevre/service/aggregation/event/aggregateUseActionsOnEvent.js +1 -1
  86. package/lib/chevre/service/assetTransaction/reserve/start.d.ts +2 -0
  87. package/lib/chevre/service/assetTransaction/reserve/start.js +1 -1
  88. package/lib/chevre/service/event/createEvent.d.ts +2 -0
  89. package/lib/chevre/service/event/createEvent.js +1 -1
  90. package/lib/chevre/service/event.d.ts +6 -0
  91. package/lib/chevre/service/event.js +120 -43
  92. package/lib/chevre/service/offer/event/authorize/processStartReserve4chevre.d.ts +2 -0
  93. package/lib/chevre/service/offer/event/authorize.d.ts +2 -0
  94. package/lib/chevre/service/offer/event/searchEventTicketOffers.d.ts +3 -0
  95. package/lib/chevre/service/offer/event/searchEventTicketOffers.js +6 -6
  96. package/lib/chevre/service/offer/eventServiceByCOA/acceptOffer.js +1 -1
  97. package/lib/chevre/service/offer/eventServiceByCOA/authorize.js +1 -1
  98. package/lib/chevre/service/offer/eventServiceByCOA/changeOffers.js +1 -1
  99. package/lib/chevre/service/offer/onEventChanged.d.ts +2 -0
  100. package/lib/chevre/service/offer/onEventChanged.js +31 -4
  101. package/lib/chevre/service/offer.js +1 -1
  102. package/lib/chevre/service/payment/movieTicket/checkMovieTicket.js +1 -1
  103. package/lib/chevre/service/payment/movieTicket/factory.js +0 -6
  104. package/lib/chevre/service/payment/movieTicket/payMovieTicket.js +1 -1
  105. package/lib/chevre/service/payment/movieTicket/processPurchaseNumberAuth.js +0 -6
  106. package/lib/chevre/service/payment/movieTicket/validation.js +1 -1
  107. package/lib/chevre/service/report/telemetry.js +1 -1
  108. package/lib/chevre/service/reserve/potentialActions/onReservationCheckedIn.js +1 -1
  109. package/lib/chevre/service/task/createEvent.js +2 -0
  110. package/lib/chevre/service/task/importEventsFromCOA.js +2 -0
  111. package/lib/chevre/service/task/onEventChanged.js +2 -0
  112. package/lib/chevre/service/task/onResourceUpdated/onResourceDeleted.d.ts +2 -0
  113. package/lib/chevre/service/task/onResourceUpdated/onResourceDeleted.js +16 -7
  114. package/lib/chevre/service/task/onResourceUpdated.js +2 -0
  115. package/lib/chevre/service/transaction/returnOrder/preStart.js +1 -1
  116. package/lib/chevre/settings.d.ts +6 -0
  117. package/package.json +6 -6
  118. package/example/src/chevre/createManyEvents.ts +0 -75
  119. package/example/src/chevre/migrateMembers2.ts +0 -74
  120. package/example/src/chevre/projectEventFields.ts +0 -39
  121. package/example/src/chevre/searchAvaialbleAppliesToMovieTicketByOfferCatalogId.ts +0 -45
  122. package/example/src/chevre/searchEventIds.ts +0 -24
  123. package/example/src/chevre/searchScreeningEventSeries.ts +0 -34
@@ -26,8 +26,8 @@ import type { BulkWriteResult } from 'mongodb';
26
26
  import type { Connection, Document, FilterQuery } from 'mongoose';
27
27
  import * as factory from '../factory';
28
28
  import * as EventFactory from '../factory/event';
29
- import { IDocType } from './mongoose/schemas/event';
30
- export interface IAttributes4patchUpdate<T extends factory.eventType> {
29
+ type AvailableEventType = factory.eventType.Event | factory.eventType.ScreeningEvent;
30
+ export interface IAttributes4patchUpdate<T extends AvailableEventType> {
31
31
  typeOf: T;
32
32
  eventStatus?: factory.eventStatusType;
33
33
  }
@@ -46,7 +46,7 @@ export interface IUpdateAggregateReservationParams {
46
46
  remainingAttendeeCapacity?: '';
47
47
  };
48
48
  }
49
- export type ISearchConditions<T extends factory.eventType> = factory.event.ISearchConditions<T>;
49
+ export type ISearchConditions<T extends AvailableEventType> = factory.event.ISearchConditions<T>;
50
50
  interface IAggregationByStatus {
51
51
  eventCount: number;
52
52
  reservationCount: number;
@@ -69,13 +69,13 @@ interface IAggregateEvent {
69
69
  statuses: IStatus[];
70
70
  }
71
71
  export import IMinimizedIndividualEvent = EventFactory.IMinimizedIndividualEvent;
72
- type IKeyOfProjection<T extends factory.eventType> = Exclude<keyof factory.event.IEvent<T>, 'id'> | 'aggregateEntranceGate' | 'aggregateOffer' | 'superEvent.location.id' | 'offers.itemOffered';
72
+ type IKeyOfProjection<T extends AvailableEventType> = Exclude<keyof factory.event.IEvent<T>, 'id'> | 'aggregateEntranceGate' | 'aggregateOffer' | 'superEvent.location.id' | 'offers.itemOffered';
73
73
  /**
74
74
  * minimizedEvent検索時のprojection候補
75
75
  * add(2024-07-18~)
76
76
  */
77
- type IKeyOfProjection4minimizedEvent<T extends factory.eventType> = T extends factory.eventType.ScreeningEvent ? Exclude<keyof IMinimizedIndividualEvent<T>, 'additionalProperty' | 'id'> | 'superEvent.id' | 'location.branchCode' | 'superEvent.workPerformed.identifier' | 'superEvent.location.id' | 'offers.itemOffered' | 'offers.itemOffered.id' | 'offers.offeredThrough' | 'offers.unacceptedPaymentMethod' | 'offers.eligibleQuantity' : T extends factory.eventType.Event ? Exclude<keyof IMinimizedIndividualEvent<T>, 'additionalProperty' | 'id'> | 'superEvent.id' | 'location.branchCode' | 'superEvent.workPerformed.identifier' | 'superEvent.location.id' | 'offers.itemOffered' | 'offers.itemOffered.id' | 'offers.offeredThrough' | 'offers.unacceptedPaymentMethod' | 'offers.eligibleQuantity' : never;
78
- type IUnset<T extends factory.eventType> = {
77
+ type IKeyOfProjection4minimizedEvent<T extends AvailableEventType> = T extends factory.eventType.ScreeningEvent ? Exclude<keyof IMinimizedIndividualEvent<T>, 'additionalProperty' | 'id'> | 'superEvent.id' | 'location.branchCode' | 'superEvent.workPerformed.identifier' | 'superEvent.location.id' | 'offers.itemOffered' | 'offers.itemOffered.id' | 'offers.offeredThrough' | 'offers.unacceptedPaymentMethod' | 'offers.eligibleQuantity' : T extends factory.eventType.Event ? Exclude<keyof IMinimizedIndividualEvent<T>, 'additionalProperty' | 'id'> | 'superEvent.id' | 'location.branchCode' | 'superEvent.workPerformed.identifier' | 'superEvent.location.id' | 'offers.itemOffered' | 'offers.itemOffered.id' | 'offers.offeredThrough' | 'offers.unacceptedPaymentMethod' | 'offers.eligibleQuantity' : never;
78
+ type IUnset<T extends AvailableEventType> = {
79
79
  [key in keyof factory.event.IEvent<T>]?: 1;
80
80
  };
81
81
  /**
@@ -84,11 +84,11 @@ type IUnset<T extends factory.eventType> = {
84
84
  export declare class EventRepo {
85
85
  private readonly eventModel;
86
86
  constructor(connection: Connection);
87
- static CREATE_MONGO_CONDITIONS<T extends factory.eventType>(conditions: ISearchConditions<T>): FilterQuery<factory.event.IEvent<T>>[];
87
+ static CREATE_MONGO_CONDITIONS<T extends AvailableEventType>(conditions: ISearchConditions<T>): FilterQuery<factory.event.IEvent<T>>[];
88
88
  /**
89
89
  * 複数イベントを作成する
90
90
  */
91
- createMany<T extends factory.eventType>(params: {
91
+ createManyEvents<T extends AvailableEventType>(params: {
92
92
  attributes: factory.event.IAttributes<T>[];
93
93
  expectsNoContent: boolean;
94
94
  }): Promise<string[] | void>;
@@ -96,7 +96,7 @@ export declare class EventRepo {
96
96
  * 特定の追加特性をキーにして、存在しなければ作成する(複数対応)
97
97
  * 存在すれば、eventStatusのみ更新する
98
98
  */
99
- createManyIfNotExist<T extends factory.eventType>(params: {
99
+ createManyIfNotExist<T extends AvailableEventType>(params: {
100
100
  attributes: factory.event.IAttributes<T>;
101
101
  filter: {
102
102
  name: string;
@@ -107,28 +107,10 @@ export declare class EventRepo {
107
107
  id: string;
108
108
  }[];
109
109
  } | void>;
110
- /**
111
- * コンテンツ+バージョンをキーにして、なければ作成する(複数対応)
112
- */
113
- createScreeningEventSeriesIfNotExistByWorkPerformed(params: {
114
- attributes: factory.event.IAttributes<factory.eventType.ScreeningEventSeries>;
115
- }[]): Promise<BulkWriteResult | void>;
116
- /**
117
- * コンテンツ+バージョンをキーにして冪等置換
118
- */
119
- upsertScreeningEventSeriesByVersion(params: {
120
- $set: factory.event.IAttributes<factory.eventType.ScreeningEventSeries>;
121
- $unset?: IUnset<factory.eventType.ScreeningEventSeries>;
122
- }[]): Promise<{
123
- bulkWriteResult4insert: BulkWriteResult;
124
- modifiedEvents: {
125
- id: string;
126
- }[];
127
- } | void>;
128
110
  /**
129
111
  * イベント部分更新
130
112
  */
131
- updatePartiallyById<T extends factory.eventType>(params: {
113
+ updatePartiallyById<T extends AvailableEventType>(params: {
132
114
  project: {
133
115
  id: string;
134
116
  };
@@ -138,7 +120,7 @@ export declare class EventRepo {
138
120
  /**
139
121
  * イベントを保管する
140
122
  */
141
- save<T extends factory.eventType>(params: {
123
+ saveEvent<T extends AvailableEventType>(params: {
142
124
  id?: string;
143
125
  attributes: factory.event.IAttributes<T>;
144
126
  /**
@@ -149,7 +131,7 @@ export declare class EventRepo {
149
131
  }): Promise<{
150
132
  id: string;
151
133
  }>;
152
- saveMany<T extends factory.eventType>(params: {
134
+ saveManyEvents<T extends AvailableEventType>(params: {
153
135
  id: string;
154
136
  attributes: factory.event.IAttributes<T>;
155
137
  $unset?: IUnset<T>;
@@ -164,12 +146,12 @@ export declare class EventRepo {
164
146
  /**
165
147
  * イベントを検索する(inclusion projection)
166
148
  */
167
- projectFields<T extends factory.eventType>(params: ISearchConditions<T>, inclusion: IKeyOfProjection<T>[]): Promise<Omit<factory.event.IEvent<T>, 'aggregateEntranceGate' | 'aggregateOffer'>[]>;
149
+ projectEventFields<T extends AvailableEventType>(params: ISearchConditions<T>, inclusion: IKeyOfProjection<T>[]): Promise<Omit<factory.event.IEvent<T>, 'aggregateEntranceGate' | 'aggregateOffer'>[]>;
168
150
  /**
169
151
  * IDのみで検索する
170
152
  * projectionなし
171
153
  */
172
- findAnyEventById<T extends factory.eventType>(params: {
154
+ findAnyEventById<T extends AvailableEventType>(params: {
173
155
  id: {
174
156
  $eq: string;
175
157
  };
@@ -184,18 +166,18 @@ export declare class EventRepo {
184
166
  };
185
167
  };
186
168
  }): Promise<Omit<factory.event.IEvent<T>, 'aggregateEntranceGate' | 'aggregateOffer'>>;
187
- searchIds<T extends factory.eventType>(params: ISearchConditions<T>): Promise<string[]>;
169
+ searchEventIds<T extends AvailableEventType>(params: ISearchConditions<T>): Promise<string[]>;
188
170
  /**
189
171
  * 特定イベントから指定フィールドのみ取得する
190
172
  * イベント IDは必ず返ります
191
173
  */
192
- projectFieldsById<T extends factory.eventType.ScreeningEvent | factory.eventType.Event>(params: {
174
+ projectEventFieldsById<T extends AvailableEventType>(params: {
193
175
  id: string;
194
176
  }, inclusion: IKeyOfProjection4minimizedEvent<T>[]): Promise<IMinimizedIndividualEvent<T>>;
195
177
  /**
196
178
  * イベントをキャンセルする
197
179
  */
198
- cancel(params: {
180
+ cancelEvent(params: {
199
181
  project: {
200
182
  id: string;
201
183
  };
@@ -208,23 +190,18 @@ export declare class EventRepo {
208
190
  project: {
209
191
  id: string;
210
192
  };
211
- superEvent: {
212
- /**
213
- * 施設コンテンツID
214
- */
215
- id: string;
216
- };
193
+ superEventFromDB: Pick<factory.event.screeningEventSeries.IEvent, 'additionalProperty' | 'alternativeHeadline' | 'description' | 'dubLanguage' | 'endDate' | 'headline' | 'id' | 'kanaName' | 'location' | 'name' | 'soundFormat' | 'startDate' | 'subtitleLanguage' | 'typeOf' | 'videoFormat' | 'workPerformed'>;
217
194
  startDate: {
218
195
  $gte: Date;
219
196
  };
220
197
  }): Promise<void>;
221
- deleteById(params: {
198
+ deleteEventById(params: {
222
199
  project: {
223
200
  id: string;
224
201
  };
225
202
  id: string;
226
203
  }): Promise<void>;
227
- deleteManyByOrganizerId(params: {
204
+ deleteManyEventByOrganizerId(params: {
228
205
  project: {
229
206
  id: string;
230
207
  };
@@ -232,15 +209,7 @@ export declare class EventRepo {
232
209
  id: string;
233
210
  };
234
211
  }): Promise<import("mongodb").DeleteResult>;
235
- deleteManyByLocationId(params: {
236
- project: {
237
- id: string;
238
- };
239
- location: {
240
- id: string;
241
- };
242
- }): Promise<import("mongodb").DeleteResult>;
243
- deleteManyByScreeningRoom(params: {
212
+ deleteManyEventsByScreeningRoom(params: {
244
213
  project: {
245
214
  id: string;
246
215
  };
@@ -278,7 +247,7 @@ export declare class EventRepo {
278
247
  /**
279
248
  * 興行(プロダクト)から削除する
280
249
  */
281
- deleteManyByItemOfferedId(params: {
250
+ deleteManyEventsByItemOfferedId(params: {
282
251
  project: {
283
252
  id: string;
284
253
  };
@@ -290,21 +259,14 @@ export declare class EventRepo {
290
259
  };
291
260
  };
292
261
  }): Promise<import("mongodb").DeleteResult>;
293
- deleteManyEndedByIds(params: {
294
- typeOf: {
295
- $in: factory.eventType[];
296
- };
297
- project: {
298
- id: string;
299
- };
300
- ids: string[];
301
- endDate: {
302
- $lte: Date;
303
- };
304
- }): Promise<import("mongodb").DeleteResult>;
305
- deleteManyEndedByProject(params: {
262
+ /**
263
+ * 旧施設コンテンツ廃止専用メソッド
264
+ * 2024-09-11~
265
+ */
266
+ deleteOldEventSeries(): Promise<import("mongodb").DeleteResult>;
267
+ deleteManyEventsEndedByProject(params: {
306
268
  typeOf: {
307
- $in: factory.eventType[];
269
+ $in: AvailableEventType[];
308
270
  };
309
271
  project: {
310
272
  id: string;
@@ -313,9 +275,9 @@ export declare class EventRepo {
313
275
  $lte: Date;
314
276
  };
315
277
  }): Promise<import("mongodb").DeleteResult>;
316
- deleteManyEnded(params: {
278
+ deleteManyEventsEnded(params: {
317
279
  typeOf: {
318
- $eq: factory.eventType;
280
+ $eq: AvailableEventType;
319
281
  };
320
282
  endDate: {
321
283
  $lte: Date;
@@ -337,53 +299,35 @@ export declare class EventRepo {
337
299
  validationErrors: import("mongoose").Error[];
338
300
  } | undefined;
339
301
  }>;
340
- getCursor(conditions: FilterQuery<any>, projection: any): import("mongoose").Cursor<Document<unknown, {}, IDocType> & Omit<(import("@chevre/factory/lib/event/anyEvent").IAttributes & {
302
+ getCursor(conditions: FilterQuery<any>, projection: any): import("mongoose").Cursor<Document<unknown, {}, import("./mongoose/schemas/event").IDocType> & ((import("@chevre/factory/lib/event/anyEvent").IAttributes & {
341
303
  _id: string;
342
304
  } & Required<{
343
- /**
344
- * イベントリポジトリ
345
- */
346
305
  _id: string;
347
306
  }>) | (import("@chevre/factory/lib/event/screeningEvent").IAttributes & {
348
307
  _id: string;
349
308
  alternateName?: any;
350
309
  aggregateOffer?: import("@chevre/factory/lib/event/anyEvent").IAggregateOffer | undefined;
351
310
  } & Required<{
352
- /**
353
- * イベントリポジトリ
354
- */
355
311
  _id: string;
356
312
  }>) | (import("@chevre/factory/lib/event/screeningEventSeries").IAttributes & {
357
313
  _id: string;
358
314
  } & Required<{
359
- /**
360
- * イベントリポジトリ
361
- */
362
315
  _id: string;
363
- }>), never>, import("mongoose").QueryOptions<Document<unknown, {}, IDocType> & Omit<(import("@chevre/factory/lib/event/anyEvent").IAttributes & {
316
+ }>)), import("mongoose").QueryOptions<Document<unknown, {}, import("./mongoose/schemas/event").IDocType> & ((import("@chevre/factory/lib/event/anyEvent").IAttributes & {
364
317
  _id: string;
365
318
  } & Required<{
366
- /**
367
- * イベントリポジトリ
368
- */
369
319
  _id: string;
370
320
  }>) | (import("@chevre/factory/lib/event/screeningEvent").IAttributes & {
371
321
  _id: string;
372
322
  alternateName?: any;
373
323
  aggregateOffer?: import("@chevre/factory/lib/event/anyEvent").IAggregateOffer | undefined;
374
324
  } & Required<{
375
- /**
376
- * イベントリポジトリ
377
- */
378
325
  _id: string;
379
326
  }>) | (import("@chevre/factory/lib/event/screeningEventSeries").IAttributes & {
380
327
  _id: string;
381
328
  } & Required<{
382
- /**
383
- * イベントリポジトリ
384
- */
385
329
  _id: string;
386
- }>), never>>>;
330
+ }>))>>;
387
331
  addAvailableAtOrFrom(params: {
388
332
  id: string;
389
333
  offers: {
@@ -392,44 +336,10 @@ export declare class EventRepo {
392
336
  };
393
337
  };
394
338
  }): Promise<void>;
395
- deleteAvailableAtOrFrom(params: {
396
- id: string;
397
- offers: {
398
- seller: {
399
- makesOffer: {
400
- availableAtOrFrom: {
401
- id: string;
402
- };
403
- };
404
- };
405
- };
406
- }): Promise<void>;
407
- unsetUnnecessaryFields<T extends factory.eventType>(params: {
339
+ unsetUnnecessaryFields<T extends AvailableEventType>(params: {
408
340
  filter: FilterQuery<factory.event.IEvent<T>>;
409
341
  $unset: IUnset<T>;
410
- }): Promise<import("mongodb").UpdateResult>;
411
- /**
412
- * 既存施設コンテンツの最大バージョンを集計する
413
- */
414
- aggregateScreeningEventMaxVersion(params: {
415
- project: {
416
- id: {
417
- $eq: string;
418
- };
419
- };
420
- workPerformed: {
421
- identifier: {
422
- $eq: string;
423
- };
424
- };
425
- location: {
426
- branchCode: {
427
- $in: string[];
428
- };
429
- };
430
- }): Promise<{
431
- maxVersion: string;
432
- }>;
342
+ }): Promise<import("mongoose").UpdateWriteOpResult>;
433
343
  aggregateEvent(params: {
434
344
  project?: {
435
345
  id?: {
@@ -438,7 +348,7 @@ export declare class EventRepo {
438
348
  };
439
349
  startFrom: Date;
440
350
  startThrough: Date;
441
- typeOf: factory.eventType;
351
+ typeOf: AvailableEventType;
442
352
  }): Promise<IAggregateEvent>;
443
353
  private agggregateByStatus;
444
354
  }