Adding your own entities to Case Management


Case managment is a generic cross module solution where you can log cases with or without a defined process and keep a information. A case can be related to a number of various entities in the solution.

There are 9 case categories where you can group processes:

  • General
  • Sales
  • Purchase
  • Service
  • Project
  • Production
  • Collections
  • Audit
  • Human Resources

You also have 22 entities you can associate the case with:

  • Lead
  • Opportunity
  • Customer
  • Vendor
  • Prospect
  • Project
  • Sales order
  • Purchase order
  • Worker
  • Service order
  • Item
  • Customer transaction
  • Expence report
  • Expence report line
  • Venrod invoice
  • Vendor invoice line
  • Purchase order line
  • Returned order
  • Case
  • Product
  • BOM/Formula
  • Route

Both categories and entities can be extended.

Working with manufacturing companies we quickly came in to a lack of entities that our customers often wanted to associate a case with. Mainly Production orders and tracking data like serial and batch numbers. We also added a lot of other entities to our standard expansion solution to our customers.

How to extend the entities?

1.  Add your entities to the Entity type BaseEnum (CaseEntityType).
PS: Remember to add 100 to the last enum in the list.

2.  Make the Assiciation link class (smmAssociationLink) be able to look up the data for the new entity

  • entityType2FieldId
    entityType2FieldId
  • entityType2FieldName
    entityType2FieldName
  • entityType2TableId
    entityType2TableId
  • performJumpRef
    performJumpRef
  • performLookup
    performLookup
  • tableId2EntityType
    tableId2EntityType

3. Create relations from the case association table (CaseAssociation) to the new entity tables
Set the parameter “UseDefaultRoleNames” to “Yes”.

4. Add the dynamic lookup to the Case form (CaseDetail)
CaseProductionOrderExample

4.1 Add the entity tables as Data Source
Use the following parameters:
CaseDatasourceProdTable

4.2 Duplicate CaseMoreInformation node and add the fields you want to look up
You will find this under:
Forms > CaseDetails > Designs > Design > Tab > TabPageDetails > TabHeader > AssociationsTabPage > Group_MoreInformation

This example is for Production orders as shown above:
CaseMoreInformation_Production

4.3 Edit the dynamic switch for the display.
Edit the class: showMoreInformation located in methods on the root of form:CaseDetail.

  • Add a new boolean in the top
    Case_moreInfo_boolean
  • Add the boolean to showMoreInformationGroup
    case_moreInfo_switch
  • In the bottom part of the code add a new if statement
    case_moreInfo_if

5. Add the form actions to create and view related cases
Open a form in the AOT with these methods (like the salesTable form) and drag the wanted sections to the form you want. Result might look like this:
caseCreateLookupFormButtons

If you copy from the Sales order form you might want to change the “MenuItemName” parameter to a generic or production (in this case) to get the right category.

Remember that you can extend any type of entity to be a part of the case managment. Hope this post helps you to use it even more.
For more information about case managment check out MSDN:
https://technet.microsoft.com/en-us/library/hh242147.aspx

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s