import { useMemo } from 'react';
import { useOrderPerspective } from "./useOrderPerspective";
import { useBookingPerspective } from "./useBookingPerspective";
var usePerspectives = function usePerspectives(params) {
  // params 里可携带 onOpenDetail（opt-in 行点击拦截），透传给两个 perspective
  var onOpenDetail = params === null || params === void 0 ? void 0 : params.onOpenDetail;
  var businessCode = params === null || params === void 0 ? void 0 : params.businessCode;
  var orderPerspective = useOrderPerspective({
    onOpenDetail: onOpenDetail,
    businessCode: businessCode
  });
  var bookingPerspective = useBookingPerspective(params, {
    onOpenDetail: onOpenDetail
  });
  return useMemo(function () {
    return [orderPerspective, bookingPerspective];
  }, [orderPerspective, bookingPerspective]);
};
export { useOrderPerspective, useBookingPerspective };
export default usePerspectives;