美甲小程序
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.

97 line
1.5 KiB

  1. // pages/pageBusiness/pageBusiness.js
  2. const utils = require('../../utils/serve')
  3. Page({
  4. /**
  5. * 页面的初始数据
  6. */
  7. data: {
  8. swiperArr: [],
  9. busData: null,
  10. },
  11. Clipboard: function (event) {
  12. let value = event.currentTarget.dataset.value
  13. wx.setClipboardData({
  14. data: value,
  15. })
  16. },
  17. /**
  18. * 生命周期函数--监听页面加载
  19. */
  20. onLoad: function (options) {
  21. this.init()
  22. },
  23. init: function (params) {
  24. utils.http({
  25. url: '/manicureApi/Index/business',
  26. method: 'GET',
  27. }).then(res => {
  28. this.setData({
  29. swiperArr: res.data.list,
  30. busData: {
  31. businessWechat: res.data.businessWechat,
  32. businessPhone: res.data.businessPhone,
  33. businessAddress: res.data.businessAddress,
  34. }
  35. })
  36. })
  37. },
  38. /**
  39. * 生命周期函数--监听页面初次渲染完成
  40. */
  41. onReady: function () {
  42. },
  43. /**
  44. * 生命周期函数--监听页面显示
  45. */
  46. onShow: function () {
  47. },
  48. /**
  49. * 生命周期函数--监听页面隐藏
  50. */
  51. onHide: function () {
  52. },
  53. /**
  54. * 生命周期函数--监听页面卸载
  55. */
  56. onUnload: function () {
  57. },
  58. /**
  59. * 页面相关事件处理函数--监听用户下拉动作
  60. */
  61. onPullDownRefresh: function () {
  62. },
  63. /**
  64. * 页面上拉触底事件的处理函数
  65. */
  66. onReachBottom: function () {
  67. },
  68. /**
  69. * 用户点击右上角分享
  70. */
  71. onShareAppMessage: function () {
  72. }
  73. })