@chevre/domain 23.1.0-alpha.3 → 23.1.0-alpha.4
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.
|
@@ -74,11 +74,22 @@ function requestedProgramMembershipUsed2permit(params) {
|
|
|
74
74
|
throw new factory.errors.Argument('programMembershipUsed', `invalid issuedThrough.typeOf: ${issuedThroughTypeOf}`);
|
|
75
75
|
}
|
|
76
76
|
}
|
|
77
|
+
else if (ownedGoodType === factory.service.paymentService.PaymentServiceType.FaceToFace) {
|
|
78
|
+
const paymentMethodId = permitOwnershipInfo.typeOfGood.serviceOutput.paymentMethodId;
|
|
79
|
+
if (typeof paymentMethodId !== 'string' || paymentMethodId === '') {
|
|
80
|
+
throw new factory.errors.Argument('programMembershipUsed', 'paymentMethodId required');
|
|
81
|
+
}
|
|
82
|
+
programMembershipUsedAsPermit = {
|
|
83
|
+
identifier: paymentMethodId,
|
|
84
|
+
issuedThrough: { typeOf: ownedGoodType },
|
|
85
|
+
typeOf: factory.permit.PermitType.Permit
|
|
86
|
+
};
|
|
87
|
+
}
|
|
77
88
|
else if (ownedGoodType === factory.service.paymentService.PaymentServiceType.CreditCard) {
|
|
78
89
|
// CreditCard決済の場合、決済方法所有権を受け入れる(2025-11-11~)
|
|
79
90
|
const paymentServiceId = (_d = permitOwnershipInfo.typeOfGood) === null || _d === void 0 ? void 0 : _d.id;
|
|
80
91
|
const paymentMethodId = permitOwnershipInfo.typeOfGood.serviceOutput.paymentMethodId;
|
|
81
|
-
if (typeof
|
|
92
|
+
if (typeof paymentServiceId !== 'string' || paymentServiceId === '') {
|
|
82
93
|
throw new factory.errors.Argument('programMembershipUsed', 'paymentServiceId required');
|
|
83
94
|
}
|
|
84
95
|
if (typeof paymentMethodId !== 'string' || paymentMethodId === '') {
|
|
@@ -11,7 +11,9 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.verifyTicketTokenAsNeeded = verifyTicketTokenAsNeeded;
|
|
13
13
|
const factory = require("../../../factory");
|
|
14
|
+
// tslint:disable-next-line:max-func-body-length
|
|
14
15
|
function verifyTicketTokenAsNeeded(params) {
|
|
16
|
+
// tslint:disable-next-line:cyclomatic-complexity
|
|
15
17
|
return (repos) => __awaiter(this, void 0, void 0, function* () {
|
|
16
18
|
var _a, _b;
|
|
17
19
|
const { paymentServiceType, object, project } = params;
|
|
@@ -67,13 +69,17 @@ function verifyTicketTokenAsNeeded(params) {
|
|
|
67
69
|
}
|
|
68
70
|
}
|
|
69
71
|
else if (typeOfGood.typeOf === factory.service.paymentService.PaymentServiceType.CreditCard
|
|
70
|
-
|| typeOfGood.typeOf === factory.service.paymentService.PaymentServiceType.MovieTicket
|
|
72
|
+
|| typeOfGood.typeOf === factory.service.paymentService.PaymentServiceType.MovieTicket
|
|
73
|
+
|| typeOfGood.typeOf === factory.service.paymentService.PaymentServiceType.FaceToFace) {
|
|
71
74
|
// 決済方法所有権を受け入れる(2025-11-11~)
|
|
72
75
|
if (typeOfGood.typeOf !== paymentServiceType) {
|
|
73
76
|
throw new factory.errors.Argument('ticketToken', 'paymentServiceType not matched');
|
|
74
77
|
}
|
|
75
|
-
|
|
76
|
-
|
|
78
|
+
// FaceToFace以外の場合、発行サービスIDを検証
|
|
79
|
+
if (typeOfGood.typeOf !== factory.service.paymentService.PaymentServiceType.FaceToFace) {
|
|
80
|
+
if (typeOfGood.id !== issuedThrough.id) {
|
|
81
|
+
throw new factory.errors.Argument('ticketToken', 'issuedThrough.id not matched');
|
|
82
|
+
}
|
|
77
83
|
}
|
|
78
84
|
permitOrInvoice = { paymentMethodId: typeOfGood.serviceOutput.paymentMethodId, typeOf: 'Invoice' };
|
|
79
85
|
}
|
package/package.json
CHANGED
|
@@ -11,8 +11,8 @@
|
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"@aws-sdk/client-cognito-identity-provider": "3.600.0",
|
|
13
13
|
"@aws-sdk/credential-providers": "3.600.0",
|
|
14
|
-
"@chevre/factory": "5.2.0-alpha.
|
|
15
|
-
"@cinerino/sdk": "12.7.0-alpha.
|
|
14
|
+
"@chevre/factory": "5.2.0-alpha.9",
|
|
15
|
+
"@cinerino/sdk": "12.7.0-alpha.4",
|
|
16
16
|
"@motionpicture/coa-service": "9.6.0",
|
|
17
17
|
"@motionpicture/gmo-service": "5.4.0-alpha.1",
|
|
18
18
|
"@sendgrid/client": "8.1.4",
|
|
@@ -115,5 +115,5 @@
|
|
|
115
115
|
"postversion": "git push origin --tags",
|
|
116
116
|
"prepublishOnly": "npm run clean && npm run build && npm test && npm run doc"
|
|
117
117
|
},
|
|
118
|
-
"version": "23.1.0-alpha.
|
|
118
|
+
"version": "23.1.0-alpha.4"
|
|
119
119
|
}
|