jiangping
2024-07-16 39613118a5bae23c45498c4f5a939e83595f99f5
wechat_jiaxuan/pages/sets/protocol.js
@@ -1,25 +1,36 @@
// pages/sets/protocol.js
import {
  getDictData
} from '../../api/index'
Page({
  /**
   * 页面的初始数据
   */
  data: {
    label: '',
    activeHtml: ''
  },
  /**
   * 生命周期函数--监听页面加载
   */
  onLoad(options) {
    const { label } = options
    this.initData(label)
  },
  /**
   * 生命周期函数--监听页面初次渲染完成
   */
  onReady() {
  initData(label){
    getDictData({
      code: 'ZBOM_CUSTOMIZED',
      label
    }).then(res => {
      wx.setNavigationBarTitle({
        title: res.data.remark
      })
      this.setData({
        activeHtml: res.data.code
      })
    })
  },
  /**