Files
bodyWeight/pages/familyMembers/familyMembers.js
T
2025-03-25 20:52:15 +08:00

45 lines
818 B
JavaScript

import $ from "../../utils/request";
Page({
data: {
userInfo: null,
subUserList: [],
},
onShow() {
this.setData({
userInfo: wx.getStorageSync("userInfo") || null
})
this.getSubUser();
},
// 获取家庭成员列表
getSubUser() {
let params = {};
$.ajax("weighingScale/list/subUser", params, "GET", true, "正在获取...").then(res => {
this.setData({
subUserList: res.result
})
})
},
openUserInfo() {
wx.navigateTo({
url: "/pages/userInfo/userInfo?initBluetooth=1&customerType=0"
})
},
editMyInfo() {
wx.navigateTo({
url: "/pages/userInfo/userInfo?initBluetooth=1&customerType=1"
})
},
editUserInfo(e) {
let id = e.currentTarget.dataset.id;
wx.navigateTo({
url: "/pages/userInfo/userInfo?id="+ id +"&initBluetooth=1&customerType=0"
})
}
})