diff --git a/Sharepoint_ToolBox.ps1 b/Sharepoint_ToolBox.ps1 index 6a2c33f..525d25b 100644 --- a/Sharepoint_ToolBox.ps1 +++ b/Sharepoint_ToolBox.ps1 @@ -140,13 +140,13 @@ function Load-Settings { return $data } catch {} } - return [PSCustomObject]@{ dataFolder = "" } + return [PSCustomObject]@{ dataFolder = ""; lang = "en" } } function Save-Settings { - param([string]$DataFolder) + param([string]$DataFolder, [string]$Lang = "en") $path = Get-SettingsFilePath - [PSCustomObject]@{ dataFolder = $DataFolder } | + [PSCustomObject]@{ dataFolder = $DataFolder; lang = $Lang } | ConvertTo-Json | Set-Content $path -Encoding UTF8 } @@ -308,7 +308,7 @@ function Show-SitePicker { $dlg.Controls.AddRange(@($lblFilter, $txtFilter, $btnLoad, $lv, $lblStatus, $btnSelAll, $btnSelNone, $btnOK, $btnDlgCancel)) - # Init script-scope state (modal dialog — no concurrency issue) + # Init script-scope state (modal dialog - no concurrency issue) $script:_pkl = @{ AllSites = @() CheckedUrls = [System.Collections.Generic.HashSet[string]]::new( @@ -483,7 +483,7 @@ function Save-Templates { @{ templates = @($Templates) } | ConvertTo-Json -Depth 20 | Set-Content $path -Encoding UTF8 } -# Script-scope helpers (accessible from all event handlers — no closure tricks) +# Script-scope helpers (accessible from all event handlers - no closure tricks) function _Tpl-Repopulate { $lv = $script:_tpl.Lv $lv.BeginUpdate() @@ -932,7 +932,7 @@ function Show-TemplateManager { rootSiteRel = $srl # site-relative URL of library root folders = @($fld) }) - BgLog " [$($list.BaseType)] $($list.Title) ($srl) — $($fld.Count) dossier(s)" "Cyan" + BgLog " [$($list.BaseType)] $($list.Title) ($srl) - $($fld.Count) dossier(s)" "Cyan" } $result.structure = @($struct) } @@ -954,7 +954,7 @@ function Show-TemplateManager { roles = @($roles) members = @($members) }) - BgLog " Groupe: $($g.Title) — $($members.Count) membre(s)" "Cyan" + BgLog " Groupe: $($g.Title) - $($members.Count) membre(s)" "Cyan" } catch {} } $result.permissions = @($permArr) @@ -1396,7 +1396,7 @@ function Export-PermissionsToHTML { foreach ($mrow in $mergedRows) { $locs = @($mrow.Locations) - # Dominant type badge (use first location's type — entries in a merged group are typically the same type) + # Dominant type badge (use first location's type - entries in a merged group are typically the same type) $dominantType = $locs[0].Object $badgeClass = switch -Regex ($dominantType) { "Site Collection" { "bc"; break } @@ -1525,7 +1525,7 @@ a:hover{text-decoration:underline}
$rows -