@chevre/domain 22.6.0-alpha.9 → 22.6.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 (210) hide show
  1. package/example/src/chevre/aggregateAllEvents2.ts +0 -19
  2. package/example/src/chevre/createEventBySchedule.ts +53 -0
  3. package/example/src/chevre/findSchedule.ts +4 -0
  4. package/example/src/chevre/findSetting.ts +75 -0
  5. package/example/src/chevre/projectEventFieldsById.ts +23 -0
  6. package/example/src/chevre/reIndex.ts +20 -0
  7. package/example/src/chevre/retryTasks.ts +6 -4
  8. package/example/src/chevre/searchAuthorizations.ts +35 -0
  9. package/example/src/chevre/unsetUnnecessaryFields.ts +34 -16
  10. package/lib/chevre/credentials.js +0 -13
  11. package/lib/chevre/emailMessageBuilder.d.ts +5 -5
  12. package/lib/chevre/emailMessageBuilder.js +20 -8
  13. package/lib/chevre/repo/action.d.ts +7 -1
  14. package/lib/chevre/repo/authorization.js +5 -1
  15. package/lib/chevre/repo/credentials.d.ts +19 -0
  16. package/lib/chevre/repo/credentials.js +70 -0
  17. package/lib/chevre/repo/event.d.ts +0 -5
  18. package/lib/chevre/repo/event.js +0 -26
  19. package/lib/chevre/repo/interface.d.ts +25 -0
  20. package/lib/chevre/repo/interface.js +62 -0
  21. package/lib/chevre/repo/mongoose/schemas/aggregateOffer.js +5 -21
  22. package/lib/chevre/repo/mongoose/schemas/authorization.js +9 -0
  23. package/lib/chevre/repo/mongoose/schemas/categoryCode.js +36 -11
  24. package/lib/chevre/repo/mongoose/schemas/civicStructure.js +9 -1
  25. package/lib/chevre/repo/mongoose/schemas/creativeWork.js +9 -1
  26. package/lib/chevre/repo/mongoose/schemas/interface.d.ts +11 -0
  27. package/lib/chevre/repo/mongoose/schemas/interface.js +55 -0
  28. package/lib/chevre/repo/mongoose/schemas/offerCatalog.d.ts +1 -1
  29. package/lib/chevre/repo/mongoose/schemas/offerCatalog.js +29 -25
  30. package/lib/chevre/repo/mongoose/schemas/offerCatalogItem.d.ts +1 -1
  31. package/lib/chevre/repo/mongoose/schemas/offerCatalogItem.js +21 -15
  32. package/lib/chevre/repo/mongoose/schemas/place.js +1 -1
  33. package/lib/chevre/repo/mongoose/schemas/reservation.d.ts +1 -1
  34. package/lib/chevre/repo/mongoose/schemas/reservation.js +25 -19
  35. package/lib/chevre/repo/mongoose/schemas/schedule.d.ts +1 -1
  36. package/lib/chevre/repo/mongoose/schemas/setting.d.ts +41 -0
  37. package/lib/chevre/repo/mongoose/schemas/setting.js +61 -0
  38. package/lib/chevre/repo/offerCatalog.d.ts +5 -1
  39. package/lib/chevre/repo/offerCatalog.js +6 -0
  40. package/lib/chevre/repo/offerCatalogItem.d.ts +5 -1
  41. package/lib/chevre/repo/offerCatalogItem.js +6 -0
  42. package/lib/chevre/repo/place/movieTheater.d.ts +0 -6
  43. package/lib/chevre/repo/place/movieTheater.js +0 -14
  44. package/lib/chevre/repo/reservation.d.ts +2 -1
  45. package/lib/chevre/repo/reservation.js +13 -3
  46. package/lib/chevre/repo/schedule.d.ts +9 -2
  47. package/lib/chevre/repo/schedule.js +19 -6
  48. package/lib/chevre/repo/setting.d.ts +50 -0
  49. package/lib/chevre/repo/setting.js +60 -0
  50. package/lib/chevre/repository.d.ts +15 -0
  51. package/lib/chevre/repository.js +41 -2
  52. package/lib/chevre/service/aggregation/event/aggregateOffers.js +44 -29
  53. package/lib/chevre/service/aggregation/event/aggregateScreeningEvent.js +10 -4
  54. package/lib/chevre/service/aggregation/event/aggregateUseActionsOnEvent.js +17 -9
  55. package/lib/chevre/service/assetTransaction/pay.d.ts +6 -1
  56. package/lib/chevre/service/assetTransaction/pay.js +9 -4
  57. package/lib/chevre/service/assetTransaction/reserve/cancel.d.ts +2 -0
  58. package/lib/chevre/service/assetTransaction/reserve/cancel.js +4 -2
  59. package/lib/chevre/service/assetTransaction/reserve/confirm.d.ts +2 -0
  60. package/lib/chevre/service/assetTransaction/reserve/confirm.js +11 -11
  61. package/lib/chevre/service/assetTransaction/reserve/exportTasksById.js +31 -39
  62. package/lib/chevre/service/assetTransaction/reserve/start/factory/createReservation.d.ts +7 -3
  63. package/lib/chevre/service/assetTransaction/reserve/start/factory/createReservation.js +3 -1
  64. package/lib/chevre/service/assetTransaction/reserve/start.d.ts +2 -0
  65. package/lib/chevre/service/assetTransaction/reserve/start.js +6 -4
  66. package/lib/chevre/service/event.d.ts +3 -2
  67. package/lib/chevre/service/event.js +7 -7
  68. package/lib/chevre/service/offer/event/authorize/processStartReserve4chevre.d.ts +2 -0
  69. package/lib/chevre/service/offer/event/authorize.d.ts +2 -0
  70. package/lib/chevre/service/offer/event/voidTransaction/processVoidTransaction4chevre.d.ts +2 -0
  71. package/lib/chevre/service/offer/event/voidTransaction.d.ts +2 -0
  72. package/lib/chevre/service/offer/event/voidTransactionByActionId.d.ts +2 -0
  73. package/lib/chevre/service/offer/onEventChanged.d.ts +3 -2
  74. package/lib/chevre/service/offer/onEventChanged.js +22 -11
  75. package/lib/chevre/service/order/onAssetTransactionStatusChanged.d.ts +3 -0
  76. package/lib/chevre/service/order/onAssetTransactionStatusChanged.js +1 -1
  77. package/lib/chevre/service/order/onOrderStatusChanged/onOrderDelivered/factory.d.ts +2 -2
  78. package/lib/chevre/service/order/onOrderStatusChanged/onOrderDelivered/factory.js +5 -2
  79. package/lib/chevre/service/order/onOrderStatusChanged/onOrderDelivered.d.ts +3 -2
  80. package/lib/chevre/service/order/onOrderStatusChanged/onOrderDelivered.js +6 -2
  81. package/lib/chevre/service/order/onOrderStatusChanged/onOrderDeliveredPartially/factory.d.ts +2 -2
  82. package/lib/chevre/service/order/onOrderStatusChanged/onOrderDeliveredPartially/factory.js +5 -2
  83. package/lib/chevre/service/order/onOrderStatusChanged/onOrderDeliveredPartially.d.ts +3 -2
  84. package/lib/chevre/service/order/onOrderStatusChanged/onOrderDeliveredPartially.js +6 -2
  85. package/lib/chevre/service/order/onOrderStatusChanged/onOrderProcessing/factory.d.ts +2 -2
  86. package/lib/chevre/service/order/onOrderStatusChanged/onOrderProcessing/factory.js +5 -2
  87. package/lib/chevre/service/order/onOrderStatusChanged/onOrderProcessing.d.ts +2 -0
  88. package/lib/chevre/service/order/onOrderStatusChanged/onOrderProcessing.js +2 -1
  89. package/lib/chevre/service/order/onOrderStatusChanged/onOrderReturned/factory.d.ts +2 -2
  90. package/lib/chevre/service/order/onOrderStatusChanged/onOrderReturned/factory.js +5 -2
  91. package/lib/chevre/service/order/onOrderStatusChanged/onOrderReturned.d.ts +3 -2
  92. package/lib/chevre/service/order/onOrderStatusChanged/onOrderReturned.js +6 -2
  93. package/lib/chevre/service/order/onOrderUpdated/factory.d.ts +2 -2
  94. package/lib/chevre/service/order/onOrderUpdated/factory.js +5 -2
  95. package/lib/chevre/service/order/onOrderUpdated.d.ts +3 -2
  96. package/lib/chevre/service/order/onOrderUpdated.js +8 -2
  97. package/lib/chevre/service/order/payOrder.d.ts +2 -0
  98. package/lib/chevre/service/order/placeOrder.d.ts +2 -0
  99. package/lib/chevre/service/order/returnOrder.d.ts +3 -2
  100. package/lib/chevre/service/order/returnOrder.js +7 -5
  101. package/lib/chevre/service/order/sendOrder.d.ts +2 -0
  102. package/lib/chevre/service/order/sendOrder.js +5 -3
  103. package/lib/chevre/service/payment/any/onRefund.js +30 -17
  104. package/lib/chevre/service/payment/any/person2username.d.ts +2 -2
  105. package/lib/chevre/service/payment/any/person2username.js +10 -2
  106. package/lib/chevre/service/payment/any/verifyTicketTokenAsNeeded.d.ts +2 -1
  107. package/lib/chevre/service/payment/any/verifyTicketTokenAsNeeded.js +26 -17
  108. package/lib/chevre/service/payment/any.d.ts +5 -1
  109. package/lib/chevre/service/payment/any.js +31 -12
  110. package/lib/chevre/service/payment/movieTicket/authorize.d.ts +6 -1
  111. package/lib/chevre/service/payment/movieTicket/authorize.js +4 -2
  112. package/lib/chevre/service/payment/movieTicket/checkMovieTicket.d.ts +2 -0
  113. package/lib/chevre/service/payment/movieTicket/checkMovieTicket.js +9 -12
  114. package/lib/chevre/service/payment/movieTicket/factory.js +12 -16
  115. package/lib/chevre/service/payment/movieTicket/payMovieTicket.d.ts +2 -0
  116. package/lib/chevre/service/payment/movieTicket/payMovieTicket.js +2 -1
  117. package/lib/chevre/service/payment/movieTicket/processPurchaseNumberAuth.d.ts +2 -0
  118. package/lib/chevre/service/payment/movieTicket/processPurchaseNumberAuth.js +2 -1
  119. package/lib/chevre/service/payment/movieTicket/refundMovieTicket.d.ts +2 -0
  120. package/lib/chevre/service/payment/movieTicket/refundMovieTicket.js +2 -1
  121. package/lib/chevre/service/payment/movieTicket/validation.d.ts +5 -1
  122. package/lib/chevre/service/payment/movieTicket/validation.js +47 -40
  123. package/lib/chevre/service/payment/movieTicket/voidTransaction.d.ts +2 -0
  124. package/lib/chevre/service/payment.d.ts +13 -4
  125. package/lib/chevre/service/payment.js +15 -11
  126. package/lib/chevre/service/reserve/cancelReservation.d.ts +5 -3
  127. package/lib/chevre/service/reserve/cancelReservation.js +8 -4
  128. package/lib/chevre/service/reserve/checkInReservation.d.ts +3 -2
  129. package/lib/chevre/service/reserve/checkInReservation.js +18 -21
  130. package/lib/chevre/service/reserve/confirmReservation.d.ts +3 -2
  131. package/lib/chevre/service/reserve/confirmReservation.js +4 -2
  132. package/lib/chevre/service/reserve/potentialActions/onPendingReservationCanceled.d.ts +3 -2
  133. package/lib/chevre/service/reserve/potentialActions/onPendingReservationCanceled.js +8 -2
  134. package/lib/chevre/service/reserve/potentialActions/onReservationCanceled.d.ts +3 -2
  135. package/lib/chevre/service/reserve/potentialActions/onReservationCanceled.js +8 -2
  136. package/lib/chevre/service/reserve/potentialActions/onReservationCheckedIn.d.ts +6 -3
  137. package/lib/chevre/service/reserve/potentialActions/onReservationCheckedIn.js +10 -9
  138. package/lib/chevre/service/reserve/potentialActions/onReservationConfirmed.d.ts +3 -2
  139. package/lib/chevre/service/reserve/potentialActions/onReservationConfirmed.js +8 -2
  140. package/lib/chevre/service/reserve/potentialActions/onReservationUsed.d.ts +7 -3
  141. package/lib/chevre/service/reserve/potentialActions/onReservationUsed.js +28 -13
  142. package/lib/chevre/service/reserve/potentialActions/onReservationsCreated.d.ts +3 -2
  143. package/lib/chevre/service/reserve/potentialActions/onReservationsCreated.js +8 -2
  144. package/lib/chevre/service/reserve/useReservation.d.ts +3 -2
  145. package/lib/chevre/service/reserve/useReservation.js +11 -7
  146. package/lib/chevre/service/task/acceptCOAOffer.d.ts +1 -1
  147. package/lib/chevre/service/task/acceptCOAOffer.js +27 -4
  148. package/lib/chevre/service/task/authorizePayment.js +9 -0
  149. package/lib/chevre/service/task/cancelPendingReservation.js +12 -14
  150. package/lib/chevre/service/task/cancelReservation.js +12 -14
  151. package/lib/chevre/service/task/checkMovieTicket.js +12 -3
  152. package/lib/chevre/service/task/confirmReserveTransaction.d.ts +3 -1
  153. package/lib/chevre/service/task/confirmReserveTransaction.js +22 -6
  154. package/lib/chevre/service/task/createEvent/createEvent.d.ts +3 -2
  155. package/lib/chevre/service/task/createEvent/createEvent.js +5 -2
  156. package/lib/chevre/service/task/createEvent/createEventBySchedule.d.ts +3 -2
  157. package/lib/chevre/service/task/createEvent/createEventBySchedule.js +185 -94
  158. package/lib/chevre/service/task/createEvent.js +6 -2
  159. package/lib/chevre/service/task/deletePerson.js +28 -10
  160. package/lib/chevre/service/task/importEventCapacitiesFromCOA.d.ts +2 -2
  161. package/lib/chevre/service/task/importEventCapacitiesFromCOA.js +14 -5
  162. package/lib/chevre/service/task/importEventsFromCOA.d.ts +2 -2
  163. package/lib/chevre/service/task/importEventsFromCOA.js +14 -5
  164. package/lib/chevre/service/task/importOffersFromCOA.d.ts +2 -2
  165. package/lib/chevre/service/task/importOffersFromCOA.js +15 -6
  166. package/lib/chevre/service/task/onAssetTransactionStatusChanged.js +2 -0
  167. package/lib/chevre/service/task/onAuthorizationCreated.js +13 -12
  168. package/lib/chevre/service/task/onEventChanged.js +6 -2
  169. package/lib/chevre/service/task/onOrderPaymentCompleted.js +2 -0
  170. package/lib/chevre/service/task/onResourceUpdated/onAggregateOfferUpdated.d.ts +3 -3
  171. package/lib/chevre/service/task/onResourceUpdated/onAggregateOfferUpdated.js +7 -3
  172. package/lib/chevre/service/task/onResourceUpdated/onHasPOSUpdated.d.ts +3 -2
  173. package/lib/chevre/service/task/onResourceUpdated/onHasPOSUpdated.js +8 -3
  174. package/lib/chevre/service/task/onResourceUpdated/onOfferCatalogUpdated.d.ts +4 -3
  175. package/lib/chevre/service/task/onResourceUpdated/onOfferCatalogUpdated.js +7 -3
  176. package/lib/chevre/service/task/onResourceUpdated/onResourceDeleted.d.ts +3 -2
  177. package/lib/chevre/service/task/onResourceUpdated/onResourceDeleted.js +7 -3
  178. package/lib/chevre/service/task/onResourceUpdated.js +61 -33
  179. package/lib/chevre/service/task/pay.js +27 -2
  180. package/lib/chevre/service/task/placeOrder.js +2 -0
  181. package/lib/chevre/service/task/refund.js +10 -0
  182. package/lib/chevre/service/task/reserve.js +6 -2
  183. package/lib/chevre/service/task/returnOrder.js +6 -2
  184. package/lib/chevre/service/task/returnReserveTransaction.d.ts +1 -1
  185. package/lib/chevre/service/task/returnReserveTransaction.js +21 -7
  186. package/lib/chevre/service/task/sendOrder.js +2 -0
  187. package/lib/chevre/service/task/useReservation.js +6 -2
  188. package/lib/chevre/service/task/voidPayment.js +14 -1
  189. package/lib/chevre/service/task/voidReserveTransaction.d.ts +1 -1
  190. package/lib/chevre/service/task/voidReserveTransaction.js +21 -6
  191. package/lib/chevre/service/task.d.ts +0 -5
  192. package/lib/chevre/service/task.js +6 -0
  193. package/lib/chevre/service/transaction/placeOrder/confirm/potentialActions/sendEmailMessage.d.ts +2 -2
  194. package/lib/chevre/service/transaction/placeOrder/confirm/potentialActions/sendEmailMessage.js +5 -2
  195. package/lib/chevre/service/transaction/placeOrder/confirm/potentialActions.d.ts +2 -2
  196. package/lib/chevre/service/transaction/placeOrder/confirm/potentialActions.js +5 -2
  197. package/lib/chevre/service/transaction/placeOrder/confirm.d.ts +3 -2
  198. package/lib/chevre/service/transaction/placeOrder/confirm.js +11 -2
  199. package/lib/chevre/service/transaction/returnOrder/potentialActions/returnPaymentMethod.d.ts +2 -2
  200. package/lib/chevre/service/transaction/returnOrder/potentialActions/returnPaymentMethod.js +14 -7
  201. package/lib/chevre/service/transaction/returnOrder/potentialActions/sendEmailMessage.d.ts +2 -2
  202. package/lib/chevre/service/transaction/returnOrder/potentialActions/sendEmailMessage.js +4 -2
  203. package/lib/chevre/service/transaction/returnOrder/potentialActions.d.ts +2 -2
  204. package/lib/chevre/service/transaction/returnOrder/potentialActions.js +6 -3
  205. package/lib/chevre/service/transaction/returnOrder.d.ts +3 -1
  206. package/lib/chevre/service/transaction/returnOrder.js +10 -2
  207. package/lib/chevre/settings.d.ts +20 -66
  208. package/lib/chevre/settings.js +21 -10
  209. package/package.json +5 -5
  210. package/example/src/chevre/searchAssetTransactions.ts +0 -38
@@ -11,35 +11,64 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
12
  exports.createEventBySchedule = void 0;
13
13
  const createDebug = require("debug");
14
+ // import * as fs from 'fs';
14
15
  const moment = require("moment-timezone");
15
16
  const factory = require("../../../factory");
17
+ // import { Settings } from '../../../settings';
16
18
  const event_1 = require("../../event");
17
19
  const debug = createDebug('chevre-domain:service:task');
18
- var RoleName;
19
- (function (RoleName) {
20
- RoleName["Customer"] = "customer";
21
- RoleName["POS"] = "pos";
22
- })(RoleName || (RoleName = {}));
23
- const AVAILABLE_ROLE_NAMES = [RoleName.Customer, RoleName.POS];
24
- function createEvents(schedule
25
- // createDate?: Date
26
- ) {
27
- // tslint:disable-next-line:max-func-body-length
28
- return (repos, settings) => __awaiter(this, void 0, void 0, function* () {
29
- var _a, _b, _c;
30
- if (typeof schedule.eventServiceProductID !== 'string' || schedule.eventServiceProductID.length === 0) {
31
- throw new factory.errors.NotFound('schedule.eventServiceProductID');
20
+ function createEvents(
21
+ // schedule: factory.schedule.ISchedule4ttts | factory.schedule.IEventWithSchedule,
22
+ schedule, createDate) {
23
+ // tslint:disable-next-line:cyclomatic-complexity max-func-body-length
24
+ return (repos
25
+ // settings: Settings
26
+ ) => __awaiter(this, void 0, void 0, function* () {
27
+ var _a, _b, _c, _d, _e, _f, _g, _h;
28
+ // console.log(moment.duration(15, 'minute').toISOString());
29
+ // return;
30
+ const eventServiceId = (_b = (_a = schedule.offers) === null || _a === void 0 ? void 0 : _a.itemOffered) === null || _b === void 0 ? void 0 : _b.id;
31
+ const makesOffer = (_d = (_c = schedule.offers) === null || _c === void 0 ? void 0 : _c.seller) === null || _d === void 0 ? void 0 : _d.makesOffer;
32
+ const applicationIds = (Array.isArray(makesOffer))
33
+ ? makesOffer.map(({ availableAtOrFrom }) => availableAtOrFrom.id)
34
+ : [];
35
+ const eventSeriesId = (_e = schedule.superEvent) === null || _e === void 0 ? void 0 : _e.id;
36
+ if (typeof eventServiceId !== 'string' || eventServiceId === '') {
37
+ throw new factory.errors.NotFound('schedule.offers.itemOffered.id');
38
+ }
39
+ if (typeof eventSeriesId !== 'string' || eventSeriesId === '') {
40
+ throw new factory.errors.NotFound('schedule.superEvent.id');
32
41
  }
33
42
  const project = schedule.project;
34
43
  // 引数情報取得
35
- const targetInfo = getTargetInfoForCreateFromSetting(schedule);
44
+ if (schedule.eventSchedule === undefined) {
45
+ throw new factory.errors.NotFound('eventSchedule');
46
+ }
47
+ const targetInfo = getTargetInfoByEventWithSchedule(schedule, createDate);
36
48
  debug(targetInfo.length, 'targetInfos ->', targetInfo);
49
+ // fs.writeFileSync(
50
+ // `${__dirname}/../../../../../targetInfo_${schedule.eventSchedule?.typeOf}.json`,
51
+ // JSON.stringify(targetInfo, null, ' ')
52
+ // );
53
+ // return;
54
+ // 施設コンテンツ検索
55
+ const screeningEventSeries = (yield repos.eventSeries.projectEventSeriesFields({
56
+ project: { id: { $eq: project.id } },
57
+ id: { $eq: eventSeriesId }
58
+ }, [
59
+ 'location', 'additionalProperty', 'description', 'endDate', 'headline', 'kanaName', 'name',
60
+ 'soundFormat', 'startDate', 'typeOf', 'videoFormat', 'workPerformed'
61
+ ])).shift();
62
+ if (screeningEventSeries === undefined) {
63
+ throw new factory.errors.NotFound(factory.eventType.ScreeningEventSeries);
64
+ }
65
+ const workPerformedIdentifier = screeningEventSeries.workPerformed.identifier;
37
66
  // 劇場検索
38
67
  const movieTheaters = yield repos.movieTheater.projectFields({
39
68
  limit: 1,
40
69
  page: 1,
41
70
  project: { id: { $eq: project.id } },
42
- branchCode: { $eq: schedule.theater }
71
+ branchCode: { $eq: screeningEventSeries.location.branchCode }
43
72
  }, ['id', 'branchCode', 'offers', 'parentOrganization']);
44
73
  const movieTheater = movieTheaters.shift();
45
74
  if (movieTheater === undefined) {
@@ -56,41 +85,38 @@ function createEvents(schedule
56
85
  if (screeningRoom === undefined) {
57
86
  throw new factory.errors.NotFound(factory.placeType.ScreeningRoom);
58
87
  }
59
- // 施設コンテンツ検索
60
- const workPerformedIdentifier = schedule.film;
61
- const screeningEventSeries = (yield repos.eventSeries.projectEventSeriesFields({
62
- project: { id: { $eq: project.id } },
63
- workPerformed: { identifiers: [workPerformedIdentifier] }
64
- }, [
65
- 'location', 'additionalProperty', 'description', 'endDate', 'headline', 'kanaName', 'name',
66
- 'soundFormat', 'startDate', 'typeOf', 'videoFormat', 'workPerformed'
67
- ])).shift();
68
- if (screeningEventSeries === undefined) {
69
- throw new factory.errors.NotFound(factory.eventType.ScreeningEventSeries);
70
- }
71
88
  // 興行検索
72
- const eventServiceProductID = schedule.eventServiceProductID; // 興行設定に変更(2023-09-24~)
89
+ // const eventServiceProductID = schedule.eventServiceProductID; // 興行設定に変更(2023-09-24~)
73
90
  const searchEventServicesResult = yield repos.product.projectFields({
74
91
  limit: 1,
75
92
  page: 1,
76
93
  project: { id: { $eq: project.id } },
77
- productID: { $eq: eventServiceProductID }
94
+ id: { $eq: eventServiceId }
95
+ // productID: { $eq: eventServiceProductID }
78
96
  }, ['name']);
79
97
  const eventService = searchEventServicesResult.shift();
80
98
  if (typeof (eventService === null || eventService === void 0 ? void 0 : eventService.id) !== 'string') {
81
- throw new Error(`EventService ${eventServiceProductID} not found`);
99
+ throw new Error(`EventService ${eventServiceId} not found`);
100
+ }
101
+ let existingApplicationMembers = [];
102
+ if (applicationIds.length > 0) {
103
+ existingApplicationMembers = (yield repos.member.projectFields({
104
+ limit: 100,
105
+ page: 1,
106
+ project: { id: { $eq: project.id } },
107
+ member: {
108
+ typeOf: {
109
+ $eq: factory.creativeWorkType.WebApplication
110
+ },
111
+ id: { $in: applicationIds }
112
+ }
113
+ }, ['member']));
82
114
  }
83
- let existingApplicationMembers = yield repos.member.projectFields({
84
- limit: 100,
85
- page: 1,
86
- project: { id: { $eq: project.id } },
87
- member: { typeOf: { $eq: factory.creativeWorkType.WebApplication } }
88
- }, ['member']);
89
115
  // ロールで絞る(customer or pos)
90
- existingApplicationMembers = existingApplicationMembers
91
- .filter((m) => {
92
- return Array.isArray(m.member.hasRole) && m.member.hasRole.some((r) => AVAILABLE_ROLE_NAMES.includes(r.roleName));
93
- });
116
+ // existingApplicationMembers = existingApplicationMembers
117
+ // .filter((m) => {
118
+ // return Array.isArray(m.member.hasRole) && m.member.hasRole.some((r) => AVAILABLE_ROLE_NAMES.includes(r.roleName));
119
+ // });
94
120
  for (const performanceInfo of targetInfo) {
95
121
  const id = [
96
122
  // tslint:disable-next-line:no-magic-numbers
@@ -100,7 +126,7 @@ function createEvents(schedule
100
126
  screeningRoom.branchCode,
101
127
  performanceInfo.start_time
102
128
  ].join('');
103
- const maxValue = (_b = (_a = movieTheater.offers) === null || _a === void 0 ? void 0 : _a.eligibleQuantity) === null || _b === void 0 ? void 0 : _b.maxValue;
129
+ const maxValue = (_g = (_f = movieTheater.offers) === null || _f === void 0 ? void 0 : _f.eligibleQuantity) === null || _g === void 0 ? void 0 : _g.maxValue;
104
130
  const availabilityEnds = moment(performanceInfo.end_date)
105
131
  .tz('Asia/Tokyo')
106
132
  .endOf('date')
@@ -155,7 +181,7 @@ function createEvents(schedule
155
181
  ? { name: screeningEventSeries.location.name }
156
182
  : undefined)
157
183
  }
158
- } }, { name: { ja: (typeof eventService.name === 'string') ? eventService.name : String((_c = eventService.name) === null || _c === void 0 ? void 0 : _c.ja) } }), seller: offersSeller }, {
184
+ } }, { name: { ja: (typeof eventService.name === 'string') ? eventService.name : String((_h = eventService.name) === null || _h === void 0 ? void 0 : _h.ja) } }), seller: offersSeller }, {
159
185
  // availabilityEnds, // discontinue(2024-10-16~)
160
186
  // availabilityStarts,
161
187
  // validThrough,
@@ -201,7 +227,9 @@ function createEvents(schedule
201
227
  attributes: eventAttributes,
202
228
  project: { id: eventAttributes.project.id },
203
229
  agent: eventAttributes.project
204
- })(repos, settings);
230
+ })(repos
231
+ // settings
232
+ );
205
233
  debug('event update(updateEvent4ttts)', id, eventAttributes.startDate);
206
234
  }
207
235
  debug(targetInfo.length, 'events updated');
@@ -210,71 +238,134 @@ function createEvents(schedule
210
238
  /**
211
239
  * パフォーマンス作成・作成対象情報取得
212
240
  */
213
- function getTargetInfoForCreateFromSetting(settings) {
241
+ // function getTargetInfoForCreateFromSetting(
242
+ // settings: factory.schedule.ISchedule4ttts,
243
+ // createDate: Date
244
+ // ): ITargetPerformanceInfo[] {
245
+ // const performanceInfos: ITargetPerformanceInfo[] = [];
246
+ // const { days, duration, noPerformanceTimes, hours, minutes, tours } = settings;
247
+ // // 本日日付+開始日までの日数から作成開始日セット
248
+ // // 作成日数分の作成対象日付作成
249
+ // for (let index = 0; index < days; index = index + 1) {
250
+ // const now = (createDate instanceof Date)
251
+ // ? moment(createDate)
252
+ // .add(index, 'days')
253
+ // : moment()
254
+ // .add(index, 'days');
255
+ // hours.forEach((hourStr) => {
256
+ // // 2桁でない時は'0'詰め
257
+ // // tslint:disable-next-line:no-magic-numbers
258
+ // const hour = `0${hourStr}`.slice(-2);
259
+ // minutes.forEach((minute, minuteIndex) => {
260
+ // // ツアー情報作成
261
+ // const tourNumber = `${hour}${tours[minuteIndex]}`;
262
+ // const startDate = moment(
263
+ // `${now.tz('Asia/Tokyo')
264
+ // .format('YYYYMMDD')} ${hour}:${minute}:00+09:00`,
265
+ // 'YYYYMMDD HH:mm:ssZ'
266
+ // );
267
+ // const endDate = moment(startDate)
268
+ // .add(duration, 'minutes');
269
+ // const day = moment(startDate)
270
+ // .tz('Asia/Tokyo')
271
+ // .format('YYYYMMDD');
272
+ // const startTime = moment(startDate)
273
+ // .tz('Asia/Tokyo')
274
+ // .format('HHmm');
275
+ // const endTime = moment(endDate)
276
+ // .tz('Asia/Tokyo')
277
+ // .format('HHmm');
278
+ // // パフォーマンスを作成しない時刻に指定されていなかったら作成
279
+ // if (noPerformanceTimes.indexOf(`${hour}${minute}`) < 0) {
280
+ // performanceInfos.push({
281
+ // day: day,
282
+ // start_time: startTime,
283
+ // end_time: endTime,
284
+ // door_time: startDate.toDate(),
285
+ // start_date: startDate.toDate(),
286
+ // end_date: endDate.toDate(),
287
+ // tour_number: tourNumber,
288
+ // duration: moment.duration(duration, 'minutes')
289
+ // .toISOString()
290
+ // });
291
+ // }
292
+ // });
293
+ // });
294
+ // }
295
+ // return performanceInfos;
296
+ // }
297
+ function getTargetInfoByEventWithSchedule(settings, createDate) {
214
298
  const performanceInfos = [];
215
- const { days, duration, noPerformanceTimes, createDate, hours, start, minutes, tours } = settings;
299
+ const { eventSchedule } = settings;
216
300
  // 作成対象時間: 9,10,11など
217
301
  // const hours: string[] = ['9', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22'];
218
- // 作成開始が今日から何日後か: 30
219
- // const start: number = 91;
220
- // 何日分作成するか: 7
221
- // const days: number = 1;
222
302
  // const minutes = ['00', '15', '30', '45'];
223
303
  // const tours = ['1', '2', '3', '4'];
224
- // 本日日付+開始日までの日数から作成開始日セット
225
- // 作成日数分の作成対象日付作成
226
- for (let index = 0; index < days; index = index + 1) {
227
- const now = (createDate instanceof Date)
228
- ? moment(createDate)
229
- .add(start + index, 'days')
230
- : moment()
231
- .add(start + index, 'days');
232
- hours.forEach((hourStr) => {
304
+ // 1日分作成する
305
+ const now = (createDate instanceof Date)
306
+ ? moment(createDate)
307
+ : moment();
308
+ let startDate = moment.tz(`${now.tz(eventSchedule.scheduleTimezone)
309
+ .format('YYYYMMDD')} ${eventSchedule.startTime}`, 'YYYYMMDD HH:mm:ss', eventSchedule.scheduleTimezone);
310
+ const startDateShouldBeLte = moment.tz(`${now.tz(eventSchedule.scheduleTimezone)
311
+ .format('YYYYMMDD')} ${eventSchedule.endTime}`, 'YYYYMMDD HH:mm:ss', eventSchedule.scheduleTimezone);
312
+ const frequencyInMinutes = moment.duration(eventSchedule.repeatFrequency)
313
+ .asMinutes();
314
+ // tslint:disable-next-line:no-magic-numbers
315
+ const repeatCountInHour = Math.floor(60 / frequencyInMinutes);
316
+ let i = 0;
317
+ while (startDate < startDateShouldBeLte) {
318
+ i += 1;
319
+ if (i > 1) {
320
+ startDate = moment(startDate)
321
+ .add(moment.duration(eventSchedule.repeatFrequency));
322
+ }
323
+ const hour = `0${moment(startDate)
324
+ .format('HH')}`
233
325
  // 2桁でない時は'0'詰め
234
326
  // tslint:disable-next-line:no-magic-numbers
235
- const hour = `0${hourStr}`.slice(-2);
236
- minutes.forEach((minute, minuteIndex) => {
237
- // ツアー情報作成
238
- const tourNumber = `${hour}${tours[minuteIndex]}`;
239
- const startDate = moment(`${now.tz('Asia/Tokyo')
240
- .format('YYYYMMDD')} ${hour}:${minute}:00+09:00`, 'YYYYMMDD HH:mm:ssZ');
241
- const endDate = moment(startDate)
242
- .add(duration, 'minutes');
243
- const day = moment(startDate)
244
- .tz('Asia/Tokyo')
245
- .format('YYYYMMDD');
246
- const startTime = moment(startDate)
247
- .tz('Asia/Tokyo')
248
- .format('HHmm');
249
- const endTime = moment(endDate)
250
- .tz('Asia/Tokyo')
251
- .format('HHmm');
252
- // パフォーマンスを作成しない時刻に指定されていなかったら作成
253
- if (noPerformanceTimes.indexOf(`${hour}${minute}`) < 0) {
254
- performanceInfos.push({
255
- day: day,
256
- start_time: startTime,
257
- end_time: endTime,
258
- door_time: startDate.toDate(),
259
- start_date: startDate.toDate(),
260
- end_date: endDate.toDate(),
261
- tour_number: tourNumber,
262
- duration: moment.duration(duration, 'minutes')
263
- .toISOString()
264
- });
265
- }
266
- });
327
+ .slice(-2);
328
+ let tourIndex = i % repeatCountInHour;
329
+ if (tourIndex === 0) {
330
+ tourIndex = repeatCountInHour;
331
+ }
332
+ const tourNumber = `${hour}${tourIndex}`;
333
+ const endDate = moment(startDate)
334
+ .add(moment.duration(eventSchedule.duration));
335
+ const day = moment(startDate)
336
+ .tz(eventSchedule.scheduleTimezone)
337
+ .format('YYYYMMDD');
338
+ const startTime = moment(startDate)
339
+ .tz(eventSchedule.scheduleTimezone)
340
+ .format('HHmm');
341
+ const endTime = moment(endDate)
342
+ .tz(eventSchedule.scheduleTimezone)
343
+ .format('HHmm');
344
+ performanceInfos.push({
345
+ day: day,
346
+ start_time: startTime,
347
+ end_time: endTime,
348
+ door_time: startDate.toDate(),
349
+ start_date: startDate.toDate(),
350
+ end_date: endDate.toDate(),
351
+ tour_number: tourNumber,
352
+ duration: eventSchedule.duration
267
353
  });
268
354
  }
269
355
  return performanceInfos;
270
356
  }
271
357
  function createEventBySchedule(params) {
272
- return (repos, settings) => __awaiter(this, void 0, void 0, function* () {
273
- const schedule = yield repos.schedule.findOne({ id: { $eq: params.object.eventSchedule.id } });
358
+ return (repos
359
+ // settings: Settings
360
+ ) => __awaiter(this, void 0, void 0, function* () {
361
+ const schedule = yield repos.schedule.findOne({
362
+ id: { $eq: params.object.eventSchedule.id },
363
+ project: { id: { $eq: params.project.id } }
364
+ });
274
365
  if (schedule === null) {
275
366
  throw new factory.errors.NotFound('Schedule');
276
367
  }
277
- yield createEvents(schedule)(repos, settings);
368
+ yield createEvents(schedule, (params.object.startDate instanceof Date) ? params.object.startDate : new Date())(repos);
278
369
  });
279
370
  }
280
371
  exports.createEventBySchedule = createEventBySchedule;
@@ -19,13 +19,14 @@ const screeningRoom_1 = require("../../repo/place/screeningRoom");
19
19
  const product_1 = require("../../repo/product");
20
20
  const project_1 = require("../../repo/project");
21
21
  const schedule_1 = require("../../repo/schedule");
22
+ const setting_1 = require("../../repo/setting");
22
23
  const task_1 = require("../../repo/task");
23
24
  const createEvent_1 = require("./createEvent/createEvent");
24
25
  /**
25
26
  * タスク実行関数
26
27
  */
27
28
  function call(data) {
28
- return ({ connection, settings }) => __awaiter(this, void 0, void 0, function* () {
29
+ return ({ connection }) => __awaiter(this, void 0, void 0, function* () {
29
30
  yield (0, createEvent_1.createEvent)(data)({
30
31
  action: new action_1.ActionRepo(connection),
31
32
  event: new event_1.EventRepo(connection),
@@ -36,8 +37,11 @@ function call(data) {
36
37
  product: new product_1.ProductRepo(connection),
37
38
  project: new project_1.ProjectRepo(connection),
38
39
  schedule: new schedule_1.ScheduleRepo(connection),
40
+ setting: new setting_1.SettingRepo(connection),
39
41
  task: new task_1.TaskRepo(connection)
40
- }, settings);
42
+ }
43
+ // settings
44
+ );
41
45
  });
42
46
  }
43
47
  exports.call = call;
@@ -12,6 +12,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
12
12
  exports.call = void 0;
13
13
  const GMO = require("@motionpicture/gmo-service");
14
14
  const factory = require("../../factory");
15
+ // import { Settings } from '../../settings';
15
16
  const person2username_1 = require("../payment/any/person2username");
16
17
  const account_1 = require("../../repo/account");
17
18
  const action_1 = require("../../repo/action");
@@ -20,6 +21,7 @@ const creditCard_1 = require("../../repo/paymentMethod/creditCard");
20
21
  const paymentService_1 = require("../../repo/paymentService");
21
22
  const person_1 = require("../../repo/person");
22
23
  const project_1 = require("../../repo/project");
24
+ const setting_1 = require("../../repo/setting");
23
25
  const task_1 = require("../../repo/task");
24
26
  const DEFAULT_PAYMENT_METHOD_TYPE_FOR_CREDIT_CARD = 'CreditCard';
25
27
  let cognitoIdentityServiceProvider;
@@ -37,12 +39,18 @@ function call(params) {
37
39
  credentials: fromEnv()
38
40
  });
39
41
  }
42
+ const settingRepo = new setting_1.SettingRepo(connection);
43
+ const setting = yield settingRepo.findOne({ project: { id: { $eq: '*' } } }, ['userPoolIdOld']);
44
+ if (typeof (setting === null || setting === void 0 ? void 0 : setting.userPoolIdOld) !== 'string') {
45
+ throw new factory.errors.NotFound('setting.userPoolIdOld');
46
+ }
40
47
  const newPersonRepo = new person_1.PersonRepo({
41
48
  userPoolId: params.data.userPoolId,
42
49
  cognitoIdentityServiceProvider
43
50
  });
44
51
  const oldPersonRepo = new person_1.PersonRepo({
45
- userPoolId: settings.userPoolIdOld,
52
+ // userPoolId: settings.userPoolIdOld,
53
+ userPoolId: setting.userPoolIdOld,
46
54
  cognitoIdentityServiceProvider
47
55
  });
48
56
  const paymentServiceRepo = new paymentService_1.PaymentServiceRepo(connection);
@@ -63,7 +71,7 @@ function call(params) {
63
71
  : 20000 // cronで実行の場合は長めに(2024-10-05~)
64
72
  })
65
73
  });
66
- yield deleteById(params.data)({
74
+ yield deleteById(params.data, setting)({
67
75
  account: new account_1.AccountRepo(connection),
68
76
  action: new action_1.ActionRepo(connection),
69
77
  creditCard: creditCardRepo,
@@ -74,16 +82,20 @@ function call(params) {
74
82
  project: new project_1.ProjectRepo(connection),
75
83
  task: new task_1.TaskRepo(connection),
76
84
  cognitoIdentityServiceProvider
77
- }, settings);
85
+ }
86
+ // settings
87
+ );
78
88
  });
79
89
  }
80
90
  exports.call = call;
81
91
  /**
82
92
  * 会員削除処理
83
93
  */
84
- function deleteById(params) {
94
+ function deleteById(params, setting) {
85
95
  // tslint:disable-next-line:max-func-body-length
86
- return (repos, settings) => __awaiter(this, void 0, void 0, function* () {
96
+ return (repos
97
+ // settings: Settings
98
+ ) => __awaiter(this, void 0, void 0, function* () {
87
99
  const deleteMemberAction = {
88
100
  agent: params.agent,
89
101
  object: Object.assign({ id: params.id, typeOf: factory.personType.Person, migrate: params.migrate, physically: params.physically }, (typeof params.migratePersonRecipientUrl === 'string')
@@ -124,11 +136,13 @@ function deleteById(params) {
124
136
  yield deleteCreditCardsById({
125
137
  id: params.id,
126
138
  useUsernameAsGMOMemberId: params.useUsernameAsGMOMemberId
127
- })({
139
+ }, setting)({
128
140
  person: repos.newPerson,
129
141
  creditCard: repos.creditCard,
130
142
  cognitoIdentityServiceProvider: repos.cognitoIdentityServiceProvider
131
- }, settings);
143
+ }
144
+ // settings
145
+ );
132
146
  }
133
147
  // 所有権削除
134
148
  // tslint:disable-next-line:no-console
@@ -361,8 +375,10 @@ function sleep(waitTime) {
361
375
  }
362
376
  const DELETE_CREDIT_CARD_MAX_RETRY_COUNT = 2;
363
377
  const DELETE_CREDIT_CARD_RETRY_INTERVAL_IN_MS = 1000;
364
- function deleteCreditCardsById(params) {
365
- return (repos, settings) => __awaiter(this, void 0, void 0, function* () {
378
+ function deleteCreditCardsById(params, setting) {
379
+ return (repos
380
+ // settings: Settings
381
+ ) => __awaiter(this, void 0, void 0, function* () {
366
382
  let retry = true;
367
383
  let numberOfTry = 0;
368
384
  while (numberOfTry >= 0) {
@@ -380,7 +396,9 @@ function deleteCreditCardsById(params) {
380
396
  const person = yield repos.person.findById({ userId: params.id });
381
397
  let oldUsername;
382
398
  try {
383
- oldUsername = yield (0, person2username_1.person2username)(person, repos.cognitoIdentityServiceProvider, settings);
399
+ oldUsername = yield (0, person2username_1.person2username)(person, repos.cognitoIdentityServiceProvider,
400
+ // settings
401
+ setting);
384
402
  }
385
403
  catch (error) {
386
404
  let throwsPerson2usernameError = true;
@@ -1,6 +1,6 @@
1
1
  import * as factory from '../../factory';
2
- import type { IOperationExecute } from '../task';
2
+ import type { ICallResult, IOperationExecute } from '../task';
3
3
  /**
4
4
  * タスク実行関数
5
5
  */
6
- export declare function call(data: factory.task.importEventCapacitiesFromCOA.IData): IOperationExecute<void>;
6
+ export declare function call(params: factory.task.importEventCapacitiesFromCOA.ITask): IOperationExecute<ICallResult>;
@@ -11,22 +11,31 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
12
  exports.call = void 0;
13
13
  const COA = require("@motionpicture/coa-service");
14
- const factory = require("../../factory");
15
14
  const event_1 = require("../../repo/event");
15
+ const interface_1 = require("../../repo/interface");
16
+ const factory = require("../../factory");
16
17
  const EventAggregationService = require("../aggregation/event");
18
+ let coaAuthClient;
17
19
  /**
18
20
  * タスク実行関数
19
21
  */
20
- function call(data) {
21
- return ({ connection, settings, coaAuthClient }) => __awaiter(this, void 0, void 0, function* () {
22
+ function call(params) {
23
+ return ({ connection, settings }) => __awaiter(this, void 0, void 0, function* () {
24
+ var _a;
22
25
  if (coaAuthClient === undefined) {
23
- throw new factory.errors.Argument('settings', 'coaAuthClient required');
26
+ const interfaceRepo = new interface_1.InterfaceRepo(connection);
27
+ const coaAPI = yield interfaceRepo.findOne({ project: { id: { $eq: params.project.id } } });
28
+ const credentials = (_a = coaAPI === null || coaAPI === void 0 ? void 0 : coaAPI.availableChannel) === null || _a === void 0 ? void 0 : _a.credentials;
29
+ if (typeof (credentials === null || credentials === void 0 ? void 0 : credentials.refreshToken) !== 'string') {
30
+ throw new factory.errors.NotFound('WebAPI');
31
+ }
32
+ coaAuthClient = new COA.auth.RefreshToken(credentials);
24
33
  }
25
34
  const reserveService = new COA.service.Reserve({
26
35
  endpoint: coaAuthClient.options.endpoint,
27
36
  auth: coaAuthClient
28
37
  }, { timeout: settings.coa.timeout });
29
- yield EventAggregationService.importFromCOA(data)({
38
+ yield EventAggregationService.importFromCOA(params.data)({
30
39
  event: new event_1.EventRepo(connection),
31
40
  reserveService
32
41
  });
@@ -1,6 +1,6 @@
1
1
  import * as factory from '../../factory';
2
- import type { IOperationExecute } from '../task';
2
+ import type { ICallResult, IOperationExecute } from '../task';
3
3
  /**
4
4
  * タスク実行関数
5
5
  */
6
- export declare function call(data: factory.task.importEventsFromCOA.IData): IOperationExecute<void>;
6
+ export declare function call(params: factory.task.importEventsFromCOA.ITask): IOperationExecute<ICallResult>;
@@ -11,29 +11,38 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
12
  exports.call = void 0;
13
13
  const COA = require("@motionpicture/coa-service");
14
- const factory = require("../../factory");
15
14
  const action_1 = require("../../repo/action");
16
15
  const categoryCode_1 = require("../../repo/categoryCode");
17
16
  const creativeWork_1 = require("../../repo/creativeWork");
18
17
  const event_1 = require("../../repo/event");
19
18
  const eventSeries_1 = require("../../repo/eventSeries");
19
+ const interface_1 = require("../../repo/interface");
20
20
  const movieTheater_1 = require("../../repo/place/movieTheater");
21
21
  const screeningRoom_1 = require("../../repo/place/screeningRoom");
22
22
  const seller_1 = require("../../repo/seller");
23
+ const factory = require("../../factory");
23
24
  const EventService = require("../event");
25
+ let coaAuthClient;
24
26
  /**
25
27
  * タスク実行関数
26
28
  */
27
- function call(data) {
28
- return ({ connection, settings, coaAuthClient }) => __awaiter(this, void 0, void 0, function* () {
29
+ function call(params) {
30
+ return ({ connection, settings }) => __awaiter(this, void 0, void 0, function* () {
31
+ var _a;
29
32
  if (coaAuthClient === undefined) {
30
- throw new factory.errors.Argument('settings', 'coaAuthClient required');
33
+ const interfaceRepo = new interface_1.InterfaceRepo(connection);
34
+ const coaAPI = yield interfaceRepo.findOne({ project: { id: { $eq: params.project.id } } });
35
+ const credentials = (_a = coaAPI === null || coaAPI === void 0 ? void 0 : coaAPI.availableChannel) === null || _a === void 0 ? void 0 : _a.credentials;
36
+ if (typeof (credentials === null || credentials === void 0 ? void 0 : credentials.refreshToken) !== 'string') {
37
+ throw new factory.errors.NotFound('WebAPI');
38
+ }
39
+ coaAuthClient = new COA.auth.RefreshToken(credentials);
31
40
  }
32
41
  const masterService = new COA.service.Master({
33
42
  endpoint: coaAuthClient.options.endpoint,
34
43
  auth: coaAuthClient
35
44
  }, { timeout: settings.coa.timeout });
36
- yield EventService.importFromCOA(data)({
45
+ yield EventService.importFromCOA(params.data)({
37
46
  action: new action_1.ActionRepo(connection),
38
47
  categoryCode: new categoryCode_1.CategoryCodeRepo(connection),
39
48
  creativeWork: new creativeWork_1.CreativeWorkRepo(connection),
@@ -1,6 +1,6 @@
1
1
  import * as factory from '../../factory';
2
- import type { IOperationExecute } from '../task';
2
+ import type { ICallResult, IOperationExecute } from '../task';
3
3
  /**
4
4
  * タスク実行関数
5
5
  */
6
- export declare function call(data: factory.task.importOffersFromCOA.IData): IOperationExecute<void>;
6
+ export declare function call(params: factory.task.importOffersFromCOA.ITask): IOperationExecute<ICallResult>;