Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TeamsEventsPolicy: Add missing attributes #4243

Merged
merged 3 commits into from
Jan 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@
* SPOSharingSettings
* Fixed an Issue where the MySiteSharingCapability could be returned as an
empty string instead of a null value from the Get method.
* TeamsEventsPolicy
* Add missing attributes
FIXES [#4242](https://github.com/microsoft/Microsoft365DSC/issues/4242)
* DEPENDENCIES
* Updated Microsoft.Graph dependencies to version 2.12.0.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,44 @@ function Get-TargetResource
[ValidateSet('Everyone', 'EveryoneInCompanyExcludingGuests')]
$EventAccessType,

[Parameter()]
[ValidateSet('Enabled', 'Disabled')]
[System.String]
$AllowEmailEditing,

[Parameter()]
[System.Boolean]
$AllowEventIntegrations,

[Parameter()]
[ValidateSet('Enabled', 'Disabled')]
[System.String]
$AllowTownhalls,

[Parameter()]
[ValidateSet('DefaultOnly', 'DefaultAndPredefinedOnly', 'AllQuestions')]
[System.String]
$AllowedQuestionTypesInRegistrationForm,

[Parameter()]
[ValidateSet('None', 'InviteOnly', 'EveryoneInCompanyIncludingGuests', 'Everyone')]
[System.String]
$AllowedWebinarTypesForRecordingPublish,

[Parameter()]
[ValidateSet('None', 'InviteOnly', 'EveryoneInCompanyIncludingGuests', 'Everyone')]
[System.String]
$AllowedTownhallTypesForRecordingPublish,

[Parameter()]
[ValidateSet('Optimized', 'None')]
[System.String]
$TownhallChatExperience,

[Parameter()]
[System.Boolean]
$UseMicrosoftECDN,

[Parameter()]
[ValidateSet('Present', 'Absent')]
[System.String]
Expand Down Expand Up @@ -75,15 +113,23 @@ function Get-TargetResource
}
Write-Verbose -Message "Found Teams Events Policy {$Identity}"
$result = @{
Identity = $Identity
Description = $policy.Description
AllowWebinars = $policy.AllowWebinars
EventAccessType = $policy.EventAccessType
Ensure = 'Present'
Credential = $Credential
ApplicationId = $ApplicationId
TenantId = $TenantId
CertificateThumbprint = $CertificateThumbprint
Identity = $Identity
Description = $policy.Description
AllowWebinars = $policy.AllowWebinars
EventAccessType = $policy.EventAccessType
AllowEmailEditing = $policy.AllowEmailEditing
AllowEventIntegrations = $policy.AllowEventIntegrations
AllowTownhalls = $policy.AllowTownhalls
AllowedQuestionTypesInRegistrationForm = $policy.AllowedQuestionTypesInRegistrationForm
AllowedWebinarTypesForRecordingPublish = $policy.AllowedWebinarTypesForRecordingPublish
AllowedTownhallTypesForRecordingPublish = $policy.AllowedTownhallTypesForRecordingPublish
TownhallChatExperience = $policy.TownhallChatExperience
UseMicrosoftECDN = $policy.UseMicrosoftECDN
Ensure = 'Present'
Credential = $Credential
ApplicationId = $ApplicationId
TenantId = $TenantId
CertificateThumbprint = $CertificateThumbprint
}

return $result
Expand Down Expand Up @@ -123,6 +169,44 @@ function Set-TargetResource
[ValidateSet('Everyone', 'EveryoneInCompanyExcludingGuests')]
$EventAccessType,

[Parameter()]
[ValidateSet('Enabled', 'Disabled')]
[System.String]
$AllowEmailEditing,

[Parameter()]
[System.Boolean]
$AllowEventIntegrations,

[Parameter()]
[ValidateSet('Enabled', 'Disabled')]
[System.String]
$AllowTownhalls,

[Parameter()]
[ValidateSet('DefaultOnly', 'DefaultAndPredefinedOnly', 'AllQuestions')]
[System.String]
$AllowedQuestionTypesInRegistrationForm,

[Parameter()]
[ValidateSet('None', 'InviteOnly', 'EveryoneInCompanyIncludingGuests', 'Everyone')]
[System.String]
$AllowedWebinarTypesForRecordingPublish,

[Parameter()]
[ValidateSet('None', 'InviteOnly', 'EveryoneInCompanyIncludingGuests', 'Everyone')]
[System.String]
$AllowedTownhallTypesForRecordingPublish,

[Parameter()]
[ValidateSet('Optimized', 'None')]
[System.String]
$TownhallChatExperience,

[Parameter()]
[System.Boolean]
$UseMicrosoftECDN,

[Parameter()]
[ValidateSet('Present', 'Absent')]
[System.String]
Expand Down Expand Up @@ -212,6 +296,44 @@ function Test-TargetResource
[ValidateSet('Everyone', 'EveryoneInCompanyExcludingGuests')]
$EventAccessType,

[Parameter()]
[ValidateSet('Enabled', 'Disabled')]
[System.String]
$AllowEmailEditing,

[Parameter()]
[System.Boolean]
$AllowEventIntegrations,

[Parameter()]
[ValidateSet('Enabled', 'Disabled')]
[System.String]
$AllowTownhalls,

[Parameter()]
[ValidateSet('DefaultOnly', 'DefaultAndPredefinedOnly', 'AllQuestions')]
[System.String]
$AllowedQuestionTypesInRegistrationForm,

[Parameter()]
[ValidateSet('None', 'InviteOnly', 'EveryoneInCompanyIncludingGuests', 'Everyone')]
[System.String]
$AllowedWebinarTypesForRecordingPublish,

[Parameter()]
[ValidateSet('None', 'InviteOnly', 'EveryoneInCompanyIncludingGuests', 'Everyone')]
[System.String]
$AllowedTownhallTypesForRecordingPublish,

[Parameter()]
[ValidateSet('Optimized', 'None')]
[System.String]
$TownhallChatExperience,

[Parameter()]
[System.Boolean]
$UseMicrosoftECDN,

[Parameter()]
[ValidateSet('Present', 'Absent')]
[System.String]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,17 @@ class MSFT_TeamsEventsPolicy : OMI_BaseResource
{
[Key, Description("Identity of the Teams Events Policy.")] String Identity;
[Write, Description("Description of the Teams Events Policy.")] String Description;
[Write, Description("This setting governs if a user is allowed to edit the communication emails in Teams Town Hall or Teams Webinar events."), ValueMap{"Disabled","Enabled"}, Values{"Disabled","Enabled"}] String AllowEmailEditing;
[Write, Description("This setting governs access to the integrations tab in the event creation workflow.")] Boolean AllowEventIntegrations;
[Write, Description("Determines if webinars are allowed by the policy or not."), ValueMap{"Disabled","Enabled"}, Values{"Disabled","Enabled"}] String AllowWebinars;
[Write, Description("This setting governs if a user can create town halls using Teams Events."), ValueMap{"Disabled","Enabled"}, Values{"Disabled","Enabled"}] String AllowTownhalls;
[Write, Description("This setting governs which users in a tenant can add which registration form questions to an event registration page for attendees to answer when registering for the event."), ValueMap{"DefaultOnly","DefaultAndPredefinedOnly","AllQuestions"}, Values{"DefaultOnly","DefaultAndPredefinedOnly","AllQuestions"}] String AllowedQuestionTypesInRegistrationForm;
[Write, Description("This setting describes how IT admins can control which types of Town Hall attendees can have their recordings published."), ValueMap{"None","InviteOnly","EveryoneInCompanyIncludingGuests","Everyone"}, Values{"None","InviteOnly","EveryoneInCompanyIncludingGuests","Everyone"}] String AllowedTownhallTypesForRecordingPublish;
[Write, Description("This setting describes how IT admins can control which types of webinar attendees can have their recordings published."), ValueMap{"None","InviteOnly","EveryoneInCompanyIncludingGuests","Everyone"}, Values{"None","InviteOnly","EveryoneInCompanyIncludingGuests","Everyone"}] String AllowedWebinarTypesForRecordingPublish;
[Write, Description("Defines who is allowed to join the event."), ValueMap{"Everyone", "EveryoneInCompanyExcludingGuests"}, Values{"Everyone", "EveryoneInCompanyExcludingGuests"}] String EventAccessType;
[Write, Description("Present ensures the policy exists, absent ensures it is removed."), ValueMap{"Present","Absent"}, Values{"Present","Absent"}] String Ensure;
[Write, Description("This setting governs whether the user can enable the Comment Stream chat experience for Town Halls."), ValueMap{"Optimized","None"}, Values{"Optimized","None"}] String TownhallChatExperience;
[Write, Description("This setting governs whether the global admin disables this property and prevents the organizers from creating town halls that use Microsoft eCDN even though they have been assigned a Teams Premium license.")] Boolean UseMicrosoftECDN;
[Write, Description("Credentials of the Teams Global Admin."), EmbeddedInstance("MSFT_Credential")] string Credential;
[Write, Description("Id of the Azure Active Directory application to authenticate with.")] String ApplicationId;
[Write, Description("Name of the Azure Active Directory tenant used for authentication. Format contoso.onmicrosoft.com")] String TenantId;
Expand Down
Loading