提交1 bmad搭建与项目启动 - ok

This commit is contained in:
2025-10-17 17:24:56 +08:00
commit ec58562661
686 changed files with 149750 additions and 0 deletions

View File

@@ -0,0 +1,57 @@
// 应用常量配置
export const APP_CONFIG = {
name: '智慧农业生产管理系统',
version: '1.0.0',
description: 'Smart Agriculture Production Management System'
}
// 路由常量
export const ROUTE_CONSTANTS = {
LOGIN: '/login',
DASHBOARD: '/dashboard',
// 模块路由前缀
MACHINERY: '/machinery',
LAND: '/land',
OPERATION: '/operation',
ASSET: '/asset',
AI_MODEL: '/ai-model',
IRRIGATION: '/irrigation',
CONFIG: '/config'
}
// 状态常量
export const STATUS = {
ACTIVE: 'active',
INACTIVE: 'inactive',
PENDING: 'pending',
COMPLETED: 'completed',
CANCELLED: 'cancelled',
ERROR: 'error'
}
// 用户角色
export const USER_ROLES = {
ADMIN: 'admin',
MANAGER: 'manager',
OPERATOR: 'operator',
VIEWER: 'viewer'
}
// 分页默认配置
export const PAGINATION = {
DEFAULT_PAGE_SIZE: 10,
DEFAULT_PAGE: 1,
PAGE_SIZE_OPTIONS: [10, 20, 50, 100]
}
// 主题配置
export const THEME = {
colors: {
primary: '#0ea5e9',
secondary: '#64748b',
success: '#22c55e',
warning: '#f59e0b',
error: '#ef4444'
}
}

View File

@@ -0,0 +1,85 @@
// 功能配置系统 - 特性开关
export const featureConfig = {
// 认证系统
auth: {
enabled: true,
mockData: true,
phoneLogin: true,
autoLogin: true
},
// 地块管理
landManagement: {
enabled: true,
mapIntegration: true,
spatialAnalysis: true,
riskWarning: true
},
// 农机管理
machineryManagement: {
enabled: true,
realTimeMonitoring: true,
faultDiagnosis: true,
precisionFarming: true,
scheduling: true
},
// 农事管理
farmingOperation: {
enabled: true,
planning: true,
tracking: true,
analysis: true
},
// 资产管理
assetManagement: {
enabled: true,
inventory: true,
depreciation: true
},
// AI模型
aiModel: {
enabled: true,
prediction: true,
recommendation: true,
analysis: true
},
// 水肥控制
irrigationControl: {
enabled: true,
automation: true,
monitoring: true,
scheduling: true
},
// 系统配置
systemConfig: {
enabled: true,
tenantManagement: true,
userManagement: true,
systemMonitoring: true,
messageCenter: true
}
}
// 环境配置
export const envConfig = {
development: {
apiUrl: 'http://localhost:3001/api',
mockApi: true,
debugMode: true
},
production: {
apiUrl: '/api',
mockApi: false,
debugMode: false
}
}
// 当前环境
export const currentEnv = import.meta.env.MODE || 'development'
export const config = envConfig[currentEnv]