留言板

Custom Attributes Hidden Field

thumbnail
Gnaniyar Zubair,修改在11 年前。

Custom Attributes Hidden Field

Liferay Master 帖子: 722 加入日期: 07-12-19 最近的帖子
Hi,

I have created hidden custom fields for user and added in my create_account.jsp file using this tag :

<liferay-ui:custom-attribute className="<%=User.class.getName() %>" classPK="<%= 0 %>" editable="true" label="true" name="Account For"></liferay-ui:custom-attribute>


As i dont want to display for users, i have set it as hidden. But I need to send the values from create_account.jsp file based on some criteria.
I tried like this in jquery :

$('input[name*="Account For"]').val("Owner");


But above custom field is not stored in ExpandoValue table. I thought if we set custom attribute in hidden mode, liferay tag will generate the field with type = "hidden" .

If custom field is in "hidden" mode, cant we send the value from jsp ?

Any idea why it is not stored in table?

- Gnaniyar Zubair