feat: update tutorial steps and enhance contract signing flow with tutorial parameter handling
This commit is contained in:
parent
5174b3dc78
commit
d764532d24
@ -308,31 +308,31 @@ export const createTutorialSteps = (
|
||||
},
|
||||
{
|
||||
id: 5,
|
||||
title: "Our team is preparing your contract ⏳",
|
||||
description: "Excellent! Now our team needs to manually review your information and prepare your personalized contract. This ensures everything is perfectly tailored to your needs.",
|
||||
title: "Ready to sign your contract! 📝",
|
||||
description: "Perfect! You've completed all the preparation steps. Now it's time to review and sign your personalized contract to finalize your account setup.",
|
||||
details: [
|
||||
"Our admin team is currently reviewing your submitted documents",
|
||||
"We're preparing a personalized contract just for you",
|
||||
"This process typically takes 1-2 business days",
|
||||
"You'll receive an email notification once your contract is ready to sign"
|
||||
"Review the terms and conditions carefully",
|
||||
"Your contract has been prepared based on your information",
|
||||
"Digital signature makes the process quick and secure",
|
||||
"This is the final step to activate your account"
|
||||
],
|
||||
icon: ClockIcon,
|
||||
buttonText: contractSigned ? "Contract signed! ✅" : "Waiting for admin review",
|
||||
buttonAction: onSignContract,
|
||||
icon: DocumentTextIcon,
|
||||
buttonText: contractSigned ? "Contract signed! ✅" : "Review & sign contract",
|
||||
buttonAction: contractSigned ? onNext : onSignContract,
|
||||
canProceed: emailVerified && idUploaded && additionalInfo
|
||||
},
|
||||
{
|
||||
id: 6,
|
||||
title: "You're all set! 🎉 Welcome to the community",
|
||||
title: "You're all set! 🎉 Welcome to the family",
|
||||
description: "Congratulations! You've completed all the steps perfectly. Our friendly team will now review your information - we'll have you approved and ready to go very soon!",
|
||||
details: [
|
||||
"Our team will carefully review everything you've submitted",
|
||||
"This usually takes just 1-2 business days",
|
||||
"We'll send you a celebratory email once you're approved",
|
||||
"In the meantime, feel free to explore"
|
||||
"In the meantime, feel free to explore your dashboard"
|
||||
],
|
||||
icon: HeartIcon,
|
||||
buttonText: "I understand!",
|
||||
buttonText: "Perfect! I understand 💫",
|
||||
buttonAction: onCloseTutorial,
|
||||
canProceed: true
|
||||
}
|
||||
|
||||
@ -126,7 +126,7 @@ export default function QuickActionDashboardPage() {
|
||||
|
||||
const handleSignContract = useCallback(() => {
|
||||
const userType = user?.userType || 'personal'
|
||||
router.push(`/quickaction-dashboard/register-sign-contract/${userType}`)
|
||||
router.push(`/quickaction-dashboard/register-sign-contract/${userType}?tutorial=true`)
|
||||
}, [router, user])
|
||||
|
||||
// Tutorial handlers
|
||||
|
||||
@ -110,7 +110,15 @@ export default function CompanySignContractPage() {
|
||||
|
||||
// Redirect to main dashboard after short delay
|
||||
setTimeout(() => {
|
||||
router.push('/quickaction-dashboard')
|
||||
// Check if we came from tutorial
|
||||
const urlParams = new URLSearchParams(window.location.search)
|
||||
const fromTutorial = urlParams.get('tutorial') === 'true'
|
||||
|
||||
if (fromTutorial) {
|
||||
router.push('/quickaction-dashboard?tutorial=true')
|
||||
} else {
|
||||
router.push('/quickaction-dashboard')
|
||||
}
|
||||
}, 2000)
|
||||
|
||||
} catch (error: any) {
|
||||
|
||||
@ -102,7 +102,15 @@ export default function PersonalSignContractPage() {
|
||||
|
||||
// Redirect to main dashboard after short delay
|
||||
setTimeout(() => {
|
||||
router.push('/quickaction-dashboard')
|
||||
// Check if we came from tutorial
|
||||
const urlParams = new URLSearchParams(window.location.search)
|
||||
const fromTutorial = urlParams.get('tutorial') === 'true'
|
||||
|
||||
if (fromTutorial) {
|
||||
router.push('/quickaction-dashboard?tutorial=true')
|
||||
} else {
|
||||
router.push('/quickaction-dashboard')
|
||||
}
|
||||
}, 2000)
|
||||
|
||||
} catch (error: any) {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user