Hi,

I will have to auto populate/bind a lookup column based on other column value.

My scenario is : I have added a lookup object UsrTerritory -- Values are Domestic & International

I have added a column with the above lookup reference in Account called "UsrTerritory".

 

This column should auto bind to domestic if the country is india, else to international.

 

In Edit page I have mentioned like 

attributes: {

             "UsrTerritory":

            {

                dataValueType: Terrasoft.DataValueType.LOOKUP,

                dependencies: [

                    {

                        columns: ["Country"],

                        methodName: "GetTerritoryDetails"

                    }

                ]

            },

        },

 

 

    GetTerritoryDetails :function()

            {

                //var Country = this.get("Country").displayValue;

                 

                var esqOrder = this.Ext.create("Terrasoft.EntitySchemaQuery", {

                    rootSchemaName: "UsrTerritory"

                });

                esqOrder.addColumn("Id");

                esqOrder.addColumn("Name");

                

                var DomesticValue,InternationValue;

                    esqOrder.getEntityCollection(function (result) {

                         if (!result.success) {

                            this.showInformationDialog("Data query error");

                        return;

                         }

                        result.collection.each(function (item) {

                            if(item.get("Name") === "Domestic"){

                            DomesticValue = item.get("Id");

                            }

                            if(item.get("Name") === "International"){

                            InternationValue = item.get("Id");

                            }

                        });

                        if(this.get("Country").displayValue ==="India")

                        {

                            this.set("UsrTerritory", DomesticValue);

                        }

                        else{

                            this.set("UsrTerritory", InternationValue);

                        }

                    }, this);

            

            }

 

 

But am unable to achive in binding the column. It says undefined.

Please help

 

Like 0

Like

1 comments

Dear Sriraksha,

You are getting an 'undefined' value due to the fact, that in lookup fields you are supposed to pass an object, but not just GUID. In order to check what is set and stored in the lookup fields you can run a simple procedure: select a value in the lookup, set debugger to stop when selecting and check what is in there. You will see an object. Therefore, in your method you need to set an object to the lookup field. Be sure that such object has at least 2 fields required:

{    displayValue: "The text that will show in the field",             value: "unique value identifier"

}

Regards,

Anastasia

Show all comments

Hi,

On Order section there is a OOB lookups field called "Client". On click we can select either Account or Contact because both list are appearing for selection.

By default the field "Client" is a mandatory field. From section wizard > Edit Page, This field is not removing and we cannot make it non-mandatory. I need to avoid this field.

 

Any help will be highly appreciable

 

Regards

Like 0

Like

2 comments

Dear Muhammad,

There is a part of code in OrderPageV2 in Order package that looks like:

                    "Client": {

                        "caption": {"bindTo": "Resources.Strings.Client"},

                        "dataValueType": this.Terrasoft.DataValueType.LOOKUP,

                        "multiLookupColumns": ["Contact", "Account"],

                        "isRequired": true

                    },

isRequired attribute makes this field required and to make it non-mandatory you need to create a replacing schema and add your logic that will make this field non-mandatory.

Best regards,

Oscar

Hi,

Yes I already found it however thanks

 

Regards

Show all comments

I would like to know how to listen to merge event with business process.

For instance, delete, create and modify events are there:

420.png

I would like to get Id of an entry that was merged, and then use it in business process. 

"Modify" is not always applicable. Sometimes an entry is not considered modified when merged.

Thanks in advance

Like 0

Like

1 comments

Hello Yuriy, 

There is no such out of the box functionality that allows you to subscribe on merge event due to unexisting of such event.

As workaround, you may try to modificate Deduplication process (starts when records are merging). The records that remains in the database is called golden record and id of golden record is the first id in collection that is transferred to deduplication process. 

So once you have this golden record, you may process is it as you wish.

Also please note that process of merging records is asynchronous. 



Regards,

Alex

Show all comments

Hi Community,

Any idea why SysAdminUnit is not accessible in esq when user is portal user.

 

Like 0

Like

1 comments

Dear Fulgen,

Could you please let us know what is your business task, so we could give you a proper answer to this question?

Looking forward to your reply.

Dean

Show all comments

Hi everybody.

We need to create filters to display only accounts owned by the current user. The goal is to create just a unique filter (i.e. My Accounts) that compares the Account Owner with the Logged in User. So the same filter will show different accounts depending on the active user. Thanks for your comments.  Diego

Like 0

Like

2 comments

Hi Community,

Any idea how we can upload custom HTML file on BPMOnline hosted site.

Example URL: https://testcrm.bpmonline.com/test.html

I need to access this html in hosted bpmonline system

 

 

Like 0

Like

2 comments

Hello Fulgen,



It is not allowed to host any sites (or html files) in bpm'online.

In such case, you may host them on your own server or use any other hosting service.



Best regards,

Alex 

you can deploy your custom HTML in your hosting, and then call them with webpage or iframe

Show all comments

How do you restrict access to a custom process? For example, if I want to ensure that only System Administrators can run a process, is the only way to restrict who can run the process by checking the current user in the process?

Like 0

Like

1 comments

Hello Janine,



Unfortunately, bpm'online has no business process rights functionality.

Your suggestion to check the current user in business process seems to be a nice workaround. I think the most convenient way to implement it in script task.



Best regards,

Alex

Show all comments

Hi,

Is there a way to fetch System setting values using ESQ Server side.

I need to validate based on system setting value.

 

Please help.

 

Like 1

Like

8 comments

You can get a system setting using the following C# :

var mySetting = Terrasoft.Core.Configuration.SysSettings.GetValue(UserConnection, "MyCustomSetting").ToString();

Ryan

Ryan Farley,

Can i use it in server side?

Sriraksha KS,

Yes. That is C# for executing it server side (for example, in a script task or a configuration service)

Ryan Farley,

How can i fetch in client side? i need to take the value from system settings in ContactPageV2. how can i do that. Please help!!

Sriraksha KS,

_initLmsDocumentations: function() {

                    var sysSettingsNameArray = ["UseLMSDocumentation"];

                    Terrasoft.SysSettings.querySysSettings(sysSettingsNameArray, function(values) {

                        this.set("UseLMSDocumentation", values.UseLMSDocumentation);

                        if (values.UseLMSDocumentation === false) {

                            this.set("IsAcademyBannerVisible", false);

                        }

                        Terrasoft.AcademyUtilities.getUrl({

                            scope: this,

                            contextHelpCode: this.name,

                            callback: this._onGetAcademyUrlCallback

                        });

                    }, this);

Are we still not able to set SystemSetting values for current user?

 

I have a case where I'd like to run an API method which return Token values, which I'd like to store in System Settings

Julius,

You can do it using a script task with the following code:

var userConnection = Get<UserConnection>("UserConnection");
Terrasoft.Core.Configuration.SysSettings.SetValue(userConnection, "IsDebug", false);
return true;

As a result the system setting with "IsDebug" code will get a "false" value after the execution of the code. So you can use this approach if needed.

Julius,

I have an article here that outlines how to read and set system settings from both server-side and client-side code, as well as per-user setting values. 

https://customerfx.com/article/retrieving-and-setting-system-settings-i…

Ryan

Show all comments

I read the article "https://academy.bpmonline.com/documents/technic-sdk/7-13/creating-anonymous-web-service ". The problem in creating an anonymous web service is resolved by configuring on web.config. However, I want to resolve that not using web.config.

Like 0

Like

2 comments

It's not possible.

Please note that in order to change web.config you need to deploy the application locally, change the config, test it, then send the config to support@bpmonline.com then test it after applying the changes. 

Show all comments

Why are not manually created activities seen in my Business process task area in my Communication panel? (Even with the Show future tasks -checkbox checked).

I'd like to have manually created tasks seen in this panel as well.

I have read the Academy information about this thuroughly and I feel the requirement for the tasks created manually are met and therefor should be shown.

Academy post : https://academy.bpmonline.com/documents/base/7-13/business-process-task…

Like 0

Like

1 comments

Dear Julius,

This section (process task) is used only for records that are created with business process and are connected to it. If you want to see activities created manually you can use notification panel: http://prntscr.com/n7xvwk

Best regards,

Angela

Show all comments