Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Use selected object attributes in dependent form fields

Đang mở
#29 0 bình luận 1 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
42/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
python
Lĩnh vực
frontend, web-dev

Hướng nghiên cứu

Start with NetBox's dynamic-selection fields in netbox/utilities/forms/fields/dynamic.py and the related widgets. Trace how query_params currently resolve $variable references and how dependent fields refresh when selections change or clear. Done means a documented, limited attribute syntax supports permitted API attributes, handles missing data predictably, preserves existing behavior, and respects object permissions.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

app: scripts complexity: high status: backlog type: feature
Plugin Version

v0.0.1

Proposed functionality

Allow dynamic query_params references to use a selected object's attribute, not just its ID. For example, $prefix.prefix could supply a selected Prefix's value to an IP address filter.

Define a limited, documented syntax and preserve existing $variable behavior. Allow only permitted attributes from the object's API representation, not arbitrary expressions or unrestricted model traversal.

Refresh dependent fields when the selection changes or is cleared. Handle missing attributes and unavailable objects predictably, without bypassing object permissions.

Use case

Some filters need a prefix, slug, or another value rather than a database ID. Authors should not need custom JavaScript or ask users to re-enter information already available from their selection.

Related request: netbox-community/netbox#23082.

External dependencies

This may need changes to NetBox's dynamic-selection fields and widgets. No new package or service is expected.

Ngôn ngữ chính
Python
Star
8
Fork
0
Merge trung bình
11 giờ 35 phút
Pull request đã merge (30 ngày)
20

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của netbox-community/netbox-scripts

Tất cả issue của netbox-community/netbox-scripts

Issue tương tự

Thêm issue về Python

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.