diff --git a/pages.json b/pages.json
index 1eba65b..5f52036 100644
--- a/pages.json
+++ b/pages.json
@@ -26,6 +26,14 @@
"navigationStyle": "custom"
}
},
+ {
+ "path": "pages/avatar/index",
+ "style": {
+ "navigationBarTitleText": "新春头像挂饰",
+ "enablePullDownRefresh": false,
+ "navigationStyle": "custom"
+ }
+ },
{
"path": "pages/detail/index",
"style": {
@@ -33,6 +41,14 @@
"enablePullDownRefresh": false,
"navigationStyle": "custom"
}
+ },
+ {
+ "path": "pages/fortune/index",
+ "style": {
+ "navigationBarTitleText": "新年运势",
+ "enablePullDownRefresh": false,
+ "navigationStyle": "custom"
+ }
}
],
"globalStyle": {
diff --git a/pages/avatar/index.vue b/pages/avatar/index.vue
new file mode 100644
index 0000000..dc4d91b
--- /dev/null
+++ b/pages/avatar/index.vue
@@ -0,0 +1,378 @@
+
+
+
+ ‹
+ 新春头像挂饰
+
+
+
+
+
+
+
+ 实时预览效果
+
+
+
+
+
+
+
+
+
+
+
+
+ ✔
+
+
+
+
+
+
+ 头像框
+ 挂饰配件
+
+
+
+
+
+ ✔
+
+
+
+
+
+
+ ✔
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/pages/fortune/index.vue b/pages/fortune/index.vue
new file mode 100644
index 0000000..51ac7b9
--- /dev/null
+++ b/pages/fortune/index.vue
@@ -0,0 +1,529 @@
+
+
+
+
+ ‹
+ 2026 新年运势
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 祈福
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ☀
+
+ {{ currentFortune.title }}
+
+ {{ currentFortune.desc }}
+ 旧岁千般皆如意,新年万事定称心。
+
+
+
+
+
+ ● 每日仅限一次抽取
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/pages/index/index.vue b/pages/index/index.vue
index c0a9156..ebe6b98 100644
--- a/pages/index/index.vue
+++ b/pages/index/index.vue
@@ -95,7 +95,7 @@ const features = ref([
type: "video",
},
{
- title: "新春头像挂饰",
+ title: "新春头像",
subtitle: "焕上节日新饰",
icon: "/static/icon/guashi.png",
type: "avatar_decor",
@@ -104,7 +104,7 @@ const features = ref([
title: "新年运势",
subtitle: "抽取新年关键词",
icon: "/static/icon/yunshi.png",
- type: "avatar_frame",
+ type: "fortune",
},
]);
@@ -140,8 +140,19 @@ const popularCards = ref([
]);
const onFeatureTap = (item) => {
+ if (item.type === "avatar_decor" || item.type === "avatar_frame") {
+ uni.navigateTo({ url: "/pages/avatar/index" });
+ return;
+ }
+ if (item.type === "fortune") {
+ uni.navigateTo({ url: "/pages/fortune/index" });
+ return;
+ }
+ if (item.type === "card") {
+ uni.navigateTo({ url: "/pages/make/index" });
+ return;
+ }
uni.showToast({ title: `进入:${item.title}`, icon: "none" });
- // uni.navigateTo({ url: `/pages/${item.type}/index` })
};
const previewCard = (card) => {
diff --git a/pages/make/index.vue b/pages/make/index.vue
index 9b5d83a..6db9211 100644
--- a/pages/make/index.vue
+++ b/pages/make/index.vue
@@ -215,8 +215,8 @@ const greetingLib = [
];
onLoad((options) => {
- // cardId.value = "69674f307307beac4519025f";
- createCard();
+ cardId.value = "69674f307307beac4519025f";
+ // createCard();
});
const createCard = async () => {
@@ -321,27 +321,27 @@ const preview = () => {
};
const shareOrSave = async () => {
- const tempPath = await saveByCanvas(false);
- const fileKeyRes = await uni.uploadFile({
- url: "https://api.ai-meng.com/api/common/upload",
- filePath: tempPath,
- name: "file", // 和后端接收文件字段名一致
- header: {
- "x-app-id": "69665538a49b8ae3be50fe5d",
- },
- });
- if (fileKeyRes.statusCode < 400) {
- const keyJson = JSON.parse(fileKeyRes.data);
- const url = `https://file.lihailezzc.com/${keyJson?.data.key}`;
- // const url =
- // "https://file.lihailezzc.com/resource/99c9f7e0086ed66d20bd1675b4ab22e9.png";
- updateCard({
- id: cardId.value,
- imageUrl: url,
- status: 1,
- });
- }
- createCard();
+ // const tempPath = await saveByCanvas(false);
+ // const fileKeyRes = await uni.uploadFile({
+ // url: "https://api.ai-meng.com/api/common/upload",
+ // filePath: tempPath,
+ // name: "file", // 和后端接收文件字段名一致
+ // header: {
+ // "x-app-id": "69665538a49b8ae3be50fe5d",
+ // },
+ // });
+ // if (fileKeyRes.statusCode < 400) {
+ // const keyJson = JSON.parse(fileKeyRes.data);
+ // const url = `https://file.lihailezzc.com/${keyJson?.data.key}`;
+ // // const url =
+ // // "https://file.lihailezzc.com/resource/99c9f7e0086ed66d20bd1675b4ab22e9.png";
+ // updateCard({
+ // id: cardId.value,
+ // imageUrl: url,
+ // status: 1,
+ // });
+ // }
+ // createCard();
// uni.showToast({ title: '已保存到相册并可分享', icon: 'none' })
};
diff --git a/static/music/shake.mp3 b/static/music/shake.mp3
new file mode 100644
index 0000000..baebf09
Binary files /dev/null and b/static/music/shake.mp3 differ