refactor: 大规模代码整理与功能优化

1. 重构后端API路由、CRUD与模块结构,整合日志管理,移除废弃demo代码
2. 优化前端组件类型定义、样式与路由配置,修复权限判断逻辑
3. 调整默认排序规则、滚动条样式与工具类函数,更新依赖与配置文件
4. 修复多处类型不匹配与默认值问题,完善表单与菜单验证逻辑
This commit is contained in:
zhangtao
2026-06-17 01:56:31 +08:00
parent 17b3cd0a4c
commit 73f2823692
500 changed files with 40763 additions and 26616 deletions
@@ -12,8 +12,10 @@
import { computed, watch, nextTick, onUnmounted, shallowRef } from "vue";
import { useTransition, TransitionPresets } from "@vueuse/core";
defineOptions({ name: "FaCountTo" });
// 类型定义
interface CountToProps {
interface Props {
/** 目标值 */
target: number;
/** 动画持续时间(毫秒) */
@@ -36,7 +38,7 @@ interface CountToProps {
disabled?: boolean;
}
interface CountToEmits {
interface Emits {
started: [value: number];
finished: [value: number];
paused: [value: number];
@@ -64,7 +66,7 @@ const MAX_DECIMALS = 10;
const DEFAULT_EASING = "easeOutExpo";
const DEFAULT_DURATION = 2000;
const props = withDefaults(defineProps<CountToProps>(), {
const props = withDefaults(defineProps<Props>(), {
target: 0,
duration: DEFAULT_DURATION,
autoStart: true,
@@ -77,7 +79,7 @@ const props = withDefaults(defineProps<CountToProps>(), {
disabled: false,
});
const emit = defineEmits<CountToEmits>();
const emit = defineEmits<Emits>();
// 工具函数
const validateNumber = (value: number, name: string, defaultValue: number): number => {
@@ -7,7 +7,7 @@
<FaTextScroll
v-if="showFestivalStrip"
class="mb-3!"
type="primary"
type="theme"
:text="festivalScrollDisplayHtml"
height="40px"
:speed="55"
@@ -67,7 +67,7 @@ type ThemeType =
/**
* 文本滚动组件属性接口
*/
export interface TextScrollProps {
export interface Props {
/** 滚动文本内容 */
text?: string;
/** 主题类型 */
@@ -88,7 +88,7 @@ export interface TextScrollProps {
alwaysScroll?: boolean;
}
const props = withDefaults(defineProps<TextScrollProps>(), {
const props = withDefaults(defineProps<Props>(), {
text: "",
direction: "left",
speed: 80,
@@ -100,9 +100,11 @@ const props = withDefaults(defineProps<TextScrollProps>(), {
alwaysScroll: true,
});
const emit = defineEmits<{
interface Emits {
close: [];
}>();
}
const emit = defineEmits<Emits>();
const handleClose = () => {
emit("close");