搜索结果列表页面开发
This commit is contained in:
78
src/router/config/account.ts
Normal file
78
src/router/config/account.ts
Normal file
@@ -0,0 +1,78 @@
|
||||
import DefaultLayout from '@/layouts/DefaultLayout/index.vue';
|
||||
|
||||
const className = 'w-full';
|
||||
|
||||
export default [
|
||||
{
|
||||
path: '/',
|
||||
component: DefaultLayout,
|
||||
meta: {
|
||||
hasMobile: true,
|
||||
loginHidden: true // 登录后不可进入
|
||||
},
|
||||
children: [
|
||||
{
|
||||
path: 'register',
|
||||
name: 'register',
|
||||
component: () => import('@/views/Mobile/Account/Register/index.vue'),
|
||||
meta: {
|
||||
title: '注册',
|
||||
className
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'login',
|
||||
name: 'login',
|
||||
component: () => import('@/views/Mobile/Account/Login/Password/index.vue'),
|
||||
meta: {
|
||||
title: '登录',
|
||||
className
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'loginByPhone',
|
||||
name: 'loginByPhone',
|
||||
component: () => import('@/views/Mobile/Account/Login/Phone/index.vue'),
|
||||
meta: {
|
||||
title: '短信登录',
|
||||
className
|
||||
}
|
||||
},
|
||||
// {
|
||||
// path: 'bindPhone',
|
||||
// name: 'bindPhone',
|
||||
// component: () => import('@/views/Mobile/Account/BindPhone/index.vue'),
|
||||
// meta: {
|
||||
// title: '绑定手机号',
|
||||
// className
|
||||
// }
|
||||
// },
|
||||
{
|
||||
path: 'resetPassword',
|
||||
name: 'resetPassword',
|
||||
component: () => import('@/views/Mobile/Account/ResetPassword/index.vue'),
|
||||
meta: {
|
||||
title: '重置密码',
|
||||
className
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
path: '/oauth/callback',
|
||||
name: 'oauth',
|
||||
component: () => import('@/views/OAuth/callback.vue'),
|
||||
meta: {
|
||||
title: '第三方授权',
|
||||
loginHidden: true
|
||||
}
|
||||
},
|
||||
{
|
||||
path: '/-/oauth/login',
|
||||
name: 'oauthLogin',
|
||||
component: () => import('@/views/OAuth/login.vue'),
|
||||
meta: {
|
||||
title: '登录账号'
|
||||
}
|
||||
}
|
||||
];
|
||||
142
src/router/config/dashboard.ts
Normal file
142
src/router/config/dashboard.ts
Normal file
@@ -0,0 +1,142 @@
|
||||
import DashboardLayout from '@/layouts/DashboardLayout/index.vue';
|
||||
|
||||
export default [
|
||||
{
|
||||
path: '/issues',
|
||||
component: DashboardLayout,
|
||||
meta: { needLogin: true },
|
||||
children: [
|
||||
{
|
||||
path: '',
|
||||
name: 'issues',
|
||||
component: () => import('@/views/Dashboard/Issue/index.vue'),
|
||||
meta: {
|
||||
title: '我的issues',
|
||||
reportTitle: '工作台-issue'
|
||||
}
|
||||
},
|
||||
// {
|
||||
// path: 'created',
|
||||
// name: 'issuesCreated',
|
||||
// component: () => import('@/views/Dashboard/Issue/index.vue'),
|
||||
// meta: {
|
||||
// basePath: 'issues',
|
||||
// title: '我的issues-我创建的'
|
||||
// }
|
||||
// },
|
||||
{
|
||||
path: 'assigned',
|
||||
name: 'issuesAssigned',
|
||||
component: () => import('@/views/Dashboard/Issue/index.vue'),
|
||||
meta: {
|
||||
basePath: 'issues',
|
||||
title: '我负责的issues'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'about',
|
||||
name: 'issuesMentioned',
|
||||
component: () => import('@/views/Dashboard/Issue/index.vue'),
|
||||
meta: {
|
||||
basePath: 'issues',
|
||||
title: '@我的issues'
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
path: '/contributed',
|
||||
component: DashboardLayout,
|
||||
meta: { needLogin: true },
|
||||
children: [
|
||||
{
|
||||
path: '',
|
||||
name: 'contributed',
|
||||
component: () => import('@/views/Dashboard/Projects/index.vue'),
|
||||
meta: {
|
||||
basePath: 'contributed',
|
||||
title: '参与的项目'
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
path: '/discussion',
|
||||
component: DashboardLayout,
|
||||
meta: { needLogin: true },
|
||||
children: [
|
||||
{
|
||||
path: '',
|
||||
name: 'discussionCreated',
|
||||
component: () => import('@/views/Dashboard/Discussion/Created/index.vue'),
|
||||
meta: {
|
||||
basePath: 'discussionCreated',
|
||||
title: '我创建的',
|
||||
reportTitle: '工作台-讨论'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'joined',
|
||||
name: 'discussionJoined',
|
||||
component: () => import('@/views/Dashboard/Discussion/Joined/index.vue'),
|
||||
meta: {
|
||||
basePath: 'discussionCreated',
|
||||
title: '我参与的'
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
path: '/merge_requests',
|
||||
component: DashboardLayout,
|
||||
meta: { needLogin: true },
|
||||
children: [
|
||||
{
|
||||
path: '',
|
||||
name: 'merge',
|
||||
component: () => import('@/views/Dashboard/Merge/index.vue'),
|
||||
meta: {
|
||||
basePath: 'merge',
|
||||
title: '我的合并请求',
|
||||
reportTitle: '工作台-mr'
|
||||
}
|
||||
},
|
||||
// {
|
||||
// path: 'created',
|
||||
// name: 'mergeCreated',
|
||||
// component: () => import('@/views/Dashboard/Merge/index.vue'),
|
||||
// meta: {
|
||||
// basePath: 'merge',
|
||||
// title: '我的合并请求-我创建的'
|
||||
// }
|
||||
// },
|
||||
{
|
||||
path: 'assigned',
|
||||
name: 'mergeAssigned',
|
||||
component: () => import('@/views/Dashboard/Merge/index.vue'),
|
||||
meta: {
|
||||
basePath: 'merge',
|
||||
title: '合并请求-我负责的'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'mentioned',
|
||||
name: 'mergeMentioned',
|
||||
component: () => import('@/views/Dashboard/Merge/index.vue'),
|
||||
meta: {
|
||||
basePath: 'merge',
|
||||
title: '合并请求-@我的'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'reviewed',
|
||||
name: 'mergeReviewed',
|
||||
component: () => import('@/views/Dashboard/Merge/index.vue'),
|
||||
meta: {
|
||||
basePath: 'merge',
|
||||
title: '合并请求-我评审的'
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
];
|
||||
26
src/router/config/editor.ts
Normal file
26
src/router/config/editor.ts
Normal file
@@ -0,0 +1,26 @@
|
||||
import DefaultLayout from '@/layouts/DefaultLayout/index.vue';
|
||||
|
||||
export default [
|
||||
{
|
||||
path: '/online_editor',
|
||||
meta: {
|
||||
className: 'max-w-[100%] m-auto w-full',
|
||||
},
|
||||
component: DefaultLayout,
|
||||
children: [
|
||||
{
|
||||
path: '',
|
||||
name: 'onlineEditor',
|
||||
component: () => import('@/views/Repo/online_editor/index.vue'),
|
||||
meta: {
|
||||
hasMobile: true,
|
||||
asideMenu: 'drawer',
|
||||
title: '在线编辑器',
|
||||
reportTitle: '在线编辑器',
|
||||
pType: 'onlineEditor',
|
||||
hiddenFooter: true
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
52
src/router/config/error.ts
Normal file
52
src/router/config/error.ts
Normal file
@@ -0,0 +1,52 @@
|
||||
import DefaultLayout from '@/layouts/DefaultLayout/index.vue';
|
||||
|
||||
export default [
|
||||
{
|
||||
path: '/',
|
||||
component: DefaultLayout,
|
||||
children: [
|
||||
{
|
||||
path: '404',
|
||||
name: '404',
|
||||
component: () => import('@/views/ErrorPage/index.vue'),
|
||||
meta: {
|
||||
title: '404',
|
||||
hasMobile: true
|
||||
}
|
||||
},
|
||||
{
|
||||
path: '403',
|
||||
name: '403',
|
||||
component: () => import('@/views/ErrorPage/index.vue'),
|
||||
meta: {
|
||||
title: '403',
|
||||
hasMobile: true
|
||||
}
|
||||
},
|
||||
{
|
||||
path: '503',
|
||||
name: '503',
|
||||
component: () => import('@/views/ErrorPage/index.vue'),
|
||||
meta: {
|
||||
title: '503',
|
||||
hasMobile: true
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
path: '/:pathMatch(.*)*',
|
||||
component: DefaultLayout,
|
||||
children: [
|
||||
{
|
||||
path: '',
|
||||
name: 'notFound',
|
||||
component: () => import('@/views/ErrorPage/index.vue'),
|
||||
meta: {
|
||||
title: '404',
|
||||
hasMobile: true
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
];
|
||||
57
src/router/config/home.ts
Normal file
57
src/router/config/home.ts
Normal file
@@ -0,0 +1,57 @@
|
||||
import DefaultLayout from '@/layouts/DefaultLayout/index.vue';
|
||||
|
||||
export default [
|
||||
{
|
||||
path: '/:namespace+',
|
||||
component: () => import('@/views/Homepage/index.vue'),
|
||||
name: 'homepage',
|
||||
meta: {
|
||||
hasMobile: true, // 是否展示移动端
|
||||
pageType: 'userOrOrg' // 用户或组织主页
|
||||
}
|
||||
},
|
||||
{
|
||||
path: '/',
|
||||
component: DefaultLayout,
|
||||
children: [
|
||||
{
|
||||
path: '',
|
||||
name: 'home',
|
||||
component: () => import('@/views/micro-page/proxy-homeweb.vue'),
|
||||
meta: {
|
||||
micorApp: ['micoro-app-homeweb-app'],
|
||||
hasMobile: true,
|
||||
hiddenFooter: true,
|
||||
reportTitle: '首页',
|
||||
className: 'w-full min-w-full',
|
||||
headerClassName: ''
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'search',
|
||||
name: 'search',
|
||||
component: () => import('@/views/Jyh/Search/index.vue'),
|
||||
meta: {
|
||||
title: '高级搜索',
|
||||
reportTitle: '搜索',
|
||||
className: 'w-full min-w-full',
|
||||
hiddenFooter: true,
|
||||
hasMobile: true,
|
||||
asideMenu: 'drawer' // 左侧菜单抽屉模式
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'explore',
|
||||
name: 'explore',
|
||||
component: () => import('@/views/micro-page/proxy-homeweb.vue'),
|
||||
meta: {
|
||||
micorApp: ['micoro-app-homeweb-app'],
|
||||
title: '搜索开源',
|
||||
className: 'w-full min-w-full',
|
||||
hiddenFooter: true,
|
||||
hasMobile: true
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
];
|
||||
14
src/router/config/issue.ts
Normal file
14
src/router/config/issue.ts
Normal file
@@ -0,0 +1,14 @@
|
||||
export default [
|
||||
{
|
||||
path: 'issues/create/choose',
|
||||
name: 'repoIssueCreateChoose',
|
||||
component: () => import('@/views/Repo/Issue/Choose/index.vue'),
|
||||
meta: {
|
||||
title: '选择新建issue模版',
|
||||
reportTitle: '选择新建issue模版',
|
||||
// todo? 统计
|
||||
pType: 'repoIssuesChoose',
|
||||
needLogin: true
|
||||
}
|
||||
},
|
||||
]
|
||||
23
src/router/config/notice.ts
Normal file
23
src/router/config/notice.ts
Normal file
@@ -0,0 +1,23 @@
|
||||
import DefaultLayout from '@/layouts/DefaultLayout/index.vue';
|
||||
// import NoticeLayout from '@/layouts/NoticeLayout/index.vue';
|
||||
// import ProxyView from '@/views/UserCenter/proxy.vue';
|
||||
|
||||
export default [
|
||||
{
|
||||
path: '/notice',
|
||||
component: DefaultLayout,
|
||||
children: [
|
||||
{
|
||||
path: '',
|
||||
name: 'notice',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: '通知中心',
|
||||
reportTitle: '通知',
|
||||
needLogin: true
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
];
|
||||
222
src/router/config/setting.ts
Normal file
222
src/router/config/setting.ts
Normal file
@@ -0,0 +1,222 @@
|
||||
import UserLayout from '@/layouts/UserLayout/index.vue';
|
||||
// import ProxyView from '@/views/UserCenter/proxy.vue';
|
||||
|
||||
export default [
|
||||
{
|
||||
path: '/setting',
|
||||
component: UserLayout,
|
||||
meta: {
|
||||
hideNav: true,
|
||||
sidebarType: 'userSetting',
|
||||
needLogin: true,
|
||||
reportTitle: '用户设置'
|
||||
},
|
||||
children: [
|
||||
{
|
||||
path: '',
|
||||
name: 'setting',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: '用户设置',
|
||||
application: 'user-center'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'account',
|
||||
name: 'settingAccount',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: '用户设置',
|
||||
application: 'user-center'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'cla',
|
||||
name: 'settingCla',
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: '用户已签署CLA',
|
||||
application: 'user-center'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'preference',
|
||||
name: 'settingPreference',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: '偏好设置',
|
||||
application: 'user-center'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'notice',
|
||||
name: 'settingNotice',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: '用户设置',
|
||||
application: 'user-center'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'organization',
|
||||
name: 'settingOrganization',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: '组织管理',
|
||||
application: 'user-center'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'email',
|
||||
name: 'settingEmail',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: '电子邮件',
|
||||
application: 'user-center'
|
||||
}
|
||||
},
|
||||
// {
|
||||
// path: 'password',
|
||||
// name: 'settingPassword',
|
||||
// component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
// meta: {
|
||||
// title: '密码设置'
|
||||
// }
|
||||
// },
|
||||
{
|
||||
path: 'key-ssh',
|
||||
name: 'settingSSH',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: 'SSH公钥',
|
||||
application: 'user-center'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'key-ssh/create',
|
||||
name: 'settingSSHCreate',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: '新建SSH',
|
||||
application: 'user-center'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'key-gpg',
|
||||
name: 'settingGPG',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: 'GPG公钥',
|
||||
application: 'user-center'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'key-gpg/create',
|
||||
name: 'settingGPGCreate',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: '新建GPG',
|
||||
application: 'user-center'
|
||||
}
|
||||
},
|
||||
// {
|
||||
// path: 'key-gpg',
|
||||
// name: 'settingGPG',
|
||||
// component: () => import('@/views/UserSetting/GPG/index.vue'),
|
||||
// meta: {
|
||||
// title: '用户设置'
|
||||
// }
|
||||
// },
|
||||
// {
|
||||
// path: 'key-gpg/create',
|
||||
// name: 'settingGPGCreate',
|
||||
// component: () => import('@/views/UserSetting/GPG/Create.vue'),
|
||||
// meta: {
|
||||
// title: '用户设置'
|
||||
// }
|
||||
// },
|
||||
{
|
||||
path: 'session',
|
||||
name: 'settingSession',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: '活动会话',
|
||||
application: 'user-center'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'repo',
|
||||
name: 'settingRepo',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: '项目管理',
|
||||
application: 'user-center'
|
||||
}
|
||||
},
|
||||
// {
|
||||
// path: 'reply',
|
||||
// name: 'settingReply',
|
||||
// component: () => import('@/views/UserSetting/Reply/index.vue'),
|
||||
// meta: {
|
||||
// title: '用户设置-快捷回复'
|
||||
// }
|
||||
// },
|
||||
// {
|
||||
// path: 'reply/create',
|
||||
// name: 'settingRepoCreate',
|
||||
// component: () => import('@/views/UserSetting/Reply/Create/index.vue'),
|
||||
// meta: {
|
||||
// title: '用户设置'
|
||||
// }
|
||||
// },
|
||||
// {
|
||||
// path: 'logs',
|
||||
// name: 'settingLog',
|
||||
// component: () => import('@/views/UserSetting/Log/index.vue'),
|
||||
// meta: {
|
||||
// title: '用户设置-审计日志'
|
||||
// }
|
||||
// },
|
||||
{
|
||||
path: 'pipeline',
|
||||
name: 'settingPipeline',
|
||||
component: () => import('@/views/UserSetting/Pipeline/index.vue'),
|
||||
meta: {
|
||||
title: '流水线'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'token-classic',
|
||||
name: 'settingClassic',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: '访问令牌(经典)',
|
||||
application: 'user-center'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'token-classic/create',
|
||||
name: 'settingClassicCreate',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: '新建访问令牌',
|
||||
application: 'user-center'
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
];
|
||||
75
src/router/config/user.ts
Normal file
75
src/router/config/user.ts
Normal file
@@ -0,0 +1,75 @@
|
||||
import UserLayout from '@/layouts/UserLayout/index.vue';
|
||||
// import ProxyView from '@/views/UserCenter/proxy.vue';
|
||||
|
||||
export default [
|
||||
{
|
||||
path: '/user/:namespace+',
|
||||
component: UserLayout,
|
||||
meta: { type: 'user', namespace: 'user' },
|
||||
children: [
|
||||
{
|
||||
path: '',
|
||||
name: 'user',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
pType: 'homepage',
|
||||
hasMobile: true,
|
||||
title: '个人主页',
|
||||
reportTitle: '个人主页', // 用于数组上报分析
|
||||
application: 'user-center'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'repos',
|
||||
name: 'userRepos',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: '个人项目',
|
||||
application: 'user-center'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'stars',
|
||||
name: 'userStars',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: 'Star列表',
|
||||
application: 'user-center'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'stars/:listName',
|
||||
name: 'userStarsList',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: 'Star列表详情',
|
||||
application: 'user-center'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'fans',
|
||||
name: 'userFans',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: '粉丝',
|
||||
application: 'user-center'
|
||||
}
|
||||
},
|
||||
{
|
||||
path: 'following',
|
||||
name: 'userFollowing',
|
||||
// component: ProxyView,
|
||||
component: () => import('@/views/UserCenter/proxy.vue'),
|
||||
meta: {
|
||||
title: '关注的人',
|
||||
application: 'user-center'
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
];
|
||||
Reference in New Issue
Block a user