Commit 76ad7180 authored by wildfirecode13's avatar wildfirecode13

u

parent 484c1133
......@@ -67,8 +67,8 @@
</script>
<!-- 构建的js -->
<!-- <script src="output.js" crossorigin="anonymous"></script> -->
<script src="https://yun.duiba.com.cn/db_games/activity/template/1628580191/output.js" crossorigin="anonymous"></script>
<script src="output.js" crossorigin="anonymous"></script>
<!-- <script src="https://yun.duiba.com.cn/db_games/activity/template/1628580191/output.js" crossorigin="anonymous"></script> -->
......
......@@ -2,5 +2,5 @@
"code": null,
"data": "1234567890123",
"message": 123,
"success": 0
"success": 1
}
\ No newline at end of file
{
"code": null,
"data": 1,
"data": 0,
"message": null,
"success": true
}
\ No newline at end of file
......@@ -912,5 +912,5 @@ export const ResJson = {
"name": "svga"
}
],
"path": "https://yun.duiba.com.cn/db_games/activity/template/1628578111/resource/"
"path": "https://yun.duiba.com.cn/db_games/activity/template/1628580956/resource/"
}
\ No newline at end of file
export default (queryParams)=>{
const base = 'http://0.0.0.0:8080/?';
export const getShareUrl = (queryParams) => {
let str = '';
for (const key in queryParams) {
str +=`${key}=${queryParams[key]}&`
str += `${key}=${queryParams[key]}&`
}
const url = `http://0.0.0.0:8080/?${str}`;
const url = `${base}${str}`;
return url;
}
export const getAutoPrizeUrl = () => {
return getShareUrl({autoPrize:1})
}
\ No newline at end of file
......@@ -2,8 +2,12 @@ import { RES } from "../../module/RES";
import { Panel } from "../../module/views/Panel";
import centerTextField from "../common/centerTextField";
import getObject from "../common/getObject";
import { getAutoPrizeUrl } from "../getShareUrl";
export class AssistPanel extends Panel {
onClick_share_go(){
location.href=getAutoPrizeUrl()
}
initUi() {
super.initUi();
var skin = RES.getSkinDataByName(this.skinName);
......@@ -30,4 +34,16 @@ export class AssistPanel extends Panel {
prize_tips1.x = prize_tips2.x + prize_tips2.textWidth;
centerTextField(getObject(this,'assist_tips2'),595)
}
initEvents() {
super.initEvents();
getObject(this, 'assist_btn').addEventListener(FYGE.MouseEvent.CLICK, this.onClick_share_go, this);
}
removeEvents() {
super.removeEvents();
getObject(this, 'assist_btn').removeEventListener(FYGE.MouseEvent.CLICK, this.onClick_share_go, this);
}
}
\ No newline at end of file
......@@ -4,6 +4,7 @@ import centerTextField from "../common/centerTextField";
import getObject from "../common/getObject";
import getQueryParams from "../common/getQueryParams";
import Marquee from "../common/Marquee";
import { getAutoPrizeUrl } from "../getShareUrl";
import { AssistPanel } from "../panels/assist";
import { RulePanel } from "../panels/rule";
import { getPxTokenSave, sendWebNet, WebNetName } from "../WebNet";
......@@ -24,6 +25,9 @@ export class ShareScene extends Scene {
onClick_share_rule() {
showPanel(RulePanel);
}
onClick_share_go() {
location.href = getAutoPrizeUrl();
}
async start(data) {
......@@ -69,11 +73,13 @@ export class ShareScene extends Scene {
getObject(this, 'share_rule').addEventListener(FYGE.MouseEvent.CLICK, this.onClick_share_rule, this);
getObject(this, 'share_assist').addEventListener(FYGE.MouseEvent.CLICK, this.onClick_share_assist, this);
getObject(this, 'share_go').addEventListener(FYGE.MouseEvent.CLICK, this.onClick_share_go, this);
}
removeEvents() {
super.removeEvents();
getObject(this, 'share_rule').removeEventListener(FYGE.MouseEvent.CLICK, this.onClick_share_rule, this);
getObject(this, 'share_assist').removeEventListener(FYGE.MouseEvent.CLICK, this.onClick_share_assist, this);
getObject(this, 'share_go').removeEventListener(FYGE.MouseEvent.CLICK, this.onClick_share_go, this);
}
get groupNames() { return ["share"] }
......
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