Commit Graph

342 Commits

Author SHA1 Message Date
MarkLo 803885305a 2025-12-16 19:03:58 +08:00
MarkLo 488eeac64c 2025-12-16 18:45:43 +08:00
MarkLo 5569f1097c 2025-12-16 18:31:24 +08:00
MarkLo ad86c6c9e9
更新 README.md 2025-12-16 15:12:26 +08:00
MarkLo 04d3bc7de3 2025-12-16 13:32:42 +08:00
MarkLo 48256c2c23 2025-12-16 13:21:02 +08:00
MarkLo 875772bb0f 2025-12-16 04:18:29 +08:00
MarkLo ecc31c9710 2025-12-16 03:05:55 +08:00
MarkLo 5b46904a98 2025-12-16 02:55:58 +08:00
MarkLo 83680dba26 2025-12-16 02:33:22 +08:00
MarkLo 8bd7bcee59 2025-12-16 02:19:25 +08:00
MarkLo ce584183ff 2025-12-16 02:06:07 +08:00
MarkLo 8fcc3d6256 2025-12-16 01:57:40 +08:00
MarkLo dbee0c4817 2025-12-16 01:42:30 +08:00
MarkLo 4234a181e5 2025-12-16 01:19:21 +08:00
MarkLo 69ca5b75c1 2025-12-16 00:54:15 +08:00
MarkLo 47f04a6ff7 2025-12-16 00:45:07 +08:00
MarkLo 7d5155052b 2025-12-16 00:18:15 +08:00
MarkLo b47e79f44a 2025-12-15 03:48:13 +08:00
MarkLo 3568ff5b33 2025-12-15 03:38:56 +08:00
MarkLo facd78aac3 2025-12-15 03:17:48 +08:00
MarkLo 4f347316a1 2025-12-15 02:02:24 +08:00
MarkLo 1e6237977b 2025-12-15 00:24:40 +08:00
MarkLo 1cacc8d0be 2025-12-14 23:30:41 +08:00
MarkLo e8b6919179 2025-12-14 21:26:36 +08:00
MarkLo 2143b02541
Delete frontend/README.md 2025-12-14 04:50:21 +08:00
MarkLo 4016976e1d 2025-12-14 04:34:15 +08:00
MarkLo 22f57a8674 feat: recover pending analysis tasks after page close
Added task recovery system that allows users to recover and save
analysis results even if they accidentally close the page:

1. New pending-task.ts utility:
   - Saves task info to localStorage when analysis starts
   - Clears after task completes/fails
   - 24-hour expiry for old tasks

2. PendingTaskRecovery component:
   - Shows on history page if pending task found
   - Polls API for task status
   - Saves result to IndexedDB + cloud upon completion

3. Updated useAnalysis hook:
   - Tracks pending tasks in localStorage
   - Clears on completion/failure

Now users visiting /history after closing the page during analysis
will see a prompt to recover and save their completed report.
2025-12-14 03:55:12 +08:00
MarkLo 07f76294d8 2025-12-14 03:48:26 +08:00
MarkLo cf4aaa09b1 feat: auto-save reports + fix PDF download from history
1. Auto-save reports when page closes:
   - Added beforeunload handler to auto-save analysis to history
   - Saves to local IndexedDB and cloud (if authenticated)
   - Prevents data loss if user accidentally closes the page

2. Fix PDF download from history page:
   - Made taskId optional in DownloadReports component
   - Added direct mode: can pass reports data directly
   - Updated backend to support both task-based and direct-data modes
   - History reports now have download PDF option available
2025-12-14 03:21:59 +08:00
MarkLo 3f13475485 feat: add Heikin Ashi candlestick and volume charts to PDF reports
- Add matplotlib for chart generation
- Implement _calculate_heikin_ashi() for HA OHLC calculation
- Implement _generate_price_chart() to create candlestick + volume charts
- Charts are generated as PNG images and embedded in PDF
- Fallback to text summary if chart generation fails
- First page now shows visual charts like the web interface
2025-12-14 03:11:47 +08:00
MarkLo 9ceff4cf9b feat: add price information cover page to analyst PDF reports
- Page 1 now shows price statistics (growth rate, duration, start/end prices)
- Page 1 also includes last 5 trading days data
- Page 2+ contains the original analyst insights
- Updates pdf_generator.py, download_service.py, and routes.py
2025-12-14 02:45:14 +08:00
MarkLo 11cda2acaf 2025-12-14 02:31:31 +08:00
MarkLo 8ca4072233 fix: add apple-touch-icon.png for iOS Safari compatibility 2025-12-14 02:30:55 +08:00
MarkLo 155454f164 2025-12-14 00:09:06 +08:00
MarkLo a8d9dee437 feat: add manifest.json for PWA and Safari support 2025-12-13 23:34:20 +08:00
MarkLo beb6ea6bdc 2025-12-13 23:26:03 +08:00
MarkLo 9280c71bfc 2025-12-13 22:50:40 +08:00
MarkLo ca1d0f092f 2025-12-13 16:57:20 +08:00
MarkLo 0bddce0cdc 2025-12-13 16:48:12 +08:00
MarkLo bddcca3ebb 2025-12-13 16:19:46 +08:00
MarkLo c9f6e6a8d1 2025-12-13 07:14:45 +08:00
MarkLo 8b2dbe9437 2025-12-13 06:50:03 +08:00
MarkLo 7926eb74b4 2025-12-13 06:42:20 +08:00
MarkLo 2a65c7f44d 2025-12-13 06:34:48 +08:00
MarkLo 4eed994fcb 2025-12-13 06:22:59 +08:00
MarkLo bcfa6dab06 2025-12-13 06:13:15 +08:00
MarkLo 5d3751602e 2025-12-13 06:00:19 +08:00
MarkLo eed052abe9 2025-12-13 03:15:29 +08:00
MarkLo 95f6b25333 2025-12-13 02:26:49 +08:00