Commit 499e424b authored by FE-安焕焕's avatar FE-安焕焕 👣

埋点和修复已知问题

parent f88d03e5
......@@ -9,7 +9,7 @@ const payTypeE = [
'PD_YXMMAEC_UserClickCashierSelectWechatPay'
];
const codeArr = ['4034', '4035', '4036', '3005', '6049', '401'];
const codeArr = ['4034', '4035', '4036', '3005'];
// (4034, "密码错误"),
// (4035, "密码重试超限,无法验证"),
// (4036, "验证码错误");
......
<template>
<div @click="changePayType(thirdPayInfo)">
<div class="groupCard">
<PayCardItem
:is-group-pay="true"
:value="creditPayInfo"
:coupon-info="couponInfo"
:show-coupon="showCoupon"
:risk-limit="riskLimit"
:coupon-disabled="couponDisabled"
/>
</div>
<div class="dashed">
<p class="dashed-line" />
<cr-checkbox
v-model="thirdPayInfo.isCheck"
shape="round"
checked-color="#EC1500"
:disabled="disabled || thirdPayInfo.disabled"
class="dashed-checkbox"
@click.native="changePayType(thirdPayInfo)"
/>
</div>
<div class="groupCard">
<PayCardItem :is-group-pay="true" :value="thirdPayInfo" />
<div>
<div @click="changePayType(thirdPayInfo)">
<div class="groupCard">
<PayCardItem
:is-group-pay="true"
:value="creditPayInfo"
:coupon-info="couponInfo"
:show-coupon="showCoupon"
:risk-limit="riskLimit"
:coupon-disabled="couponDisabled"
/>
</div>
<div class="dashed">
<p class="dashed-line" />
<cr-checkbox
v-model="thirdPayInfo.isCheck"
shape="round"
checked-color="#EC1500"
:disabled="disabled || thirdPayInfo.disabled"
class="dashed-checkbox"
@click.native="changePayType(thirdPayInfo)"
/>
</div>
<div class="groupCard">
<PayCardItem :is-group-pay="true" :value="thirdPayInfo" />
</div>
</div>
<p class="group-more b-t" @click="openMore">更多支付组合<cr-icon type="arrow" size="15px" /></p>
<cr-popup v-model="morePopup" round position="bottom" :style="{ height: '30%' }" closeable>
......
import cookies from '@/service/cookieStorage.service';
export const goUrlExtends = {
methods: {
goHome() {
goHome(payStatus) {
// 商城地址
if (payStatus) {
this.$track.registeredEvents('h5_RechargeResultPageClick', {
pay_status: payStatus,
buttons_name: '返回首页'
});
}
const returnUrl = this.getReturnUrl();
if (returnUrl) {
window.location.replace(`${returnUrl}`);
......@@ -10,7 +16,13 @@ export const goUrlExtends = {
}
this.$router.replace({ name: 'home' });
},
goOrderList() {
goOrderList(payStatus) {
if (payStatus) {
this.$track.registeredEvents('h5_RechargeResultPageClick', {
pay_status: payStatus,
buttons_name: '查看订单'
});
}
const returnUrl = this.getReturnUrl();
if (returnUrl) {
window.location.replace(`${returnUrl}/orderList`);
......
......@@ -81,7 +81,6 @@
:show-coupon="couponPopup"
:enable-list="payCouponList"
:value="selectedCoupon.id"
@click="selectCouponItem"
@change="handleSelectCoupon"
/>
</cr-popup>
......@@ -100,6 +99,7 @@ import localStorage from '@/service/localStorage.service';
import { throttle } from '@/service/utils.service';
import { goUrlExtends } from './extends';
import cookies from '@/service/cookieStorage.service';
import { getTokenFromNative } from '@/service/utils.service';
import {
codeArr,
payTypeE,
......@@ -223,6 +223,7 @@ export default {
// 先支付再查询信息
this.pay(this.payInfo?.paramsData, 'ocr', cookies.get('ocrflag'));
}
!this.$route?.query?.ocrflag && this.$track.registeredEvents('h5_CheckOutCouterExposure');
const vccToken = localStorage.get('vccToken');
Current_Url = `${window.location.origin}/payWaiting?vccToken=${vccToken}&orderNo=${this.orderNo}`;
this.queryPayInfo();
......@@ -311,7 +312,7 @@ export default {
this.creditPayInfo = displayInfo.creditPayInfo || {};
displayInfo.periodSeconds = displayInfo.periodSeconds * 1000;
this.getBtnStatus(this.isRiskLimit());
if (this.payInfo.payType) {
if (this.payInfo?.payType) {
this.selectedCoupon = this.payInfo.selectedCoupon;
this.changePayType(this.payInfo.payType, this.payInfo.mergePayPretreatmentInfo);
this.isShowProtocol && (this.isCheckAgreement = true);
......@@ -385,6 +386,12 @@ export default {
}
},
nextAction: throttle(function() {
this.$track.registeredEvents('h5_CheckOutCounterConfirmPayClick', {
order_id: this.orderNo,
pay_method: this.payType,
vcc_state: !IS_THIRD_PAY(this.payType) ? this.creditPayInfo?.accountStatus : '',
buttons_name: this.accountS.text
});
this.accountS.fn();
}, 1000),
/* 预支付 */
......@@ -492,7 +499,7 @@ export default {
payType: this.payType,
selectedCoupon: this.selectedCoupon,
isCheckAgreement: this.isCheckAgreement,
mergePayPretreatmentId: this.mergePayPretreatmentId
mergePayPretreatmentInfo: this.mergePayPretreatmentInfo
});
this.close();
this.goOcr();
......@@ -517,13 +524,17 @@ export default {
this.mergePayPretreatmentInfo = mergePayPretreatmentInfo || null;
},
openCouponModal() {
registeredEvents('PD_YXMMACP_UserClickCouponBanner');
this.random = Math.random();
this.couponPopup = true;
this.$track.registeredEvents('h5_CheckOutCouterCouponBannerClick');
},
/* 选取优惠券 */
handleSelectCoupon(id, selectedCoupon) {
registeredEvents('PD_YXMMACP_UserClickCouponPopupWindowComfirmBtn');
this.$track.registeredEvents('h5_CheckOutCounterCouponPopupWindowClick', {
coupon_type: '享花券',
check_or_not: id ? '勾选' : '取消',
coupon_id: id
});
this.selectedCoupon = selectedCoupon || {};
this.getBtnStatus(this.isRiskLimit());
this.couponPopup = false;
......@@ -573,12 +584,6 @@ export default {
if (!res.callBackUrl) return;
window.location.href = res.callBackUrl;
},
selectCouponItem(isSelected, couponInfo) {
registeredEvents('PD_YXMMACP_UserClickCouponPopupWindowCoupon', {
check_or_not: isSelected ? '勾选' : '取消',
coupon_id: couponInfo.id
});
},
/* 密码支付失败 */
retrieve() {
this.$refs.pwd.tips(false, this.error);
......
......@@ -18,10 +18,17 @@
您可在“我的-我的订单”中查看详情
</p>
<div class="actions">
<cr-button shape="circle" class="actions__back" :plain="true" type="primary" @click="goHome"
<cr-button
shape="circle"
class="actions__back"
:plain="true"
type="primary"
@click="goHome(payStatus)"
>返回首页</cr-button
>
<cr-button shape="circle" type="primary" @click="goOrderList">查看订单</cr-button>
<cr-button shape="circle" type="primary" @click="goOrderList(payStatus)"
>查看订单</cr-button
>
</div>
</div>
<div v-else class="card">
......@@ -45,7 +52,6 @@
</div>
</template>
<script>
import { registeredEvents } from '@/service/sa.service';
import RecoGoods from '@/components/RecoGoods.vue';
import cookies from '@/service/cookieStorage.service';
import { goUrlExtends } from './extends';
......@@ -57,7 +63,8 @@ export default {
money: '00.00',
orderNo: null,
isSuccess: false,
freeAmount: 0
freeAmount: 0,
payStatus: ''
};
},
created() {
......@@ -69,11 +76,16 @@ export default {
this.reason = reason || '';
this.isSuccess = success || false;
this.freeAmount = amount.freeAmount;
this.payStatus = success ? '订单支付成功' : '订单支付失败';
this.$track.registeredEvents('h5_RechargeResultPageExposure', {
pay_status: this.payStatus
});
},
methods: {
goPay() {
registeredEvents('PD_YXMMAEC_UserClickCashierPaymentAgainBtn', {
order_id: this.orderNo
this.$track.registeredEvents('h5_RechargeResultPageClick', {
pay_status: this.payStatus,
buttons_name: '重新支付'
});
this.$router.replace({ name: 'pay', query: { orderNo: this.orderNo } });
}
......
......@@ -15,10 +15,17 @@
努力返回支付结果中,请留心查看!
</p>
<div class="actions">
<cr-button class="actions__back" :plain="true" type="primary" shape="circle" @click="goHome"
<cr-button
class="actions__back"
:plain="true"
type="primary"
shape="circle"
@click="goHome('正在支付')"
>返回首页</cr-button
>
<cr-button shape="circle" type="primary" @click="goOrderDetail">查看订单</cr-button>
<cr-button shape="circle" type="primary" @click="goOrderDetail('正在支付')"
>查看订单</cr-button
>
</div>
</div>
</template>
......@@ -47,12 +54,19 @@ export default {
}
},
mounted() {
this.$track.registeredEvents('h5_RechargeResultPageExposure', {
pay_status: '正在支付'
});
this.$dialog({
message: '请确认订单已完成支付',
confirmButtonText: '已完成支付',
cancelButtonText: '重新支付',
confirmButtonColor: '#EC1500',
onCancel: () => {
this.$track.registeredEvents('h5_RechargeResultPageClick', {
pay_status: '正在支付',
buttons_name: '重新支付'
});
this.goPay();
},
onConfirm: () => {
......
......@@ -6,7 +6,7 @@
:key="index"
class="Vl__sku-item"
:class="{
cheap: item.price - item.salePrice > 0,
cheap: item.price - item.salePrice < 0,
active: props.info.skuNo === item.skuNo,
'no-stock': !item.hasStock,
nohhird: (index + 1) % 3 !== 0
......
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