function showCommitter()

in source/javascripts/phonebook.js [222:317]


function showCommitter(obj, uid) {
   var details = document.getElementById('details_committer_' + uid)
   if (!details) {
      details = document.createElement('p')
      details.setAttribute("id", 'details_committer_' + uid)
      var cl = getProjectCommittership(uid) // committer(in :members) of these LDAP PMC projects 
      var roles = getCommitteeRoles(uid)
      var cttees = getProjectOwnership(uid) // member(in :owners) of these LDAP PMC projects
      var pl = roles[0] // pmc membership
      var ch = roles[1] // chairs
      if (isNologin(uid)) {
         details.innerHTML += "<b>Login is currently disabled</b><br/><br/>"
      }
      if (isMember(uid)) {
         details.innerHTML += "<i>Foundation member</i><br/><br/>"
      }
      if (ch.length > 0) {
         details.innerHTML += "<b>Chair of:</b> " + linkifyList(Q_PMC, ch)
         if (!isChair(uid)) {
            details.innerHTML += " <b>Not a member of pmc-chairs!</b>"
         }
         details.innerHTML += "<br/><br/>"
      }
      var purls = urls(uid)
      if (purls.length > 0) {
         details.innerHTML += "<b>Personal URLs:</b> " + linkifyURLs(purls) + "<br/><br/>"
      }
      if (cl.length > 0) {
         details.innerHTML += "<b>Committer on:</b> " + linkifyList(Q_UNIX, cl) + "<br/><br/>"
      }
      var nc = [] // On PMC but not in LDAP unix
      var nl = [] // On PMC but not in LDAP committee
      var np = [] // Not in PMC even though in LDAP committee
      var nu = [] // In LDAP committee but not in LDAP unix
      var pn;
      if (pl.length > 0) {
         details.innerHTML += "<b>PMC member of:</b> " + linkifyList(Q_PMC, pl) + "<br/><br/>"
         for (p in pl) {
            pn = pl[p]
            // There is an LDAP PMC group but the uid is not in the committer(:members) group
            if (isProjectPMC(pn) && cl.indexOf(pn) < 0) {
               nc.push(pn)
            }
            // There is an LDAP PMC group but the uid is not in the committee(:owners) group
            if (isProjectPMC(pn) && cttees.indexOf(pn) < 0) {
               nl.push(pn)
            }
         }
      }

      if (cttees.length > 0) {
         for (p in cttees) {
            pn = cttees[p]
            // name is a PMC but uid is not on the PMC
            if (isPMC(pn) && pl.indexOf(pn) < 0) {
               np.push(pn)
            }
            // name has LDAP project entry but uid is not in the committer (member) list  
            if (isProjectPMC(pn) && cl.indexOf(pn) < 0) {
               nu.push(pn)
            }
         }
         details.innerHTML += "<b>LDAP committee group membership:</b> " + linkifyList(Q_CTTE, cttees) + "<br/><br/>"
      }

      var services = getRoster(ldapservices, uid)
      if (services.length > 0) {
         details.innerHTML += "<b>Service group membership:</b> " + linkifyList(Q_SERVICE, services) + "<br/><br/>"
      }
      var auths = getRoster(ldapauth, uid)
      if (auths.length > 0) {
         details.innerHTML += "<b>Auth group membership:</b> " + linkifyList(Q_AUTH, auths) + "<br/><br/>"
      }
      var pods = getRoster(podlings, uid)
      if (pods.length > 0) {
         details.innerHTML += "<b>Podling membership:</b> " + linkifyList(Q_PODLING, pods) + "<br/><br/>"
      }

      // Note any discrepancies
      if (np.length > 0) {
         details.innerHTML += "<span class='error'>In LDAP committee group, but <b>not a PMC member</b>:</span> " + linkifyList(Q_CTTE, np) + "<br/><br/>"
      }
      if (nc.length > 0) {
         details.innerHTML += "<span class='error'>On PMC, but not a member of the committer group:</span> " + linkifyList(Q_PMC, nc) + "<br/><br/>"
      }
      if (nl.length > 0) {
         details.innerHTML += "<span class='error'>On PMC, but not member of the LDAP committee group:</span> " + linkifyList(Q_CTTE, nl) + "<br/><br/>"
      }
      if (nu.length > 0) {
         details.innerHTML += "<span class='error'>In LDAP committee group but not a member of the committer group:</span> " + linkifyList(Q_UNIX, nu) + "<br/><br/>"
      }
      obj.appendChild(details)
   } else {
      obj.removeChild(details)
   }
}