公司过滤
This commit is contained in:
parent
d245e34f51
commit
5c5ddc5a24
|
|
@ -59,7 +59,9 @@ const onSubmitLogin = async () => {
|
|||
const { data: result } = await appLoginAPI(loginForm)
|
||||
memberStore.setToken(result.access_token)
|
||||
const userResult = await getUserInfoAPI()
|
||||
const { data: comResult } = await getCompanyListAPI()
|
||||
const { data: res } = await getCompanyListAPI()
|
||||
const comResult = res.filter((e) => e.isShow)
|
||||
// console.log('🚀 ~ onSubmitLogin ~ comResult:', comResult)
|
||||
const userCompanyList = comResult.filter((e) => e.companyId == userResult.user.companyId)
|
||||
memberStore.setUserInfo(userResult.user)
|
||||
memberStore.setCompanyList(comResult)
|
||||
|
|
@ -98,7 +100,9 @@ onMounted(async () => {
|
|||
|
||||
memberStore.setToken(result.access_token)
|
||||
const userResult = await getUserInfoAPI()
|
||||
const { data: comResult } = await getCompanyListAPI()
|
||||
const { data: res } = await getCompanyListAPI()
|
||||
const comResult = res.filter((e) => e.isShow)
|
||||
// console.log('🚀 ~ onMounted ~ comResult:', comResult)
|
||||
const userCompanyList = comResult.filter(
|
||||
(e) => e.companyId == userResult.user.companyId,
|
||||
)
|
||||
|
|
|
|||
Loading…
Reference in New Issue