Browse Source

万星广场停车调试

siChuanBan_2019.10.29
Stormeye Wu 5 years ago
parent
commit
7cdd0247d9
2 changed files with 90 additions and 90 deletions
  1. +3
    -3
      ext.json
  2. +87
    -87
      index/index.js

+ 3
- 3
ext.json View File

@@ -36,8 +36,8 @@
"ifHaveWebSocket": "0", "ifHaveWebSocket": "0",
"ifHaveCarModular": "1" "ifHaveCarModular": "1"
}, },
"name": "富茂链客生产版",
"weappId": "wx6a2524a8286d687f",
"name": "福州连江万星广场",
"weappId": "wxce917a9a151fc03c",
"appVersion": "C.5.1.1" "appVersion": "C.5.1.1"
}, },
"debug": false, "debug": false,
@@ -76,7 +76,7 @@
"navigationBarTitleText": "", "navigationBarTitleText": "",
"navigationBarBackgroundColor": "#FFFFFF" "navigationBarBackgroundColor": "#FFFFFF"
}, },
"extAppid": "wx6a2524a8286d687f",
"extAppid": "wxce917a9a151fc03c",
"extEnable": true, "extEnable": true,
"permission": { "permission": {
"scope.userLocation": { "scope.userLocation": {


+ 87
- 87
index/index.js View File

@@ -10,7 +10,7 @@ const bgColor = require("../utils/bgColor.js")
let app = getApp(); let app = getApp();
Page({ Page({
data: { data: {
showLocationIf:true,
showLocationIf: true,
ifStoreApp: ifStoreApp, ifStoreApp: ifStoreApp,
navigationBarTitle: '首页', navigationBarTitle: '首页',
navigationBarHeight, navigationBarHeight,
@@ -19,7 +19,7 @@ Page({
qg: bgColor.colorFirst.main.qg, qg: bgColor.colorFirst.main.qg,
newUrl: "", newUrl: "",
cover: "", cover: "",
kanjia:imgurl.kanjia.url,
kanjia: imgurl.kanjia.url,
pintuan: imgurl.pintuan.url, pintuan: imgurl.pintuan.url,
xiaofeika: imgurl.xiaofeika.url, xiaofeika: imgurl.xiaofeika.url,
xingyun: imgurl.xingyun.url, xingyun: imgurl.xingyun.url,
@@ -51,7 +51,7 @@ Page({
duihuan: imgurl.duihuan.url, duihuan: imgurl.duihuan.url,
market: app.globalData.market, market: app.globalData.market,
list: [], list: [],
xslist:[],
xslist: [],
loading: true, loading: true,
fistLogin: null, fistLogin: null,
alphaData: null, alphaData: null,
@@ -64,24 +64,24 @@ Page({
scrollTop: 0, scrollTop: 0,
showGame: false, showGame: false,
showTopic: false, showTopic: false,
showQg:false,
showQg: false,
gamedata: {}, gamedata: {},
couponId: '', //游戏返回时传回的字段 couponId: '', //游戏返回时传回的字段
played: false, //从游戏页面跳回首页返回true played: false, //从游戏页面跳回首页返回true
havePlayEd: app.globalData.havePlayEd, havePlayEd: app.globalData.havePlayEd,
havePlayEd1:app.globalData.havePlayEd1,
havePlayEd1: app.globalData.havePlayEd1,
staticGamedata: {}, staticGamedata: {},
showIf: false, showIf: false,
showPages: false, showPages: false,
display: 'none', display: 'none',
display1: 'none', display1: 'none',
optionsData: null, optionsData: null,
page: 1 ,// 刷新进入页面时已经加载了第一页数据,onReachBottom时 page++,从第2页开始加载
openId:'',
page: 1, // 刷新进入页面时已经加载了第一页数据,onReachBottom时 page++,从第2页开始加载
openId: '',
showGg: false, showGg: false,
ggdata:{}
ggdata: {}
}, },
alphaClick1: function (even) {
alphaClick1: function(even) {
var animation = wx.createAnimation({}) var animation = wx.createAnimation({})
animation.opacity(0).step({ animation.opacity(0).step({
duration: 2000 duration: 2000
@@ -138,17 +138,17 @@ Page({
}, },
gotogame: function() { gotogame: function() {
let that = this; let that = this;
if (!that.data.showIf){
if (!that.data.showIf) {
wx.showToast({ wx.showToast({
title: '暂无游戏频道', title: '暂无游戏频道',
icon:"none",
duration:3000
icon: "none",
duration: 3000
}) })
}else{
} else {
Http.get({ Http.get({
url: config.api.checkPhoneStatus,
data: {}
})
url: config.api.checkPhoneStatus,
data: {}
})
.then(res => { .then(res => {
var data = { var data = {
couponChannelId: "" + that.data.couponChannelId, couponChannelId: "" + that.data.couponChannelId,
@@ -188,7 +188,7 @@ Page({
} }
}) })
} }
}, },
mySpecial: function() { mySpecial: function() {
console.log("special"); console.log("special");
@@ -204,12 +204,12 @@ Page({
let that = this; let that = this;
let optionss; let optionss;
let openId = wx.getStorageSync('openId') let openId = wx.getStorageSync('openId')
if(openId){
if (openId) {
that.setData({ that.setData({
openId:openId
openId: openId
}) })
} }
if (wx.getStorageSync('options')){
if (wx.getStorageSync('options')) {
optionss = JSON.parse(wx.getStorageSync('options')); optionss = JSON.parse(wx.getStorageSync('options'));
} }
if (options.played == "true") { if (options.played == "true") {
@@ -235,7 +235,7 @@ Page({
let that = this; let that = this;
wx.getLocation({ wx.getLocation({
type: "wgs84", type: "wgs84",
success: function (res) {
success: function(res) {
console.log(res, 9999) console.log(res, 9999)
if (res && res.longitude && res.latitude) { if (res && res.longitude && res.latitude) {
Http.post({ Http.post({
@@ -245,7 +245,7 @@ Page({
longitude: res.longitude longitude: res.longitude
} }
}).then(res => { }).then(res => {
console.log(res,9999)
console.log(res, 9999)
}) })
} }
}, },
@@ -264,7 +264,7 @@ Page({
let that = this; let that = this;
that.setData({ that.setData({
havePlayEd: app.globalData.havePlayEd ? app.globalData.havePlayEd : false, havePlayEd: app.globalData.havePlayEd ? app.globalData.havePlayEd : false,
havePlayEd1:app.globalData.havePlayEd1?app.globalData.havePlayEd1 : false
havePlayEd1: app.globalData.havePlayEd1 ? app.globalData.havePlayEd1 : false
}) })


/** /**
@@ -294,14 +294,14 @@ Page({
that.alphaClick(); that.alphaClick();
}, 8000) }, 8000)
// 如果有广告 // 如果有广告
setTimeout(function () {
setTimeout(function() {
// debugger // debugger
that.alphaClick1(); that.alphaClick1();
}, 8000) }, 8000)
}, },
getmemberId: function(token) { getmemberId: function(token) {
let that = this;
Http.get({
let that = this;
Http.get({
url: config.api.getScore, url: config.api.getScore,
data: { data: {
token: token token: token
@@ -327,17 +327,17 @@ Page({
url: '/pages/czdetail/czdetail', url: '/pages/czdetail/czdetail',
}) })
}, },
gotoBargain: function () {
gotoBargain: function() {
wx.navigateTo({ wx.navigateTo({
url: '/pages/bargain/bargain', url: '/pages/bargain/bargain',
}) })
}, },
gotoSpellGroup: function () {
gotoSpellGroup: function() {
wx.navigateTo({ wx.navigateTo({
url: '/pages/spellGroup/spellGroup', url: '/pages/spellGroup/spellGroup',
}) })
}, },
gotoCard: function () {
gotoCard: function() {
wx.navigateTo({ wx.navigateTo({
url: '/pages/discountCardList/discountCardList', url: '/pages/discountCardList/discountCardList',
}) })
@@ -347,12 +347,12 @@ Page({
// url: '/pages/game/index', // url: '/pages/game/index',
// }) // })
// }, // },
gotoJfsc: function () {
gotoJfsc: function() {
wx.navigateTo({ wx.navigateTo({
url: '/pages/integralmall/index', url: '/pages/integralmall/index',
}) })
}, },
/** /**
* *
* @param {code,page} * @param {code,page}
@@ -374,7 +374,7 @@ Page({
that.topicShow(); that.topicShow();
that.getxsList(); that.getxsList();
that.getMallInfo(app.globalData.token); that.getMallInfo(app.globalData.token);
if (app.couponChannelListCallback) { if (app.couponChannelListCallback) {
app.couponChannelListCallback(app.globalData.token); app.couponChannelListCallback(app.globalData.token);
} }
@@ -493,36 +493,36 @@ Page({
}); });
}, },
//获取限时抢购列表 //获取限时抢购列表
getxsList(){
getxsList() {
let that = this; let that = this;
Http.get({ Http.get({
url: config.api.couponChannelList,
data: {
pageNum: 1,
pageSize: 3,
targetAd: 2
}
}).then(res => {
if (res && res.data.total>0) {
that.setData({
xslist: res.data.list,
showQg:true
url: config.api.couponChannelList,
data: {
pageNum: 1,
pageSize: 3,
targetAd: 2
}
}).then(res => {
if (res && res.data.total > 0) {
that.setData({
xslist: res.data.list,
showQg: true
});
} else {
that.setData({
showQg: false
})
}
})
.catch(err => {
console.log(err)
wx.showToast({
title: err.errMsg,
icon: 'none',
duration: 2000,
mask: false
}); });
}else{
that.setData({
showQg:false
})
}
})
.catch(err => {
console.log(err)
wx.showToast({
title: err.errMsg,
icon: 'none',
duration: 2000,
mask: false
});
})
})
}, },
/** /**
* banner * banner
@@ -641,48 +641,48 @@ Page({
}) })
}, },
//限时抢购的详情页面 //限时抢购的详情页面
gotodetail: function (e) {
gotodetail: function(e) {
wx.navigateTo({ wx.navigateTo({
url: `/pages/coupon/detail/index?couponChannelId=${ url: `/pages/coupon/detail/index?couponChannelId=${
e.currentTarget.dataset.couponchannelid e.currentTarget.dataset.couponchannelid
}&couponId=${e.currentTarget.dataset.couponid}` }&couponId=${e.currentTarget.dataset.couponid}`
}); });
}, },
//浮层广告
getGg: function (token) {
//浮层广告
getGg: function(token) {
let that = this let that = this
Http.get({ Http.get({
url: config.api.getGg,
data: {
token: token,
appId: config.weapp.AppId,
openId: that.data.openId
}
}).then(res => {
console.log(res)
if (res.data.id) {
url: config.api.getGg,
data: {
token: token,
appId: config.weapp.AppId,
openId: that.data.openId
}
}).then(res => {
console.log(res)
if (res.data.id) {
that.setData({
showGg: true,
})
console.log(that.data.showGg, 1111111111111)
} else {
that.setData({
showGg: false
})
that.getGameOne(app.globalData.token)
console.log(that.data.showGg, 222222222222222222)
}
that.setData({ that.setData({
showGg: true,
ggdata: res.data
}) })
console.log(that.data.showGg,1111111111111)
} else {
that.setData({
})
.catch(err => {
this.setData({
showGg: false showGg: false
}) })
that.getGameOne(app.globalData.token) that.getGameOne(app.globalData.token)
console.log(that.data.showGg,222222222222222222)
}
that.setData({
ggdata: res.data
that.alphaClick1();
}) })
})
.catch(err => {
this.setData({
showGg: false
})
that.getGameOne(app.globalData.token)
that.alphaClick1();
})
}, },
/** /**
* 刷新 * 刷新


Loading…
Cancel
Save