limited.js 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. import common from '../../utils/util';
  2. import server from '../../utils/main';
  3. const app = getApp();
  4. Page({
  5. data: {
  6. FileUrl: app.globalData.imageUrl,
  7. },
  8. onLoad: function (options) {
  9. this.setData({
  10. Containnerheight: common.getSystemHeight(),
  11. });
  12. this.init();
  13. },
  14. init: function () {
  15. var that = this;
  16. server.getData('GetWXUsersAllTime?ProductID=' + app.globalData.ProgramID + '&UserID=' + app.globalData.userInfo.UserID, function (data) {
  17. if (data) {
  18. for (var i = 0; i < data.length; i++) {
  19. var date = common.formatDateCHS(common.formatTime(new Date()));
  20. if (data[i].Time >= date)
  21. data[i].Member = "会员";
  22. else
  23. data[i].Member = "非会员";
  24. }
  25. that.setData({
  26. ProductList: data,
  27. });
  28. }
  29. });
  30. },
  31. gotoFeedback: function () {
  32. server.gotoFeedback();
  33. },
  34. onShareAppMessage: function () {
  35. return {
  36. title: app.globalData.ShareTitle,
  37. path: app.globalData.SharePath + '?UserID=' + app.globalData.userInfo.UserID,
  38. imageUrl: app.globalData.ShareImage,
  39. }
  40. },
  41. });