@pisell/private-materials 6.5.20 → 6.5.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.
Files changed (85) hide show
  1. package/build/lowcode/assets-daily.json +11 -11
  2. package/build/lowcode/assets-dev.json +2 -2
  3. package/build/lowcode/assets-prod.json +11 -11
  4. package/build/lowcode/meta.js +1 -1
  5. package/build/lowcode/render/default/view.js +1 -1
  6. package/build/lowcode/view.js +1 -1
  7. package/es/components/appointmentBooking/components/Cart/Item/index.d.ts +0 -1
  8. package/es/components/appointmentBooking/components/Cart/index.d.ts +0 -1
  9. package/es/components/appointmentBooking/components/Footer/index.d.ts +0 -1
  10. package/es/components/booking/components/TabProduct/index.d.ts +0 -1
  11. package/es/components/booking/components/TabProduct/productItem/index.d.ts +0 -1
  12. package/es/components/booking/forms/footer.d.ts +0 -1
  13. package/es/components/booking/forms/sendModal/useSendModal.d.ts +0 -1
  14. package/es/components/booking/info/clientVariant/hooks/useClientFn.d.ts +0 -1
  15. package/es/components/booking/info/date/index.d.ts +0 -1
  16. package/es/components/booking/info/dateRange/index.d.ts +0 -1
  17. package/es/components/booking/info/hooks/useInfoHolder.d.ts +0 -1
  18. package/es/components/booking/info/notes/index.d.ts +0 -1
  19. package/es/components/booking/info/service/Lists.d.ts +0 -1
  20. package/es/components/booking/info/service/actions/index.d.ts +0 -1
  21. package/es/components/booking/info/service/editService/BookingList/index.d.ts +0 -1
  22. package/es/components/booking/info/service/serviceItem/index.d.ts +0 -1
  23. package/es/components/booking/info/service/serviceList/index.d.ts +0 -1
  24. package/es/components/booking/info/service2/Lists.d.ts +0 -1
  25. package/es/components/booking/info/service2/utils.js +9 -2
  26. package/es/components/booking/info2/service/actions/index.d.ts +0 -1
  27. package/es/components/booking/info2/service/serviceItem/index.d.ts +0 -1
  28. package/es/components/booking/info2/service/serviceList/index.d.ts +0 -1
  29. package/es/components/booking/materiels/duration/index.d.ts +0 -1
  30. package/es/components/booking/materiels/holder/index.d.ts +0 -1
  31. package/es/components/booking/materiels/startTime/index.d.ts +0 -1
  32. package/es/components/booking/utils.d.ts +2 -2
  33. package/es/components/eventBooking/components/Provider/Cart/Item/index.d.ts +0 -1
  34. package/es/components/eventBooking/components/Provider/Cart/index.d.ts +0 -1
  35. package/es/components/eventBooking/components/Provider/Content/index.d.ts +0 -1
  36. package/es/components/eventBooking/components/Provider/Footer/index.d.ts +0 -1
  37. package/es/components/productExtension/fields/Actor/index.d.ts +0 -1
  38. package/es/components/productExtension/fields/Forms/index.d.ts +0 -1
  39. package/es/components/productExtension/fields/SelectProducts/index.d.ts +0 -1
  40. package/es/components/shoppingCart/components/Cart/Product.d.ts +0 -1
  41. package/es/components/shoppingCart/components/Cart/index.d.ts +0 -1
  42. package/es/components/shoppingCart/components/Render/index.d.ts +0 -1
  43. package/es/components/shoppingCart/index.d.ts +0 -1
  44. package/es/components/ticketBooking/components/addServiceVariant/addService.js +45 -13
  45. package/es/components/ticketBooking/utils/index.d.ts +1 -1
  46. package/lib/components/appointmentBooking/components/Cart/Item/index.d.ts +0 -1
  47. package/lib/components/appointmentBooking/components/Cart/index.d.ts +0 -1
  48. package/lib/components/appointmentBooking/components/Footer/index.d.ts +0 -1
  49. package/lib/components/booking/components/TabProduct/index.d.ts +0 -1
  50. package/lib/components/booking/components/TabProduct/productItem/index.d.ts +0 -1
  51. package/lib/components/booking/forms/footer.d.ts +0 -1
  52. package/lib/components/booking/forms/sendModal/useSendModal.d.ts +0 -1
  53. package/lib/components/booking/info/clientVariant/hooks/useClientFn.d.ts +0 -1
  54. package/lib/components/booking/info/date/index.d.ts +0 -1
  55. package/lib/components/booking/info/dateRange/index.d.ts +0 -1
  56. package/lib/components/booking/info/hooks/useInfoHolder.d.ts +0 -1
  57. package/lib/components/booking/info/notes/index.d.ts +0 -1
  58. package/lib/components/booking/info/service/Lists.d.ts +0 -1
  59. package/lib/components/booking/info/service/actions/index.d.ts +0 -1
  60. package/lib/components/booking/info/service/editService/BookingList/index.d.ts +0 -1
  61. package/lib/components/booking/info/service/serviceItem/index.d.ts +0 -1
  62. package/lib/components/booking/info/service/serviceList/index.d.ts +0 -1
  63. package/lib/components/booking/info/service2/Lists.d.ts +0 -1
  64. package/lib/components/booking/info/service2/utils.js +6 -2
  65. package/lib/components/booking/info2/service/actions/index.d.ts +0 -1
  66. package/lib/components/booking/info2/service/serviceItem/index.d.ts +0 -1
  67. package/lib/components/booking/info2/service/serviceList/index.d.ts +0 -1
  68. package/lib/components/booking/materiels/duration/index.d.ts +0 -1
  69. package/lib/components/booking/materiels/holder/index.d.ts +0 -1
  70. package/lib/components/booking/materiels/startTime/index.d.ts +0 -1
  71. package/lib/components/booking/utils.d.ts +2 -2
  72. package/lib/components/eventBooking/components/Provider/Cart/Item/index.d.ts +0 -1
  73. package/lib/components/eventBooking/components/Provider/Cart/index.d.ts +0 -1
  74. package/lib/components/eventBooking/components/Provider/Content/index.d.ts +0 -1
  75. package/lib/components/eventBooking/components/Provider/Footer/index.d.ts +0 -1
  76. package/lib/components/productExtension/fields/Actor/index.d.ts +0 -1
  77. package/lib/components/productExtension/fields/Forms/index.d.ts +0 -1
  78. package/lib/components/productExtension/fields/SelectProducts/index.d.ts +0 -1
  79. package/lib/components/shoppingCart/components/Cart/Product.d.ts +0 -1
  80. package/lib/components/shoppingCart/components/Cart/index.d.ts +0 -1
  81. package/lib/components/shoppingCart/components/Render/index.d.ts +0 -1
  82. package/lib/components/shoppingCart/index.d.ts +0 -1
  83. package/lib/components/ticketBooking/components/addServiceVariant/addService.js +25 -3
  84. package/lib/components/ticketBooking/utils/index.d.ts +1 -1
  85. package/package.json +1 -1
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const CartItem: ({ onNext }: any) => JSX.Element;
4
3
  export default CartItem;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const Cart: ({ open, onCancel, onNext }: any) => JSX.Element;
4
3
  export default Cart;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const Footer: ({ onNext, isOpen }: any) => JSX.Element;
4
3
  export default Footer;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import "./index.less";
3
2
  interface TabProductProps {
4
3
  list: any[];
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const ProductItem: ({ item, onClick, amountSymbol, style, className, }: any) => JSX.Element;
4
3
  export default ProductItem;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  interface FooterProps {
3
2
  state: any;
4
3
  reload: () => void;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { SendModalValues } from './index';
3
2
  declare const useSendModal: (bookingId?: number) => {
4
3
  open: boolean;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { FormState } from '../../../model';
3
2
  interface useClientFnParams {
4
3
  state: any;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import "./index.less";
3
2
  export declare const updateServiceDate: (services: any[], date: any, isTime: boolean) => any[];
4
3
  declare const DateCom: () => JSX.Element;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  export declare const disabledDate: (current: any, position: any, currentDate: any) => any;
4
3
  declare const DateRange: ({ state, dispatch, key }: any) => JSX.Element;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { EditServiceRef } from "../service/editService";
3
2
  declare const useInfoHolder: (state: any, dispatch: any) => {
4
3
  detailRef: import("react").MutableRefObject<EditServiceRef | undefined>;
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
1
  declare const Notes: () => JSX.Element | null;
3
2
  export default Notes;
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
1
  declare const Lists: ({ onEdit, onChange, onAction, isParallelResource }: any) => JSX.Element;
3
2
  export default Lists;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import "./index.less";
3
2
  declare const Actions: ({ currentService }: {
4
3
  currentService: any;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const BookingList: ({ items }: {
3
2
  items: any[];
4
3
  }) => JSX.Element;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const ServiceItem: ({ d, handleEditService, state, handleLike, resourceItem, errorMessage, handleDeleteService, }: any) => JSX.Element;
4
3
  export default ServiceItem;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const ServiceList: ({ onEdit }: {
4
3
  onEdit: any;
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
1
  declare const Lists: ({ onEdit, onChange }: any) => JSX.Element;
3
2
  export default Lists;
@@ -665,14 +665,21 @@ export var formatProducts = function formatProducts(lists, state) {
665
665
  var bundle = formatBundle(item === null || item === void 0 || (_item$_extend12 = item._extend) === null || _item$_extend12 === void 0 || (_item$_extend12 = _item$_extend12.other) === null || _item$_extend12 === void 0 ? void 0 : _item$_extend12.bundle);
666
666
  // 是否是普通商品
667
667
  var isNormalProduct = !appointmentTypes.includes(item === null || item === void 0 ? void 0 : item.extension_type) || (state === null || state === void 0 ? void 0 : state.renderType) === 'eventBooking';
668
+ var isNormalProductByDurationScheduleVal = isNormalProductByDurationSchedule(item);
668
669
  var resourceItem = {};
669
670
  var errorMessage = '';
670
- if (_isDayBookingProduct || isGeneral) {
671
+ // 普通商品没有
672
+ if ((_isDayBookingProduct || isGeneral) && !isNormalProductByDurationScheduleVal) {
671
673
  var _item$_extend13;
672
674
  resourceItem = getResourceItem(item === null || item === void 0 || (_item$_extend13 = item._extend) === null || _item$_extend13 === void 0 ? void 0 : _item$_extend13.resource, state);
673
675
  errorMessage = getErrorMessage(item, resourceItem, isDayBooking(state));
674
676
  }
675
- var generalParams = isGeneral ? getGeneralParams(item, state, !!isParallelResource) : {};
677
+
678
+ // 普通商品没有
679
+ var generalParams = {};
680
+ if (isGeneral && !isNormalProductByDurationScheduleVal) {
681
+ generalParams = getGeneralParams(item, state, !!isParallelResource);
682
+ }
676
683
  return _objectSpread(_objectSpread({
677
684
  id: item === null || item === void 0 ? void 0 : item.id,
678
685
  _id: item === null || item === void 0 ? void 0 : item._id,
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import '../../../info/service/actions/index.less';
3
2
  declare const Actions: ({ currentService }: {
4
3
  currentService: any;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const ServiceItem: ({ d, handleEditService, state, handleLike, errorMessage, handleDeleteService, }: any) => JSX.Element;
4
3
  export default ServiceItem;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const ServiceList: ({ onEdit }: {
4
3
  onEdit: any;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { SelectProps } from 'antd';
3
2
  interface DurationProps extends SelectProps {
4
3
  locale?: string;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { SelectProps } from 'antd';
3
2
  interface HolderProps extends SelectProps {
4
3
  selectProps?: SelectProps;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { SelectProps } from "antd";
3
2
  interface StartTimeProps extends SelectProps {
4
3
  locale?: string;
@@ -165,10 +165,10 @@ export declare const getProductTotalPrice: (item: any) => number;
165
165
  export declare const getDuration: (duration: number | {
166
166
  type: string;
167
167
  value: number;
168
- }) => number | "flexible" | {
168
+ }) => number | {
169
169
  type: string;
170
170
  value: number;
171
- };
171
+ } | "flexible";
172
172
  export declare const isWalkIn: (customer_id?: number | string) => boolean;
173
173
  export declare const getIsEdit: (state: any) => boolean;
174
174
  export {};
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const CartItem: () => JSX.Element;
4
3
  export default CartItem;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const Cart: ({ open, onCancel }: any) => JSX.Element;
4
3
  export default Cart;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const Layout: () => JSX.Element;
4
3
  export default Layout;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const Footer: () => JSX.Element;
4
3
  export default Footer;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const Actor: ({ name }: {
3
2
  name: string;
4
3
  }) => JSX.Element;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  export interface InfoProps {
3
2
  relation_id: any;
4
3
  action: any;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  interface valueType {
4
3
  }
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { ProductProps } from '../../type';
3
2
  declare const Product: (props: ProductProps) => JSX.Element;
4
3
  export default Product;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const Cart: () => JSX.Element;
4
3
  export default Cart;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const Content: () => JSX.Element;
4
3
  export default Content;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { shoppingCartProps } from './type';
3
2
  declare const shoppingCart: ({ onCard, onAction, onChange, onAddProduct, onActiveKey, ...props }: shoppingCartProps) => JSX.Element;
4
3
  export default shoppingCart;
@@ -327,10 +327,13 @@ var AddSerivce = function AddSerivce(props) {
327
327
  clearTimeout(debounceTimersRef.current[productId]);
328
328
  }
329
329
 
330
+ // 从 localStorage 获取防抖时间配置,默认为 0
331
+ var debounceTime = Number(localStorage.getItem('pisell_service_add_debounce_time')) || 0;
332
+
330
333
  // 创建新的防抖定时器
331
334
  debounceTimersRef.current[productId] = setTimeout(function () {
332
335
  executeCacheValues(productId, cacheValues, item, callback);
333
- }, 0);
336
+ }, debounceTime);
334
337
  });
335
338
 
336
339
  // 检查资源可用性
@@ -380,7 +383,10 @@ var AddSerivce = function AddSerivce(props) {
380
383
  if (renderMode === 'current') {
381
384
  cacheItem.currentDefaultTime = state.date.value.format('HH:mm');
382
385
  }
383
- cacheItem = getProductExtend({
386
+ var isNormalProduct = isNormalProductByDurationSchedule(item);
387
+ cacheItem = isNormalProduct ? _objectSpread(_objectSpread({}, cacheItem), {}, {
388
+ autoClose: true
389
+ }) : getProductExtend({
384
390
  cacheItem: cacheItem,
385
391
  state: state,
386
392
  isDisabledTime: true
@@ -409,6 +415,7 @@ var AddSerivce = function AddSerivce(props) {
409
415
 
410
416
  // 处理自动关闭的服务添加(带防抖)
411
417
  var processAutoCloseService = useMemoizedFn(function (cacheItem, item, detail, notShowToast) {
418
+ console.time('processAutoCloseService2');
412
419
  cacheItem.autoClose = false;
413
420
  cacheItem._serviceKey = genServiceKey(cacheItem);
414
421
  var productKey = getProductKey(item, cacheItem);
@@ -441,14 +448,21 @@ var AddSerivce = function AddSerivce(props) {
441
448
  clearTimeout(debounceTimersRef.current[productKey]);
442
449
  }
443
450
 
451
+ // 从 localStorage 获取防抖时间配置,默认为 0
452
+ var debounceTime = Number(localStorage.getItem('pisell_service_add_debounce_time')) || 0;
453
+
444
454
  // 创建新的防抖定时器
445
455
  debounceTimersRef.current[productKey] = setTimeout(function () {
446
456
  executeServiceDispatch(productKey);
447
- }, 300); // 300ms 防抖时间
457
+ }, debounceTime);
458
+ console.timeEnd('processAutoCloseService2');
459
+ // 5ms
448
460
  });
449
461
 
450
462
  // 执行实际的 dispatch 操作
451
463
  var executeServiceDispatch = useMemoizedFn(function (productKey) {
464
+ console.time('executeServiceDispatch');
465
+ console.time('executeServiceDispatch1');
452
466
  var pendingData = pendingCacheValuesRef.current[productKey];
453
467
  if (!pendingData) return;
454
468
  var cacheItem = pendingData.cacheItem,
@@ -462,17 +476,21 @@ var AddSerivce = function AddSerivce(props) {
462
476
  quantity: clickCount
463
477
  })
464
478
  });
465
-
479
+ console.timeEnd('executeServiceDispatch1');
480
+ console.time('executeServiceDispatch addService');
466
481
  // 使用 stateRef 获取最新的 service.value,避免竞态条件
467
482
  var _addService2 = addService(_toConsumableArray(stateRef.current.service.value || []), finalCacheItem, stateRef.current),
468
483
  _list = _addService2.list,
469
484
  quantity = _addService2.quantity;
485
+ console.timeEnd('executeServiceDispatch addService');
486
+ console.time('executeServiceDispatch2');
470
487
  window.dispatchEvent(new CustomEvent('onAddNewService', {
471
488
  detail: {
472
489
  cacheItem: finalCacheItem
473
490
  }
474
491
  }));
475
-
492
+ console.timeEnd('executeServiceDispatch2');
493
+ console.time('executeServiceDispatch3');
476
494
  // 2155 日志记录
477
495
  logServiceForSpecificShop(item, detail, _list);
478
496
 
@@ -491,6 +509,8 @@ var AddSerivce = function AddSerivce(props) {
491
509
  changeService: false
492
510
  }
493
511
  });
512
+ console.timeEnd('executeServiceDispatch3');
513
+ console.timeEnd('executeServiceDispatch');
494
514
 
495
515
  // 清理缓存数据
496
516
  delete pendingCacheValuesRef.current[productKey];
@@ -609,14 +629,21 @@ var AddSerivce = function AddSerivce(props) {
609
629
  case 4:
610
630
  return _context2.abrupt("return");
611
631
  case 5:
632
+ console.time('createCacheItemFromParams');
612
633
  cacheItem = createCacheItemFromParams(item, item.cartDetailValue);
634
+ console.timeEnd('createCacheItemFromParams');
635
+ // 5ms
636
+
613
637
  if (cacheItem.autoClose) {
614
638
  // 使用带防抖的处理函数
639
+ console.time('processAutoCloseService');
615
640
  processAutoCloseService(cacheItem, item, item, false);
641
+ console.timeEnd('processAutoCloseService');
642
+ // 5ms
616
643
  } else {
617
644
  processManualEditService(cacheItem);
618
645
  }
619
- case 7:
646
+ case 9:
620
647
  case "end":
621
648
  return _context2.stop();
622
649
  }
@@ -697,26 +724,31 @@ var AddSerivce = function AddSerivce(props) {
697
724
  while (1) switch (_context4.prev = _context4.next) {
698
725
  case 0:
699
726
  type = _args4.length > 1 && _args4[1] !== undefined ? _args4[1] : 'select';
727
+ console.time("handleSelectProduct2");
700
728
  console.log(item, 'handleSelectProduct');
701
729
  // 检查资源可用性
730
+ console.time("checkResourceAvailability");
702
731
  if (checkResourceAvailability(item)) {
703
- _context4.next = 4;
732
+ _context4.next = 6;
704
733
  break;
705
734
  }
706
735
  return _context4.abrupt("return");
707
- case 4:
736
+ case 6:
737
+ console.timeEnd("checkResourceAvailability");
738
+ // 0ms
739
+ // 如果不需要打开详情弹窗,直接添加服务
708
740
  if (item.isOpenDetailModal) {
709
- _context4.next = 8;
741
+ _context4.next = 11;
710
742
  break;
711
743
  }
712
- _context4.next = 7;
744
+ _context4.next = 10;
713
745
  return handleDirectAddService(item);
714
- case 7:
746
+ case 10:
715
747
  return _context4.abrupt("return");
716
- case 8:
748
+ case 11:
717
749
  // 打开产品选择弹窗
718
750
  openProductModal(item, type);
719
- case 9:
751
+ case 12:
720
752
  case "end":
721
753
  return _context4.stop();
722
754
  }
@@ -41,7 +41,7 @@ declare type ScanData = {
41
41
  };
42
42
  };
43
43
  export declare const formatScanCustomer: (data: ScanData) => {
44
- searchType: "customer" | "product" | "wallet" | "walletPass" | "local_product";
44
+ searchType: "product" | "customer" | "wallet" | "walletPass" | "local_product";
45
45
  data: any;
46
46
  scanCode: string;
47
47
  } | null;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const CartItem: ({ onNext }: any) => JSX.Element;
4
3
  export default CartItem;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const Cart: ({ open, onCancel, onNext }: any) => JSX.Element;
4
3
  export default Cart;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const Footer: ({ onNext, isOpen }: any) => JSX.Element;
4
3
  export default Footer;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import "./index.less";
3
2
  interface TabProductProps {
4
3
  list: any[];
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const ProductItem: ({ item, onClick, amountSymbol, style, className, }: any) => JSX.Element;
4
3
  export default ProductItem;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  interface FooterProps {
3
2
  state: any;
4
3
  reload: () => void;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { SendModalValues } from './index';
3
2
  declare const useSendModal: (bookingId?: number) => {
4
3
  open: boolean;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { FormState } from '../../../model';
3
2
  interface useClientFnParams {
4
3
  state: any;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import "./index.less";
3
2
  export declare const updateServiceDate: (services: any[], date: any, isTime: boolean) => any[];
4
3
  declare const DateCom: () => JSX.Element;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  export declare const disabledDate: (current: any, position: any, currentDate: any) => any;
4
3
  declare const DateRange: ({ state, dispatch, key }: any) => JSX.Element;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { EditServiceRef } from "../service/editService";
3
2
  declare const useInfoHolder: (state: any, dispatch: any) => {
4
3
  detailRef: import("react").MutableRefObject<EditServiceRef | undefined>;
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
1
  declare const Notes: () => JSX.Element | null;
3
2
  export default Notes;
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
1
  declare const Lists: ({ onEdit, onChange, onAction, isParallelResource }: any) => JSX.Element;
3
2
  export default Lists;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import "./index.less";
3
2
  declare const Actions: ({ currentService }: {
4
3
  currentService: any;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare const BookingList: ({ items }: {
3
2
  items: any[];
4
3
  }) => JSX.Element;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const ServiceItem: ({ d, handleEditService, state, handleLike, resourceItem, errorMessage, handleDeleteService, }: any) => JSX.Element;
4
3
  export default ServiceItem;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const ServiceList: ({ onEdit }: {
4
3
  onEdit: any;
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
1
  declare const Lists: ({ onEdit, onChange }: any) => JSX.Element;
3
2
  export default Lists;
@@ -555,13 +555,17 @@ var formatProducts = (lists, state, isRenderGroup = true, isGeneral, isParallelR
555
555
  const options = formatOptions((_c = (_b = item == null ? void 0 : item._extend) == null ? void 0 : _b.other) == null ? void 0 : _c.option);
556
556
  const bundle = formatBundle((_e = (_d = item == null ? void 0 : item._extend) == null ? void 0 : _d.other) == null ? void 0 : _e.bundle);
557
557
  const isNormalProduct = !import_status.appointmentTypes.includes(item == null ? void 0 : item.extension_type) || (state == null ? void 0 : state.renderType) === "eventBooking";
558
+ const isNormalProductByDurationScheduleVal = isNormalProductByDurationSchedule(item);
558
559
  let resourceItem = {};
559
560
  let errorMessage = "";
560
- if (_isDayBookingProduct || isGeneral) {
561
+ if ((_isDayBookingProduct || isGeneral) && !isNormalProductByDurationScheduleVal) {
561
562
  resourceItem = getResourceItem((_f = item == null ? void 0 : item._extend) == null ? void 0 : _f.resource, state);
562
563
  errorMessage = getErrorMessage(item, resourceItem, isDayBooking(state));
563
564
  }
564
- const generalParams = isGeneral ? getGeneralParams(item, state, !!isParallelResource) : {};
565
+ let generalParams = {};
566
+ if (isGeneral && !isNormalProductByDurationScheduleVal) {
567
+ generalParams = getGeneralParams(item, state, !!isParallelResource);
568
+ }
565
569
  return {
566
570
  id: item == null ? void 0 : item.id,
567
571
  _id: item == null ? void 0 : item._id,
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import '../../../info/service/actions/index.less';
3
2
  declare const Actions: ({ currentService }: {
4
3
  currentService: any;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const ServiceItem: ({ d, handleEditService, state, handleLike, errorMessage, handleDeleteService, }: any) => JSX.Element;
4
3
  export default ServiceItem;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const ServiceList: ({ onEdit }: {
4
3
  onEdit: any;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { SelectProps } from 'antd';
3
2
  interface DurationProps extends SelectProps {
4
3
  locale?: string;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { SelectProps } from 'antd';
3
2
  interface HolderProps extends SelectProps {
4
3
  selectProps?: SelectProps;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { SelectProps } from "antd";
3
2
  interface StartTimeProps extends SelectProps {
4
3
  locale?: string;
@@ -165,10 +165,10 @@ export declare const getProductTotalPrice: (item: any) => number;
165
165
  export declare const getDuration: (duration: number | {
166
166
  type: string;
167
167
  value: number;
168
- }) => number | "flexible" | {
168
+ }) => number | {
169
169
  type: string;
170
170
  value: number;
171
- };
171
+ } | "flexible";
172
172
  export declare const isWalkIn: (customer_id?: number | string) => boolean;
173
173
  export declare const getIsEdit: (state: any) => boolean;
174
174
  export {};
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const CartItem: () => JSX.Element;
4
3
  export default CartItem;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const Cart: ({ open, onCancel }: any) => JSX.Element;
4
3
  export default Cart;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const Layout: () => JSX.Element;
4
3
  export default Layout;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import './index.less';
3
2
  declare const Footer: () => JSX.Element;
4
3
  export default Footer;