@chevre/domain 24.0.0-alpha.39 → 24.0.0-alpha.40
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/action/acceptPay.d.ts +3 -0
- package/lib/chevre/repo/action/acceptPay.js +7 -1
- package/lib/chevre/repo/action.d.ts +6 -2
- package/lib/chevre/repo/action.js +3 -3
- package/lib/chevre/repo/aggregateOffer.d.ts +3 -3
- package/lib/chevre/repo/aggregateOffer.js +1 -0
- package/lib/chevre/repo/assetTransaction.d.ts +1 -1
- package/lib/chevre/repo/assetTransaction.js +1 -0
- package/lib/chevre/repo/creativeWork.d.ts +2 -2
- package/lib/chevre/repo/creativeWork.js +1 -0
- package/lib/chevre/repo/customerType.d.ts +1 -1
- package/lib/chevre/repo/customerType.js +1 -0
- package/lib/chevre/repo/eventOffer.d.ts +3 -3
- package/lib/chevre/repo/eventOffer.js +1 -0
- package/lib/chevre/repo/eventSellerMakesOffer.d.ts +3 -3
- package/lib/chevre/repo/eventSellerMakesOffer.js +1 -0
- package/lib/chevre/repo/note.d.ts +3 -3
- package/lib/chevre/repo/note.js +1 -0
- package/lib/chevre/repo/noteAboutOrder.d.ts +1 -1
- package/lib/chevre/repo/noteAboutOrder.js +1 -0
- package/lib/chevre/repo/offerCatalog.d.ts +3 -3
- package/lib/chevre/repo/offerCatalog.js +1 -0
- package/lib/chevre/repo/offerCatalogItem.d.ts +3 -3
- package/lib/chevre/repo/offerCatalogItem.js +1 -0
- package/lib/chevre/repo/place/seat.d.ts +6 -6
- package/lib/chevre/repo/place/seat.js +3 -0
- package/lib/chevre/repo/product.d.ts +3 -3
- package/lib/chevre/repo/product.js +1 -0
- package/lib/chevre/repo/productOffer.d.ts +3 -3
- package/lib/chevre/repo/productOffer.js +1 -0
- package/lib/chevre/repo/reservation.d.ts +1 -1
- package/lib/chevre/repo/reservation.js +1 -0
- package/lib/chevre/repo/sellerMakesOffer.d.ts +2 -2
- package/lib/chevre/repo/sellerMakesOffer.js +2 -0
- package/lib/chevre/repo/transaction.d.ts +1 -1
- package/lib/chevre/repo/transaction.js +1 -0
- package/lib/chevre/service/assetTransaction.d.ts +1 -1
- package/lib/chevre/service/order/placeOrder.js +1 -1
- package/lib/chevre/service/reserve/cancelReservation.js +1 -1
- package/lib/chevre/service/reserve/confirmReservation.js +1 -1
- package/lib/chevre/service/transaction/placeOrder/confirm.d.ts +3 -2
- package/lib/chevre/service/transaction/placeOrder/confirm.js +20 -9
- package/lib/chevre/service/transaction.d.ts +1 -1
- package/package.json +1 -1
|
@@ -16,6 +16,9 @@ export declare class AcceptPayActionRepo extends ActionProcessRepo<IAcceptPayAct
|
|
|
16
16
|
purpose: {
|
|
17
17
|
id: string;
|
|
18
18
|
};
|
|
19
|
+
actionStatus?: factory.actionStatusType.CompletedActionStatus;
|
|
20
|
+
limit?: number;
|
|
21
|
+
page?: number;
|
|
19
22
|
}, inclusion: IKeyOfProjection[]): Promise<IAcceptPayAction[]>;
|
|
20
23
|
/**
|
|
21
24
|
* 決済取引番号から完了済の決済採用アクションを参照する
|
|
@@ -38,13 +38,19 @@ class AcceptPayActionRepo extends actionProcess_1.ActionProcessRepo {
|
|
|
38
38
|
* 件数はlimitされない
|
|
39
39
|
*/
|
|
40
40
|
async findAcceptActionsByPurpose(params, inclusion) {
|
|
41
|
+
const { actionStatus, limit, page } = params;
|
|
41
42
|
return this.findAnyActions({
|
|
42
43
|
project: { id: { $eq: params.project.id } },
|
|
43
44
|
typeOf: { $eq: factory.actionType.AcceptAction }, // 採用アクション
|
|
44
45
|
purpose: { id: { $in: [params.purpose.id] } },
|
|
45
46
|
object: {
|
|
46
47
|
typeOf: { $eq: factory.assetTransactionType.Pay } // 対象が決済取引
|
|
47
|
-
}
|
|
48
|
+
},
|
|
49
|
+
...(typeof actionStatus === 'string')
|
|
50
|
+
? { actionStatus: { $in: [actionStatus] } }
|
|
51
|
+
: undefined,
|
|
52
|
+
...(typeof limit === 'number') ? { limit } : undefined,
|
|
53
|
+
...(typeof page === 'number') ? { page } : undefined,
|
|
48
54
|
}, inclusion);
|
|
49
55
|
// const andConditions: FilterQuery<IAcceptPayAction>[] = [
|
|
50
56
|
// { typeOf: { $eq: factory.actionType.AcceptAction } },
|
|
@@ -14,9 +14,13 @@ type IAvailableActionRecipe = IActionRecipe<Exclude<factory.recipe.RecipeCategor
|
|
|
14
14
|
*/
|
|
15
15
|
export declare class ActionRepo extends ActionProcessRepo<IAction<StartableActionType>, IAvailableActionRecipe> {
|
|
16
16
|
/**
|
|
17
|
-
*
|
|
17
|
+
* 汎用アクション検索
|
|
18
18
|
*/
|
|
19
|
-
|
|
19
|
+
findActionsByType<T extends StartableActionType>(params: factory.action.ISearchConditions & {
|
|
20
|
+
typeOf?: T | {
|
|
21
|
+
$eq?: T;
|
|
22
|
+
};
|
|
23
|
+
}, inclusion: IKeyOfProjection[]): Promise<IAction<T>[]>;
|
|
20
24
|
findPayAction(params: {
|
|
21
25
|
project: {
|
|
22
26
|
id: string;
|
|
@@ -42,9 +42,9 @@ class ActionRepo extends actionProcess_1.ActionProcessRepo {
|
|
|
42
42
|
// this.actionRecipeModel = connection.model(recipeModelName, createRecipeSchema());
|
|
43
43
|
// }
|
|
44
44
|
/**
|
|
45
|
-
*
|
|
45
|
+
* 汎用アクション検索
|
|
46
46
|
*/
|
|
47
|
-
async
|
|
47
|
+
async findActionsByType(params, inclusion) {
|
|
48
48
|
return (this.findAnyActions(params, inclusion));
|
|
49
49
|
}
|
|
50
50
|
// /**
|
|
@@ -281,7 +281,7 @@ class ActionRepo extends actionProcess_1.ActionProcessRepo {
|
|
|
281
281
|
// return doc;
|
|
282
282
|
// }
|
|
283
283
|
async findPayAction(params) {
|
|
284
|
-
const payActions = await this.
|
|
284
|
+
const payActions = await this.findActionsByType({
|
|
285
285
|
limit: 1,
|
|
286
286
|
page: 1,
|
|
287
287
|
actionStatus: (Array.isArray(params.actionStatus?.$in))
|
|
@@ -84,11 +84,11 @@ export declare class AggregateOfferRepo {
|
|
|
84
84
|
*/
|
|
85
85
|
productType: factory.product.ProductType;
|
|
86
86
|
}): Promise<{
|
|
87
|
-
bulkWriteResult
|
|
88
|
-
modifiedOffers
|
|
87
|
+
bulkWriteResult?: BulkWriteResult;
|
|
88
|
+
modifiedOffers?: {
|
|
89
89
|
id: string;
|
|
90
90
|
}[];
|
|
91
|
-
}
|
|
91
|
+
}>;
|
|
92
92
|
/**
|
|
93
93
|
* sskts専用オファー保管
|
|
94
94
|
*/
|
|
@@ -150,7 +150,7 @@ export declare class AssetTransactionRepo {
|
|
|
150
150
|
expires: {
|
|
151
151
|
$lt: Date;
|
|
152
152
|
};
|
|
153
|
-
}): Promise<Pick<factory.assetTransaction.ITransaction<factory.assetTransactionType>, 'id' | 'typeOf'> |
|
|
153
|
+
}): Promise<Pick<factory.assetTransaction.ITransaction<factory.assetTransactionType>, 'id' | 'typeOf'> | undefined>;
|
|
154
154
|
/**
|
|
155
155
|
* 取引を期限切れにする
|
|
156
156
|
*/
|
|
@@ -32,11 +32,11 @@ export declare class EventOfferRepo {
|
|
|
32
32
|
*/
|
|
33
33
|
update: boolean;
|
|
34
34
|
}): Promise<{
|
|
35
|
-
bulkWriteResult
|
|
36
|
-
modifiedProductOffers
|
|
35
|
+
bulkWriteResult?: BulkWriteResult;
|
|
36
|
+
modifiedProductOffers?: {
|
|
37
37
|
id: string;
|
|
38
38
|
}[];
|
|
39
|
-
}
|
|
39
|
+
}>;
|
|
40
40
|
/**
|
|
41
41
|
* 販売者の提供するイベントオファーを削除する
|
|
42
42
|
*/
|
|
@@ -29,11 +29,11 @@ export declare class NoteRepo {
|
|
|
29
29
|
*/
|
|
30
30
|
update: boolean;
|
|
31
31
|
}): Promise<{
|
|
32
|
-
bulkWriteResult
|
|
33
|
-
modifiedNotes
|
|
32
|
+
bulkWriteResult?: BulkWriteResult;
|
|
33
|
+
modifiedNotes?: {
|
|
34
34
|
id: string;
|
|
35
35
|
}[];
|
|
36
|
-
}
|
|
36
|
+
}>;
|
|
37
37
|
/**
|
|
38
38
|
* 主題リソースから全メモを削除する
|
|
39
39
|
*/
|
package/lib/chevre/repo/note.js
CHANGED
|
@@ -21,7 +21,7 @@ export declare class NoteAboutOrderRepo {
|
|
|
21
21
|
*/
|
|
22
22
|
upsertOrderNoteByIdentifier(params: Pick<INoteAboutOrder, 'about' | 'creator' | 'identifier' | 'project' | 'provider' | 'text' | 'version'>[], options: {
|
|
23
23
|
overwrite: boolean;
|
|
24
|
-
}): Promise<BulkWriteResult |
|
|
24
|
+
}): Promise<BulkWriteResult | undefined>;
|
|
25
25
|
updateById(params: {
|
|
26
26
|
id: string;
|
|
27
27
|
attributes: Pick<INoteAboutOrder, 'text' | 'editor'>;
|
|
@@ -49,11 +49,11 @@ export declare class OfferCatalogRepo {
|
|
|
49
49
|
*/
|
|
50
50
|
itemListElementType: factory.offerCatalog.IItemListElement['typeOf'];
|
|
51
51
|
}): Promise<{
|
|
52
|
-
bulkWriteResult
|
|
53
|
-
modifiedCatalogs
|
|
52
|
+
bulkWriteResult?: BulkWriteResult;
|
|
53
|
+
modifiedCatalogs?: {
|
|
54
54
|
id: string;
|
|
55
55
|
}[];
|
|
56
|
-
}
|
|
56
|
+
}>;
|
|
57
57
|
/**
|
|
58
58
|
* 同期日時を更新する
|
|
59
59
|
*/
|
|
@@ -42,11 +42,11 @@ export declare class OfferCatalogItemRepo {
|
|
|
42
42
|
*/
|
|
43
43
|
productType: factory.product.ProductType;
|
|
44
44
|
}): Promise<{
|
|
45
|
-
bulkWriteResult
|
|
46
|
-
modifiedCatalogs
|
|
45
|
+
bulkWriteResult?: BulkWriteResult;
|
|
46
|
+
modifiedCatalogs?: {
|
|
47
47
|
id: string;
|
|
48
48
|
}[];
|
|
49
|
-
}
|
|
49
|
+
}>;
|
|
50
50
|
/**
|
|
51
51
|
* 同期日時を更新する
|
|
52
52
|
*/
|
|
@@ -47,8 +47,8 @@ export declare class SeatRepo {
|
|
|
47
47
|
addSeatsByBranchCodeIfNotExist(params: {
|
|
48
48
|
$set: ICreatingSeat;
|
|
49
49
|
}[], options: IUpdateOptions): Promise<{
|
|
50
|
-
bulkWriteResult
|
|
51
|
-
}
|
|
50
|
+
bulkWriteResult?: BulkWriteResult;
|
|
51
|
+
}>;
|
|
52
52
|
/**
|
|
53
53
|
* コードをキーにして冪等編集
|
|
54
54
|
*/
|
|
@@ -58,8 +58,8 @@ export declare class SeatRepo {
|
|
|
58
58
|
[key in keyof ICreatingSeat]?: 1;
|
|
59
59
|
};
|
|
60
60
|
}[], options: IUpdateOptions): Promise<{
|
|
61
|
-
bulkWriteResult
|
|
62
|
-
}
|
|
61
|
+
bulkWriteResult?: BulkWriteResult;
|
|
62
|
+
}>;
|
|
63
63
|
updateSeatByBranchCode(seat: ICreatingSeat, $unset: any, options: IUpdateOptions): Promise<IUpdateSeatResult>;
|
|
64
64
|
searchSeats(params: factory.place.seat.ISearchConditions): Promise<factory.place.seat.IPlace[]>;
|
|
65
65
|
projectSeatsByScreeningRoom(params: Pick<factory.place.seat.ISearchConditions, '$projection' | 'additionalProperty' | 'branchCode' | 'seatingType' | 'name' | 'limit' | 'page'> & {
|
|
@@ -161,8 +161,8 @@ export declare class SeatRepo {
|
|
|
161
161
|
*/
|
|
162
162
|
branchCode: string;
|
|
163
163
|
}[], options: IUpdateOptions): Promise<{
|
|
164
|
-
bulkWriteResult
|
|
165
|
-
}
|
|
164
|
+
bulkWriteResult?: BulkWriteResult;
|
|
165
|
+
}>;
|
|
166
166
|
deleteSeatByBranchCode(seat: {
|
|
167
167
|
/**
|
|
168
168
|
* 座席コード
|
|
@@ -356,6 +356,7 @@ class SeatRepo {
|
|
|
356
356
|
const bulkWriteResult = await this.placeModel.bulkWrite(bulkWriteOps, { ordered: false });
|
|
357
357
|
return { bulkWriteResult };
|
|
358
358
|
}
|
|
359
|
+
return {};
|
|
359
360
|
}
|
|
360
361
|
/**
|
|
361
362
|
* コードをキーにして冪等編集
|
|
@@ -432,6 +433,7 @@ class SeatRepo {
|
|
|
432
433
|
const bulkWriteResult = await this.placeModel.bulkWrite(bulkWriteOps, { ordered: false });
|
|
433
434
|
return { bulkWriteResult };
|
|
434
435
|
}
|
|
436
|
+
return {};
|
|
435
437
|
}
|
|
436
438
|
async updateSeatByBranchCode(seat, $unset, options) {
|
|
437
439
|
const { project, parentOrganization, movieTheaterCode, roomCode, sectionCode } = options;
|
|
@@ -788,6 +790,7 @@ class SeatRepo {
|
|
|
788
790
|
const bulkWriteResult = await this.placeModel.bulkWrite(bulkWriteOps, { ordered: false });
|
|
789
791
|
return { bulkWriteResult };
|
|
790
792
|
}
|
|
793
|
+
return {};
|
|
791
794
|
}
|
|
792
795
|
async deleteSeatByBranchCode(seat, options) {
|
|
793
796
|
const { project, parentOrganization, movieTheaterCode, roomCode, sectionCode } = options;
|
|
@@ -69,11 +69,11 @@ export declare class ProductRepo {
|
|
|
69
69
|
[key in IUnsetKey]?: 1;
|
|
70
70
|
};
|
|
71
71
|
}[]): Promise<{
|
|
72
|
-
bulkWriteResult
|
|
73
|
-
modifiedProducts
|
|
72
|
+
bulkWriteResult?: BulkWriteResult;
|
|
73
|
+
modifiedProducts?: {
|
|
74
74
|
id: string;
|
|
75
75
|
}[];
|
|
76
|
-
}
|
|
76
|
+
}>;
|
|
77
77
|
/**
|
|
78
78
|
* プロダクトIDからavailableChannelを取得する
|
|
79
79
|
*/
|
|
@@ -32,11 +32,11 @@ export declare class ProductOfferRepo {
|
|
|
32
32
|
*/
|
|
33
33
|
update: boolean;
|
|
34
34
|
}): Promise<{
|
|
35
|
-
bulkWriteResult
|
|
36
|
-
modifiedProductOffers
|
|
35
|
+
bulkWriteResult?: BulkWriteResult;
|
|
36
|
+
modifiedProductOffers?: {
|
|
37
37
|
id: string;
|
|
38
38
|
}[];
|
|
39
|
-
}
|
|
39
|
+
}>;
|
|
40
40
|
/**
|
|
41
41
|
* 販売者の提供するプロダクトオファーを削除する
|
|
42
42
|
*/
|
|
@@ -49,7 +49,7 @@ export declare class ReservationRepo {
|
|
|
49
49
|
reservationNumber: string;
|
|
50
50
|
underName?: factory.reservation.IUnderName<factory.reservationType.EventReservation>;
|
|
51
51
|
broker?: factory.reservation.IBroker<factory.reservationType>;
|
|
52
|
-
}): Promise<BulkWriteResult |
|
|
52
|
+
}): Promise<BulkWriteResult | undefined>;
|
|
53
53
|
/**
|
|
54
54
|
* 予約取消
|
|
55
55
|
*/
|
|
@@ -51,7 +51,7 @@ export declare class SellerMakesOfferRepo {
|
|
|
51
51
|
id: string;
|
|
52
52
|
};
|
|
53
53
|
}[];
|
|
54
|
-
}): Promise<BulkWriteResult |
|
|
54
|
+
}): Promise<BulkWriteResult | undefined>;
|
|
55
55
|
/**
|
|
56
56
|
* 販売者とアプリケーションに対してオファーが存在すれば削除する
|
|
57
57
|
*/
|
|
@@ -67,6 +67,6 @@ export declare class SellerMakesOfferRepo {
|
|
|
67
67
|
id: string;
|
|
68
68
|
};
|
|
69
69
|
}[];
|
|
70
|
-
}): Promise<BulkWriteResult |
|
|
70
|
+
}): Promise<BulkWriteResult | undefined>;
|
|
71
71
|
}
|
|
72
72
|
export {};
|
|
@@ -112,6 +112,7 @@ class SellerMakesOfferRepo {
|
|
|
112
112
|
if (bulkWriteOps.length > 0) {
|
|
113
113
|
return this.sellerModel.bulkWrite(bulkWriteOps, { ordered: false });
|
|
114
114
|
}
|
|
115
|
+
return;
|
|
115
116
|
}
|
|
116
117
|
/**
|
|
117
118
|
* 販売者とアプリケーションに対してオファーが存在すれば削除する
|
|
@@ -141,6 +142,7 @@ class SellerMakesOfferRepo {
|
|
|
141
142
|
if (bulkWriteOps.length > 0) {
|
|
142
143
|
return this.sellerModel.bulkWrite(bulkWriteOps, { ordered: false });
|
|
143
144
|
}
|
|
145
|
+
return;
|
|
144
146
|
}
|
|
145
147
|
}
|
|
146
148
|
exports.SellerMakesOfferRepo = SellerMakesOfferRepo;
|
|
@@ -99,7 +99,7 @@ export declare class TransactionRepo {
|
|
|
99
99
|
expires: {
|
|
100
100
|
$lt: Date;
|
|
101
101
|
};
|
|
102
|
-
}): Promise<Pick<factory.transaction.ITransaction<factory.transactionType>, 'id' | 'typeOf'> |
|
|
102
|
+
}): Promise<Pick<factory.transaction.ITransaction<factory.transactionType>, 'id' | 'typeOf'> | undefined>;
|
|
103
103
|
/**
|
|
104
104
|
* 取引を期限切れにする
|
|
105
105
|
*/
|
|
@@ -39,4 +39,4 @@ export declare function exportOneTransactionTasksIfExists(params: {
|
|
|
39
39
|
}): (repos: {
|
|
40
40
|
task: TaskRepo;
|
|
41
41
|
assetTransaction: AssetTransactionRepo;
|
|
42
|
-
}) => Promise<Pick<factory.assetTransaction.ITransaction<factory.assetTransactionType>, "id" | "typeOf"> |
|
|
42
|
+
}) => Promise<Pick<factory.assetTransaction.ITransaction<factory.assetTransactionType>, "id" | "typeOf"> | undefined>;
|
|
@@ -77,7 +77,7 @@ function placeOrder(params) {
|
|
|
77
77
|
typeOf: factory.actionType.OrderAction
|
|
78
78
|
};
|
|
79
79
|
// 冪等性を担保(2023-05-31~)
|
|
80
|
-
const completedActions = await repos.action.
|
|
80
|
+
const completedActions = await repos.action.findActionsByType({
|
|
81
81
|
limit: 1,
|
|
82
82
|
page: 1,
|
|
83
83
|
actionStatus: { $in: [factory.actionStatusType.CompletedActionStatus] },
|
|
@@ -75,7 +75,7 @@ function cancelPengindIfNotYet(params) {
|
|
|
75
75
|
let actionId;
|
|
76
76
|
const actionAttributes = (0, factory_1.createCancelPendingReservationAction)({ transaction: reserveTransaction });
|
|
77
77
|
// 冪等性を担保(2023-06-05~)
|
|
78
|
-
const completedActions = await repos.action.
|
|
78
|
+
const completedActions = await repos.action.findActionsByType({
|
|
79
79
|
limit: 1,
|
|
80
80
|
page: 1,
|
|
81
81
|
actionStatus: { $in: [factory.actionStatusType.CompletedActionStatus] },
|
|
@@ -134,7 +134,7 @@ params, options) {
|
|
|
134
134
|
const actionAttributes = reserveTransaction2action({ transaction: reserveTransaction });
|
|
135
135
|
// 冪等性を担保(2023-05-31~)
|
|
136
136
|
debug('searching completed reserveAction... byTask:', options?.byTask, 'reservationNumber:', reservationPackage.reservationNumber);
|
|
137
|
-
const completedActions = await repos.action.
|
|
137
|
+
const completedActions = await repos.action.findActionsByType({
|
|
138
138
|
limit: 1,
|
|
139
139
|
page: 1,
|
|
140
140
|
actionStatus: { $in: [factory.actionStatusType.CompletedActionStatus] },
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { AcceptPayActionRepo } from '../../../repo/action/acceptPay';
|
|
2
2
|
import type { AuthorizePaymentMethodActionRepo } from '../../../repo/action/authorizePaymentMethod';
|
|
3
3
|
import type { AuthorizeOfferActionRepo } from '../../../repo/action/authorizeOffer';
|
|
4
4
|
import type { AssetTransactionRepo } from '../../../repo/assetTransaction';
|
|
@@ -14,7 +14,8 @@ import type { PlaceOrderRepo } from '../../../repo/transaction/placeOrder';
|
|
|
14
14
|
import * as factory from '../../../factory';
|
|
15
15
|
import { placeOrder as PlaceOrderFactory } from '../../../factory/transaction';
|
|
16
16
|
interface IConfirmOperationRepos {
|
|
17
|
-
action
|
|
17
|
+
action?: never;
|
|
18
|
+
acceptPayAction: AcceptPayActionRepo;
|
|
18
19
|
authorizePaymentMethodAction: AuthorizePaymentMethodActionRepo;
|
|
19
20
|
authorizeOfferAction: AuthorizeOfferActionRepo;
|
|
20
21
|
assetTransaction: AssetTransactionRepo;
|
|
@@ -65,6 +65,7 @@ function processTransactionNotInProgress(transaction) {
|
|
|
65
65
|
else if (transaction.status === factory.transactionStatusType.Canceled) {
|
|
66
66
|
throw new factory.errors.Argument('transactionId', 'Transaction already canceled');
|
|
67
67
|
}
|
|
68
|
+
return;
|
|
68
69
|
};
|
|
69
70
|
}
|
|
70
71
|
/**
|
|
@@ -397,16 +398,26 @@ function createResult(params, options) {
|
|
|
397
398
|
}
|
|
398
399
|
function searchAcceptPayActions(params) {
|
|
399
400
|
return async (repos) => {
|
|
400
|
-
let acceptPayActions = await repos.action.search(
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
401
|
+
// let acceptPayActions = <IAcceptPayAction[]>await repos.action.search(
|
|
402
|
+
// {
|
|
403
|
+
// project: { id: { $eq: params.project.id } },
|
|
404
|
+
// typeOf: { $eq: factory.actionType.AcceptAction },
|
|
405
|
+
// actionStatus: { $in: [factory.actionStatusType.CompletedActionStatus] },
|
|
406
|
+
// purpose: {
|
|
407
|
+
// id: { $in: [params.id] },
|
|
408
|
+
// typeOf: { $in: [factory.transactionType.PlaceOrder] }
|
|
409
|
+
// },
|
|
410
|
+
// object: {
|
|
411
|
+
// typeOf: { $eq: factory.assetTransactionType.Pay }
|
|
412
|
+
// }
|
|
413
|
+
// },
|
|
414
|
+
// ['object', 'endDate', 'result']
|
|
415
|
+
// );
|
|
416
|
+
let acceptPayActions = await repos.acceptPayAction.findAcceptActionsByPurpose({
|
|
417
|
+
project: { id: params.project.id },
|
|
418
|
+
actionStatus: factory.actionStatusType.CompletedActionStatus,
|
|
404
419
|
purpose: {
|
|
405
|
-
id:
|
|
406
|
-
typeOf: { $in: [factory.transactionType.PlaceOrder] }
|
|
407
|
-
},
|
|
408
|
-
object: {
|
|
409
|
-
typeOf: { $eq: factory.assetTransactionType.Pay }
|
|
420
|
+
id: params.id
|
|
410
421
|
}
|
|
411
422
|
}, ['object', 'endDate', 'result']);
|
|
412
423
|
// 万が一このプロセス中に他処理が発生してもそれらを無視するように、endDateでフィルタリング
|
|
@@ -48,4 +48,4 @@ export declare function exportOneTransactionTasksIfExists(params: {
|
|
|
48
48
|
endDate?: factory.sortType;
|
|
49
49
|
startDate?: factory.sortType;
|
|
50
50
|
};
|
|
51
|
-
}): IExportTasksOperation<Pick<factory.transaction.ITransaction<factory.transactionType>, 'id' | 'typeOf'> |
|
|
51
|
+
}): IExportTasksOperation<Pick<factory.transaction.ITransaction<factory.transactionType>, 'id' | 'typeOf'> | undefined>;
|
package/package.json
CHANGED