ConvertTo-PodeWebPage - add grouping parameters#351
Open
EreminDV wants to merge 2 commits intoBadgerati:developfrom
Open
ConvertTo-PodeWebPage - add grouping parameters#351EreminDV wants to merge 2 commits intoBadgerati:developfrom
EreminDV wants to merge 2 commits intoBadgerati:developfrom
Conversation
add parameter 'Group' to 'ConvertTo-PodeWebPage' as it defined in 'Add-PodeWebPage', group pages by passed key. add parameter 'GroupModule' to 'ConvertTo-PodeWebPage' -- group pages by module name.
ConvertTo-PodeWebPage - add grouping parameters
Badgerati
requested changes
Sep 23, 2022
| } | ||
|
|
||
| 'GroupByVerbs' { | ||
| $group = [string]::Empty |
| switch ($PSCmdlet.ParameterSetName) { | ||
| 'NoGrouping' { | ||
| $group = [string]::Empty | ||
| break |
Owner
There was a problem hiding this comment.
The breaks aren't really needed in this switch statement, since only a single value is being supplied to the switch and not an array.
| } | ||
|
|
||
| 'GroupByCustomKey' { | ||
| $group = $Group -replace "\.","" |
Owner
There was a problem hiding this comment.
I was wondering why you were replacing the dots, but I'm guessing it's because it stops the groups expanding? This looks like the same issue as with spaces.
This line here:
Pode.Web/src/Private/Helpers.ps1
Line 347 in 7db656c
Changing \s to [\s\.] should fix this issue, and mean we can remove these two replace '\.' parts here :)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description of the Change
Related Issue
no, its enhancement
Examples
ConvertTo-PodeWebPage -Module 'Custom.ADHelpers' -Group 'AD Tools'
ConvertTo-PodeWebPage -Module 'DBUtils' -GroupModule
Additional Context
In general, I want to add missing parameter ("group") to 'ConvertTo-PodeWebPage' cmdlet.