Commit 2986933c authored by 王炽's avatar 王炽

66666

parent 8ea0ef83
......@@ -168,6 +168,7 @@
import { ref, onMounted, computed, watch, nextTick } from 'vue';
import { useIntegralStore } from '../stores/integral';
import { throttleTap } from '../utils/index';
import md from '../md';
// Props
const props = defineProps({
......@@ -357,6 +358,15 @@ const shouldShowSection = computed(() => {
// sessionsLength: creditsSaleData.value?.sessions?.length || 0,
// creditsSaleData: creditsSaleData.value
// });
if(hasSessions) {
md.sensorComponentLogTake({
xcxComponentExposure: "true",
pageName: "积分服务页",
componentName: "积分限时购",
componentContent: "积分限时购"
});
}
return hasSessions;
});
......@@ -657,6 +667,13 @@ const mapSeckillDataToCreditsSale = (seckillData) => {
// 处理积分抢购点击事件
const handleCreditsSaleClick = (good) => {
console.log('点击抢购商品:', good);
md.sensorComponentLogTake({
xcxComponentClick: "true",
pageName: "积分服务页",
componentName: "积分限时购",
componentContent: good.name
});
// 获取当前活动ID和场次Key
const activityId = creditsSaleData.value.activityId;
const sessionKey = creditsSaleData.value.sessions[currentSessionIndex.value]?.sessionKey;
......
......@@ -41,9 +41,9 @@
</template>
<script setup>
import { defineProps, defineEmits } from 'vue';
import { defineProps, defineEmits, watch } from 'vue';
import { jump, JumpType } from '../../utils';
import md from '../../md.js';
// Props 定义
const props = defineProps({
visible: {
......@@ -75,6 +75,20 @@ const props = defineProps({
// Emits 定义
const emit = defineEmits(['close', 'record', 'prize']);
// 监听 visible 值的变化
watch(() => props.visible, (newVal, oldVal) => {
console.log('InvitePrizePanel visible 值变化:', { newVal, oldVal });
// 当 visible 变为 true 时执行埋点
if (newVal) {
md.sensorPopLogTake({
xcxPopExposure: "true",
toolName: "邀请组件",
popName: "邀请成功弹窗"
});
}
});
// 关闭弹窗
const handleClose = () => {
emit('close');
......@@ -82,6 +96,13 @@ const handleClose = () => {
// 查看邀请记录按钮点击事件
const handleRecordClick = () => {
md.sensorPopLogTake({
xcxPopClick: "true",
toolName: "邀请组件",
popName: "邀请成功弹窗",
buttonName: "查看邀请明细"
});
jump({
type: 1,
url: '/pages/invate/invaterecords'
......@@ -92,6 +113,13 @@ const handleRecordClick = () => {
// 查看奖品按钮点击事件
const handlePrizeClick = () => {
md.sensorPopLogTake({
xcxPopClick: "true",
toolName: "邀请组件",
popName: "邀请成功弹窗",
buttonName: "查看奖品"
});
console.log('查看奖品按钮点击');
if(props.prizeType === 'credits') {
const urlStr = 'https://mom.feihe.com/member/mine/newPointDetail?crmId={crmid}&appCode=XMH';
......
......@@ -30,7 +30,8 @@
</template>
<script setup>
import { defineProps, defineEmits, ref } from 'vue';
import { defineProps, defineEmits, ref, watch } from 'vue';
import md from '../../md';
// Props 定义
const props = defineProps({
......@@ -54,6 +55,18 @@ const emit = defineEmits(['close', 'accept']);
// 是否正在播放动画
const isAnimating = ref(false);
// 监听 visible 值的变化
watch(() => props.visible, (newVal) => {
if (newVal) {
console.log('埋点');
md.sensorPopLogTake({
xcxPopExposure: "true",
toolName: "做任务赚积分",
popName: "任务完成弹窗"
});
}
});
// 关闭弹窗
const handleClose = () => {
emit('close');
......
......@@ -44,6 +44,7 @@
<script setup>
import { defineProps, defineEmits, ref, onMounted, watch } from 'vue';
import { useIntegralStore } from '../../stores/integral';
import md from '../../md.js';
// Props 定义
const props = defineProps({
......@@ -57,6 +58,17 @@ const props = defineProps({
}
});
onMounted(() => {
props.taskTodo.forEach(item => {
md.sensorComponentLogTake({
xcxComponentExposure: "true",
pageName: "任务面板页",
componentName: "做任务赚积分",
componentContent: item.taskTodoExtra?.title
});
});
});
// Emits 定义
const emit = defineEmits(['close', 'taskClick']);
......@@ -98,6 +110,13 @@ const handleClose = () => {
// 任务点击事件
const handleTaskClick = (task, index) => {
md.sensorComponentLogTake({
xcxComponentClick: "true",
pageName: "任务面板页",
componentName: "做任务赚积分",
componentContent: task.taskTodoExtra?.title
});
if (task?.taskTodoExtra?.status === '3') {
// 已完成的任务不触发跳转
console.log('任务已完成:', task?.taskTodoExtra?.title);
......
......@@ -24,6 +24,7 @@
import { ref, onMounted } from 'vue';
import { useIntegralStore } from '@/stores/integral';
import { showLoading, hideLoading } from '@/utils';
import md from '../../md';
const integralStore = useIntegralStore();
const records = ref([]);
......@@ -66,6 +67,13 @@ const formatTimestamp = (timestamp) => {
};
onMounted(async () => {
md.sensorComponentLogTake({
xcxComponentExposure: "true",
pageName: "邀请记录页",
componentName: "邀请记录",
componentContent: "邀请记录"
});
showLoading('加载中...');
try {
await integralStore.getInvitationList();
......
......@@ -55,6 +55,7 @@ import { jump, JumpType, showLoading, hideLoading } from '../../utils';
import { useGlobalStore } from '@/stores/global';
import { useUserStore } from '@/stores/user';
import { useIntegralStore } from '@/stores/integral';
import md from '../../md';
// 分享登录弹窗状态
const showSharePopLogin = ref(false);
......@@ -111,6 +112,12 @@ const initInviteParams = () => {
};
onMounted(async() => {
md.sensorComponentLogTake({
xcxComponentExposure: "true",
pageName: "新人福利页",
componentName: "新人福利页",
componentContent: "立即领取"
});
showLoading();
// 先进行自动登录获取基础信息,登录成功后执行页面初始化
......@@ -322,6 +329,13 @@ const handleViewBenefits = () => {
// 一键领取按钮点击事件
const handleClaim = () => {
md.sensorComponentLogTake({
xcxComponentClick: "true",
pageName: "新人福利页",
componentName: "新人福利页",
componentContent: "立即领取"
});
if(!isLogin.value) {
showPhone.value = true;
return;
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment