Use Advanced Search Selects to create linked selection lists

Hints, Tips and Tricks

Technical Hints Tips and Tricks that cover customization and development using Sage CRM. API usage and coding are covered.

Use Advanced Search Selects to create linked selection lists

  • Comments 16
  • Likes

Many teams need to link selection lists so that the contents of one selection list determine the contents of another.  For example Support teams love the ability when creating a case, to fill in a value for a type of support issue, and then narrow down the issue with a second set of options, and perhaps even narrow down the issue further.

I was amazed when Jack told me this feature was available in Sage CRM, so I just had to blog about it.

What is the feature?

 On a case summary screen I have added three new fields, Area Select, Category, and Issue:

The field are related to each other.

First of all the Area Selects that I have entered are hardware, software and warranty.  In this example let us say the customer is complaining about some software, and so the user picks software.

Once the user picks software, the Category selection will fill up with different types of software.   In this example the software options are Mac, Microsoft and Red Hat. The user asks the customer which software they have a problem with.    

Let us say the customer is complaining about Microsoft software.  The user selects Microsoft.   Now the Issue selection fills with different Microsoft versions.   In this example the options are Vista, Windows 95 and Windows NT.  The user can pick a version.

 The result is that the case now identifies the exact area of the problem. 

 This example can obviously be reused in many different ways, and can be customised to suit each customer's needs.

How to do it?

Note:

1) Setup of these fields requires no coding. There is some advanced configuration needed, and so you must try it out first on a trial install.

2) You must be familiar with the "Main Entity Wizard" of the Sage CRM component manager.

3) I recommend that you follow my instructions to the letter when doing your first attempt, and then do it again yourself with your own customisations once you know what you are doing. Implementation takes about one hour.

 First I'll show you how to do the Area Select and Category selections.

Step 1)

Using the "Main Entity Wizard" of the component manager create new entities for Area and Category.  (It is assumed that you already know about the "Main Entity Wizard" and the component manager).

Navigate to Administration-> customisation-Component manager, and start up the Sage CRM component manager. 

 Highlight advanced customisation wizard and click install component.

Create a new Area entity: 

 Put in values for Entity name "Area", and entity column prefix "area" as shown.  Click Install component and it will finish with the message below. 

Now do the same for Category:  

 Make the entity name "Category" and the entity column prefix "cate".

Step 2)

Edit Category so that it links to Area.

Navigate to Administration -> customisation -> category -> Fields

Create a new field of type search select advanced:

Make the entry type "Search Select Advanced", column name "cate_areaid", caption "Area", and Search entity "Area".

Note: This bit is the trickiest part of this project.  You must get the column name exactly right or it will not work.  You need to take the name of the selection you are linking to, and add id.  The format of the name is <column prefix>_<entity you are linking to>id

Add this new field to the category screen.  Navigate to Administration -> customisation -> category -> Screens

Edit Category new entry screen.

Add the field "Area", as the first field like so:  

Step 3)

Add some data to the Area and Category entities. 

Note By default non admin users will not see the new -> area, and new -> category buttons unless security permissions are changed.  That is probably a good thing.

Navigate to Main Menu-> New -> Area

Add the following values: "Hardware", "Software", "Warranty".

Now add values to category linked with area. Navigate to Main Menu-> New -> Category

In the Area field pick "Hardware", and for Name pick "Toshiba", and Save.

Now add more hardware values "Sony" and "Samsung".

Now add some new software values.  Create a new category, and select the Area as "Software".  Add values for "Microsoft", "Mac" and "Red Hat".

Step 4)

Add the field to the case summary screen.

Navigate to Administration -> Customisation -> Cases -> Fields

Add a new search select advanced: 

Entry type is "Search Select Advanced", column name is "case_area", caption is "Area Select", search entity is "Area".

Note:  The reason why the caption is "Area Select" and not "Area" is because there is already an "Area" caption on the case screen.

Add a second new search select advanced: 

Entry type is "Search Select Advanced", column name is "case_category", caption is "Category", search entity is "Category", and Restrictor Field is "Area Select".

Navigate to Administration -> Customisation -> Cases -> Screens

Edit CaseDetailBox

Add the Area Select and Category fields like so: 

Now navigate to a case, and edit it, and you will see the Area Select and Category fields working.  When you select an Area the Category field is filled in with the correct values.  If you clear both field and select a Category it will fill in the Area for you.  This also works in the new case screen.

Step 5)

Finally repeat the above steps for the Issue entity.  You will end up with a three tier selection as described in the introduction.

 

Comments
  • No.  I don't think there is.

    The only thing that I can suggest is using clientside code to only display (or allow entry) to subsequent fields once the first field's selection has been made.