2

I wanted to do some enhancements in the forms used for adding and editing the users. In my requirement I am using only sites so I don't want to use Organizations and User groups sections. I want to hide some sections in the user creation and editing forms. With reference to some web search I have created the properties-ext.properties file with following content

users.form.my.account.main=details,password,sites,roles
users.form.my.account.identification=addresses,phone-numbers 
users.form.my.account.miscellaneous=announcements,comments

After restarting the tomcat, The changes are reflected only at "My Account" tab. But I want to reflect the same changes in user creation and user edit forms also. How can I do that? Are there any specific configuration is there to do the same Or did I miss some steps? Or If we want to do enhancements through Hooks, Where can I find the source code files for add and edit user forms?

Vinod
  • 2,263
  • 9
  • 55
  • 104

1 Answers1

2

Below are portal properties to set which sections you want in User Add/Edit screen.

#
# Input a list of sections that will be included as part of the user form
# when adding a user.
#
users.form.add.main=details,organizations,personal-site
users.form.add.identification=
users.form.add.miscellaneous=

#
# Input a list of sections that will be included as part of the user form
# when updating a user.
#
users.form.update.main=details,password,organizations,sites,user-groups,roles,personal-site,categorization
users.form.update.identification=addresses,phone-numbers,additional-email-addresses,websites,instant-messenger,social-network,sms,open-id
users.form.update.miscellaneous=announcements,display-settings,comments,custom-fields
Pankaj Kathiriya
  • 4,210
  • 2
  • 19
  • 26
  • It is working. Thank you. I have few more queries which I have updated as new questions. Please give me some suggestion If you have any idea on the same. http://stackoverflow.com/questions/29262168/issue-with-site-administrator-page-level-access-permissions and http://stackoverflow.com/questions/29256685/can-it-possible-to-add-the-custom-fields-under-details-tab-liferay – Vinod Mar 26 '15 at 05:38
  • Where can I find the front end source code for User Add and Edit screens? Can you please tell me the path for these files in the liferay source bundle. Please... – Vinod Mar 26 '15 at 14:11
  • 2
    `portal-web\docroot\html\portlet\users_admin\edit_user.jsp` and jsp-files under folder `portal-web\docroot\html\portlet\users_admin\user` – Pankaj Kathiriya Mar 26 '15 at 14:59
  • Will the add and edit screen jsp files are same? I am able to see the edit_user.jsp. What about add screen? – Prasad Mar 26 '15 at 15:30
  • 2
    same file is used for Add/Edit User screen – Pankaj Kathiriya Mar 26 '15 at 15:56
  • Hi I add a new label "users.form.update.miscellaneous= salary" but when I click on this its showing blank. could you please suggest how can I use this link. I don't want to use custom field please suggest with jsp hook. – nitin verma Jun 02 '17 at 10:35
  • You have to create respective jsp for salary (salary.jsp), you may look into folder structure(docroot\html\portlet\users_admin\user) and you will get idea – Pankaj Kathiriya Jun 02 '17 at 20:02