|
@@ -111,36 +111,32 @@
|
|
|
const filterOption = (input, option) => {
|
|
const filterOption = (input, option) => {
|
|
|
return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0
|
|
return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0
|
|
|
}
|
|
}
|
|
|
- const popupScroll = (el) => {
|
|
|
|
|
- let offset = 0
|
|
|
|
|
- if (el.target.scrollHeight - el.target.scrollTop - offset <= el.target.clientHeight) {
|
|
|
|
|
- userPagination.value.current += 1
|
|
|
|
|
- getUserAllList(true)
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
const userPagination = ref({
|
|
const userPagination = ref({
|
|
|
size: 10,
|
|
size: 10,
|
|
|
- current: 1,
|
|
|
|
|
|
|
+ current: 1
|
|
|
})
|
|
})
|
|
|
const userTotal = ref(0)
|
|
const userTotal = ref(0)
|
|
|
//获取用户
|
|
//获取用户
|
|
|
const getUserAllList = (add) => {
|
|
const getUserAllList = (add) => {
|
|
|
- if (userPagination.value.size * userPagination.value.current < userTotal.value) {
|
|
|
|
|
- forumApi.allUserList(userPagination.value).then((res) => {
|
|
|
|
|
- userTotal.value = res.total
|
|
|
|
|
- let userList = res.records.map((r) => {
|
|
|
|
|
- return {
|
|
|
|
|
- label: r.name,
|
|
|
|
|
- value: r.id,
|
|
|
|
|
- ...r
|
|
|
|
|
- }
|
|
|
|
|
- })
|
|
|
|
|
- if (add) {
|
|
|
|
|
- usertypeOptions.value.push(userList)
|
|
|
|
|
- } else {
|
|
|
|
|
- usertypeOptions.value = userList
|
|
|
|
|
|
|
+ forumApi.allUserList(userPagination.value).then((res) => {
|
|
|
|
|
+ userTotal.value = res.total
|
|
|
|
|
+ let userList = res.records.map((r) => {
|
|
|
|
|
+ return {
|
|
|
|
|
+ label: `${r.name}-${r.eduIdentityName}`,
|
|
|
|
|
+ value: r.id,
|
|
|
|
|
+ ...r
|
|
|
}
|
|
}
|
|
|
})
|
|
})
|
|
|
|
|
+ usertypeOptions.value = add ? [...usertypeOptions.value, ...userList] : userList
|
|
|
|
|
+ })
|
|
|
|
|
+ }
|
|
|
|
|
+ const popupScroll = (el) => {
|
|
|
|
|
+ let offset = 0
|
|
|
|
|
+ if (el.target.scrollHeight - el.target.scrollTop - offset <= el.target.clientHeight) {
|
|
|
|
|
+ if (userPagination.value.size * userPagination.value.current < userTotal.value) {
|
|
|
|
|
+ userPagination.value.current += 1
|
|
|
|
|
+ getUserAllList(true)
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
const getData = async () => {
|
|
const getData = async () => {
|
|
@@ -224,7 +220,7 @@
|
|
|
}
|
|
}
|
|
|
//获取操作系统/浏览器等信息
|
|
//获取操作系统/浏览器等信息
|
|
|
const browserObj = ref({
|
|
const browserObj = ref({
|
|
|
- forumSupportEnvParam:{}
|
|
|
|
|
|
|
+ forumSupportEnvParam: {}
|
|
|
})
|
|
})
|
|
|
function getBower() {
|
|
function getBower() {
|
|
|
const browser = Bowser.getParser(window.navigator.userAgent)
|
|
const browser = Bowser.getParser(window.navigator.userAgent)
|