0
AUI自動刪除字段按鈕不工作好。但是添加按鈕的作品,因爲它是。
下面是配置代碼,我已經使用:
AUI().use('liferay-auto-fields',function(A) {
new Liferay.AutoFields({
contentBox: '#clientContact',
fieldIndexes: namespace + 'clientContactIndexs',
on: {
'init':function(event) {
console.log('init');
},
'clone': function(event) {
console.log('clone');
console.log(event);
},
'delete': function(event) {
console.log('delete');
console.log(event);
}
}
}).render();
});
HTML代碼:
<div id="clientContact">
<div class="lfr-form-row lfr-form-row-inline">
<div class="row-fields">
<aui:row>
<aui:column cssClass="col-xs-12 col-md-4">
<aui:input name="clientContactName1" id="clientContactName1" label="" placeholder="client.contact.name">
<aui:validator name="required"></aui:validator>
</aui:input>
</aui:column>
<aui:column cssClass="col-xs-12 col-md-4">
<aui:input name="clientContactMobile1" id="clientContactMobile1" label="" placeholder="mobile">
</aui:input>
</aui:column>
<aui:column cssClass="col-xs-12 col-md-4">
<aui:input name="clientContactEmail1" id="clientContactEmail1" label="" placeholder="email">
</aui:input>
</aui:column>
</aui:row>
</div>
</div>
</div>
有什麼我失蹤? 謝謝,