Office365-REST-Python-Client 2.4.2__py3-none-any.whl → 2.4.4__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.4.2.dist-info → Office365_REST_Python_Client-2.4.4.dist-info}/METADATA +65 -31
- {Office365_REST_Python_Client-2.4.2.dist-info → Office365_REST_Python_Client-2.4.4.dist-info}/RECORD +401 -259
- office365/base_item.py +27 -5
- office365/booking/business.py +7 -0
- office365/booking/currency.py +5 -0
- office365/booking/solutions_root.py +32 -0
- office365/communications/calls/invitation_participant_info.py +17 -1
- office365/communications/calls/options.py +9 -0
- office365/communications/onlinemeetings/provider_type.py +3 -0
- office365/communications/presences/presence.py +14 -0
- office365/communications/presences/status_message.py +12 -0
- office365/directory/administrative_unit.py +22 -0
- office365/directory/applications/collection.py +2 -1
- office365/directory/applications/roles/assignment.py +45 -5
- office365/directory/applications/roles/assignment_collection.py +8 -0
- office365/directory/applications/roles/role.py +6 -1
- office365/directory/audit/signins/activity.py +31 -0
- office365/directory/audit/signins/location.py +17 -0
- office365/directory/audit/signins/signin.py +33 -0
- office365/directory/authentication/authentication.py +9 -0
- office365/directory/authentication/methods/details.py +25 -0
- office365/directory/authentication/methods/email.py +16 -0
- office365/directory/authentication/methods/root.py +27 -0
- office365/directory/certificates/authority.py +6 -1
- office365/directory/extensions/extended_property.py +8 -1
- office365/directory/extensions/extension.py +1 -1
- office365/directory/extensions/extension_property.py +0 -3
- office365/directory/extensions/open_type.py +8 -0
- office365/directory/groups/collection.py +2 -4
- office365/directory/groups/group.py +18 -4
- office365/directory/identities/governance.py +2 -0
- office365/directory/identities/object_identity.py +3 -3
- office365/directory/insights/resource_reference.py +15 -0
- office365/directory/insights/shared.py +36 -0
- office365/directory/insights/sharing_detail.py +11 -0
- office365/directory/insights/trending.py +8 -0
- office365/directory/insights/usage_details.py +16 -0
- office365/directory/insights/used.py +30 -0
- office365/directory/invitations/invitation.py +33 -1
- office365/directory/licenses/assigned_plan.py +19 -1
- office365/directory/licenses/assignment_state.py +5 -0
- office365/directory/licenses/service_plan_info.py +4 -0
- office365/directory/licenses/subscribed_sku.py +41 -0
- office365/directory/licenses/units_detail.py +11 -0
- office365/directory/object.py +3 -1
- office365/directory/object_collection.py +3 -4
- office365/directory/password_credential.py +5 -1
- office365/directory/permissions/email_identity.py +5 -0
- office365/directory/permissions/grants/condition_set.py +26 -0
- office365/directory/permissions/grants/resource_specific.py +21 -0
- office365/directory/policies/authentication_flows.py +9 -0
- office365/directory/policies/authentication_strength.py +10 -0
- office365/directory/policies/authorization.py +8 -0
- office365/directory/policies/cross_tenant_access.py +5 -0
- office365/directory/policies/root.py +35 -2
- office365/directory/protection/information.py +5 -0
- office365/directory/protection/risk_detection.py +11 -0
- office365/directory/protection/riskyusers/activity.py +5 -0
- office365/directory/protection/riskyusers/collection.py +32 -0
- office365/directory/protection/riskyusers/history_item.py +20 -0
- office365/directory/protection/riskyusers/risky_user.py +26 -0
- office365/directory/protection/root.py +31 -0
- office365/directory/rolemanagement/application.py +35 -0
- office365/directory/{roles → rolemanagement}/management.py +8 -1
- office365/directory/{roles → rolemanagement}/role.py +14 -0
- office365/directory/{roles → rolemanagement}/template.py +8 -0
- office365/directory/rolemanagement/unified_role_assignment.py +45 -0
- office365/directory/rolemanagement/unified_role_definition.py +6 -0
- office365/directory/security/alerts/alert.py +21 -0
- office365/directory/security/alerts/history_state.py +5 -0
- office365/directory/security/attacksimulations/automation.py +21 -0
- office365/directory/security/attacksimulations/automation_run.py +5 -0
- office365/directory/security/attacksimulations/repeat_offender.py +6 -0
- office365/directory/security/attacksimulations/root.py +26 -0
- office365/directory/security/attacksimulations/simulation.py +17 -0
- office365/directory/security/cases/__init__.py +0 -0
- office365/directory/security/cases/ediscovery.py +6 -0
- office365/directory/security/cases/root.py +22 -0
- office365/directory/security/incidents/incident.py +67 -0
- office365/directory/security/security.py +10 -1
- office365/directory/serviceprincipals/service_principal.py +89 -4
- office365/directory/synchronization/__init__.py +0 -0
- office365/directory/synchronization/job.py +16 -0
- office365/directory/synchronization/progress.py +5 -0
- office365/directory/synchronization/status.py +13 -0
- office365/directory/synchronization/synchronization.py +24 -0
- office365/directory/tenant_information.py +17 -0
- office365/directory/tenant_relationship.py +21 -0
- office365/directory/users/activities/activity.py +45 -1
- office365/directory/users/collection.py +8 -0
- office365/directory/users/password_profile.py +18 -2
- office365/directory/users/user.py +254 -29
- office365/entity.py +3 -3
- office365/graph_client.py +64 -12
- office365/intune/audit/actor.py +5 -0
- office365/intune/audit/event.py +21 -24
- office365/intune/audit/event_collection.py +26 -0
- office365/intune/audit/property.py +5 -0
- office365/intune/audit/resource.py +11 -0
- office365/intune/brand.py +6 -0
- office365/intune/devices/compliance/__init__.py +0 -0
- office365/intune/devices/compliance/policy.py +6 -0
- office365/intune/devices/compliance/policy_state.py +5 -0
- office365/intune/devices/data.py +5 -0
- office365/intune/devices/detail.py +10 -0
- office365/intune/devices/enrollment/__init__.py +0 -0
- office365/intune/devices/enrollment/configuration.py +25 -0
- office365/intune/devices/enrollment/configuration_assignment.py +5 -0
- office365/intune/devices/enrollment/limit_configuration.py +5 -0
- office365/intune/devices/managed.py +44 -3
- office365/intune/devices/management/__init__.py +0 -0
- office365/intune/devices/management/management.py +69 -0
- office365/intune/devices/management/reports/__init__.py +0 -0
- office365/intune/devices/management/reports/reports.py +5 -0
- office365/intune/devices/management/settings.py +18 -0
- office365/intune/organizations/branding.py +15 -0
- office365/intune/organizations/organization.py +14 -0
- office365/intune/printing/__init__.py +0 -0
- office365/intune/printing/base.py +11 -0
- office365/intune/printing/capabilities.py +5 -0
- office365/intune/printing/connectors/__init__.py +0 -0
- office365/intune/printing/connectors/connector.py +6 -0
- office365/intune/printing/operations/__init__.py +0 -0
- office365/intune/printing/print.py +24 -0
- office365/intune/printing/printer.py +6 -0
- office365/intune/printing/services/__init__.py +0 -0
- office365/intune/printing/services/endpoint.py +5 -0
- office365/intune/printing/services/service.py +17 -0
- office365/intune/printing/share.py +5 -0
- office365/intune/printing/shares/__init__.py +0 -0
- office365/intune/printing/taskdefinitions/__init__.py +0 -0
- office365/intune/provisioned_plan.py +5 -1
- office365/intune/servicecommunications/__init__.py +0 -0
- office365/intune/servicecommunications/announcement.py +39 -0
- office365/intune/servicecommunications/announcement_base.py +5 -0
- office365/intune/servicecommunications/health/__init__.py +0 -0
- office365/intune/servicecommunications/health/health.py +7 -0
- office365/intune/servicecommunications/issues/__init__.py +0 -0
- office365/intune/servicecommunications/issues/issue.py +29 -0
- office365/intune/servicecommunications/messages/__init__.py +0 -0
- office365/intune/servicecommunications/messages/update.py +10 -0
- office365/intune/termsandconditions/__init__.py +0 -0
- office365/intune/vpp_token.py +10 -0
- office365/onedrive/admin.py +16 -0
- office365/onedrive/columns/content_approval_status.py +5 -0
- office365/onedrive/columns/datetime.py +15 -0
- office365/onedrive/columns/default_value.py +4 -0
- office365/onedrive/columns/definition.py +49 -3
- office365/onedrive/columns/definition_collection.py +17 -6
- office365/onedrive/columns/lookup.py +5 -1
- office365/onedrive/columns/types.py +13 -0
- office365/onedrive/contenttypes/content_type.py +8 -0
- office365/onedrive/driveitems/audio.py +12 -1
- office365/onedrive/driveitems/driveItem.py +147 -69
- office365/onedrive/driveitems/image.py +8 -1
- office365/onedrive/driveitems/item_preview_info.py +20 -2
- office365/onedrive/driveitems/remote_item.py +19 -4
- office365/onedrive/drives/drive.py +7 -1
- office365/onedrive/drives/quota.py +18 -0
- office365/onedrive/drives/recipient.py +4 -0
- office365/onedrive/files/system_info.py +8 -6
- office365/onedrive/folders/folder.py +3 -3
- office365/onedrive/internal/paths/children.py +1 -4
- office365/onedrive/internal/paths/shared.py +7 -2
- office365/onedrive/lists/collection.py +12 -6
- office365/onedrive/lists/list.py +13 -5
- office365/onedrive/operations/long_running.py +7 -0
- office365/onedrive/operations/pending.py +13 -0
- office365/onedrive/operations/pending_content_update.py +5 -0
- office365/onedrive/permissions/collection.py +5 -6
- office365/onedrive/permissions/sharing_link.py +16 -1
- office365/onedrive/sensitivitylabels/__init__.py +0 -0
- office365/onedrive/sensitivitylabels/assignment.py +17 -0
- office365/onedrive/sensitivitylabels/assignment_method.py +4 -0
- office365/onedrive/sensitivitylabels/extract_result.py +13 -0
- office365/onedrive/sharepoint_settings.py +25 -0
- office365/onedrive/sites/sites_with_root.py +11 -1
- office365/onedrive/termstore/groups/collection.py +1 -1
- office365/onedrive/termstore/groups/group.py +1 -0
- office365/onedrive/termstore/sets/collection.py +1 -1
- office365/onenote/operations/operation.py +10 -1
- office365/onenote/resources/resource.py +1 -0
- office365/outlook/calendar/calendar.py +116 -6
- office365/outlook/calendar/dateTimeTimeZone.py +4 -0
- office365/outlook/calendar/email_address.py +7 -0
- office365/outlook/calendar/events/event.py +0 -4
- office365/outlook/calendar/events/reminder.py +22 -3
- office365/outlook/calendar/group.py +0 -2
- office365/outlook/calendar/location_constraint.py +16 -1
- office365/outlook/calendar/meetingtimes/activity_domain.py +10 -0
- office365/outlook/calendar/meetingtimes/suggestion.py +1 -1
- office365/outlook/calendar/meetingtimes/time_constraint.py +18 -0
- office365/outlook/calendar/permissions/__init__.py +0 -0
- office365/outlook/calendar/permissions/collection.py +24 -0
- office365/outlook/calendar/{permission.py → permissions/permission.py} +35 -2
- office365/outlook/calendar/place.py +7 -0
- office365/outlook/calendar/role_type.py +17 -0
- office365/outlook/calendar/schedule/information.py +5 -4
- office365/outlook/calendar/schedule/item.py +20 -1
- office365/outlook/calendar/sharing_message.py +2 -2
- office365/outlook/calendar/time_zone_base.py +3 -0
- office365/outlook/calendar/working_hours.py +17 -1
- office365/outlook/contacts/collection.py +39 -0
- office365/outlook/contacts/contact.py +21 -11
- office365/outlook/geo_coordinates.py +20 -0
- office365/outlook/item.py +5 -4
- office365/outlook/locale_info.py +3 -0
- office365/outlook/mail/automatic_replies_setting.py +14 -0
- office365/outlook/mail/folders/folder.py +52 -3
- office365/outlook/mail/folders/search.py +11 -0
- office365/outlook/mail/importance.py +1 -0
- office365/outlook/mail/item_body.py +3 -0
- office365/outlook/mail/location.py +27 -2
- office365/outlook/mail/location_constraint_item.py +5 -0
- office365/outlook/mail/mailbox_settings.py +13 -1
- office365/outlook/mail/messages/collection.py +7 -0
- office365/outlook/mail/messages/followup_flag.py +21 -0
- office365/outlook/mail/messages/internet_header.py +16 -0
- office365/outlook/mail/messages/message.py +184 -6
- office365/outlook/mail/messages/rules/__init__.py +0 -0
- office365/outlook/mail/messages/rules/actions.py +38 -0
- office365/outlook/mail/messages/rules/predicates.py +5 -0
- office365/outlook/mail/messages/rules/rule.py +32 -0
- office365/outlook/mail/patterned_recurrence.py +14 -1
- office365/outlook/mail/physical_address.py +5 -1
- office365/outlook/mail/recipient.py +3 -0
- office365/outlook/mail/recurrence_pattern.py +18 -1
- office365/outlook/mail/recurrence_range.py +16 -2
- office365/outlook/timezone_information.py +3 -0
- office365/reports/root.py +28 -1
- office365/reports/security/__init__.py +0 -0
- office365/reports/security/root.py +21 -0
- office365/reports/userregistration/__init__.py +0 -0
- office365/reports/userregistration/method_count.py +17 -0
- office365/reports/userregistration/method_summary.py +21 -0
- office365/runtime/auth/authentication_context.py +123 -25
- office365/runtime/auth/client_credential.py +2 -2
- office365/runtime/auth/providers/acs_token_provider.py +6 -3
- office365/runtime/auth/providers/saml_token_provider.py +10 -7
- office365/runtime/auth/token_response.py +3 -3
- office365/runtime/client_object_collection.py +12 -7
- office365/runtime/client_result.py +9 -0
- office365/runtime/client_runtime_context.py +10 -8
- office365/runtime/http/request_options.py +2 -1
- office365/runtime/odata/request.py +4 -4
- office365/runtime/paths/appid.py +2 -1
- office365/runtime/paths/entity.py +2 -2
- office365/{sharepoint/internal/paths/entity.py → runtime/paths/key.py} +5 -3
- office365/runtime/paths/resource_path.py +3 -0
- office365/runtime/types/event_handler.py +6 -0
- office365/search/external/__init__.py +0 -0
- office365/search/external/configuration.py +8 -0
- office365/search/external/connection.py +27 -0
- office365/{external → search/external}/external.py +1 -1
- office365/search/external/search_settings.py +5 -0
- office365/search/query.py +3 -1
- office365/search/request.py +3 -1
- office365/search/sharepoint_onedrive_options.py +3 -0
- office365/search/sort_property.py +9 -0
- office365/sharepoint/activities/client_request.py +4 -1
- office365/sharepoint/activities/logger.py +25 -0
- office365/sharepoint/activities/revision_info.py +9 -0
- office365/sharepoint/addtoonedrive/mount_point.py +25 -0
- office365/sharepoint/addtoonedrive/mounted_folder_info.py +5 -0
- office365/sharepoint/alerts/alert.py +31 -0
- office365/sharepoint/apps/license_collection.py +1 -2
- office365/sharepoint/changes/item.py +14 -0
- office365/sharepoint/client_context.py +91 -30
- office365/sharepoint/clientsidecomponent/component_context_info.py +7 -0
- office365/sharepoint/clientsidecomponent/identifier.py +3 -0
- office365/sharepoint/compliance/tag_info.py +17 -0
- office365/sharepoint/contenttypes/collection.py +6 -7
- office365/sharepoint/contenttypes/content_type.py +49 -1
- office365/sharepoint/contenttypes/fieldlinks/collection.py +5 -6
- office365/sharepoint/features/known_list.py +2 -0
- office365/sharepoint/fields/collection.py +70 -39
- office365/sharepoint/fields/computed.py +5 -2
- office365/sharepoint/fields/creation_information.py +5 -4
- office365/sharepoint/fields/field.py +73 -15
- office365/sharepoint/fields/user.py +3 -3
- office365/sharepoint/files/checked_out_file.py +3 -2
- office365/sharepoint/files/file.py +9 -4
- office365/sharepoint/files/versions/version.py +7 -9
- office365/sharepoint/folders/collection.py +2 -2
- office365/sharepoint/folders/coloring.py +39 -0
- office365/sharepoint/folders/coloring_information.py +15 -0
- office365/sharepoint/folders/folder.py +21 -10
- office365/sharepoint/forms/customization.py +8 -0
- office365/sharepoint/listitems/listitem.py +29 -10
- office365/sharepoint/lists/bloom_filter.py +0 -1
- office365/sharepoint/lists/creation_information.py +18 -4
- office365/sharepoint/lists/list.py +203 -27
- office365/sharepoint/lists/render_data_parameters.py +21 -1
- office365/sharepoint/lists/template_type.py +10 -0
- office365/sharepoint/navigation/configured_metadata_items.py +25 -1
- office365/sharepoint/navigation/metadata_settings.py +6 -4
- office365/sharepoint/permissions/irm/file_settings.py +43 -0
- office365/sharepoint/permissions/securable_object.py +5 -6
- office365/sharepoint/portal/sites/manager.py +5 -6
- office365/sharepoint/portal/userprofiles/documents_shared_with_group.py +3 -0
- office365/sharepoint/publishing/base_custom_property.py +8 -0
- office365/sharepoint/publishing/navigation/structural_navigation_cache_wrapper.py +8 -0
- office365/sharepoint/publishing/pagecopywithassets/__init__.py +0 -0
- office365/sharepoint/publishing/pagecopywithassets/response.py +8 -0
- office365/sharepoint/publishing/pages/campaign_publication.py +7 -0
- office365/sharepoint/publishing/pages/collection.py +1 -1
- office365/sharepoint/publishing/pages/page.py +4 -1
- office365/sharepoint/publishing/pages/reposts/metadata.py +8 -0
- office365/sharepoint/publishing/personmagazine/person_magazine.py +4 -1
- office365/sharepoint/search/administration/tenant_crawl_versions_info_provider.py +8 -1
- office365/sharepoint/search/query/auto_completion_match.py +3 -0
- office365/sharepoint/search/query/property_value.py +18 -0
- office365/sharepoint/search/request.py +16 -2
- office365/sharepoint/sharing/abilities.py +22 -0
- office365/sharepoint/sharing/direct_abilities.py +27 -0
- office365/sharepoint/sharing/link_abilities.py +9 -1
- office365/sharepoint/sharing/links/data.py +26 -1
- office365/sharepoint/sharing/links/info.py +1 -1
- office365/sharepoint/sharing/links/partial_success_response.py +5 -0
- office365/sharepoint/sharing/links/share_settings.py +24 -1
- office365/sharepoint/sharing/object_sharing_information.py +65 -2
- office365/sharepoint/sharing/object_sharing_information_user.py +9 -0
- office365/sharepoint/sharing/object_sharing_settings.py +17 -4
- office365/sharepoint/sharing/principal.py +10 -0
- office365/sharepoint/sharing/securable_object_extensions.py +1 -17
- office365/sharepoint/sharing/site_sharing_report_helper.py +2 -1
- office365/sharepoint/sharing/user_sharing_result.py +18 -8
- office365/sharepoint/sitehealth/result.py +10 -0
- office365/sharepoint/sites/language.py +11 -1
- office365/sharepoint/sites/language_collection.py +1 -0
- office365/sharepoint/sites/site.py +42 -7
- office365/sharepoint/taxonomy/create_xml_parameters.py +22 -15
- office365/sharepoint/taxonomy/field.py +10 -8
- office365/sharepoint/taxonomy/groups/collection.py +8 -1
- office365/sharepoint/taxonomy/groups/group.py +26 -0
- office365/sharepoint/taxonomy/sets/collection.py +15 -0
- office365/sharepoint/taxonomy/sets/name.py +23 -0
- office365/sharepoint/taxonomy/sets/set.py +16 -1
- office365/sharepoint/taxonomy/stores/store.py +0 -8
- office365/sharepoint/tenant/administration/audit/search_request_status.py +8 -0
- office365/sharepoint/tenant/administration/deny_add_and_customize_pages_status.py +3 -0
- office365/sharepoint/tenant/administration/hubsites/permission.py +10 -0
- office365/sharepoint/tenant/administration/sites/properties.py +12 -10
- office365/sharepoint/tenant/administration/tenant.py +2 -1
- office365/sharepoint/tenant/apps/information.py +3 -1
- office365/sharepoint/tenant/management/office365_tenant.py +14 -11
- office365/sharepoint/types/resource_path.py +3 -1
- office365/sharepoint/userprofiles/people_manager.py +0 -2
- office365/sharepoint/userprofiles/sharedwithme/document.py +16 -0
- office365/sharepoint/userprofiles/sharedwithme/document_user.py +12 -0
- office365/sharepoint/userprofiles/sharedwithme/item_collection.py +41 -0
- office365/sharepoint/userprofiles/sharedwithme/items.py +18 -1
- office365/sharepoint/viva/site_manager.py +14 -0
- office365/sharepoint/webhooks/subscription_collection.py +5 -6
- office365/sharepoint/webparts/definition.py +1 -1
- office365/sharepoint/webparts/webpart.py +18 -4
- office365/sharepoint/webs/context_web_information.py +2 -4
- office365/sharepoint/webs/web.py +31 -12
- office365/sharepoint/workflowservices/manager.py +0 -2
- office365/subscriptions/collection.py +42 -0
- office365/subscriptions/subscription.py +120 -2
- office365/teams/apps/catalog.py +23 -0
- office365/teams/associated_info.py +12 -0
- office365/teams/channels/channel.py +2 -3
- office365/teams/channels/collection.py +1 -1
- office365/teams/channels/iIdentity.py +5 -0
- office365/teams/chats/chat.py +12 -2
- office365/teams/chats/collection.py +1 -2
- office365/teams/chats/messages/__init__.py +0 -0
- office365/teams/chats/messages/info.py +14 -0
- office365/teams/chats/{message.py → messages/message.py} +18 -3
- office365/teams/info.py +20 -0
- office365/teams/members/aad_user_conversation.py +2 -2
- office365/teams/members/conversation_collection.py +3 -3
- office365/teams/schedule/change_request.py +4 -2
- office365/teams/schedule/change_tracked_entity.py +11 -2
- office365/teams/summary.py +15 -0
- office365/teams/tabs/configuration.py +12 -1
- office365/teams/tabs/tab.py +0 -1
- office365/teams/team.py +34 -1
- office365/teams/teamwork/__init__.py +0 -0
- office365/teams/teamwork/activity_topic.py +5 -0
- office365/teams/teamwork/tags/__init__.py +0 -0
- office365/teams/teamwork/tags/identity.py +6 -0
- office365/teams/teamwork/tags/member.py +5 -0
- office365/teams/teamwork/tags/tag.py +15 -0
- office365/{directory/security/cases_root.py → teams/viva/employee_experience_user.py} +1 -1
- office365/todo/attachments/session.py +34 -0
- office365/todo/linked_resource.py +10 -1
- office365/todo/tasks/task.py +4 -0
- office365/directory/identities/protection_root.py +0 -5
- office365/directory/rbac/application.py +0 -18
- office365/directory/rbac/unified_role_assignment.py +0 -8
- office365/external/connection.py +0 -5
- office365/intune/devices/management.py +0 -35
- office365/onedrive/internal/queries/download_content.py +0 -26
- office365/onedrive/internal/queries/upload_content.py +0 -23
- office365/outlook/mail/messages/message_rule.py +0 -15
- office365/runtime/auth/providers/oauth_token_provider.py +0 -25
- office365/teams/team_info.py +0 -6
- {Office365_REST_Python_Client-2.4.2.dist-info → Office365_REST_Python_Client-2.4.4.dist-info}/LICENSE +0 -0
- {Office365_REST_Python_Client-2.4.2.dist-info → Office365_REST_Python_Client-2.4.4.dist-info}/WHEEL +0 -0
- {Office365_REST_Python_Client-2.4.2.dist-info → Office365_REST_Python_Client-2.4.4.dist-info}/top_level.txt +0 -0
- /office365/{directory/rbac → booking}/__init__.py +0 -0
- /office365/directory/{roles → protection}/__init__.py +0 -0
- /office365/{external → directory/protection/riskyusers}/__init__.py +0 -0
- /office365/{teams/messages → directory/rolemanagement}/__init__.py +0 -0
- /office365/outlook/calendar/{time_slot.py → meetingtimes/time_slot.py} +0 -0
- /office365/teams/chats/{message_attachment.py → messages/attachment.py} +0 -0
- /office365/teams/{member_settings.py → members/settings.py} +0 -0
- /office365/teams/{user_teamwork.py → teamwork/user.py} +0 -0
|
@@ -1,8 +1,33 @@
|
|
|
1
|
+
from office365.runtime.queries.service_operation import ServiceOperationQuery
|
|
1
2
|
from office365.sharepoint.base_entity import BaseEntity
|
|
2
3
|
|
|
3
4
|
|
|
4
5
|
class ActivityLogger(BaseEntity):
|
|
5
6
|
|
|
7
|
+
def log_activity(self, operation, list_id, list_item_unique_id, affected_resource_url, item_type,
|
|
8
|
+
audit_creation_time, is_offline):
|
|
9
|
+
"""
|
|
10
|
+
:param str operation:
|
|
11
|
+
:param str list_id:
|
|
12
|
+
:param str list_item_unique_id:
|
|
13
|
+
:param str affected_resource_url:
|
|
14
|
+
:param str item_type:
|
|
15
|
+
:param str audit_creation_time:
|
|
16
|
+
:param bool is_offline:
|
|
17
|
+
"""
|
|
18
|
+
payload = {
|
|
19
|
+
"Operation": operation,
|
|
20
|
+
"ListId": list_id,
|
|
21
|
+
"ListItemUniqueId": list_item_unique_id,
|
|
22
|
+
"AffectedResourceUrl": affected_resource_url,
|
|
23
|
+
"ItemType": item_type,
|
|
24
|
+
"AuditCreationTime": audit_creation_time,
|
|
25
|
+
"IsOffline": is_offline
|
|
26
|
+
}
|
|
27
|
+
qry = ServiceOperationQuery(self, "LogActivity", None, payload)
|
|
28
|
+
self.context.add_query(qry)
|
|
29
|
+
return self
|
|
30
|
+
|
|
6
31
|
@property
|
|
7
32
|
def entity_type_name(self):
|
|
8
33
|
return "Microsoft.SharePoint.Internal.ActivityLogger"
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
from office365.runtime.queries.service_operation import ServiceOperationQuery
|
|
2
|
+
from office365.sharepoint.addtoonedrive.mounted_folder_info import MountedFolderInfo
|
|
3
|
+
from office365.sharepoint.base_entity import BaseEntity
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
class MountPoint(BaseEntity):
|
|
7
|
+
""""""
|
|
8
|
+
|
|
9
|
+
@staticmethod
|
|
10
|
+
def get_mounted_folder_info(context, target_site_id, target_web_id, target_unique_id):
|
|
11
|
+
"""
|
|
12
|
+
:type context: office365.sharepoint.client_context.ClientContext
|
|
13
|
+
:param str target_site_id:
|
|
14
|
+
:param str target_web_id:
|
|
15
|
+
:param str target_unique_id:
|
|
16
|
+
"""
|
|
17
|
+
return_type = MountedFolderInfo(context)
|
|
18
|
+
payload = {
|
|
19
|
+
"targetSiteId": target_site_id,
|
|
20
|
+
"targetWebId": target_web_id,
|
|
21
|
+
"targetUniqueId": target_unique_id
|
|
22
|
+
}
|
|
23
|
+
qry = ServiceOperationQuery(context.web, "GetMountedFolderInfo", None, payload, None, return_type, True)
|
|
24
|
+
context.add_query(qry)
|
|
25
|
+
return return_type
|
|
@@ -12,6 +12,37 @@ class Alert(BaseEntity):
|
|
|
12
12
|
set for this type.
|
|
13
13
|
"""
|
|
14
14
|
|
|
15
|
+
@property
|
|
16
|
+
def alert_frequency(self):
|
|
17
|
+
"""
|
|
18
|
+
Gets the time interval for sending the alert.
|
|
19
|
+
:rtype: int
|
|
20
|
+
"""
|
|
21
|
+
return self.properties.get("AlertFrequency", None)
|
|
22
|
+
|
|
23
|
+
@property
|
|
24
|
+
def alert_template_name(self):
|
|
25
|
+
"""
|
|
26
|
+
Gets the string representing the alert template name.
|
|
27
|
+
:rtype: int
|
|
28
|
+
"""
|
|
29
|
+
return self.properties.get("AlertTemplateName", None)
|
|
30
|
+
|
|
31
|
+
@property
|
|
32
|
+
def always_notify(self):
|
|
33
|
+
"""
|
|
34
|
+
Gets a Boolean value that causes daily and weekly alerts to trigger, even if there is no matching event.
|
|
35
|
+
:rtype: bool
|
|
36
|
+
"""
|
|
37
|
+
return self.properties.get("AlwaysNotify", None)
|
|
38
|
+
|
|
39
|
+
@property
|
|
40
|
+
def item(self):
|
|
41
|
+
"""Gets the list item or document to which the alert applies."""
|
|
42
|
+
from office365.sharepoint.listitems.listitem import ListItem
|
|
43
|
+
return self.properties.get('Item',
|
|
44
|
+
ListItem(self.context, ResourcePath("item", self.resource_path)))
|
|
45
|
+
|
|
15
46
|
@property
|
|
16
47
|
def user(self):
|
|
17
48
|
"""Gets user object that represents User for the alert."""
|
|
@@ -6,6 +6,5 @@ from office365.sharepoint.apps.license import AppLicense
|
|
|
6
6
|
class AppLicenseCollection(ClientValue):
|
|
7
7
|
"""Specifies a collection of marketplace licenses."""
|
|
8
8
|
|
|
9
|
-
def __init__(self, items
|
|
9
|
+
def __init__(self, items=ClientValueCollection(AppLicense)):
|
|
10
10
|
self.Items = items
|
|
11
|
-
|
|
@@ -6,6 +6,20 @@ from office365.sharepoint.sharing.shared_with_user import SharedWithUser
|
|
|
6
6
|
class ChangeItem(Change):
|
|
7
7
|
"""A change on an item."""
|
|
8
8
|
|
|
9
|
+
@property
|
|
10
|
+
def activity_type(self):
|
|
11
|
+
"""
|
|
12
|
+
Returns activity type defined in ChangeActivityType
|
|
13
|
+
"""
|
|
14
|
+
return self.properties.get("ActivityType", None)
|
|
15
|
+
|
|
16
|
+
@property
|
|
17
|
+
def content_type_id(self):
|
|
18
|
+
"""
|
|
19
|
+
Specifies an identifier for the content type
|
|
20
|
+
"""
|
|
21
|
+
return self.properties.get("ContentTypeId", None)
|
|
22
|
+
|
|
9
23
|
@property
|
|
10
24
|
def shared_by_user(self):
|
|
11
25
|
"""Return the sharedBy User Information in sharing action for change log."""
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import copy
|
|
2
2
|
|
|
3
3
|
from office365.runtime.auth.authentication_context import AuthenticationContext
|
|
4
|
+
from office365.runtime.auth.client_credential import ClientCredential
|
|
4
5
|
from office365.runtime.auth.user_credential import UserCredential
|
|
5
6
|
from office365.runtime.client_runtime_context import ClientRuntimeContext
|
|
6
7
|
from office365.runtime.compat import urlparse, get_absolute_url
|
|
@@ -22,7 +23,7 @@ from office365.sharepoint.webs.web import Web
|
|
|
22
23
|
|
|
23
24
|
|
|
24
25
|
class ClientContext(ClientRuntimeContext):
|
|
25
|
-
"""SharePoint client context"""
|
|
26
|
+
"""SharePoint client context (used for SharePoint v1 API)"""
|
|
26
27
|
|
|
27
28
|
def __init__(self, base_url, auth_context=None):
|
|
28
29
|
"""
|
|
@@ -43,27 +44,21 @@ class ClientContext(ClientRuntimeContext):
|
|
|
43
44
|
@staticmethod
|
|
44
45
|
def from_url(full_url):
|
|
45
46
|
"""
|
|
46
|
-
Constructs
|
|
47
|
+
Constructs a client from absolute resource url
|
|
47
48
|
|
|
48
|
-
:param str full_url:
|
|
49
|
-
:return: ClientContext
|
|
49
|
+
:param str full_url: Absolute Url to a resource
|
|
50
50
|
"""
|
|
51
51
|
root_site_url = get_absolute_url(full_url)
|
|
52
52
|
ctx = ClientContext(root_site_url)
|
|
53
|
-
result = Web.get_web_url_from_page_url(ctx, full_url)
|
|
54
53
|
|
|
55
|
-
def
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
"""
|
|
59
|
-
resp.raise_for_status()
|
|
60
|
-
ctx._auth_context.url = result.value
|
|
61
|
-
|
|
62
|
-
ctx.after_execute(_init_context_for_web)
|
|
54
|
+
def _init_context(return_type):
|
|
55
|
+
ctx._auth_context.url = return_type.value
|
|
56
|
+
Web.get_web_url_from_page_url(ctx, full_url).after_execute(_init_context)
|
|
63
57
|
return ctx
|
|
64
58
|
|
|
65
59
|
def with_client_certificate(self, tenant, client_id, thumbprint, cert_path=None, private_key=None, scopes=None):
|
|
66
|
-
"""
|
|
60
|
+
"""
|
|
61
|
+
Creates authenticated SharePoint context via certificate credentials
|
|
67
62
|
|
|
68
63
|
:param str tenant: Tenant name
|
|
69
64
|
:param str or None cert_path: Path to A PEM encoded certificate private key.
|
|
@@ -77,21 +72,49 @@ class ClientContext(ClientRuntimeContext):
|
|
|
77
72
|
scopes)
|
|
78
73
|
return self
|
|
79
74
|
|
|
75
|
+
def with_interactive(self, tenant, client_id, scopes=None):
|
|
76
|
+
"""
|
|
77
|
+
Initializes a client to acquire a token interactively i.e. via a local browser.
|
|
78
|
+
|
|
79
|
+
Prerequisite: In Azure Portal, configure the Redirect URI of your
|
|
80
|
+
"Mobile and Desktop application" as ``http://localhost``.
|
|
81
|
+
|
|
82
|
+
:param str tenant: Tenant name, for example: contoso.onmicrosoft.com
|
|
83
|
+
:param str client_id: The OAuth client id of the calling application.
|
|
84
|
+
:param list[str] or None scopes: Scopes requested to access a protected API (a resource)
|
|
85
|
+
"""
|
|
86
|
+
self.authentication_context.with_interactive(tenant, client_id, scopes)
|
|
87
|
+
return self
|
|
88
|
+
|
|
89
|
+
def with_device_flow(self, tenant, client_id, scopes=None):
|
|
90
|
+
"""
|
|
91
|
+
Initializes a client to acquire a token via device flow auth.
|
|
92
|
+
|
|
93
|
+
:param str tenant: Tenant name, for example: contoso.onmicrosoft.com
|
|
94
|
+
:param str client_id: The OAuth client id of the calling application.
|
|
95
|
+
:param list[str] or None scopes: Scopes requested to access a protected API (a resource)
|
|
96
|
+
"""
|
|
97
|
+
self.authentication_context.with_device_flow(tenant, client_id, scopes)
|
|
98
|
+
return self
|
|
99
|
+
|
|
80
100
|
def with_access_token(self, token_func):
|
|
81
101
|
"""
|
|
82
|
-
|
|
102
|
+
Initializes a client to acquire a token from a callback
|
|
103
|
+
|
|
104
|
+
:param () -> TokenResponse token_func: A callback
|
|
83
105
|
"""
|
|
84
106
|
self.authentication_context.with_access_token(token_func)
|
|
85
107
|
return self
|
|
86
108
|
|
|
87
109
|
def with_user_credentials(self, username, password, allow_ntlm=False, browser_mode=False):
|
|
88
110
|
"""
|
|
89
|
-
|
|
111
|
+
Initializes a client to acquire a token via user credentials.
|
|
90
112
|
|
|
91
|
-
|
|
92
|
-
:
|
|
93
|
-
:
|
|
94
|
-
:
|
|
113
|
+
|
|
114
|
+
:param str username: Typically, a UPN in the form of an email address
|
|
115
|
+
:param str password: The password
|
|
116
|
+
:param bool allow_ntlm: Flag indicates whether NTLM scheme is enabled. Disabled by default
|
|
117
|
+
:param bool browser_mode:
|
|
95
118
|
"""
|
|
96
119
|
self.authentication_context.with_credentials(
|
|
97
120
|
UserCredential(username, password),
|
|
@@ -99,9 +122,22 @@ class ClientContext(ClientRuntimeContext):
|
|
|
99
122
|
browser_mode=browser_mode)
|
|
100
123
|
return self
|
|
101
124
|
|
|
125
|
+
def with_client_credentials(self, client_id, client_secret):
|
|
126
|
+
"""
|
|
127
|
+
Initializes a client to acquire a token via client credentials (SharePoint App-Only)
|
|
128
|
+
|
|
129
|
+
SharePoint App-Only is the older, but still very relevant, model of setting up app-principals.
|
|
130
|
+
This model works for both SharePoint Online and SharePoint 2013/2016/2019 on-premises
|
|
131
|
+
|
|
132
|
+
:param str client_id: The OAuth client id of the calling application
|
|
133
|
+
:param str client_secret: Secret string that the application uses to prove its identity when requesting a token
|
|
134
|
+
"""
|
|
135
|
+
self.authentication_context.with_credentials(ClientCredential(client_id, client_secret))
|
|
136
|
+
return self
|
|
137
|
+
|
|
102
138
|
def with_credentials(self, credentials):
|
|
103
139
|
"""
|
|
104
|
-
|
|
140
|
+
Initializes a client to acquire a token via user or client credentials
|
|
105
141
|
|
|
106
142
|
:type credentials: UserCredential or ClientCredential
|
|
107
143
|
"""
|
|
@@ -110,7 +146,7 @@ class ClientContext(ClientRuntimeContext):
|
|
|
110
146
|
|
|
111
147
|
def execute_batch(self, items_per_batch=100):
|
|
112
148
|
"""
|
|
113
|
-
Construct and submit a batch request
|
|
149
|
+
Construct and submit to a server a batch request
|
|
114
150
|
|
|
115
151
|
:param int items_per_batch: Maximum to be selected for bulk operation
|
|
116
152
|
"""
|
|
@@ -143,9 +179,13 @@ class ClientContext(ClientRuntimeContext):
|
|
|
143
179
|
request.set_header('X-RequestDigest', self._ctx_web_info.FormDigestValue)
|
|
144
180
|
|
|
145
181
|
def _get_context_web_information(self):
|
|
146
|
-
"""
|
|
182
|
+
"""
|
|
183
|
+
Returns an ContextWebInformation object that specifies metadata about the site
|
|
184
|
+
"""
|
|
147
185
|
client = ODataRequest(JsonLightFormat())
|
|
148
|
-
|
|
186
|
+
for e in self.pending_request().beforeExecute:
|
|
187
|
+
client.beforeExecute += e
|
|
188
|
+
client.beforeExecute -= self._build_modification_query
|
|
149
189
|
request = RequestOptions("{0}/contextInfo".format(self.service_root_url()))
|
|
150
190
|
request.method = HttpMethod.Post
|
|
151
191
|
response = client.execute_request_direct(request)
|
|
@@ -194,6 +234,10 @@ class ClientContext(ClientRuntimeContext):
|
|
|
194
234
|
return ctx
|
|
195
235
|
|
|
196
236
|
def _authenticate_request(self, request):
|
|
237
|
+
"""
|
|
238
|
+
Authenticate request
|
|
239
|
+
:type request: office365.runtime.http.request_options.RequestOptions
|
|
240
|
+
"""
|
|
197
241
|
self.authentication_context.authenticate_request(request)
|
|
198
242
|
|
|
199
243
|
def _build_modification_query(self, request):
|
|
@@ -205,7 +249,7 @@ class ClientContext(ClientRuntimeContext):
|
|
|
205
249
|
if request.method == HttpMethod.Post:
|
|
206
250
|
self._ensure_form_digest(request)
|
|
207
251
|
# set custom SharePoint control headers
|
|
208
|
-
if isinstance(self.pending_request().
|
|
252
|
+
if isinstance(self.pending_request().json_format, JsonLightFormat):
|
|
209
253
|
if isinstance(self.current_query, DeleteEntityQuery):
|
|
210
254
|
request.ensure_header("X-HTTP-Method", "DELETE")
|
|
211
255
|
request.ensure_header("IF-MATCH", '*')
|
|
@@ -284,9 +328,8 @@ class ClientContext(ClientRuntimeContext):
|
|
|
284
328
|
|
|
285
329
|
@property
|
|
286
330
|
def context_info(self):
|
|
287
|
-
"""
|
|
288
|
-
|
|
289
|
-
:rtype: ContextWebInformation
|
|
331
|
+
"""
|
|
332
|
+
Returns an ContextWebInformation object that specifies metadata about the site
|
|
290
333
|
"""
|
|
291
334
|
if self._ctx_web_info is None:
|
|
292
335
|
self._ctx_web_info = ContextWebInformation()
|
|
@@ -294,20 +337,26 @@ class ClientContext(ClientRuntimeContext):
|
|
|
294
337
|
|
|
295
338
|
@property
|
|
296
339
|
def web(self):
|
|
297
|
-
"""
|
|
340
|
+
"""
|
|
341
|
+
A group of related webpages that is hosted by a server on the World Wide Web or an intranet.
|
|
342
|
+
Each website has its own entry points, metadata, administration settings, and workflows.
|
|
343
|
+
"""
|
|
298
344
|
if not self._web:
|
|
299
345
|
self._web = Web(self)
|
|
300
346
|
return self._web
|
|
301
347
|
|
|
302
348
|
@property
|
|
303
349
|
def site(self):
|
|
304
|
-
"""
|
|
350
|
+
"""
|
|
351
|
+
Represents a collection of sites in a Web application, including a top-level website and all its sub sites.
|
|
352
|
+
"""
|
|
305
353
|
if not self._site:
|
|
306
354
|
self._site = Site(self)
|
|
307
355
|
return self._site
|
|
308
356
|
|
|
309
357
|
@property
|
|
310
358
|
def apps(self):
|
|
359
|
+
""""""
|
|
311
360
|
from office365.sharepoint.apps.app_collection import AppCollection
|
|
312
361
|
return AppCollection(self, ResourcePath("Apps"))
|
|
313
362
|
|
|
@@ -346,6 +395,12 @@ class ClientContext(ClientRuntimeContext):
|
|
|
346
395
|
from office365.sharepoint.contentcenter.machinelearning.models.collection import SPMachineLearningModelCollection
|
|
347
396
|
return SPMachineLearningModelCollection(self, ResourcePath("models"))
|
|
348
397
|
|
|
398
|
+
@property
|
|
399
|
+
def folder_coloring(self):
|
|
400
|
+
"""Alias to FolderColoring"""
|
|
401
|
+
from office365.sharepoint.folders.coloring import FolderColoring
|
|
402
|
+
return FolderColoring(self, ResourcePath("foldercoloring"))
|
|
403
|
+
|
|
349
404
|
@property
|
|
350
405
|
def group_site_manager(self):
|
|
351
406
|
"""Alias to GroupSiteManager"""
|
|
@@ -499,6 +554,11 @@ class ClientContext(ClientRuntimeContext):
|
|
|
499
554
|
from office365.sharepoint.tenant.settings import TenantSettings
|
|
500
555
|
return TenantSettings.current(self)
|
|
501
556
|
|
|
557
|
+
@property
|
|
558
|
+
def viva_site_manager(self):
|
|
559
|
+
from office365.sharepoint.viva.site_manager import VivaSiteManager
|
|
560
|
+
return VivaSiteManager(self)
|
|
561
|
+
|
|
502
562
|
@property
|
|
503
563
|
def workflow_services_manager(self):
|
|
504
564
|
"""Alias to WorkflowServicesManager"""
|
|
@@ -507,6 +567,7 @@ class ClientContext(ClientRuntimeContext):
|
|
|
507
567
|
|
|
508
568
|
@property
|
|
509
569
|
def work_items(self):
|
|
570
|
+
""""""
|
|
510
571
|
from office365.sharepoint.contentcenter.machinelearning.workitems.collection import \
|
|
511
572
|
SPMachineLearningWorkItemCollection
|
|
512
573
|
return SPMachineLearningWorkItemCollection(self, ResourcePath("workitems"))
|
|
@@ -4,6 +4,13 @@ from office365.sharepoint.base_entity import BaseEntity
|
|
|
4
4
|
class ComponentContextInfo(BaseEntity):
|
|
5
5
|
"""This class functions as a wrapper of the ContextInfo object. Reserved for internal use only."""
|
|
6
6
|
|
|
7
|
+
@property
|
|
8
|
+
def serialized_data(self):
|
|
9
|
+
"""
|
|
10
|
+
:rtype: str
|
|
11
|
+
"""
|
|
12
|
+
return self.properties.get("SerializedData", None)
|
|
13
|
+
|
|
7
14
|
@property
|
|
8
15
|
def entity_type_name(self):
|
|
9
16
|
return "Microsoft.SharePoint.Internal.ClientSideComponent.ComponentContextInfo"
|
|
@@ -8,6 +8,9 @@ class SPClientSideComponentIdentifier(ClientValue):
|
|
|
8
8
|
self.id = _id
|
|
9
9
|
self.version = version
|
|
10
10
|
|
|
11
|
+
def __repr__(self):
|
|
12
|
+
return self.id
|
|
13
|
+
|
|
11
14
|
@property
|
|
12
15
|
def entity_type_name(self):
|
|
13
16
|
return "Microsoft.SharePoint.ClientSideComponent.SPClientSideComponentIdentifier"
|
|
@@ -3,6 +3,23 @@ from office365.runtime.client_value import ClientValue
|
|
|
3
3
|
|
|
4
4
|
class ComplianceTagInfo(ClientValue):
|
|
5
5
|
|
|
6
|
+
def __init__(self, is_record=None, is_regulatory=None, should_keep=None, tag_name=None, unified_rule_id=None,
|
|
7
|
+
unified_tag_id=None):
|
|
8
|
+
"""
|
|
9
|
+
:param bool is_record:
|
|
10
|
+
:param bool is_regulatory:
|
|
11
|
+
:param bool should_keep:
|
|
12
|
+
:param str tag_name:
|
|
13
|
+
:param str unified_rule_id:
|
|
14
|
+
:param str unified_tag_id:
|
|
15
|
+
"""
|
|
16
|
+
self.IsRecord = is_record
|
|
17
|
+
self.IsRegulatory = is_regulatory
|
|
18
|
+
self.ShouldKeep = should_keep
|
|
19
|
+
self.TagName = tag_name
|
|
20
|
+
self.UnifiedRuleId = unified_rule_id
|
|
21
|
+
self.UnifiedTagId = unified_tag_id
|
|
22
|
+
|
|
6
23
|
@property
|
|
7
24
|
def entity_type_name(self):
|
|
8
25
|
return "SP.ComplianceFoundation.Models.ComplianceTagInfo"
|
|
@@ -19,7 +19,7 @@ class ContentTypeCollection(BaseEntityCollection):
|
|
|
19
19
|
:param str name: Content type name
|
|
20
20
|
:rtype: ContentType
|
|
21
21
|
"""
|
|
22
|
-
return self.
|
|
22
|
+
return self.single("Name eq '{0}'".format(name))
|
|
23
23
|
|
|
24
24
|
def get_by_id(self, content_type_id):
|
|
25
25
|
"""
|
|
@@ -57,24 +57,23 @@ class ContentTypeCollection(BaseEntityCollection):
|
|
|
57
57
|
:param str group: Specifies the group of the content type
|
|
58
58
|
:param str or ContentType parent_content_type: Specifies the parent content type (string identifier or object)
|
|
59
59
|
"""
|
|
60
|
-
def
|
|
60
|
+
def _create_and_add_query(parent_content_type_id):
|
|
61
61
|
"""
|
|
62
62
|
:type parent_content_type_id: str
|
|
63
63
|
"""
|
|
64
64
|
parameters = ContentTypeEntityData(name, description, group, parent_content_type_id)
|
|
65
65
|
payload = {"parameters": parameters}
|
|
66
|
-
|
|
66
|
+
qry = ServiceOperationQuery(self, "Create", None, payload, None, return_type)
|
|
67
|
+
self.context.add_query(qry)
|
|
67
68
|
|
|
68
69
|
return_type = ContentType(self.context)
|
|
69
70
|
self.add_child(return_type)
|
|
70
71
|
if isinstance(parent_content_type, ContentType):
|
|
71
72
|
def _ct_loaded():
|
|
72
|
-
|
|
73
|
-
self.context.add_query(next_qry)
|
|
73
|
+
_create_and_add_query(parent_content_type.string_id)
|
|
74
74
|
parent_content_type.ensure_property("StringId", _ct_loaded)
|
|
75
75
|
else:
|
|
76
|
-
|
|
77
|
-
self.context.add_query(qry)
|
|
76
|
+
_create_and_add_query(parent_content_type)
|
|
78
77
|
return return_type
|
|
79
78
|
|
|
80
79
|
def add_available_content_type(self, content_type_id):
|
|
@@ -9,7 +9,13 @@ from office365.sharepoint.translation.user_resource import UserResource
|
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
class ContentType(BaseEntity):
|
|
12
|
-
"""
|
|
12
|
+
"""
|
|
13
|
+
Specifies a content type.
|
|
14
|
+
|
|
15
|
+
A named and uniquely identifiable collection of settings and fields that store metadata for individual items
|
|
16
|
+
in a SharePoint list. One or more content types can be associated with a list, which restricts the contents
|
|
17
|
+
to items of those types
|
|
18
|
+
"""
|
|
13
19
|
|
|
14
20
|
def reorder_fields(self, field_names):
|
|
15
21
|
"""
|
|
@@ -39,6 +45,30 @@ class ContentType(BaseEntity):
|
|
|
39
45
|
self.context.add_query(qry)
|
|
40
46
|
return self
|
|
41
47
|
|
|
48
|
+
@property
|
|
49
|
+
def client_form_custom_formatter(self):
|
|
50
|
+
"""
|
|
51
|
+
:rtype: str
|
|
52
|
+
"""
|
|
53
|
+
return self.properties.get("ClientFormCustomFormatter", None)
|
|
54
|
+
|
|
55
|
+
@property
|
|
56
|
+
def display_form_client_side_component_id(self):
|
|
57
|
+
"""
|
|
58
|
+
The component ID of an SPFx Form Customizer to connect to this content type for usage with display forms.
|
|
59
|
+
:rtype: str
|
|
60
|
+
"""
|
|
61
|
+
return self.properties.get("DisplayFormClientSideComponentId", None)
|
|
62
|
+
|
|
63
|
+
@property
|
|
64
|
+
def display_form_client_side_component_properties(self):
|
|
65
|
+
"""
|
|
66
|
+
The component properties of an SPFx Form Customizer to connect to this content type for usage with display forms
|
|
67
|
+
:rtype: str
|
|
68
|
+
"""
|
|
69
|
+
return self.properties.get("DisplayFormClientSideComponentProperties", None)
|
|
70
|
+
|
|
71
|
+
|
|
42
72
|
@property
|
|
43
73
|
def display_form_template_name(self):
|
|
44
74
|
"""
|
|
@@ -54,6 +84,23 @@ class ContentType(BaseEntity):
|
|
|
54
84
|
"""
|
|
55
85
|
return self.properties.get("DisplayFormUrl", None)
|
|
56
86
|
|
|
87
|
+
@property
|
|
88
|
+
def edit_form_client_side_component_id(self):
|
|
89
|
+
"""
|
|
90
|
+
The component properties of an SPFx Form Customizer to connect to this content type for usage with edit item
|
|
91
|
+
forms
|
|
92
|
+
:rtype: str
|
|
93
|
+
"""
|
|
94
|
+
return self.properties.get("EditFormClientSideComponentId", None)
|
|
95
|
+
|
|
96
|
+
@property
|
|
97
|
+
def edit_form_client_side_component_properties(self):
|
|
98
|
+
"""
|
|
99
|
+
The component ID of an SPFx Form Customizer to connect to this content type for usage with edit item forms
|
|
100
|
+
:rtype: str
|
|
101
|
+
"""
|
|
102
|
+
return self.properties.get("EditFormClientSideComponentProperties", None)
|
|
103
|
+
|
|
57
104
|
@property
|
|
58
105
|
def id(self):
|
|
59
106
|
"""Specifies an identifier for the content type as specified in [MS-WSSTS] section 2.1.2.8.1.
|
|
@@ -85,6 +132,7 @@ class ContentType(BaseEntity):
|
|
|
85
132
|
@property
|
|
86
133
|
def new_form_client_side_component_properties(self):
|
|
87
134
|
"""
|
|
135
|
+
The component properties of an SPFx Form Customizer to connect to this content type for usage with new item forms
|
|
88
136
|
:rtype: str or None
|
|
89
137
|
"""
|
|
90
138
|
return self.properties.get("NewFormClientSideComponentProperties", None)
|
|
@@ -20,23 +20,22 @@ class FieldLinkCollection(BaseEntityCollection):
|
|
|
20
20
|
|
|
21
21
|
:param str or office365.sharepoint.fields.field.Field field: Specifies the internal name of the field or type
|
|
22
22
|
"""
|
|
23
|
-
def
|
|
23
|
+
def _create_and_add_query(field_internal_name):
|
|
24
24
|
"""
|
|
25
25
|
:type field_internal_name: str
|
|
26
26
|
"""
|
|
27
27
|
return_type.set_property("FieldInternalName", field_internal_name)
|
|
28
|
-
|
|
28
|
+
qry = CreateEntityQuery(self, return_type, return_type)
|
|
29
|
+
self.context.add_query(qry)
|
|
29
30
|
|
|
30
31
|
return_type = FieldLink(self.context)
|
|
31
32
|
self.add_child(return_type)
|
|
32
33
|
if isinstance(field, Field):
|
|
33
34
|
def _field_loaded():
|
|
34
|
-
|
|
35
|
-
self.context.add_query(next_qry)
|
|
35
|
+
_create_and_add_query(field.internal_name)
|
|
36
36
|
field.ensure_property("InternalName", _field_loaded)
|
|
37
37
|
else:
|
|
38
|
-
|
|
39
|
-
self.context.add_query(qry)
|
|
38
|
+
_create_and_add_query(field)
|
|
40
39
|
return return_type
|
|
41
40
|
|
|
42
41
|
def get_by_id(self, _id):
|