cancel
Showing results for 
Search instead for 
Did you mean: 

Can I store custom properties for users if the users come from ldap ?

fast_narcis_
Confirmed Champ
Confirmed Champ

Can I store custom properties for users if the users come from ldap ?

I need to be able to store some custom properties on users and I don't want to add those properties in LDAP. For example I need to disable a user in my project although it still exists in LDAP.

1 ACCEPTED ANSWER

Olivier_Grisel
Star Contributor
Star Contributor

It is possible map arbitrary string properties to LDAP attributes by defining your own schema instead of the default "user" schema definition (and the matching layout if you want to make those property editable from the web UI in the Admin Center).

Edit: I misread the original question. If you don't want to store the custom properties in the LDAP you can use a MultiDirectory to merge entries that come from a LDAP and SQL directory. You will still need to define your own schema and layout to do so.

View answer in original post

7 REPLIES 7

Olivier_Grisel
Star Contributor
Star Contributor

It is possible map arbitrary string properties to LDAP attributes by defining your own schema instead of the default "user" schema definition (and the matching layout if you want to make those property editable from the web UI in the Admin Center).

Edit: I misread the original question. If you don't want to store the custom properties in the LDAP you can use a MultiDirectory to merge entries that come from a LDAP and SQL directory. You will still need to define your own schema and layout to do so.

fast_narcis_
Confirmed Champ
Confirmed Champ

Maybe I didn't formulate my question very clearly.

Benjamin_Jalon1
Elite Collaborator
Elite Collaborator

Hi,

There is another solution, with the new module in 5.5 release: "social collaboration". You will find in this module the rich profile feature. For each user, you will have the possibility to store other information in a nuxeo document for ones not stored into your user directory (birthdate, company name, gender, phone number, ...).

Like other Nuxeo Document type, we define a list of schema this Nuxeo Document type will implement and a layout... Finally you will have something like that:

alt text

This screenshot presents the default layout proposed by Social Collaboration. And here is the edition view:

alt text

You will have the possibility to declare your own schema and layout associated that will be added into these view.

  • When you install your Nuxeo select Nuxeo DM and Social Collaboration.
  • About adding your own layout (with Studio for instance), you just have to override "summary_user_profile_layout" defined like that (don't forget to require "org.nuxeo.ecm.social.user.profile.layout.config" if you don't create with Studio):

Here is the XML fragment example:

  <extension target="org.nuxeo.ecm.platform.forms.layout.WebLayoutManager"
    point="layouts">
    <layout name="summary_user_profile_layout">
      <templates>
        <template mode="any">/layouts/layout_summary_template.xhtml</template>
      </templates>
      <rows>
        <row>
          <widget>summary_user_profile</widget>
        </row>
        <row>
          <widget>summary_user_relationship</widget>
          <widget>summary_user_mini_messages</widget>
          <widget>summary_user_activity_stream</widget>
        </row>
      </rows>
    </layout>
  </extension>

Thanks for your answer Benjamin. This looks like what we were looking for.

You should use the "comment" button instead of writing an answer for each sub-questions. Please delete your answers and rewrite them as comments to the matching answer such that future readers can understand the flow of comments.

This is available in the trunk and will be available for the next Nuxeo version.

This is now available, you don't need to build the Social Collaboration feature now, as this is integrated into the installer. I changed my answer accordingly.