碧桂园
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

78 行
1.3 KiB

  1. // pages/out/index.js
  2. Page({
  3. /**
  4. * 页面的初始数据
  5. */
  6. data: {
  7. web:null,
  8. index:1,
  9. userid: 0,// 用户ID
  10. gameid: 0,// 游戏ID
  11. type: 1,
  12. allurl: ""
  13. },
  14. /**
  15. * 生命周期函数--监听页面加载
  16. */
  17. onLoad: function (options) {
  18. console.log(options);
  19. this.setData({
  20. allurl: options.url||'https://cktest.2weisou.com/dance/',
  21. web:options.web,
  22. index:options.index,
  23. userid: options.userid,
  24. gameid: options.gameid,
  25. type: options.type,
  26. allurl: this.data.allurl +`?userid=${options.userid||0}&gameid=${options.gameid||0}&type=${options.type==2?2:1}`
  27. })
  28. console.log(this.data.allurl)
  29. },
  30. /**
  31. * 生命周期函数--监听页面初次渲染完成
  32. */
  33. onReady: function () {
  34. },
  35. /**
  36. * 生命周期函数--监听页面显示
  37. */
  38. onShow: function () {
  39. },
  40. /**
  41. * 生命周期函数--监听页面隐藏
  42. */
  43. onHide: function () {
  44. },
  45. /**
  46. * 生命周期函数--监听页面卸载
  47. */
  48. onUnload: function () {
  49. },
  50. /**
  51. * 页面相关事件处理函数--监听用户下拉动作
  52. */
  53. onPullDownRefresh: function () {
  54. },
  55. /**
  56. * 页面上拉触底事件的处理函数
  57. */
  58. onReachBottom: function () {
  59. },
  60. /**
  61. * 用户点击右上角分享
  62. */
  63. onShareAppMessage: function () {
  64. }
  65. })