@vendure/core 1.3.2 → 1.4.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 (293) hide show
  1. package/dist/api/common/validate-custom-field-value.d.ts +1 -1
  2. package/dist/api/common/validate-custom-field-value.js +12 -2
  3. package/dist/api/common/validate-custom-field-value.js.map +1 -1
  4. package/dist/api/config/configure-graphql-module.js +2 -0
  5. package/dist/api/config/configure-graphql-module.js.map +1 -1
  6. package/dist/api/config/generate-list-options.js +7 -2
  7. package/dist/api/config/generate-list-options.js.map +1 -1
  8. package/dist/api/config/graphql-custom-fields.d.ts +2 -0
  9. package/dist/api/config/graphql-custom-fields.js +43 -1
  10. package/dist/api/config/graphql-custom-fields.js.map +1 -1
  11. package/dist/api/resolvers/admin/search.resolver.js +1 -1
  12. package/dist/api/resolvers/admin/search.resolver.js.map +1 -1
  13. package/dist/api/resolvers/admin/tax-category.resolver.js +2 -2
  14. package/dist/api/resolvers/admin/tax-category.resolver.js.map +1 -1
  15. package/dist/api/resolvers/admin/tax-rate.resolver.js +2 -2
  16. package/dist/api/resolvers/admin/tax-rate.resolver.js.map +1 -1
  17. package/dist/api/resolvers/shop/shop-order.resolver.js +1 -1
  18. package/dist/api/resolvers/shop/shop-order.resolver.js.map +1 -1
  19. package/dist/api/schema/admin-api/order.api.graphql +4 -1
  20. package/dist/api/schema/common/common-types.graphql +12 -0
  21. package/dist/api/schema/common/custom-field-types.graphql +9 -0
  22. package/dist/api/schema/shop-api/shop.api.graphql +1 -1
  23. package/dist/common/configurable-operation.d.ts +2 -24
  24. package/dist/common/configurable-operation.js +1 -1
  25. package/dist/common/configurable-operation.js.map +1 -1
  26. package/dist/common/self-refreshing-cache.d.ts +9 -4
  27. package/dist/common/self-refreshing-cache.js +26 -20
  28. package/dist/common/self-refreshing-cache.js.map +1 -1
  29. package/dist/common/types/entity-relation-paths.d.ts +1 -1
  30. package/dist/config/auth/bcrypt-password-hashing-strategy.d.ts +1 -1
  31. package/dist/config/auth/bcrypt-password-hashing-strategy.js +11 -7
  32. package/dist/config/auth/bcrypt-password-hashing-strategy.js.map +1 -1
  33. package/dist/config/catalog/collection-filter.d.ts +1 -1
  34. package/dist/config/catalog/collection-filter.js +1 -1
  35. package/dist/config/catalog/default-collection-filters.d.ts +4 -4
  36. package/dist/config/catalog/default-collection-filters.js +4 -2
  37. package/dist/config/catalog/default-collection-filters.js.map +1 -1
  38. package/dist/config/custom-field/custom-field-types.d.ts +16 -8
  39. package/dist/config/default-config.js +8 -1
  40. package/dist/config/default-config.js.map +1 -1
  41. package/dist/config/index.d.ts +9 -5
  42. package/dist/config/index.js +9 -5
  43. package/dist/config/index.js.map +1 -1
  44. package/dist/config/merge-config.d.ts +7 -0
  45. package/dist/config/merge-config.js +7 -0
  46. package/dist/config/merge-config.js.map +1 -1
  47. package/dist/config/payment/payment-method-handler.d.ts +2 -2
  48. package/dist/config/promotion/actions/buy-x-get-y-free-action.d.ts +2 -2
  49. package/dist/config/promotion/actions/facet-values-percentage-discount-action.d.ts +2 -2
  50. package/dist/config/promotion/actions/order-fixed-discount-action.d.ts +1 -1
  51. package/dist/config/promotion/actions/order-percentage-discount-action.d.ts +1 -1
  52. package/dist/config/promotion/actions/product-percentage-discount-action.d.ts +2 -2
  53. package/dist/config/promotion/conditions/buy-x-get-y-free-condition.d.ts +2 -2
  54. package/dist/config/promotion/conditions/contains-products-condition.d.ts +1 -1
  55. package/dist/config/promotion/conditions/customer-group-condition.d.ts +1 -1
  56. package/dist/config/promotion/conditions/has-facet-values-condition.d.ts +1 -1
  57. package/dist/config/promotion/conditions/min-order-amount-condition.d.ts +1 -1
  58. package/dist/config/promotion/index.d.ts +13 -21
  59. package/dist/config/shipping-method/default-shipping-calculator.d.ts +4 -4
  60. package/dist/config/shipping-method/default-shipping-eligibility-checker.d.ts +1 -1
  61. package/dist/connection/connection.module.d.ts +1 -1
  62. package/dist/connection/transaction-subscriber.js +8 -1
  63. package/dist/connection/transaction-subscriber.js.map +1 -1
  64. package/dist/data-import/providers/import-parser/import-parser.d.ts +40 -40
  65. package/dist/data-import/providers/import-parser/import-parser.js +343 -56
  66. package/dist/data-import/providers/import-parser/import-parser.js.map +1 -1
  67. package/dist/data-import/providers/importer/importer.d.ts +1 -0
  68. package/dist/data-import/providers/importer/importer.js +69 -41
  69. package/dist/data-import/providers/importer/importer.js.map +1 -1
  70. package/dist/data-import/providers/populator/populator.js +9 -1
  71. package/dist/data-import/providers/populator/populator.js.map +1 -1
  72. package/dist/entity/country/country-translation.entity.d.ts +4 -1
  73. package/dist/entity/country/country-translation.entity.js +5 -0
  74. package/dist/entity/country/country-translation.entity.js.map +1 -1
  75. package/dist/entity/country/country.entity.d.ts +4 -1
  76. package/dist/entity/country/country.entity.js +5 -0
  77. package/dist/entity/country/country.entity.js.map +1 -1
  78. package/dist/entity/custom-entity-fields.d.ts +28 -12
  79. package/dist/entity/custom-entity-fields.js +44 -20
  80. package/dist/entity/custom-entity-fields.js.map +1 -1
  81. package/dist/entity/customer-group/customer-group.entity.d.ts +4 -1
  82. package/dist/entity/customer-group/customer-group.entity.js +6 -1
  83. package/dist/entity/customer-group/customer-group.entity.js.map +1 -1
  84. package/dist/entity/payment-method/payment-method.entity.d.ts +4 -1
  85. package/dist/entity/payment-method/payment-method.entity.js +5 -0
  86. package/dist/entity/payment-method/payment-method.entity.js.map +1 -1
  87. package/dist/entity/promotion/promotion.entity.d.ts +4 -1
  88. package/dist/entity/promotion/promotion.entity.js +5 -0
  89. package/dist/entity/promotion/promotion.entity.js.map +1 -1
  90. package/dist/entity/register-custom-entity-fields.js +9 -1
  91. package/dist/entity/register-custom-entity-fields.js.map +1 -1
  92. package/dist/entity/tax-category/tax-category.entity.d.ts +4 -1
  93. package/dist/entity/tax-category/tax-category.entity.js +5 -0
  94. package/dist/entity/tax-category/tax-category.entity.js.map +1 -1
  95. package/dist/entity/tax-rate/tax-rate.entity.d.ts +4 -1
  96. package/dist/entity/tax-rate/tax-rate.entity.js +5 -0
  97. package/dist/entity/tax-rate/tax-rate.entity.js.map +1 -1
  98. package/dist/entity/zone/zone.entity.d.ts +4 -1
  99. package/dist/entity/zone/zone.entity.js +5 -0
  100. package/dist/entity/zone/zone.entity.js.map +1 -1
  101. package/dist/event-bus/events/account-verified-event.d.ts +16 -0
  102. package/dist/event-bus/events/account-verified-event.js +21 -0
  103. package/dist/event-bus/events/account-verified-event.js.map +1 -0
  104. package/dist/event-bus/events/administrator-event.d.ts +18 -0
  105. package/dist/event-bus/events/administrator-event.js +19 -0
  106. package/dist/event-bus/events/administrator-event.js.map +1 -0
  107. package/dist/event-bus/events/asset-event.d.ts +17 -9
  108. package/dist/event-bus/events/asset-event.js +15 -9
  109. package/dist/event-bus/events/asset-event.js.map +1 -1
  110. package/dist/event-bus/events/change-channel-event.d.ts +22 -0
  111. package/dist/event-bus/events/change-channel-event.js +25 -0
  112. package/dist/event-bus/events/change-channel-event.js.map +1 -0
  113. package/dist/event-bus/events/channel-event.d.ts +18 -0
  114. package/dist/event-bus/events/channel-event.js +19 -0
  115. package/dist/event-bus/events/channel-event.js.map +1 -0
  116. package/dist/event-bus/events/collection-event.d.ts +18 -0
  117. package/dist/event-bus/events/collection-event.js +19 -0
  118. package/dist/event-bus/events/collection-event.js.map +1 -0
  119. package/dist/event-bus/events/country-event.d.ts +18 -0
  120. package/dist/event-bus/events/country-event.js +19 -0
  121. package/dist/event-bus/events/country-event.js.map +1 -0
  122. package/dist/event-bus/events/coupon-code-event.d.ts +19 -0
  123. package/dist/event-bus/events/coupon-code-event.js +24 -0
  124. package/dist/event-bus/events/coupon-code-event.js.map +1 -0
  125. package/dist/event-bus/events/customer-address-event.d.ts +21 -6
  126. package/dist/event-bus/events/customer-address-event.js +16 -6
  127. package/dist/event-bus/events/customer-address-event.js.map +1 -1
  128. package/dist/event-bus/events/customer-event.d.ts +16 -6
  129. package/dist/event-bus/events/customer-event.js +13 -7
  130. package/dist/event-bus/events/customer-event.js.map +1 -1
  131. package/dist/event-bus/events/customer-group-entity-event.d.ts +19 -0
  132. package/dist/event-bus/events/customer-group-entity-event.js +21 -0
  133. package/dist/event-bus/events/customer-group-entity-event.js.map +1 -0
  134. package/dist/event-bus/events/customer-group-event.d.ts +17 -0
  135. package/dist/event-bus/events/customer-group-event.js +21 -1
  136. package/dist/event-bus/events/customer-group-event.js.map +1 -1
  137. package/dist/event-bus/events/facet-event.d.ts +18 -0
  138. package/dist/event-bus/events/facet-event.js +19 -0
  139. package/dist/event-bus/events/facet-event.js.map +1 -0
  140. package/dist/event-bus/events/facet-value-event.d.ts +18 -0
  141. package/dist/event-bus/events/facet-value-event.js +19 -0
  142. package/dist/event-bus/events/facet-value-event.js.map +1 -0
  143. package/dist/event-bus/events/fulfillment-event.d.ts +27 -0
  144. package/dist/event-bus/events/fulfillment-event.js +19 -0
  145. package/dist/event-bus/events/fulfillment-event.js.map +1 -0
  146. package/dist/event-bus/events/global-settings-event.d.ts +16 -0
  147. package/dist/event-bus/events/global-settings-event.js +20 -0
  148. package/dist/event-bus/events/global-settings-event.js.map +1 -0
  149. package/dist/event-bus/events/history-entry-event.d.ts +22 -0
  150. package/dist/event-bus/events/history-entry-event.js +20 -0
  151. package/dist/event-bus/events/history-entry-event.js.map +1 -0
  152. package/dist/event-bus/events/order-placed-event.d.ts +22 -0
  153. package/dist/event-bus/events/order-placed-event.js +26 -0
  154. package/dist/event-bus/events/order-placed-event.js.map +1 -0
  155. package/dist/event-bus/events/order-state-transition-event.js.map +1 -1
  156. package/dist/event-bus/events/password-reset-verified-event.d.ts +16 -0
  157. package/dist/event-bus/events/password-reset-verified-event.js +21 -0
  158. package/dist/event-bus/events/password-reset-verified-event.js.map +1 -0
  159. package/dist/event-bus/events/payment-method-event.d.ts +18 -0
  160. package/dist/event-bus/events/payment-method-event.js +19 -0
  161. package/dist/event-bus/events/payment-method-event.js.map +1 -0
  162. package/dist/event-bus/events/product-event.d.ts +14 -6
  163. package/dist/event-bus/events/product-event.js +13 -7
  164. package/dist/event-bus/events/product-event.js.map +1 -1
  165. package/dist/event-bus/events/product-option-event.d.ts +18 -0
  166. package/dist/event-bus/events/product-option-event.js +19 -0
  167. package/dist/event-bus/events/product-option-event.js.map +1 -0
  168. package/dist/event-bus/events/product-option-group-change-event.d.ts +19 -0
  169. package/dist/event-bus/events/product-option-group-change-event.js +23 -0
  170. package/dist/event-bus/events/product-option-group-change-event.js.map +1 -0
  171. package/dist/event-bus/events/product-option-group-event.d.ts +18 -0
  172. package/dist/event-bus/events/product-option-group-event.js +19 -0
  173. package/dist/event-bus/events/product-option-group-event.js.map +1 -0
  174. package/dist/event-bus/events/product-variant-event.d.ts +14 -6
  175. package/dist/event-bus/events/product-variant-event.js +13 -7
  176. package/dist/event-bus/events/product-variant-event.js.map +1 -1
  177. package/dist/event-bus/events/promotion-event.d.ts +18 -0
  178. package/dist/event-bus/events/promotion-event.js +19 -0
  179. package/dist/event-bus/events/promotion-event.js.map +1 -0
  180. package/dist/event-bus/events/role-change-event.d.ts +20 -0
  181. package/dist/event-bus/events/role-change-event.js +24 -0
  182. package/dist/event-bus/events/role-change-event.js.map +1 -0
  183. package/dist/event-bus/events/role-event.d.ts +18 -0
  184. package/dist/event-bus/events/role-event.js +19 -0
  185. package/dist/event-bus/events/role-event.js.map +1 -0
  186. package/dist/event-bus/events/shipping-method-event.d.ts +18 -0
  187. package/dist/event-bus/events/shipping-method-event.js +19 -0
  188. package/dist/event-bus/events/shipping-method-event.js.map +1 -0
  189. package/dist/event-bus/events/tax-category-event.d.ts +18 -0
  190. package/dist/event-bus/events/tax-category-event.js +19 -0
  191. package/dist/event-bus/events/tax-category-event.js.map +1 -0
  192. package/dist/event-bus/events/tax-rate-event.d.ts +18 -0
  193. package/dist/event-bus/events/tax-rate-event.js +19 -0
  194. package/dist/event-bus/events/tax-rate-event.js.map +1 -0
  195. package/dist/event-bus/events/tax-rate-modification-event.d.ts +1 -0
  196. package/dist/event-bus/events/tax-rate-modification-event.js +1 -0
  197. package/dist/event-bus/events/tax-rate-modification-event.js.map +1 -1
  198. package/dist/event-bus/events/zone-event.d.ts +18 -0
  199. package/dist/event-bus/events/zone-event.js +19 -0
  200. package/dist/event-bus/events/zone-event.js.map +1 -0
  201. package/dist/event-bus/events/zone-members-event.d.ts +19 -0
  202. package/dist/event-bus/events/zone-members-event.js +23 -0
  203. package/dist/event-bus/events/zone-members-event.js.map +1 -0
  204. package/dist/event-bus/index.d.ts +32 -4
  205. package/dist/event-bus/index.js +32 -4
  206. package/dist/event-bus/index.js.map +1 -1
  207. package/dist/event-bus/vendure-entity-event.d.ts +17 -0
  208. package/dist/event-bus/vendure-entity-event.js +23 -0
  209. package/dist/event-bus/vendure-entity-event.js.map +1 -0
  210. package/dist/i18n/messages/en.json +2 -1
  211. package/dist/plugin/default-search-plugin/api/fulltext-search.resolver.js +1 -1
  212. package/dist/plugin/default-search-plugin/api/fulltext-search.resolver.js.map +1 -1
  213. package/dist/plugin/default-search-plugin/indexer/indexer.controller.js +1 -1
  214. package/dist/plugin/default-search-plugin/indexer/indexer.controller.js.map +1 -1
  215. package/dist/plugin/default-search-plugin/search-strategy/mysql-search-strategy.js +1 -1
  216. package/dist/plugin/default-search-plugin/search-strategy/mysql-search-strategy.js.map +1 -1
  217. package/dist/service/helpers/entity-hydrator/entity-hydrator.service.d.ts +7 -0
  218. package/dist/service/helpers/entity-hydrator/entity-hydrator.service.js +28 -1
  219. package/dist/service/helpers/entity-hydrator/entity-hydrator.service.js.map +1 -1
  220. package/dist/service/helpers/order-calculator/order-calculator.js +3 -0
  221. package/dist/service/helpers/order-calculator/order-calculator.js.map +1 -1
  222. package/dist/service/helpers/order-state-machine/order-state-machine.d.ts +3 -1
  223. package/dist/service/helpers/order-state-machine/order-state-machine.js +10 -2
  224. package/dist/service/helpers/order-state-machine/order-state-machine.js.map +1 -1
  225. package/dist/service/helpers/product-price-applicator/product-price-applicator.js +1 -1
  226. package/dist/service/services/administrator.service.d.ts +3 -1
  227. package/dist/service/services/administrator.service.js +16 -2
  228. package/dist/service/services/administrator.service.js.map +1 -1
  229. package/dist/service/services/asset.service.js +14 -6
  230. package/dist/service/services/asset.service.js.map +1 -1
  231. package/dist/service/services/channel.service.d.ts +4 -2
  232. package/dist/service/services/channel.service.js +14 -3
  233. package/dist/service/services/channel.service.js.map +1 -1
  234. package/dist/service/services/collection.service.js +11 -4
  235. package/dist/service/services/collection.service.js.map +1 -1
  236. package/dist/service/services/country.service.d.ts +3 -3
  237. package/dist/service/services/country.service.js +8 -4
  238. package/dist/service/services/country.service.js.map +1 -1
  239. package/dist/service/services/customer-group.service.js +8 -1
  240. package/dist/service/services/customer-group.service.js.map +1 -1
  241. package/dist/service/services/customer.service.js +13 -8
  242. package/dist/service/services/customer.service.js.map +1 -1
  243. package/dist/service/services/facet-value.service.d.ts +3 -1
  244. package/dist/service/services/facet-value.service.js +10 -3
  245. package/dist/service/services/facet-value.service.js.map +1 -1
  246. package/dist/service/services/facet.service.d.ts +3 -1
  247. package/dist/service/services/facet.service.js +10 -3
  248. package/dist/service/services/facet.service.js.map +1 -1
  249. package/dist/service/services/fulfillment.service.js +7 -1
  250. package/dist/service/services/fulfillment.service.js.map +1 -1
  251. package/dist/service/services/global-settings.service.d.ts +3 -1
  252. package/dist/service/services/global-settings.service.js +7 -2
  253. package/dist/service/services/global-settings.service.js.map +1 -1
  254. package/dist/service/services/history.service.d.ts +3 -1
  255. package/dist/service/services/history.service.js +20 -6
  256. package/dist/service/services/history.service.js.map +1 -1
  257. package/dist/service/services/order.service.d.ts +4 -1
  258. package/dist/service/services/order.service.js +67 -20
  259. package/dist/service/services/order.service.js.map +1 -1
  260. package/dist/service/services/payment-method.service.js +10 -1
  261. package/dist/service/services/payment-method.service.js.map +1 -1
  262. package/dist/service/services/product-option-group.service.d.ts +3 -1
  263. package/dist/service/services/product-option-group.service.js +9 -3
  264. package/dist/service/services/product-option-group.service.js.map +1 -1
  265. package/dist/service/services/product-option.service.d.ts +3 -1
  266. package/dist/service/services/product-option.service.js +9 -3
  267. package/dist/service/services/product-option.service.js.map +1 -1
  268. package/dist/service/services/product-variant.service.js +5 -4
  269. package/dist/service/services/product-variant.service.js.map +1 -1
  270. package/dist/service/services/product.service.d.ts +1 -1
  271. package/dist/service/services/product.service.js +8 -5
  272. package/dist/service/services/product.service.js.map +1 -1
  273. package/dist/service/services/promotion.service.d.ts +3 -1
  274. package/dist/service/services/promotion.service.js +10 -3
  275. package/dist/service/services/promotion.service.js.map +1 -1
  276. package/dist/service/services/role.service.d.ts +3 -1
  277. package/dist/service/services/role.service.js +12 -4
  278. package/dist/service/services/role.service.js.map +1 -1
  279. package/dist/service/services/shipping-method.service.d.ts +3 -1
  280. package/dist/service/services/shipping-method.service.js +10 -3
  281. package/dist/service/services/shipping-method.service.js.map +1 -1
  282. package/dist/service/services/stock-movement.service.d.ts +11 -0
  283. package/dist/service/services/stock-movement.service.js +15 -5
  284. package/dist/service/services/stock-movement.service.js.map +1 -1
  285. package/dist/service/services/tax-category.service.d.ts +3 -1
  286. package/dist/service/services/tax-category.service.js +8 -2
  287. package/dist/service/services/tax-category.service.js.map +1 -1
  288. package/dist/service/services/tax-rate.service.js +4 -0
  289. package/dist/service/services/tax-rate.service.js.map +1 -1
  290. package/dist/service/services/zone.service.d.ts +5 -3
  291. package/dist/service/services/zone.service.js +24 -12
  292. package/dist/service/services/zone.service.js.map +1 -1
  293. package/package.json +5 -5
@@ -0,0 +1,22 @@
1
+ import { HistoryEntryType } from '@vendure/common/lib/generated-types';
2
+ import { ID } from '@vendure/common/lib/shared-types';
3
+ import { RequestContext } from '../../api/common/request-context';
4
+ import { HistoryEntry } from '../../entity/history-entry/history-entry.entity';
5
+ import { VendureEntityEvent } from '../vendure-entity-event';
6
+ declare type HistoryInput = {
7
+ type: HistoryEntryType;
8
+ data?: any;
9
+ } | ID;
10
+ /**
11
+ * @description
12
+ * This event is fired whenever one {@link HistoryEntry} is added, updated or deleted.
13
+ *
14
+ * @docsCategory events
15
+ * @docsPage Event Types
16
+ * @since 1.4
17
+ */
18
+ export declare class HistoryEntryEvent extends VendureEntityEvent<HistoryEntry, HistoryInput> {
19
+ readonly historyType: 'order' | 'customer' | string;
20
+ constructor(ctx: RequestContext, entity: HistoryEntry, type: 'created' | 'updated' | 'deleted', historyType: 'order' | 'customer' | string, input?: HistoryInput);
21
+ }
22
+ export {};
@@ -0,0 +1,20 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.HistoryEntryEvent = void 0;
4
+ const vendure_entity_event_1 = require("../vendure-entity-event");
5
+ /**
6
+ * @description
7
+ * This event is fired whenever one {@link HistoryEntry} is added, updated or deleted.
8
+ *
9
+ * @docsCategory events
10
+ * @docsPage Event Types
11
+ * @since 1.4
12
+ */
13
+ class HistoryEntryEvent extends vendure_entity_event_1.VendureEntityEvent {
14
+ constructor(ctx, entity, type, historyType, input) {
15
+ super(entity, type, ctx, input);
16
+ this.historyType = historyType;
17
+ }
18
+ }
19
+ exports.HistoryEntryEvent = HistoryEntryEvent;
20
+ //# sourceMappingURL=history-entry-event.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"history-entry-event.js","sourceRoot":"","sources":["../../../src/event-bus/events/history-entry-event.ts"],"names":[],"mappings":";;;AAKA,kEAA6D;AAS7D;;;;;;;GAOG;AACH,MAAa,iBAAkB,SAAQ,yCAA8C;IAGjF,YACI,GAAmB,EACnB,MAAoB,EACpB,IAAuC,EACvC,WAA0C,EAC1C,KAAoB;QAEpB,KAAK,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,EAAE,KAAK,CAAC,CAAC;QAChC,IAAI,CAAC,WAAW,GAAG,WAAW,CAAC;IACnC,CAAC;CACJ;AAbD,8CAaC"}
@@ -0,0 +1,22 @@
1
+ import { RequestContext } from '../../api/common/request-context';
2
+ import { Order } from '../../entity/order/order.entity';
3
+ import { OrderState } from '../../service/helpers/order-state-machine/order-state';
4
+ import { VendureEvent } from '../vendure-event';
5
+ /**
6
+ * @description
7
+ * This event is fired whenever an {@link Order} is set as "placed", which by default is
8
+ * when it transitions from 'ArrangingPayment' to either 'PaymentAuthorized' or 'PaymentSettled'.
9
+ *
10
+ * Note that the exact point that it is set as "placed" can be configured according to the
11
+ * {@link OrderPlacedStrategy}.
12
+ *
13
+ * @docsCategory events
14
+ * @docsPage Event Types
15
+ */
16
+ export declare class OrderPlacedEvent extends VendureEvent {
17
+ fromState: OrderState;
18
+ toState: OrderState;
19
+ ctx: RequestContext;
20
+ order: Order;
21
+ constructor(fromState: OrderState, toState: OrderState, ctx: RequestContext, order: Order);
22
+ }
@@ -0,0 +1,26 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.OrderPlacedEvent = void 0;
4
+ const vendure_event_1 = require("../vendure-event");
5
+ /**
6
+ * @description
7
+ * This event is fired whenever an {@link Order} is set as "placed", which by default is
8
+ * when it transitions from 'ArrangingPayment' to either 'PaymentAuthorized' or 'PaymentSettled'.
9
+ *
10
+ * Note that the exact point that it is set as "placed" can be configured according to the
11
+ * {@link OrderPlacedStrategy}.
12
+ *
13
+ * @docsCategory events
14
+ * @docsPage Event Types
15
+ */
16
+ class OrderPlacedEvent extends vendure_event_1.VendureEvent {
17
+ constructor(fromState, toState, ctx, order) {
18
+ super();
19
+ this.fromState = fromState;
20
+ this.toState = toState;
21
+ this.ctx = ctx;
22
+ this.order = order;
23
+ }
24
+ }
25
+ exports.OrderPlacedEvent = OrderPlacedEvent;
26
+ //# sourceMappingURL=order-placed-event.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"order-placed-event.js","sourceRoot":"","sources":["../../../src/event-bus/events/order-placed-event.ts"],"names":[],"mappings":";;;AAGA,oDAAgD;AAEhD;;;;;;;;;;GAUG;AACH,MAAa,gBAAiB,SAAQ,4BAAY;IAC9C,YACW,SAAqB,EACrB,OAAmB,EACnB,GAAmB,EACnB,KAAY;QAEnB,KAAK,EAAE,CAAC;QALD,cAAS,GAAT,SAAS,CAAY;QACrB,YAAO,GAAP,OAAO,CAAY;QACnB,QAAG,GAAH,GAAG,CAAgB;QACnB,UAAK,GAAL,KAAK,CAAO;IAGvB,CAAC;CACJ;AATD,4CASC"}
@@ -1 +1 @@
1
- {"version":3,"file":"order-state-transition-event.js","sourceRoot":"","sources":["../../../src/event-bus/events/order-state-transition-event.ts"],"names":[],"mappings":";;;AAIA,oDAAgD;AAEhD;;;;;;GAMG;AACH,MAAa,yBAA0B,SAAQ,4BAAY;IACvD,YACW,SAAqB,EACrB,OAAmB,EACnB,GAAmB,EACnB,KAAY;QAEnB,KAAK,EAAE,CAAC;QALD,cAAS,GAAT,SAAS,CAAY;QACrB,YAAO,GAAP,OAAO,CAAY;QACnB,QAAG,GAAH,GAAG,CAAgB;QACnB,UAAK,GAAL,KAAK,CAAO;IAGvB,CAAC;CACJ;AATD,8DASC"}
1
+ {"version":3,"file":"order-state-transition-event.js","sourceRoot":"","sources":["../../../src/event-bus/events/order-state-transition-event.ts"],"names":[],"mappings":";;;AAGA,oDAAgD;AAEhD;;;;;;GAMG;AACH,MAAa,yBAA0B,SAAQ,4BAAY;IACvD,YACW,SAAqB,EACrB,OAAmB,EACnB,GAAmB,EACnB,KAAY;QAEnB,KAAK,EAAE,CAAC;QALD,cAAS,GAAT,SAAS,CAAY;QACrB,YAAO,GAAP,OAAO,CAAY;QACnB,QAAG,GAAH,GAAG,CAAgB;QACnB,UAAK,GAAL,KAAK,CAAO;IAGvB,CAAC;CACJ;AATD,8DASC"}
@@ -0,0 +1,16 @@
1
+ import { RequestContext } from '../../api/common/request-context';
2
+ import { User } from '../../entity/user/user.entity';
3
+ import { VendureEvent } from '../vendure-event';
4
+ /**
5
+ * @description
6
+ * This event is fired when a password reset is executed with a verified token.
7
+ *
8
+ * @docsCategory events
9
+ * @docsPage Event Types
10
+ * @since 1.4
11
+ */
12
+ export declare class PasswordResetVerifiedEvent extends VendureEvent {
13
+ ctx: RequestContext;
14
+ user: User;
15
+ constructor(ctx: RequestContext, user: User);
16
+ }
@@ -0,0 +1,21 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.PasswordResetVerifiedEvent = void 0;
4
+ const vendure_event_1 = require("../vendure-event");
5
+ /**
6
+ * @description
7
+ * This event is fired when a password reset is executed with a verified token.
8
+ *
9
+ * @docsCategory events
10
+ * @docsPage Event Types
11
+ * @since 1.4
12
+ */
13
+ class PasswordResetVerifiedEvent extends vendure_event_1.VendureEvent {
14
+ constructor(ctx, user) {
15
+ super();
16
+ this.ctx = ctx;
17
+ this.user = user;
18
+ }
19
+ }
20
+ exports.PasswordResetVerifiedEvent = PasswordResetVerifiedEvent;
21
+ //# sourceMappingURL=password-reset-verified-event.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"password-reset-verified-event.js","sourceRoot":"","sources":["../../../src/event-bus/events/password-reset-verified-event.ts"],"names":[],"mappings":";;;AAEA,oDAAgD;AAEhD;;;;;;;GAOG;AACH,MAAa,0BAA2B,SAAQ,4BAAY;IACxD,YAAmB,GAAmB,EAAS,IAAU;QACrD,KAAK,EAAE,CAAC;QADO,QAAG,GAAH,GAAG,CAAgB;QAAS,SAAI,GAAJ,IAAI,CAAM;IAEzD,CAAC;CACJ;AAJD,gEAIC"}
@@ -0,0 +1,18 @@
1
+ import { CreatePaymentMethodInput, UpdatePaymentMethodInput } from '@vendure/common/lib/generated-types';
2
+ import { ID } from '@vendure/common/lib/shared-types';
3
+ import { RequestContext } from '../../api/common/request-context';
4
+ import { PaymentMethod } from '../../entity';
5
+ import { VendureEntityEvent } from '../vendure-entity-event';
6
+ declare type PaymentMethodInputTypes = CreatePaymentMethodInput | UpdatePaymentMethodInput | ID;
7
+ /**
8
+ * @description
9
+ * This event is fired whenever a {@link PaymentMethod} is added, updated
10
+ * or deleted.
11
+ *
12
+ * @docsCategory events
13
+ * @docsPage Event Types
14
+ */
15
+ export declare class PaymentMethodEvent extends VendureEntityEvent<PaymentMethod, PaymentMethodInputTypes> {
16
+ constructor(ctx: RequestContext, entity: PaymentMethod, type: 'created' | 'updated' | 'deleted', input?: PaymentMethodInputTypes);
17
+ }
18
+ export {};
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.PaymentMethodEvent = void 0;
4
+ const vendure_entity_event_1 = require("../vendure-entity-event");
5
+ /**
6
+ * @description
7
+ * This event is fired whenever a {@link PaymentMethod} is added, updated
8
+ * or deleted.
9
+ *
10
+ * @docsCategory events
11
+ * @docsPage Event Types
12
+ */
13
+ class PaymentMethodEvent extends vendure_entity_event_1.VendureEntityEvent {
14
+ constructor(ctx, entity, type, input) {
15
+ super(entity, type, ctx, input);
16
+ }
17
+ }
18
+ exports.PaymentMethodEvent = PaymentMethodEvent;
19
+ //# sourceMappingURL=payment-method-event.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"payment-method-event.js","sourceRoot":"","sources":["../../../src/event-bus/events/payment-method-event.ts"],"names":[],"mappings":";;;AAKA,kEAA6D;AAI7D;;;;;;;GAOG;AACH,MAAa,kBAAmB,SAAQ,yCAA0D;IAC9F,YACI,GAAmB,EACnB,MAAqB,EACrB,IAAuC,EACvC,KAA+B;QAE/B,KAAK,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,EAAE,KAAK,CAAC,CAAC;IACpC,CAAC;CACJ;AATD,gDASC"}
@@ -1,6 +1,9 @@
1
+ import { CreateProductInput, UpdateProductInput } from '@vendure/common/lib/generated-types';
2
+ import { ID } from '@vendure/common/lib/shared-types';
1
3
  import { RequestContext } from '../../api/common/request-context';
2
4
  import { Product } from '../../entity';
3
- import { VendureEvent } from '../vendure-event';
5
+ import { VendureEntityEvent } from '../vendure-entity-event';
6
+ declare type ProductInputTypes = CreateProductInput | UpdateProductInput | ID;
4
7
  /**
5
8
  * @description
6
9
  * This event is fired whenever a {@link Product} is added, updated
@@ -9,9 +12,14 @@ import { VendureEvent } from '../vendure-event';
9
12
  * @docsCategory events
10
13
  * @docsPage Event Types
11
14
  */
12
- export declare class ProductEvent extends VendureEvent {
13
- ctx: RequestContext;
14
- product: Product;
15
- type: 'created' | 'updated' | 'deleted';
16
- constructor(ctx: RequestContext, product: Product, type: 'created' | 'updated' | 'deleted');
15
+ export declare class ProductEvent extends VendureEntityEvent<Product, ProductInputTypes> {
16
+ constructor(ctx: RequestContext, entity: Product, type: 'created' | 'updated' | 'deleted', input?: ProductInputTypes);
17
+ /**
18
+ * Return an product field to become compatible with the
19
+ * deprecated old version of ProductEvent
20
+ * @deprecated Use `entity` instead
21
+ * @since 1.4
22
+ */
23
+ get product(): Product;
17
24
  }
25
+ export {};
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.ProductEvent = void 0;
4
- const vendure_event_1 = require("../vendure-event");
4
+ const vendure_entity_event_1 = require("../vendure-entity-event");
5
5
  /**
6
6
  * @description
7
7
  * This event is fired whenever a {@link Product} is added, updated
@@ -10,12 +10,18 @@ const vendure_event_1 = require("../vendure-event");
10
10
  * @docsCategory events
11
11
  * @docsPage Event Types
12
12
  */
13
- class ProductEvent extends vendure_event_1.VendureEvent {
14
- constructor(ctx, product, type) {
15
- super();
16
- this.ctx = ctx;
17
- this.product = product;
18
- this.type = type;
13
+ class ProductEvent extends vendure_entity_event_1.VendureEntityEvent {
14
+ constructor(ctx, entity, type, input) {
15
+ super(entity, type, ctx, input);
16
+ }
17
+ /**
18
+ * Return an product field to become compatible with the
19
+ * deprecated old version of ProductEvent
20
+ * @deprecated Use `entity` instead
21
+ * @since 1.4
22
+ */
23
+ get product() {
24
+ return this.entity;
19
25
  }
20
26
  }
21
27
  exports.ProductEvent = ProductEvent;
@@ -1 +1 @@
1
- {"version":3,"file":"product-event.js","sourceRoot":"","sources":["../../../src/event-bus/events/product-event.ts"],"names":[],"mappings":";;;AAEA,oDAAgD;AAEhD;;;;;;;GAOG;AACH,MAAa,YAAa,SAAQ,4BAAY;IAC1C,YACW,GAAmB,EACnB,OAAgB,EAChB,IAAuC;QAE9C,KAAK,EAAE,CAAC;QAJD,QAAG,GAAH,GAAG,CAAgB;QACnB,YAAO,GAAP,OAAO,CAAS;QAChB,SAAI,GAAJ,IAAI,CAAmC;IAGlD,CAAC;CACJ;AARD,oCAQC"}
1
+ {"version":3,"file":"product-event.js","sourceRoot":"","sources":["../../../src/event-bus/events/product-event.ts"],"names":[],"mappings":";;;AAKA,kEAA6D;AAI7D;;;;;;;GAOG;AACH,MAAa,YAAa,SAAQ,yCAA8C;IAC5E,YACI,GAAmB,EACnB,MAAe,EACf,IAAuC,EACvC,KAAyB;QAEzB,KAAK,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,EAAE,KAAK,CAAC,CAAC;IACpC,CAAC;IAED;;;;;OAKG;IACH,IAAI,OAAO;QACP,OAAO,IAAI,CAAC,MAAM,CAAC;IACvB,CAAC;CACJ;AAnBD,oCAmBC"}
@@ -0,0 +1,18 @@
1
+ import { CreateGroupOptionInput, CreateProductOptionInput, UpdateProductOptionInput } from '@vendure/common/lib/generated-types';
2
+ import { ID } from '@vendure/common/lib/shared-types';
3
+ import { RequestContext } from '../../api/common/request-context';
4
+ import { ProductOption } from '../../entity';
5
+ import { VendureEntityEvent } from '../vendure-entity-event';
6
+ declare type ProductOptionInputTypes = CreateGroupOptionInput | CreateProductOptionInput | UpdateProductOptionInput | ID;
7
+ /**
8
+ * @description
9
+ * This event is fired whenever a {@link ProductOption} is added or updated.
10
+ *
11
+ * @docsCategory events
12
+ * @docsPage Event Types
13
+ * @since 1.4
14
+ */
15
+ export declare class ProductOptionEvent extends VendureEntityEvent<ProductOption, ProductOptionInputTypes> {
16
+ constructor(ctx: RequestContext, entity: ProductOption, type: 'created' | 'updated', input?: ProductOptionInputTypes);
17
+ }
18
+ export {};
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ProductOptionEvent = void 0;
4
+ const vendure_entity_event_1 = require("../vendure-entity-event");
5
+ /**
6
+ * @description
7
+ * This event is fired whenever a {@link ProductOption} is added or updated.
8
+ *
9
+ * @docsCategory events
10
+ * @docsPage Event Types
11
+ * @since 1.4
12
+ */
13
+ class ProductOptionEvent extends vendure_entity_event_1.VendureEntityEvent {
14
+ constructor(ctx, entity, type, input) {
15
+ super(entity, type, ctx, input);
16
+ }
17
+ }
18
+ exports.ProductOptionEvent = ProductOptionEvent;
19
+ //# sourceMappingURL=product-option-event.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"product-option-event.js","sourceRoot":"","sources":["../../../src/event-bus/events/product-option-event.ts"],"names":[],"mappings":";;;AASA,kEAA6D;AAQ7D;;;;;;;GAOG;AACH,MAAa,kBAAmB,SAAQ,yCAA0D;IAC9F,YACI,GAAmB,EACnB,MAAqB,EACrB,IAA2B,EAC3B,KAA+B;QAE/B,KAAK,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,EAAE,KAAK,CAAC,CAAC;IACpC,CAAC;CACJ;AATD,gDASC"}
@@ -0,0 +1,19 @@
1
+ import { ID } from '@vendure/common/lib/shared-types';
2
+ import { RequestContext } from '../../api/common/request-context';
3
+ import { Product } from '../../entity';
4
+ import { VendureEvent } from '../vendure-event';
5
+ /**
6
+ * @description
7
+ * This event is fired whenever a {@link ProductOptionGroup} is assigned or removed from a {@link Product}.
8
+ *
9
+ * @docsCategory events
10
+ * @docsPage Event Types
11
+ * @since 1.4
12
+ */
13
+ export declare class ProductOptionGroupChangeEvent extends VendureEvent {
14
+ ctx: RequestContext;
15
+ product: Product;
16
+ optionGroupId: ID;
17
+ type: 'assigned' | 'removed';
18
+ constructor(ctx: RequestContext, product: Product, optionGroupId: ID, type: 'assigned' | 'removed');
19
+ }
@@ -0,0 +1,23 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ProductOptionGroupChangeEvent = void 0;
4
+ const vendure_event_1 = require("../vendure-event");
5
+ /**
6
+ * @description
7
+ * This event is fired whenever a {@link ProductOptionGroup} is assigned or removed from a {@link Product}.
8
+ *
9
+ * @docsCategory events
10
+ * @docsPage Event Types
11
+ * @since 1.4
12
+ */
13
+ class ProductOptionGroupChangeEvent extends vendure_event_1.VendureEvent {
14
+ constructor(ctx, product, optionGroupId, type) {
15
+ super();
16
+ this.ctx = ctx;
17
+ this.product = product;
18
+ this.optionGroupId = optionGroupId;
19
+ this.type = type;
20
+ }
21
+ }
22
+ exports.ProductOptionGroupChangeEvent = ProductOptionGroupChangeEvent;
23
+ //# sourceMappingURL=product-option-group-change-event.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"product-option-group-change-event.js","sourceRoot":"","sources":["../../../src/event-bus/events/product-option-group-change-event.ts"],"names":[],"mappings":";;;AAIA,oDAAgD;AAEhD;;;;;;;GAOG;AACH,MAAa,6BAA8B,SAAQ,4BAAY;IAC3D,YACW,GAAmB,EACnB,OAAgB,EAChB,aAAiB,EACjB,IAA4B;QAEnC,KAAK,EAAE,CAAC;QALD,QAAG,GAAH,GAAG,CAAgB;QACnB,YAAO,GAAP,OAAO,CAAS;QAChB,kBAAa,GAAb,aAAa,CAAI;QACjB,SAAI,GAAJ,IAAI,CAAwB;IAGvC,CAAC;CACJ;AATD,sEASC"}
@@ -0,0 +1,18 @@
1
+ import { CreateProductOptionGroupInput, UpdateProductOptionGroupInput } from '@vendure/common/lib/generated-types';
2
+ import { ID } from '@vendure/common/lib/shared-types';
3
+ import { RequestContext } from '../../api/common/request-context';
4
+ import { ProductOptionGroup } from '../../entity';
5
+ import { VendureEntityEvent } from '../vendure-entity-event';
6
+ declare type ProductOptionGroupInputTypes = CreateProductOptionGroupInput | UpdateProductOptionGroupInput | ID;
7
+ /**
8
+ * @description
9
+ * This event is fired whenever a {@link ProductOptionGroup} is added or updated.
10
+ *
11
+ * @docsCategory events
12
+ * @docsPage Event Types
13
+ * @since 1.4
14
+ */
15
+ export declare class ProductOptionGroupEvent extends VendureEntityEvent<ProductOptionGroup, ProductOptionGroupInputTypes> {
16
+ constructor(ctx: RequestContext, entity: ProductOptionGroup, type: 'created' | 'updated', input?: ProductOptionGroupInputTypes);
17
+ }
18
+ export {};
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ProductOptionGroupEvent = void 0;
4
+ const vendure_entity_event_1 = require("../vendure-entity-event");
5
+ /**
6
+ * @description
7
+ * This event is fired whenever a {@link ProductOptionGroup} is added or updated.
8
+ *
9
+ * @docsCategory events
10
+ * @docsPage Event Types
11
+ * @since 1.4
12
+ */
13
+ class ProductOptionGroupEvent extends vendure_entity_event_1.VendureEntityEvent {
14
+ constructor(ctx, entity, type, input) {
15
+ super(entity, type, ctx, input);
16
+ }
17
+ }
18
+ exports.ProductOptionGroupEvent = ProductOptionGroupEvent;
19
+ //# sourceMappingURL=product-option-group-event.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"product-option-group-event.js","sourceRoot":"","sources":["../../../src/event-bus/events/product-option-group-event.ts"],"names":[],"mappings":";;;AAQA,kEAA6D;AAI7D;;;;;;;GAOG;AACH,MAAa,uBAAwB,SAAQ,yCAG5C;IACG,YACI,GAAmB,EACnB,MAA0B,EAC1B,IAA2B,EAC3B,KAAoC;QAEpC,KAAK,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,EAAE,KAAK,CAAC,CAAC;IACpC,CAAC;CACJ;AAZD,0DAYC"}
@@ -1,6 +1,9 @@
1
+ import { CreateProductVariantInput, UpdateProductVariantInput } from '@vendure/common/lib/generated-types';
2
+ import { ID } from '@vendure/common/lib/shared-types';
1
3
  import { RequestContext } from '../../api/common/request-context';
2
4
  import { ProductVariant } from '../../entity';
3
- import { VendureEvent } from '../vendure-event';
5
+ import { VendureEntityEvent } from '../vendure-entity-event';
6
+ declare type ProductVariantInputTypes = CreateProductVariantInput[] | UpdateProductVariantInput[] | ID | ID[];
4
7
  /**
5
8
  * @description
6
9
  * This event is fired whenever a {@link ProductVariant} is added, updated
@@ -9,9 +12,14 @@ import { VendureEvent } from '../vendure-event';
9
12
  * @docsCategory events
10
13
  * @docsPage Event Types
11
14
  */
12
- export declare class ProductVariantEvent extends VendureEvent {
13
- ctx: RequestContext;
14
- variants: ProductVariant[];
15
- type: 'created' | 'updated' | 'deleted';
16
- constructor(ctx: RequestContext, variants: ProductVariant[], type: 'created' | 'updated' | 'deleted');
15
+ export declare class ProductVariantEvent extends VendureEntityEvent<ProductVariant[], ProductVariantInputTypes> {
16
+ constructor(ctx: RequestContext, entity: ProductVariant[], type: 'created' | 'updated' | 'deleted', input?: ProductVariantInputTypes);
17
+ /**
18
+ * Return an variants field to become compatible with the
19
+ * deprecated old version of ProductEvent
20
+ * @deprecated Use `entity` instead
21
+ * @since 1.4
22
+ */
23
+ get variants(): ProductVariant[];
17
24
  }
25
+ export {};
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.ProductVariantEvent = void 0;
4
- const vendure_event_1 = require("../vendure-event");
4
+ const vendure_entity_event_1 = require("../vendure-entity-event");
5
5
  /**
6
6
  * @description
7
7
  * This event is fired whenever a {@link ProductVariant} is added, updated
@@ -10,12 +10,18 @@ const vendure_event_1 = require("../vendure-event");
10
10
  * @docsCategory events
11
11
  * @docsPage Event Types
12
12
  */
13
- class ProductVariantEvent extends vendure_event_1.VendureEvent {
14
- constructor(ctx, variants, type) {
15
- super();
16
- this.ctx = ctx;
17
- this.variants = variants;
18
- this.type = type;
13
+ class ProductVariantEvent extends vendure_entity_event_1.VendureEntityEvent {
14
+ constructor(ctx, entity, type, input) {
15
+ super(entity, type, ctx, input);
16
+ }
17
+ /**
18
+ * Return an variants field to become compatible with the
19
+ * deprecated old version of ProductEvent
20
+ * @deprecated Use `entity` instead
21
+ * @since 1.4
22
+ */
23
+ get variants() {
24
+ return this.entity;
19
25
  }
20
26
  }
21
27
  exports.ProductVariantEvent = ProductVariantEvent;
@@ -1 +1 @@
1
- {"version":3,"file":"product-variant-event.js","sourceRoot":"","sources":["../../../src/event-bus/events/product-variant-event.ts"],"names":[],"mappings":";;;AAEA,oDAAgD;AAEhD;;;;;;;GAOG;AACH,MAAa,mBAAoB,SAAQ,4BAAY;IACjD,YACW,GAAmB,EACnB,QAA0B,EAC1B,IAAuC;QAE9C,KAAK,EAAE,CAAC;QAJD,QAAG,GAAH,GAAG,CAAgB;QACnB,aAAQ,GAAR,QAAQ,CAAkB;QAC1B,SAAI,GAAJ,IAAI,CAAmC;IAGlD,CAAC;CACJ;AARD,kDAQC"}
1
+ {"version":3,"file":"product-variant-event.js","sourceRoot":"","sources":["../../../src/event-bus/events/product-variant-event.ts"],"names":[],"mappings":";;;AAKA,kEAA6D;AAI7D;;;;;;;GAOG;AACH,MAAa,mBAAoB,SAAQ,yCAA8D;IACnG,YACI,GAAmB,EACnB,MAAwB,EACxB,IAAuC,EACvC,KAAgC;QAEhC,KAAK,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,EAAE,KAAK,CAAC,CAAC;IACpC,CAAC;IAED;;;;;OAKG;IACH,IAAI,QAAQ;QACR,OAAO,IAAI,CAAC,MAAM,CAAC;IACvB,CAAC;CACJ;AAnBD,kDAmBC"}
@@ -0,0 +1,18 @@
1
+ import { CreatePromotionInput, UpdatePromotionInput } from '@vendure/common/lib/generated-types';
2
+ import { ID } from '@vendure/common/lib/shared-types';
3
+ import { RequestContext } from '../../api/common/request-context';
4
+ import { Promotion } from '../../entity';
5
+ import { VendureEntityEvent } from '../vendure-entity-event';
6
+ declare type PromotionInputTypes = CreatePromotionInput | UpdatePromotionInput | ID;
7
+ /**
8
+ * @description
9
+ * This event is fired whenever a {@link Promotion} is added, updated
10
+ * or deleted.
11
+ *
12
+ * @docsCategory events
13
+ * @docsPage Event Types
14
+ */
15
+ export declare class PromotionEvent extends VendureEntityEvent<Promotion, PromotionInputTypes> {
16
+ constructor(ctx: RequestContext, entity: Promotion, type: 'created' | 'updated' | 'deleted', input?: PromotionInputTypes);
17
+ }
18
+ export {};
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.PromotionEvent = void 0;
4
+ const vendure_entity_event_1 = require("../vendure-entity-event");
5
+ /**
6
+ * @description
7
+ * This event is fired whenever a {@link Promotion} is added, updated
8
+ * or deleted.
9
+ *
10
+ * @docsCategory events
11
+ * @docsPage Event Types
12
+ */
13
+ class PromotionEvent extends vendure_entity_event_1.VendureEntityEvent {
14
+ constructor(ctx, entity, type, input) {
15
+ super(entity, type, ctx, input);
16
+ }
17
+ }
18
+ exports.PromotionEvent = PromotionEvent;
19
+ //# sourceMappingURL=promotion-event.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"promotion-event.js","sourceRoot":"","sources":["../../../src/event-bus/events/promotion-event.ts"],"names":[],"mappings":";;;AAKA,kEAA6D;AAI7D;;;;;;;GAOG;AACH,MAAa,cAAe,SAAQ,yCAAkD;IAClF,YACI,GAAmB,EACnB,MAAiB,EACjB,IAAuC,EACvC,KAA2B;QAE3B,KAAK,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,EAAE,KAAK,CAAC,CAAC;IACpC,CAAC;CACJ;AATD,wCASC"}
@@ -0,0 +1,20 @@
1
+ import { ID } from '@vendure/common/lib/shared-types';
2
+ import { RequestContext } from '../../api/common/request-context';
3
+ import { Administrator } from '../../entity';
4
+ import { VendureEvent } from '../vendure-event';
5
+ /**
6
+ * @description
7
+ * This event is fired whenever one {@link Role} is assigned or removed from a user.
8
+ * The property `roleIds` only contains the removed or assigned role ids.
9
+ *
10
+ * @docsCategory events
11
+ * @docsPage Event Types
12
+ * @since 1.4
13
+ */
14
+ export declare class RoleChangeEvent extends VendureEvent {
15
+ ctx: RequestContext;
16
+ admin: Administrator;
17
+ roleIds: ID[];
18
+ type: 'assigned' | 'removed';
19
+ constructor(ctx: RequestContext, admin: Administrator, roleIds: ID[], type: 'assigned' | 'removed');
20
+ }
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.RoleChangeEvent = void 0;
4
+ const vendure_event_1 = require("../vendure-event");
5
+ /**
6
+ * @description
7
+ * This event is fired whenever one {@link Role} is assigned or removed from a user.
8
+ * The property `roleIds` only contains the removed or assigned role ids.
9
+ *
10
+ * @docsCategory events
11
+ * @docsPage Event Types
12
+ * @since 1.4
13
+ */
14
+ class RoleChangeEvent extends vendure_event_1.VendureEvent {
15
+ constructor(ctx, admin, roleIds, type) {
16
+ super();
17
+ this.ctx = ctx;
18
+ this.admin = admin;
19
+ this.roleIds = roleIds;
20
+ this.type = type;
21
+ }
22
+ }
23
+ exports.RoleChangeEvent = RoleChangeEvent;
24
+ //# sourceMappingURL=role-change-event.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"role-change-event.js","sourceRoot":"","sources":["../../../src/event-bus/events/role-change-event.ts"],"names":[],"mappings":";;;AAIA,oDAAgD;AAEhD;;;;;;;;GAQG;AACH,MAAa,eAAgB,SAAQ,4BAAY;IAC7C,YACW,GAAmB,EACnB,KAAoB,EACpB,OAAa,EACb,IAA4B;QAEnC,KAAK,EAAE,CAAC;QALD,QAAG,GAAH,GAAG,CAAgB;QACnB,UAAK,GAAL,KAAK,CAAe;QACpB,YAAO,GAAP,OAAO,CAAM;QACb,SAAI,GAAJ,IAAI,CAAwB;IAGvC,CAAC;CACJ;AATD,0CASC"}
@@ -0,0 +1,18 @@
1
+ import { CreateRoleInput, UpdateRoleInput } from '@vendure/common/lib/generated-types';
2
+ import { ID } from '@vendure/common/lib/shared-types';
3
+ import { RequestContext } from '../../api/common/request-context';
4
+ import { Role } from '../../entity';
5
+ import { VendureEntityEvent } from '../vendure-entity-event';
6
+ declare type RoleInputTypes = CreateRoleInput | UpdateRoleInput | ID;
7
+ /**
8
+ * @description
9
+ * This event is fired whenever one {@link Role} is is added, updated or deleted.
10
+ *
11
+ * @docsCategory events
12
+ * @docsPage Event Types
13
+ * @since 1.4
14
+ */
15
+ export declare class RoleEvent extends VendureEntityEvent<Role, RoleInputTypes> {
16
+ constructor(ctx: RequestContext, entity: Role, type: 'created' | 'updated' | 'deleted', input?: RoleInputTypes);
17
+ }
18
+ export {};
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.RoleEvent = void 0;
4
+ const vendure_entity_event_1 = require("../vendure-entity-event");
5
+ /**
6
+ * @description
7
+ * This event is fired whenever one {@link Role} is is added, updated or deleted.
8
+ *
9
+ * @docsCategory events
10
+ * @docsPage Event Types
11
+ * @since 1.4
12
+ */
13
+ class RoleEvent extends vendure_entity_event_1.VendureEntityEvent {
14
+ constructor(ctx, entity, type, input) {
15
+ super(entity, type, ctx, input);
16
+ }
17
+ }
18
+ exports.RoleEvent = RoleEvent;
19
+ //# sourceMappingURL=role-event.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"role-event.js","sourceRoot":"","sources":["../../../src/event-bus/events/role-event.ts"],"names":[],"mappings":";;;AAKA,kEAA6D;AAI7D;;;;;;;GAOG;AACH,MAAa,SAAU,SAAQ,yCAAwC;IACnE,YACI,GAAmB,EACnB,MAAY,EACZ,IAAuC,EACvC,KAAsB;QAEtB,KAAK,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,EAAE,KAAK,CAAC,CAAC;IACpC,CAAC;CACJ;AATD,8BASC"}
@@ -0,0 +1,18 @@
1
+ import { CreateShippingMethodInput, UpdateShippingMethodInput } from '@vendure/common/lib/generated-types';
2
+ import { ID } from '@vendure/common/lib/shared-types';
3
+ import { RequestContext } from '../../api/common/request-context';
4
+ import { ShippingMethod } from '../../entity';
5
+ import { VendureEntityEvent } from '../vendure-entity-event';
6
+ declare type ShippingMethodInputTypes = CreateShippingMethodInput | UpdateShippingMethodInput | ID;
7
+ /**
8
+ * @description
9
+ * This event is fired whenever a {@link ShippingMethod} is added, updated
10
+ * or deleted.
11
+ *
12
+ * @docsCategory events
13
+ * @docsPage Event Types
14
+ */
15
+ export declare class ShippingMethodEvent extends VendureEntityEvent<ShippingMethod, ShippingMethodInputTypes> {
16
+ constructor(ctx: RequestContext, entity: ShippingMethod, type: 'created' | 'updated' | 'deleted', input?: ShippingMethodInputTypes);
17
+ }
18
+ export {};