diff --git a/Extensions/DocumentationCustom.psm1 b/Extensions/DocumentationCustom.psm1 index f7a3b66..4c9667b 100644 --- a/Extensions/DocumentationCustom.psm1 +++ b/Extensions/DocumentationCustom.psm1 @@ -4624,19 +4624,22 @@ function Invoke-CDDocumentTranslateSectionFile if($obj.'@OData.Type' -eq "#microsoft.graph.windows10CompliancePolicy" -and $fileInfo.BaseName -eq "customcompliance_compliancewindows10") { $category = Get-Category $categoryObj."$($fileInfo.BaseName)".category - + if($null -eq $obj.deviceCompliancePolicyScript) { $propValue = Get-LanguageString "BooleanActions.notConfigured" + $rawValue = "notConfigured" } else { $propValue = Get-LanguageString "BooleanActions.require" + $rawValue = "require" } Add-CustomSettingObject ([PSCustomObject]@{ Name = Get-LanguageString "SettingDetails.adminConfiguredComplianceSettingName" Value = $propValue EntityKey = "deviceCompliancePolicyScript" + RawValue = $rawValue Category = $category SubCategory = $null }) diff --git a/Extensions/DocumentationMD.psm1 b/Extensions/DocumentationMD.psm1 index c267673..3d44495 100644 --- a/Extensions/DocumentationMD.psm1 +++ b/Extensions/DocumentationMD.psm1 @@ -29,6 +29,7 @@ function Add-MDOptionsControl Set-XamlProperty $script:mdForm "chkMDOpenDocument" "IsChecked" (Get-Setting "Documentation" "MDOpenFile" $true) Set-XamlProperty $script:mdForm "cbMDDocumentOutputFile" "ItemsSource" ("[ { Name: `"Single file`",Value: `"Full`" }, { Name: `"One file per object`",Value: `"Object`" }]" | ConvertFrom-Json) Set-XamlProperty $script:mdForm "cbMDDocumentOutputFile" "SelectedValue" (Get-Setting "Documentation" "MDDocumentFileType" "Full") + Set-XamlProperty $script:mdForm "cbMDDocumentSkipDate" "IsChecked" ((Get-Setting "Documentation" "MDDocumentSkipDate" "False") -eq "True") Add-XamlEvent $script:mdForm "browseMDDocumentName" "add_click" { $sf = [System.Windows.Forms.SaveFileDialog]::new() @@ -72,6 +73,7 @@ function Invoke-MDPreProcessItems Save-Setting "Documentation" "MDCSSFile" (Get-XamlProperty $script:mdForm "txtMDCSSFile" "Text" "") Save-Setting "Documentation" "MDOpenFile" (Get-XamlProperty $script:mdForm "chkMDOpenDocument" "IsChecked") Save-Setting "Documentation" "MDDocumentFileType" (Get-XamlProperty $script:mdForm "cbMDDocumentOutputFile" "SelectedValue" '') + Save-Setting "Documentation" "MDDocumentSkipDate" (Get-XamlProperty $script:mdForm "cbMDDocumentSkipDate" "IsChecked") $defaultCSSFile = $global:AppRootFolder + "\Documentation\DefaultMDStyle.css" $MDCssFile = Get-XamlProperty $script:mdForm "txtMDCSSFile" "Text" $defaultCSSFile @@ -142,7 +144,9 @@ function Invoke-MDPostProcessItems $script:mdContent.AppendLine("*Organization:* $($global:Organization.displayName)`n") $script:mdContent.AppendLine("*Generated by:* $userName$mail`n") - $script:mdContent.AppendLine("*Generated:* $((Get-Date).ToShortDateString()) $((Get-Date).ToLongTimeString())`n") + if((Get-XamlProperty $script:mdForm "cbMDDocumentSkipDate" "IsChecked") -ne $true) { + $script:mdContent.AppendLine("*Generated:* $((Get-Date).ToShortDateString()) $((Get-Date).ToLongTimeString())`n") + } if($script:sectionAnchors.Count -gt 0) { diff --git a/Xaml/DocumentationMDOptions.xaml b/Xaml/DocumentationMDOptions.xaml index 3ac80d8..38e8f38 100644 --- a/Xaml/DocumentationMDOptions.xaml +++ b/Xaml/DocumentationMDOptions.xaml @@ -85,4 +85,10 @@ + + + + \ No newline at end of file