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
RE: Liferay 7.3.4 GA5 aui auto fields delete ( - )button not working
Aui Auto Fields delete button is not working well. However add ( + ) button works as it is.
Here is configuration code I have used:
<aui:form action="${editFeesConfigURL}" method="post" name="LiferayAutoFieldForm">
<div id="splitFeesDtl-fields">
<div class="lfr-form-row
lfr-form-row-inline">
<div
class="row-fields">
<aui:input fieldParam='feesConfigDtlName0' id='feesConfigDtlName0'
name="feesConfigDtlName0"
label="common.splitname" >
<aui:validator name="required"/>
</aui:input>
<aui:input fieldParam='splitAmt0' id='splitAmt0'
name="splitAmt0"
label="common.splitamount" >
<aui:validator name="required"/>
<aui:validator
name="number"/>
</aui:input>
</div>
</div>
</div>
</aui:form>
<aui:script use="liferay-auto-fields">
new
Liferay.AutoFields(
{
contentBox:
'#splitFeesDtl-fields',
fieldIndexes:
'<portlet:namespace />splitFeesIndexes'
}
).render();
</aui:script>
Can someone help me ?
Thank you.
I had the same problem once. What did not work for me was the
following line in auto_fields.js:
https://github.com/liferay/liferay-portal/blob/master/modules/apps/frontend-js/frontend-js-aui-web/src/main/resources/META-INF/resources/liferay/auto_fields.js#L452
I changed it to using a JS Override (e.g https://help.liferay.com/hc/en-us/articles/360017881192-Overriding-Liferay-DXP-s-Default-YUI-and-AUI-Modules):
var visibleRows = contentBox.all('.lfr-form-row:not(.hide)');
Hello Dominik,
Thanks for your reply.
Powered by Liferay™