This is a sample of custom name picker with organization tree.
There are two methods to add recipient(s) from the name picker.
-
Add a single recipient to whichever of To, Cc or Bcc input fields is currently selected. It is introduced in Verse on-Premises 1.0.2 and is available in Verse on-Cloud as well. The vop1.0.2 branch illustrates how to create this kind of name picker.
-
Add recipients to To, Cc and Bcc input fields all together in one action. It is introduced in Verse on-Premises 1.0.4 and is available in Verse on-Cloud as well. This repository illustrates how to create this kind of name picker.
This is a Nodejs project. Please make sure that you have installed the latest Nodejs before try this demo.
- Clone this repository
- Run
npm i
in the root folder of the cloned project - Run
npm run server
to start the server - Open https://127.0.0.1:8080 in your browser, you should see the sample custom name picker with organization tree UI
- Use the applications.json under the root folder of the cloned project to register Verse applications. You have several options to register applications into Verse.
- If you want to try this sample on your personal client, you can locally register applications through IBM Verse Developer Browser Extension. The tutorial is here.
- If you want to register applications for your organization, you need to register it on server. For VoC, you can register it with use of IBM App Registry. Please take the section "Deploy application on Verse on-Cloud" of Registering an Application in IBM Verse as a reference.
- Check the
originsList
variable insrc/javascripts/index.jsx
, please add your VOP server hostname in it. - Login Verse with web browser and make sure you have enabled feature
custom-name-picker
- It should be good to try in Verse now !
This sample works with Chrome/Firefox/IE11.
The data in this sample is fake. Related codes are in file /utils.js
and file /src/javascripts/service/api.js
. You can modify corresponding code logic according to your requirements.