@pisell/pisellos 0.0.441 → 0.0.442

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.
@@ -4103,17 +4103,22 @@ export var CheckoutImpl = /*#__PURE__*/function (_BaseModule) {
4103
4103
  payment_status: latestPaymentStatus
4104
4104
  });
4105
4105
  case 81:
4106
- // 最后同步一个支付项添加成功事件,让购物车那边也显示支付成功
4107
- // 触发支付项添加事件(可以复用支付开始事件)
4108
- this.core.effects.emit("".concat(this.name, ":onPaymentItemAdded"), {
4109
- orderUuid: orderUuid
4106
+ _context40.next = 83;
4107
+ return this.core.effects.emit("".concat(this.name, ":onOrderSynced"), {
4108
+ orderUuid: orderUuid,
4109
+ realOrderId: realOrderId,
4110
+ virtualOrderId: orderUuid,
4111
+ timestamp: Date.now(),
4112
+ isManual: false,
4113
+ response: checkoutResponse
4110
4114
  });
4115
+ case 83:
4111
4116
  return _context40.abrupt("return", {
4112
4117
  success: true,
4113
4118
  orderId: realOrderId,
4114
4119
  response: checkoutResponse
4115
4120
  });
4116
- case 83:
4121
+ case 84:
4117
4122
  case "end":
4118
4123
  return _context40.stop();
4119
4124
  }
@@ -2596,8 +2596,13 @@ var CheckoutImpl = class extends import_BaseModule.BaseModule {
2596
2596
  await this.payment.updateOrderAsync(orderUuid, {
2597
2597
  payment_status: latestPaymentStatus
2598
2598
  });
2599
- this.core.effects.emit(`${this.name}:onPaymentItemAdded`, {
2600
- orderUuid
2599
+ await this.core.effects.emit(`${this.name}:onOrderSynced`, {
2600
+ orderUuid,
2601
+ realOrderId,
2602
+ virtualOrderId: orderUuid,
2603
+ timestamp: Date.now(),
2604
+ isManual: false,
2605
+ response: checkoutResponse
2601
2606
  });
2602
2607
  return {
2603
2608
  success: true,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "private": false,
3
3
  "name": "@pisell/pisellos",
4
- "version": "0.0.441",
4
+ "version": "0.0.442",
5
5
  "description": "一个可扩展的前端模块化SDK框架,支持插件系统",
6
6
  "main": "dist/index.js",
7
7
  "types": "dist/index.d.ts",