K2 BLACKPEARL PRODUCT DOCUMENTATION: USER GUIDE
SmartObject Lookup

SmartObject Lookup

The SmartObject lookup feature can be used as a Data Level Security lookup object. An association is required between the SmartObjects in order for the lookup to know which SmartObjects are associated with one another.

Create Lookup Settings in K2 for Visual Studio

We will create two SmartObjects and use one as a lookup for reporting purposes. Follow the steps below to create the lookup from K2 for Visual Studio:

  1. Create a Customer SmartObject

    Fig. 1. Customer SmartObject

  2. Create a Region SmartObject

    Fig. 1. Customer SmartObject

  3. On the Region SmartObject screen, click on Additional Settings. Check This SmartObject is used as a Lookup Object checkbox. Select RegionID as the Id Property, RegionName as the Display Property and Get List as the Lookup Method.

    Fig. 1. Customer SmartObject

  4. Click OK and deploy the project.
  5. Create a one to many association on the Customer SmartObject with the Region SmartObject using the RegionID as the mapping property. Deploy the project.

    Fig. 1. Customer SmartObject

  6. Enter valid data into the SmartObjects
  7. Go to K2 Management Console in K2 Workspace
  8. Navigate to Server name:Port > SmartBox > Security and click on CustomerVS
  9. Select the Data-level Mapping tab

    Fig. 1. Customer SmartObject

  10. Tick RegionVS and click on the Security button. Click on the Map … button next to the user you want to apply permissions to.

    Fig. 1. Customer SmartObject

  11. Select the Regions you want this user to view and click OK.

    Fig. 1. Customer SmartObject

  12. When this user is logged in and data is retrieved from the Customer SmartObject, only information for the Northern and Southern regions will be displayed.

Create Lookup Settings in K2 Management Console

Lookup Settings can also be done via the K2 Management Console.

  1. Follow Steps 1 and 2
  2. Follow Steps 4-9. Click the Additional Settings button

    Fig. 1. Customer SmartObject

  3. Follow Step 3.
  4. Continue from Step 10 onwards

 

 


K2 blackpearl Help 4.6.11 (4.12060.1731.0)