-
-
Notifications
You must be signed in to change notification settings - Fork 340
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
SharePoint API new types and model updates
- Loading branch information
Showing
19 changed files
with
256 additions
and
30 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
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 @@ | ||
""" | ||
Exports a SharePoint List schema | ||
""" | ||
|
||
from office365.sharepoint.client_context import ClientContext | ||
from tests import test_client_credentials, test_team_site_url | ||
|
||
ctx = ClientContext(test_team_site_url).with_credentials(test_client_credentials) | ||
target_list = ( | ||
ctx.web.lists.get_by_title("Site Pages").select(["SchemaXml"]).get().execute_query() | ||
) | ||
print(target_list.schema_xml) |
Large diffs are not rendered by default.
Oops, something went wrong.
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,5 @@ | ||
from office365.runtime.client_value import ClientValue | ||
|
||
|
||
class ServiceStatus(ClientValue): | ||
"""Represents the tenant-level service status of the backup service.""" |
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
10 changes: 10 additions & 0 deletions
10
office365/intune/devices/management/terms_and_conditions.py
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.entity import Entity | ||
|
||
|
||
class TermsAndConditions(Entity): | ||
""" | ||
A termsAndConditions entity represents the metadata and contents of a given Terms and Conditions (T&C) policy. | ||
T&C policies’ contents are presented to users upon their first attempt to enroll into Intune and subsequently | ||
upon edits where an administrator has required re-acceptance. They enable administrators to communicate | ||
the provisions to which a user must agree in order to have devices enrolled into Intune. | ||
""" |
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,8 @@ | ||
from office365.entity import Entity | ||
|
||
|
||
class VirtualEndpoint(Entity): | ||
""" | ||
Use the Cloud PC API to provision and manage virtual desktops for employees in an organization, | ||
or along with the Intune API to manage physical and virtual endpoints. | ||
""" |
Empty file.
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 BrandCenter(Entity): | ||
""" | ||
The SharePoint brand center API offers a centralized branding management application | ||
that empowers your brand managers or designated brand owners to help your organization to customize | ||
the look and feel of their experiences. | ||
""" |
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,5 @@ | ||
from office365.runtime.client_value import ClientValue | ||
|
||
|
||
class BrandCenterConfiguration(ClientValue): | ||
""" """ |
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 |
---|---|---|
@@ -1,15 +1,57 @@ | ||
from office365.runtime.client_value import ClientValue | ||
from office365.runtime.client_value_collection import ClientValueCollection | ||
from office365.sharepoint.translation.resource_entry import SPResourceEntry | ||
|
||
|
||
class MenuNode(ClientValue): | ||
"""Represents a navigation node in the navigation hierarchy. A navigation hierarchy is a tree structure of | ||
navigation nodes.""" | ||
|
||
def __init__(self, current_lcid=None, title=None): | ||
def __init__( | ||
self, | ||
audience_ids=None, | ||
current_lcid=None, | ||
title=None, | ||
is_deleted=None, | ||
is_hidden=None, | ||
key=None, | ||
nodes=None, | ||
node_type=None, | ||
open_in_new_window=None, | ||
simple_url=None, | ||
translations=None, | ||
): | ||
""" | ||
:param list[str] audience_ids: | ||
:param int current_lcid: | ||
:param str title: Specifies the title of the navigation node. The value is in the preferred language of the | ||
user, if available, or is in the default language of the site (2) as a fallback. | ||
:param int node_type: Specifies the type of the navigation node. | ||
:param bool is_deleted: A client MUST use this property set to TRUE to indicate that this node MUST be | ||
deleted by the server. When set to TRUE the server MUST delete the node including all the child nodes | ||
when present. When set to FALSE the server SHOULD NOT delete this node. | ||
:param bool is_hidden: Specifies whether the node will be hidden in the navigation menu. During editing, | ||
all nodes temporarily become visible so that they can be edited. | ||
:param str key: Specifies the identifier for the navigation node in the menu tree. If the navigation node does | ||
not exist on the protocol server, this value MUST be an empty string. | ||
:param list[MenuNode] nodes: | ||
:param bool open_in_new_window: | ||
:param str simple_url: If the NodeType (section 3.2.5.244.1.1.7) property is set to "SimpleLink", | ||
this property represents the URL of the navigation node. The URL can be relative or absolute. | ||
If the value is a relative URL, it can begin with URL tokens "~site" and "~sitecollection". | ||
These tokens indicate that the URL is either relative to the site (2) or to the site collection | ||
respectively. If the NodeType (section 3.2.5.244.1.1.7) property is not set to "SimpleLink", | ||
the value MUST be an empty string. | ||
:param list[SPResourceEntry] translations: | ||
""" | ||
self.AudienceIds = audience_ids | ||
self.CurrentLCID = current_lcid | ||
self.IsDeleted = is_deleted | ||
self.IsHidden = is_hidden | ||
self.Key = key | ||
self.Nodes = ClientValueCollection(MenuNode, nodes) | ||
self.NodeType = node_type | ||
self.OpenInNewWindow = open_in_new_window | ||
self.SimpleUrl = simple_url | ||
self.Title = title | ||
self.Translations = ClientValueCollection(SPResourceEntry, translations) |
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