|
|
@@ -11,18 +11,6 @@
|
|
|
<!-- 任务 #6996 -->
|
|
|
<Banner :data-list="topBanners" :height="290" />
|
|
|
<div class="home-main__container">
|
|
|
-
|
|
|
-
|
|
|
- <button type="button" style="border: 1px solid #000; padding: 20px; background-color: #fff;"
|
|
|
- @click="trackEvent">initSDK Test</button>
|
|
|
-
|
|
|
- <button type="button" style="border: 1px solid #000; padding: 20px; background-color: #fff;"
|
|
|
- @click="registrationEvent">registration Test</button>
|
|
|
-
|
|
|
- <button type="button" style="border: 1px solid #000; padding: 20px; background-color: #fff;"
|
|
|
- @click="purchaseEvent">purchase Test</button>
|
|
|
-
|
|
|
-
|
|
|
<app-block class="home-main__notice">
|
|
|
<h4 @click="$router.push({ name: 'notice-list' })">
|
|
|
<span>{{ $t('routes.notice') }}</span>
|
|
|
@@ -73,76 +61,6 @@ import Banner from '@mobile/components/base/banner/index.vue'
|
|
|
import plus from '@/utils/h5plus'
|
|
|
import ProductList from '../../product/list/components/waterfall-list/index.vue'
|
|
|
|
|
|
-
|
|
|
-
|
|
|
-const trackEvent = () => {
|
|
|
- plus.onPlusReady(() => {
|
|
|
-
|
|
|
- const startSDKsuccess = (args: unknown) => {
|
|
|
- window.alert('成功:' + JSON.stringify(args))
|
|
|
- }
|
|
|
-
|
|
|
-
|
|
|
- const success = (args: unknown) => {
|
|
|
-
|
|
|
- window.plus.bridge.exec('AppsFlyerExpand', 'startSDK', [startSDKcallbackID])
|
|
|
-
|
|
|
- }
|
|
|
-
|
|
|
- const fail = (code: unknown) => {
|
|
|
- window.alert('失败:' + JSON.stringify(code))
|
|
|
- }
|
|
|
-
|
|
|
- const callbackID = window.plus.bridge.callbackId(success, fail)
|
|
|
-
|
|
|
-
|
|
|
- const startSDKcallbackID = window.plus.bridge.callbackId(startSDKsuccess, fail)
|
|
|
-
|
|
|
- window.plus.bridge.exec('AppsFlyerExpand', 'initSDK', [callbackID, '123', false])
|
|
|
- })
|
|
|
-}
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-const registrationEvent = () => {
|
|
|
- plus.onPlusReady(() => {
|
|
|
-
|
|
|
- const success = (args: unknown) => {
|
|
|
- window.alert('成功:' + JSON.stringify(args))
|
|
|
- }
|
|
|
-
|
|
|
- const fail = (code: unknown) => {
|
|
|
- window.alert('失败:' + JSON.stringify(code))
|
|
|
- }
|
|
|
-
|
|
|
- const callbackID = window.plus.bridge.callbackId(success, fail)
|
|
|
-
|
|
|
- window.plus.bridge.exec('AppsFlyerExpand', 'logEvent', [callbackID, 'af_complete_registration', JSON.stringify({ af_registration_method: "Mobile" })])
|
|
|
- })
|
|
|
-}
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-const purchaseEvent = () => {
|
|
|
- plus.onPlusReady(() => {
|
|
|
-
|
|
|
- const success = (args: unknown) => {
|
|
|
- window.alert('成功:' + JSON.stringify(args))
|
|
|
- }
|
|
|
-
|
|
|
- const fail = (code: unknown) => {
|
|
|
- window.alert('失败:' + JSON.stringify(code))
|
|
|
- }
|
|
|
-
|
|
|
- const callbackID = window.plus.bridge.callbackId(success, fail)
|
|
|
-
|
|
|
- window.plus.bridge.exec('AppsFlyerExpand', 'logEvent', [callbackID, 'af_purchase', JSON.stringify({ af_revenue: 9.99, af_currency: "USD" })])
|
|
|
- })
|
|
|
-}
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
const noticeStore = useNoticeStore()
|
|
|
const goodsCollectionStore = useGoodsCollectionStore()
|
|
|
|