Commit Graph

388 Commits

Author SHA1 Message Date
c5486dd3d3 feat: 启用后端自动启动与 Setup 引导流程增强
主要修改点:

1. 网络绑定扩展至 Server
   - .env.example: SERVER_HOST/VITE_SERVER_HOST 从 127.0.0.1 改为 0.0.0.0
   - server/src/app/core/config.py: 默认 app_host 从 127.0.0.1 改为 0.0.0.0

2. 启动脚本重构(重命名以区分职责)
   - server/start.sh → server/server_start.sh
   - web/start.sh → web/web_start.sh
   - 根目录 start.sh: 更新调用路径(./start.sh → ./server_start.sh, ./web_start.sh)
   - 根目录 start.sh: 新增 setup_ready() 检测函数
   - 根目录 start.sh: server_probe_host() 支持 0.0.0.0 探测转换为 127.0.0.1
   - 根目录 start.sh: start_setup_web() 新增 X_FINANCIAL_FORCE_SETUP=true

3. API URL 动态化 (web/src/services/api.js)
   - 从 localStorage 持久化读取 API Base URL
   - 新增 setRuntimeApiBaseUrl() / getRuntimeApiBaseUrl() 导出函数
   - buildUrl() 改用运行时 runtimeApiBaseUrl

4. 浏览器 Host 智能解析 (web/vite.config.js)
   - 新增 resolveBrowserApiHost(): 根据 server_host/web_host 配置决定浏览器端使用的 API Host
   - buildApiBaseUrl() 改用 resolveBrowserApiHost()
   - 新增后端启动状态管理: backendStartState / cloneBackendStartState() / updateBackendStep()
   - 后端启动分 5 步追踪: config → deps → server → health → done
   - 新增 backendStartPromise 避免重复启动

5. Setup 表单逻辑增强 (web/src/composables/useSetupView.js)
   - 新增 shouldExposeServerHost(): 判断浏览器 host 是否非本地
   - 新增 resolveInitialServerHost(): 当浏览器访问且 server_host 为本地时暴露 0.0.0.0
   - buildPayload(): 根据 shouldExposeServerHost() 自动将 127.0.0.1/localhost 转为 0.0.0.0

6. Bootstrap API 扩展 (web/src/services/bootstrap.js)
   - 新增 startBootstrapBackend(): POST /bootstrap/backend 触发后端启动
   - 新增 fetchBootstrapBackendStatus(): GET /bootstrap/backend 查询后端状态

7. Session 导航增强 (web/src/composables/useSystemState.js)
   - 新增 resolveBrowserApiBaseUrl(): 智能解析浏览器端 API Base URL
   - installSessionNavigation(): 调用 fetchBootstrapState() 同步引导状态
   - 新增 reconcileEntryRoute(): 根据引导状态协调路由
   - VITE_SERVER_HOST 默认值从 127.0.0.1 改为 0.0.0.0

8. Setup 视图增强 (web/src/views/SetupRouteView.vue)
   - 向 SetupView 传递启动进度相关 props: startupCountdownSeconds, startupLog, startupSteps, startupVisible, progressMessage

9. CSS 新增 (web/src/assets/styles/views/setup-view.css)
   - .setup-complete-progress: 进度文字样式
   - .setup-modal-backdrop: 模态框遮罩
   - .setup-startup-modal: 启动模态框容器
   - .setup-startup-head / .setup-startup-body / .setup-startup-spinner: 模态框头部/内容/加载动画
   - .setup-startup-steps / .setup-startup-step: 步骤列表及单个步骤
   - .setup-startup-step.is-running / .is-success / .is-failed: 步骤状态样式
   - .setup-startup-log: 启动日志区域
2026-05-08 10:52:54 +08:00
828e8f5aaf feat: 优化网络绑定配置支持外部访问
主要修改点:
1. 网络绑定调整
   - .env.example: WEB_HOST/VITE_WEB_HOST 从 127.0.0.1 改为 0.0.0.0
   - server/src/app/core/config.py: 默认 web_host 从 127.0.0.1 改为 0.0.0.0
   - web/package.json: Vite 脚本 host 从 127.0.0.1 改为 0.0.0.0
   - web/vite.config.js: normalizeState 中 WEB_HOST 默认值从 127.0.0.1 改为 0.0.0.0

2. CORS 配置扩展
   - .env.example: CORS_ORIGINS 添加 http://0.0.0.0:5173

3. Shell 脚本权限修复
   - server/start.sh, start.sh: 添加可执行权限 (644 -> 755)

4. Setup 表单与验证逻辑简化
   - web/src/composables/useSetupView.js:
     - 新增 readCurrentWebEndpoint() 从 window.location 自动检测当前 web host/port
     - 简化 runtimeInputsReady: 移除 web_host/web_port 必填验证,仅保留 server_host/server_port
     - 简化 buildRuntimeFingerprint(): 移除 web_host/web_port
     - buildPayload() 改用 readCurrentWebEndpoint() 解析 web 配置
   - web/vite.config.js:
     - 新增 resolveRuntimePayload(): 运行时解析 web_host/web_port
     - 移除 validateRuntimePayload() 中的 web_host/web_port 字段验证
     - 移除 testRuntimePorts() 中 web 端口冲突检测逻辑
     - 移除 canReuseCurrentWebPort() 函数

5. CSS 清理
   - web/src/assets/styles/views/setup-view.css: 移除未使用的 .setup-summary-grid 和 .setup-summary-item 样式
2026-05-08 09:27:45 +08:00
adda87a01d feat: add system settings with model connectivity and encrypted storage 2026-05-08 08:56:52 +08:00
e8f3d97d6a feat: add settings page with navigation and access control updates 2026-05-07 15:55:23 +08:00
b8ba0ea6a0 feat: add auth module with login and access control 2026-05-07 14:34:42 +08:00
2d56bc2889 feat: enhance employee CRUD with search, filters, and security module 2026-05-07 13:48:00 +08:00
c00db75c13 feat: add employee management, backend health check, and UI improvements 2026-05-07 11:50:10 +08:00
a5db09f41e docs: update work log with commit details and problem/solution
- Add commit file changes statistics
- Add Problem/Solution sections
- Add What's Done/Not Done sections

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-06 22:29:02 +08:00
62f7810bd0 docs: restore full work log with commit history
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-06 22:26:59 +08:00
f1dcfcfebf docs: update work log with git commits
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-06 22:25:48 +08:00
04e4b7148c docs: add work log for 2026-05-06
- Fix server/start.sh venv issue on Windows/Git Bash
- Create work-log skill for project documentation
- Add SetupView and routing refactoring

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-06 22:25:01 +08:00
ae63766c91 Add vue-router, login/setup flow and backend logging
Refactor frontend to route-based navigation with vue-router, add
system setup and login pages with API integration. Add structured
logging, access-log middleware and startup lifecycle to FastAPI
backend.
2026-05-06 22:23:42 +08:00
83d7da3d62 feat: add FastAPI backend with PostgreSQL and start script fixes
- Add server/ directory with FastAPI backend
- Fix server/start.sh to properly handle venv on Windows/Git Bash
- Add alembic migrations and pyproject.toml
- Add server tests

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-06 17:43:47 +08:00
9785fb527b refactor: split project into web and server directories
- Move frontend to web/ directory
- Add server/ directory for backend
- Restructure project for前后端分离架构

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-06 11:00:38 +08:00
9a7b0794a1 refactor: refactor smart entry as standalone modal overlay
- Convert TravelReimbursementCreateView from page to modal overlay
- Simplify App.vue navigation flow with smartEntryOpen state
- Add create-request button in RequestsView

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-05 23:47:20 +08:00
2d2ed27861 feat: add skill center navigation and travel request detail view
- Refactor audit to skill center for skill management
- Add TravelRequestDetailView for requests detail page
- Update PersonalWorkbench with enhanced features
- Add UI preview screenshots

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-05 22:35:38 +08:00
ab9f132192 feat: add personal workbench view with todo and reimbursement tracking
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-05 18:22:47 +08:00
ad66067694 feat: add breathing animation to current progress step node
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-02 23:44:16 +08:00
fb0cbb4bda chore: add UI preview screenshots for knowledge ops and approval
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-05-02 11:30:54 +08:00
e356a842ff refactor: simplify ChatView and ApprovalCenterView layout structure
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-05-02 11:30:43 +08:00
c0720d4b23 refactor: streamline layout, views routing and component composition
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-05-02 11:30:25 +08:00
8fb3992fb3 feat: improve TopBar layout with refined styling and navigation state
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-05-02 11:30:12 +08:00
ff894969f4 chore: add UI preview screenshots for documentation
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-05-01 00:43:01 +08:00
99fde07826 feat: add ApprovalCenterView with animated rolling values
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-05-01 00:41:52 +08:00
7d6dbc4ac0 chore: remove prototype files and unused UI assets
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-05-01 00:39:24 +08:00
64537119e0 fix: adjust knowledge operations overview layout and add rank badges
- Change ops-grid from 3 columns to 2 for better metric card sizing
- Add rank badges (hot/warm/normal) to liked and disliked answer lists
- Unify row heights (min-height: 32px) across hot-list and feedback-list
2026-04-30 22:11:57 +08:00
789f90dc1f feat: improve layout shell, navigation composables and add UI assets
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-04-30 17:11:24 +08:00
d07f88ba34 feat: enhance ChatView with improved layout and conversation interactions
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-04-30 17:11:05 +08:00
9e61163fa2 feat: redesign RequestsView with travel expense table, KPIs and pagination
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-04-30 17:10:47 +08:00
053ebdbcb0 feat: add travel reimbursement creation page
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-04-30 17:10:30 +08:00
d860b0cc34 feat: refactor OverviewView to extract inline charts into components
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-04-30 17:10:12 +08:00
e9f6a726db feat: add reusable BarChart and GaugeChart components
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-04-30 17:09:56 +08:00
8fcb9c7500 feat: redesign LoginView with hero layout, SSO and tenant support
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-04-30 17:09:38 +08:00
cbbd4d37b5 feat: add Chart.js doughnut charts and refine KPI card layout
- Replace CSS conic-gradient donuts with Chart.js Doughnut component

- New DonutChart.vue with hover tooltips, centered label, two-column legend

- KPI cards: icon-left layout, compact K/M formatting, horizontal trend row

- Value font scaled down to 18-22px for better visual hierarchy

Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-04-29 23:50:50 +08:00
ecc0693cd7 feat: improve ChatView, add LoginView and demo reference page
- ChatView: enhanced AI chat interface with improved message rendering

- LoginView: new login page component

- demo/main_demo.html: reference implementation for Chart.js dashboards

Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-04-29 23:36:40 +08:00
f98ad7953f feat: add interactive Chart.js trend chart and improve KPI card layout
- Replace static SVG trend chart with Chart.js bar+line mixed chart

- Click-triggered custom tooltip popup with per-day detail overlay

- KPI cards: flex column layout, compact K/M currency formatting

- Custom legend above chart for consistent spacing

Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-04-29 23:36:18 +08:00
e54ebd072a feat: enhance layout components, data layer and global styles
- SidebarRail, TopBar, FilterBar: improved navigation and filtering UX

- metrics.js, requests.js: expanded data with multi-range trend series

- composables: enhanced useChat, useNavigation, useRequests

- global.css: refined design tokens and utility classes

- Add DocFilterBar component and LoginView page

Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
2026-04-29 23:35:56 +08:00
7141e1d11a feat: refactor monolithic App.vue into modular Vue component architecture
- Extract 711-line App.vue into 15+ focused files across 5 directories
- Add data layer (icons, metrics, policies, auditTrail, requests)
- Add composables (useNavigation, useRequests, useChat, useToast)
- Add layout components (SidebarRail, TopBar, FilterBar)
- Add shared components (PanelHead, InfoRow, ToastNotification)
- Add business component (RequestTable) and 5 view components
- Extract global CSS to assets/styles/global.css
- Add start.sh with WSL/Windows cross-platform support
- Add .gitignore for node_modules, dist, and IDE dirs
2026-04-28 17:20:52 +08:00