diff --git a/src/utils/blessing.js b/src/utils/blessing.js new file mode 100644 index 0000000..145100f --- /dev/null +++ b/src/utils/blessing.js @@ -0,0 +1,25 @@ +/** + * 根据场景值获取场景名称 + * @param {string} scene - 场景值 + * @returns {string} - 场景名称 + */ +const sceneMap = { + card_generate: '祝福卡片', + fortune_draw: '抽签', + wallpaper_download: '壁纸', + avatar_download: '头像', + card_generate_index: '祝福卡片分享首页', + fortune_draw_index: '抽签分享首页', + wallpaper_download_index: '壁纸分享首页', + avatar_download_index: '头像分享首页', + index: '分享首页', + mine: '我的页面分享', +} + +export function getSceneName(scene) { + return sceneMap[scene] || scene +} + +export const getThumbUrl = (url) => { + return `${url}?imageView2/1/w/340/h/600/q/80` +} diff --git a/src/views/spring/user/saveRecord/index.vue b/src/views/spring/user/saveRecord/index.vue index ed0a056..a4bbb56 100644 --- a/src/views/spring/user/saveRecord/index.vue +++ b/src/views/spring/user/saveRecord/index.vue @@ -35,7 +35,7 @@ @@ -110,6 +110,7 @@