留言板

Liferay Autofields

Kiran Kulkarni,修改在10 年前。

Liferay Autofields

New Member 帖子: 12 加入日期: 13-12-3 最近的帖子
Hi,
Can anyone point me out on official documentation of how to use Liferay Autofield. I am very much confused about using Liferay documentation as there are very less examples and resources out there. I feel it is not properly organized (personal opinion though!!). Can anyone help me on how to use Liferay.Autofields in aui-script with example explaining each and every step (like creating the indexes). My issue is that, I have created the form with Autofield but I am unable to understand the concept of "fieldIndexes" and other few things. I also want to save these unique indexes , so that I can retreive the values of elements inside every fieldset after submitting the form. And later, I should be able to view the same form by duplicating the fieldsets.

It would be of great help if there is a sample example explaining about how this can be achieved with all the steps.
Below is the jsp code that I have used to create simple autofield :-

<aui:fieldset cssclass="dependents">
	<div class="lfr-form-row lfr-form-row-inline">
		<div style="float: left; padding-right: 5px;">
			<aui:input name="name" />
		</div>
		<div style="float: left; padding-right: 5px;">
			<aui:input name="relation" />
		</div>
		<div style="float: left; padding-right: 5px;">
			<aui:input name="birthDate" />
		</div>
	</div>
</aui:fieldset>



<aui:script use="liferay-auto-fields">
	new Liferay.AutoFields(
		{
			contentBox: 'fieldset.dependents',
			fieldIndexes: '<portlet:namespace />fieldset.dependentIndexes'
		}
	).render();
</aui:script>


	
thumbnail
meera prince,修改在10 年前。

RE: Liferay Autofields

Liferay Legend 帖子: 1111 加入日期: 11-2-8 最近的帖子
Hi
Please have a look into following link it may help you..

http://www.liferaysavvy.com/2013/10/liferay-auto-fields.html


Regards,
Meera Prince
Kiran Kulkarni,修改在10 年前。

RE: Liferay Autofields

New Member 帖子: 12 加入日期: 13-12-3 最近的帖子
Thanks for the detailed explanation. Cheers emoticon