浏览代码

Remove extraneous argument to GenericRelation

jeremystretch 3 年之前
父节点
当前提交
6415661b61
共有 1 个文件被更改,包括 1 次插入2 次删除
  1. 1 2
      netbox/dcim/models/device_components.py

+ 1 - 2
netbox/dcim/models/device_components.py

@@ -95,8 +95,7 @@ class ModularComponentModel(ComponentModel):
     inventory_items = GenericRelation(
     inventory_items = GenericRelation(
         to='dcim.InventoryItem',
         to='dcim.InventoryItem',
         content_type_field='component_type',
         content_type_field='component_type',
-        object_id_field='component_id',
-        related_name='%(class)ss',
+        object_id_field='component_id'
     )
     )
 
 
     class Meta:
     class Meta: