add:fronted
This commit is contained in:
@@ -0,0 +1,4 @@
|
||||
# @Time : 2023/8/14 14:38
|
||||
# @Author : Lan
|
||||
# @File : __init__.py.py
|
||||
# @Software: PyCharm
|
||||
@@ -0,0 +1,10 @@
|
||||
# @Time : 2023/8/14 14:38
|
||||
# @Author : Lan
|
||||
# @File : views.py
|
||||
# @Software: PyCharm
|
||||
from fastapi import APIRouter
|
||||
|
||||
admin_api = APIRouter(
|
||||
prefix='/admin',
|
||||
tags=['管理'],
|
||||
)
|
||||
Vendored
+7
@@ -8,18 +8,25 @@ export {}
|
||||
declare module 'vue' {
|
||||
export interface GlobalComponents {
|
||||
CardTools: typeof import('./src/components/CardTools.vue')['default']
|
||||
ElAside: typeof import('element-plus/es')['ElAside']
|
||||
ElButton: typeof import('element-plus/es')['ElButton']
|
||||
ElCard: typeof import('element-plus/es')['ElCard']
|
||||
ElCol: typeof import('element-plus/es')['ElCol']
|
||||
ElContainer: typeof import('element-plus/es')['ElContainer']
|
||||
ElDrawer: typeof import('element-plus/es')['ElDrawer']
|
||||
ElHeader: typeof import('element-plus/es')['ElHeader']
|
||||
ElIcon: typeof import('element-plus/es')['ElIcon']
|
||||
ElInput: typeof import('element-plus/es')['ElInput']
|
||||
ElMain: typeof import('element-plus/es')['ElMain']
|
||||
ElMenu: typeof import('element-plus/es')['ElMenu']
|
||||
ElMenuItem: typeof import('element-plus/es')['ElMenuItem']
|
||||
ElOption: typeof import('element-plus/es')['ElOption']
|
||||
ElProgress: typeof import('element-plus/es')['ElProgress']
|
||||
ElRadio: typeof import('element-plus/es')['ElRadio']
|
||||
ElRadioGroup: typeof import('element-plus/es')['ElRadioGroup']
|
||||
ElRow: typeof import('element-plus/es')['ElRow']
|
||||
ElSelect: typeof import('element-plus/es')['ElSelect']
|
||||
ElSubmenu: typeof import('element-plus/es')['ElSubmenu']
|
||||
ElTag: typeof import('element-plus/es')['ElTag']
|
||||
ElUpload: typeof import('element-plus/es')['ElUpload']
|
||||
FileBox: typeof import('./src/components/FileBox.vue')['default']
|
||||
|
||||
@@ -5,9 +5,6 @@
|
||||
<template>
|
||||
<div>
|
||||
<RouterView />
|
||||
<div style="text-align: center; margin-top: 1rem;color: #606266">
|
||||
<a style="text-decoration: none;color: #606266" target="_blank" href="https://github.com/vastsa/FileCodeBox">FileCodeBox V2.0 Beta</a>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -13,6 +13,11 @@ const router = createRouter({
|
||||
name: 'send',
|
||||
component: () => import('@/views/SendView.vue'),
|
||||
},
|
||||
{
|
||||
path: '/admin',
|
||||
name: 'admin',
|
||||
component: () => import('@/views/AdminView.vue'),
|
||||
}
|
||||
],
|
||||
});
|
||||
|
||||
|
||||
@@ -0,0 +1,14 @@
|
||||
<template>
|
||||
<el-container style="width: 100vw;height: 100%;position: relative">
|
||||
<el-aside width="200" style="height: 100%">
|
||||
<el-menu>
|
||||
<el-menu-item index="1">文件管理</el-menu-item>
|
||||
<el-menu-item index="4">1</el-menu-item>
|
||||
</el-menu>
|
||||
</el-aside>
|
||||
<el-main>Main</el-main>
|
||||
</el-container>
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
|
||||
</script>
|
||||
@@ -83,6 +83,9 @@ const listenInput = (num: number) => {
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-card>
|
||||
<div style="text-align: center; margin-top: 1rem;color: #606266">
|
||||
<a style="text-decoration: none;color: #606266" target="_blank" href="https://github.com/vastsa/FileCodeBox">FileCodeBox V2.0 Beta</a>
|
||||
</div>
|
||||
</main>
|
||||
</template>
|
||||
<style lang='scss'>
|
||||
|
||||
@@ -8,6 +8,7 @@ from starlette.responses import HTMLResponse
|
||||
from starlette.staticfiles import StaticFiles
|
||||
from tortoise.contrib.fastapi import register_tortoise
|
||||
from apps.base.views import share_api
|
||||
from apps.admin.views import admin_api
|
||||
|
||||
app = FastAPI()
|
||||
|
||||
@@ -38,12 +39,10 @@ register_tortoise(
|
||||
"use_tz": False,
|
||||
"timezone": "Asia/Shanghai",
|
||||
}
|
||||
|
||||
)
|
||||
|
||||
app.include_router(
|
||||
share_api
|
||||
)
|
||||
app.include_router(share_api)
|
||||
app.include_router(admin_api)
|
||||
|
||||
|
||||
@app.get('/')
|
||||
|
||||
Reference in New Issue
Block a user