diff --git a/src/app/manifest.ts b/src/app/manifest.ts new file mode 100644 index 0000000..24d9ae1 --- /dev/null +++ b/src/app/manifest.ts @@ -0,0 +1,21 @@ +import type { MetadataRoute } from "next"; + +export default function manifest(): MetadataRoute.Manifest { + return { + name: "Next_Edu - K12 智慧教务系统", + short_name: "NextEdu", + description: "Enterprise Grade K12 Education Management System", + start_url: "/", + display: "standalone", + background_color: "#ffffff", + theme_color: "#1976d2", + orientation: "any", + icons: [ + { + src: "/icon.svg", + sizes: "any", + type: "image/svg+xml", + }, + ], + }; +} \ No newline at end of file diff --git a/vercel.json b/vercel.json new file mode 100644 index 0000000..5b1effb --- /dev/null +++ b/vercel.json @@ -0,0 +1,9 @@ +{ + "$schema": "https://openapi.vercel.sh/vercel.json", + "crons": [ + { + "path": "/api/cron/audit-cleanup", + "schedule": "0 3 * * *" + } + ] +} diff --git a/vitest.config.ts b/vitest.config.ts index a5754b2..61e6fff 100644 --- a/vitest.config.ts +++ b/vitest.config.ts @@ -5,6 +5,8 @@ export default defineConfig({ resolve: { alias: { "@": path.resolve(__dirname, "src"), + // 测试环境跳过 server-only 守卫(生产环境阻止客户端导入服务端模块) + "server-only": path.resolve(__dirname, "tests/setup/empty-stub.ts"), }, }, test: {