Skip to content

Commit 242bdda

Browse files
authored
Weight Import Fix (#1187)
* weight schema configuration changes * updated weight/weight unit definitions to compy with import expectations. * updated readme
1 parent 877c1ca commit 242bdda

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

57 files changed

+144
-204
lines changed

README.md

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -64,20 +64,20 @@ The following fields may **optionally** be declared:
6464
- `comments`: A string field which allows for comments to be added to the device. (**Default: None**)
6565
- Type: String
6666
> :test_tube: **Example**: `comments: This is a comment that will appear on all NetBox devices of this type`
67-
- `weight`: An array with a **single** item that allow for a value and unit of measurement to be defined. (**Default: None**)
68-
- Type: Array
69-
- Value: Number - must be multiple of 0.01
70-
- Unit: String
71-
- Options:
72-
- kg
73-
- g
74-
- lb
75-
- oz
67+
- `weight`: A number representing the numeric weight value. Must be a multiple of 0.01 (2 decimal places). (**Default: None**)
68+
- Type: Number
69+
- Value: must be a multiple of 0.01
70+
- `weight_unit`: A string defining the unit of measurement. It must be one of the supported values. (**Default: None**)
71+
- Type: String
72+
- Value: Enumerated Options
73+
- kg
74+
- g
75+
- lb
76+
- oz
7677
>:test_tube: **Example**:
7778
>```
78-
>weight:
79-
> - value: 12.21
80-
> unit: lb
79+
>weight: 12.21
80+
>weight_unit: lb
8181
>```
8282
8383
For further detail on these attributes and those listed below, please reference the

device-types/Adtran/NV4660.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,8 @@ manufacturer: Adtran
33
model: NetVanta 4660
44
slug: nv4660
55
part_number: 17004660F1
6-
weight:
7-
- value: 3.2
8-
unit: kg
6+
weight: 3.2
7+
weight_unit: kg
98
u_height: 1
109
is_full_depth: false
1110
console-ports:

device-types/Cisco/DPC3939B.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: DPC3939B-AMC11-K9
66
u_height: 0
77
is_full_depth: false
88
comments: Comcast Business Gateway Model DPC3939B
9-
weight:
10-
- value: 2.65
11-
unit: lb
9+
weight: 2.65
10+
weight_unit: lb
1211
power-ports:
1312
- name: PS1
1413
type: iec-60320-c8

device-types/Cisco/SPA112.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,8 @@ u_height: 0
77
is_full_depth: false
88
airflow: passive
99
comments: 'There are models with 1 WAN, 1 LAN under a different hardware revision #. [Cisco SPA122 ATA with Router Data Sheet](https://www.cisco.com/c/en/us/products/collateral/unified-communications/small-business-voice-gateways-ata/datasheet_C78-691107.html)'
10-
weight:
11-
- value: 5.4
12-
unit: oz
10+
weight: 5.4
11+
weight_unit: oz
1312
power-ports:
1413
- name: POWER
1514
type: dc-terminal

device-types/Cisco/WS-C2960XR-24TD-I.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,8 @@ slug: cisco-ws-c2960xr-24td-i
55
part_number: WS-C2960XR-24TD-I
66
is_full_depth: false
77
u_height: 1
8-
weight:
9-
- value: 13.0
10-
unit: lb
8+
weight: 13.0
9+
weight_unit: lb
1110
comments: IP Lite feature set (https://www.cisco.com/c/en/us/products/collateral/switches/catalyst-2960-x-series-switches/datasheet_c78-728232.pdf)
1211
airflow: side-to-rear
1312
interfaces:

device-types/Datto/AP440.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: AP440
66
u_height: 0
77
is_full_depth: false
88
comments: '[Datto Access Points](https://www.datto.com/product-assets/wifi/AP840_840E_Datasheet_US.pdf)'
9-
weight:
10-
- value: 1.19
11-
unit: lb
9+
weight: 1.19
10+
weight_unit: lb
1211
power-ports:
1312
- name: DC
1413
type: dc-terminal

device-types/Datto/AP840.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: AP840
66
u_height: 0
77
is_full_depth: false
88
comments: '[Datto Access Points](https://www.datto.com/product-assets/wifi/AP840_840E_Datasheet_US.pdf)'
9-
weight:
10-
- value: 2.03
11-
unit: lb
9+
weight: 2.03
10+
weight_unit: lb
1211
power-ports:
1312
- name: DC
1413
type: dc-terminal

device-types/Datto/AP840E.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: AP840E
66
u_height: 0
77
is_full_depth: false
88
comments: '[Datto Access Points](https://www.datto.com/product-assets/wifi/AP840_840E_Datasheet_US.pdf)'
9-
weight:
10-
- value: 3.55
11-
unit: lb
9+
weight: 3.55
10+
weight_unit: lb
1211
power-ports:
1312
- name: DC
1413
type: dc-terminal

device-types/EnGenius/EWS1200-28TFP.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: EWS1200-28TFP
66
u_height: 1
77
is_full_depth: false
88
comments: "24-Port Managed Gigabit 410W PoE+ Network Switch\r\n\r\nSpecifications: [EWS1200-28TFP](https://www.engeniusnetworks.eu/products/network-switches/ews1200-28tfp/#specification)"
9-
weight:
10-
- value: 3.85
11-
unit: kg
9+
weight: 3.85
10+
weight_unit: kg
1211
power-ports:
1312
- name: Power
1413
type: iec-60320-c14

device-types/EnGenius/EWS360AP.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,8 @@ u_height: 0
77
is_full_depth: false
88
airflow: passive
99
comments: "EWS 11ac Managed Indoor Access Point\r\n\r\nSpecifications: [EWS360AP](https://www.engeniusnetworks.eu/products/wireless/indoor-access-points/ews360ap/#specification)"
10-
weight:
11-
- value: 363
12-
unit: g
10+
weight: 363
11+
weight_unit: g
1312
power-ports:
1413
- name: Power
1514
type: dc-terminal

device-types/EnGenius/EWS5912FP.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: EWS5912FP
66
u_height: 1
77
is_full_depth: false
88
comments: "8-Port Managed Gigabit 130W PoE+ Network Switch\r\n\r\nSpecifications: [EWS5912FP](https://www.engeniusnetworks.eu/products/network-switches/ews5912fp/#specification)"
9-
weight:
10-
- value: 1.9
11-
unit: kg
9+
weight: 1.9
10+
weight_unit: kg
1211
power-ports:
1312
- name: Power
1413
type: iec-60320-c14

device-types/FS/S3150-8T2FP.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,8 @@ is_full_depth: false
77
u_height: 1
88
airflow: passive
99
comments: '[FS S3150 Series Switches Data Sheet](https://www.fs.com/products_support/preview.html?categories_id=3256&files_id=4543&model_name=S3150-8T2FP&is_datasheet=1)'
10-
weight:
11-
- value: 3.7
12-
unit: lb
10+
weight: 3.7
11+
weight_unit: lb
1312
console-ports:
1413
- name: Console
1514
type: rj-45

device-types/Fortinet/FEX-40D.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,8 @@ model: FortiExtender 40D
44
slug: fortinet-fex-40d
55
part_number: FEX-40D
66
u_height: 0
7-
weight:
8-
- value: 0.83
9-
unit: lb
7+
weight: 0.83
8+
weight_unit: lb
109
is_full_depth: false
1110
comments: Built in LTE modem (2 antenna), PoE-capable, Wall-mount.
1211
console-ports:

device-types/Fortinet/FS-1048E.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,8 @@ model: FortiSwitch 1048E
44
slug: fortinet-fs-1048e
55
part_number: FS-1048E
66
u_height: 1
7-
weight:
8-
- value: 18.96
9-
unit: lb
7+
weight: 18.96
8+
weight_unit: lb
109
is_full_depth: false
1110
comments: '[Datasheet](https://www.fortinet.com/content/dam/fortinet/assets/data-sheets/FortiSwitch_Data_Center_Series.pdf)'
1211
airflow: front-to-rear

device-types/Fortinet/FS-424E-FPOE.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,8 @@ model: FortiSwitch 424E-FPOE
44
slug: fortinet-fs-424e-fpoe
55
part_number: FS-424E-FPOE
66
u_height: 1
7-
weight:
8-
- value: 12.72
9-
unit: lb
7+
weight: 12.72
8+
weight_unit: lb
109
is_full_depth: false
1110
comments: '[Datasheet](https://www.fortinet.com/content/dam/fortinet/assets/data-sheets/FortiSwitch_Secure_Access_Series.pdf)'
1211
airflow: side-to-rear

device-types/Fortinet/FS-448D-FPOE.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,8 @@ model: FortiSwitch 448D-FPOE
44
slug: fortinet-fs-448d-fpoe
55
part_number: FS-448D-FPOE
66
u_height: 1
7-
weight:
8-
- value: 15.45
9-
unit: lb
7+
weight: 15.45
8+
weight_unit: lb
109
is_full_depth: false
1110
airflow: side-to-rear
1211
console-ports:

device-types/Fortinet/FS-448D-POE.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,8 @@ model: FortiSwitch 448D-POE
44
slug: fortinet-fs-448d-poe
55
part_number: FS-448D-POE
66
u_height: 1
7-
weight:
8-
- value: 13.44
9-
unit: lb
7+
weight: 13.44
8+
weight_unit: lb
109
is_full_depth: false
1110
airflow: side-to-rear
1211
console-ports:

device-types/HPE/Aruba-2530-24-PoEP.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: J9779A
66
u_height: 1
77
is_full_depth: false
88
comments: '[Aruba 2530 Switch Series - Specifications](https://support.hpe.com/hpesc/public/docDisplay?docId=emr_na-c03624915#N11BE7)'
9-
weight:
10-
- value: 3.8
11-
unit: kg
9+
weight: 3.8
10+
weight_unit: kg
1211
console-ports:
1312
- name: console
1413
type: rj-45

device-types/HPE/Aruba-2530-24.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: J9782A
66
u_height: 1
77
is_full_depth: false
88
comments: '[Aruba 2530 Switch Series - Specifications](https://support.hpe.com/hpesc/public/docDisplay?docId=emr_na-c03624915#N1040D)'
9-
weight:
10-
- value: 2.6
11-
unit: kg
9+
weight: 2.6
10+
weight_unit: kg
1211
power-ports:
1312
- name: PS1
1413
type: iec-60320-c14

device-types/HPE/Aruba-2530-24G-PoEP.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: J9773A
66
u_height: 1
77
is_full_depth: false
88
comments: '[Aruba 2530 Switch Series - Specifications](https://support.hpe.com/hpesc/public/docDisplay?docId=emr_na-c03624915#N127FD)'
9-
weight:
10-
- value: 4
11-
unit: kg
9+
weight: 4
10+
weight_unit: kg
1211
power-ports:
1312
- name: PS1
1413
type: iec-60320-c14

device-types/HPE/Aruba-2530-24G.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: J9776A
66
u_height: 1
77
is_full_depth: false
88
comments: '[Aruba 2530 Switch Series - Specifications](https://support.hpe.com/hpesc/public/docDisplay?docId=emr_na-c03624915#N11007)'
9-
weight:
10-
- value: 6.1
11-
unit: lb
9+
weight: 6.1
10+
weight_unit: lb
1211
power-ports:
1312
- name: PS1
1413
type: iec-60320-c14

device-types/HPE/Aruba-2530-48-PoEP.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: J9778A
66
u_height: 1
77
is_full_depth: false
88
comments: '[Aruba 2530 Switch Series - Specifications](https://support.hpe.com/hpesc/public/docDisplay?docId=emr_na-c03624915#N11FF3)'
9-
weight:
10-
- value: 10
11-
unit: lb
9+
weight: 10
10+
weight_unit: lb
1211
console-ports:
1312
- name: console
1413
type: rj-45

device-types/HPE/Aruba-2530-48.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: J9781A
66
u_height: 1
77
is_full_depth: false
88
comments: '[Aruba 2530 Switch Series - Specifications](https://support.hpe.com/hpesc/public/docDisplay?docId=emr_na-c03624915#N10805)'
9-
weight:
10-
- value: 2.6
11-
unit: kg
9+
weight: 2.6
10+
weight_unit: kg
1211
power-ports:
1312
- name: PS1
1413
type: iec-60320-c14

device-types/HPE/Aruba-2530-48G-PoEP.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: J9772A
66
u_height: 1
77
is_full_depth: false
88
comments: '[Aruba 2530 Switch Series - Specifications](https://support.hpe.com/hpesc/public/docDisplay?docId=emr_na-c03624915#N12C00)'
9-
weight:
10-
- value: 2.6
11-
unit: kg
9+
weight: 2.6
10+
weight_unit: kg
1211
power-ports:
1312
- name: PS1
1413
type: iec-60320-c14

device-types/HPE/Aruba-2530-48G.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: J9775A
66
u_height: 1
77
is_full_depth: false
88
comments: '[Aruba 2530 Switch Series - Specifications](https://support.hpe.com/hpesc/public/docDisplay?docId=emr_na-c03624915#N113F7)'
9-
weight:
10-
- value: 3
11-
unit: kg
9+
weight: 3
10+
weight_unit: kg
1211
power-ports:
1312
- name: PS1
1413
type: iec-60320-c14

device-types/HPE/Aruba-2530-8-PoEP.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: J9780A
66
u_height: 1
77
is_full_depth: false
88
comments: '[Aruba 2530 Switch Series - Specifications](https://support.hpe.com/hpesc/public/docDisplay?docId=emr_na-c03624915#N117E5)'
9-
weight:
10-
- value: 2
11-
unit: lb
9+
weight: 2
10+
weight_unit: lb
1211
console-ports:
1312
- name: console
1413
type: rj-45

device-types/HPE/Aruba-2530-8.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: J9783A
66
u_height: 1
77
is_full_depth: false
88
comments: '[Aruba 2530 Switch Series - Specifications](https://support.hpe.com/hpesc/public/docDisplay?docId=emr_na-c03624915)'
9-
weight:
10-
- value: 0.82
11-
unit: kg
9+
weight: 0.82
10+
weight_unit: kg
1211
power-ports:
1312
- name: PS1
1413
type: dc-terminal

device-types/HPE/Aruba-2530-8G-PoEP.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: J9774A
66
u_height: 1
77
is_full_depth: false
88
comments: '[Aruba 2530 Switch Series - Specifications](https://support.hpe.com/hpesc/public/docDisplay?docId=emr_na-c03624915#N123F6)'
9-
weight:
10-
- value: 1
11-
unit: kg
9+
weight: 1
10+
weight_unit: kg
1211
power-ports:
1312
- name: PS1
1413
type: dc-terminal

device-types/HPE/Aruba-2530-8G.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: J9777A
66
u_height: 1
77
is_full_depth: false
88
comments: '[Aruba 2530 Switch Series - Specifications](https://support.hpe.com/hpesc/public/docDisplay?docId=emr_na-c03624915)'
9-
weight:
10-
- value: 0.91
11-
unit: kg
9+
weight: 0.91
10+
weight_unit: kg
1211
power-ports:
1312
- name: PS1
1413
type: iec-60320-c14

device-types/HPE/Aruba-2930F-24G-4SFP.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: JL259A
66
u_height: 1
77
is_full_depth: false
88
comments: '[Aruba 2930F 24G 4SFP Switch Data sheet](https://www.hpe.com/psnow/doc/PSN1008995548USEN.pdf)'
9-
weight:
10-
- value: 5.31
11-
unit: lb
9+
weight: 5.31
10+
weight_unit: lb
1211
power-ports:
1312
- name: PS1
1413
type: iec-60320-c14

device-types/HPE/Aruba-2930F-24G-PoEP-4SFP.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ part_number: JL261A
66
u_height: 1
77
is_full_depth: false
88
comments: '[Aruba 2930F 24G PoE+ 4SFP Switch Data sheet](https://www.hpe.com/psnow/doc/PSN1008995334USEN.pdf)'
9-
weight:
10-
- value: 8.6
11-
unit: lb
9+
weight: 8.6
10+
weight_unit: lb
1211
power-ports:
1312
- name: PS1
1413
type: iec-60320-c14

0 commit comments

Comments
 (0)