-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Custom Field UI - hidden if unset - independent of rw/ro #13299
Comments
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. NetBox is governed by a small group of core maintainers which means not all opened issues may receive direct feedback. Do not attempt to circumvent this process by "bumping" the issue; doing so will result in its immediate closure and you may be barred from participating in any future discussions. Please see our contributing guide. |
I'm going to propose replacing the current
The former will control whether the custom field value can be modified using the web UI; the later will control whether a custom field is displayed in the web UI. As with the current field, neither will have any impact on REST or GraphQL API operation. This will obviously result in a breaking API change, but we'll be able to migrate existing custom fields automatically. |
Thinking about this further, it might make sense to give
Selecting "no" would still include the custom field in the object edit form with a read-only (disabled) widget. Selecting "hidden" would omit it completely. |
I just ran into this yesterday and was surprised that setting a custom field to readonly still showed it in the add/edit form, just in a readonly state. To me, the proposed No and Hidden options for Regardless, the proposed Hidden option would certainly be an improvement over the current situation, as there is apparently no way currently to have a field show in the UI, but not on the edit screen, so if you have big JSON fields that can only set by script/API, you have to keep scrolling over them every time you want to add/edit an object. |
This comment was marked as off-topic.
This comment was marked as off-topic.
For me it's about providing consistency. A user may be confused if they see a custom field displayed in the UI but absent in the object edit form. Rendering it as a disabled form field provides assurance that the field is not "missing." Some administrators still may prefer to omit it from the form anyway, so we provide both options. |
Could I suggest another option to Edit: Re-readings things, maybe I'm still waking up and the intention for this was when viewing a device, not editing. In which case, sounds like my input is already covered. |
What about these settings?
|
#14289) * Add ui_visible and ui_editable fields * Extend migration to map new visible/editable values * Remove ui_visibility field * Update docs
NetBox version
v3.5.7
Feature type
Change to existing functionality
Proposed functionality
I have many custom fields which only apply to a part of e.g. devices. With the "UI visibility" = "Hidden(if unset)" you can keep the UI clean for each device and you only see those that are set for the device. The problem and hence the feature reqest the "if unset" option should be independent of "Read/Write" or "Read only" option.
UI visibility:
or maybe with a checkbox
UI visibility:
Read/Write
Read-only
Hidden
Hidden if unset
Use case
I have custom fields that are Ready-only but I don't want them to appear in the UI on every device as they have no meaning for those devices. So it would be good if I could select read-only and "hidden if unset". Maybe there is another way to achieve this, but I haven't found any.
Database changes
No response
External dependencies
No response
The text was updated successfully, but these errors were encountered: