share update
This commit is contained in:
@@ -29,7 +29,7 @@
|
||||
import { ref, computed } from "vue"
|
||||
import { globalStore } from "@/globalstore";
|
||||
import ModalTransition from "./ModalTransition.vue"
|
||||
import { Storage, generateQR, isWeixin, isMiniPage } from "../libs/utils"
|
||||
import { Storage, generateQR, isWeixin, isMiniPage, Request } from "../libs/utils"
|
||||
import Haibao from "@/libs/haibao"
|
||||
import bg from "../assets/images/haibao-bg.webp"
|
||||
import mask from "../assets/images/haibao-mask.webp"
|
||||
@@ -122,10 +122,6 @@ const openQiwei = (e) => {
|
||||
|
||||
const openHaibao = async (e) => {
|
||||
const target = e.currentTarget
|
||||
// TODO 首页分享增加一次合成次数
|
||||
if (!globalStore.first_share_today) {
|
||||
await Request('face/share', { mergeId: mergeId })
|
||||
}
|
||||
if (target.classList.contains("has")) {
|
||||
return
|
||||
}
|
||||
@@ -147,6 +143,11 @@ const openHaibao = async (e) => {
|
||||
globalStore.result_url = foundItem.result_url;
|
||||
mergeId = foundItem.id;
|
||||
haibaoShow.value = true
|
||||
|
||||
if (!globalStore.first_share_today) {
|
||||
Request(`face/share/${mergeId}`)
|
||||
}
|
||||
|
||||
handleHaibao()
|
||||
} else {
|
||||
return weui.alert("请先参与活动合成图片并打榜!")
|
||||
|
||||
Reference in New Issue
Block a user