lrf402788946 3 years ago
parent
commit
413674c18a
6 changed files with 76 additions and 2 deletions
  1. 2 1
      app.json
  2. 66 0
      pages/history/detail.js
  3. 3 0
      pages/history/detail.json
  4. 2 0
      pages/history/detail.wxml
  5. 1 0
      pages/history/detail.wxss
  6. 2 1
      pages/my/index.js

+ 2 - 1
app.json

@@ -8,7 +8,8 @@
     "pages/history/index",
     "pages/news/index",
     "pages/news/detail",
-    "pages/login/index"
+    "pages/login/index",
+    "pages/history/detail"
   ],
   "usingComponents": {
     "van-button": "/miniprogram_npm/vant-weapp/button/index",

+ 66 - 0
pages/history/detail.js

@@ -0,0 +1,66 @@
+// pages/history/detail.js
+Page({
+
+  /**
+   * 页面的初始数据
+   */
+  data: {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面加载
+   */
+  onLoad: function (options) {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面初次渲染完成
+   */
+  onReady: function () {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面显示
+   */
+  onShow: function () {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面隐藏
+   */
+  onHide: function () {
+
+  },
+
+  /**
+   * 生命周期函数--监听页面卸载
+   */
+  onUnload: function () {
+
+  },
+
+  /**
+   * 页面相关事件处理函数--监听用户下拉动作
+   */
+  onPullDownRefresh: function () {
+
+  },
+
+  /**
+   * 页面上拉触底事件的处理函数
+   */
+  onReachBottom: function () {
+
+  },
+
+  /**
+   * 用户点击右上角分享
+   */
+  onShareAppMessage: function () {
+
+  }
+})

+ 3 - 0
pages/history/detail.json

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

+ 2 - 0
pages/history/detail.wxml

@@ -0,0 +1,2 @@
+<!--pages/history/detail.wxml-->
+<text>pages/history/detail.wxml</text>

+ 1 - 0
pages/history/detail.wxss

@@ -0,0 +1 @@
+/* pages/history/detail.wxss */

+ 2 - 1
pages/my/index.js

@@ -16,9 +16,10 @@ Page({
   // 跳转页面
   routeBtn: function (e) {
     let type = e.currentTarget.dataset.type;
+    console.log(app.globalData.wxInfo)
     if (type == '1') {
       wx.redirectTo({
-        url: `/pages/history/index?openid=${app.globalData.userInfo.openid}`
+        url: `/pages/history/index?openid=${app.globalData.wxInfo.openid}`
       })
     } else if (type == '2') {
       app.globalData.userInfo = {}