From a6d06dfe2ab0aadb6b0987fb7f96e8f3c9841846 Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Tue, 29 May 2012 18:23:12 -0500 Subject: RW support for groups now in place --- src/ldapmgr.cpp | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) (limited to 'src/ldapmgr.cpp') diff --git a/src/ldapmgr.cpp b/src/ldapmgr.cpp index 5f2433c..ba45fd1 100644 --- a/src/ldapmgr.cpp +++ b/src/ldapmgr.cpp @@ -201,6 +201,30 @@ void LDAPConfig::updateGroupsList() { processLockouts(); } +LDAPUserInfo LDAPConfig::findUserInfoByName(TQString name) { + // Figure out which user is selected + LDAPUserInfoList::Iterator it; + for (it = m_userInfoList.begin(); it != m_userInfoList.end(); ++it) { + LDAPUserInfo user = *it; + if (user.name == name) { + return user; + } + } + return LDAPUserInfo(); +} + +LDAPGroupInfo LDAPConfig::findGroupInfoByName(TQString name) { + // Figure out which group is selected + LDAPGroupInfoList::Iterator it; + for (it = m_groupInfoList.begin(); it != m_groupInfoList.end(); ++it) { + LDAPGroupInfo group = *it; + if (group.name == name) { + return group; + } + } + return LDAPGroupInfo(); +} + LDAPUserInfo LDAPConfig::findUserInfoByNameAndUID(TQString name, TQString uid) { // Figure out which user is selected LDAPUserInfoList::Iterator it; @@ -345,6 +369,8 @@ void LDAPConfig::modifySelectedGroup() { group = m_ldapmanager->getGroupByDistinguishedName(group.distinguishedName); GroupConfigDialog groupconfigdlg(group, this); if (groupconfigdlg.exec() == TQDialog::Accepted) { + group = groupconfigdlg.m_group; + m_ldapmanager->updateGroupInfo(group); // RAJA FIXME } updateAllInformation(); -- cgit v1.2.1