@chevre/domain 25.2.0-alpha.29 → 25.2.0-alpha.30
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/repo/transaction/placeOrder.d.ts +1 -1
- package/lib/chevre/repo/transaction/placeOrder.js +1 -1
- package/lib/chevre/service/transaction/placeOrder/confirm/potentialActions.js +0 -1
- package/lib/chevre/service/transaction/placeOrder/confirm.d.ts +4 -0
- package/lib/chevre/service/transaction/placeOrder/confirm.js +2 -7
- package/package.json +1 -1
|
@@ -84,7 +84,7 @@ export declare class PlaceOrderRepo {
|
|
|
84
84
|
confirmationNumber: string;
|
|
85
85
|
};
|
|
86
86
|
result: factory.transaction.IResult<factory.transactionType.PlaceOrder>;
|
|
87
|
-
potentialActions
|
|
87
|
+
potentialActions?: factory.transaction.IPotentialActions<factory.transactionType.PlaceOrder>;
|
|
88
88
|
}): Promise<void>;
|
|
89
89
|
/**
|
|
90
90
|
* 取引を中止する
|
|
@@ -402,7 +402,7 @@ class PlaceOrderRepo {
|
|
|
402
402
|
'object.orderNumber': params.object.orderNumber, // add(2026-06-27~)
|
|
403
403
|
'object.confirmationNumber': params.object.confirmationNumber, // add(2026-07-08~)
|
|
404
404
|
result: params.result, // resultを更新
|
|
405
|
-
potentialActions: params.potentialActions //
|
|
405
|
+
...((params.potentialActions !== undefined) && { potentialActions: params.potentialActions }) // support undefined(2026-07-17~)
|
|
406
406
|
}, {
|
|
407
407
|
new: true,
|
|
408
408
|
projection: { _id: 1 }
|
|
@@ -13,7 +13,6 @@ async function createPotentialActions(params, setting) {
|
|
|
13
13
|
potentialActions: {
|
|
14
14
|
order: {
|
|
15
15
|
onOrderProcessing: { sendEmailMessage: sendEmailMessageActions } // optimize(2024-06-29~)
|
|
16
|
-
// potentialActions: { sendOrder: sendOrderActionAttributes }
|
|
17
16
|
}
|
|
18
17
|
}
|
|
19
18
|
};
|
|
@@ -41,6 +41,10 @@ interface IConfirmOptions {
|
|
|
41
41
|
* 注文における最大CreditCardIF決済方法数
|
|
42
42
|
*/
|
|
43
43
|
maxNumCreditCardPaymentMethod: number;
|
|
44
|
+
/**
|
|
45
|
+
* 取引のpotentialActionsにメッセージ識別子を保管するかどうか
|
|
46
|
+
*/
|
|
47
|
+
useTransactionPotentialActions: boolean;
|
|
44
48
|
}
|
|
45
49
|
type IConfirmParams = PlaceOrderFactory.IConfirmParams;
|
|
46
50
|
interface IConfirmResult {
|
|
@@ -160,13 +160,8 @@ function confirm(params, options) {
|
|
|
160
160
|
customer,
|
|
161
161
|
seller,
|
|
162
162
|
paymentMethods,
|
|
163
|
-
// order: orderWithAcceptedOffers, // 現時点でcreateEmailMessageでorder.acceptedOffersを使用している(2024-02-06~)
|
|
164
|
-
// transaction: transaction,
|
|
165
163
|
...(params.potentialActions !== undefined) ? { potentialActions: params.potentialActions } : undefined,
|
|
166
|
-
|
|
167
|
-
},
|
|
168
|
-
// settings
|
|
169
|
-
setting);
|
|
164
|
+
}, setting);
|
|
170
165
|
// メッセージ保管(2024-04-28~)
|
|
171
166
|
await saveMessagesIfNeeded({
|
|
172
167
|
project: { id: transaction.project.id },
|
|
@@ -183,7 +178,7 @@ function confirm(params, options) {
|
|
|
183
178
|
confirmationNumber: placingOrder.confirmationNumber
|
|
184
179
|
},
|
|
185
180
|
result: result,
|
|
186
|
-
potentialActions
|
|
181
|
+
...((options.useTransactionPotentialActions) && { potentialActions }) // support undefined(2026-07-17~)
|
|
187
182
|
});
|
|
188
183
|
}
|
|
189
184
|
catch (error) {
|
package/package.json
CHANGED