Skip to content
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

Bill create for purchases #13

Closed
ryanmerolle opened this issue Oct 25, 2022 · 3 comments
Closed

Bill create for purchases #13

ryanmerolle opened this issue Oct 25, 2022 · 3 comments
Assignees

Comments

@ryanmerolle
Copy link
Contributor

If I were to order 200 sfps, it’s not ideal to either us the api ot ui to bulk create the items.

I think it would be useful to allow bulk creation of inventory items given a quantity, order number and inventory item type.

it could be useful to allow the same feature for marking items as used, but admittedly that is not tricky if inventory items have a serial.

@matejv
Copy link
Member

matejv commented Oct 28, 2022

We could do it the way netbox does for adding interfaces and other components. Some fields support a special syntax where you give a range of values and netbox creates an instance for each value in range. For example you could got to Add asset and in name field you'd specify sfp [1-200]. That would create 200 assets with names like sfp 1, spf 2... I think the following fields could support this syntax: name, asset_tag, serial.

Would that be acceptable?

Another way I suppose we could do is to have a separate form for bulk add with quantity field. Here you couldn't specify asset_tag or serial fields as these must be empty or unique (for a given inventoryitem type).

@matejv matejv self-assigned this Oct 28, 2022
@ryanmerolle
Copy link
Contributor Author

Either way works

@matejv
Copy link
Member

matejv commented Nov 21, 2022

I have implemented this in #24

@matejv matejv closed this as completed in 6223ea0 Nov 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants