Commit Graph

765 Commits

Author SHA1 Message Date
duanshuwen
34711330bd feat(utils, payment): add execution lock utils and prevent duplicate payment requests
Add two new throttle utility methods: createAsyncThrottle and createExecutionLock for safe async operation locking. Update the existing throttle method's comment to clarify traditional timestamp usage. Replace DebounceUtils usage with ThrottleUtils.createExecutionLock in order footer and booking page payment handlers to prevent duplicate payments. Rewrite uni.requestPayment calls to use Promise wrapping for proper async handling, and add try/catch/finally blocks to ensure loading state is always cleaned up correctly. Fix template formatting and trailing commas across modified files.
2026-07-23 21:10:34 +08:00
duanshuwen
f71f28fe99 refactor(aigc): update aigc consent dialog and apis
- set developVersion to false for production build
- format api request calls for consistent readability
- simplify consent dialog template and remove unused styles
- update default consent text and add ruleClick emit event
- add new getUserAgreement api endpoint and export it
2026-07-23 21:04:54 +08:00
duanshuwen
d71bda5e0b feat(aigc): add user agreement page and update consent dialog
Add new AIGC user agreement page with scrollable markdown rendering, loading and retry states.
Register the new route in pages.json.
Restructure AigcConsentDialog's content into styled sections, and update its rule click handler to navigate directly to the new agreement page.
2026-07-23 20:45:30 +08:00
duanshuwen
021d1fc77d fix(gift-points-toast): update default credited points from 200 to 400 2026-07-23 20:38:58 +08:00
duanshuwen
13d019b191 feat(aigc): pass wechat login code to generator task requests
Refactor the shared wechat login code utility by moving it from the recharge service to a standalone module.
Add the sensitive request flag to the createAigcGeneratorTask POST API call.
Update the aigc detail and template use pages to fetch and pass the wechat login code when creating generation tasks.
Remove the redundant login code implementation from the recharge payment service.
2026-07-23 11:57:09 +08:00
duanshuwen
64c73ad6a6 fix(TopNavBar): update root page back navigation behavior
replace WeChat mini-program specific exit logic with uni.reLaunch to index page for consistent cross-platform behavior when at the root navigation stack
2026-07-22 22:13:42 +08:00
duanshuwen
14defcc5b7 feat(recharge): add full virtual recharge flow for aigc credits
- Replace legacy recharge API endpoints with new dedicated VirtualRechargeApi with sensitive request logging
- Implement pending order tracking, automatic payment reconciliation, and recovery for interrupted payments
- Overhaul recharge component logic to support both pre-defined package and custom amount recharge
- Fix currency price formatting to consistently display 2 decimal places for all monetary values
- Remove unused xiaoqi-avatar asset and related component imports
- Simplify Vite build asset naming configuration
- Switch application to test development mode
2026-07-22 16:17:16 +08:00
duanshuwen
2407a9d941 refactor(aigc): update carousel and video components
- rewrite template carousel from custom scroll to uni swiper
- add video loading, error, and replay states to result preview
- update template card styles and video/poster handling logic
- clean up unused CSS vars and remove unnecessary min-height on detail page
- fix video file regex and add video error recovery
2026-07-18 15:30:06 +08:00
duanshuwen
05edc5666c Merge branch 'home3.0' of https://git.nianxx.cn/zoujing/YGChatCS into aigc 2026-07-18 09:29:22 +08:00
duanshuwen
5fe3dd54b3 feat(aigc): add auto-redirect when generation completes
Add complete event to GeneratingProgressPanel that emits when task status is completed and progress reaches 100%. Add handler in the parent progress page to automatically navigate to task detail page when the complete event is triggered, and stop ongoing task detail polling. Also enhance media download handling in the detail page with proper WeChat mini-program file path handling, error wrapping, temporary file cleanup, and improved error reporting for download failures.
2026-07-17 23:33:12 +08:00
duanshuwen
9b19da2257 fix(GiftPointsToast): update default points to 200 2026-07-17 21:44:46 +08:00
duanshuwen
1a4b320dc5 feat: add aigc regenerate flow and improve task polling
Add reusable RegenerateConfirmPopup component. Implement full regeneration flow in AIGC detail page with balance checks, insufficient point prompt, task creation and progress page navigation. Refine progress page polling logic with lifecycle handling, duplicate request prevention and timer cleanup.
2026-07-17 21:36:08 +08:00
9506a9034a feat: 去掉探索服务 2026-07-17 21:24:14 +08:00
duanshuwen
b04e3a4613 feat(aigc): add shared work top bar and back fixes
- add leftAction prop to AigcTopBar to switch between back arrow and home icon
- pass source=sharedWork query param when reLaunching home from shared work page
- update home page to detect shared work source, adjust top bar and back behavior
- add CSS styling for home top bar icon
- update root page back handler to exit WeChat mini program
2026-07-17 09:29:38 +08:00
duanshuwen
767ecb197b refactor: simplify TopNavBar and update sharedWork back handling
remove leftAction prop and hardcode left icon type in TopNavBar
move home navigation logic out of TopNavBar to parent components
update sharedWork.vue to use new TopNavBar API and implement proper back handling
2026-07-17 08:48:07 +08:00
duanshuwen
dc12b8ba88 feat: update TopNavBar and shared work page navigation
Add leftAction prop to TopNavBar to support back or home left navigation actions, update left icon accordingly. Add optional chaining to shareDetail.templateName to prevent errors. Modify sharedWork page to use home left action and update back handler to use direct home reLaunch.
2026-07-16 22:45:15 +08:00
duanshuwen
cf723e5b93 fix(detail): implement proper recharge navigation
replace placeholder toast with actual recharge page navigation, and add a failure callback to show error toast on navigation fail
2026-07-16 22:32:41 +08:00
7ff5fa6933 Merge branch 'aigc' of https://git.nianxx.cn/zoujing/YGChatCS into home3.0 2026-07-16 22:21:17 +08:00
duanshuwen
f3b4fd04d0 feat(record-card): expand card clickable area
move view event emission from the action button to the root record card component, expanding the clickable area to let the entire card trigger the view event when actionText is present, improving user experience.
2026-07-16 22:16:58 +08:00
ccc927b89f Merge branch 'aigc' of https://git.nianxx.cn/zoujing/YGChatCS into home3.0 2026-07-16 22:14:28 +08:00
e75c83e592 feat: 添加呼叫热线 2026-07-16 22:14:10 +08:00
duanshuwen
0a136c3040 refactor(detail): extract date formatter and clean up complete time
add formatDateOnly utility to extract YYYY-MM-DD part from date strings, and refactor the complete time calculation to use this helper
2026-07-16 22:02:25 +08:00
duanshuwen
52b6722842 feat(aigc): add video save support and improve consent flow
- add support for saving both image and video AIGC generation results
- refactor ResultActions component to accept mediaType prop and use dynamic save button text
- remove AIGC consent dialog from ChatQuickAccess and implement it on AIGC home page
- add WeChat mini-program privacy authorization check before saving media
- create reusable AigcConsentDialog component with proper styling
2026-07-16 21:49:00 +08:00
duanshuwen
38dbf7afc8 fix(aigc): correct generated media preview handling
update ResultPreview component to use proper image and video result URLs
refine isVideo detection logic across detail and shared work pages
add pointer-events none to preview elements to avoid blocking user interactions
standardize media URL usage between AIGC detail and shared work components
2026-07-16 21:24:38 +08:00
bce3e5912f Merge branch 'aigc' of https://git.nianxx.cn/zoujing/YGChatCS into home3.0 2026-07-16 21:16:58 +08:00
39c4e75de5 feat: 路由跳转的优化 2026-07-16 21:16:48 +08:00
duanshuwen
487caf9dbe feat(shared-work): update page ui and navigation
add dynamic template name to top nav bar
set top nav background to white
adjust media container styles and image display mode
remove redundant is-video CSS class and gradient backgrounds
update action button to pill shape with white text
remove scroll-y prop from scroll container
fix scroll container layout and padding
2026-07-16 21:09:22 +08:00
duanshuwen
99151bca58 feat(recharge): add points recharge agreement flow
- add new API request for fetching points top up agreement content
- update recharge footer with agreement checkbox and protocol link
- add agreement popup modal to display full agreement text
- add payment pre-validation to enforce agreement acceptance before payment
- handle loading and error states for agreement retrieval
- adjust recharge footer layout to accommodate new UI elements
2026-07-16 20:34:01 +08:00
duanshuwen
67b1b78f1f feat(aigc): add shared work page and AIGC sharing
- add new shared work page to view shared AIGC generated images and videos
- add createAigcGeneratorTaskShare and getAigcGeneratorTaskShareDetail APIs
- update ResultActions component to add share preparation state and native share support
- remove deprecated SharePreviewPopup component and its associated styles
- update AIGC detail page to generate share keys and adjust native share metadata
- register the new shared work page in pages.json
2026-07-16 13:28:46 +08:00
duanshuwen
dcf67dedfc feat(aigc/detail): add share preview popup
create reusable SharePreviewPopup component for share preview
update ResultActions to emit share event instead of direct native share
add share preview flow in aigc detail page
update native share config with correct image and fallback title
2026-07-16 11:25:39 +08:00
23f8453868 Merge branch 'aigc' of https://git.nianxx.cn/zoujing/YGChatCS into home3.0 2026-07-16 09:11:01 +08:00
duanshuwen
ada88d7b20 feat(aigc): replace mock credit data with backend api fetch
add getCreditLedgerPage API function to fetch credit ledger records
remove local mock ledger data file
update LedgerCard component to adapt to new API response structure
rewrite points details page to use z-paging with empty and error handling
2026-07-16 09:04:04 +08:00
cd61685b0b feat: 商品详情的展示问题处理 2026-07-15 17:14:34 +08:00
duanshuwen
c7785e55d7 feat(aigc): add standalone AIGC task progress page
- Add dedicated progress page for viewing AIGC generation task status
- Extract reusable GeneratingProgressPanel component
- Update task record cards to link to progress page for pending tasks
- Rework useTemplate flow to redirect to progress page post task creation
- Remove unused inline generating code and styles from useTemplate
- Adjust quick access menu item order
2026-07-15 11:24:28 +08:00
duanshuwen
d6c82204d4 Merge branch 'home3.0' of https://git.nianxx.cn/zoujing/YGChatCS into aigc 2026-07-14 22:09:53 +08:00
duanshuwen
9bdef279b7 feat(aigc): refine generation UI and add task status tracking
Add real-time task status polling for active generation jobs.
Overhaul GeneratingProgressPanel with dynamic step indicators, action buttons and updated styling.
Update PointInsufficientDialog to show detailed credit balance and usage summary.
Fix RecordCard media display and status logic for generating and completed tasks.
Restyle PhotoPickDrawer and update its instructional copy.
Add overflow styling for generating template content container.
2026-07-14 22:09:37 +08:00
2e56e20f06 feat: 消息轮播上下滚动 2026-07-14 11:28:57 +08:00
71e0d0003e feat; 先屏蔽三个组件 2026-07-14 11:18:40 +08:00
284becd6a8 feat: 调整了组件的样式 2026-07-14 11:15:49 +08:00
515e02f3af feat: 首页交互的 2026-07-14 10:09:26 +08:00
b3a15eee9b feat: 卡片数据调整对应 2026-07-14 09:17:49 +08:00
68ffab28bd feat: 头部调高4px 2026-07-14 09:17:18 +08:00
3c270525f7 Merge branch 'aigc' of https://git.nianxx.cn/zoujing/YGChatCS into home3.0 2026-07-14 08:55:06 +08:00
duanshuwen
1ebdf92159 refactor: remove unused CustomEmpty and related code
clean up dead code by removing all CustomEmpty component imports, template usages and the associated detailEmptyText state variable
2026-07-13 22:48:27 +08:00
duanshuwen
efe97452e0 feat(aigc): add task detail and image save flow
- Replace global AigcRecord store with task ID URL parameters instead of store state
- Integrate real task detail API to replace static mock result data
- Update ResultActions component with loading state, disabled styles, and native uni-app share support
- Add full image save flow with album permission checking and error handling
- Clean up unused files including the aigcRecord store and static result data
- Adjust RecordList padding and paging component text for better UX
2026-07-13 22:14:50 +08:00
7d0c784564 Merge branch 'aigc' of https://git.nianxx.cn/zoujing/YGChatCS into home3.0 2026-07-13 21:28:52 +08:00
duanshuwen
10638e0806 feat: add aigc record, video preview & custom recharge
- create useAigcRecordStore to centralize current AIGC generation record state
- add video media type support to ResultPreview component
- update RecordCard to only display view button for completed tasks
- implement custom recharge amount with input validation and 9999 max limit
- refactor detail page to load record from Pinia store instead of mock data
- clean up TemplateCarousel markup and remove unused badge styles
- fix minor formatting and code style issues
2026-07-13 21:25:17 +08:00
duanshuwen
b5952961fe feat: add mini-program privacy auth, update oss urls and refine photo guide
update oss static resource urls to oss.nianxx.cn
refactor privacy component to be reusable, add wechat mini-program privacy authorization check before image picking
add image urls to photo guide examples, refine photo guide ui styles and remove unused avatarSrc prop
2026-07-13 20:14:49 +08:00
duanshuwen
29bf6afe55 feat(recharge): add recharge package selection flow
- add new getRechargeOptions API endpoint in AigcApi
- replace CustomAmountCard with RechargePackageList component
- implement fetching and selection logic for recharge packages
- update UI to use correct recharge data fields
- add validation for selected recharge option
2026-07-13 10:27:03 +08:00
duanshuwen
cadddb5c3f feat(aigc): fully integrate backend API and replace mock data
- Replace all static mock data with real backend API calls for templates, generation tasks, credit balance and recharge
- Remove deprecated mock data files including templates.js, versionOptions.js, records.js and packages.js
- Add useCurrentCredit composable for fetching and managing user credit balance
- Update all components to align with new backend data shapes (e.g. templateItemId instead of id)
- Add loading and disabled states for interactive UI elements
- Implement full WeChat mini-program payment flow for credit recharge
- Fix template and record card UI styling and media handling
- Set developVersion flag to true for testing environment
2026-07-12 21:14:22 +08:00