Updating Access Rights in bulk for Accounts and Contacts

Problem Statement

In the bpm’online CRM there is a need to set limitations in accessing the Contacts and Accounts section wherein the users can have access only for limited records. In the present scenario, bpm’online customer has a huge number of Contacts and Accounts, and their users had access to the entire records. In this post we will discuss, how to update the access rights for Accounts and Contacts section in bulk and check the same for each record with the help of a flag on table through a business process.

Solution

Access rights set up wizard for bpm’online https://marketplace.bpmonline.com/app/access-rights-setup-wizard-bpmonline is an add-on available in bpm’online marketplace to grant and change access rights for existing records.

This add-on could update only 100 contacts and accounts in one go and we could not monitor the progress of updates happening. Hence, we resolved it with a simple process mentioned below to grant or deny permissions for bpm’online records and we could update 8000 contacts and accounts in a single run.

Image for the process that we created to achieve this in Contact Section

Description of the process:

 Set Access Process Flag as N: We used ‘Modify Data’ element to set the value of flag created in section. Based on the business condition, we set value of Flag as ‘False’ (N)

Calculate records where flag is N: We used ‘Read Data’ element to ‘Calculate the number of records’ on ‘Contacts’ section where ‘Access Processed Flag’ = ‘N’ . Other necessary condition to filter records could also be added based on business use case.

‘OR’ Gateway: We used ‘Exclusive Gateway (OR)’ element to branch the flow.

Conditional Flow Branch: To move down the flow, Condition was set to check if the count of records is greater than 0, then move forward.

Default flow: Default branch was used to end the process.

Read Contact: We used ‘Read Data’ element where ‘Access Processed Flag’ = ‘N’. Other necessary condition to filter records could also be added based on business use case.

Change Access Rights: For applying access, we used this condition and added the ‘Read’, ‘Edit’ and ‘Delete’ permission for user role same as the business requirement.

Modify Contact Flag: In the end, we used ‘Modify Data’ element to modify the value of ‘Access Processed Flag’ as ‘True’. This will help us to identify the record whose access is modified.

Settings of Business Process:  We increased the number of iterations to achieve this in bulk, based on the number of contacts in system. This is configurable based on the business case requirement.

Pro Tip: We could monitor the process through checking the number in quantity and refreshing it when the process was running.

We added a filter on Contacts section with the field ‘Access Processed Flag’ and values as ‘Yes’ and kept on refreshing the system to see the count going up.

 

In the second batch, run the process (if required), we can filter records where ‘Access Processed Flag’ = ‘N’ under set access process flag element for ‘modify records that match the condition’.

We did the same for ‘Accounts’ section using similar process as above but changed the section.

In the later requirement, to revoke ‘Delete’ permission for 2 user roles, we used similar process but changed values in ‘Change access rights’ element.

Benefits

This solution helped us grant and revoke certain permissions to specific roles based on customer requirement. We could also monitor the performance while the process is running.

AgilizTech does customization for bpm’online based on the requirements of a business. You can check out our posts for more information on bpm’online customization.

WordPress landing page integration with custom object in bpm’online

Problem Statement
During a lead generation process of a sales / marketing team, they should have the ability to capture as much as information about their lead in the bpm’online CRM. Currently bpm’online supports to capture few of the standard sections like leads, cases, orders & event registration through a WordPress integration of landing pages. This blog is about how to capture additional information to be gathered via landing pages other than the standard sections available as of today.

Solution
In this blog we will learn about the steps that needs to be followed to integrate WordPress landing page with a custom object in bpm’online.

Steps for integrating a WordPress landing Page to custom section

bpm’online configurations
Create the custom object to which landing page needs to be integrated. For example; create an object “UsrAdditionalCustomerData” (sample object name for explanation purpose)

In the [Landing pages and webforms] section, you can select one of the default webforms available as given below (Fig.1).

Fig. 1

In order to add new registration form for the custom object:

1. Add a new type “Additional Customer Data” landing page to the “Landing types” lookup, which is connected to the custom section.

Fig. 2

2. After adding a new web form in the “Landing types” lookup, use the Section Wizard to add a new page in the [Landing pages and web forms] section for the newly added type. To open the Section Wizard, go to the [Landing pages and web forms] section, and in the [View] menu select [Open section wizard] (Fig.3 & Fig.4).
Fig.3

Fig.4

3. Add new additional customer data web registration form in the section wizard (Fig.5). After saving you can see the additional customer data web registration form in the new dropdown (Fig.6).
Fig.5

Fig.6

Creating the landing page for custom object
Add new additional customer data web from and save the record. You can get the landing Id for the saved web page from the link (Fig.7). This landing Id can be used to integrate the landing page and web form in WordPress.

Fig.7

Integrating the WordPress Page to Custom Object

Install bpm’online plugin for WordPress (gravity forms, Contact form7). The steps to integrate bpm’online to a WordPress contact form is mentioned in the link below.
https://community.bpmonline.com/articles/bpmonline-plugin-wordpress-gravity-forms-contact-form-7?_ga=2.73954770.153193264.1562563622-1951839029.1560317595
In mapping of the fields (WordPress), 3rd party fields should be the column names in the UsrAdditionalCustomerData table (custom object) (Fig.8).
Fig.8

Use the Landing Id (Fig.7) as the form Id and the column names of the additional customer data table for mapping the landing page fields.

Processing the submitted data in bpm’online

After integration, when a new set of data is submitted in the additional customer data landing page, a corresponding record will be created in UsrAdditionalCustomerData object.
You can write a process to link the newly created record with the corresponding lead automatically or, can give a page where the sales team can review the submitted data and connect with corresponding lead.

Benefits
The solution helps in acquiring additional details (like customer requirement, alternate address, alternate contact information, additional company information etc.) of potential leads from a WordPress landing page.
To learn more on how AgilizTech does customization for bpm’online visit our bpm’online blog were we have explained different ways of customization for a business as per their requirements.

AgilizTech’s customization for bpm’online – Look up filtration based on flag in mobile app

In this fourth post of the series we will be discussing how to list only active products in the product selection page of the bpm’online sales enterprise edition mobile app.

The product section in mobile app has provision to activate or inactivate the products. In the desktop version if a product is inactivated, it will not list in any product selection page. In mobile page, however by default the product will be listed.

Business use case:

To display active products only in the production selection while booking orders through bpm’online mobile app.

Product:  bpm’online sales enterprise edition

Applicable for Version: 7.13 & above

Below is the desktop version of bpm’online sales enterprise wherein you can see that the Product Inactivated does not appear in the product selection page.

Fig 1: Product Inactivated

Whereas in the product selection page of the bpm’online mobile app the inactive product will be listed. This can be corrected by applying a certain code.

Fig 2: Before applying code change, product will be listed in mobile product lookup

Fig 3: After applying the code change, product will not be listed in lookup

Filtration of lookup columns based on the flag or a column is demonstrated below.

You should be knowing in which Workplace the changes need to be done. Select the workplace first to apply the changes.

In Custom package > MobileApplicationManifestDefaultWorkplace

For Example:

UsrMobileFilterModelConfig – If this is the business rule created for filtering the columns based on other columns, then you will have to mention this name in Model > Object’s Page Extension section.

Refer below code:

“Models”: {
“Order”: { {
“RequiredModels”: [
“Order”,
“Account”,
“OrderStatus”,
“OrderPaymentStatus”,
“OrderDeliveryStatus”,
“Currency”,
“DeliveryType”,
“PaymentType”,
“LeadType”,
“SocialMessage”,
“OrderProduct”,
“Product”,
“Unit”,
“Pricelist”,
“OrderVisa”,
“VisaStatus”
],
“ModelExtensions”: [],
“PagesExtensions”: [
” UsrMobileFilterModelConfig “, // Module Name
“UsrMobileOrderGridPageSettingsDefaultWorkplace”,
“UsrMobileOrderRecordPageSettingsDefaultWorkplace”
]
},
}

Create a module with the specified name. In this example it is UsrMobileFilterModelConfig.

In UsrMobileFilterModelConfig. module write the business event for Accessibility.

Find the code below.

Terrasoft.sdk.Model.addBusinessRule(“OrderProduct”,{
ruleType:Terrasoft.RuleTypes.Filtration,
events:[
Terrasoft.BusinessRuleEvents.Load,
Terrasoft.BusinessRuleEvents.Insert,
Terrasoft.BusinessRuleEvents.ValueChanged
],
triggeredByColumns:[“Product”],
filters:Ext.create(“Terrasoft.Filter”,{
modelName:”Product”,
property:”IsArchive”,
value:false
})
});

Here we are filtering “Product” lookup column in Order Products, based on Is Archive field in the product object. If the value is false, product will be listed; if value is correct i.e. if product is inactive, it won’t be listed. This Filtration should work while inserting new order, i.e. selecting a product for new order and while editing order product list for an existing order.

The event handling is explained below:
Find the code below.

events:[
Terrasoft.BusinessRuleEvents.Load, //On Data Load
Terrasoft.BusinessRuleEvents.Insert, //upon inserting new
Terrasoft.BusinessRuleEvents.ValueChanged //While Editing
]

Hence, if the above code is applied the inactive products will not be listed in the mobile product look up.

Click here to navigate to the main blog post which contains the complete list of bpm’online customization use cases.