Commit b0ecc611 authored by wildfirecode's avatar wildfirecode

1

parent 6679aa8b
......@@ -51,9 +51,8 @@
<script src="libs/downloadApp.js"></script>
<script src="http://yun.duiba.com.cn/db_games/svga.egret.min.new.js"></script>
<script>
// window['pageID'] = 'TeamShareScene';
window['pageID'] = 'JoinShareScene';
// window['pageID'] = 'Share2Scene';
window['pageID'] = 'TeamShareScene';
// window['pageID'] = 'JoinShareScene';
// window['pageID'] = 'TransScene';
window['TransLink']='';
window['projectId'] = "1";
......
......@@ -7,7 +7,7 @@ export interface IExposureData {
activityUseType?: string;
advertId?: number;
appId: number;
consumerId: number;
// consumerId: number;
dom?:string;
dcm: string;
domain: string;
......
......@@ -4,7 +4,7 @@ import { IExposureData } from '../data/common/IExposureData';
export class Buried {
private static appId: number;
private static consumerId: number;
// private static consumerId: number;
private static oaId: number;
/**
......@@ -13,23 +13,23 @@ export class Buried {
public static init(): void {
if (DataManager.ins.gameCfgData) {
this.appId = DataManager.ins.gameCfgData.appInfo.appId;
this.consumerId = DataManager.ins.getInfoData.consumerId;
// this.consumerId = DataManager.ins.getInfoData.consumerId;
this.oaId = DataManager.ins.gameCfgData.gameInfo.oaId;
} else if (DataManager.ins.customCfgData) {
this.appId = DataManager.ins.customCfgData.appId;
this.consumerId = DataManager.ins.customCfgData.consumerId;
// this.consumerId = DataManager.ins.customCfgData.consumerId;
this.oaId = DataManager.ins.customCfgData.oaId;
} else if (DataManager.ins.petIndexData && DataManager.ins.petIndexData.appId && DataManager.ins.petIndexData.activityId) {
this.appId = DataManager.ins.petIndexData.appId;
this.consumerId = DataManager.ins.petIndexData.consumerId;
// this.consumerId = DataManager.ins.petIndexData.consumerId;
this.oaId = DataManager.ins.petIndexData.activityId;
} else if (DataManager.ins.petsIndexData && DataManager.ins.petsIndexData.appId && DataManager.ins.petsIndexData.activityId) {
this.appId = DataManager.ins.petsIndexData.appId;
this.consumerId = DataManager.ins.petsIndexData.consumerId;
// this.consumerId = DataManager.ins.petsIndexData.consumerId;
this.oaId = DataManager.ins.petsIndexData.activityId;
} else {
this.appId = window["appId"];
this.consumerId = window["consumerId"];
// this.consumerId = window["consumerId"];
this.oaId = window["projectId"];
}
}
......@@ -41,15 +41,18 @@ export class Buried {
* @param {string} embedDomain 埋点域名
* @returns {{dpm: string; consumerId: number; domain: string; appId: number}}
*/
public static createExposure(dpm: string, dcm: string, dom: string, embedDomain = '//embedlog.duiba.com.cn'): IExposureData {
public static createExposure(dpm: string, dcm: string, dom?: string, embedDomain = '//embedlog.duiba.com.cn'): IExposureData {
const exposure: IExposureData = {
dpm: dpm,
dcm: dcm,
dom: dom,
consumerId: Buried.consumerId,
// consumerId: Buried.consumerId,
appId: Buried.appId,
domain: embedDomain
};
if (dom)
exposure.dom = dom;
return exposure;
}
......
......@@ -171,6 +171,7 @@ class Main extends MainBase {
// return;
if (window['pageID']) {
Buried.init();
// if (GameConst.getQueryString("InviteSource")) {
yzwNet.homeBaseInfo((s) => {
if (!s) {
......@@ -188,12 +189,6 @@ class Main extends MainBase {
if (window['pageID'] == 'TeamShareScene') {
SceneCtrl.instance.change(ModuleTypes.TeamShareScene);
}
if (window['pageID'] == 'Share2Scene') {
SceneCtrl.instance.change(ModuleTypes.Share2Scene);
}
if (window['pageID'] == 'TeamShareScene') {
SceneCtrl.instance.change(ModuleTypes.TeamShareScene);
}
if (window['pageID'] == 'TransScene') {
SceneCtrl.instance.change(ModuleTypes.TransScene);
}
......
......@@ -3,6 +3,7 @@ import ToastCtrl from "../ctrls/toastCtrl";
import GameConst from "../GameConst";
import { yzwNet } from "../NetConst";
import Panel from "../views/Panel";
import { Buried } from "../../libs/tw/util/Buried";
export default class ConfirmPanel extends Panel {
......@@ -40,4 +41,11 @@ export default class ConfirmPanel extends Panel {
},
window['projectId'], GameConst.getQueryString("joinTeamCode"));
}
}
export const getlogItem = (i) => {
const Dpm = Buried.connectDpm(110, i, 1); // 点击埋点
const Dcm = Buried.connectDcm(202, 0, 0); // 曝光埋点
return Buried.createExposure(Dpm, Dcm);
}
\ No newline at end of file
import iswx from "../iswx";
import Scene from "../views/Scene";
import GameConst from "../GameConst";
import { NetManager } from "../../libs/tw/manager/NetManager";
import { getlogItem } from "./ConfirmPanel";
export default class JoinShareScene extends Scene {
protected get skinKey() { return 'JoinShare' }
......@@ -11,6 +13,7 @@ export default class JoinShareScene extends Scene {
}
initUI(data) {
NetManager.ins.showLog(getlogItem(5));
// this['from'].text = '11111111';
// this['to'].text = '22222222';
}
......
import Scene from "../views/Scene";
import PanelCtrl from "../ctrls/panelCtrl";
import { ModuleTypes } from "../types/sceneTypes";
import { NetManager } from "../../libs/tw/manager/NetManager";
import { getlogItem } from "./ConfirmPanel";
import GameConst from "../GameConst";
export default class TeamShareScene extends Scene{
protected get skinKey(){return 'TeamShare'}
......@@ -9,12 +12,13 @@ export default class TeamShareScene extends Scene{
constructor(data){
super();
this.initUI(data);
NetManager.ins.showLog(getlogItem(6));
}
initUI(data){
initUI(data){
this['avatar'].mask = this['avatarMask'];
this['avatar'].source = 'http://yun.duiba.com.cn/db_games/activity/game/guideImage/guide2.png';
this['avatar'].source = GameConst.getQueryString('avatar');
}
......
......@@ -9,6 +9,7 @@ import SceneCtrl from "../ctrls/sceneCtrl";
import { ModuleTypes } from "../types/sceneTypes";
import PanelCtrl from "../ctrls/panelCtrl";
import iswx from "../iswx";
import { getlogItem } from "./ConfirmPanel";
export default class TransScene extends Scene {
_bg: SVGA.EgretMovieClip;
......@@ -23,6 +24,12 @@ export default class TransScene extends Scene {
}
async initUI(data) {
if (iswx()) {
NetManager.ins.showLog(getlogItem(9));
}else {
NetManager.ins.showLog(getlogItem(8));
}
this.once(egret.Event.ADDED_TO_STAGE, () => {
this.height = this.stage.stageHeight;
}, this);
......
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