@chevre/domain 21.12.0 → 21.13.0-alpha.0

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.
Files changed (113) hide show
  1. package/lib/chevre/repo/account.js +1 -1
  2. package/lib/chevre/repo/accountTitle.js +1 -1
  3. package/lib/chevre/repo/accountTransaction.js +1 -1
  4. package/lib/chevre/repo/accountingReport.js +1 -1
  5. package/lib/chevre/repo/action.js +1 -1
  6. package/lib/chevre/repo/additionalProperty.js +1 -1
  7. package/lib/chevre/repo/aggregateOffer.js +1 -1
  8. package/lib/chevre/repo/aggregation.js +1 -1
  9. package/lib/chevre/repo/assetTransaction.js +1 -1
  10. package/lib/chevre/repo/categoryCode.js +1 -1
  11. package/lib/chevre/repo/code.js +1 -1
  12. package/lib/chevre/repo/comment.js +1 -1
  13. package/lib/chevre/repo/creativeWork.js +1 -1
  14. package/lib/chevre/repo/customer.js +1 -1
  15. package/lib/chevre/repo/emailMessage.js +1 -1
  16. package/lib/chevre/repo/event.js +1 -1
  17. package/lib/chevre/repo/member.js +1 -1
  18. package/lib/chevre/repo/merchantReturnPolicy.js +1 -1
  19. package/lib/chevre/repo/mongoose/schemas/account.d.ts +4 -56
  20. package/lib/chevre/repo/mongoose/schemas/account.js +80 -32
  21. package/lib/chevre/repo/mongoose/schemas/accountTitle.d.ts +4 -90
  22. package/lib/chevre/repo/mongoose/schemas/accountTitle.js +81 -44
  23. package/lib/chevre/repo/mongoose/schemas/accountTransaction.d.ts +4 -95
  24. package/lib/chevre/repo/mongoose/schemas/accountTransaction.js +129 -62
  25. package/lib/chevre/repo/mongoose/schemas/accountingReport.d.ts +4 -68
  26. package/lib/chevre/repo/mongoose/schemas/accountingReport.js +108 -63
  27. package/lib/chevre/repo/mongoose/schemas/action.d.ts +4 -113
  28. package/lib/chevre/repo/mongoose/schemas/action.js +345 -215
  29. package/lib/chevre/repo/mongoose/schemas/additionalProperty.d.ts +4 -74
  30. package/lib/chevre/repo/mongoose/schemas/additionalProperty.js +65 -32
  31. package/lib/chevre/repo/mongoose/schemas/aggregateOffer.d.ts +4 -73
  32. package/lib/chevre/repo/mongoose/schemas/aggregateOffer.js +258 -155
  33. package/lib/chevre/repo/mongoose/schemas/aggregation.d.ts +4 -56
  34. package/lib/chevre/repo/mongoose/schemas/aggregation.js +28 -10
  35. package/lib/chevre/repo/mongoose/schemas/assetTransaction.d.ts +4 -113
  36. package/lib/chevre/repo/mongoose/schemas/assetTransaction.js +258 -146
  37. package/lib/chevre/repo/mongoose/schemas/authorization.d.ts +4 -77
  38. package/lib/chevre/repo/mongoose/schemas/authorization.js +110 -61
  39. package/lib/chevre/repo/mongoose/schemas/categoryCode.d.ts +4 -86
  40. package/lib/chevre/repo/mongoose/schemas/categoryCode.js +85 -46
  41. package/lib/chevre/repo/mongoose/schemas/comments.d.ts +4 -89
  42. package/lib/chevre/repo/mongoose/schemas/comments.js +59 -28
  43. package/lib/chevre/repo/mongoose/schemas/creativeWork.d.ts +4 -104
  44. package/lib/chevre/repo/mongoose/schemas/creativeWork.js +121 -70
  45. package/lib/chevre/repo/mongoose/schemas/customer.d.ts +4 -86
  46. package/lib/chevre/repo/mongoose/schemas/customer.js +56 -26
  47. package/lib/chevre/repo/mongoose/schemas/emailMessages.d.ts +4 -80
  48. package/lib/chevre/repo/mongoose/schemas/emailMessages.js +41 -17
  49. package/lib/chevre/repo/mongoose/schemas/event.d.ts +4 -158
  50. package/lib/chevre/repo/mongoose/schemas/event.js +307 -193
  51. package/lib/chevre/repo/mongoose/schemas/member.d.ts +4 -68
  52. package/lib/chevre/repo/mongoose/schemas/member.js +65 -37
  53. package/lib/chevre/repo/mongoose/schemas/merchantReturnPolicy.d.ts +4 -80
  54. package/lib/chevre/repo/mongoose/schemas/merchantReturnPolicy.js +29 -11
  55. package/lib/chevre/repo/mongoose/schemas/offerCatalog.d.ts +4 -91
  56. package/lib/chevre/repo/mongoose/schemas/offerCatalog.js +85 -45
  57. package/lib/chevre/repo/mongoose/schemas/offerCatalogItem.d.ts +4 -91
  58. package/lib/chevre/repo/mongoose/schemas/offerCatalogItem.js +29 -10
  59. package/lib/chevre/repo/mongoose/schemas/offerItemCondition.d.ts +4 -73
  60. package/lib/chevre/repo/mongoose/schemas/offerItemCondition.js +37 -12
  61. package/lib/chevre/repo/mongoose/schemas/order.d.ts +4 -128
  62. package/lib/chevre/repo/mongoose/schemas/order.js +407 -259
  63. package/lib/chevre/repo/mongoose/schemas/ownershipInfo.d.ts +4 -86
  64. package/lib/chevre/repo/mongoose/schemas/ownershipInfo.js +187 -111
  65. package/lib/chevre/repo/mongoose/schemas/place.d.ts +4 -128
  66. package/lib/chevre/repo/mongoose/schemas/place.js +159 -93
  67. package/lib/chevre/repo/mongoose/schemas/priceSpecification.d.ts +4 -92
  68. package/lib/chevre/repo/mongoose/schemas/priceSpecification.js +94 -49
  69. package/lib/chevre/repo/mongoose/schemas/product.d.ts +4 -95
  70. package/lib/chevre/repo/mongoose/schemas/product.js +109 -61
  71. package/lib/chevre/repo/mongoose/schemas/project.d.ts +4 -83
  72. package/lib/chevre/repo/mongoose/schemas/project.js +20 -9
  73. package/lib/chevre/repo/mongoose/schemas/reservation.d.ts +4 -143
  74. package/lib/chevre/repo/mongoose/schemas/reservation.js +377 -229
  75. package/lib/chevre/repo/mongoose/schemas/role.d.ts +4 -65
  76. package/lib/chevre/repo/mongoose/schemas/role.js +43 -19
  77. package/lib/chevre/repo/mongoose/schemas/seller.d.ts +4 -95
  78. package/lib/chevre/repo/mongoose/schemas/seller.js +96 -51
  79. package/lib/chevre/repo/mongoose/schemas/serviceOutput.d.ts +4 -65
  80. package/lib/chevre/repo/mongoose/schemas/serviceOutput.js +112 -63
  81. package/lib/chevre/repo/mongoose/schemas/task.d.ts +4 -95
  82. package/lib/chevre/repo/mongoose/schemas/task.js +214 -126
  83. package/lib/chevre/repo/mongoose/schemas/telemetry.d.ts +4 -80
  84. package/lib/chevre/repo/mongoose/schemas/telemetry.js +44 -24
  85. package/lib/chevre/repo/mongoose/schemas/transaction.d.ts +4 -107
  86. package/lib/chevre/repo/mongoose/schemas/transaction.js +291 -176
  87. package/lib/chevre/repo/mongoose/schemas/trip.d.ts +4 -65
  88. package/lib/chevre/repo/mongoose/schemas/trip.js +20 -9
  89. package/lib/chevre/repo/offer.js +3 -3
  90. package/lib/chevre/repo/offerCatalog.js +1 -1
  91. package/lib/chevre/repo/offerCatalogItem.js +1 -1
  92. package/lib/chevre/repo/offerItemCondition.js +1 -1
  93. package/lib/chevre/repo/order.js +1 -1
  94. package/lib/chevre/repo/ownershipInfo.js +1 -1
  95. package/lib/chevre/repo/paymentServiceProvider.js +1 -1
  96. package/lib/chevre/repo/permit.js +1 -1
  97. package/lib/chevre/repo/place/hasPOS.js +1 -1
  98. package/lib/chevre/repo/place.js +1 -1
  99. package/lib/chevre/repo/priceSpecification.js +1 -1
  100. package/lib/chevre/repo/product.js +1 -1
  101. package/lib/chevre/repo/productOffer.js +1 -1
  102. package/lib/chevre/repo/project.js +1 -1
  103. package/lib/chevre/repo/reservation.js +1 -1
  104. package/lib/chevre/repo/role.js +1 -1
  105. package/lib/chevre/repo/seller.js +1 -1
  106. package/lib/chevre/repo/serviceOutput.js +1 -1
  107. package/lib/chevre/repo/task.js +1 -1
  108. package/lib/chevre/repo/telemetry.js +1 -1
  109. package/lib/chevre/repo/transaction.js +1 -1
  110. package/lib/chevre/repo/trip.js +1 -1
  111. package/lib/chevre/settings.d.ts +1 -0
  112. package/lib/chevre/settings.js +2 -1
  113. package/package.json +1 -1
@@ -17,7 +17,7 @@ const factory = require("../factory");
17
17
  */
18
18
  class MongoRepository {
19
19
  constructor(connection) {
20
- this.serviceOutputModel = connection.model(serviceOutput_1.modelName, serviceOutput_1.schema);
20
+ this.serviceOutputModel = connection.model(serviceOutput_1.modelName, (0, serviceOutput_1.createSchema)());
21
21
  }
22
22
  findByIdentifier(params, projection) {
23
23
  var _a, _b;
@@ -19,7 +19,7 @@ const settings_1 = require("../../settings");
19
19
  */
20
20
  class MongoRepository {
21
21
  constructor(connection, operater) {
22
- this.placeModel = connection.model(place_1.modelName, place_1.schema);
22
+ this.placeModel = connection.model(place_1.modelName, (0, place_1.createSchema)());
23
23
  this.operator = operater;
24
24
  }
25
25
  search(params) {
@@ -30,7 +30,7 @@ const settings_1 = require("../settings");
30
30
  */
31
31
  class MongoRepository {
32
32
  constructor(connection) {
33
- this.placeModel = connection.model(place_1.modelName, place_1.schema);
33
+ this.placeModel = connection.model(place_1.modelName, (0, place_1.createSchema)());
34
34
  }
35
35
  // tslint:disable-next-line:max-func-body-length
36
36
  static CREATE_BUS_STOP_MONGO_CONDITIONS(params) {
@@ -29,7 +29,7 @@ const settings_1 = require("../settings");
29
29
  */
30
30
  class MongoRepository {
31
31
  constructor(connection) {
32
- this.priceSpecificationModel = connection.model(priceSpecification_1.modelName, priceSpecification_1.schema);
32
+ this.priceSpecificationModel = connection.model(priceSpecification_1.modelName, (0, priceSpecification_1.createSchema)());
33
33
  }
34
34
  // tslint:disable-next-line:cyclomatic-complexity max-func-body-length
35
35
  static CREATE_MONGO_CONDITIONS(params) {
@@ -29,7 +29,7 @@ const settings_1 = require("../settings");
29
29
  */
30
30
  class MongoRepository {
31
31
  constructor(connection) {
32
- this.productModel = connection.model(product_1.modelName, product_1.schema);
32
+ this.productModel = connection.model(product_1.modelName, (0, product_1.createSchema)());
33
33
  }
34
34
  // tslint:disable-next-line:max-func-body-length
35
35
  static CREATE_MONGO_CONDITIONS(params) {
@@ -19,7 +19,7 @@ const settings_1 = require("../settings");
19
19
  */
20
20
  class MongoRepository {
21
21
  constructor(connection) {
22
- this.productModel = connection.model(product_1.modelName, product_1.schema);
22
+ this.productModel = connection.model(product_1.modelName, (0, product_1.createSchema)());
23
23
  }
24
24
  /**
25
25
  * プロダクトオファー検索
@@ -18,7 +18,7 @@ const settings_1 = require("../settings");
18
18
  */
19
19
  class MongoRepository {
20
20
  constructor(connection) {
21
- this.projectModel = connection.model(project_1.modelName, project_1.schema);
21
+ this.projectModel = connection.model(project_1.modelName, (0, project_1.createSchema)());
22
22
  }
23
23
  static CREATE_MONGO_CONDITIONS(params) {
24
24
  // MongoDB検索条件
@@ -18,7 +18,7 @@ const settings_1 = require("../settings");
18
18
  */
19
19
  class MongoRepository {
20
20
  constructor(connection) {
21
- this.reservationModel = connection.model(reservation_1.modelName, reservation_1.schema);
21
+ this.reservationModel = connection.model(reservation_1.modelName, (0, reservation_1.createSchema)());
22
22
  }
23
23
  // tslint:disable-next-line:cyclomatic-complexity max-func-body-length
24
24
  static CREATE_MONGO_CONDITIONS(params) {
@@ -21,7 +21,7 @@ var RoleType;
21
21
  */
22
22
  class MongoRepository {
23
23
  constructor(connection) {
24
- this.roleModel = connection.model(role_1.modelName, role_1.schema);
24
+ this.roleModel = connection.model(role_1.modelName, (0, role_1.createSchema)());
25
25
  }
26
26
  static CREATE_MONGO_CONDITIONS(params) {
27
27
  var _a, _b, _c;
@@ -30,7 +30,7 @@ const settings_1 = require("../settings");
30
30
  */
31
31
  class MongoRepository {
32
32
  constructor(connection) {
33
- this.organizationModel = connection.model(seller_1.modelName, seller_1.schema);
33
+ this.organizationModel = connection.model(seller_1.modelName, (0, seller_1.createSchema)());
34
34
  }
35
35
  // tslint:disable-next-line:max-func-body-length
36
36
  static CREATE_MONGO_CONDITIONS(params) {
@@ -18,7 +18,7 @@ const settings_1 = require("../settings");
18
18
  */
19
19
  class MongoRepository {
20
20
  constructor(connection) {
21
- this.serviceOutputModel = connection.model(serviceOutput_1.modelName, serviceOutput_1.schema);
21
+ this.serviceOutputModel = connection.model(serviceOutput_1.modelName, (0, serviceOutput_1.createSchema)());
22
22
  }
23
23
  // tslint:disable-next-line:max-func-body-length
24
24
  static CREATE_MONGO_CONDITIONS(params) {
@@ -27,7 +27,7 @@ const sortOrder4executionOfTasks = {
27
27
  */
28
28
  class MongoRepository {
29
29
  constructor(connection) {
30
- this.taskModel = connection.model(task_1.modelName, task_1.schema);
30
+ this.taskModel = connection.model(task_1.modelName, (0, task_1.createSchema)());
31
31
  }
32
32
  // tslint:disable-next-line:max-func-body-length
33
33
  static CREATE_MONGO_CONDITIONS(params) {
@@ -7,7 +7,7 @@ const telemetry_1 = require("./mongoose/schemas/telemetry");
7
7
  */
8
8
  class MongoRepository {
9
9
  constructor(connection) {
10
- this.telemetryModel = connection.model(telemetry_1.modelName, telemetry_1.schema);
10
+ this.telemetryModel = connection.model(telemetry_1.modelName, (0, telemetry_1.createSchema)());
11
11
  }
12
12
  }
13
13
  exports.MongoRepository = MongoRepository;
@@ -20,7 +20,7 @@ const settings_1 = require("../settings");
20
20
  */
21
21
  class MongoRepository {
22
22
  constructor(connection) {
23
- this.transactionModel = connection.model(transaction_1.modelName, transaction_1.schema);
23
+ this.transactionModel = connection.model(transaction_1.modelName, (0, transaction_1.createSchema)());
24
24
  }
25
25
  // tslint:disable-next-line:cyclomatic-complexity max-func-body-length
26
26
  static CREATE_MONGO_CONDITIONS(params) {
@@ -29,7 +29,7 @@ const settings_1 = require("../settings");
29
29
  */
30
30
  class MongoRepository {
31
31
  constructor(connection) {
32
- this.tripModel = connection.model(trip_1.modelName, trip_1.schema);
32
+ this.tripModel = connection.model(trip_1.modelName, (0, trip_1.createSchema)());
33
33
  }
34
34
  // tslint:disable-next-line:cyclomatic-complexity max-func-body-length
35
35
  static CREATE_MONGO_CONDITIONS(conditions) {
@@ -44,6 +44,7 @@ export declare const USE_AUTHORIZE_PAYMENT_RESULT_AS_ARRAY: boolean;
44
44
  export declare const USE_OPTIMIZE_TICKET_OFFER: boolean;
45
45
  export declare const MONGO_MAX_TIME_MS: number;
46
46
  export declare const MONGO_READ_PREFERENCE: string;
47
+ export declare const MONGO_AUTO_INDEX: boolean;
47
48
  /**
48
49
  * グローバル設定
49
50
  */
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.settings = exports.MONGO_READ_PREFERENCE = exports.MONGO_MAX_TIME_MS = exports.USE_OPTIMIZE_TICKET_OFFER = exports.USE_AUTHORIZE_PAYMENT_RESULT_AS_ARRAY = exports.USE_ORDER_PAYMENT_DUE_ON_PLACED = exports.USE_DELETE_EVENT_BY_ORDER = exports.USE_OBJECT_AS_PAY_TRANSACTION_AMOUNT = exports.USE_NEW_EVENT_AVAILABILITY_KEY_FROM = exports.USE_ASSET_TRANSACTION_SYNC_PROCESSING = exports.DEFAULT_TASKS_EXPORT_AGENT_NAME = exports.DEFAULT_SENDER_EMAIL = exports.TRANSACTION_CANCELED_STORAGE_PERIOD_IN_DAYS = exports.TRANSACTION_CONFIRMED_STORAGE_PERIOD_IN_DAYS = exports.ASSET_TRANSACTION_STORAGE_PERIOD_IN_DAYS = exports.ABORTED_TASKS_WITHOUT_REPORT = exports.TRIGGER_WEBHOOK_RETRY_INTERVAL_IN_MS = exports.TRIGGER_WEBHOOK_MAX_RETRY_COUNT = void 0;
3
+ exports.settings = exports.MONGO_AUTO_INDEX = exports.MONGO_READ_PREFERENCE = exports.MONGO_MAX_TIME_MS = exports.USE_OPTIMIZE_TICKET_OFFER = exports.USE_AUTHORIZE_PAYMENT_RESULT_AS_ARRAY = exports.USE_ORDER_PAYMENT_DUE_ON_PLACED = exports.USE_DELETE_EVENT_BY_ORDER = exports.USE_OBJECT_AS_PAY_TRANSACTION_AMOUNT = exports.USE_NEW_EVENT_AVAILABILITY_KEY_FROM = exports.USE_ASSET_TRANSACTION_SYNC_PROCESSING = exports.DEFAULT_TASKS_EXPORT_AGENT_NAME = exports.DEFAULT_SENDER_EMAIL = exports.TRANSACTION_CANCELED_STORAGE_PERIOD_IN_DAYS = exports.TRANSACTION_CONFIRMED_STORAGE_PERIOD_IN_DAYS = exports.ASSET_TRANSACTION_STORAGE_PERIOD_IN_DAYS = exports.ABORTED_TASKS_WITHOUT_REPORT = exports.TRIGGER_WEBHOOK_RETRY_INTERVAL_IN_MS = exports.TRIGGER_WEBHOOK_MAX_RETRY_COUNT = void 0;
4
4
  const moment = require("moment");
5
5
  const factory = require("./factory");
6
6
  const transactionWebhookUrls = (typeof process.env.INFORM_TRANSACTION_URL === 'string')
@@ -75,6 +75,7 @@ exports.MONGO_MAX_TIME_MS = (typeof process.env.MONGO_MAX_TIME_MS === 'string')
75
75
  exports.MONGO_READ_PREFERENCE = (typeof process.env.MONGO_READ_PREFERENCE === 'string')
76
76
  ? process.env.MONGO_READ_PREFERENCE
77
77
  : 'primaryPreferred';
78
+ exports.MONGO_AUTO_INDEX = process.env.MONGO_AUTO_INDEX === '1';
78
79
  /**
79
80
  * グローバル設定
80
81
  */
package/package.json CHANGED
@@ -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": "21.12.0"
118
+ "version": "21.13.0-alpha.0"
119
119
  }