Office365-REST-Python-Client 2.5.7__py3-none-any.whl → 2.5.9__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {Office365_REST_Python_Client-2.5.7.dist-info → Office365_REST_Python_Client-2.5.9.dist-info}/METADATA +1 -1
- {Office365_REST_Python_Client-2.5.7.dist-info → Office365_REST_Python_Client-2.5.9.dist-info}/RECORD +109 -71
- office365/communications/onlinemeetings/online_meeting.py +30 -3
- office365/communications/onlinemeetings/recordings/__init__.py +0 -0
- office365/communications/onlinemeetings/recordings/call.py +5 -0
- office365/communications/onlinemeetings/transcripts/__init__.py +0 -0
- office365/directory/identitygovernance/entitlementmanagement/entitlement_management.py +7 -0
- office365/directory/identitygovernance/governance.py +16 -0
- office365/directory/serviceprincipals/service_principal.py +110 -21
- office365/graph_client.py +8 -0
- office365/onedrive/driveitems/driveItem.py +51 -5
- office365/onedrive/driveitems/retention_label.py +25 -0
- office365/onedrive/workbooks/charts/chart.py +13 -0
- office365/onedrive/workbooks/icon.py +5 -0
- office365/onedrive/workbooks/names/named_item.py +6 -0
- office365/onedrive/workbooks/ranges/font.py +5 -0
- office365/onedrive/workbooks/ranges/format.py +60 -0
- office365/onedrive/workbooks/ranges/range.py +12 -0
- office365/onedrive/workbooks/ranges/reference.py +6 -0
- office365/onedrive/workbooks/sort_field.py +26 -0
- office365/onedrive/workbooks/tables/pivot_table_collection.py +16 -0
- office365/onedrive/workbooks/worksheets/protection_options.py +3 -0
- office365/onedrive/workbooks/worksheets/worksheet.py +5 -4
- office365/sharepoint/activities/action_facet.py +17 -0
- office365/sharepoint/activities/client_request.py +4 -0
- office365/sharepoint/activities/client_response.py +8 -0
- office365/sharepoint/activities/entity.py +10 -0
- office365/sharepoint/activities/facets/delete.py +1 -0
- office365/sharepoint/activities/facets/get_mention.py +10 -0
- office365/sharepoint/activities/facets/in_doc.py +4 -0
- office365/sharepoint/activities/facets/move.py +14 -0
- office365/sharepoint/activities/facets/point_in_time_restore.py +9 -0
- office365/sharepoint/activities/facets/revision_set.py +9 -0
- office365/sharepoint/activities/facets/task_completed.py +9 -0
- office365/sharepoint/activities/facets/version.py +12 -0
- office365/sharepoint/activities/identity_item.py +16 -1
- office365/sharepoint/alerts/collection.py +12 -0
- office365/sharepoint/attachments/attachment.py +3 -0
- office365/sharepoint/attachments/collection.py +26 -4
- office365/sharepoint/client_context.py +29 -0
- office365/sharepoint/comments/collection.py +1 -1
- office365/sharepoint/compliance/store_proxy.py +43 -0
- office365/sharepoint/directory/provider/alternate_id_data.py +9 -0
- office365/sharepoint/directory/provider/notification.py +15 -0
- office365/sharepoint/directory/provider/object_data.py +14 -0
- office365/sharepoint/directory/provider/provider.py +13 -0
- office365/sharepoint/entity.py +15 -0
- office365/sharepoint/features/collection.py +2 -0
- office365/sharepoint/fields/date_time.py +18 -0
- office365/sharepoint/fields/lookup.py +20 -0
- office365/sharepoint/fields/multi_line_text.py +25 -0
- office365/sharepoint/fields/rating_scale.py +2 -5
- office365/sharepoint/fields/user_value.py +1 -1
- office365/sharepoint/files/collection.py +6 -5
- office365/sharepoint/files/versions/version.py +7 -0
- office365/sharepoint/folders/folder.py +2 -2
- office365/sharepoint/migrationcenter/service/performance/dashboard_data.py +12 -0
- office365/sharepoint/migrationcenter/service/performance/data.py +38 -0
- office365/sharepoint/migrationcenter/service/performance/throughput_data.py +9 -0
- office365/sharepoint/migrationcenter/service/services.py +22 -0
- office365/sharepoint/multigeo/api_versions.py +28 -0
- office365/sharepoint/multigeo/move_job_entity_data.py +9 -0
- office365/sharepoint/multigeo/services.py +39 -0
- office365/sharepoint/multigeo/site_move_job_entity_data.py +9 -0
- office365/sharepoint/multigeo/tenant_information.py +9 -0
- office365/sharepoint/multigeo/user_personal_site_location.py +9 -0
- office365/sharepoint/permissions/securable_object.py +2 -0
- office365/sharepoint/publishing/portal_health_details.py +10 -0
- office365/sharepoint/publishing/portal_health_status.py +8 -1
- office365/sharepoint/sharing/object_sharing_information.py +2 -0
- office365/sharepoint/sharing/permission_collection.py +8 -1
- office365/sharepoint/sharing/shared_document_info.py +28 -0
- office365/sharepoint/sitehealth/summary.py +20 -0
- office365/sharepoint/sites/site.py +12 -0
- office365/sharepoint/sites/version_policy_manager.py +7 -0
- office365/sharepoint/tenant/administration/container_properties.py +17 -0
- office365/sharepoint/tenant/administration/group.py +17 -0
- office365/sharepoint/tenant/administration/powerapps/environment.py +31 -0
- office365/sharepoint/tenant/administration/recent_admin_action_report.py +14 -0
- office365/sharepoint/tenant/administration/recent_admin_action_report_payload.py +10 -0
- office365/sharepoint/tenant/administration/secondary_administrators_info.py +5 -0
- office365/sharepoint/tenant/administration/siteinfo_for_site_picker.py +5 -1
- office365/sharepoint/tenant/administration/sites/creation_default_storage_quota.py +5 -0
- office365/sharepoint/tenant/administration/sites/creation_source.py +16 -1
- office365/sharepoint/tenant/administration/sites/properties_collection.py +2 -0
- office365/sharepoint/tenant/administration/sites/state_properties.py +14 -0
- office365/sharepoint/tenant/administration/tenant.py +56 -1
- office365/sharepoint/tenant/cdn_api.py +16 -0
- office365/sharepoint/tenant/management/externalusers/results/get.py +4 -0
- office365/sharepoint/tenant/management/office365_tenant.py +14 -0
- office365/sharepoint/types/resource_path.py +1 -1
- office365/sharepoint/ui/applicationpages/peoplepicker/web_service_interface.py +39 -33
- office365/sharepoint/userprofiles/cross_geo_sync.py +37 -0
- office365/sharepoint/userprofiles/cross_geo_sync_user_data_batch.py +5 -0
- office365/sharepoint/userprofiles/followed_content.py +15 -0
- office365/sharepoint/userprofiles/people_manager.py +23 -10
- office365/sharepoint/userprofiles/person_properties.py +7 -0
- office365/sharepoint/userprofiles/user_profile.py +4 -6
- office365/sharepoint/views/view.py +3 -1
- office365/sharepoint/views/visualization/__init__.py +0 -0
- office365/sharepoint/views/visualization/field.py +14 -0
- office365/sharepoint/views/visualization/style_set.py +5 -0
- office365/sharepoint/webs/web.py +43 -0
- office365/sharepoint/workflow/manager.py +5 -0
- office365/sharepoint/workflowservices/deployment_service.py +9 -0
- {Office365_REST_Python_Client-2.5.7.dist-info → Office365_REST_Python_Client-2.5.9.dist-info}/LICENSE +0 -0
- {Office365_REST_Python_Client-2.5.7.dist-info → Office365_REST_Python_Client-2.5.9.dist-info}/WHEEL +0 -0
- {Office365_REST_Python_Client-2.5.7.dist-info → Office365_REST_Python_Client-2.5.9.dist-info}/top_level.txt +0 -0
- /office365/sharepoint/views/{visualization.py → visualization/visualization.py} +0 -0
|
@@ -34,6 +34,15 @@ from office365.sharepoint.tenant.administration.insights.onedrive_site_sharing i
|
|
|
34
34
|
from office365.sharepoint.tenant.administration.insights.top_files_sharing import (
|
|
35
35
|
TopFilesSharingInsights,
|
|
36
36
|
)
|
|
37
|
+
from office365.sharepoint.tenant.administration.powerapps.environment import (
|
|
38
|
+
PowerAppsEnvironment,
|
|
39
|
+
)
|
|
40
|
+
from office365.sharepoint.tenant.administration.recent_admin_action_report import (
|
|
41
|
+
RecentAdminActionReport,
|
|
42
|
+
)
|
|
43
|
+
from office365.sharepoint.tenant.administration.recent_admin_action_report_payload import (
|
|
44
|
+
RecentAdminActionReportPayload,
|
|
45
|
+
)
|
|
37
46
|
from office365.sharepoint.tenant.administration.secondary_administrators_fields_data import (
|
|
38
47
|
SecondaryAdministratorsFieldsData,
|
|
39
48
|
)
|
|
@@ -75,6 +84,16 @@ class Tenant(Entity):
|
|
|
75
84
|
)
|
|
76
85
|
super(Tenant, self).__init__(context, static_path)
|
|
77
86
|
|
|
87
|
+
def add_recent_admin_action_report(self):
|
|
88
|
+
""""""
|
|
89
|
+
return_type = ClientResult(self.context, RecentAdminActionReport())
|
|
90
|
+
payload = {"payload": RecentAdminActionReportPayload()}
|
|
91
|
+
qry = ServiceOperationQuery(
|
|
92
|
+
self, "AddRecentAdminActionReport", None, payload, None, return_type
|
|
93
|
+
)
|
|
94
|
+
self.context.add_query(qry)
|
|
95
|
+
return return_type
|
|
96
|
+
|
|
78
97
|
def get_corporate_catalog_site(self):
|
|
79
98
|
"""Retrieves Corporate Catalog Site"""
|
|
80
99
|
settings = TenantSettings.current(self.context)
|
|
@@ -281,13 +300,25 @@ class Tenant(Entity):
|
|
|
281
300
|
|
|
282
301
|
def get_lock_state_by_id(self, site_id):
|
|
283
302
|
"""
|
|
284
|
-
:param str site_id:
|
|
303
|
+
:param str site_id: The GUID to uniquely identify a SharePoint site
|
|
285
304
|
"""
|
|
286
305
|
return self.sites.get_lock_state_by_id(site_id)
|
|
287
306
|
|
|
288
307
|
def hub_sites(self, site_url):
|
|
289
308
|
pass
|
|
290
309
|
|
|
310
|
+
def get_power_apps_environments(self):
|
|
311
|
+
""" """
|
|
312
|
+
return_type = ClientResult(
|
|
313
|
+
self.context,
|
|
314
|
+
ClientValueCollection(PowerAppsEnvironment),
|
|
315
|
+
)
|
|
316
|
+
qry = ServiceOperationQuery(
|
|
317
|
+
self, "GetPowerAppsEnvironments", None, None, None, return_type
|
|
318
|
+
)
|
|
319
|
+
self.context.add_query(qry)
|
|
320
|
+
return return_type
|
|
321
|
+
|
|
291
322
|
def check_tenant_intune_license(self):
|
|
292
323
|
"""
|
|
293
324
|
Checks whether a tenant has the Intune license.
|
|
@@ -587,6 +618,24 @@ class Tenant(Entity):
|
|
|
587
618
|
self.context.add_query(qry)
|
|
588
619
|
return return_type
|
|
589
620
|
|
|
621
|
+
@property
|
|
622
|
+
def admin_settings(self):
|
|
623
|
+
""" """
|
|
624
|
+
from office365.sharepoint.tenant.administration.settings_service import (
|
|
625
|
+
TenantAdminSettingsService,
|
|
626
|
+
)
|
|
627
|
+
|
|
628
|
+
return TenantAdminSettingsService(self.context)
|
|
629
|
+
|
|
630
|
+
@property
|
|
631
|
+
def migration_center(self):
|
|
632
|
+
""" """
|
|
633
|
+
from office365.sharepoint.migrationcenter.service.services import (
|
|
634
|
+
MigrationCenterServices,
|
|
635
|
+
)
|
|
636
|
+
|
|
637
|
+
return MigrationCenterServices(self.context)
|
|
638
|
+
|
|
590
639
|
@property
|
|
591
640
|
def ai_builder_enabled(self):
|
|
592
641
|
# type: () -> Optional[str]
|
|
@@ -656,6 +705,12 @@ class Tenant(Entity):
|
|
|
656
705
|
),
|
|
657
706
|
)
|
|
658
707
|
|
|
708
|
+
@property
|
|
709
|
+
def cdn_api(self):
|
|
710
|
+
from office365.sharepoint.tenant.cdn_api import TenantCdnApi
|
|
711
|
+
|
|
712
|
+
return TenantCdnApi(self.context)
|
|
713
|
+
|
|
659
714
|
@property
|
|
660
715
|
def syntex_billing_subscription_settings(self):
|
|
661
716
|
""""""
|
|
@@ -1,5 +1,9 @@
|
|
|
1
|
+
from office365.runtime.client_result import ClientResult
|
|
2
|
+
from office365.runtime.client_value_collection import ClientValueCollection
|
|
1
3
|
from office365.runtime.paths.resource_path import ResourcePath
|
|
4
|
+
from office365.runtime.queries.service_operation import ServiceOperationQuery
|
|
2
5
|
from office365.sharepoint.entity import Entity
|
|
6
|
+
from office365.sharepoint.tenant.cdn_url import TenantCdnUrl
|
|
3
7
|
|
|
4
8
|
|
|
5
9
|
class TenantCdnApi(Entity):
|
|
@@ -8,6 +12,18 @@ class TenantCdnApi(Entity):
|
|
|
8
12
|
context, ResourcePath("Microsoft.SharePoint.TenantCdn.TenantCdnApi")
|
|
9
13
|
)
|
|
10
14
|
|
|
15
|
+
def get_cdn_urls(self, items=None):
|
|
16
|
+
""""""
|
|
17
|
+
payload = {
|
|
18
|
+
"items": items,
|
|
19
|
+
}
|
|
20
|
+
return_type = ClientResult(self.context, ClientValueCollection(TenantCdnUrl))
|
|
21
|
+
qry = ServiceOperationQuery(
|
|
22
|
+
self, "GetCdnUrls", None, payload, None, return_type
|
|
23
|
+
)
|
|
24
|
+
self.context.add_query(qry)
|
|
25
|
+
return return_type
|
|
26
|
+
|
|
11
27
|
@property
|
|
12
28
|
def entity_type_name(self):
|
|
13
29
|
return "Microsoft.SharePoint.TenantCdn.TenantCdnApi"
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
from typing import Optional
|
|
2
|
+
|
|
1
3
|
from office365.runtime.paths.resource_path import ResourcePath
|
|
2
4
|
from office365.sharepoint.entity import Entity
|
|
3
5
|
from office365.sharepoint.tenant.management.externalusers.collection import (
|
|
@@ -8,10 +10,12 @@ from office365.sharepoint.tenant.management.externalusers.collection import (
|
|
|
8
10
|
class GetExternalUsersResults(Entity):
|
|
9
11
|
@property
|
|
10
12
|
def total_user_count(self):
|
|
13
|
+
# type: () -> Optional[int]
|
|
11
14
|
return self.properties.get("TotalUserCount", None)
|
|
12
15
|
|
|
13
16
|
@property
|
|
14
17
|
def user_collection_position(self):
|
|
18
|
+
# type: () -> Optional[int]
|
|
15
19
|
return self.properties.get("UserCollectionPosition", None)
|
|
16
20
|
|
|
17
21
|
@property
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
from typing import Optional
|
|
2
|
+
|
|
1
3
|
from office365.runtime.client_object_collection import ClientObjectCollection
|
|
2
4
|
from office365.runtime.client_result import ClientResult
|
|
3
5
|
from office365.runtime.client_value_collection import ClientValueCollection
|
|
@@ -29,8 +31,19 @@ class Office365Tenant(Entity):
|
|
|
29
31
|
)
|
|
30
32
|
super(Office365Tenant, self).__init__(context, static_path)
|
|
31
33
|
|
|
34
|
+
@property
|
|
35
|
+
def addressbar_link_permission(self):
|
|
36
|
+
# type: () -> Optional[int]
|
|
37
|
+
return self.properties.get("AddressbarLinkPermission", None)
|
|
38
|
+
|
|
39
|
+
@property
|
|
40
|
+
def allow_comments_text_on_email_enabled(self):
|
|
41
|
+
# type: () -> Optional[bool]
|
|
42
|
+
return self.properties.get("AllowCommentsTextOnEmailEnabled", None)
|
|
43
|
+
|
|
32
44
|
@property
|
|
33
45
|
def allow_editing(self):
|
|
46
|
+
# type: () -> Optional[bool]
|
|
34
47
|
return self.properties.get("AllowEditing", None)
|
|
35
48
|
|
|
36
49
|
@property
|
|
@@ -62,6 +75,7 @@ class Office365Tenant(Entity):
|
|
|
62
75
|
|
|
63
76
|
def disable_sharing_for_non_owners_of_site(self, site_url):
|
|
64
77
|
"""
|
|
78
|
+
Disables Sharing For Non Owners
|
|
65
79
|
:param str site_url:
|
|
66
80
|
"""
|
|
67
81
|
payload = {"siteUrl": site_url}
|
|
@@ -16,39 +16,6 @@ from office365.sharepoint.ui.applicationpages.peoplepicker.query_parameters impo
|
|
|
16
16
|
class ClientPeoplePickerWebServiceInterface(Entity):
|
|
17
17
|
"""Specifies an interface that can be used to query principals."""
|
|
18
18
|
|
|
19
|
-
@staticmethod
|
|
20
|
-
def get_search_results(
|
|
21
|
-
context,
|
|
22
|
-
search_pattern,
|
|
23
|
-
provider_id=None,
|
|
24
|
-
hierarchy_node_id=None,
|
|
25
|
-
entity_types=None,
|
|
26
|
-
):
|
|
27
|
-
"""
|
|
28
|
-
Specifies a JSON formatted CSOM String of principals found in the search.
|
|
29
|
-
|
|
30
|
-
:type context: office365.sharepoint.client_context.ClientContext
|
|
31
|
-
:param str search_pattern: Specifies a pattern used to search for principals.
|
|
32
|
-
The value is implementation-specific.
|
|
33
|
-
:param str provider_id: The identifier of a claims provider.
|
|
34
|
-
:param str hierarchy_node_id: The identifier of a node in the hierarchy. The search MUST be conducted under
|
|
35
|
-
this node.
|
|
36
|
-
:param str entity_types: The type of principals to search for.
|
|
37
|
-
"""
|
|
38
|
-
return_type = ClientResult(context, str())
|
|
39
|
-
payload = {
|
|
40
|
-
"searchPattern": search_pattern,
|
|
41
|
-
"providerID": provider_id,
|
|
42
|
-
"hierarchyNodeID": hierarchy_node_id,
|
|
43
|
-
"entityTypes": entity_types,
|
|
44
|
-
}
|
|
45
|
-
svc = ClientPeoplePickerWebServiceInterface(context)
|
|
46
|
-
qry = ServiceOperationQuery(
|
|
47
|
-
svc, "GetSearchResults", None, payload, None, return_type, True
|
|
48
|
-
)
|
|
49
|
-
context.add_query(qry)
|
|
50
|
-
return return_type
|
|
51
|
-
|
|
52
19
|
@staticmethod
|
|
53
20
|
def get_search_results_by_hierarchy(
|
|
54
21
|
context,
|
|
@@ -167,3 +134,42 @@ class ClientPeoplePickerWebServiceInterface(Entity):
|
|
|
167
134
|
@property
|
|
168
135
|
def entity_type_name(self):
|
|
169
136
|
return "SP.UI.ApplicationPages.ClientPeoplePickerWebServiceInterface"
|
|
137
|
+
|
|
138
|
+
|
|
139
|
+
class PeoplePickerWebServiceInterface(Entity):
|
|
140
|
+
@staticmethod
|
|
141
|
+
def get_search_results(
|
|
142
|
+
context,
|
|
143
|
+
search_pattern,
|
|
144
|
+
provider_id=None,
|
|
145
|
+
hierarchy_node_id=None,
|
|
146
|
+
entity_types=None,
|
|
147
|
+
):
|
|
148
|
+
"""
|
|
149
|
+
Specifies a JSON formatted CSOM String of principals found in the search.
|
|
150
|
+
|
|
151
|
+
:type context: office365.sharepoint.client_context.ClientContext
|
|
152
|
+
:param str search_pattern: Specifies a pattern used to search for principals.
|
|
153
|
+
The value is implementation-specific.
|
|
154
|
+
:param str provider_id: The identifier of a claims provider.
|
|
155
|
+
:param str hierarchy_node_id: The identifier of a node in the hierarchy. The search MUST be conducted under
|
|
156
|
+
this node.
|
|
157
|
+
:param str entity_types: The type of principals to search for.
|
|
158
|
+
"""
|
|
159
|
+
return_type = ClientResult(context, str())
|
|
160
|
+
payload = {
|
|
161
|
+
"searchPattern": search_pattern,
|
|
162
|
+
"providerID": provider_id,
|
|
163
|
+
"hierarchyNodeID": hierarchy_node_id,
|
|
164
|
+
"entityTypes": entity_types,
|
|
165
|
+
}
|
|
166
|
+
svc = PeoplePickerWebServiceInterface(context)
|
|
167
|
+
qry = ServiceOperationQuery(
|
|
168
|
+
svc, "GetSearchResults", None, payload, None, return_type, True
|
|
169
|
+
)
|
|
170
|
+
context.add_query(qry)
|
|
171
|
+
return return_type
|
|
172
|
+
|
|
173
|
+
@property
|
|
174
|
+
def entity_type_name(self):
|
|
175
|
+
return "SP.UI.ApplicationPages.PeoplePickerWebServiceInterface"
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
from office365.runtime.client_result import ClientResult
|
|
2
|
+
from office365.runtime.queries.service_operation import ServiceOperationQuery
|
|
3
|
+
from office365.sharepoint.client_context import ClientContext
|
|
4
|
+
from office365.sharepoint.entity import Entity
|
|
5
|
+
from office365.sharepoint.userprofiles.cross_geo_sync_user_data_batch import (
|
|
6
|
+
CrossGeoSyncUserDataBatch,
|
|
7
|
+
)
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class CrossGeoSync(Entity):
|
|
11
|
+
""""""
|
|
12
|
+
|
|
13
|
+
@staticmethod
|
|
14
|
+
def read_full_changes_batch(context, targetInstanceId, lastRecordId, batchSize):
|
|
15
|
+
# type: (ClientContext, str, str, str) -> ClientResult[CrossGeoSyncUserDataBatch]
|
|
16
|
+
""" """
|
|
17
|
+
payload = {
|
|
18
|
+
"targetInstanceId": targetInstanceId,
|
|
19
|
+
"lastRecordId": lastRecordId,
|
|
20
|
+
"batchSize": batchSize,
|
|
21
|
+
}
|
|
22
|
+
return_type = ClientResult(context, CrossGeoSyncUserDataBatch())
|
|
23
|
+
qry = ServiceOperationQuery(
|
|
24
|
+
CrossGeoSync(context),
|
|
25
|
+
"ReadFullChangesBatch",
|
|
26
|
+
None,
|
|
27
|
+
payload,
|
|
28
|
+
None,
|
|
29
|
+
return_type,
|
|
30
|
+
is_static=True,
|
|
31
|
+
)
|
|
32
|
+
context.add_query(qry)
|
|
33
|
+
return return_type
|
|
34
|
+
|
|
35
|
+
@property
|
|
36
|
+
def entity_type_name(self):
|
|
37
|
+
return "SP.UserProfiles.CrossGeoSync"
|
|
@@ -25,6 +25,21 @@ class FollowedContent(Entity):
|
|
|
25
25
|
self.context.add_query(qry)
|
|
26
26
|
return return_type
|
|
27
27
|
|
|
28
|
+
def get_followed_status(self, url):
|
|
29
|
+
"""
|
|
30
|
+
The GetFollowedStatus method retrieves the followed status of the specified document or site.
|
|
31
|
+
An item can be followed if the url parameter identifies a document or site that the current user has access to.
|
|
32
|
+
|
|
33
|
+
:param str url: URL that identifies the item
|
|
34
|
+
"""
|
|
35
|
+
return_type = ClientResult(self.context, int())
|
|
36
|
+
payload = {"url": url}
|
|
37
|
+
qry = ServiceOperationQuery(
|
|
38
|
+
self, "GetFollowedStatus", None, payload, None, return_type
|
|
39
|
+
)
|
|
40
|
+
self.context.add_query(qry)
|
|
41
|
+
return return_type
|
|
42
|
+
|
|
28
43
|
@property
|
|
29
44
|
def followed_documents_url(self):
|
|
30
45
|
# type: () -> Optional[str]
|
|
@@ -75,18 +75,30 @@ class PeopleManager(Entity):
|
|
|
75
75
|
self.context.add_query(qry)
|
|
76
76
|
return result
|
|
77
77
|
|
|
78
|
-
def get_followers_for(self,
|
|
78
|
+
def get_followers_for(self, account):
|
|
79
|
+
# type: (str|User) -> EntityCollection[PersonProperties]
|
|
79
80
|
"""
|
|
80
81
|
Gets the people who are following the specified user.
|
|
81
82
|
|
|
82
|
-
:param str
|
|
83
|
+
:param str|User account: Account name of the specified user.
|
|
83
84
|
"""
|
|
84
85
|
return_type = EntityCollection(self.context, PersonProperties)
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
86
|
+
|
|
87
|
+
def _get_followers_for(account_name):
|
|
88
|
+
params = {"accountName": account_name}
|
|
89
|
+
qry = ServiceOperationQuery(
|
|
90
|
+
self, "GetFollowersFor", params, None, None, return_type
|
|
91
|
+
)
|
|
92
|
+
self.context.add_query(qry)
|
|
93
|
+
|
|
94
|
+
if isinstance(account, User):
|
|
95
|
+
|
|
96
|
+
def _account_loaded():
|
|
97
|
+
_get_followers_for(account.login_name)
|
|
98
|
+
|
|
99
|
+
account.ensure_property("LoginName", _account_loaded)
|
|
100
|
+
else:
|
|
101
|
+
_get_followers_for(account)
|
|
90
102
|
return return_type
|
|
91
103
|
|
|
92
104
|
def get_user_information(self, account_name, site_id):
|
|
@@ -153,21 +165,22 @@ class PeopleManager(Entity):
|
|
|
153
165
|
_ensure_user(user_or_name, _user_resolved)
|
|
154
166
|
return return_type
|
|
155
167
|
|
|
156
|
-
def get_properties_for(self,
|
|
168
|
+
def get_properties_for(self, account):
|
|
157
169
|
"""
|
|
158
170
|
Gets user properties for the specified user.
|
|
159
|
-
:param str or User
|
|
171
|
+
:param str or User account: Specifies the User object or its login name.
|
|
160
172
|
"""
|
|
161
173
|
return_type = PersonProperties(self.context)
|
|
162
174
|
|
|
163
175
|
def _get_properties_for_inner(account_name):
|
|
176
|
+
# type: (str) -> None
|
|
164
177
|
params = {"accountName": account_name}
|
|
165
178
|
qry = ServiceOperationQuery(
|
|
166
179
|
self, "GetPropertiesFor", params, None, None, return_type
|
|
167
180
|
)
|
|
168
181
|
self.context.add_query(qry)
|
|
169
182
|
|
|
170
|
-
_ensure_user(
|
|
183
|
+
_ensure_user(account, _get_properties_for_inner)
|
|
171
184
|
return return_type
|
|
172
185
|
|
|
173
186
|
def get_default_document_library(
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
from typing import Optional
|
|
2
2
|
|
|
3
|
+
from office365.runtime.odata.type import ODataType
|
|
3
4
|
from office365.runtime.types.collections import StringCollection
|
|
4
5
|
from office365.sharepoint.entity import Entity
|
|
5
6
|
|
|
@@ -79,6 +80,12 @@ class PersonProperties(Entity):
|
|
|
79
80
|
def entity_type_name(self):
|
|
80
81
|
return "SP.UserProfiles.PersonProperties"
|
|
81
82
|
|
|
83
|
+
def set_property(self, k, v, persist_changes=True):
|
|
84
|
+
if k == "UserProfileProperties":
|
|
85
|
+
v = ODataType.parse_key_value_collection(v)
|
|
86
|
+
super(PersonProperties, self).set_property(k, v)
|
|
87
|
+
return self
|
|
88
|
+
|
|
82
89
|
def get_property(self, name, default_value=None):
|
|
83
90
|
if default_value is None:
|
|
84
91
|
property_mapping = {
|
|
@@ -50,9 +50,8 @@ class UserProfile(Entity):
|
|
|
50
50
|
|
|
51
51
|
@property
|
|
52
52
|
def followed_content(self):
|
|
53
|
-
|
|
54
|
-
Gets a FollowedContent object for the user.
|
|
55
|
-
"""
|
|
53
|
+
# type: () -> FollowedContent
|
|
54
|
+
"""Gets a FollowedContent object for the user."""
|
|
56
55
|
return self.properties.get(
|
|
57
56
|
"FollowedContent",
|
|
58
57
|
FollowedContent(
|
|
@@ -62,9 +61,8 @@ class UserProfile(Entity):
|
|
|
62
61
|
|
|
63
62
|
@property
|
|
64
63
|
def personal_site(self):
|
|
65
|
-
|
|
66
|
-
The PersonalSite property specifies the user's personal site
|
|
67
|
-
"""
|
|
64
|
+
# type: () -> Site
|
|
65
|
+
"""The PersonalSite property specifies the user's personal site"""
|
|
68
66
|
return self.properties.get(
|
|
69
67
|
"PersonalSite",
|
|
70
68
|
Site(self.context, ResourcePath("PersonalSite", self.resource_path)),
|
|
@@ -9,7 +9,7 @@ from office365.sharepoint.listitems.caml.query import CamlQuery
|
|
|
9
9
|
from office365.sharepoint.listitems.collection import ListItemCollection
|
|
10
10
|
from office365.sharepoint.types.resource_path import ResourcePath as SPResPath
|
|
11
11
|
from office365.sharepoint.views.field_collection import ViewFieldCollection
|
|
12
|
-
from office365.sharepoint.views.visualization import Visualization
|
|
12
|
+
from office365.sharepoint.views.visualization.visualization import Visualization
|
|
13
13
|
|
|
14
14
|
if TYPE_CHECKING:
|
|
15
15
|
from office365.sharepoint.views.collection import ViewCollection
|
|
@@ -172,6 +172,7 @@ class View(Entity):
|
|
|
172
172
|
|
|
173
173
|
@property
|
|
174
174
|
def view_fields(self):
|
|
175
|
+
# type: () -> ViewFieldCollection
|
|
175
176
|
"""Gets a value that specifies the collection of fields in the list view."""
|
|
176
177
|
return self.properties.get(
|
|
177
178
|
"ViewFields",
|
|
@@ -199,6 +200,7 @@ class View(Entity):
|
|
|
199
200
|
|
|
200
201
|
@property
|
|
201
202
|
def server_relative_path(self):
|
|
203
|
+
# type: () -> Optional[SPResPath]
|
|
202
204
|
"""Gets the server-relative Path of the View."""
|
|
203
205
|
return self.properties.get("ServerRelativePath", SPResPath())
|
|
204
206
|
|
|
File without changes
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
from office365.runtime.client_value import ClientValue
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
class VisualizationField(ClientValue):
|
|
5
|
+
"""Contains CSS properties relating to how an individual field is layed out relative to it's container."""
|
|
6
|
+
|
|
7
|
+
def __init__(self, InternalName=None, Style=None):
|
|
8
|
+
"""
|
|
9
|
+
:param str InternalName: A Property which will specify which set of sub-elements to apply this set of
|
|
10
|
+
CSS properties on.
|
|
11
|
+
:param str Style: CSS properties in serialized JSON format.
|
|
12
|
+
"""
|
|
13
|
+
self.InternalName = InternalName
|
|
14
|
+
self.Style = Style
|
office365/sharepoint/webs/web.py
CHANGED
|
@@ -89,6 +89,7 @@ from office365.sharepoint.sitescripts.serialization_result import (
|
|
|
89
89
|
SiteScriptSerializationResult,
|
|
90
90
|
)
|
|
91
91
|
from office365.sharepoint.sitescripts.utility import SiteScriptUtility
|
|
92
|
+
from office365.sharepoint.translation.resource_entry import SPResourceEntry
|
|
92
93
|
from office365.sharepoint.translation.user_resource import UserResource
|
|
93
94
|
from office365.sharepoint.types.resource_path import ResourcePath as SPResPath
|
|
94
95
|
from office365.sharepoint.ui.applicationpages.peoplepicker.web_service_interface import (
|
|
@@ -1858,12 +1859,52 @@ class Web(SecurableObject):
|
|
|
1858
1859
|
# type: () -> Optional[bool]
|
|
1859
1860
|
return self.properties.get("CustomSiteActionsDisabled", None)
|
|
1860
1861
|
|
|
1862
|
+
@property
|
|
1863
|
+
def description_translations(self):
|
|
1864
|
+
""""""
|
|
1865
|
+
return self.properties.get(
|
|
1866
|
+
"DescriptionTranslations", ClientValueCollection(SPResourceEntry)
|
|
1867
|
+
)
|
|
1868
|
+
|
|
1869
|
+
@property
|
|
1870
|
+
def design_package_id(self):
|
|
1871
|
+
# type: () -> Optional[str]
|
|
1872
|
+
"""Gets or sets the ID of the Design Package used in this SP.Web.
|
|
1873
|
+
|
|
1874
|
+
A value of Guid.Empty will mean that the default Design Package will be used for this SP.Web.
|
|
1875
|
+
The default is determined by the SP.WebTemplate of this SP.Web."""
|
|
1876
|
+
return self.properties.get("DesignPackageId", None)
|
|
1877
|
+
|
|
1878
|
+
@property
|
|
1879
|
+
def disable_app_views(self):
|
|
1880
|
+
# type: () -> Optional[bool]
|
|
1881
|
+
""""""
|
|
1882
|
+
return self.properties.get("DisableAppViews", None)
|
|
1883
|
+
|
|
1884
|
+
@property
|
|
1885
|
+
def disable_flows(self):
|
|
1886
|
+
# type: () -> Optional[bool]
|
|
1887
|
+
""""""
|
|
1888
|
+
return self.properties.get("DisableFlows", None)
|
|
1889
|
+
|
|
1861
1890
|
@property
|
|
1862
1891
|
def id(self):
|
|
1863
1892
|
# type: () -> Optional[str]
|
|
1864
1893
|
"""Specifies the site identifier for the site"""
|
|
1865
1894
|
return self.properties.get("Id", None)
|
|
1866
1895
|
|
|
1896
|
+
@property
|
|
1897
|
+
def language(self):
|
|
1898
|
+
# type: () -> Optional[int]
|
|
1899
|
+
"""Specifies the language code identifier (LCID) for the language that is used on the site"""
|
|
1900
|
+
return self.properties.get("Language", None)
|
|
1901
|
+
|
|
1902
|
+
@property
|
|
1903
|
+
def last_item_modified_date(self):
|
|
1904
|
+
# type: () -> Optional[int]
|
|
1905
|
+
"""Specifies when an item was last modified in the site"""
|
|
1906
|
+
return self.properties.get("LastItemModifiedDate", datetime.datetime.min)
|
|
1907
|
+
|
|
1867
1908
|
@property
|
|
1868
1909
|
def access_requests_list(self):
|
|
1869
1910
|
""""""
|
|
@@ -2421,9 +2462,11 @@ class Web(SecurableObject):
|
|
|
2421
2462
|
"ClientWebParts": self.client_web_parts,
|
|
2422
2463
|
"CurrentUser": self.current_user,
|
|
2423
2464
|
"DescriptionResource": self.description_resource,
|
|
2465
|
+
"DescriptionTranslations": self.description_translations,
|
|
2424
2466
|
"EffectiveBasePermissions": self.effective_base_permissions,
|
|
2425
2467
|
"EventReceivers": self.event_receivers,
|
|
2426
2468
|
"HostedApps": self.hosted_apps,
|
|
2469
|
+
"LastItemModifiedDate": self.last_item_modified_date,
|
|
2427
2470
|
"ListTemplates": self.list_templates,
|
|
2428
2471
|
"MultilingualSettings": self.multilingual_settings,
|
|
2429
2472
|
"OneDriveSharedItems": self.onedrive_shared_items,
|
|
File without changes
|
{Office365_REST_Python_Client-2.5.7.dist-info → Office365_REST_Python_Client-2.5.9.dist-info}/WHEEL
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|