raimund-schluessler / inventory

12 stars 3 forks source link

Ability to add single item via Form #481

Open intervisionlord opened 7 months ago

intervisionlord commented 7 months ago

Hello, is it possible to add item via web-interface by filling requered fields, not only by typing a long row with semicolons?

raimund-schluessler commented 7 months ago

No, that is unfortunately not yet implemented. It's a long outstanding feature I wanted to implement (see #7). I currently first put new items in an excel file, export it as a CSV and import them here. It's a bit involved if you only want to add a single item, but since I mostly add multiple items in one go, it is ok.

umlaeute commented 4 months ago

i would also like to stress that this would be ace. we are trying to build a shared inventory (which would also require #487 :wink:), and i think for the casual user to add new a new item the CSV approach is too complicated.

stullekovski commented 3 months ago

Would appreciate that option too, for the same reason (FM team is not that IT team). ;) For the sharing I made a group for that app and only allow that group to view/access the app via NC Apps settings.

turnschuhadmin1337 commented 3 months ago

Hi there, thanks for the work and app.

But I can't create anything. Maybe my syntax is wrong? Is there any tutorial for the csv or an example file? A real form would be much easier, yes.

If I try to add a test item like

Widget A; Maker Inc.; A high-quality widget; 12345; http://example.com/widgetA; 0123456789123; Color: Red, Size: M; Customer favorite; Electronics; USA; 19.99; 100; yes; Vendor 1; 2024-05-27; widget, electronics, favorite; Widget B

I only get "Iteam creation failed.", what's wrong and how do I add items in general?

Thanks a lot and keep up the work (looking forward to use it).

raimund-schluessler commented 3 months ago

Hi there, thanks for the work and app.

But I can't create anything. Maybe my syntax is wrong? Is there any tutorial for the csv or an example file? A real form would be much easier, yes.

If I try to add a test item like

Widget A; Maker Inc.; A high-quality widget; 12345; http://example.com/widgetA; 0123456789123; Color: Red, Size: M; Customer favorite; Electronics; USA; 19.99; 100; yes; Vendor 1; 2024-05-27; widget, electronics, favorite; Widget B

Yeah, I know that adding by CSV is cumbersome, but I currently don't have time to implement a proper form, sorry.

As per your CSV string, the GTIN is invalid (either provide a valid one, or leave it empty) and available needs to be a number (available is meant as how many of the initial count is still there, i.e. you bought 100, but only 50 are left, because you used them).

So, this should work: Widget A; Maker Inc.; A high-quality widget; 12345; http://example.com/widgetA;; Color: Red, Size: M; Customer favorite; Electronics; USA; 19.99; 100; 50; Vendor 1; 2024-05-27; widget, electronics, favorite;

turnschuhadmin1337 commented 3 months ago

Hi, thanks for you reply. Don't worry about the form. Take your time.

I tested it with a new item like Widget A; Maker Inc.; A high-quality widget; 12345; http://example.com/widgetA; 123456789014; Color: Red, Size: M; Customer favorite; Electronics; USA; 19.99; 100; 50; Vendor 1; 2024-05-27; widget, electronics, favorite;

If I hit "show GTIN" after, I only get an empty picture.

Maybe bit off topic: how do I get the QR code and what is the UUID? I'm asking because my plan is to print stickers and link them with the app.

Thanks a lot.

raimund-schluessler commented 3 months ago

If I hit "show GTIN" after, I only get an empty picture.

The GTIN is invalid, 1234567890142 would be valid. In #547 I added a check that you cannot add invalid GTINs anymore, but it's not yet released.

Maybe bit off topic: how do I get the QR code and what is the UUID? I'm asking because my plan is to print stickers and link them with the app.

In the left botton settings you can download a UUID sticker sheet. The creation takes a few seconds (depending on your server). It contains QR codes of randomly generated UUIDs. A UUID is just a number that is globally unique (see https://en.wikipedia.org/wiki/Universally_unique_identifier). You can print the sticker sheet e.g. on these stickers: https://www.herma.co.uk/office-home/product/labels-hard-wearing-a4-24x24-mm-8339/

turnschuhadmin1337 commented 3 months ago

Ah, now I see. Thanks so much!

I got a UUID sticker sheet yet. How can I link a to an item? Is it under "Instances" and "Add UUID"? How do I save it then?

Hope it's my last (off topic) question. ;)

raimund-schluessler commented 3 months ago

I got a UUID sticker sheet yet. How can I link a to an item? Is it under "Instances" and "Add UUID"? How do I save it then?

Yes, that's the correct location. You need to provide a valid UUID, either paste it into the input field, or scan a QR code with the camera.

turnschuhadmin1337 commented 3 months ago

Ok. That's what I did. But after a refresh it's lost. How does the UUID has to look like? e.g. 941b6f9b-79dd-4564-bda6-22cd85a1257c?

raimund-schluessler commented 3 months ago

Ok. That's what I did. But after a refresh it's lost. How does the UUID has to look like? e.g. 941b6f9b-79dd-4564-bda6-22cd85a1257c?

That is a valid UUID and should work.