Hi Community,

Recently we used BPM Online 7.13, now when I try to debug (client debugging) using Chrome developer tools, I cant find any script lets say for example AccountPageV2.js the only thing listed on sources are css and image files. But compared to BPM Online 7.12, I can see all the scripts(most especially edit pages) when the form is open. Is there any configuration that needs to be turned on?

Like 0

Like

2 comments

Dear Fulgen, 

The reason you can't see these scripts is because bundling is turned on, it accelerates the system performance but makes it harder to debug. To turn it off you may send a letter to the support team of bpm online.

Best regards,

Dennis 

Hello Fulgen,

This is new in 7.13. You can turn on debug mode for the client and then you'll see the separate scripts instead of just the combined minified file. To turn on debug mode execute the following in the browser console: 

Terrasoft.SysSettings.postPersonalSysSettingsValue("IsDebug", true)

Refresh your browser and then you'll see the separate script files to debug. When you're done, be sure to turn debug mode back off again with the following:

Terrasoft.SysSettings.postPersonalSysSettingsValue("IsDebug", false)

Ryan

Show all comments

Hi,

I have an object that ha DateTime column in which I store TimeSpan rather than DateTime. For example I will store duration of a meeting (1 hour an 30 minutes). when I show this column in a section grid I get 12:30 AM because I my culture is set to Canada. I would like to show it as 01:30. Do you have any recommendations how t achieve it?

Like 0

Like

1 comments

Hello Kirill,



You want to store value with "TimeSpan" data type in column that has "DateTime" type. This can lead to errors during saving or processing data, so it is not recommended to do that. An alternative way to achieve it is to store info about duration in three separate fields: start datetime, end datetime and duration which is calculated by subtracting end time and start time.



Also, another way is to create lookup with values of duration in step e.g. 15 minutes. After that you need to add a new field with lookup data type to the page of the object which this detail represents and bind this field to the created lookup.



Best regards,

Alex

Show all comments

In my Lookup it must show only those contacts who have Specific role.

Example:

Contact-1 , Contact-2 are present

Contact-1 Have Role-1 and contact-2 will have Role-2

Lookup must show only Contacts with Role-1 . 

If not possible Can we have workaround for this .

 

In my Example it will show all contacts who are system users.

for these i want to filter collection based on role.

I tried this Please let me know the changes needed.

"lookupListConfig": {

                    // Array of filters used for the query that forms the lookup field data.

                    "filters": [

                        function() {

                            var filterGroup = Ext.create("Terrasoft.FilterGroup");

                            // Adding the "IsUser" filter to the resulting filters collection.

                            // The filter provides for the selection of all records in the Contact core schema

                            // to which the Id column from the SysAdminUnit schema is connected, for which

                            // Id is not equal to null.

                            filterGroup.add("IsUser",

                                Terrasoft.createColumnIsNotNullFilter("[SysAdminUnit:Contact].Id"));

                                                        // Adding the "IsActive" filter to the resultant filters collection.

                            // The filter provides for the selection of all records from the core schema.

                            // Contact to which the Id column from the SysAdminUnit schema, for which

                            // Active=true, is connected.

                            filterGroup.add("IsActive",

                                Terrasoft.createColumnFilterWithParameter(

                                    Terrasoft.ComparisonType.EQUAL,

                                    "[SysAdminUnit:Contact].Active",

                                    true));

                            return filterGroup;

                        }

                    ]

                }

            }

Like 0

Like

1 comments

Dear Sushma,

In order to check whether a contact has particular role you need to create a query to the SysAdminUnitInRole table. Basically setting up the filter to check whether current user has the needed role in SysAdminUnitInRole table.

Please modify your filter settings to read from correct table. Also, please see the article below, which describes how to create queries to the database. (particularly Definition of root schema. Creation of paths to columns against root schema. Examples.)

https://academy.bpmonline.com/documents/technic-sdk/7-13/use-entitysche…

Regards,

Anastasia

Show all comments

Hi Community,

Good Day

How can I  dynamically Hide/Unhide options under Print button based on some conditions (example based on value of some lookup field).

 

 

Like 1

Like

5 comments

Dear Fulgen,

In order to achieve such task you need to add custom code customization. Please see the instruction below, hope you will find it helpful. The realization should be added to the page schema.

1. Bind options' visibility on the virtual attribute. Set it to false by default:

"setFieldVisibility": {
    dataValueType: Terrasoft.DataValueType.BOOLEAN,
    type: Terrasoft.ViewModelColumnType.VIRTUAL_COLUMN
    value: false
}  

2. In onEntityInitialized method call your custom method, which will be setting the attribute value to true or false based on filed value:

onEntityInitialized: function() {
  this.callParent(arguments);
  this.setOptionsVisibility();
}

3. Add custom method to check the value of the filed on the page and set visibility based on it.

In order to change dynamically, please add another attribute on the page, where based on the particular field change the method is triggered and changing the visibility:

"OnLookUpChange":{
    "dependencies":[
        {
           "columns":["UsrLookup1"],
           "methodName":"setOptionsVisibility"
        }
      ]
}

Regards,

Anastasia

 

 

Fulgen,

There is a marketplace solution that might do what you're after: https://marketplace.bpmonline.com/app/printable-forms-filtering-bpmonli…

Anastasia Botezat,

Hi Anastasia, Thanks for your answer.



Now I can already handle event based on the value of lookup thru:

"OnLookUpChange":{
    "dependencies":[
        {
           "columns":["UsrLookup1"],
           "methodName":"setOptionsVisibility"
        }
      ]
}

But, now how can i get the id of each printables then set it to hidden/unhidden.

try this function to hide/unhide options by Id

 

            preparePrintFormsMenuCollection: function (printForms) {

                this.callParent(arguments);

                debugger;

    //    var stage = this.get("Stage");

        printForms.eachKey(function (key, item) {

            if(key !="c1af36b1-9550-46c4-8a2c-ff6450eed242".toLowerCase())

            {

                item.set("Visible", false);

            }

        }, this);

    }

 

put it in the method property 

Dear Fulgen,

Please use the code, which was provided by Mohamad. This is an overridden basic method for printable collection, which sets properties for button options. In order to check the Id of needed printables, you can right-click on the printable and inspect the item. Its Id will be indicated in the HTML id property.

In case you will have any further question, please let us know.

Regards,

Anastasia

Show all comments

Hi Community,

How can I filter the detail based on the selected look up field. The list in detail will depend on the selected value in the look up so every time the user will change the value of look up the detail list will change also.

 

Thanks

Like 0

Like

2 comments

Dear Fulgen,

Hope you are doing great.

Unfortunately, there are no any basic tools in the system to implement this idea, however there is one solution. You can make up a business processes that will trigger once you modify some lookup data on a page. For instance, once you change the account type to some particular one, the business entity detail will also be changed according to the account type.

Hope this solution will help you. 

Best regards,

Dean 

I can bring Contact's Communication options to Lead's detail by binding Communication options.Contact to Lead.Contact field. Maybe you want similar behavior?

Show all comments

Is it possible to change controls' layout dynamically? Also: is it possible to add controls dynamically?

Like 0

Like

8 comments

Dear Carlos,

Could you please let us know more details on your question? What goal do you want to achieve? Thank you so much beforehand.

Looking forward to your clarification.

Regards,

Dean

I have two fields: object type chosen from a lookup (A) and object type written manually by some user in a text field (B). There should be only one of the fields A and B filled up at one time and I only want to show the one currently filled up. What I tried to do, is this layout and setting the visible property conditionally:

| A | some other field |
 
| B |

What I tried to achieve is:

| A | some other field | 
or
| B | some other field |

What I got:

| A | some other field | 
or
| some other field |
| B |

 

Dear Carlos,

Thank you for the reply. 

You can achieve this result by creating 2 business rules. Here is the example: On the Account page you have two fields 'Also known as' and 'Code' https://prnt.sc/lnngw2. You can create two business rules, the conditions are as follows: https://prnt.sc/lnnixz and https://prnt.sc/lnnjrt

Thus, you create to conditions that say - 'if one field is filled it, another one is not visible'. The results are in the pictures: http://prntscr.com/lnnm7t and http://prntscr.com/lnnkp4

Hope this solution will help you out.

Best regards,

Dean

Dean Parrett,

The problem is not to hide the fields. The problem is that when I hide the field A some other field on the right takes its place. I would like the field B to take place of A.

Carlos Zaldivar Batista,

If only one of the two fields will be displayed at a time, you can edit the page to have both controls occupy the same space (have the same row & column values). Technically, both controls will be in the exact same spot with only one showing at a time.

Ryan

Dear Carlos,

Yoг can also check the following post, it might help you to implement your task: https://community.bpmonline.com/questions/alignment

Ryan Farley,

Thank you, this seems to work. The bad part is that if I save the page using the designer the row and column settings return to the previous state. I'll have to remember to set them up again every time I use it.

Carlos Zaldivar Batista,

That is good to know, I wasn't aware the designer changed that back. I'll have to watch out for that.

Ryan

Show all comments

What is the correct way to perform the query in JSON to obtain the records that start with the letter "Y"?

The next JSON get the columns GivenName, MiddleName and Surname from "Contact":

{
    "RootSchemaName":"Contact",
    "OperationType":0,
    "Columns":{
        "Items":{
            "GivenName":{
                "Expression":{
                    "ExpressionType":0,
                    "ColumnPath":"GivenName"
                }
            },
            "MiddleName":{
                "Expression":{
                    "ExpressionType":0,
                    "ColumnPath":"MiddleName"
                }
            },
            "Surname":{
                "Expression":{
                    "ExpressionType":0,
                    "ColumnPath":"Surname"
                }
            }
        }
    },
    "AllColumns":1
}

And return all que records from "Contact".

When I apply the filter GivenName = Yxyxyx

{
    "RootSchemaName":"Contact",
    "OperationType":0,
    "Columns":{
        "Items":{
            "GivenName":{
                "Expression":{
                    "ExpressionType":0,
                    "ColumnPath":"GivenName"
                }
            },
            "MiddleName":{
                "Expression":{
                    "ExpressionType":0,
                    "ColumnPath":"MiddleName"
                }
            },
            "Surname":{
                "Expression":{
                    "ExpressionType":0,
                    "ColumnPath":"Surname"
                }
            }
        }
    },
    "AllColumns":1,
    "Filters":{
        "RootSchemaName":"Contact",
        "FilterType":1,
        "ComparisonType":3,
        "LeftExpression":{
            "ExpressionType":0,
            "ColumnPath":"GivenName"
        },
        "RightExpression":{
            "ExpressionType":2,
            "Parameter":{
                "DataValueType":1,
                "Value":"Yxyxyx"
            }
        }
    }
}

Returns all records with the name GivenName equal to "Yxyxyx"

But an error returned when I sent the query GivenName starts with "Y", like this:

{
    "RootSchemaName":"Contact",
    "OperationType":0,
    "Columns":{
        "Items":{
            "GivenName":{
                "Expression":{
                    "ExpressionType":0,
                    "ColumnPath":"GivenName"
                }
            },
            "MiddleName":{
                "Expression":{
                    "ExpressionType":0,
                    "ColumnPath":"MiddleName"
                }
            },
            "Surname":{
                "Expression":{
                    "ExpressionType":0,
                    "ColumnPath":"Surname"
                }
            }
        }
    },
    "AllColumns":1,
    "Filters":{
        "RootSchemaName":"Contact",
        "FilterType":1,
        "ComparisonType":16,
        "LeftExpression":{
            "ExpressionType":0,
            "ColumnPath":"GivenName"
        },
        "RightExpression":{
            "ExpressionType":2,
            "Parameter":{
                "DataValueType":1,
                "Value":"Y"
            }
        }
    }
}

The error return is:

{
    "responseStatus": {
        "ErrorCode": "SqlException",
        "Message": "Incorrect syntax near '@P1'.",
        "Errors": []
    },
    "rowsAffected": -1,
    "nextPrcElReady": false,
    "success": false
}

 

And, How do you filter two or more columns?

Like 0

Like

2 comments

Try changing the ComparisonType from:

"ComparisonType":16

To 

ComparisonType":9

9 = STARTS_WITH (16 = "NOT_EXISTS)

https://academy.bpmonline.com/api/jscoreapi/7.12.0/index.html#!/api/Ter…

Thank you.

It worked

Show all comments

Hi Community,

How can i make my detail editable directly on grid without opening another form to edit it?

Thanks

Like 0

Like

2 comments

Hello,

This article will provide the details you need to make the detail editable in the grid itself. https://academy.bpmonline.com/documents/technic-sdk/7-13/adding-detail-…

Ryan

Thanks Ryan, this example is what I am looking for.

Show all comments

Is it possible to search parts of names in lookup fields? If I have a record named 'XYZ 123' and I search for '123', I get no results.

Like 0

Like

2 comments

Hello.

You can use the '%' symbol in order to search for the records using only parts of words. In your case it would be %123.

From our side, we have registered a suggestion for our R&D team in order to enhance the search functionality in the upcoming releases.

Best regards,

Matt

Matt Watts,

Ok, thanks. I see it works only in the window mode though, not in dropdowns.

Show all comments

Hi,

When I am trying to send request from BPM (http://localhost:82) to external web app (https://localhost:58733) via 'call web service' system action I am getting an error:

"system.net.webexception could not establish secure channel for ssl/tls ---> system.security.authentication.authenticationexception the remote certificate is invalid"

What I am doing wrong? 'Call Web Service' system action should work with SSL/TLS without any problem?

Best regards,

Tom

 

Like 0

Like

2 comments

I've used Call Web Service with SSL without issue. That error is a general .NET error that usually relates to issues with the certificate and likely means one of the following is true:

  • The certificate doesn't match the URL.
  • The certificate is self-signed and not added as a trusted certificate.
  • The certificate is expired.
  • The certificate is signed by a root certificate that's not installed on your machine.

If the cert is ok, and since this is a local install, you can try going to the external URL in IE (on the server where Bpm'online is installed), click the lock icon then "View Certificates", then click the button to "Install Certificate" (be sure you select to install on "Local Machine" and not "Current User"

Tom,

Please use this article to troubleshoot the issue https://blogs.msdn.microsoft.com/friis/2017/10/10/troubleshooting-tls-s… and also Ryan is right. The reason is probably in certificate so that's why you need to check it firstly.

Best regards,

Oscar

Show all comments