2011-03-30 4 views
0

Il existe une propriété de profil utilisateur nommée "EmployeeID" pour chaque utilisateur. Je voudrais récupérer le "EmployeeID" de l'utilisateur actuel en utilisant emcascript mais je n'arrive pas à comprendre comment.sharepoint 2010 Propriété du profil utilisateur ecmascript

 ExecuteOrDelayUntilScriptLoaded(getWebUserData, "sp.js"); 
     var context = null; 
     var web = null; 
     var currentUser = null; 

     function getWebUserData() {  
      context = new SP.ClientContext.get_current(); 
      web = context.get_web(); 
      currentUser = web.get_currentUser(); 
      currentUser.retrieve(); 
      context.load(web); 
      context.executeQueryAsync(Function.createDelegate(this, this.onSuccessMethod), Function.createDelegate(this, this.onFailureMethod)); 
     } 
     function onSuccessMethod(sender, args) { 
      var currentUser= web.get_currentUser(); 
// how to get employeeID user profile property? 

     } 
     function onFailureMethod(sender, args) { 
      alert('Unable to find your user information.'); 
     } 

Répondre

Questions connexes