feat: add city/state/country to complex, new settings page with sidebar, and Biome linting
- Added city, state, and country optional fields to Complex model - Updated onboarding to include optional location fields - Created new settings page with sidebar navigation (Datos del Complejo, Canchas) - Replaced ESLint with Biome for frontend and backend linting - Added parallel dev script with concurrently - Migrated register-routes to use direct app.route() pattern
This commit is contained in:
@@ -1,27 +1,27 @@
|
||||
import type { OnboardingCompleteInput } from '@repo/api-contract'
|
||||
import type { AppContext } from '@/types/hono'
|
||||
import {
|
||||
OnboardingError,
|
||||
completeOnboarding,
|
||||
} from '@/modules/onboarding/services/onboarding.service'
|
||||
} from '@/modules/onboarding/services/onboarding.service';
|
||||
import type { AppContext } from '@/types/hono';
|
||||
import type { OnboardingCompleteInput } from '@repo/api-contract';
|
||||
|
||||
export async function completeOnboardingHandler(c: AppContext) {
|
||||
const payload = c.req.valid('json' as never) as OnboardingCompleteInput
|
||||
const payload = c.req.valid('json' as never) as OnboardingCompleteInput;
|
||||
|
||||
try {
|
||||
const result = await completeOnboarding(payload)
|
||||
const result = await completeOnboarding(payload);
|
||||
return c.json({
|
||||
message: 'Onboarding completado correctamente.',
|
||||
...result,
|
||||
})
|
||||
});
|
||||
} catch (error) {
|
||||
if (error instanceof OnboardingError) {
|
||||
return c.json({ message: error.message }, error.status)
|
||||
return c.json({ message: error.message }, error.status);
|
||||
}
|
||||
|
||||
if (error instanceof Error) {
|
||||
return c.json({ message: error.message }, 400)
|
||||
return c.json({ message: error.message }, 400);
|
||||
}
|
||||
throw error
|
||||
throw error;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user