兼兼街租房小程序
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

60 lines
1.1 KiB

  1. <script>
  2. export default {
  3. globalData: {
  4. },
  5. onLaunach: function() {
  6. },
  7. onShow: function() {
  8. },
  9. methods: {
  10. updater(){
  11. const updateManager = wx.getUpdateManager()
  12. updateManager.onCheckForUpdate(function (res) {
  13. console.log(res.hasUpdate)
  14. })
  15. updateManager.onUpdateReady(function () {
  16. wx.showModal({
  17. title: '更新提示',
  18. content: '新版本已经准备好,是否重启应用?',
  19. success(res) {
  20. if (res.confirm) {
  21. updateManager.applyUpdate()
  22. }
  23. }
  24. })
  25. })
  26. updateManager.onUpdateFailed(function () {
  27. // 新版本下载失败
  28. })
  29. }
  30. }
  31. };
  32. </script>
  33. <style lang="scss">
  34. @import "./app.css";
  35. @import "uview-ui/index.scss";
  36. /* 隐藏头部 */
  37. /* uni-page-head {
  38. display: none;
  39. }
  40. /* 轮播图指示点 */
  41. /* uni-swiper .uni-swiper-dots-horizontal {
  42. bottom: 20px !important;
  43. }
  44. page{
  45. height: 100%;
  46. } */
  47. @import '/common/css/base.scss';
  48. page {
  49. background-color: #f5f5f5;
  50. }
  51. .example-info {
  52. font-size: 14px;
  53. color: #333;
  54. padding: 10px;
  55. }
  56. </style>