feat(groups): implement group creation functionality and refactor related components
- Removed organization dependency from group creation logic. - Introduced new route and use-case for creating groups. - Refactored form handling for group creation into a reusable GroupForm component. - Updated API calls to support new group creation endpoint. - Adjusted tests to reflect changes in group creation logic and validation. - Removed obsolete organizations route and related components. - Updated breadcrumb navigation and routing for group management.
This commit is contained in:
@@ -6,12 +6,12 @@ import { PaymentsView } from './routes/payments'
|
||||
import { SettingsView } from './routes/settings'
|
||||
import { ProfileView } from './routes/profile'
|
||||
import { SecurityPage } from './routes/security'
|
||||
import { OrganizationsPage } from './routes/organizations'
|
||||
import { LoginPage } from './routes/auth/login'
|
||||
import { SignupPage } from './routes/auth/signup'
|
||||
import { VerifyEmailPage } from './routes/auth/verify-email'
|
||||
import { OnboardingView } from './routes/onboarding'
|
||||
import { GroupDetailView } from './routes/group-detail'
|
||||
import { CreateGroupView } from './routes/create-group'
|
||||
import { JoinGroupView } from './routes/join-group'
|
||||
|
||||
const rootRoute = createRootRoute({
|
||||
@@ -68,6 +68,12 @@ const groupsRoute = createRoute({
|
||||
component: GroupsView,
|
||||
})
|
||||
|
||||
const createGroupRoute = createRoute({
|
||||
getParentRoute: () => appLayoutRoute,
|
||||
path: '/groups/new',
|
||||
component: CreateGroupView,
|
||||
})
|
||||
|
||||
const groupDetailRoute = createRoute({
|
||||
getParentRoute: () => appLayoutRoute,
|
||||
path: '/groups/$groupId',
|
||||
@@ -98,12 +104,6 @@ const profileRoute = createRoute({
|
||||
component: ProfileView,
|
||||
})
|
||||
|
||||
const organizationsRoute = createRoute({
|
||||
getParentRoute: () => appLayoutRoute,
|
||||
path: '/settings/organizations',
|
||||
component: OrganizationsPage,
|
||||
})
|
||||
|
||||
const routeTree = rootRoute.addChildren([
|
||||
loginRoute,
|
||||
signupRoute,
|
||||
@@ -113,11 +113,11 @@ const routeTree = rootRoute.addChildren([
|
||||
appLayoutRoute.addChildren([
|
||||
indexRoute,
|
||||
groupsRoute,
|
||||
createGroupRoute,
|
||||
groupDetailRoute,
|
||||
paymentsRoute,
|
||||
settingsRoute,
|
||||
securityRoute,
|
||||
organizationsRoute,
|
||||
profileRoute,
|
||||
]),
|
||||
])
|
||||
|
||||
Reference in New Issue
Block a user