@chevre/domain 21.2.0-alpha.2 → 21.2.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.
- package/example/src/chevre/aggregateEventReservation.ts +1 -1
- package/example/src/chevre/countDelayedTasks.ts +17 -0
- package/example/src/chevre/countDelayedTransactions.ts +60 -0
- package/example/src/chevre/countMoneyTransferTransaction.ts +36 -0
- package/example/src/chevre/createManyEventsIfNotExist.ts +4 -1
- package/example/src/chevre/lockStockHolder.ts +48 -0
- package/example/src/chevre/migrateOrderAdditionalProperties.ts +85 -0
- package/example/src/chevre/migrateStockHolderKeys.ts +89 -0
- package/example/src/chevre/processReserve.ts +2 -2
- package/example/src/chevre/searchEventSeats.ts +42 -0
- package/example/src/chevre/transaction/findCreditCard.ts +1 -1
- package/example/src/chevre/transaction/makeExpired.ts +18 -0
- package/example/src/chevre/transaction/orderMembershipService.ts +1 -1
- package/example/src/chevre/transaction/startExportTasks.ts +19 -0
- package/example/src/chevre/updateTransaction.ts +1 -1
- package/lib/chevre/eventEmitter/task.d.ts +18 -0
- package/lib/chevre/eventEmitter/task.js +28 -0
- package/lib/chevre/eventEmitter/transaction.d.ts +21 -0
- package/lib/chevre/eventEmitter/transaction.js +28 -0
- package/lib/chevre/eventEmitter.d.ts +3 -0
- package/lib/chevre/eventEmitter.js +7 -0
- package/lib/chevre/index.d.ts +3 -2
- package/lib/chevre/index.js +5 -3
- package/lib/chevre/repo/account.js +0 -4
- package/lib/chevre/repo/accountTitle.js +0 -4
- package/lib/chevre/repo/accountTransaction.d.ts +0 -10
- package/lib/chevre/repo/accountTransaction.js +0 -57
- package/lib/chevre/repo/accountingReport.js +0 -4
- package/lib/chevre/repo/action.js +0 -4
- package/lib/chevre/repo/additionalProperty.js +0 -4
- package/lib/chevre/repo/aggregation.js +0 -4
- package/lib/chevre/repo/assetTransaction.d.ts +4 -6
- package/lib/chevre/repo/assetTransaction.js +69 -45
- package/lib/chevre/repo/categoryCode.js +0 -4
- package/lib/chevre/repo/code.js +0 -4
- package/lib/chevre/repo/comment.js +0 -4
- package/lib/chevre/repo/confirmationNumber.js +1 -1
- package/lib/chevre/repo/creativeWork.d.ts +1 -3
- package/lib/chevre/repo/creativeWork.js +0 -4
- package/lib/chevre/repo/customer.js +0 -4
- package/lib/chevre/repo/emailMessage.d.ts +1 -27
- package/lib/chevre/repo/emailMessage.js +0 -4
- package/lib/chevre/repo/event.d.ts +5 -1
- package/lib/chevre/repo/event.js +0 -4
- package/lib/chevre/repo/member.js +0 -4
- package/lib/chevre/repo/merchantReturnPolicy.d.ts +1 -3
- package/lib/chevre/repo/merchantReturnPolicy.js +0 -4
- package/lib/chevre/repo/mongoose/schemas/account.d.ts +5 -2
- package/lib/chevre/repo/mongoose/schemas/account.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/accountTitle.d.ts +30 -3
- package/lib/chevre/repo/mongoose/schemas/accountTitle.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/accountTransaction.d.ts +32 -3
- package/lib/chevre/repo/mongoose/schemas/accountTransaction.js +2 -1
- package/lib/chevre/repo/mongoose/schemas/accountingReport.d.ts +14 -3
- package/lib/chevre/repo/mongoose/schemas/accountingReport.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/action.d.ts +44 -3
- package/lib/chevre/repo/mongoose/schemas/action.js +2 -1
- package/lib/chevre/repo/mongoose/schemas/additionalProperty.d.ts +18 -3
- package/lib/chevre/repo/mongoose/schemas/additionalProperty.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/aggregation.d.ts +5 -2
- package/lib/chevre/repo/mongoose/schemas/aggregation.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/assetTransaction.d.ts +42 -3
- package/lib/chevre/repo/mongoose/schemas/assetTransaction.js +2 -1
- package/lib/chevre/repo/mongoose/schemas/authorization.d.ts +20 -3
- package/lib/chevre/repo/mongoose/schemas/authorization.js +2 -1
- package/lib/chevre/repo/mongoose/schemas/categoryCode.d.ts +26 -3
- package/lib/chevre/repo/mongoose/schemas/categoryCode.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/comments.d.ts +28 -3
- package/lib/chevre/repo/mongoose/schemas/comments.js +2 -1
- package/lib/chevre/repo/mongoose/schemas/creativeWork.d.ts +44 -3
- package/lib/chevre/repo/mongoose/schemas/creativeWork.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/customer.d.ts +26 -3
- package/lib/chevre/repo/mongoose/schemas/customer.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/emailMessages.d.ts +22 -3
- package/lib/chevre/repo/mongoose/schemas/emailMessages.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/event.d.ts +72 -3
- package/lib/chevre/repo/mongoose/schemas/event.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/member.d.ts +14 -3
- package/lib/chevre/repo/mongoose/schemas/member.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/merchantReturnPolicy.d.ts +22 -3
- package/lib/chevre/repo/mongoose/schemas/merchantReturnPolicy.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/offer.d.ts +66 -3
- package/lib/chevre/repo/mongoose/schemas/offer.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/offerCatalog.d.ts +28 -3
- package/lib/chevre/repo/mongoose/schemas/offerCatalog.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/order.d.ts +52 -3
- package/lib/chevre/repo/mongoose/schemas/order.js +2 -1
- package/lib/chevre/repo/mongoose/schemas/ownershipInfo.d.ts +26 -3
- package/lib/chevre/repo/mongoose/schemas/ownershipInfo.js +2 -1
- package/lib/chevre/repo/mongoose/schemas/place.d.ts +50 -3
- package/lib/chevre/repo/mongoose/schemas/place.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/priceSpecification.d.ts +30 -3
- package/lib/chevre/repo/mongoose/schemas/priceSpecification.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/product.d.ts +32 -3
- package/lib/chevre/repo/mongoose/schemas/product.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/project.d.ts +24 -3
- package/lib/chevre/repo/mongoose/schemas/project.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/reservation.d.ts +62 -3
- package/lib/chevre/repo/mongoose/schemas/reservation.js +2 -1
- package/lib/chevre/repo/mongoose/schemas/role.d.ts +12 -3
- package/lib/chevre/repo/mongoose/schemas/role.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/seller.d.ts +32 -3
- package/lib/chevre/repo/mongoose/schemas/seller.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/serviceOutput.d.ts +12 -3
- package/lib/chevre/repo/mongoose/schemas/serviceOutput.js +2 -1
- package/lib/chevre/repo/mongoose/schemas/task.d.ts +31 -3
- package/lib/chevre/repo/mongoose/schemas/task.js +3 -1
- package/lib/chevre/repo/mongoose/schemas/telemetry.d.ts +22 -3
- package/lib/chevre/repo/mongoose/schemas/telemetry.js +1 -0
- package/lib/chevre/repo/mongoose/schemas/transaction.d.ts +38 -3
- package/lib/chevre/repo/mongoose/schemas/transaction.js +2 -1
- package/lib/chevre/repo/mongoose/schemas/trip.d.ts +12 -3
- package/lib/chevre/repo/mongoose/schemas/trip.js +1 -0
- package/lib/chevre/repo/offer.js +0 -5
- package/lib/chevre/repo/offerCatalog.js +0 -4
- package/lib/chevre/repo/order.d.ts +25 -0
- package/lib/chevre/repo/order.js +5 -4
- package/lib/chevre/repo/orderNumber.d.ts +0 -1
- package/lib/chevre/repo/orderNumber.js +2 -12
- package/lib/chevre/repo/ownershipInfo.js +0 -4
- package/lib/chevre/repo/permit.js +0 -4
- package/lib/chevre/repo/place.d.ts +5 -1
- package/lib/chevre/repo/place.js +1 -10
- package/lib/chevre/repo/priceSpecification.js +0 -4
- package/lib/chevre/repo/product.js +0 -4
- package/lib/chevre/repo/project.js +0 -4
- package/lib/chevre/repo/rateLimit/offer.d.ts +3 -2
- package/lib/chevre/repo/rateLimit/offer.js +14 -14
- package/lib/chevre/repo/reservation.js +0 -4
- package/lib/chevre/repo/role.js +0 -4
- package/lib/chevre/repo/seller.js +0 -4
- package/lib/chevre/repo/serviceOutput.js +0 -4
- package/lib/chevre/repo/serviceOutputIdentifier.d.ts +2 -1
- package/lib/chevre/repo/serviceOutputIdentifier.js +14 -15
- package/lib/chevre/repo/{itemAvailability/screeningEvent.d.ts → stockHolder.d.ts} +5 -6
- package/lib/chevre/repo/stockHolder.js +273 -0
- package/lib/chevre/repo/task.d.ts +17 -2
- package/lib/chevre/repo/task.js +61 -10
- package/lib/chevre/repo/telemetry.js +0 -4
- package/lib/chevre/repo/transaction.d.ts +3 -2
- package/lib/chevre/repo/transaction.js +116 -54
- package/lib/chevre/repo/transactionNumber.d.ts +2 -1
- package/lib/chevre/repo/transactionNumber.js +14 -15
- package/lib/chevre/repo/trip.js +0 -4
- package/lib/chevre/repository.d.ts +3 -5
- package/lib/chevre/repository.js +5 -8
- package/lib/chevre/service/aggregation/event/aggregateScreeningEvent.d.ts +2 -2
- package/lib/chevre/service/aggregation/event/aggregateScreeningEvent.js +4 -3
- package/lib/chevre/service/assetTransaction/cancelReservation.js +1 -5
- package/lib/chevre/service/assetTransaction/moneyTransfer.js +1 -1
- package/lib/chevre/service/assetTransaction/pay.js +2 -2
- package/lib/chevre/service/assetTransaction/refund.js +1 -1
- package/lib/chevre/service/assetTransaction/registerService.js +1 -2
- package/lib/chevre/service/assetTransaction/reserve.d.ts +4 -4
- package/lib/chevre/service/assetTransaction/reserve.js +8 -5
- package/lib/chevre/service/assetTransaction.d.ts +0 -2
- package/lib/chevre/service/assetTransaction.js +0 -1
- package/lib/chevre/service/offer/event/authorize.d.ts +2 -2
- package/lib/chevre/service/offer/event/cancel.d.ts +2 -2
- package/lib/chevre/service/offer/event/voidTransaction.d.ts +2 -2
- package/lib/chevre/service/offer.d.ts +2 -2
- package/lib/chevre/service/offer.js +5 -2
- package/lib/chevre/service/order/onOrderStatusChanged.js +1 -1
- package/lib/chevre/service/order/placeOrder.js +1 -1
- package/lib/chevre/service/order/returnOrder.js +1 -5
- package/lib/chevre/service/order/sendOrder.js +1 -1
- package/lib/chevre/service/payment/any.js +1 -1
- package/lib/chevre/service/reserve/cancelReservation.d.ts +3 -3
- package/lib/chevre/service/reserve/cancelReservation.js +6 -6
- package/lib/chevre/service/task/aggregateScreeningEvent.js +2 -2
- package/lib/chevre/service/task/cancelPendingReservation.js +3 -3
- package/lib/chevre/service/task/cancelReservation.js +3 -3
- package/lib/chevre/service/task/voidReserveTransaction.js +3 -3
- package/lib/chevre/service/task.d.ts +9 -0
- package/lib/chevre/service/task.js +22 -1
- package/lib/chevre/service/transaction/moneyTransfer.js +1 -3
- package/lib/chevre/service/transaction/placeOrder.js +1 -5
- package/lib/chevre/service/transaction/placeOrderInProgress.js +2 -2
- package/lib/chevre/service/transaction/returnOrder.js +1 -5
- package/lib/chevre/service/transaction.d.ts +1 -0
- package/lib/chevre/service/transaction.js +1 -7
- package/lib/chevre/settings.d.ts +2 -1
- package/lib/chevre/settings.js +5 -4
- package/package.json +4 -4
- package/example/src/chevre/migrateMoneyTransferPendingTransactionIdentifier.ts +0 -96
- package/example/src/chevre/migrateMovieAdditionalProperties.ts +0 -98
- package/lib/chevre/repo/itemAvailability/screeningEvent.js +0 -193
|
@@ -17,9 +17,10 @@ const schema = new mongoose_1.Schema({
|
|
|
17
17
|
}, {
|
|
18
18
|
collection: 'serviceOutputs',
|
|
19
19
|
id: true,
|
|
20
|
-
read: '
|
|
20
|
+
read: 'primary',
|
|
21
21
|
writeConcern: writeConcern_1.writeConcern,
|
|
22
22
|
strict: false,
|
|
23
|
+
strictQuery: false,
|
|
23
24
|
useNestedStrict: true,
|
|
24
25
|
timestamps: {
|
|
25
26
|
createdAt: 'createdAt',
|
|
@@ -27,12 +27,13 @@ declare const modelName = "Task";
|
|
|
27
27
|
/**
|
|
28
28
|
* タスクスキーマ
|
|
29
29
|
*/
|
|
30
|
-
declare const schema: Schema<any, import("mongoose").Model<any, any, any, any, any>, {}, {}, {}, {},
|
|
30
|
+
declare const schema: Schema<any, import("mongoose").Model<any, any, any, any, any, any>, {}, {}, {}, {}, {
|
|
31
31
|
collection: string;
|
|
32
32
|
id: true;
|
|
33
33
|
read: string;
|
|
34
34
|
writeConcern: import("mongodb").WriteConcern;
|
|
35
35
|
strict: true;
|
|
36
|
+
strictQuery: false;
|
|
36
37
|
useNestedStrict: boolean;
|
|
37
38
|
timestamps: {
|
|
38
39
|
createdAt: string;
|
|
@@ -50,7 +51,7 @@ declare const schema: Schema<any, import("mongoose").Model<any, any, any, any, a
|
|
|
50
51
|
minimize: false;
|
|
51
52
|
versionKey: false;
|
|
52
53
|
};
|
|
53
|
-
}
|
|
54
|
+
}, {
|
|
54
55
|
executionResults: any[];
|
|
55
56
|
name?: string | undefined;
|
|
56
57
|
status?: string | undefined;
|
|
@@ -60,6 +61,33 @@ declare const schema: Schema<any, import("mongoose").Model<any, any, any, any, a
|
|
|
60
61
|
remainingNumberOfTries?: number | undefined;
|
|
61
62
|
lastTriedAt?: Date | undefined;
|
|
62
63
|
numberOfTried?: number | undefined;
|
|
64
|
+
executor?: any;
|
|
63
65
|
dateAborted?: Date | undefined;
|
|
64
|
-
}
|
|
66
|
+
}, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<{
|
|
67
|
+
executionResults: any[];
|
|
68
|
+
name?: string | undefined;
|
|
69
|
+
status?: string | undefined;
|
|
70
|
+
data?: any;
|
|
71
|
+
project?: any;
|
|
72
|
+
runsAt?: Date | undefined;
|
|
73
|
+
remainingNumberOfTries?: number | undefined;
|
|
74
|
+
lastTriedAt?: Date | undefined;
|
|
75
|
+
numberOfTried?: number | undefined;
|
|
76
|
+
executor?: any;
|
|
77
|
+
dateAborted?: Date | undefined;
|
|
78
|
+
}>> & Omit<import("mongoose").FlatRecord<{
|
|
79
|
+
executionResults: any[];
|
|
80
|
+
name?: string | undefined;
|
|
81
|
+
status?: string | undefined;
|
|
82
|
+
data?: any;
|
|
83
|
+
project?: any;
|
|
84
|
+
runsAt?: Date | undefined;
|
|
85
|
+
remainingNumberOfTries?: number | undefined;
|
|
86
|
+
lastTriedAt?: Date | undefined;
|
|
87
|
+
numberOfTried?: number | undefined;
|
|
88
|
+
executor?: any;
|
|
89
|
+
dateAborted?: Date | undefined;
|
|
90
|
+
}> & {
|
|
91
|
+
_id: import("mongoose").Types.ObjectId;
|
|
92
|
+
}, never>>;
|
|
65
93
|
export { modelName, schema };
|
|
@@ -17,14 +17,16 @@ const schema = new mongoose_1.Schema({
|
|
|
17
17
|
lastTriedAt: Date,
|
|
18
18
|
numberOfTried: Number,
|
|
19
19
|
executionResults: [mongoose_1.SchemaTypes.Mixed],
|
|
20
|
+
executor: mongoose_1.SchemaTypes.Mixed,
|
|
20
21
|
data: mongoose_1.SchemaTypes.Mixed,
|
|
21
22
|
dateAborted: Date
|
|
22
23
|
}, {
|
|
23
24
|
collection: 'tasks',
|
|
24
25
|
id: true,
|
|
25
|
-
read: '
|
|
26
|
+
read: 'primary',
|
|
26
27
|
writeConcern: writeConcern_1.writeConcern,
|
|
27
28
|
strict: true,
|
|
29
|
+
strictQuery: false,
|
|
28
30
|
useNestedStrict: true,
|
|
29
31
|
timestamps: {
|
|
30
32
|
createdAt: 'createdAt',
|
|
@@ -27,12 +27,13 @@ declare const modelName = "Telemetry";
|
|
|
27
27
|
/**
|
|
28
28
|
* 測定スキーマ
|
|
29
29
|
*/
|
|
30
|
-
declare const schema: Schema<any, import("mongoose").Model<any, any, any, any, any>, {}, {}, {}, {},
|
|
30
|
+
declare const schema: Schema<any, import("mongoose").Model<any, any, any, any, any, any>, {}, {}, {}, {}, {
|
|
31
31
|
collection: string;
|
|
32
32
|
id: true;
|
|
33
33
|
read: string;
|
|
34
34
|
writeConcern: import("mongodb").WriteConcern;
|
|
35
35
|
strict: true;
|
|
36
|
+
strictQuery: false;
|
|
36
37
|
useNestedStrict: boolean;
|
|
37
38
|
timestamps: {
|
|
38
39
|
createdAt: string;
|
|
@@ -50,13 +51,31 @@ declare const schema: Schema<any, import("mongoose").Model<any, any, any, any, a
|
|
|
50
51
|
minimize: false;
|
|
51
52
|
versionKey: false;
|
|
52
53
|
};
|
|
53
|
-
}
|
|
54
|
+
}, {
|
|
54
55
|
object?: any;
|
|
55
56
|
error?: any;
|
|
57
|
+
result?: any;
|
|
58
|
+
project?: any;
|
|
59
|
+
startDate?: Date | undefined;
|
|
60
|
+
endDate?: Date | undefined;
|
|
61
|
+
purpose?: any;
|
|
62
|
+
}, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<{
|
|
63
|
+
object?: any;
|
|
64
|
+
error?: any;
|
|
65
|
+
result?: any;
|
|
56
66
|
project?: any;
|
|
57
67
|
startDate?: Date | undefined;
|
|
58
68
|
endDate?: Date | undefined;
|
|
69
|
+
purpose?: any;
|
|
70
|
+
}>> & Omit<import("mongoose").FlatRecord<{
|
|
71
|
+
object?: any;
|
|
72
|
+
error?: any;
|
|
59
73
|
result?: any;
|
|
74
|
+
project?: any;
|
|
75
|
+
startDate?: Date | undefined;
|
|
76
|
+
endDate?: Date | undefined;
|
|
60
77
|
purpose?: any;
|
|
61
|
-
}
|
|
78
|
+
}> & {
|
|
79
|
+
_id: import("mongoose").Types.ObjectId;
|
|
80
|
+
}, never>>;
|
|
62
81
|
export { modelName, schema };
|
|
@@ -27,12 +27,13 @@ declare const modelName = "Transaction";
|
|
|
27
27
|
/**
|
|
28
28
|
* 取引スキーマ
|
|
29
29
|
*/
|
|
30
|
-
declare const schema: Schema<any, import("mongoose").Model<any, any, any, any, any>, {}, {}, {}, {},
|
|
30
|
+
declare const schema: Schema<any, import("mongoose").Model<any, any, any, any, any, any>, {}, {}, {}, {}, {
|
|
31
31
|
collection: string;
|
|
32
32
|
id: true;
|
|
33
33
|
read: string;
|
|
34
34
|
writeConcern: import("mongodb").WriteConcern;
|
|
35
35
|
strict: true;
|
|
36
|
+
strictQuery: false;
|
|
36
37
|
useNestedStrict: boolean;
|
|
37
38
|
timestamps: {
|
|
38
39
|
createdAt: string;
|
|
@@ -50,11 +51,28 @@ declare const schema: Schema<any, import("mongoose").Model<any, any, any, any, a
|
|
|
50
51
|
minimize: false;
|
|
51
52
|
versionKey: false;
|
|
52
53
|
};
|
|
53
|
-
}
|
|
54
|
+
}, {
|
|
54
55
|
object?: any;
|
|
55
56
|
typeOf?: string | undefined;
|
|
57
|
+
error?: any;
|
|
56
58
|
status?: string | undefined;
|
|
59
|
+
result?: any;
|
|
60
|
+
expires?: Date | undefined;
|
|
61
|
+
project?: any;
|
|
62
|
+
agent?: any;
|
|
63
|
+
recipient?: any;
|
|
64
|
+
startDate?: Date | undefined;
|
|
65
|
+
endDate?: Date | undefined;
|
|
66
|
+
potentialActions?: any;
|
|
67
|
+
tasksExportationStatus?: string | undefined;
|
|
68
|
+
tasksExportedAt?: Date | undefined;
|
|
69
|
+
seller?: any;
|
|
70
|
+
}, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<{
|
|
71
|
+
object?: any;
|
|
72
|
+
typeOf?: string | undefined;
|
|
57
73
|
error?: any;
|
|
74
|
+
status?: string | undefined;
|
|
75
|
+
result?: any;
|
|
58
76
|
expires?: Date | undefined;
|
|
59
77
|
project?: any;
|
|
60
78
|
agent?: any;
|
|
@@ -64,7 +82,24 @@ declare const schema: Schema<any, import("mongoose").Model<any, any, any, any, a
|
|
|
64
82
|
potentialActions?: any;
|
|
65
83
|
tasksExportationStatus?: string | undefined;
|
|
66
84
|
tasksExportedAt?: Date | undefined;
|
|
85
|
+
seller?: any;
|
|
86
|
+
}>> & Omit<import("mongoose").FlatRecord<{
|
|
87
|
+
object?: any;
|
|
88
|
+
typeOf?: string | undefined;
|
|
89
|
+
error?: any;
|
|
90
|
+
status?: string | undefined;
|
|
67
91
|
result?: any;
|
|
92
|
+
expires?: Date | undefined;
|
|
93
|
+
project?: any;
|
|
94
|
+
agent?: any;
|
|
95
|
+
recipient?: any;
|
|
96
|
+
startDate?: Date | undefined;
|
|
97
|
+
endDate?: Date | undefined;
|
|
98
|
+
potentialActions?: any;
|
|
99
|
+
tasksExportationStatus?: string | undefined;
|
|
100
|
+
tasksExportedAt?: Date | undefined;
|
|
68
101
|
seller?: any;
|
|
69
|
-
}
|
|
102
|
+
}> & {
|
|
103
|
+
_id: import("mongoose").Types.ObjectId;
|
|
104
|
+
}, never>>;
|
|
70
105
|
export { modelName, schema };
|
|
@@ -28,9 +28,10 @@ const schema = new mongoose_1.Schema({
|
|
|
28
28
|
}, {
|
|
29
29
|
collection: 'transactions',
|
|
30
30
|
id: true,
|
|
31
|
-
read: '
|
|
31
|
+
read: 'primary',
|
|
32
32
|
writeConcern: writeConcern_1.writeConcern,
|
|
33
33
|
strict: true,
|
|
34
|
+
strictQuery: false,
|
|
34
35
|
useNestedStrict: true,
|
|
35
36
|
timestamps: {
|
|
36
37
|
createdAt: 'createdAt',
|
|
@@ -27,12 +27,13 @@ declare const modelName = "Trip";
|
|
|
27
27
|
/**
|
|
28
28
|
* トリップスキーマ
|
|
29
29
|
*/
|
|
30
|
-
declare const schema: Schema<any, import("mongoose").Model<any, any, any, any, any>, {}, {}, {}, {},
|
|
30
|
+
declare const schema: Schema<any, import("mongoose").Model<any, any, any, any, any, any>, {}, {}, {}, {}, {
|
|
31
31
|
collection: string;
|
|
32
32
|
id: true;
|
|
33
33
|
read: string;
|
|
34
34
|
writeConcern: import("mongodb").WriteConcern;
|
|
35
35
|
strict: false;
|
|
36
|
+
strictQuery: false;
|
|
36
37
|
useNestedStrict: boolean;
|
|
37
38
|
timestamps: {
|
|
38
39
|
createdAt: string;
|
|
@@ -50,8 +51,16 @@ declare const schema: Schema<any, import("mongoose").Model<any, any, any, any, a
|
|
|
50
51
|
minimize: false;
|
|
51
52
|
versionKey: false;
|
|
52
53
|
};
|
|
53
|
-
}
|
|
54
|
+
}, {
|
|
54
55
|
typeOf: string;
|
|
55
56
|
project?: any;
|
|
56
|
-
}
|
|
57
|
+
}, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<{
|
|
58
|
+
typeOf: string;
|
|
59
|
+
project?: any;
|
|
60
|
+
}>> & Omit<import("mongoose").FlatRecord<{
|
|
61
|
+
typeOf: string;
|
|
62
|
+
project?: any;
|
|
63
|
+
}> & {
|
|
64
|
+
_id: import("mongoose").Types.ObjectId;
|
|
65
|
+
}, never>>;
|
|
57
66
|
export { modelName, schema };
|
package/lib/chevre/repo/offer.js
CHANGED
|
@@ -23,7 +23,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
23
23
|
exports.MongoRepository = void 0;
|
|
24
24
|
const uniqid = require("uniqid");
|
|
25
25
|
const factory = require("../factory");
|
|
26
|
-
const onIndexCreated_1 = require("./mongoose/onIndexCreated");
|
|
27
26
|
const offer_1 = require("./mongoose/schemas/offer");
|
|
28
27
|
const offerCatalog_1 = require("./mongoose/schemas/offerCatalog");
|
|
29
28
|
/**
|
|
@@ -33,10 +32,6 @@ class MongoRepository {
|
|
|
33
32
|
constructor(connection) {
|
|
34
33
|
this.offerModel = connection.model(offer_1.modelName, offer_1.schema);
|
|
35
34
|
this.offerCatalogModel = connection.model(offerCatalog_1.modelName, offerCatalog_1.schema);
|
|
36
|
-
if (connection.get('autoIndex') === true) {
|
|
37
|
-
this.offerModel.on(onIndexCreated_1.INDEX_EVENT, onIndexCreated_1.onIndexCreated);
|
|
38
|
-
this.offerCatalogModel.on(onIndexCreated_1.INDEX_EVENT, onIndexCreated_1.onIndexCreated);
|
|
39
|
-
}
|
|
40
35
|
}
|
|
41
36
|
// tslint:disable-next-line:cyclomatic-complexity max-func-body-length
|
|
42
37
|
static CREATE_OFFER_MONGO_CONDITIONS(params) {
|
|
@@ -23,7 +23,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
23
23
|
exports.MongoRepository = void 0;
|
|
24
24
|
const uniqid = require("uniqid");
|
|
25
25
|
const factory = require("../factory");
|
|
26
|
-
const onIndexCreated_1 = require("./mongoose/onIndexCreated");
|
|
27
26
|
const offerCatalog_1 = require("./mongoose/schemas/offerCatalog");
|
|
28
27
|
/**
|
|
29
28
|
* オファーカタログリポジトリ
|
|
@@ -31,9 +30,6 @@ const offerCatalog_1 = require("./mongoose/schemas/offerCatalog");
|
|
|
31
30
|
class MongoRepository {
|
|
32
31
|
constructor(connection) {
|
|
33
32
|
this.offerCatalogModel = connection.model(offerCatalog_1.modelName, offerCatalog_1.schema);
|
|
34
|
-
if (connection.get('autoIndex') === true) {
|
|
35
|
-
this.offerCatalogModel.on(onIndexCreated_1.INDEX_EVENT, onIndexCreated_1.onIndexCreated);
|
|
36
|
-
}
|
|
37
33
|
}
|
|
38
34
|
// tslint:disable-next-line:max-func-body-length
|
|
39
35
|
static CREATE_MONGO_CONDITIONS(params) {
|
|
@@ -1,3 +1,27 @@
|
|
|
1
|
+
/// <reference types="mongoose/types/aggregate" />
|
|
2
|
+
/// <reference types="mongoose/types/callback" />
|
|
3
|
+
/// <reference types="mongoose/types/collection" />
|
|
4
|
+
/// <reference types="mongoose/types/connection" />
|
|
5
|
+
/// <reference types="mongoose/types/cursor" />
|
|
6
|
+
/// <reference types="mongoose/types/document" />
|
|
7
|
+
/// <reference types="mongoose/types/error" />
|
|
8
|
+
/// <reference types="mongoose/types/expressions" />
|
|
9
|
+
/// <reference types="mongoose/types/helpers" />
|
|
10
|
+
/// <reference types="mongoose/types/middlewares" />
|
|
11
|
+
/// <reference types="mongoose/types/indexes" />
|
|
12
|
+
/// <reference types="mongoose/types/models" />
|
|
13
|
+
/// <reference types="mongoose/types/mongooseoptions" />
|
|
14
|
+
/// <reference types="mongoose/types/pipelinestage" />
|
|
15
|
+
/// <reference types="mongoose/types/populate" />
|
|
16
|
+
/// <reference types="mongoose/types/query" />
|
|
17
|
+
/// <reference types="mongoose/types/schemaoptions" />
|
|
18
|
+
/// <reference types="mongoose/types/schematypes" />
|
|
19
|
+
/// <reference types="mongoose/types/session" />
|
|
20
|
+
/// <reference types="mongoose/types/types" />
|
|
21
|
+
/// <reference types="mongoose/types/utility" />
|
|
22
|
+
/// <reference types="mongoose/types/validation" />
|
|
23
|
+
/// <reference types="mongoose/types/virtuals" />
|
|
24
|
+
/// <reference types="mongoose/types/inferschematype" />
|
|
1
25
|
import { Connection } from 'mongoose';
|
|
2
26
|
import * as factory from '../factory';
|
|
3
27
|
/**
|
|
@@ -86,4 +110,5 @@ export declare class MongoRepository {
|
|
|
86
110
|
$in: string[];
|
|
87
111
|
};
|
|
88
112
|
}): Promise<(string)[]>;
|
|
113
|
+
getCursor(conditions: any, projection: any): import("mongoose").Cursor<any, import("mongoose").QueryOptions<any>>;
|
|
89
114
|
}
|
package/lib/chevre/repo/order.js
CHANGED
|
@@ -11,7 +11,6 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.MongoRepository = void 0;
|
|
13
13
|
const factory = require("../factory");
|
|
14
|
-
const onIndexCreated_1 = require("./mongoose/onIndexCreated");
|
|
15
14
|
const order_1 = require("./mongoose/schemas/order");
|
|
16
15
|
const errorHandler_1 = require("../errorHandler");
|
|
17
16
|
const order_2 = require("../factory/order");
|
|
@@ -21,9 +20,6 @@ const order_2 = require("../factory/order");
|
|
|
21
20
|
class MongoRepository {
|
|
22
21
|
constructor(connection) {
|
|
23
22
|
this.orderModel = connection.model(order_1.modelName, order_1.schema);
|
|
24
|
-
if (connection.get('autoIndex') === true) {
|
|
25
|
-
this.orderModel.on(onIndexCreated_1.INDEX_EVENT, onIndexCreated_1.onIndexCreated);
|
|
26
|
-
}
|
|
27
23
|
}
|
|
28
24
|
// tslint:disable-next-line:cyclomatic-complexity max-func-body-length
|
|
29
25
|
static CREATE_MONGO_CONDITIONS(params) {
|
|
@@ -1014,5 +1010,10 @@ class MongoRepository {
|
|
|
1014
1010
|
return [...new Set(reservationNumbers)];
|
|
1015
1011
|
});
|
|
1016
1012
|
}
|
|
1013
|
+
getCursor(conditions, projection) {
|
|
1014
|
+
return this.orderModel.find(conditions, projection)
|
|
1015
|
+
.sort({ orderDate: factory.sortType.Descending })
|
|
1016
|
+
.cursor();
|
|
1017
|
+
}
|
|
1017
1018
|
}
|
|
1018
1019
|
exports.MongoRepository = MongoRepository;
|
|
@@ -16,7 +16,6 @@ const util = require("util");
|
|
|
16
16
|
// tslint:disable-next-line:no-require-imports no-var-requires
|
|
17
17
|
const fpe = require('node-fpe');
|
|
18
18
|
const factory = require("../factory");
|
|
19
|
-
const settings_1 = require("../settings");
|
|
20
19
|
const ORDER_NUMBER_SEPARATOR = '-';
|
|
21
20
|
/**
|
|
22
21
|
* 注文番号リポジトリ
|
|
@@ -26,15 +25,7 @@ class RedisRepository {
|
|
|
26
25
|
this.redisClient = redisClient;
|
|
27
26
|
}
|
|
28
27
|
static createKey(params) {
|
|
29
|
-
|
|
30
|
-
&& moment(params.orderDate)
|
|
31
|
-
.isSameOrAfter(settings_1.USE_NEW_ORDER_NUMBER_KEY_FROM);
|
|
32
|
-
if (useNewKey) {
|
|
33
|
-
return util.format('%s:%s:%s', RedisRepository.REDIS_KEY_PREFIX_NEW, params.projectPrefix, params.timestamp);
|
|
34
|
-
}
|
|
35
|
-
else {
|
|
36
|
-
return util.format('%s:%s:%s', RedisRepository.REDIS_KEY_PREFIX, params.projectPrefix, params.timestamp);
|
|
37
|
-
}
|
|
28
|
+
return util.format('%s:%s:%s', RedisRepository.REDIS_KEY_PREFIX, params.projectPrefix, params.timestamp);
|
|
38
29
|
}
|
|
39
30
|
/**
|
|
40
31
|
* タイムスタンプから発行する
|
|
@@ -79,6 +70,5 @@ class RedisRepository {
|
|
|
79
70
|
});
|
|
80
71
|
}
|
|
81
72
|
}
|
|
82
|
-
RedisRepository.
|
|
83
|
-
RedisRepository.REDIS_KEY_PREFIX = 'cinerino:orderNumber';
|
|
73
|
+
RedisRepository.REDIS_KEY_PREFIX = 'orderNumber';
|
|
84
74
|
exports.RedisRepository = RedisRepository;
|
|
@@ -11,7 +11,6 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.MongoRepository = void 0;
|
|
13
13
|
const uuid = require("uuid");
|
|
14
|
-
const onIndexCreated_1 = require("./mongoose/onIndexCreated");
|
|
15
14
|
const ownershipInfo_1 = require("./mongoose/schemas/ownershipInfo");
|
|
16
15
|
const errorHandler_1 = require("../errorHandler");
|
|
17
16
|
const factory = require("../factory");
|
|
@@ -21,9 +20,6 @@ const factory = require("../factory");
|
|
|
21
20
|
class MongoRepository {
|
|
22
21
|
constructor(connection) {
|
|
23
22
|
this.ownershipInfoModel = connection.model(ownershipInfo_1.modelName, ownershipInfo_1.schema);
|
|
24
|
-
if (connection.get('autoIndex') === true) {
|
|
25
|
-
this.ownershipInfoModel.on(onIndexCreated_1.INDEX_EVENT, onIndexCreated_1.onIndexCreated);
|
|
26
|
-
}
|
|
27
23
|
}
|
|
28
24
|
// tslint:disable-next-line:cyclomatic-complexity max-func-body-length
|
|
29
25
|
static CREATE_MONGO_CONDITIONS(params) {
|
|
@@ -10,7 +10,6 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.MongoRepository = void 0;
|
|
13
|
-
const onIndexCreated_1 = require("./mongoose/onIndexCreated");
|
|
14
13
|
const serviceOutput_1 = require("./mongoose/schemas/serviceOutput");
|
|
15
14
|
const factory = require("../factory");
|
|
16
15
|
/**
|
|
@@ -19,9 +18,6 @@ const factory = require("../factory");
|
|
|
19
18
|
class MongoRepository {
|
|
20
19
|
constructor(connection) {
|
|
21
20
|
this.serviceOutputModel = connection.model(serviceOutput_1.modelName, serviceOutput_1.schema);
|
|
22
|
-
if (connection.get('autoIndex') === true) {
|
|
23
|
-
this.serviceOutputModel.on(onIndexCreated_1.INDEX_EVENT, onIndexCreated_1.onIndexCreated);
|
|
24
|
-
}
|
|
25
21
|
}
|
|
26
22
|
findByIdentifier(params, projection) {
|
|
27
23
|
var _a, _b;
|
|
@@ -48,7 +48,11 @@ export declare class MongoRepository {
|
|
|
48
48
|
/**
|
|
49
49
|
* 施設検索
|
|
50
50
|
*/
|
|
51
|
-
searchMovieTheaters(params: factory.place.movieTheater.ISearchConditions
|
|
51
|
+
searchMovieTheaters(params: factory.place.movieTheater.ISearchConditions & {
|
|
52
|
+
$projection?: {
|
|
53
|
+
[key: string]: 0;
|
|
54
|
+
};
|
|
55
|
+
}): Promise<factory.place.movieTheater.IPlaceWithoutScreeningRoom[]>;
|
|
52
56
|
/**
|
|
53
57
|
* 施設取得
|
|
54
58
|
*/
|
package/lib/chevre/repo/place.js
CHANGED
|
@@ -22,7 +22,6 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
22
22
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
23
23
|
exports.MongoRepository = void 0;
|
|
24
24
|
const mongoose_1 = require("mongoose");
|
|
25
|
-
const onIndexCreated_1 = require("./mongoose/onIndexCreated");
|
|
26
25
|
const place_1 = require("./mongoose/schemas/place");
|
|
27
26
|
const factory = require("../factory");
|
|
28
27
|
/**
|
|
@@ -31,9 +30,6 @@ const factory = require("../factory");
|
|
|
31
30
|
class MongoRepository {
|
|
32
31
|
constructor(connection) {
|
|
33
32
|
this.placeModel = connection.model(place_1.modelName, place_1.schema);
|
|
34
|
-
if (connection.get('autoIndex') === true) {
|
|
35
|
-
this.placeModel.on(onIndexCreated_1.INDEX_EVENT, onIndexCreated_1.onIndexCreated);
|
|
36
|
-
}
|
|
37
33
|
}
|
|
38
34
|
// tslint:disable-next-line:max-func-body-length
|
|
39
35
|
static CREATE_BUS_STOP_MONGO_CONDITIONS(params) {
|
|
@@ -276,12 +272,7 @@ class MongoRepository {
|
|
|
276
272
|
return __awaiter(this, void 0, void 0, function* () {
|
|
277
273
|
const conditions = MongoRepository.CREATE_MOVIE_THEATER_MONGO_CONDITIONS(params);
|
|
278
274
|
// containsPlaceを含めるとデータサイズが大きくなるので、検索結果には含めない
|
|
279
|
-
const query = this.placeModel.find((conditions.length > 0) ? { $and: conditions } : {}, {
|
|
280
|
-
__v: 0,
|
|
281
|
-
createdAt: 0,
|
|
282
|
-
updatedAt: 0,
|
|
283
|
-
containsPlace: 0
|
|
284
|
-
});
|
|
275
|
+
const query = this.placeModel.find((conditions.length > 0) ? { $and: conditions } : {}, Object.assign({ __v: 0, createdAt: 0, updatedAt: 0, containsPlace: 0 }, params.$projection));
|
|
285
276
|
if (typeof params.limit === 'number' && params.limit > 0) {
|
|
286
277
|
const page = (typeof params.page === 'number' && params.page > 0) ? params.page : 1;
|
|
287
278
|
query.limit(params.limit)
|
|
@@ -22,7 +22,6 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
22
22
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
23
23
|
exports.MongoRepository = void 0;
|
|
24
24
|
const factory = require("../factory");
|
|
25
|
-
const onIndexCreated_1 = require("./mongoose/onIndexCreated");
|
|
26
25
|
const priceSpecification_1 = require("./mongoose/schemas/priceSpecification");
|
|
27
26
|
/**
|
|
28
27
|
* 価格仕様リポジトリ
|
|
@@ -30,9 +29,6 @@ const priceSpecification_1 = require("./mongoose/schemas/priceSpecification");
|
|
|
30
29
|
class MongoRepository {
|
|
31
30
|
constructor(connection) {
|
|
32
31
|
this.priceSpecificationModel = connection.model(priceSpecification_1.modelName, priceSpecification_1.schema);
|
|
33
|
-
if (connection.get('autoIndex') === true) {
|
|
34
|
-
this.priceSpecificationModel.on(onIndexCreated_1.INDEX_EVENT, onIndexCreated_1.onIndexCreated);
|
|
35
|
-
}
|
|
36
32
|
}
|
|
37
33
|
// tslint:disable-next-line:cyclomatic-complexity max-func-body-length
|
|
38
34
|
static CREATE_MONGO_CONDITIONS(params) {
|
|
@@ -21,7 +21,6 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
21
21
|
};
|
|
22
22
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
23
23
|
exports.MongoRepository = void 0;
|
|
24
|
-
const onIndexCreated_1 = require("./mongoose/onIndexCreated");
|
|
25
24
|
const product_1 = require("./mongoose/schemas/product");
|
|
26
25
|
const factory = require("../factory");
|
|
27
26
|
/**
|
|
@@ -30,9 +29,6 @@ const factory = require("../factory");
|
|
|
30
29
|
class MongoRepository {
|
|
31
30
|
constructor(connection) {
|
|
32
31
|
this.productModel = connection.model(product_1.modelName, product_1.schema);
|
|
33
|
-
if (connection.get('autoIndex') === true) {
|
|
34
|
-
this.productModel.on(onIndexCreated_1.INDEX_EVENT, onIndexCreated_1.onIndexCreated);
|
|
35
|
-
}
|
|
36
32
|
}
|
|
37
33
|
// tslint:disable-next-line:max-func-body-length
|
|
38
34
|
static CREATE_MONGO_CONDITIONS(params) {
|
|
@@ -10,7 +10,6 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.MongoRepository = void 0;
|
|
13
|
-
const onIndexCreated_1 = require("./mongoose/onIndexCreated");
|
|
14
13
|
const project_1 = require("./mongoose/schemas/project");
|
|
15
14
|
const factory = require("../factory");
|
|
16
15
|
/**
|
|
@@ -19,9 +18,6 @@ const factory = require("../factory");
|
|
|
19
18
|
class MongoRepository {
|
|
20
19
|
constructor(connection) {
|
|
21
20
|
this.projectModel = connection.model(project_1.modelName, project_1.schema);
|
|
22
|
-
if (connection.get('autoIndex') === true) {
|
|
23
|
-
this.projectModel.on(onIndexCreated_1.INDEX_EVENT, onIndexCreated_1.onIndexCreated);
|
|
24
|
-
}
|
|
25
21
|
}
|
|
26
22
|
static CREATE_MONGO_CONDITIONS(params) {
|
|
27
23
|
// MongoDB検索条件
|
|
@@ -18,10 +18,11 @@ export interface IRateLimitKey {
|
|
|
18
18
|
* オファーレート制限リポジトリ
|
|
19
19
|
*/
|
|
20
20
|
export declare class RedisRepository {
|
|
21
|
-
static
|
|
21
|
+
private static readonly KEY_PREFIX_NEW;
|
|
22
|
+
private static readonly KEY_PREFIX;
|
|
22
23
|
private readonly redisClient;
|
|
23
24
|
constructor(redisClient: RedisClientType);
|
|
24
|
-
static
|
|
25
|
+
private static createKey;
|
|
25
26
|
/**
|
|
26
27
|
* ロックする
|
|
27
28
|
*/
|