Browse Source

添加过度页

dev
corala 3 years ago
parent
commit
8245d58992
8 changed files with 135 additions and 5 deletions
  1. +1
    -0
      app.json
  2. +62
    -0
      pages/guodu/index.js
  3. +3
    -0
      pages/guodu/index.json
  4. +4
    -0
      pages/guodu/index.wxml
  5. +29
    -0
      pages/guodu/index.wxss
  6. +33
    -2
      pages/index/index.js
  7. +1
    -1
      pages/index/index.wxml
  8. +2
    -2
      pages/out/index.js

+ 1
- 0
app.json View File

@@ -1,6 +1,7 @@
{
"pages": [
"pages/index/index",
"pages/guodu/index",
"pages/middle/index",
"pages/login/index",
"pages/share/index",


+ 62
- 0
pages/guodu/index.js View File

@@ -0,0 +1,62 @@

Page({

/**
* 页面的初始数据
*/
data: {
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},

/**
* 生命周期函数--监听页面显示
*/
onShow: function () {

},

/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {

},

/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {

},

/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {

},

/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {

},

/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {

}
})

+ 3
- 0
pages/guodu/index.json View File

@@ -0,0 +1,3 @@
{
"usingComponents": {}
}

+ 4
- 0
pages/guodu/index.wxml View File

@@ -0,0 +1,4 @@
<view class="container">
<!-- <image class="progress" src="https://static.quhouse.com/6241c801d8f04e4a8ad2d82cb9b219a5.png"></image>
<view class="desc">活动游戏拼命加载中...</view> -->
</view>

+ 29
- 0
pages/guodu/index.wxss View File

@@ -0,0 +1,29 @@
.container{
width: 750rpx;
height: 1624rpx;
min-height: 100vh;
background: url('https://static.quhouse.com/dd537d22bd3042629743ccab7cb8b2a5.png') no-repeat #FFBE49;
background-size: cover;
display: flex;
flex-direction: column;
align-items: center;
position: relative;
}
.progress{
position: absolute;
top: 1000rpx;
width: 540rpx;
height: 60rpx;
margin-bottom: 18rpx;
}
.desc{
position: absolute;
top: 1070rpx;
height: 56rpx;
font-size: 40rpx;
font-family: PingFangSC-Semibold, PingFang SC;
font-weight: 600;
color: #FFFFFF;
line-height: 56rpx;
}

+ 33
- 2
pages/index/index.js View File

@@ -14,6 +14,37 @@ Page({
},1000)
}
},
panduanFun(){
let that = this
wx.request({
url: 'http://192.168.31.104:9998/ar/game/getOne',
// url: 'https://cktest.2weisou.com/meta/ar/game/getOne',
method: "get",
data: {},
header: {
Authorization: 'bearer '+ getApp().globalData.token
},
success(res) {
console.log(res)
if (res.data.code == 0) {
let data = res.data.data
if(data.miniType==0){
that.tabindex(data.linkUrl)
}else{
wx.navigateTo({
url: '/pages/guodu/index'
})
}
}else{
wx.showToast({
icon: 'none',
title: res.data.msg
})
return ;
}
}
})
},
inviteFun(id){
let token = wx.getStorageSync('token')
console.log(token)
@@ -37,7 +68,7 @@ Page({
}
})
},
tabindex() {
tabindex(url) {
let userInfo = getApp().globalData.userInfo
console.log(userInfo)
let id = 0
@@ -45,7 +76,7 @@ Page({
id = userInfo.id
}
wx.navigateTo({
url: '/pages/out/index?index=1&userid=' + id+ '&gameid=1&type=1'
url: '/pages/out/index?index=1&userid=' + id+ '&gameid=1&type=1&url='+url
})
},
tabsaoma() {


+ 1
- 1
pages/index/index.wxml View File

@@ -1,5 +1,5 @@
<!--index.wxml-->
<view class="container">
<view class="btn1" data-index="1" bindtap="tabindex"></view>
<view class="btn1" data-index="1" bindtap="panduanFun"></view>
<view class="btn2" data-index="2" bindtap="tabsaoma"></view>
</view>

+ 2
- 2
pages/out/index.js View File

@@ -10,7 +10,7 @@ Page({
userid: 0,// 用户ID
gameid: 0,// 游戏ID
type: 1,
allurl: "https://cktest.2weisou.com/dance/"
allurl: ""
},
/**
* 生命周期函数--监听页面加载
@@ -18,6 +18,7 @@ Page({
onLoad: function (options) {
console.log(options);
this.setData({
allurl: options.url||'https://cktest.2weisou.com/dance/',
web:options.web,
index:options.index,
userid: options.userid,
@@ -27,7 +28,6 @@ Page({
})
console.log(this.data.allurl)
},

/**
* 生命周期函数--监听页面初次渲染完成
*/


Loading…
Cancel
Save