mirror of
https://github.com/snazy2000/SnipeitPS.git
synced 2025-12-13 18:02:30 +00:00
commit
a69a583429
4 changed files with 6 additions and 5 deletions
|
|
@ -61,7 +61,7 @@ New-SnipeitAsset -status_id 1 -model_id 1 -name "Machine1" -asset_tag "DEV123"
|
||||||
Specifying asset tag when creating asset
|
Specifying asset tag when creating asset
|
||||||
|
|
||||||
.EXAMPLE
|
.EXAMPLE
|
||||||
New-SnipeitAsset -status_id 1 -model_id 1 -name "Machine1" -CustomValues = @{ "_snipeit_os_5" = "Windows 10 Pro" }
|
New-SnipeitAsset -status_id 1 -model_id 1 -name "Machine1" -customfields = @{ "_snipeit_os_5" = "Windows 10 Pro" }
|
||||||
Using customfields when creating asset.
|
Using customfields when creating asset.
|
||||||
#>
|
#>
|
||||||
|
|
||||||
|
|
@ -120,6 +120,7 @@ function New-SnipeitAsset()
|
||||||
[parameter(mandatory = $true)]
|
[parameter(mandatory = $true)]
|
||||||
[string]$apiKey,
|
[string]$apiKey,
|
||||||
|
|
||||||
|
[Alias('CustomValues')]
|
||||||
[hashtable] $customfields
|
[hashtable] $customfields
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -69,7 +69,7 @@
|
||||||
Set-SnipeitAsset -id 1 -status_id 1 -model_id 1 -name "Machine1"
|
Set-SnipeitAsset -id 1 -status_id 1 -model_id 1 -name "Machine1"
|
||||||
|
|
||||||
.EXAMPLE
|
.EXAMPLE
|
||||||
Set-SnipeitAsset -id 1 -status_id 1 -model_id 1 -name "Machine1" -CustomValues = @{ "_snipeit_os_5 = "Windows 10 Pro" }
|
Set-SnipeitAsset -id 1 -name "Machine1" -customfields = @{ "_snipeit_os_5" = "Windows 10 Pro" ; "_snipeit_os_version" = "1909" }
|
||||||
|
|
||||||
.EXAMPLE
|
.EXAMPLE
|
||||||
Get-SnipeitAsset -serial 12345678 | Set-SnipeitAsset -notes 'Just updated'
|
Get-SnipeitAsset -serial 12345678 | Set-SnipeitAsset -notes 'Just updated'
|
||||||
|
|
@ -101,7 +101,6 @@ function Set-SnipeitAsset()
|
||||||
|
|
||||||
[string]$serial,
|
[string]$serial,
|
||||||
|
|
||||||
|
|
||||||
[string]$order_number,
|
[string]$order_number,
|
||||||
|
|
||||||
[int]$warranty_months,
|
[int]$warranty_months,
|
||||||
|
|
@ -127,6 +126,7 @@ function Set-SnipeitAsset()
|
||||||
[parameter(mandatory = $true)]
|
[parameter(mandatory = $true)]
|
||||||
[string]$apiKey,
|
[string]$apiKey,
|
||||||
|
|
||||||
|
[Alias('CustomValues')]
|
||||||
[hashtable] $customfields
|
[hashtable] $customfields
|
||||||
)
|
)
|
||||||
begin{
|
begin{
|
||||||
|
|
|
||||||
|
|
@ -97,7 +97,7 @@ Use internal field names from snipeit .You can use Get-CustomField to get intern
|
||||||
```yaml
|
```yaml
|
||||||
Type: Hashtable
|
Type: Hashtable
|
||||||
Parameter Sets: (All)
|
Parameter Sets: (All)
|
||||||
Aliases:
|
Aliases: CustomValues
|
||||||
|
|
||||||
Required: False
|
Required: False
|
||||||
Position: 16
|
Position: 16
|
||||||
|
|
|
||||||
|
|
@ -110,7 +110,7 @@ Hastable of custom fields and extra fields that need passing through to Snipeit
|
||||||
```yaml
|
```yaml
|
||||||
Type: Hashtable
|
Type: Hashtable
|
||||||
Parameter Sets: (All)
|
Parameter Sets: (All)
|
||||||
Aliases:
|
Aliases: CustomValues
|
||||||
|
|
||||||
Required: False
|
Required: False
|
||||||
Position: 20
|
Position: 20
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue