Commit ca5eb1f0 authored by 石盼盼's avatar 石盼盼

登录页面,暂无数据修改

parent dc2b673f
...@@ -40,7 +40,7 @@ App({ ...@@ -40,7 +40,7 @@ App({
}, },
getVision() { getVision() {
const accountInfo = wx.getAccountInfoSync(); const accountInfo = wx.getAccountInfoSync();
console.log(accountInfo) // console.log(accountInfo)
if (accountInfo.miniProgram.envVersion == 'develop') { // 开发板 if (accountInfo.miniProgram.envVersion == 'develop') { // 开发板
this.globalData.globalUrl = 'https://tianzehr.xueyoubangedu.com' this.globalData.globalUrl = 'https://tianzehr.xueyoubangedu.com'
} else if (accountInfo.miniProgram.envVersion == 'trial') { // 体验版 } else if (accountInfo.miniProgram.envVersion == 'trial') { // 体验版
...@@ -50,7 +50,7 @@ App({ ...@@ -50,7 +50,7 @@ App({
} else { } else {
this.globalData.globalUrl = 'https://tianzehr.xueyoubangedu.com' this.globalData.globalUrl = 'https://tianzehr.xueyoubangedu.com'
} }
console.log(this.globalData.globalUrl) // console.log(this.globalData.globalUrl)
}, },
// 将token从缓存中 赋值到全局变量 // 将token从缓存中 赋值到全局变量
getToken: function () { getToken: function () {
...@@ -71,7 +71,6 @@ App({ ...@@ -71,7 +71,6 @@ App({
// 调用登录接口 // 调用登录接口
wx.login({ wx.login({
success: function (res) { success: function (res) {
console.log('wx.login微信登录',res)
that.codeChangeToken(res.code, cb, cb1) that.codeChangeToken(res.code, cb, cb1)
} }
}) })
...@@ -94,7 +93,6 @@ App({ ...@@ -94,7 +93,6 @@ App({
token: that.globalData.token token: that.globalData.token
}, },
success: function (res) { success: function (res) {
console.log('saveInfo',res)
if (res.data.meta.code === 200) { if (res.data.meta.code === 200) {
wx.setStorageSync('userInfo', JSON.parse(info.rawData)) wx.setStorageSync('userInfo', JSON.parse(info.rawData))
that.globalData.userInfo = JSON.parse(info.rawData) that.globalData.userInfo = JSON.parse(info.rawData)
......
<view class="loginbox"> <view class="loginbox">
<image class="title_img" src="/images/logo.png"></image> <image class="title_img" src="/images/logo1.png"></image>
<view class="title_tip"> 天择人才</view> <view class="title_tip"> 天择人才</view>
<button class="title_btn flex-h flex-vc flex-hc" wx:if="{{canIUseGetUserProfile}}" bindtap="getUserProfile"> <button class="title_btn flex-h flex-vc flex-hc" wx:if="{{canIUseGetUserProfile}}" bindtap="getUserProfile">
<text class="iconfont icon-weixin1"></text> 微信一键注册/登录 <text class="iconfont icon-weixin1"></text> 立即登录
</button> </button>
<button class="title_btn flex-h flex-vc flex-hc" wx:else open-type="getUserInfo" bindgetuserinfo="userInfoHandler"> <button class="title_btn flex-h flex-vc flex-hc" wx:else open-type="getUserInfo" bindgetuserinfo="userInfoHandler">
<text class="iconfont icon-weixin1"></text> 微信一键注册/登录 <text class="iconfont icon-weixin1"></text> 立即登录
</button> </button>
<view class="small_tip">请登录查看更多内容</view> <view class="small_tip">请登录查看更多内容</view>
......
...@@ -23,6 +23,7 @@ Page({ ...@@ -23,6 +23,7 @@ Page({
onLoad: function (options) { onLoad: function (options) {
this.getList() this.getList()
}, },
//获取直播间列表
getList() { getList() {
let params = { let params = {
url: apiList.live_list, url: apiList.live_list,
...@@ -47,8 +48,8 @@ Page({ ...@@ -47,8 +48,8 @@ Page({
}) })
base.newRequest(params) base.newRequest(params)
}, },
//跳转直播间
goLive(e) { goLive(e) {
// console.log(e.currentTarget.dataset.roomid)
let roomId = e.currentTarget.dataset.roomid // 房间号 let roomId = e.currentTarget.dataset.roomid // 房间号
try { try {
var userInfo = wx.getStorageSync('userInfo') var userInfo = wx.getStorageSync('userInfo')
......
...@@ -28,7 +28,7 @@ ...@@ -28,7 +28,7 @@
<view class="blank"></view> <view class="blank"></view>
</view> </view>
<view wx:else class="noneBox column"> <view wx:else class="noneBox column">
<image src="/images/none.png"></image> <image src="/images/none_pic.png"></image>
<view>暂无任何直播哦~</view> <view>暂无任何直播哦~</view>
</view> </view>
</view> </view>
\ No newline at end of file
...@@ -63,15 +63,15 @@ page { ...@@ -63,15 +63,15 @@ page {
} }
.noneBox { .noneBox {
padding: 140rpx 0 0; padding: 224rpx 125rpx;
align-items: center; align-items: center;
font-size: 28rpx; font-size: 28rpx;
color: #999; color: #999;
} }
.noneBox image { .noneBox image {
width: 215rpx; width: 500rpx;
height: 337rpx; height: 400rpx;
margin-bottom: 30rpx; margin-bottom: 30rpx;
} }
......
...@@ -38,7 +38,6 @@ class Base { ...@@ -38,7 +38,6 @@ class Base {
if (wx.showLoading()) { if (wx.showLoading()) {
wx.hideLoading() //隐藏加载动画 wx.hideLoading() //隐藏加载动画
} }
console.log(res)
if (res.statusCode == 200) { if (res.statusCode == 200) {
let rstcode = res.data.meta.code, msg = res.data.meta.message let rstcode = res.data.meta.code, msg = res.data.meta.message
// todo: 状态码判断 // todo: 状态码判断
......
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