You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When you add a bunch of items using Create & Add Another, the value of the Asset Tag is copied to the next form. However, this is confusing because an asset tag should be unique somehow to uniquely identify an asset.
After looking at the NetBox code, I see that the dcim.Device model uses a unique constraint for field asset_tag, so I'd suggest doing the same for this plugin to have consistent behavior.
The text was updated successfully, but these errors were encountered:
netbox_inventory enforces that the combination of asset.owner and asset.asset_tag is unique.
I intentionally keep the old asset tag value when using "Create & add another" since my thinking is: if you're adding multiple of similar asset in a row, and you keep track of asset tags, it's likely that your asset tags will be sequential. Sou you can just increment the last number of old asset tag instead of having to type the whole value in again (increasing the chance of a type in the process).
What I did miss is that if the asset owner is not set, the asset tag value uniqueness is then not enforced. I'll take a look how this can be done.
When you add a bunch of items using
Create & Add Another
, the value of the Asset Tag is copied to the next form. However, this is confusing because an asset tag should be unique somehow to uniquely identify an asset.After looking at the NetBox code, I see that the
dcim.Device
model uses a unique constraint for fieldasset_tag
, so I'd suggest doing the same for this plugin to have consistent behavior.The text was updated successfully, but these errors were encountered: