Ask Questions and Find Answers
Important:
Ask is now read-only. You can review any existing questions and answers, but not add anything new.
But - don't panic! While ask is no more, we've replaced it with discuss - the new Liferay Discussion Forum! Read more here here or just visit the site here:
discuss.liferay.com
Liferay 7.4.1-GA2 ReactJS Portlet configuration could not persisted
Hey guys,
We have some ReactJS portlets which are generated with the
'generator-liferay-js' and our portlets has custom
configurations.
In Liferay 7.3.7-GA8 the configurations are
saved without any problems in database.
But, in Liferay 7.4.1
the configurations could not be persisted. Existing configurations of
a ReactJS Portlet could be loaded.
We use the latest version of
the 'generator-liferay-js'. Also we use version '2.26.0' of the
'liferay-npm-bundler' and 'liferay-npm-build-support'.
Is there any migration guide or workaround?
Note: If we generate a new 'testing-like' portlet by the 'generator-liferay-js' with sample code (it contains sample configuration) and deploy this portlet into Liferay 7.4.1, we are not able to save the configuration.
If we try to save the configuration (in Liferays page editor) the
configuration modal calls
the '/o/dynamic-data-mapping-form-context-provider' endpoint.
Only in the developer tools of the browser we get an error with the
message: "TypeError: Cannot read property 'get' of undefined"
If we use a default widget of Liferay like 'IFrame' the configuration could be saved.
Has anybody an idea?
Best regards
Hi Sascha, sorry to hear about your issue...
I haven't seen this issue myself, but I haven't been using 7.4 yet.
If you haven't already, I'd suggest posting a ticket to https://issues.liferay.com to document the issue.
I second that, the issue is in the file http://localhost:8080/src/main/resources/META-INF/resources/js/custom/form/FormView.es.js
at linenumber 68: const liferayForm = event.target.id && Liferay.Form.get(event.target.id);
PS: I used ?
js_fast_load=0&css_fast_load=0&
strip=0
Powered by Liferay™