When we receive certain stock items, we need to apply an internal barcode to them. This barcode is part of a much larger system that we cannot alter/influence. These barcodes are printed/created by the property team; we get a roll of them, apply them to devices, and then notify the property team what barcodes were applied to which devices. We'd like to track that internal barcode in addition to the stock item serial number. Additionally, it needs to be searchable.
As a possible solution, there could just be an additional field added to the stock object called 'asset tag' lower level of effort required, but less flexibility.
Another possible solution would be allow users to define custom fields in each part (or in the admin panel, for the stock model in general), but that were unique to each instance of the stock. Then we could not only define 'asset tags' but then also things like 'this device was purchased for (re: with the money from) blue customer, or our red customer` (something else we need to do for compliance reasons).
We've looked at using the Stock Item Notes, but this field is not indexed by search (understandably so), meaning that its difficult to reference stock items by the contents of that field.
We also use Netbox, and it handles this in a relatively elegant way; custom fields for each model (it's also Django based).
So, unfortunately in our environment (datacenter with high compliance restrictions) we cant utilize the mobile app or barcode scanners hooked up to computers unless they've been specifically approved. And getting them approved is a sisyphean task. (not something I expected one to divine from my initial FR)
That being said, the example I provided in the initial suggestion was just one use case. We have other use cases where we need to associate arbitrary data to ever stock or part in inventree:
I could have worded the original request better to better describe the other use cases; I'm happy to edit if preferred.
You could also add the values hand into the text field.
We provide additional meta fields to plugins / via the API - not sure if we should add more options @SchrodingersGat
When we receive certain stock items, we need to apply an internal barcode to them.
Maybe I'm missing something from the discussion here, but InvenTree already supports custom barcodes for stock items?
You could also add the values hand into the text field.
We looked at that, but unfortunately the text field is not indexed (not saying it should be); this means that we cant search inventree by contents of that field.
Maybe I'm missing something from the discussion here, but InvenTree already supports custom barcodes for stock items?
The issue we have with barcodes is that we dont have any way (at least, today) to connect a barcode scanner (or camera, or mobile device) to the same network that has our instance of inventree running on it. When I try to type in the barcode manually (it's only 5-7 characters long), it assigns a long ID in the barcode field and I cant search by the text I had entered. I understand this is a unique aspect of our deployment that I dont expect inventree to handle (very much a corner case).
But barcode was only one example, the larger issue is that we're running into several fields that are specific to our environment that we need to track per stock item that we just dont have a way to do today. This could be everything from:
The example I referenced was Netbox, where they have per-model custom fields that can be defined in the admin page, and then utilized in the app. Does that clarify the use case at all? (genuinely asking)
@mddeff the closest thing we currently offer "out of the box" is that the StockItem model has a "metadata" parameter which is a JSON object field which can contain any custom user data of arbitrary complexity. This can be accessed / edited via the API or the admin interface (currently not exposed via the web interface).
Does this perhaps go some way towards what you are looking for?
@SchrodingersGat , It does sound like its in the right direction; does any of that get parsed/indexed by the main site search? I'm assuming to integrate it into the UI, somebody would have to write a plugin? The target audience who would need to interface this isnt likely to have access to (or want to use) the admin interface.
@mddeff sounds like a plugin would be suitable here. The admin interface is certainly clunky and not designed for everyday use
Does any of that get parsed/indexed by the main site search?
Nope, metadata is not parsed by the search engine
I think a generic way to add (searchable) custom fields that can be set on a stock item would be beneficial.
In my usecase I have docks/pcs/etc, those have a trackable serial number, a service tag and more. This works well as I set the part as 'trackable' and enter the serial for each stock item. However I would also like to store the service tag and MAC address for each stock item (in a searchable manner). Currently I have not found a way to do this.
Search engine is a bit misleading. Our search is a bunch of API calls strung together. Adding anything there is not an easy feat without slowing the userinterface down.
If you only need asset managment I would suggest looking into netbox / snipe-it as this FR will take a while to develop and no dev has signed up to do it in the last 3 weeks. I use snipe-it for (IT) asset management at work and netbox for network infrastructure.
Yeah, I should not have used dock/pc as use-case, I thought it was a clear understandable example I just happened to run into today. It is not our main use.
We tried snipe-it before, but it did not work out for our use. Inventree fits it much better (even with this limitation we don't want to go back).
Owner Name | inventree |
Repo Name | InvenTree |
Full Name | inventree/InvenTree |
Language | Python |
Created Date | 2017-03-23 |
Updated Date | 2023-03-31 |
Star Count | 2586 |
Watcher Count | 61 |
Fork Count | 411 |
Issue Count | 141 |
Issue Title | Created Date | Updated Date |
---|