Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
SharePoint model updates, activities namespace enhancements
- Loading branch information
Showing
32 changed files
with
414 additions
and
77 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
""" | ||
Gets the people who are following the specified user. | ||
""" | ||
from office365.sharepoint.client_context import ClientContext | ||
from tests import test_client_credentials, test_site_url, test_user_principal_name | ||
|
||
client = ClientContext(test_site_url).with_credentials(test_client_credentials) | ||
user = client.site.root_web.site_users.get_by_email(test_user_principal_name) | ||
|
||
result = client.people_manager.get_followers_for(user).execute_query() | ||
for follower in result: | ||
print(follower) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
from office365.runtime.client_value import ClientValue | ||
from office365.runtime.client_value_collection import ClientValueCollection | ||
from office365.sharepoint.activities.identity import ActivityIdentity | ||
|
||
|
||
class GetMentionFacet(ClientValue): | ||
"""""" | ||
|
||
def __init__(self, mentionees=None): | ||
self.mentionees = ClientValueCollection(ActivityIdentity, mentionees) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
from office365.runtime.client_value import ClientValue | ||
from office365.sharepoint.types.resource_path import ResourcePath as SPResPath | ||
|
||
|
||
class MoveFacet(ClientValue): | ||
"""""" | ||
|
||
def __init__(self, from_=SPResPath(), to=SPResPath()): | ||
self.from_ = from_ | ||
self.to = to | ||
|
||
@property | ||
def entity_type_name(self): | ||
return "Microsoft.SharePoint.Activities.MoveFacet" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
from office365.runtime.client_value import ClientValue | ||
|
||
|
||
class AlternateIdData(ClientValue): | ||
"""""" | ||
|
||
@property | ||
def entity_type_name(self): | ||
return "SP.Directory.Provider.AlternateIdData" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
from office365.runtime.paths.resource_path import ResourcePath | ||
from office365.sharepoint.entity import Entity | ||
|
||
|
||
class DirectoryNotification(Entity): | ||
"""""" | ||
|
||
def __init__(self, context, resource_path=None): | ||
if resource_path is None: | ||
resource_path = ResourcePath("SP.Directory.Provider.DirectoryNotification") | ||
super(DirectoryNotification, self).__init__(context, resource_path) | ||
|
||
@property | ||
def entity_type_name(self): | ||
return "SP.Directory.Provider.DirectoryNotification" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
from office365.runtime.client_value import ClientValue | ||
from office365.sharepoint.directory.provider.alternate_id_data import AlternateIdData | ||
|
||
|
||
class DirectoryObjectData(ClientValue): | ||
"""""" | ||
|
||
def __init__(self, AlternateId=AlternateIdData(), Id=None): | ||
self.AlternateId = AlternateId | ||
self.Id = Id | ||
|
||
@property | ||
def entity_type_name(self): | ||
return "SP.Directory.Provider.DirectoryObjectData" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
from office365.sharepoint.entity import Entity | ||
|
||
|
||
class MoveJobEntityData(Entity): | ||
"""""" | ||
|
||
@property | ||
def entity_type_name(self): | ||
return "Microsoft.Online.SharePoint.MultiGeo.Service.MoveJobEntityData" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
from office365.sharepoint.multigeo.move_job_entity_data import MoveJobEntityData | ||
|
||
|
||
class SiteMoveJobEntityData(MoveJobEntityData): | ||
"""""" | ||
|
||
@property | ||
def entity_type_name(self): | ||
return "Microsoft.Online.SharePoint.MultiGeo.Service.SiteMoveJobEntityData" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
from office365.sharepoint.entity import Entity | ||
|
||
|
||
class UserPersonalSiteLocation(Entity): | ||
"""""" | ||
|
||
@property | ||
def entity_type_name(self): | ||
return "Microsoft.Online.SharePoint.MultiGeo.Service.UserPersonalSiteLocation" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.