@chevre/domain 26.0.0-alpha.2 → 26.0.0-alpha.3
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.
- package/lib/chevre/service/assetTransaction/reserve/start/factory/createStartParams.js +5 -25
- package/lib/chevre/service/offer/eventServiceByCOA/authorize/factory.js +1 -1
- package/lib/chevre/service/task/importEventCapacitiesFromCOA.js +4 -1
- package/lib/chevre/service/task/importEventsFromCOA.js +4 -1
- package/lib/chevre/service/task/importOffersFromCOA.js +5 -5
- package/lib/chevre/service/taskHandler.js +0 -34
- package/package.json +2 -2
|
@@ -9,7 +9,7 @@ function createStartParams(params) {
|
|
|
9
9
|
typeOf: factory_1.factory.organizationType.Corporation
|
|
10
10
|
};
|
|
11
11
|
// reservationFor,issuedThrough保管をaddReservationsから移行(2024-07-01~)
|
|
12
|
-
const reservationFor = createReservationFor(params.event
|
|
12
|
+
const reservationFor = createReservationFor(params.event);
|
|
13
13
|
const { issuedThrough } = createIssuedThrough({ reservationFor: params.event });
|
|
14
14
|
const reservationPackage = {
|
|
15
15
|
issuedThrough, // addReservationsから移行(2024-07-01~)
|
|
@@ -33,7 +33,7 @@ function createStartParams(params) {
|
|
|
33
33
|
instrument
|
|
34
34
|
};
|
|
35
35
|
}
|
|
36
|
-
function createReservationFor(params
|
|
36
|
+
function createReservationFor(params) {
|
|
37
37
|
if (params.typeOf === factory_1.factory.eventType.ScreeningEvent) {
|
|
38
38
|
return {
|
|
39
39
|
endDate: params.endDate,
|
|
@@ -41,7 +41,7 @@ function createReservationFor(params, useOptimizeReservation) {
|
|
|
41
41
|
location: params.location,
|
|
42
42
|
name: params.name,
|
|
43
43
|
startDate: params.startDate,
|
|
44
|
-
superEvent: optimizeReservationSuperEvent(params
|
|
44
|
+
superEvent: optimizeReservationSuperEvent(params),
|
|
45
45
|
typeOf: params.typeOf,
|
|
46
46
|
...(params.doorTime instanceof Date)
|
|
47
47
|
? { doorTime: params.doorTime }
|
|
@@ -52,38 +52,18 @@ function createReservationFor(params, useOptimizeReservation) {
|
|
|
52
52
|
throw new factory_1.factory.errors.NotImplemented(`typeOf: ${params.typeOf}`);
|
|
53
53
|
}
|
|
54
54
|
}
|
|
55
|
-
function optimizeReservationSuperEvent(params
|
|
55
|
+
function optimizeReservationSuperEvent(params) {
|
|
56
56
|
const superEvent = params.superEvent;
|
|
57
57
|
return {
|
|
58
58
|
id: superEvent.id,
|
|
59
|
-
// kanaName: superEvent.kanaName, // 廃止(2024-01-26~)
|
|
60
59
|
location: superEvent.location,
|
|
61
60
|
name: superEvent.name,
|
|
62
|
-
soundFormat: superEvent.soundFormat,
|
|
61
|
+
// soundFormat: superEvent.soundFormat, // discontinue(2026-08-01~)
|
|
63
62
|
typeOf: superEvent.typeOf,
|
|
64
63
|
workPerformed: superEvent.workPerformed,
|
|
65
|
-
// 廃止(2024-01-26~)
|
|
66
|
-
// ...(superEvent.description !== undefined)
|
|
67
|
-
// ? { description: superEvent.description }
|
|
68
|
-
// : undefined,
|
|
69
64
|
...(superEvent.headline !== undefined)
|
|
70
65
|
? { headline: superEvent.headline }
|
|
71
66
|
: undefined,
|
|
72
|
-
// 最適化対応(2024-03-16~)
|
|
73
|
-
...(useOptimizeReservation)
|
|
74
|
-
? {}
|
|
75
|
-
: {
|
|
76
|
-
additionalProperty: (Array.isArray(superEvent.additionalProperty))
|
|
77
|
-
? superEvent.additionalProperty
|
|
78
|
-
: []
|
|
79
|
-
}
|
|
80
|
-
// videoFormatをデータとしても廃止(万が一に備えてUSE_DEPRECATED_VIDEO_FORMATで再設定可能)(2026-02-03~)
|
|
81
|
-
// ...(USE_DEPRECATED_VIDEO_FORMAT)
|
|
82
|
-
// ? {
|
|
83
|
-
// // 現時点で型廃止済だがデータとしては互換性維持(2026-01-15~)
|
|
84
|
-
// videoFormat: (<any>superEvent).videoFormat
|
|
85
|
-
// }
|
|
86
|
-
// : undefined
|
|
87
67
|
};
|
|
88
68
|
}
|
|
89
69
|
function createIssuedThrough(params) {
|
|
@@ -100,7 +100,7 @@ function responseBody2acceptedOffers4result(params) {
|
|
|
100
100
|
name: event.superEvent.name,
|
|
101
101
|
alternativeHeadline: event.superEvent.alternativeHeadline,
|
|
102
102
|
location: event.superEvent.location,
|
|
103
|
-
soundFormat: event.superEvent.soundFormat,
|
|
103
|
+
// soundFormat: event.superEvent.soundFormat, // discontinue(2026-08-01~)
|
|
104
104
|
workPerformed: workPerformed,
|
|
105
105
|
duration: event.superEvent.duration,
|
|
106
106
|
coaInfo: event.superEvent.coaInfo
|
|
@@ -60,7 +60,10 @@ function call(params) {
|
|
|
60
60
|
endpoint: coaAuthClient.options.endpoint, // same as authClient(2024-07-17~)
|
|
61
61
|
auth: coaAuthClient
|
|
62
62
|
}, { timeout: (await settings.getByKey('coa')).timeoutReserve });
|
|
63
|
-
await EventAggregationService.importFromCOA(
|
|
63
|
+
await EventAggregationService.importFromCOA({
|
|
64
|
+
...params.data,
|
|
65
|
+
project: { id: params.project.id, typeOf: factory_1.factory.organizationType.Project }
|
|
66
|
+
})({
|
|
64
67
|
event: new event_1.EventRepo(connection),
|
|
65
68
|
reserveService
|
|
66
69
|
});
|
|
@@ -67,7 +67,10 @@ function call(params) {
|
|
|
67
67
|
endpoint: coaAuthClient.options.endpoint, // same as authClient(2024-07-17~)
|
|
68
68
|
auth: coaAuthClient
|
|
69
69
|
}, { timeout: (await settings.getByKey('coa')).timeoutMaster });
|
|
70
|
-
await EventService.importFromCOA(
|
|
70
|
+
await EventService.importFromCOA({
|
|
71
|
+
...params.data,
|
|
72
|
+
project: { id: params.project.id, typeOf: factory_1.factory.organizationType.Project }
|
|
73
|
+
})({
|
|
71
74
|
action: new action_1.ActionRepo(connection),
|
|
72
75
|
categoryCode: new categoryCode_1.CategoryCodeRepo(connection),
|
|
73
76
|
creativeWork: new creativeWork_1.CreativeWorkRepo(connection),
|
|
@@ -65,22 +65,22 @@ function call(params) {
|
|
|
65
65
|
const settings = new integration_1.IntegrationSettingRepo({ connection });
|
|
66
66
|
const aggregateOfferRepo = new aggregateOffer_1.AggregateOfferRepo(connection);
|
|
67
67
|
const categoryCodeRepo = new categoryCode_1.CategoryCodeRepo(connection);
|
|
68
|
-
// const taskRepo = new TaskRepo(connection);
|
|
69
68
|
const masterService = new coa_service_1.COA.service.Master({
|
|
70
69
|
endpoint: coaAuthClient.options.endpoint, // same as authClient(2024-07-17~)
|
|
71
70
|
auth: coaAuthClient
|
|
72
71
|
}, { timeout: (await settings.getByKey('coa')).timeoutMaster });
|
|
73
72
|
await OfferService.event.importFromCOA({
|
|
74
|
-
project: { id: params.
|
|
73
|
+
project: { id: params.project.id },
|
|
75
74
|
theaterCode: params.data.theaterCode,
|
|
76
75
|
paymentMethodType4membershipCoupon
|
|
77
76
|
})({
|
|
78
|
-
// categoryCode: categoryCodeRepo,
|
|
79
77
|
aggregateOffer: aggregateOfferRepo,
|
|
80
|
-
// task: taskRepo,
|
|
81
78
|
masterService
|
|
82
79
|
});
|
|
83
|
-
await OfferService.event.importCategoryCodesFromCOA(
|
|
80
|
+
await OfferService.event.importCategoryCodesFromCOA({
|
|
81
|
+
...params.data,
|
|
82
|
+
project: { id: params.project.id }
|
|
83
|
+
})({
|
|
84
84
|
categoryCode: categoryCodeRepo,
|
|
85
85
|
masterService
|
|
86
86
|
});
|
|
@@ -44,40 +44,6 @@ function executeTask(task, next) {
|
|
|
44
44
|
const { call } = await exports.taskLoader.load(task.name); // testが書きづらいのでtaskLoader経由で呼ぶ
|
|
45
45
|
const callResult = await call(task)(settings, options);
|
|
46
46
|
// ICallableTaskOperationSimpleを廃止(2026-07-22~)
|
|
47
|
-
// let callResult: ICallResult | undefined;
|
|
48
|
-
// switch (task.name) {
|
|
49
|
-
// case factory.taskName.AcceptCOAOffer:
|
|
50
|
-
// case factory.taskName.AggregateOnSystem:
|
|
51
|
-
// case factory.taskName.AuthorizePayment:
|
|
52
|
-
// case factory.taskName.CancelPendingReservation:
|
|
53
|
-
// case factory.taskName.CheckMovieTicket:
|
|
54
|
-
// case factory.taskName.CheckResource:
|
|
55
|
-
// case factory.taskName.CreateAccountingReport:
|
|
56
|
-
// case factory.taskName.HandleNotification:
|
|
57
|
-
// case factory.taskName.ImportEventCapacitiesFromCOA:
|
|
58
|
-
// case factory.taskName.ImportEventsFromCOA:
|
|
59
|
-
// case factory.taskName.ImportOffersFromCOA:
|
|
60
|
-
// case factory.taskName.InvalidatePaymentUrl:
|
|
61
|
-
// case factory.taskName.OnAuthorizationCreated:
|
|
62
|
-
// case factory.taskName.OnResourceDeleted:
|
|
63
|
-
// case factory.taskName.Pay:
|
|
64
|
-
// case factory.taskName.PublishPaymentUrl:
|
|
65
|
-
// case factory.taskName.Refund:
|
|
66
|
-
// case factory.taskName.VoidPayTransaction:
|
|
67
|
-
// case factory.taskName.VoidReserveTransaction:
|
|
68
|
-
// case factory.taskName.ConfirmPayTransaction:
|
|
69
|
-
// case factory.taskName.ConfirmReserveTransaction:
|
|
70
|
-
// case factory.taskName.ReturnPayTransaction:
|
|
71
|
-
// case factory.taskName.ReturnReserveTransaction:
|
|
72
|
-
// case factory.taskName.SendEmailMessage:
|
|
73
|
-
// case factory.taskName.SyncResourcesFromCOA:
|
|
74
|
-
// case factory.taskName.TriggerWebhook:
|
|
75
|
-
// case factory.taskName.UseReservation:
|
|
76
|
-
// callResult = await (call as ICallableTaskOperation)(task)(settings, options);
|
|
77
|
-
// break;
|
|
78
|
-
// default:
|
|
79
|
-
// await (call as ICallableTaskOperationSimple)(task.data)(settings); // TODO discontinue
|
|
80
|
-
// }
|
|
81
47
|
const result = {
|
|
82
48
|
executedAt: now,
|
|
83
49
|
endDate: new Date(),
|
package/package.json
CHANGED
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"@aws-sdk/client-cognito-identity-provider": "3.1090.0",
|
|
13
13
|
"@aws-sdk/credential-providers": "3.1090.0",
|
|
14
|
-
"@chevre/factory": "10.1.0-alpha.
|
|
14
|
+
"@chevre/factory": "10.1.0-alpha.4",
|
|
15
15
|
"@motionpicture/coa-service": "10.0.0",
|
|
16
16
|
"@motionpicture/gmo-service": "6.1.0-alpha.0",
|
|
17
17
|
"@sendgrid/client": "8.1.4",
|
|
@@ -88,5 +88,5 @@
|
|
|
88
88
|
"postversion": "git push origin --tags",
|
|
89
89
|
"prepublishOnly": "npm run clean && npm run build"
|
|
90
90
|
},
|
|
91
|
-
"version": "26.0.0-alpha.
|
|
91
|
+
"version": "26.0.0-alpha.3"
|
|
92
92
|
}
|