Browse Source

fix dropdown sorting

Arthur 2 tháng trước cách đây
mục cha
commit
d18ef98b00
1 tập tin đã thay đổi với 2 bổ sung1 xóa
  1. 2 1
      netbox/dcim/forms/model_forms.py

+ 2 - 1
netbox/dcim/forms/model_forms.py

@@ -745,7 +745,8 @@ class ModuleForm(ModuleCommonForm, PrimaryModelForm):
         label=_('Module bay'),
         queryset=ModuleBay.objects.all(),
         query_params={
-            'device_id': '$device'
+            'device_id': '$device',
+            'ordering': 'name',
         },
         context={
             'disabled': 'installed_module',