@chevre/domain 24.0.0-alpha.20 → 24.0.0-alpha.21
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.
|
@@ -4,6 +4,57 @@ import { ActionProcessRepo, IActionRecipe } from './actionProcess';
|
|
|
4
4
|
export type IMinimizedPurchaseNumberAuthResult = Pick<factory.action.check.paymentMethod.movieTicket.IPurchaseNumberAuthResult, 'mkknmiNumSum' | 'resultInfo' | 'ykknmiNumSum'> & {
|
|
5
5
|
knyknrNoInfoOut: Omit<factory.action.check.paymentMethod.movieTicket.IPurchaseNumberInfo, 'ykknInfo' | 'mkknInfo'>[] | null;
|
|
6
6
|
};
|
|
7
|
+
/**
|
|
8
|
+
* アクションIDで参照、あるいは、決済カードコード+イベントIDで参照
|
|
9
|
+
*/
|
|
10
|
+
type IFindCompletedCheckActionsParams = ({
|
|
11
|
+
/**
|
|
12
|
+
* アクションID
|
|
13
|
+
*/
|
|
14
|
+
id?: string;
|
|
15
|
+
purpose?: {
|
|
16
|
+
/**
|
|
17
|
+
* 注文取引ID
|
|
18
|
+
*/
|
|
19
|
+
id?: string;
|
|
20
|
+
};
|
|
21
|
+
object?: never;
|
|
22
|
+
sort?: never;
|
|
23
|
+
}) | (Pick<factory.action.ISearchConditions, 'sort'> & {
|
|
24
|
+
purpose?: {
|
|
25
|
+
/**
|
|
26
|
+
* 注文取引ID
|
|
27
|
+
*/
|
|
28
|
+
id?: string;
|
|
29
|
+
};
|
|
30
|
+
object?: {
|
|
31
|
+
/**
|
|
32
|
+
* 決済サービス
|
|
33
|
+
*/
|
|
34
|
+
id?: {
|
|
35
|
+
$eq?: string;
|
|
36
|
+
};
|
|
37
|
+
movieTickets?: {
|
|
38
|
+
identifier?: {
|
|
39
|
+
$eq?: string;
|
|
40
|
+
};
|
|
41
|
+
serviceOutput?: {
|
|
42
|
+
reservationFor?: {
|
|
43
|
+
id?: {
|
|
44
|
+
$eq?: string;
|
|
45
|
+
};
|
|
46
|
+
};
|
|
47
|
+
};
|
|
48
|
+
};
|
|
49
|
+
typeOf?: {
|
|
50
|
+
$eq?: factory.service.paymentService.PaymentServiceType.MovieTicket;
|
|
51
|
+
};
|
|
52
|
+
};
|
|
53
|
+
/**
|
|
54
|
+
* アクションID
|
|
55
|
+
*/
|
|
56
|
+
id?: never;
|
|
57
|
+
});
|
|
7
58
|
export type ICheckMovieTicketAction = factory.action.check.paymentMethod.movieTicket.IAction;
|
|
8
59
|
/**
|
|
9
60
|
* 決済カード認証アクションリポジトリ
|
|
@@ -55,39 +106,6 @@ export declare class CheckMovieTicketActionRepo extends ActionProcessRepo<ICheck
|
|
|
55
106
|
/**
|
|
56
107
|
* 認証済アクション参照
|
|
57
108
|
*/
|
|
58
|
-
findCompletedCheckActions(params: Pick<
|
|
59
|
-
/**
|
|
60
|
-
* アクションID
|
|
61
|
-
*/
|
|
62
|
-
id?: string;
|
|
63
|
-
purpose?: {
|
|
64
|
-
/**
|
|
65
|
-
* 注文取引ID
|
|
66
|
-
*/
|
|
67
|
-
id?: string;
|
|
68
|
-
};
|
|
69
|
-
object?: {
|
|
70
|
-
/**
|
|
71
|
-
* 決済サービス
|
|
72
|
-
*/
|
|
73
|
-
id?: {
|
|
74
|
-
$eq?: string;
|
|
75
|
-
};
|
|
76
|
-
movieTickets?: {
|
|
77
|
-
identifier?: {
|
|
78
|
-
$eq?: string;
|
|
79
|
-
};
|
|
80
|
-
serviceOutput?: {
|
|
81
|
-
reservationFor?: {
|
|
82
|
-
id?: {
|
|
83
|
-
$eq?: string;
|
|
84
|
-
};
|
|
85
|
-
};
|
|
86
|
-
};
|
|
87
|
-
};
|
|
88
|
-
typeOf?: {
|
|
89
|
-
$eq?: factory.service.paymentService.PaymentServiceType.MovieTicket;
|
|
90
|
-
};
|
|
91
|
-
};
|
|
92
|
-
}): Promise<Pick<ICheckMovieTicketAction, 'id'>[]>;
|
|
109
|
+
findCompletedCheckActions(params: IFindCompletedCheckActionsParams): Promise<Pick<ICheckMovieTicketAction, 'id'>[]>;
|
|
93
110
|
}
|
|
111
|
+
export {};
|
|
@@ -193,7 +193,7 @@ class CheckMovieTicketActionRepo extends actionProcess_1.ActionProcessRepo {
|
|
|
193
193
|
// const explainResult = await (<any>query).explain();
|
|
194
194
|
// console.log(explainResult[0].executionStats.allPlansExecution.map((e: any) => e.executionStages.inputStage));
|
|
195
195
|
return query.setOptions({ maxTimeMS: settings_1.MONGO_MAX_TIME_MS })
|
|
196
|
-
.lean()
|
|
196
|
+
.lean()
|
|
197
197
|
.exec();
|
|
198
198
|
}
|
|
199
199
|
}
|
|
@@ -173,6 +173,7 @@ function checkByIdentifierIfNotYet(params) {
|
|
|
173
173
|
...(typeof placeOrderId === 'string') ? { purpose: { id: placeOrderId } } : undefined
|
|
174
174
|
})).shift();
|
|
175
175
|
}
|
|
176
|
+
debug('checkByIdentifierIfNotYet: alreadyCheckedAction:', JSON.stringify(alreadyCheckedAction), 'params:', JSON.stringify(params));
|
|
176
177
|
if (alreadyCheckedAction !== undefined) {
|
|
177
178
|
const recipe = await repos.checkMovieTicketAction.findRecipeByAction({
|
|
178
179
|
project: { id: params.screeningEvent.project.id },
|
|
@@ -13,6 +13,12 @@ import type { SellerPaymentAcceptedRepo } from '../../../repo/sellerPaymentAccep
|
|
|
13
13
|
import type { TaskRepo } from '../../../repo/task';
|
|
14
14
|
import * as factory from '../../../factory';
|
|
15
15
|
import { Settings } from '../../../settings';
|
|
16
|
+
interface IPayTask2payActionAttributesRepos {
|
|
17
|
+
action: ActionRepo;
|
|
18
|
+
acceptedOffer: AcceptedOfferRepo;
|
|
19
|
+
assetTransaction: AssetTransactionRepo;
|
|
20
|
+
order: OrderRepo;
|
|
21
|
+
}
|
|
16
22
|
declare function payTask2payActionAttributes(params: factory.task.pay.IData & {
|
|
17
23
|
sameAs?: {
|
|
18
24
|
/**
|
|
@@ -21,16 +27,8 @@ declare function payTask2payActionAttributes(params: factory.task.pay.IData & {
|
|
|
21
27
|
id: string;
|
|
22
28
|
typeOf: 'Task';
|
|
23
29
|
};
|
|
24
|
-
}): (repos:
|
|
25
|
-
|
|
26
|
-
acceptedOffer: AcceptedOfferRepo;
|
|
27
|
-
assetTransaction: AssetTransactionRepo;
|
|
28
|
-
order: OrderRepo;
|
|
29
|
-
}) => Promise<factory.action.trade.pay.IAttributes>;
|
|
30
|
-
/**
|
|
31
|
-
* 決済確定
|
|
32
|
-
*/
|
|
33
|
-
declare function payByTask(payActionAttributes: factory.action.trade.pay.IAttributes): (repos: {
|
|
30
|
+
}): (repos: IPayTask2payActionAttributesRepos) => Promise<factory.action.trade.pay.IAttributes>;
|
|
31
|
+
interface IPayByTaskRepos {
|
|
34
32
|
acceptedOffer: AcceptedOfferRepo;
|
|
35
33
|
action: ActionRepo;
|
|
36
34
|
accountingReport: AccountingReportRepo;
|
|
@@ -44,5 +42,9 @@ declare function payByTask(payActionAttributes: factory.action.trade.pay.IAttrib
|
|
|
44
42
|
product: ProductRepo;
|
|
45
43
|
project: ProjectRepo;
|
|
46
44
|
task: TaskRepo;
|
|
47
|
-
}
|
|
48
|
-
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* 決済確定
|
|
48
|
+
*/
|
|
49
|
+
declare function payByTask(payActionAttributes: factory.action.trade.pay.IAttributes): (repos: IPayByTaskRepos, settings: Settings) => Promise<void>;
|
|
50
|
+
export { IPayTask2payActionAttributesRepos, IPayByTaskRepos, payByTask, payTask2payActionAttributes };
|
package/package.json
CHANGED