2、 分别描述如下: 1、取得当前Sharepoint网站所有的Group //Get All The Site Groups in SharePoint Using ECMAScript var groupCollection; function getAllSiteGroups() { var clientContext = new SP.ClientContext(); this.groupCollection = clientContext.get_
4、ttp://qianming.wan128.cn function onQuerySucceededgetAllSiteGroups() { var groupName = 'Site Groups: '; var groupsEnumerator = this.groupCollection.getEnumerator(); while (groupsEnumerator.moveNext()) { var group = group
6、ssage() + '' + args.get_stackTrace()); } 2、获取当前登录用户的Title与所属Group //retrieve curent loggedin user and the usres GROUP var user; var visitorsGroup; function retrieveCurrLgUserAndGrp() { var clientContext = new SP.ClientContext();
7、 var groupCollection = clientContext.get_web().get_siteGroups(); // Get the visitors group, assuming its ID is 4. visitorsGroup = groupCollection.getById(4); user = clientContext.get_web().get_currentUser(); var userCollectio