export function toBackPage(delay = 1000, onSuccess = () => {}) {
	setTimeout(() => {
		uni.navigateBack({
			success: () => {
				const pages = getCurrentPages();
				if (pages.length > 1) {
					const prevPage = pages[pages.length - 2];
					onSuccess(prevPage);
				}
			}
		});
	}, delay);
}