-
Notifications
You must be signed in to change notification settings - Fork 17
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
JSON editor is not present when creating nested resources #7
Comments
@sedubois as far as I understand you have a problem with displaying editors that were added after page initialized. We are using this JS https://github.com/codica2/administrate-field-jsonb/blob/master/app/assets/javascripts/administrate-field-jsonb/components/editor.js to initialize the editor. You need to run this code every time you add a new entity with NestedHasMany. |
@volkov-sergey I see here that the JS is included with |
I have a
Post
which has_manyPost::Translation
s, which themselves have a JSONtags
property. When creating the post with its nested resource(s), the tag editor does not appear (https://localhost:3000/admin/posts/new):However it does appear when creating the translation sub-resource directly (https://localhost:3000/admin/post/translations/new):
Also, the editor does appear when editing an existing post:
The dashboard is configured as follows:
As my
tags
cannot benil
(as enforced by DB schema), this issue prevents creating new posts and is therefore quite blocking.Using Rails 5.2.3, Administrate 0.12.0, administrate-field-jsonb 0.4.0, and administrate-field-nested_has_many 1.1.0 although it's mostly overridden; code is included for reference above but in principle unrelated to this issue.
The text was updated successfully, but these errors were encountered: