warning.js 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. const app = getApp();
  2. Page({
  3. /**
  4. * 页面的初始数据
  5. */
  6. data: {
  7. tab: 1,
  8. list: [{
  9. img: '/images/head.png',
  10. name: '刘天仙',
  11. address: '一号宿舍楼 502宿舍'
  12. }, {
  13. img: '/images/head.png',
  14. name: '陈方明',
  15. address: '一号宿舍楼 508宿舍'
  16. }]
  17. },
  18. checkTab: function(e) {
  19. const that = this;
  20. let type = e.currentTarget.dataset.type;
  21. that.setData({
  22. tab: type
  23. })
  24. },
  25. /**
  26. * 生命周期函数--监听页面加载
  27. */
  28. onLoad: function(options) {
  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. })