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
This commit is contained in:
duanshuwen
2026-07-13 22:14:50 +08:00
parent 10638e0806
commit efe97452e0
9 changed files with 239 additions and 107 deletions

View File

@@ -1,12 +1,28 @@
<template>
<view class="result-actions">
<view class="result-action is-primary" @tap="emit('save')">保存图片</view>
<view class="result-action is-secondary" @tap="emit('share')">分享好友</view>
<view :class="['result-action', 'is-primary', { 'is-disabled': saving }]" @tap="handleSave">
{{ saving ? "保存中..." : "保存图片" }}
</view>
<button class="result-action is-secondary" open-type="share" hover-class="none">分享好友</button>
</view>
</template>
<script setup>
const emit = defineEmits(["save", "share"]);
const props = defineProps({
saving: {
type: Boolean,
default: false,
},
});
const emit = defineEmits(["save"]);
const handleSave = () => {
if (!props.saving) {
emit("save");
}
};
</script>
<style scoped lang="scss">