feat(project): Edit-ProjectItem with rich parameters#202
Conversation
|
|
||
| } Export-ModuleMember -Function Get-ProjectItem -Alias "gpi" | ||
|
|
||
| function Update-ProjectItem { |
Check warning
Code scanning / PSScriptAnalyzer
Function 'Update-ProjectItem' has verb that could change system state. Therefore, the function has to support 'ShouldProcess'. Warning
|
|
||
| } Export-ModuleMember -Function Set-ProjectParameters -Alias "Set-Project","spp" No newline at end of file | ||
| } Export-ModuleMember -Function Set-ProjectParameters -Alias "Set-Project","spp" | ||
|
|
Check warning
Code scanning / PSScriptAnalyzer
The cmdlet 'Get-ProjectParameters' uses a plural noun. A singular noun should be used instead. Warning
| [String[]] GetValidValues() { return @( "Status" ) } | ||
| } | ||
|
|
||
| function Get-ValidNames{ |
Check warning
Code scanning / PSScriptAnalyzer
The cmdlet 'Get-ValidNames' uses a plural noun. A singular noun should be used instead. Warning
| [Parameter()][string]$ProjectNumber, | ||
| [Parameter(Mandatory, Position = 1)][string]$RepoOwner, | ||
| [Parameter(Mandatory, Position = 2)][string]$RepoName, | ||
| [Parameter(Mandatory,ValueFromPipelineByPropertyName, Position = 1)][Alias("Owner")][string]$RepoOwner, |
Check warning
Code scanning / PSScriptAnalyzer
Command accepts pipeline input but has not defined a process block. Warning
| [Parameter(Mandatory, Position = 1)][string]$RepoOwner, | ||
| [Parameter(Mandatory, Position = 2)][string]$RepoName, | ||
| [Parameter(Mandatory,ValueFromPipelineByPropertyName, Position = 1)][Alias("Owner")][string]$RepoOwner, | ||
| [Parameter(Mandatory,ValueFromPipelineByPropertyName, Position = 2)][string]$RepoName, |
Check warning
Code scanning / PSScriptAnalyzer
Command accepts pipeline input but has not defined a process block. Warning
| @@ -0,0 +1,246 @@ | |||
|
|
|||
| class ValidStatus : System.Management.Automation.IValidateSetValuesGenerator { | |||
Check notice
Code scanning / PSScriptAnalyzer
Line has trailing whitespace Note
| $db = Get-Project -Owner $Owner -ProjectNumber $ProjectNumber -ErrorAction SilentlyContinue -skipItems | ||
|
|
||
| $ret.ProjectTitle = $db.title | ||
|
|
Check notice
Code scanning / PSScriptAnalyzer
The cmdlet 'Get-ProjectParameters' returns an object of type 'System.Collections.Hashtable' but this type is not declared in the OutputType attribute. Note
| ProjectTitle = $result.ProjectTitle | ||
| } | ||
| $ret.Owner = $result.Owner | ||
| $ret.ProjectNumber = $result.ProjectNumber |
Check notice
Code scanning / PSScriptAnalyzer
Line has trailing whitespace Note
|
|
||
| } Export-ModuleMember -Function Set-ProjectParameters -Alias "Set-Project","spp" No newline at end of file | ||
| } Export-ModuleMember -Function Set-ProjectParameters -Alias "Set-Project","spp" | ||
|
|
Check notice
Code scanning / PSScriptAnalyzer
The cmdlet 'Get-ProjectParameters' does not have a help comment. Note
| Set-MyInvokeCommandAlias -Alias $EditFileAliasCode -Command 'code -w "{path}"' | ||
| Set-MyInvokeCommandAlias -Alias $EditFileAlias -Command "$MODULE_NAME\Invoke-$($MODULE_NAME)EditFile -Text '{text}'" | ||
|
|
||
| function Invoke-GetLongText{ |
Check notice
Code scanning / PSScriptAnalyzer
The cmdlet 'Invoke-GetLongText' does not have a help comment. Note
Enhance project item management by updating parameter attributes for repository details, adding functions for retrieving project parameters, and editing project items with rich parameters. Fix issues related to function naming and test failures. Update mock data to reflect the current status of project items. Commit messages include:
feat(New-ProjectIssue): update parameter attributes for RepoOwner and RepoName
feat(project): add Update-ProjectItem function for item updates
fix(project): rename Update-ProjectItem function to UpdateProjectItem
fix(mocks): update "Todo" status to "In Progress" in project item fields
fix(database): update alias for GetDatabaseStorePath command and set variable to null
feat(project): add Get-ProjectParameters function to retrieve project details
feat(items): Edit-ProjectItem with rich parameters for standard projects
feat(test): add tests for Edit-ProjectItem functionality
fix(tests): fix test after product changes
refactor(getproject): reorder parameter positions for clarity