-
-
Notifications
You must be signed in to change notification settings - Fork 669
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
Part responsible owner #5774
Part responsible owner #5774
Conversation
SchrodingersGat
commented
Oct 23, 2023
- Replaces Part responsible #5060
- Fixes Part responsible is limited to a User, groups not allowed #5059
- Will replace "responsible" field
- Adds 'responsible_owner' value for parts which have 'responsible' set - Selects correct content type - Performs reverse migratoin
- Point to the new field - Rename to preserve compatibility - OPTIONS metadata will take care of the rest
✅ Deploy Preview for inventree-web-pui-preview canceled.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
InvenTree/part/serializers.py
Outdated
responsible = serializers.PrimaryKeyRelatedField( | ||
queryset=users.models.Owner.objects.all(), | ||
source='responsible_owner', | ||
) | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Comment: This should lead to a bumb of the API version, right?
@miggland FYI this is how complex migrations should be handled. In separate sequential migrations:
Data and schema migrations should not be performed in the same step. And it should be written in such a way that it is reversible if required :) |
Looks nice, thanks for fixing this. 👍 |
No worries, it is a pretty tricky thing to get right! |