Browse Source

Merge remote-tracking branch 'origin/master'

chen 5 năm trước cách đây
mục cha
commit
af210a5fd1
2 tập tin đã thay đổi với 4 bổ sung38 xóa
  1. 3 37
      pages/messageInfo/index.js
  2. 1 1
      pages/messageInfo/index.wxml

+ 3 - 37
pages/messageInfo/index.js

@@ -27,7 +27,7 @@ Page({
    */
   onLoad: function (options) {
    
-    if (wx.getStorageSync('uid') == ""){
+    if (wx.getStorageSync('user')._id == ""){
       wx.redirectTo({
       url: '/pages/login/index'
     })
@@ -38,40 +38,7 @@ Page({
     
   },
 
-  /**
-   * 生命周期函数--监听页面初次渲染完成
-   */
-  onReady: function () {
-
-  },
-
-  /**
-   * 生命周期函数--监听页面显示
-   */
-  onShow: function () {
-
-  },
-
-  /**
-   * 生命周期函数--监听页面隐藏
-   */
-  onHide: function () {
-
-  },
-
-  /**
-   * 生命周期函数--监听页面卸载
-   */
-  onUnload: function () {
-
-  },
-
-  /**
-   * 用户点击右上角分享
-   */
-  onShareAppMessage: function () {
-
-  },
+ 
   // 列表查询
   searchInfo: function (message) {
     wx.showLoading({
@@ -82,7 +49,7 @@ Page({
       url: 'http://124.235.209.122:88/api/financial/viewnews/select', //真是接口
       method: 'post',
       data: {
-        qyid: '5e903455d72a944fd899c59c',//wx.getStorageSync('uid')
+        qyid: '5e903455d72a944fd899c59c',//wx.getStorageSync('user')._id
         skip: that.data.skip,
         limit: that.data.limit
       },
@@ -136,7 +103,6 @@ Page({
   onReachBottom: function () {
     const pageNum = this.data.skip;
     const _pagenum = Math.ceil(this.data.total / this.data.limit);
-    console.log(pageNum + "哈哈哈哈" + _pagenum)
     if (pageNum < _pagenum) {
       this.setData({
         skip: pageNum + 1 //设置下一页

+ 1 - 1
pages/messageInfo/index.wxml

@@ -13,4 +13,4 @@
 			</view>
 		</view>
 	</view>
-</view>
+</view>