@chevre/domain 24.0.0-alpha.40 → 24.0.0-alpha.41

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 (228) hide show
  1. package/lib/chevre/repo/accountTitle.d.ts +3 -3
  2. package/lib/chevre/repo/action/pay.d.ts +9 -0
  3. package/lib/chevre/repo/action/pay.js +13 -0
  4. package/lib/chevre/repo/action/refund.d.ts +9 -0
  5. package/lib/chevre/repo/action/refund.js +13 -0
  6. package/lib/chevre/repo/action.d.ts +3 -3
  7. package/lib/chevre/repo/additionalProperty.js +2 -2
  8. package/lib/chevre/repo/advanceBookingRequirement.d.ts +1 -3
  9. package/lib/chevre/repo/advanceBookingRequirement.js +2 -2
  10. package/lib/chevre/repo/aggregateOffer.d.ts +5 -9
  11. package/lib/chevre/repo/aggregateOffer.js +3 -3
  12. package/lib/chevre/repo/assetTransaction.d.ts +3 -3
  13. package/lib/chevre/repo/assetTransaction.js +12 -6
  14. package/lib/chevre/repo/categoryCode.d.ts +4 -6
  15. package/lib/chevre/repo/categoryCode.js +2 -2
  16. package/lib/chevre/repo/comment.d.ts +3 -3
  17. package/lib/chevre/repo/creativeWork.d.ts +3 -3
  18. package/lib/chevre/repo/creativeWork.js +3 -3
  19. package/lib/chevre/repo/customer.d.ts +3 -3
  20. package/lib/chevre/repo/customer.js +2 -2
  21. package/lib/chevre/repo/emailMessage.js +1 -1
  22. package/lib/chevre/repo/event.d.ts +6 -6
  23. package/lib/chevre/repo/event.js +10 -4
  24. package/lib/chevre/repo/eventSeries.d.ts +6 -6
  25. package/lib/chevre/repo/eventSeries.js +2 -2
  26. package/lib/chevre/repo/identity.d.ts +4 -6
  27. package/lib/chevre/repo/identityProvider.d.ts +4 -6
  28. package/lib/chevre/repo/identityProvider.js +2 -2
  29. package/lib/chevre/repo/issuer.d.ts +3 -3
  30. package/lib/chevre/repo/issuer.js +3 -3
  31. package/lib/chevre/repo/member.d.ts +3 -3
  32. package/lib/chevre/repo/merchantReturnPolicy.d.ts +3 -3
  33. package/lib/chevre/repo/merchantReturnPolicy.js +1 -1
  34. package/lib/chevre/repo/mongoose/schemas/acceptedPaymentMethod.d.ts +2 -2
  35. package/lib/chevre/repo/mongoose/schemas/account.d.ts +2 -2
  36. package/lib/chevre/repo/mongoose/schemas/accountTitle.d.ts +2 -2
  37. package/lib/chevre/repo/mongoose/schemas/accountTransaction.d.ts +2 -2
  38. package/lib/chevre/repo/mongoose/schemas/accountingReport.d.ts +2 -2
  39. package/lib/chevre/repo/mongoose/schemas/action.d.ts +2 -2
  40. package/lib/chevre/repo/mongoose/schemas/actionRecipe.d.ts +2 -2
  41. package/lib/chevre/repo/mongoose/schemas/additionalProperty.d.ts +2 -2
  42. package/lib/chevre/repo/mongoose/schemas/advanceBookingRequirement.d.ts +2 -2
  43. package/lib/chevre/repo/mongoose/schemas/aggregateOffer.d.ts +2 -2
  44. package/lib/chevre/repo/mongoose/schemas/aggregateOrder.d.ts +2 -2
  45. package/lib/chevre/repo/mongoose/schemas/aggregateReservation.d.ts +2 -2
  46. package/lib/chevre/repo/mongoose/schemas/aggregation.d.ts +2 -2
  47. package/lib/chevre/repo/mongoose/schemas/assetTransaction.d.ts +2 -2
  48. package/lib/chevre/repo/mongoose/schemas/authorization.d.ts +2 -2
  49. package/lib/chevre/repo/mongoose/schemas/categoryCode.d.ts +2 -2
  50. package/lib/chevre/repo/mongoose/schemas/civicStructure.d.ts +2 -2
  51. package/lib/chevre/repo/mongoose/schemas/comments.d.ts +2 -2
  52. package/lib/chevre/repo/mongoose/schemas/creativeWork.d.ts +2 -2
  53. package/lib/chevre/repo/mongoose/schemas/customer.d.ts +2 -2
  54. package/lib/chevre/repo/mongoose/schemas/customerType.d.ts +2 -2
  55. package/lib/chevre/repo/mongoose/schemas/emailMessages.d.ts +2 -2
  56. package/lib/chevre/repo/mongoose/schemas/event.d.ts +2 -2
  57. package/lib/chevre/repo/mongoose/schemas/eventOffer.d.ts +2 -2
  58. package/lib/chevre/repo/mongoose/schemas/eventSeries.d.ts +2 -2
  59. package/lib/chevre/repo/mongoose/schemas/identity.d.ts +2 -2
  60. package/lib/chevre/repo/mongoose/schemas/identityProvider.d.ts +2 -2
  61. package/lib/chevre/repo/mongoose/schemas/issuer.d.ts +2 -2
  62. package/lib/chevre/repo/mongoose/schemas/member/global.d.ts +2 -2
  63. package/lib/chevre/repo/mongoose/schemas/member.d.ts +2 -2
  64. package/lib/chevre/repo/mongoose/schemas/merchantReturnPolicy.d.ts +2 -2
  65. package/lib/chevre/repo/mongoose/schemas/message.d.ts +2 -2
  66. package/lib/chevre/repo/mongoose/schemas/movieTicketTypes.d.ts +2 -2
  67. package/lib/chevre/repo/mongoose/schemas/note.d.ts +2 -2
  68. package/lib/chevre/repo/mongoose/schemas/offerCatalog.d.ts +2 -2
  69. package/lib/chevre/repo/mongoose/schemas/offerCatalogItem.d.ts +2 -2
  70. package/lib/chevre/repo/mongoose/schemas/offerItemCondition.d.ts +2 -2
  71. package/lib/chevre/repo/mongoose/schemas/order.d.ts +2 -2
  72. package/lib/chevre/repo/mongoose/schemas/ownershipInfo.d.ts +2 -2
  73. package/lib/chevre/repo/mongoose/schemas/paymentService.d.ts +2 -2
  74. package/lib/chevre/repo/mongoose/schemas/paymentServiceChannel.d.ts +2 -2
  75. package/lib/chevre/repo/mongoose/schemas/pendingReservation.d.ts +2 -2
  76. package/lib/chevre/repo/mongoose/schemas/pendingReservationAggregate.d.ts +2 -2
  77. package/lib/chevre/repo/mongoose/schemas/place.d.ts +2 -2
  78. package/lib/chevre/repo/mongoose/schemas/potentialAction.d.ts +2 -2
  79. package/lib/chevre/repo/mongoose/schemas/priceSpecification.d.ts +2 -2
  80. package/lib/chevre/repo/mongoose/schemas/product.d.ts +2 -2
  81. package/lib/chevre/repo/mongoose/schemas/productModel.d.ts +2 -2
  82. package/lib/chevre/repo/mongoose/schemas/productOffer.d.ts +2 -2
  83. package/lib/chevre/repo/mongoose/schemas/project.d.ts +2 -2
  84. package/lib/chevre/repo/mongoose/schemas/reservation.d.ts +2 -2
  85. package/lib/chevre/repo/mongoose/schemas/reserveInterface.d.ts +2 -2
  86. package/lib/chevre/repo/mongoose/schemas/role.d.ts +2 -2
  87. package/lib/chevre/repo/mongoose/schemas/schedule.d.ts +2 -2
  88. package/lib/chevre/repo/mongoose/schemas/seller.d.ts +2 -2
  89. package/lib/chevre/repo/mongoose/schemas/sellerReturnPolicy.d.ts +2 -2
  90. package/lib/chevre/repo/mongoose/schemas/service/availableHour.d.ts +2 -2
  91. package/lib/chevre/repo/mongoose/schemas/serviceOutput.d.ts +2 -2
  92. package/lib/chevre/repo/mongoose/schemas/setting.d.ts +2 -2
  93. package/lib/chevre/repo/mongoose/schemas/task.d.ts +2 -2
  94. package/lib/chevre/repo/mongoose/schemas/ticket.d.ts +2 -2
  95. package/lib/chevre/repo/mongoose/schemas/transaction.d.ts +2 -2
  96. package/lib/chevre/repo/mongoose/schemas/transactionNumber.d.ts +2 -2
  97. package/lib/chevre/repo/mongoose/schemas/trip.d.ts +2 -2
  98. package/lib/chevre/repo/mongoose/schemas/webSite.d.ts +2 -2
  99. package/lib/chevre/repo/movieTicketType.d.ts +1 -3
  100. package/lib/chevre/repo/movieTicketType.js +2 -2
  101. package/lib/chevre/repo/offer/offerInCatalogReadOnly.d.ts +1 -3
  102. package/lib/chevre/repo/offer/unitPriceInCatalog.d.ts +1 -3
  103. package/lib/chevre/repo/offerCatalog.d.ts +3 -3
  104. package/lib/chevre/repo/offerCatalog.js +5 -4
  105. package/lib/chevre/repo/offerCatalogItem.js +4 -4
  106. package/lib/chevre/repo/offerItemCondition.js +2 -2
  107. package/lib/chevre/repo/order.d.ts +3 -3
  108. package/lib/chevre/repo/ownershipInfo.d.ts +3 -3
  109. package/lib/chevre/repo/passport.js +1 -1
  110. package/lib/chevre/repo/paymentService.d.ts +1 -3
  111. package/lib/chevre/repo/paymentService.js +2 -2
  112. package/lib/chevre/repo/paymentServiceChannel.d.ts +1 -3
  113. package/lib/chevre/repo/paymentServiceChannel.js +2 -2
  114. package/lib/chevre/repo/person.js +2 -2
  115. package/lib/chevre/repo/place/busStop.js +1 -1
  116. package/lib/chevre/repo/place/movieTheater.d.ts +3 -3
  117. package/lib/chevre/repo/place/movieTheater.js +10 -4
  118. package/lib/chevre/repo/place/screeningRoom.d.ts +3 -3
  119. package/lib/chevre/repo/place/screeningRoom.js +2 -2
  120. package/lib/chevre/repo/place/seat.d.ts +2 -4
  121. package/lib/chevre/repo/potentialAction.d.ts +4 -6
  122. package/lib/chevre/repo/potentialAction.js +2 -2
  123. package/lib/chevre/repo/priceSpecification.d.ts +3 -3
  124. package/lib/chevre/repo/priceSpecification.js +2 -2
  125. package/lib/chevre/repo/product.d.ts +5 -9
  126. package/lib/chevre/repo/product.js +3 -3
  127. package/lib/chevre/repo/productModel.js +2 -2
  128. package/lib/chevre/repo/project.d.ts +3 -3
  129. package/lib/chevre/repo/rateLimit/offer.js +1 -1
  130. package/lib/chevre/repo/reservation.d.ts +4 -6
  131. package/lib/chevre/repo/seller.d.ts +5 -9
  132. package/lib/chevre/repo/seller.js +2 -2
  133. package/lib/chevre/repo/sellerReturnPolicy.d.ts +1 -3
  134. package/lib/chevre/repo/sellerReturnPolicy.js +2 -2
  135. package/lib/chevre/repo/task.d.ts +3 -3
  136. package/lib/chevre/repo/task.js +1 -1
  137. package/lib/chevre/repo/transaction.d.ts +3 -3
  138. package/lib/chevre/repo/transactionProcess.js +1 -1
  139. package/lib/chevre/repo/trip.d.ts +4 -12
  140. package/lib/chevre/repo/trip.js +3 -3
  141. package/lib/chevre/repo/webSite.d.ts +1 -3
  142. package/lib/chevre/repo/webSite.js +3 -2
  143. package/lib/chevre/repository.d.ts +10 -0
  144. package/lib/chevre/repository.js +22 -0
  145. package/lib/chevre/service/assetTransaction/moneyTransfer.js +8 -5
  146. package/lib/chevre/service/assetTransaction/pay/confirm.d.ts +1 -1
  147. package/lib/chevre/service/assetTransaction/pay/exportTasksById.js +2 -1
  148. package/lib/chevre/service/assetTransaction/pay/publishPaymentUrl.js +2 -1
  149. package/lib/chevre/service/assetTransaction/pay/start/factory.js +2 -1
  150. package/lib/chevre/service/assetTransaction/pay/start/processAuthorize.d.ts +6 -0
  151. package/lib/chevre/service/assetTransaction/pay/start/processAuthorizeMovieTicket.d.ts +6 -0
  152. package/lib/chevre/service/assetTransaction/pay/start.d.ts +6 -0
  153. package/lib/chevre/service/assetTransaction/reserve/start/createSubReservations.js +6 -3
  154. package/lib/chevre/service/delivery/factory.js +2 -1
  155. package/lib/chevre/service/event/saveScreeningEvents.js +2 -2
  156. package/lib/chevre/service/event.js +1 -1
  157. package/lib/chevre/service/notification/notifyByEmail.d.ts +1 -1
  158. package/lib/chevre/service/notification/triggerWebhook.js +1 -1
  159. package/lib/chevre/service/offer/event/authorize.js +2 -1
  160. package/lib/chevre/service/offer/event/searchEventTicketOffers.js +2 -1
  161. package/lib/chevre/service/offer/event/searchOffersByIds.js +2 -1
  162. package/lib/chevre/service/offer/event/voidTransaction.js +6 -3
  163. package/lib/chevre/service/offer/event/voidTransactionByActionId.js +2 -1
  164. package/lib/chevre/service/offer/eventServiceByCOA/authorize.d.ts +1 -1
  165. package/lib/chevre/service/offer/eventServiceByCOA/changeOffers.d.ts +1 -1
  166. package/lib/chevre/service/offer/eventServiceByCOA/findAcceptAction.js +2 -1
  167. package/lib/chevre/service/offer/product.js +1 -1
  168. package/lib/chevre/service/order/confirmPayTransaction.d.ts +1 -1
  169. package/lib/chevre/service/order/onAssetTransactionStatusChanged.js +2 -1
  170. package/lib/chevre/service/order/onOrderStatusChanged/onOrderReturned.js +4 -2
  171. package/lib/chevre/service/payment/any/authorize.d.ts +6 -0
  172. package/lib/chevre/service/payment/any/findAcceptAction.js +2 -1
  173. package/lib/chevre/service/payment/any/findAuthorizeAction.js +2 -1
  174. package/lib/chevre/service/payment/any/findCheckAction.js +2 -1
  175. package/lib/chevre/service/payment/any/invalidatePaymentUrl.js +2 -1
  176. package/lib/chevre/service/payment/any/onPayActionCompleted.d.ts +6 -2
  177. package/lib/chevre/service/payment/any/onPayActionCompleted.js +7 -2
  178. package/lib/chevre/service/payment/any/onPaymentStatusChanged.d.ts +10 -5
  179. package/lib/chevre/service/payment/any/onPaymentStatusChanged.js +21 -11
  180. package/lib/chevre/service/payment/any/onRefundActionCompletedOrFailed.d.ts +12 -10
  181. package/lib/chevre/service/payment/any/onRefundActionCompletedOrFailed.js +9 -6
  182. package/lib/chevre/service/payment/any/processVoidPayTransaction.js +2 -1
  183. package/lib/chevre/service/payment/any/verifyTicketTokenAsNeeded.js +2 -1
  184. package/lib/chevre/service/payment/creditCard/authorize/processAuthorizeCreditCard.js +1 -1
  185. package/lib/chevre/service/payment/creditCard/payCreditCard.d.ts +6 -0
  186. package/lib/chevre/service/payment/creditCard/refundCreditCard.d.ts +6 -0
  187. package/lib/chevre/service/payment/creditCard/refundCreditCard.js +1 -1
  188. package/lib/chevre/service/payment/faceToFace.d.ts +10 -0
  189. package/lib/chevre/service/payment/factory/createPayObjectServiceOutput.js +2 -1
  190. package/lib/chevre/service/payment/factory.js +4 -2
  191. package/lib/chevre/service/payment/movieTicket/authorize.d.ts +6 -0
  192. package/lib/chevre/service/payment/movieTicket/authorize.js +1 -1
  193. package/lib/chevre/service/payment/movieTicket/payMovieTicket/payActionParams2seatInfoSyncIn.d.ts +12 -0
  194. package/lib/chevre/service/payment/movieTicket/payMovieTicket/payActionParams2seatInfoSyncIn.js +72 -0
  195. package/lib/chevre/service/payment/movieTicket/payMovieTicket/processSeatInfoSync.d.ts +8 -0
  196. package/lib/chevre/service/payment/movieTicket/payMovieTicket/processSeatInfoSync.js +29 -0
  197. package/lib/chevre/service/payment/movieTicket/payMovieTicket.d.ts +7 -1
  198. package/lib/chevre/service/payment/movieTicket/payMovieTicket.js +4 -71
  199. package/lib/chevre/service/payment/movieTicket/refundMovieTicket.d.ts +6 -0
  200. package/lib/chevre/service/payment/movieTicket/validation.d.ts +1 -2
  201. package/lib/chevre/service/payment/movieTicket/validation.js +37 -29
  202. package/lib/chevre/service/payment/movieTicket/voidTransaction.d.ts +6 -0
  203. package/lib/chevre/service/payment/paymentCard.d.ts +10 -0
  204. package/lib/chevre/service/permit.js +4 -2
  205. package/lib/chevre/service/reserve/factory.d.ts +1 -1
  206. package/lib/chevre/service/reserve/findByCode.js +2 -1
  207. package/lib/chevre/service/reserve/searchByOrder.js +2 -1
  208. package/lib/chevre/service/reserve/verifyToken4reservation.js +2 -1
  209. package/lib/chevre/service/task/authorizePayment.js +6 -0
  210. package/lib/chevre/service/task/confirmReserveTransaction.js +4 -2
  211. package/lib/chevre/service/task/invalidatePaymentUrl.js +6 -0
  212. package/lib/chevre/service/task/onResourceUpdated.js +1 -1
  213. package/lib/chevre/service/task/pay.js +6 -0
  214. package/lib/chevre/service/task/payment/invalidatePaymentUrlByTask.d.ts +6 -0
  215. package/lib/chevre/service/task/payment/payByTask.d.ts +6 -0
  216. package/lib/chevre/service/task/payment/payByTask.js +2 -1
  217. package/lib/chevre/service/task/payment/refundByTask.d.ts +6 -0
  218. package/lib/chevre/service/task/payment/voidPaymentByTask.d.ts +6 -0
  219. package/lib/chevre/service/task/refund.js +6 -0
  220. package/lib/chevre/service/task/returnReserveTransaction.js +2 -1
  221. package/lib/chevre/service/task/voidPayment.js +6 -0
  222. package/lib/chevre/service/transaction/deleteTransaction.js +4 -2
  223. package/lib/chevre/service/transaction/placeOrder/exportTasks/factory.js +2 -1
  224. package/lib/chevre/service/transaction/returnOrder/exportTasks/factory.js +2 -1
  225. package/lib/chevre/service/transaction/returnOrder/potentialActions/returnPaymentMethod.js +2 -2
  226. package/lib/chevre/service/transaction/returnOrder/preStart/getReturnPolicyByProject.js +5 -3
  227. package/lib/chevre/service/validation/validateOrder.js +4 -2
  228. package/package.json +1 -1
@@ -44,7 +44,7 @@ function verifyToken4reservation(params) {
44
44
  throw new factory.errors.ArgumentNull('ticket.token or ticket.ticketToken');
45
45
  }
46
46
  switch (payload.typeOf) {
47
- case factory.order.OrderType.Order:
47
+ case factory.order.OrderType.Order: {
48
48
  orderNumber = payload.orderNumber;
49
49
  if (typeof orderNumber !== 'string' || orderNumber.length === 0) {
50
50
  throw new factory.errors.NotFound('payload.orderNumber');
@@ -66,6 +66,7 @@ function verifyToken4reservation(params) {
66
66
  throw new factory.errors.Argument('token', `invalid orderStatus '${order.orderStatus}'`);
67
67
  }
68
68
  break;
69
+ }
69
70
  default:
70
71
  throw new factory.errors.NotImplemented(`Payload type ${payload.typeOf} not implemented`);
71
72
  }
@@ -28,6 +28,8 @@ const factory = __importStar(require("../../factory"));
28
28
  const acceptedPaymentMethod_1 = require("../../repo/acceptedPaymentMethod");
29
29
  const accountingReport_1 = require("../../repo/accountingReport");
30
30
  const action_1 = require("../../repo/action");
31
+ const pay_1 = require("../../repo/action/pay");
32
+ const refund_1 = require("../../repo/action/refund");
31
33
  const checkMovieTicket_1 = require("../../repo/action/checkMovieTicket");
32
34
  const acceptPay_1 = require("../../repo/action/acceptPay");
33
35
  const authorizeInvoice_1 = require("../../repo/action/authorizeInvoice");
@@ -81,6 +83,10 @@ function call(params) {
81
83
  acceptedPaymentMethod: new acceptedPaymentMethod_1.AcceptedPaymentMethodRepo(connection),
82
84
  accountingReport: new accountingReport_1.AccountingReportRepo(connection),
83
85
  action: new action_1.ActionRepo(connection),
86
+ actions: {
87
+ pay: new pay_1.PayActionRepo(connection),
88
+ refund: new refund_1.RefundActionRepo(connection),
89
+ },
84
90
  checkMovieTicketAction: new checkMovieTicket_1.CheckMovieTicketActionRepo(connection),
85
91
  acceptPayAction: new acceptPay_1.AcceptPayActionRepo(connection),
86
92
  authorizeInvoiceAction: new authorizeInvoice_1.AuthorizeInvoiceActionRepo(connection),
@@ -176,7 +176,7 @@ function confirmReserveTransaction(params, options) {
176
176
  // let updReserveResult: COA.factory.reserve.IUpdReserveResult | undefined;
177
177
  let recipe;
178
178
  switch (params.object.typeOf) {
179
- case factory.assetTransactionType.COAReserveTransaction:
179
+ case factory.assetTransactionType.COAReserveTransaction: {
180
180
  // 最適化されたタスクに対応するため、ここでIObject4COAを注文から生成する(2024-01-24~)
181
181
  const order = await fixOrderAsPurpose({
182
182
  project: { id: params.project.id },
@@ -194,6 +194,7 @@ function confirmReserveTransaction(params, options) {
194
194
  project: { id: params.project.id }
195
195
  });
196
196
  break;
197
+ }
197
198
  default:
198
199
  confirmActionObject = params.object;
199
200
  }
@@ -210,7 +211,7 @@ function confirmReserveTransaction(params, options) {
210
211
  try {
211
212
  const object = confirmActionAttributes.object;
212
213
  switch (object.typeOf) {
213
- case factory.assetTransactionType.COAReserveTransaction:
214
+ case factory.assetTransactionType.COAReserveTransaction: {
214
215
  // COA本予約
215
216
  const processConfirmCOAReserveResult = await (0, reserveCOA_1.confirm)({
216
217
  project: { id: confirmActionAttributes.project.id },
@@ -223,6 +224,7 @@ function confirmReserveTransaction(params, options) {
223
224
  project: { id: confirmActionAttributes.project.id }
224
225
  });
225
226
  break;
227
+ }
226
228
  default:
227
229
  // 予約取引確定
228
230
  await (0, confirm_1.confirm)({
@@ -3,6 +3,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.call = call;
4
4
  const accountingReport_1 = require("../../repo/accountingReport");
5
5
  const action_1 = require("../../repo/action");
6
+ const pay_1 = require("../../repo/action/pay");
7
+ const refund_1 = require("../../repo/action/refund");
6
8
  const assetTransaction_1 = require("../../repo/assetTransaction");
7
9
  const paymentService_1 = require("../../repo/paymentService");
8
10
  const paymentServiceProvider_1 = require("../../repo/paymentServiceProvider");
@@ -17,6 +19,10 @@ function call(params) {
17
19
  })({
18
20
  accountingReport: new accountingReport_1.AccountingReportRepo(connection),
19
21
  action: new action_1.ActionRepo(connection),
22
+ actions: {
23
+ pay: new pay_1.PayActionRepo(connection),
24
+ refund: new refund_1.RefundActionRepo(connection),
25
+ },
20
26
  assetTransaction: new assetTransaction_1.AssetTransactionRepo(connection),
21
27
  paymentAccepted: new sellerPaymentAccepted_1.SellerPaymentAcceptedRepo(connection),
22
28
  paymentService: new paymentService_1.PaymentServiceRepo(connection),
@@ -450,7 +450,7 @@ function createInformMovieTheaterTasks(params, setting) {
450
450
  // );
451
451
  // 入場ゲートを廃止(2026-01-17~)
452
452
  const movieTheaters4inform = movieTheaters.map((movieTheater) => {
453
- const { hasEntranceGate, ...movieTheaterWithoutEntranceGates } = movieTheater;
453
+ const { hasEntranceGate, ...movieTheaterWithoutEntranceGates } = movieTheater; // eslint-disable-line @typescript-eslint/no-unused-vars
454
454
  return {
455
455
  ...movieTheaterWithoutEntranceGates
456
456
  // ...movieTheater
@@ -28,6 +28,8 @@ const factory = __importStar(require("../../factory"));
28
28
  const acceptedOffer_1 = require("../../repo/acceptedOffer");
29
29
  const accountingReport_1 = require("../../repo/accountingReport");
30
30
  const action_1 = require("../../repo/action");
31
+ const pay_1 = require("../../repo/action/pay");
32
+ const refund_1 = require("../../repo/action/refund");
31
33
  const checkMovieTicket_1 = require("../../repo/action/checkMovieTicket");
32
34
  const assetTransaction_1 = require("../../repo/assetTransaction");
33
35
  const credentials_1 = require("../../repo/credentials");
@@ -71,6 +73,10 @@ function call(params) {
71
73
  acceptedOffer: new acceptedOffer_1.AcceptedOfferRepo(connection),
72
74
  accountingReport: new accountingReport_1.AccountingReportRepo(connection),
73
75
  action: new action_1.ActionRepo(connection),
76
+ actions: {
77
+ pay: new pay_1.PayActionRepo(connection),
78
+ refund: new refund_1.RefundActionRepo(connection),
79
+ },
74
80
  assetTransaction: new assetTransaction_1.AssetTransactionRepo(connection),
75
81
  credentials: new credentials_1.CredentialsRepo(redisClient, {
76
82
  scope: `${factory.service.paymentService.PaymentServiceType.MovieTicket}:${paymentServiceId}`,
@@ -2,6 +2,8 @@ import * as factory from '../../../factory';
2
2
  import { Settings } from '../../../settings';
3
3
  import type { AccountingReportRepo } from '../../../repo/accountingReport';
4
4
  import type { ActionRepo } from '../../../repo/action';
5
+ import type { PayActionRepo } from '../../../repo/action/pay';
6
+ import type { RefundActionRepo } from '../../../repo/action/refund';
5
7
  import type { AssetTransactionRepo } from '../../../repo/assetTransaction';
6
8
  import type { PaymentServiceRepo } from '../../../repo/paymentService';
7
9
  import type { PaymentServiceProviderRepo } from '../../../repo/paymentServiceProvider';
@@ -10,6 +12,10 @@ import type { TaskRepo } from '../../../repo/task';
10
12
  type IInvalidatePaymentUrlOperation<T> = (repos: {
11
13
  accountingReport: AccountingReportRepo;
12
14
  action: ActionRepo;
15
+ actions: {
16
+ pay: PayActionRepo;
17
+ refund: RefundActionRepo;
18
+ };
13
19
  paymentAccepted: SellerPaymentAcceptedRepo;
14
20
  paymentService: PaymentServiceRepo;
15
21
  paymentServiceProvider: PaymentServiceProviderRepo;
@@ -1,6 +1,8 @@
1
1
  import type { AcceptedOfferRepo } from '../../../repo/acceptedOffer';
2
2
  import type { AccountingReportRepo } from '../../../repo/accountingReport';
3
3
  import type { ActionRepo } from '../../../repo/action';
4
+ import type { PayActionRepo } from '../../../repo/action/pay';
5
+ import type { RefundActionRepo } from '../../../repo/action/refund';
4
6
  import type { CheckMovieTicketActionRepo } from '../../../repo/action/checkMovieTicket';
5
7
  import type { AssetTransactionRepo } from '../../../repo/assetTransaction';
6
8
  import type { CredentialsRepo } from '../../../repo/credentials';
@@ -32,6 +34,10 @@ declare function payTask2payActionAttributes(params: factory.task.pay.IData & {
32
34
  interface IPayByTaskRepos {
33
35
  acceptedOffer: AcceptedOfferRepo;
34
36
  action: ActionRepo;
37
+ actions: {
38
+ pay: PayActionRepo;
39
+ refund: RefundActionRepo;
40
+ };
35
41
  accountingReport: AccountingReportRepo;
36
42
  assetTransaction: AssetTransactionRepo;
37
43
  credentials: CredentialsRepo;
@@ -177,7 +177,7 @@ payActionAttributes) {
177
177
  case factory.service.paymentService.PaymentServiceType.CreditCard:
178
178
  await CreditCardPaymentService.payCreditCard(payActionAttributes)(repos, settings);
179
179
  break;
180
- case factory.service.paymentService.PaymentServiceType.MovieTicket:
180
+ case factory.service.paymentService.PaymentServiceType.MovieTicket: {
181
181
  // check purpose(2025-02-12~)
182
182
  const purpose = payActionAttributes.purpose;
183
183
  if (purpose?.typeOf !== factory.order.OrderType.Order) {
@@ -188,6 +188,7 @@ payActionAttributes) {
188
188
  purpose
189
189
  }, { callOnPayActionCompleted: true })(repos, settings);
190
190
  break;
191
+ }
191
192
  default:
192
193
  throw new factory.errors.NotImplemented(`Payment service '${paymentServiceType}' not implemented`);
193
194
  }
@@ -1,5 +1,7 @@
1
1
  import type { AccountingReportRepo } from '../../../repo/accountingReport';
2
2
  import type { ActionRepo } from '../../../repo/action';
3
+ import type { PayActionRepo } from '../../../repo/action/pay';
4
+ import type { RefundActionRepo } from '../../../repo/action/refund';
3
5
  import type { AssetTransactionRepo } from '../../../repo/assetTransaction';
4
6
  import type { CredentialsRepo } from '../../../repo/credentials';
5
7
  import type { PaymentServiceRepo } from '../../../repo/paymentService';
@@ -17,6 +19,10 @@ declare function refundByTask(params: factory.task.refund.IData & {
17
19
  };
18
20
  }): (repos: {
19
21
  action: ActionRepo;
22
+ actions: {
23
+ pay: PayActionRepo;
24
+ refund: RefundActionRepo;
25
+ };
20
26
  accountingReport: AccountingReportRepo;
21
27
  credentials: CredentialsRepo;
22
28
  paymentAccepted: SellerPaymentAcceptedRepo;
@@ -1,5 +1,7 @@
1
1
  import type { AccountingReportRepo } from '../../../repo/accountingReport';
2
2
  import type { ActionRepo } from '../../../repo/action';
3
+ import type { PayActionRepo } from '../../../repo/action/pay';
4
+ import type { RefundActionRepo } from '../../../repo/action/refund';
3
5
  import type { AuthorizeInvoiceActionRepo } from '../../../repo/action/authorizeInvoice';
4
6
  import type { CredentialsRepo } from '../../../repo/credentials';
5
7
  import type { PaymentServiceRepo } from '../../../repo/paymentService';
@@ -12,6 +14,10 @@ import * as factory from '../../../factory';
12
14
  import { Settings } from '../../../settings';
13
15
  declare function voidPaymentByTask(params: factory.task.voidPayment.IData): (repos: {
14
16
  action: ActionRepo;
17
+ actions: {
18
+ pay: PayActionRepo;
19
+ refund: RefundActionRepo;
20
+ };
15
21
  authorizeInvoiceAction: AuthorizeInvoiceActionRepo;
16
22
  accountingReport: AccountingReportRepo;
17
23
  credentials: CredentialsRepo;
@@ -27,6 +27,8 @@ exports.call = call;
27
27
  const factory = __importStar(require("../../factory"));
28
28
  const accountingReport_1 = require("../../repo/accountingReport");
29
29
  const action_1 = require("../../repo/action");
30
+ const pay_1 = require("../../repo/action/pay");
31
+ const refund_1 = require("../../repo/action/refund");
30
32
  const assetTransaction_1 = require("../../repo/assetTransaction");
31
33
  const credentials_1 = require("../../repo/credentials");
32
34
  const paymentService_1 = require("../../repo/paymentService");
@@ -62,6 +64,10 @@ function call(params) {
62
64
  await (0, refundByTask_1.refundByTask)(data)({
63
65
  accountingReport: new accountingReport_1.AccountingReportRepo(connection),
64
66
  action: new action_1.ActionRepo(connection),
67
+ actions: {
68
+ pay: new pay_1.PayActionRepo(connection),
69
+ refund: new refund_1.RefundActionRepo(connection),
70
+ },
65
71
  credentials: new credentials_1.CredentialsRepo(redisClient, {
66
72
  scope: `${factory.service.paymentService.PaymentServiceType.MovieTicket}:${paymentServiceId}`,
67
73
  expireInSeconds: (useCredentialsRepo) ? credentialsExpireInSeconds : 0
@@ -101,7 +101,7 @@ function returnReserve(params) {
101
101
  });
102
102
  try {
103
103
  switch (params.object.typeOf) {
104
- case factory.assetTransactionType.COAReserveTransaction:
104
+ case factory.assetTransactionType.COAReserveTransaction: {
105
105
  const processReturnCOAReserveResult = await CancelReservationCOAService.confirm({ object: params.object })({
106
106
  reserveService: repos.reserveService
107
107
  });
@@ -110,6 +110,7 @@ function returnReserve(params) {
110
110
  project: { id: project.id }
111
111
  });
112
112
  break;
113
+ }
113
114
  default:
114
115
  await processCancelReservation4chevre(params, {
115
116
  id: action.id,
@@ -27,6 +27,8 @@ exports.call = call;
27
27
  const factory = __importStar(require("../../factory"));
28
28
  const accountingReport_1 = require("../../repo/accountingReport");
29
29
  const action_1 = require("../../repo/action");
30
+ const pay_1 = require("../../repo/action/pay");
31
+ const refund_1 = require("../../repo/action/refund");
30
32
  const authorizeInvoice_1 = require("../../repo/action/authorizeInvoice");
31
33
  const credentials_1 = require("../../repo/credentials");
32
34
  const paymentService_1 = require("../../repo/paymentService");
@@ -51,6 +53,10 @@ function call(data) {
51
53
  await (0, voidPaymentByTask_1.voidPaymentByTask)(data)({
52
54
  accountingReport: new accountingReport_1.AccountingReportRepo(connection),
53
55
  action: new action_1.ActionRepo(connection),
56
+ actions: {
57
+ pay: new pay_1.PayActionRepo(connection),
58
+ refund: new refund_1.RefundActionRepo(connection),
59
+ },
54
60
  authorizeInvoiceAction: new authorizeInvoice_1.AuthorizeInvoiceActionRepo(connection),
55
61
  credentials: new credentials_1.CredentialsRepo(redisClient, {
56
62
  scope: `${factory.service.paymentService.PaymentServiceType.MovieTicket}:${paymentServiceId}`,
@@ -197,7 +197,7 @@ function deleteTransactionById(params) {
197
197
  try {
198
198
  const transactionTypeOf = transaction.typeOf;
199
199
  switch (transactionTypeOf) {
200
- case factory.transactionType.PlaceOrder:
200
+ case factory.transactionType.PlaceOrder: {
201
201
  // 取引に対する全ての承認アクションを検索
202
202
  const authorizeActions = await repos.action.searchByPurpose({
203
203
  typeOf: factory.actionType.AuthorizeAction,
@@ -210,7 +210,7 @@ function deleteTransactionById(params) {
210
210
  case factory.transactionStatusType.Canceled:
211
211
  case factory.transactionStatusType.Expired:
212
212
  break;
213
- case factory.transactionStatusType.Confirmed:
213
+ case factory.transactionStatusType.Confirmed: {
214
214
  const deletingOrder = transaction.result?.order;
215
215
  if (typeof deletingOrder?.orderNumber === 'string') {
216
216
  await (0, deleteOrder_1.deleteOrder)({
@@ -218,6 +218,7 @@ function deleteTransactionById(params) {
218
218
  })(repos);
219
219
  }
220
220
  break;
221
+ }
221
222
  default:
222
223
  throw new factory.errors.NotImplemented(`${transaction.status} not implemented`);
223
224
  }
@@ -256,6 +257,7 @@ function deleteTransactionById(params) {
256
257
  // 取引削除
257
258
  await repos.transaction.findByIdAndDelete({ id: transaction.id });
258
259
  break;
260
+ }
259
261
  // implemented(2022-06-09~)
260
262
  case factory.transactionType.ReturnOrder:
261
263
  // 取引削除
@@ -166,7 +166,7 @@ function createTasks(params, setting
166
166
  };
167
167
  taskAttributes.push(...triggerWebhookTaskAttributes, deleteTransactionTask);
168
168
  switch (transaction.status) {
169
- case factory.transactionStatusType.Confirmed:
169
+ case factory.transactionStatusType.Confirmed: {
170
170
  taskAttributes.push(voidReserveTaskAttributes, voidPaymentTaskAttributes);
171
171
  // const potentialActions = transaction.potentialActions;
172
172
  // if (potentialActions === undefined) {
@@ -201,6 +201,7 @@ function createTasks(params, setting
201
201
  };
202
202
  taskAttributes.push(placeOrderTaskAttributes);
203
203
  break;
204
+ }
204
205
  case factory.transactionStatusType.Canceled:
205
206
  taskAttributes.push(voidReserveTaskAttributes, voidPaymentTaskAttributes);
206
207
  break;
@@ -92,7 +92,7 @@ function createTasks(params, setting
92
92
  };
93
93
  taskAttributes.push(deleteTransactionTask);
94
94
  switch (transaction.status) {
95
- case factory.transactionStatusType.Confirmed:
95
+ case factory.transactionStatusType.Confirmed: {
96
96
  const returnOrderPotentialActions = transaction.potentialActions?.returnOrder;
97
97
  if (Array.isArray(returnOrderPotentialActions)) {
98
98
  // 返品タスク
@@ -118,6 +118,7 @@ function createTasks(params, setting
118
118
  taskAttributes.push(...returnOrderTask);
119
119
  }
120
120
  break;
121
+ }
121
122
  case factory.transactionStatusType.Expired:
122
123
  // 特にタスクなし
123
124
  break;
@@ -112,7 +112,7 @@ setting) {
112
112
  : undefined
113
113
  }, setting);
114
114
  emailMessagesOnReturnInvoice.push(...emailMessagesOnReturnEachPaymentMethodId);
115
- const { paymentStatus, ...referencedInvoiceAsObject } = referencedInvoice;
115
+ const { paymentStatus, ...referencedInvoiceAsObject } = referencedInvoice; // eslint-disable-line @typescript-eslint/no-unused-vars
116
116
  const object = {
117
117
  ...referencedInvoiceAsObject,
118
118
  typeOf: 'Invoice'
@@ -190,7 +190,7 @@ setting) {
190
190
  : undefined
191
191
  }, setting);
192
192
  emailMessagesOnReturnMovieTicket.push(...emailMessagesOnReturnEachPaymentMethodId);
193
- const { paymentStatus, ...referencedInvoiceAsObject } = referencedInvoice;
193
+ const { paymentStatus, ...referencedInvoiceAsObject } = referencedInvoice; // eslint-disable-line @typescript-eslint/no-unused-vars
194
194
  const object = {
195
195
  ...referencedInvoiceAsObject,
196
196
  typeOf: 'Invoice'
@@ -51,7 +51,8 @@ function createOrder4returnPolicy(params) {
51
51
  priceSpecification: {
52
52
  priceComponent: (Array.isArray(priceComponent))
53
53
  ? priceComponent.map((component) => {
54
- const { accounting, name, priceCurrency, valueAddedTaxIncluded, ...postingComponent } = component;
54
+ const { accounting, name, priceCurrency, valueAddedTaxIncluded, // eslint-disable-line @typescript-eslint/no-unused-vars
55
+ ...postingComponent } = component;
55
56
  return postingComponent;
56
57
  })
57
58
  : []
@@ -89,7 +90,7 @@ async function getReturnPolicyByProject(params) {
89
90
  try {
90
91
  body = await res.json();
91
92
  }
92
- catch (error) {
93
+ catch (_error) {
93
94
  // no op
94
95
  }
95
96
  let returnPolicy;
@@ -97,7 +98,7 @@ async function getReturnPolicyByProject(params) {
97
98
  case http_status_1.OK:
98
99
  case http_status_1.CREATED:
99
100
  case http_status_1.ACCEPTED:
100
- case http_status_1.NO_CONTENT:
101
+ case http_status_1.NO_CONTENT: {
101
102
  const restockingFeeValue = body?.restockingFee?.value;
102
103
  if (typeof restockingFeeValue !== 'number') {
103
104
  throw new factory.errors.Internal('invalid return policy');
@@ -121,6 +122,7 @@ async function getReturnPolicyByProject(params) {
121
122
  };
122
123
  }
123
124
  break;
125
+ }
124
126
  case http_status_1.NOT_FOUND:
125
127
  throw new factory.errors.Argument('', `custom return policy returned statusCode: ${res.status}`);
126
128
  // break;
@@ -165,7 +165,7 @@ function validateOrder(params) {
165
165
  let numOrderedItemExpected = 0;
166
166
  const itemOfferedTypeOf = itemOfferedTypeOfs[0];
167
167
  switch (itemOfferedTypeOf) {
168
- case factory.reservationType.EventReservation:
168
+ case factory.reservationType.EventReservation: {
169
169
  numOrderedItemExpected = reservationForIds.length;
170
170
  const reservationAcceptedOffers = acceptedOffers;
171
171
  const coaTicketInfoExists = reservationAcceptedOffers[0].itemOffered.reservedTicket.coaTicketInfo !== undefined;
@@ -197,13 +197,15 @@ function validateOrder(params) {
197
197
  });
198
198
  }
199
199
  break;
200
- case factory.permit.PermitType.Permit:
200
+ }
201
+ case factory.permit.PermitType.Permit: {
201
202
  numOrderedItemExpected = acceptedOffers.length;
202
203
  const permitAcceptedOffers = acceptedOffers;
203
204
  priceExpected = (0, factory_2.acceptedOffers2amount)({
204
205
  acceptedOffers: permitAcceptedOffers
205
206
  });
206
207
  break;
208
+ }
207
209
  // case factory.actionType.MoneyTransfer:
208
210
  // break;
209
211
  default:
package/package.json CHANGED
@@ -99,5 +99,5 @@
99
99
  "postversion": "git push origin --tags",
100
100
  "prepublishOnly": "npm run clean && npm run build"
101
101
  },
102
- "version": "24.0.0-alpha.40"
102
+ "version": "24.0.0-alpha.41"
103
103
  }