import { _objectSpread2 } from "../../_virtual/_@oxc-project_runtime@0.122.0/helpers/objectSpread2.js";
import { _asyncToGenerator } from "../../_virtual/_@oxc-project_runtime@0.122.0/helpers/asyncToGenerator.js";
import { getUniqueId, locales } from "@pisell/utils";
import { PisellToast } from "@pisell/materials";
//#region src/components/appointmentBooking/utils.ts
/**
* @title: 格式化holder表数据
* @description: 
* @param {any} data
* @return {*}
* @Author: WangHan
* @Date: 2025-05-07 21:22
*/
const formatHolder = (data) => {
	return data === null || data === void 0 ? void 0 : data.map((d) => {
		return _objectSpread2(_objectSpread2({}, d), {}, {
			key: d === null || d === void 0 ? void 0 : d.id,
			label: d === null || d === void 0 ? void 0 : d.username,
			name: d === null || d === void 0 ? void 0 : d.username
		});
	});
};
const formatGuest = (data, products) => {
	return data === null || data === void 0 ? void 0 : data.map((d) => {
		const children = products.filter((p) => (p === null || p === void 0 ? void 0 : p.holder_id) === (d === null || d === void 0 ? void 0 : d.id)).map((p) => {
			return { name: p === null || p === void 0 ? void 0 : p.name };
		});
		return _objectSpread2(_objectSpread2({}, d), {}, {
			key: d === null || d === void 0 ? void 0 : d.id,
			name: d === null || d === void 0 ? void 0 : d.username,
			children: children || []
		});
	});
};
/**
* @title: 对资源进行排序
* @description: 
* @param {any} currentResourcesMap
* @param {any} resourceSort
* @return {*}
* @Author: WangHan
* @Date: 2025-04-14 11:16
*/
const sortResources = (resources, resourceSort) => {
	try {
		let sortedResources = resources.sort((a, b) => {
			return resourceSort.indexOf(a.code) - resourceSort.indexOf(b.code);
		});
		sortedResources = sortedResources.map((resource) => {
			var _resource$renderList;
			const renderList = resource === null || resource === void 0 || (_resource$renderList = resource.renderList) === null || _resource$renderList === void 0 ? void 0 : _resource$renderList.map((d) => {
				var _d$cover;
				return _objectSpread2(_objectSpread2({}, d), {}, {
					image: d === null || d === void 0 || (_d$cover = d.cover) === null || _d$cover === void 0 || (_d$cover = _d$cover[0]) === null || _d$cover === void 0 ? void 0 : _d$cover.url,
					title: d === null || d === void 0 ? void 0 : d.main_field,
					subtitle: d === null || d === void 0 ? void 0 : d.sub_field
				});
			});
			return _objectSpread2(_objectSpread2({}, resource), {}, { renderList });
		});
		return sortedResources || [];
	} catch (error) {
		console.log(error, "wh2222");
	}
};
/**
* @title: 处理资源列表并提取资源代码
* @description: 对资源列表进行排序，并提取 resourceCodes
* @param {any[]} resources - 原始资源列表
* @param {any[]} resourceSort - 资源排序配置
* @return {*} 返回处理后的资源列表和资源代码数组
* @Author: WangHan
* @Date: 2025-11-21 15:33
*/
const processResourceList = (resources, resourceSort) => {
	var _processedResources$;
	const processedResources = resources.map((item) => {
		return _objectSpread2(_objectSpread2({}, item), {}, { resources: sortResources((item === null || item === void 0 ? void 0 : item.resources) || [], resourceSort) });
	});
	return {
		resources: processedResources,
		resourceCodes: ((processedResources === null || processedResources === void 0 || (_processedResources$ = processedResources[0]) === null || _processedResources$ === void 0 ? void 0 : _processedResources$.resources) || []).map((item) => item.code)
	};
};
const getCustomer = (utils) => {
	try {
		var _utils$getStore$getSt;
		if (!utils) return;
		let userInfo = (_utils$getStore$getSt = utils.getStore().getState()) === null || _utils$getStore$getSt === void 0 || (_utils$getStore$getSt = _utils$getStore$getSt.global) === null || _utils$getStore$getSt === void 0 ? void 0 : _utils$getStore$getSt.userInfo;
		const localUserInfo = JSON.parse(utils.storage.get("customer") || "{}");
		userInfo = (userInfo === null || userInfo === void 0 ? void 0 : userInfo.id) ? userInfo : localUserInfo;
		return userInfo;
	} catch (error) {
		console.log(`getCustomer ${error}`);
	}
};
const formatCustomer = (val) => {
	let currentUserName = `${(val === null || val === void 0 ? void 0 : val.first_name) || ""}${(val === null || val === void 0 ? void 0 : val.last_name) ? ` ${val === null || val === void 0 ? void 0 : val.last_name}` : ""}`;
	currentUserName = currentUserName || (val === null || val === void 0 ? void 0 : val.nickname) || "Me";
	return {
		id: (val === null || val === void 0 ? void 0 : val.id) || getUniqueId(),
		username: currentUserName
	};
};
const formatCurrentUser = (utils) => {
	return formatCustomer(getCustomer(utils));
};
/**
* @title: 定金合并的标点符号
* @description: 
* @return {*}
* @Author: WangHan
* @Date: 2025-04-21 17:52
*/
const getPunctuationMark = (index, totalLength, isEn) => {
	const isLastItem = index === totalLength - 1;
	const isSecondLastItem = index === totalLength - 2;
	if (isLastItem) return isEn ? "." : "。";
	if (isSecondLastItem) return locales.getText("pisell2.appointment.deposit.and");
	return isEn ? ", " : "、";
};
/**
* @title: 打开表单
* @description: 
* @param {string} title
* @param {any} callback
* @return {*}
* @Author: WangHan
* @Date: 2025-04-26 15:26
*/
const openForm = ({ form_id, title, callback, utils }) => {
	utils.action({
		type: "pisell1.form",
		data: {
			form_id,
			form_title: title,
			isV2API: true
		},
		callback
	});
};
/**
* @title: 更新表单存储
* @description: 
* @param {any} bookingForm
* @param {number} id
* @param {any} newData
* @return {*}
* @Author: WangHan
* @Date: 2025-04-27 17:27
*/
const updateBookingFormStorage = (bookingForm, id, newData) => {
	const newBookingForm = _objectSpread2({}, bookingForm);
	if (newBookingForm[id]) newBookingForm[id] = _objectSpread2(_objectSpread2({}, newBookingForm[id]), newData);
	else newBookingForm[id] = _objectSpread2({}, newData);
	return newBookingForm;
};
const Toast = (text) => {
	try {
		PisellToast({ content: text });
	} catch (error) {
		var _window;
		(_window = window) === null || _window === void 0 || _window.alert(text);
	}
};
const getCartCurrentResourceData = (cart, currentKey, resources) => {
	try {
		var _currentKey$split, _resources$, _cart$_origin, _resourceItem$renderL;
		const currentFormId = currentKey === null || currentKey === void 0 || (_currentKey$split = currentKey.split("_@")) === null || _currentKey$split === void 0 || (_currentKey$split = _currentKey$split[1]) === null || _currentKey$split === void 0 ? void 0 : _currentKey$split.split("-");
		const form_id = Number((currentFormId === null || currentFormId === void 0 ? void 0 : currentFormId[0]) || (resources === null || resources === void 0 || (_resources$ = resources[0]) === null || _resources$ === void 0 || (_resources$ = _resources$.resources) === null || _resources$ === void 0 || (_resources$ = _resources$[0]) === null || _resources$ === void 0 ? void 0 : _resources$.id));
		if (!form_id || !resources.length) return;
		const cartId = cart._id;
		const cartOriginResources = ((_cart$_origin = cart._origin) === null || _cart$_origin === void 0 ? void 0 : _cart$_origin.resources) || [];
		const resourceData = resources.find((r) => String(r._id) === String(cartId));
		if (!resourceData) return;
		let resourceItem = (resourceData.resources || []).find((r) => Number(r.id) === form_id);
		if (!resourceItem) return;
		resourceItem = _objectSpread2(_objectSpread2({}, resourceItem), {}, { renderList: (resourceItem === null || resourceItem === void 0 || (_resourceItem$renderL = resourceItem.renderList) === null || _resourceItem$renderL === void 0 ? void 0 : _resourceItem$renderL.map((r) => {
			return _objectSpread2(_objectSpread2({}, r), {}, { label: (r === null || r === void 0 ? void 0 : r.main_field) || (r === null || r === void 0 ? void 0 : r.id) });
		})) || [] });
		const cartResource = cartOriginResources.find((r) => Number(r.form_id) === form_id);
		const renderId = (cartResource === null || cartResource === void 0 ? void 0 : cartResource.id) || 0;
		const renderItem = ((resourceItem === null || resourceItem === void 0 ? void 0 : resourceItem.renderList) || []).find((r) => Number(r === null || r === void 0 ? void 0 : r.id) === Number(renderId));
		return {
			cartItem: cart,
			resourceItem: _objectSpread2(_objectSpread2({}, resourceItem), {}, { originRenderLists: resourceData.resources }),
			renderItem
		};
	} catch (error) {
		return cart;
	}
};
/**
* @title: 获取购物车资源列表
* @description: 
* @return {*}
* @Author: WangHan
* @Date: 2025-05-25 13:56
*/
const getMultiResources = (cart, currentSelectedResource, currentKey) => {
	var _cart$_origin2;
	const resourceItem = currentSelectedResource === null || currentSelectedResource === void 0 ? void 0 : currentSelectedResource.resourceItem;
	if (!resourceItem || !cart) return [];
	const isCurrentResourceStep = currentKey.startsWith("select-resource");
	let resources = (cart === null || cart === void 0 || (_cart$_origin2 = cart._origin) === null || _cart$_origin2 === void 0 ? void 0 : _cart$_origin2.resources) || [];
	let selectedResources = isCurrentResourceStep ? resources.filter((r) => (r === null || r === void 0 ? void 0 : r.form_id) !== (resourceItem === null || resourceItem === void 0 ? void 0 : resourceItem.form_id)) : resources;
	selectedResources = selectedResources.map((r) => {
		return _objectSpread2(_objectSpread2({}, r), {}, {
			name: (r === null || r === void 0 ? void 0 : r.main_field) || (r === null || r === void 0 ? void 0 : r.id),
			isShowChangeResource: false,
			is_hide_like: true
		});
	});
	let currentResources = resources.find((r) => (r === null || r === void 0 ? void 0 : r.form_id) === (resourceItem === null || resourceItem === void 0 ? void 0 : resourceItem.form_id));
	const errorTip = (currentSelectedResource === null || currentSelectedResource === void 0 ? void 0 : currentSelectedResource.errorTip) || {};
	let currentResource = isCurrentResourceStep ? [{
		allowClearResource: true,
		lists: (resourceItem === null || resourceItem === void 0 ? void 0 : resourceItem.renderList) || [],
		is_hide_like: true,
		id: currentResources === null || currentResources === void 0 ? void 0 : currentResources.id,
		isErrorResource: (errorTip === null || errorTip === void 0 ? void 0 : errorTip.isErrorResource) || false,
		resourceErrorText: (errorTip === null || errorTip === void 0 ? void 0 : errorTip.resourceErrorText) || ""
	}] : [];
	return [...selectedResources, ...currentResource];
};
const getCurrentBoard = (appointmentBooking, code) => {
	var _appointmentBoard$res;
	const { appointmentBoard } = (appointmentBooking === null || appointmentBooking === void 0 ? void 0 : appointmentBooking.otherParams) || {};
	return appointmentBoard === null || appointmentBoard === void 0 || (_appointmentBoard$res = appointmentBoard.resource_tab) === null || _appointmentBoard$res === void 0 ? void 0 : _appointmentBoard$res[code];
};
/**
* @title: 
* @description: 根据资源code获取资源标题
* @param {any} appointmentBooking
* @param {string} code
* @return {*}
* @Author: WangHan
* @Date: 2025-05-24 18:51
*/
const getResourceTitle = (appointmentBooking, code, utils, originResource) => {
	const resourceConfig = getCurrentBoard(appointmentBooking, code);
	let name = "";
	if (resourceConfig === null || resourceConfig === void 0 ? void 0 : resourceConfig.resource_type_title) name = utils.translation(resourceConfig === null || resourceConfig === void 0 ? void 0 : resourceConfig.resource_type_title);
	else name = (originResource === null || originResource === void 0 ? void 0 : originResource.title) || "";
	return name;
};
/**
* @title: 监测购物车中是否有没有选择资源的
* @description: 
* @param {any} carts
* @return {*}
* @Author: WangHan
* @Date: 2025-05-24 18:47
*/
const checkAndMarkCartRenderError = (carts, appointmentBooking, utils) => {
	try {
		let hasError = false;
		carts = carts.filter((n) => !appointmentBooking.isTargetCartIdNormalProduct(n._id));
		const updatedCartList = carts === null || carts === void 0 ? void 0 : carts.map((cart) => {
			const currentResource = cart === null || cart === void 0 ? void 0 : cart.currentSelectedResource;
			if (!(currentResource === null || currentResource === void 0 ? void 0 : currentResource.renderItem)) {
				hasError = true;
				const resourceItem = (currentResource === null || currentResource === void 0 ? void 0 : currentResource.resourceItem) || {};
				const name = getResourceTitle(appointmentBooking, resourceItem === null || resourceItem === void 0 ? void 0 : resourceItem.code, utils, resourceItem);
				return _objectSpread2(_objectSpread2({}, cart), {}, { currentSelectedResource: _objectSpread2(_objectSpread2({}, currentResource), {}, { errorTip: {
					isErrorResource: true,
					resourceErrorText: name
				} }) });
			}
			return cart;
		});
		return {
			hasError,
			updatedCartList
		};
	} catch (error) {
		console.error(error);
		return {};
	}
};
/**
* @title: 查表表单步骤插入到哪个步骤的后面的key
* @description: 
* @param {string} currentKey
* @param {any} stepList
* @return {*}
* @Author: WangHan
* @Date: 2025-05-24 19:05
*/
const getFormInsertBeforeKey = (currentKey, stepList) => {
	const isFirstResource = currentKey === "select-resource";
	const timeStep = stepList.find((item) => item.key.startsWith("select-time"));
	if (isFirstResource && timeStep) return timeStep.key;
	else return currentKey;
};
/**
* @title: 监测holder数据
* @description: 
* @param {any} isFormSubject
* @param {any} checkAccount
* @param {any} carts
* @return {*}
* @Author: WangHan
* @Date: 2025-05-24 22:46
*/
const checkAndGoNext = (isFormSubject, checkAccount, carts) => {
	let hasError = false;
	let updatedCartList = [...carts];
	if (isFormSubject && !checkAccount("holder")) updatedCartList = carts === null || carts === void 0 ? void 0 : carts.map((item) => {
		if (!(item === null || item === void 0 ? void 0 : item.holder_id)) {
			hasError = true;
			return _objectSpread2(_objectSpread2({}, item), {}, { isErrorHolder: true });
		}
		return item;
	});
	return {
		hasError,
		updatedCartList
	};
};
const currentAppointmentBoard = (currentKey, resources, appointmentBooking) => {
	try {
		var _currentKey$split2, _resources$2, _resources$3, _appointmentBooking$o;
		const currentStepKey = currentKey === null || currentKey === void 0 || (_currentKey$split2 = currentKey.split("_@")) === null || _currentKey$split2 === void 0 || (_currentKey$split2 = _currentKey$split2[1]) === null || _currentKey$split2 === void 0 ? void 0 : _currentKey$split2.split("-");
		const form_id = Number((currentStepKey === null || currentStepKey === void 0 ? void 0 : currentStepKey[0]) || (resources === null || resources === void 0 || (_resources$2 = resources[0]) === null || _resources$2 === void 0 || (_resources$2 = _resources$2.resources) === null || _resources$2 === void 0 || (_resources$2 = _resources$2[0]) === null || _resources$2 === void 0 ? void 0 : _resources$2.id));
		const form_code = (currentStepKey === null || currentStepKey === void 0 ? void 0 : currentStepKey[1]) || (resources === null || resources === void 0 || (_resources$3 = resources[0]) === null || _resources$3 === void 0 || (_resources$3 = _resources$3.resources) === null || _resources$3 === void 0 || (_resources$3 = _resources$3[0]) === null || _resources$3 === void 0 ? void 0 : _resources$3.code);
		const cart_id = currentStepKey === null || currentStepKey === void 0 ? void 0 : currentStepKey[2];
		const resource_form_id = currentStepKey === null || currentStepKey === void 0 ? void 0 : currentStepKey[3];
		const policy_id = currentStepKey === null || currentStepKey === void 0 ? void 0 : currentStepKey[4];
		const resource_tab = appointmentBooking === null || appointmentBooking === void 0 || (_appointmentBooking$o = appointmentBooking.otherParams) === null || _appointmentBooking$o === void 0 || (_appointmentBooking$o = _appointmentBooking$o.appointmentBoard) === null || _appointmentBooking$o === void 0 ? void 0 : _appointmentBooking$o.resource_tab;
		const config = resource_tab === null || resource_tab === void 0 ? void 0 : resource_tab[form_code];
		return {
			isRequired: (config === null || config === void 0 ? void 0 : config.customer_resource) === "customer_resource_required",
			isSystem: (config === null || config === void 0 ? void 0 : config.customer_resource) === "customer_resource_system",
			isSkip: (config === null || config === void 0 ? void 0 : config.hasOwnProperty("resource_skip_select")) ? !!(config === null || config === void 0 ? void 0 : config.resource_skip_select) : true,
			form_id,
			form_code,
			cart_id,
			resource_form_id,
			policy_id
		};
	} catch (error) {
		return {};
	}
};
const currentRenderLists = (resources, code) => {
	var _resources$4;
	if (!(resources === null || resources === void 0 ? void 0 : resources.length) || !code) return [];
	const _resources = (resources === null || resources === void 0 || (_resources$4 = resources[0]) === null || _resources$4 === void 0 ? void 0 : _resources$4.resources) || [];
	const currentResource = _resources === null || _resources === void 0 ? void 0 : _resources.find((item) => item.code === code);
	return (currentResource === null || currentResource === void 0 ? void 0 : currentResource.renderList) || [];
};
/**
* @title: 更新购物车
* @description: 
* @param {any} carts
* @param {any} value
* @return {*}
* @Author: WangHan
* @Date: 2025-05-25 23:17
*/
const updateCartResources = (item, value, currentSelectedResources) => {
	var _item$_origin;
	let newResource = [];
	let resources = (item === null || item === void 0 || (_item$_origin = item._origin) === null || _item$_origin === void 0 ? void 0 : _item$_origin.resources) || [];
	if (value) if (resources.findIndex((item) => item.form_id === value.form_id) > -1) newResource = resources.map((item) => item.form_id === value.form_id ? value : item);
	else newResource = [...resources, value];
	else {
		var _currentResource$curr;
		const currentResource = currentSelectedResources === null || currentSelectedResources === void 0 ? void 0 : currentSelectedResources.find((resource) => (resource === null || resource === void 0 ? void 0 : resource._id) === (item === null || item === void 0 ? void 0 : item._id));
		const form_id = currentResource === null || currentResource === void 0 || (_currentResource$curr = currentResource.currentSelectedResource) === null || _currentResource$curr === void 0 || (_currentResource$curr = _currentResource$curr.renderItem) === null || _currentResource$curr === void 0 ? void 0 : _currentResource$curr.form_id;
		newResource = resources.filter((item) => item.form_id !== form_id);
	}
	return newResource || [];
};
const isSessionProduct = function() {
	var _ref = _asyncToGenerator(function* (appointmentBooking) {
		const carts = yield appointmentBooking.getCart();
		return carts === null || carts === void 0 ? void 0 : carts.some((item) => {
			var _item$_productInit;
			return (item === null || item === void 0 || (_item$_productInit = item._productInit) === null || _item$_productInit === void 0 || (_item$_productInit = _item$_productInit["schedule.ids"]) === null || _item$_productInit === void 0 ? void 0 : _item$_productInit.length) > 0;
		});
	});
	return function isSessionProduct(_x) {
		return _ref.apply(this, arguments);
	};
}();
const STEP_CLEAR_CONFIG = {
	"select-time": ["time"],
	"fill-form": ["time", "form"],
	"select-resource": [
		"time",
		"form",
		"resource"
	],
	"select-date": [
		"time",
		"form",
		"resource",
		"date"
	],
	"select-service": [
		"time",
		"form",
		"resource",
		"date"
	]
};
/**
* 根据key匹配步骤（支持精确匹配和startsWith匹配）
* @param key - 步骤key
* @returns 匹配到的步骤key，未匹配到返回null
*/
const getMatchedStepKey = (key) => {
	if (STEP_CLEAR_CONFIG[key]) return key;
	return Object.keys(STEP_CLEAR_CONFIG).find((stepKey) => key.startsWith(stepKey)) || null;
};
/**
* 创建清空操作的映射
*/
const createClearActions = (appointmentBooking, setTimes) => {
	return {
		time: () => {
			appointmentBooking.deleteCartItemInfo("time");
			setTimes === null || setTimes === void 0 || setTimes([]);
		},
		resource: () => {
			appointmentBooking.deleteCartItemInfo("resource");
		},
		form: () => {
			appointmentBooking.deleteCartItemInfo("relationForms");
			appointmentBooking.removeStep("fill-form");
		},
		date: () => {
			var _appointmentBooking$o2;
			const { bookingProcess } = (appointmentBooking === null || appointmentBooking === void 0 || (_appointmentBooking$o2 = appointmentBooking.otherParams) === null || _appointmentBooking$o2 === void 0 ? void 0 : _appointmentBooking$o2.productModuleParams) || {};
			if (bookingProcess !== "date_first") appointmentBooking.clearDateRange();
		}
	};
};
/**
* 处理选择服务步骤的特殊逻辑：清空所有相关的资源和表单步骤
*/
const clearServiceRelatedSteps = (appointmentBooking) => {
	const stepList = (appointmentBooking === null || appointmentBooking === void 0 ? void 0 : appointmentBooking.getStepList()) || [];
	const stepKeysToRemove = ["select-resource_", "fill-form_"];
	stepList.forEach((item) => {
		if (item === null || item === void 0 ? void 0 : item.isSkip) appointmentBooking.updateStep(item.key, {
			key: item.key,
			isSkip: false
		});
		if (stepKeysToRemove.some((prefix) => {
			var _item$key;
			return (_item$key = item.key) === null || _item$key === void 0 ? void 0 : _item$key.startsWith(prefix);
		})) appointmentBooking.removeStep(item.key);
	});
};
/**
* 执行清空操作
*/
const executeClearActions = (dataTypes, clearActions) => {
	Array.from(new Set(dataTypes)).forEach((type) => {
		const action = clearActions[type];
		if (action) action();
	});
};
/**
* @title: 根据步骤key清空数据
* @param {string} key - 当前步骤的key
* @param {any} appointmentBooking - 预约预订实例
* @param {(times: any[]) => void} setTimes - 设置时间列表的回调函数
* @return {string[]} 返回需要清空的数据类型数组
* @Author: WangHan
* @Date: 2025-11-21 15:40
*/
const clearDataByStepKey = function() {
	var _ref2 = _asyncToGenerator(function* (key, appointmentBooking, setTimes) {
		var _appointmentBooking$o3;
		if (!key || !appointmentBooking) return;
		if (key === "select-service") clearServiceRelatedSteps(appointmentBooking);
		const stepKey = getMatchedStepKey(key);
		if (!stepKey) return;
		let clearDataTypes = STEP_CLEAR_CONFIG[stepKey] || [];
		const { bookingProcess } = (appointmentBooking === null || appointmentBooking === void 0 || (_appointmentBooking$o3 = appointmentBooking.otherParams) === null || _appointmentBooking$o3 === void 0 ? void 0 : _appointmentBooking$o3.productModuleParams) || {};
		if (key !== "select-date" && bookingProcess === "date_first") clearDataTypes = clearDataTypes.filter((item) => item !== "date");
		if (yield isSessionProduct(appointmentBooking)) clearDataTypes = clearDataTypes.filter((item) => item !== "time");
		if (clearDataTypes.length === 0) return clearDataTypes;
		const clearActions = createClearActions(appointmentBooking, setTimes);
		executeClearActions(clearDataTypes, clearActions);
		return clearDataTypes;
	});
	return function clearDataByStepKey(_x2, _x3, _x4) {
		return _ref2.apply(this, arguments);
	};
}();
/**
* @description: 跳转到某个步骤
* @return {*}
*/
const handleGoToStep = ({ appointmentBooking, setTimes, skipStepKey = "select-service", isSkipClearData = true }) => {
	if (isSkipClearData) clearDataByStepKey(skipStepKey, appointmentBooking, setTimes);
	const serviceIndex = appointmentBooking.getStepList().findIndex((item) => (item === null || item === void 0 ? void 0 : item.key) === skipStepKey);
	appointmentBooking.gotoStep(serviceIndex);
};
//#endregion
export { Toast, checkAndGoNext, checkAndMarkCartRenderError, clearDataByStepKey, currentAppointmentBoard, currentRenderLists, formatCurrentUser, formatCustomer, formatGuest, formatHolder, getCartCurrentResourceData, getCustomer, getFormInsertBeforeKey, getMultiResources, getPunctuationMark, getResourceTitle, handleGoToStep, openForm, processResourceList, updateBookingFormStorage, updateCartResources };
