-
Notifications
You must be signed in to change notification settings - Fork 141
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
Expose attribute aliases in list of attributes #1278
Conversation
38d375b
to
489e623
Compare
@@ -21,7 +21,7 @@ def attribute_selection | |||
if [email protected]? || @additional_attributes | |||
@req.attributes | Array(@additional_attributes) | ID_ATTRS | |||
else | |||
Picture.attribute_names - %w(content) | |||
Picture.attribute_names | Picture.try(:attribute_aliases)&.keys - %w(content) |
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.
I made a comment in the other PR, but I don't understand this. Does this not return the same thing in Rails 7.1 as in 7.0? In 7.0 the |
WIP: introducing more generic method for the concept of attributes and attribute aliases. After that is done, will change this code to leverage that. |
489e623
to
8383a3d
Compare
update:
un-WIP |
8383a3d
to
f2d7ff9
Compare
f2d7ff9
to
a92ad3d
Compare
This assertion on the response body fails against master code before this branch. I think the intention was to test that creation with a virtual columns works.
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
Blocked:
This enables fixes for 7.1
But this does not depend upon 7.1 and even in 7.0 is a more accurate implementation