留言板
passing values to hidden expando field
Andrés Cerezo,修改在13 年前。
passing values to hidden expando field
Junior Member 帖子: 92 加入日期: 10-11-11 最近的帖子
Hello all, I have a hidden expando field and I need to pass a default value depending of a variable. Anyone knows how can I do it?
Thanks.
Thanks.
Udaya Ramakrishnan,修改在12 年前。
RE: passing values to hidden expando field
Junior Member 帖子: 67 加入日期: 11-9-7 最近的帖子
hi,
use the below code as a example:
try {
ExpandoBridge expandoBridge=user.getExpandoBridge();;
ExpandoValueLocalServiceUtil.addValue(
expandoBridge.getCompanyId(), expandoBridge.getClassName(),
ExpandoTableConstants.DEFAULT_TABLE_NAME, "ur_custom_field",
expandoBridge.getClassPK(), "default_value");
}
catch (Exception e) {
_log.error(e, e);
}
execute this lines while u adding. For example i have added this lines when a new user was added to LR
Let me know this is useful to u.......................
thanks,
Udaya.R
use the below code as a example:
try {
ExpandoBridge expandoBridge=user.getExpandoBridge();;
ExpandoValueLocalServiceUtil.addValue(
expandoBridge.getCompanyId(), expandoBridge.getClassName(),
ExpandoTableConstants.DEFAULT_TABLE_NAME, "ur_custom_field",
expandoBridge.getClassPK(), "default_value");
}
catch (Exception e) {
_log.error(e, e);
}
execute this lines while u adding. For example i have added this lines when a new user was added to LR
Let me know this is useful to u.......................
thanks,
Udaya.R