feat: fix LDAP mobile field incorrect mapped (#2206)

This commit is contained in:
Yaodong Yu
2023-08-12 13:45:26 +08:00
committed by GitHub
parent 33a922f026
commit db4ac60bb6
2 changed files with 4 additions and 5 deletions

View File

@ -47,13 +47,12 @@ type LdapUser struct {
Email string `json:"email"` Email string `json:"email"`
EmailAddress string EmailAddress string
TelephoneNumber string TelephoneNumber string
Mobile string Mobile string `json:"mobile"`
MobileTelephoneNumber string MobileTelephoneNumber string
RegisteredAddress string RegisteredAddress string
PostalAddress string PostalAddress string
GroupId string `json:"groupId"` GroupId string `json:"groupId"`
Phone string `json:"phone"`
Address string `json:"address"` Address string `json:"address"`
MemberOf string `json:"memberOf"` MemberOf string `json:"memberOf"`
} }
@ -318,7 +317,7 @@ func SyncLdapUsers(owner string, syncUsers []LdapUser, ldapId string) (existUser
DisplayName: syncUser.buildLdapDisplayName(), DisplayName: syncUser.buildLdapDisplayName(),
Avatar: organization.DefaultAvatar, Avatar: organization.DefaultAvatar,
Email: syncUser.Email, Email: syncUser.Email,
Phone: syncUser.Phone, Phone: syncUser.Mobile,
Address: []string{syncUser.Address}, Address: []string{syncUser.Address},
Affiliation: affiliation, Affiliation: affiliation,
Tag: tag, Tag: tag,

View File

@ -191,8 +191,8 @@ class LdapSyncPage extends React.Component {
}, },
{ {
title: i18next.t("general:Phone"), title: i18next.t("general:Phone"),
dataIndex: "phone", dataIndex: "mobile",
key: "phone", key: "mobile",
sorter: (a, b) => a.phone.localeCompare(b.phone), sorter: (a, b) => a.phone.localeCompare(b.phone),
}, },
{ {