fix: 修改账号选择下拉列表。

This commit is contained in:
tianyongbao
2026-01-21 16:53:29 +08:00
parent 0027510594
commit 2301661fb5

View File

@@ -79,14 +79,20 @@ watchEffect(() => {
function getParentList() { function getParentList() {
list_user_parent().then((res: any) => { list_user_parent().then((res: any) => {
if (res.code == 200) { if (res.code == 200) {
const originalUserId = Taro.getStorageSync("UserId");
const originalUserName = Taro.getStorageSync("UserName");
const arr = [ const arr = [
{ {
userId: Taro.getStorageSync("UserId"), userId: originalUserId,
userName: Taro.getStorageSync("UserName"), userName: `${originalUserName}(主账号)`,
}, },
]; ];
res.data.forEach((r) => { res.data.forEach((r) => {
arr.push(r); arr.push({
userId: r.userId,
userName: `${r.userName}(关联账号)`,
});
}); });
parentList.value = arr; parentList.value = arr;
} }