From d40b24c08c046082ef97906a3221eac76756ab5d Mon Sep 17 00:00:00 2001 From: wangxia <779219182@qq.com> Date: Fri, 20 Jun 2025 19:17:27 +0800 Subject: [PATCH] =?UTF-8?q?=E5=90=8C=E6=AD=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- root/person/teamManage.vue | 35 ++++++++++++++++++++++++++--------- 1 file changed, 26 insertions(+), 9 deletions(-) diff --git a/root/person/teamManage.vue b/root/person/teamManage.vue index 5883673..fab4a6e 100644 --- a/root/person/teamManage.vue +++ b/root/person/teamManage.vue @@ -15,7 +15,7 @@
{{ item.aliasName || item.userName }} -
{{ item.agencyRoleName }}
+
{{ i }}
{{ item.tel }} @@ -25,7 +25,7 @@
- +
@@ -67,6 +67,18 @@ export default { }, methods: { + compare(a, b) { + let sortList = ["创建人", "管理员"]; + if (sortList.includes(a) && sortList.includes(b)) { + return sortList.indexOf(a) - sortList.indexOf(b); + } else if (sortList.includes(a)) { + return -1; + } else if (sortList.includes(b)) { + return 1; + } else { + return a.localeCompare(b); + } + }, getMemberList() { let that = this; uni.showLoading({ @@ -74,7 +86,12 @@ export default { }); this.G.Get(this.api.order_peopleList, { pageSize: 500 }, (res) => { console.log("报名人列表:", res); - that.memberList = res.recordList + that.memberList = res.recordList; + that.memberList.forEach((item) => { + item.agencyRoleNameList = item.agencyRoleName.split(";"); + item.agencyRoleNameList = item.agencyRoleNameList.sort(this.compare); + }); + uni.hideLoading(); }); }, @@ -105,19 +122,19 @@ export default {