@pisell/pisellos 2.2.138 → 2.2.140

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.
@@ -0,0 +1,9 @@
1
+ // 导出评估器
2
+ export { PromotionEvaluator } from "./evaluator";
3
+
4
+ // 导出适配器
5
+ export { PromotionAdapter } from "./adapter";
6
+ export { default } from "./adapter";
7
+
8
+ // 导出策略配置示例常量
9
+ export { X_ITEMS_FOR_Y_PRICE_STRATEGY, BUY_X_GET_Y_FREE_STRATEGY } from "./examples";
@@ -30,10 +30,10 @@ export function validateCheckoutData(params) {
30
30
  });
31
31
  }
32
32
 
33
- // 验证订单类型
34
- if (params.orderType && !['virtual', 'appointment_booking'].includes(params.orderType)) {
35
- errors.push('订单类型无效,必须是 virtual 或 appointment_booking');
36
- }
33
+ // // 验证订单类型
34
+ // if (params.orderType && !['virtual', 'appointment_booking'].includes(params.orderType)) {
35
+ // errors.push('订单类型无效,必须是 virtual 或 appointment_booking');
36
+ // }
37
37
 
38
38
  // 验证平台类型
39
39
  if (params.platform && !['pc', 'h5'].includes(params.platform)) {
@@ -851,7 +851,7 @@ export var SalesImpl = /*#__PURE__*/function (_BaseModule) {
851
851
  return _this6.getBookingAppointmentStatus(booking) === 'completed';
852
852
  });
853
853
  unpaidBookingList = matchedBookingList.filter(function (booking) {
854
- return _this6.getBookingOrderPaymentStatus(booking) === 'unpaid';
854
+ return _this6.getBookingOrderPaymentStatus(booking) === 'unpaid' || _this6.getBookingOrderPaymentStatus(booking) === 'payment_processing';
855
855
  });
856
856
  bookings = this.pickBookingsForCurrentPoint(current, this.normalizeResourceBookings(current, deviceCurrent, matchedBookingList));
857
857
  completedBookings = this.pickBookingsForCurrentPoint(current, this.normalizeResourceBookings(current, deviceCurrent, completedBookingList, {
@@ -63,9 +63,6 @@ function validateCheckoutData(params) {
63
63
  }
64
64
  });
65
65
  }
66
- if (params.orderType && !["virtual", "appointment_booking"].includes(params.orderType)) {
67
- errors.push("订单类型无效,必须是 virtual 或 appointment_booking");
68
- }
69
66
  if (params.platform && !["pc", "h5"].includes(params.platform)) {
70
67
  errors.push("平台类型无效,必须是 pc 或 h5");
71
68
  }
@@ -600,7 +600,7 @@ var SalesImpl = class extends import_BaseModule.BaseModule {
600
600
  (booking) => this.getBookingAppointmentStatus(booking) === "completed"
601
601
  );
602
602
  const unpaidBookingList = matchedBookingList.filter(
603
- (booking) => this.getBookingOrderPaymentStatus(booking) === "unpaid"
603
+ (booking) => this.getBookingOrderPaymentStatus(booking) === "unpaid" || this.getBookingOrderPaymentStatus(booking) === "payment_processing"
604
604
  );
605
605
  const bookings = this.pickBookingsForCurrentPoint(
606
606
  current,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "private": false,
3
3
  "name": "@pisell/pisellos",
4
- "version": "2.2.138",
4
+ "version": "2.2.140",
5
5
  "description": "一个可扩展的前端模块化SDK框架,支持插件系统",
6
6
  "main": "dist/index.js",
7
7
  "types": "dist/index.d.ts",