-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
[WIP] API Forms #1716
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
[WIP] API Forms #1716
Conversation
- Limit available "actions" data to only what the user is allowed to do
- Skeleton only (for now!)
- Support text field - Support checkbox field
- Fetch existing data from the API
- Now can specify the "order" of fields
- It will make sense, trust me
# Conflicts: # InvenTree/InvenTree/static/css/inventree.css
@SchrodingersGat loots of great stuff in here, will make adding new forms more seamless. I will keep doing small stuff while you work on this and then finish the wishlist for pricing. Everything left there needs form rendering. |
|
@SchrodingersGat For the moment the "API-ready" forms are only for companies and orders? I've tried Parts, Categories and Stock location/items and still getting |
|
It's so quick btw 😃 |
I have only migrated a handful of the existing forms - basically the ones without any complex server-side logic. Those will require some closer attention. |
|
Sounds good! |
This PR implements "forms" across the API.
The eventual goal here is to eliminate the current duplication of code which renders web forms from the django server, and also (separately) defines the API.
The DRF API will (when this PR is complete) provide all (or at least most) of the modal forms.
Form Features
min_valuefrom numerical django model fieldsmax_valuefrom numerical django model fieldsBugs
Other Items
Supported Input Types
Ref: django DRF metadata
Python Integration
TODO: Add support to the python bindings to allow dynamic lookup of "queryset" for a given ForeignKey field.
Unit Testing
Documentation
References