Symptoms

Error while loading the presentation.

Type: Terrasoft.FileException

Message: Error while reading the file

Additional information:

Name: https://ourcompany.bpmonline.com/0/ServiceModel/EntityDataService.svc/ActivityFileCollection(guid'71fff37b-3e84-4042-a7bb-ec1b49876e1b')/Data?ForceUseSession=true&X-Terrasoft-Mobile=true

Call chain:

failure@file:///var/mobile/Applications/12072E52-5AC6-48DB-B608-A61D72AA7758/Documents/BPMonline700/AppStructure/rev_1/src/MobileUtilities.js?hash=b1e737c2-e66b-4a95-b823-bab46756b5b5:278:38

callback@file:///var/mobile/Applications/12072E52-5AC6-48DB-B608-A61D72AA7758/bpm'online.app/www/appV1/Common/lib/SenchaTouch/sencha-touch-all-debug.js:10397:31

Terrasoft.File.callFailure@file:///var/mobile/Applications/12072E52-5AC6-48DB-B608-A61D72AA7758/bpm'online.app/www/appV1/Common/Terrasoft.Mobile.Combined.js:4418:16

failure@file:///var/mobile/Applications/12072E52-5AC6-48DB-B608-A61D72AA7758/bpm'online.app/www/appV1/Common/Terrasoft.Mobile.Combined.js:4463:20

callback@file:///var/mobile/Applications/12072E52-5AC6-48DB-B608-A61D72AA7758/bpm'online.app/www/appV1/Common/lib/SenchaTouch/sencha-touch-all-debug.js:10397:31

file:///var/mobile/Applications/12072E52-5AC6-48DB-B608-A61D72AA7758/bpm'online.app/www/appV1/Common/Terrasoft.Mobile.Combined.js:4788:18

file:///var/mobile/Applications/12072E52-5AC6-48DB-B608-A61D72AA7758/bpm'online.app/www/plugins/org.apache.cordova.file/www/DirectoryEntry.js:112:22

callbackFromNative@file:///var/mobile/Applications/12072E52-5AC6-48DB-B608-A61D72AA7758/bpm'online.app/www/cordova.js:288:57

file:///var/mobile/Applications/12072E52-5AC6-48DB-B608-A61D72AA7758/bpm'online.app/www/cordova.js:1098:35

nativeEvalAndFetch@file:///var/mobile/Applications/12072E52-5AC6-48DB-B608-A61D72AA7758/bpm'online.app/www/cordova.js:1106:13

nativeCallback@file:///var/mobile/Applications/12072E52-5AC6-48DB-B608-A61D72AA7758/bpm'online.app/www/cordova.js:1095:38

global code@file:///var/mobile/Applications/12072E52-5AC6-48DB-B608-A61D72AA7758/bpm'online.app/www/appV1/MobileApp/MobileMainPage.html:1:47

Type: Terrasoft.FileSystemException

Message: URL to the object is incorrectly formed

Additional information:

Code: 5

Data: {

"code": 5

}

Cause

Bpm'online does not support working with files that contain the slash symbol (“/”) in the title. Since a link to a knowledge base article is, in fact, a link to a file, the application ignored this link and did not load anything locally.

Solution

What needs to be done:

- Rename the necessary knowledge base article;

Like 0

Like

Share

0 comments
Show all comments

Question

Contact search does not work, if I enter the first name and the last name in the order that differs from the database order..

Answer

The search by the [Full name] field is performed based on comparing strings. If you change the order of the first name and the last name, the string will be absolutely different and bpm'online will not be able to identify it as the initial contact. Besides, depending on the above mentioned order of the first and last names in the [Full name] field as well as in some system settings, bpm'online automatically populates contact fields that correspond to the first and last names separately.

If you are not sure what the order of the first and last names of a contact is, you can leave only the first or the last name in the serach string with adding the "%" character in front of the name. In this case, bom'online will search for all the strings that start with or contain the specified value. For example, if you specify the "%Best" value in the search field, bpm'online will display the "John Best" and "Best John" contacts (if such contacts are available in the database).

You can also select the "First name" or "Last name" field as a search parameter.

Like 0

Like

Share

0 comments
Show all comments
SDK
mobile
support
Q&A

Question

How do I hide the "Dashboards" section in the mobile app?

Answer

Create a custom schems (Source Code) (for example, "MobileUtilitiesCustom")

/* Hiding the "Dashboards" section */
 
Terrasoft.ApplicationUtils.initializeSystemData({
    success: function() {
        Terrasoft.ApplicationConfig.moduleGroups.get("sales").modules.splice(0, 1);
    }
});

In the mobile application manifest (for example, "UsrMobileApplicationManifestCustomMobile") specify the custom schema

{
    "CustomSchemas": [
        "MobileUtilitiesCustom"
    ]
}

 

Like 0

Like

Share

0 comments
Show all comments

Question

How can I add a loading mask to the [Connected to] detail of the [Accounts] section (version 7.7.0) in a diagram display mode?

Answer

To add a loading mask to the [Connected to] detail of the [Accounts] section in a diagram display mode, create a replacing client module for the AccountRelationshipDetailV2 schema and insert the following code therein:

define("AccountRelationshipDetailV2", [], function() {
    return {
        methods: {
            loadRelationship: function() {
                this.set("MaskId", Terrasoft.Mask.show({
                    selector: "#RelationshipTabContainer"
                }));
                this.callParent(arguments);
            },
 
            relationshipDiagramServiceCallback: function(response) {
                this.callParent(arguments);
                Terrasoft.Mask.hide(this.get("MaskId"));
            }
        },
 
        diff: /**SCHEMA_DIFF*/ []/**SCHEMA_DIFF*/
    };
});

Save the schema and reload the application page with clearing the cache.

 

Like 0

Like

Share

0 comments
Show all comments

Question

Mobile app. How to add the "Add" button to the lookup field which does not have its own section?

Answer

According to the base logic of the mobile application, you can only add new values in the lookup fields only if there is a section for this field with an edit page (for example, the “Owner” field and the “Contacts” section). In order to implement the "Add" button, you need to add a separate edit page and all necessary columns.

To do this:

Create a page schema with an Edit type for the Usrnomberoflid object (for example, the name of the UsrnomberoflidEditPage schema (page)). Quick page code generation mechanisms are described in the "How to quickly generate a page code for the mobile application" article:

Terrasoft.LastLoadedPageData = {
    controllerName: "Terrasoft.configuration.UsrnomberoflidEditPageController",
    viewXClass: "Terrasoft.configuration.UsrnomberoflidEditPageView"
};
 
Ext.define("Terrasoft.configuration.view.UsrnomberoflidEditPage", {
    extend: "Terrasoft.view.BaseEditPage",
    alternateClassName: "Terrasoft.configuration.UsrnomberoflidEditPageView",
    config: {
        id: "UsrnomberoflidEditPage"
    }
});
 
Ext.define("Terrasoft.configuration.controller.UsrnomberoflidEditPage", {
    extend: "Terrasoft.controller.BaseEditPage",
    alternateClassName: "Terrasoft.configuration.UsrnomberoflidEditPageController",
    statics: {
        Model: Usrnomberoflid
    },
    config: {
        refs: {
            view: "#UsrnomberoflidEditPage"
        }
    }
});

Create a schema and register the columns that we want to display on the page (for example, the name of the UsrMobileUsrnomberoflidModuleConfig schema (setting up columns in a new page)):

Terrasoft.sdk.GridPage.setPrimaryColumn("Usrnomberoflid", "Name");
Terrasoft.sdk.RecordPage.addColumnSet("Usrnomberoflid", 
    {
        name: "primaryColumnSet",
        isPrimary: true
    }, 
    [
        {
            name: "Name"
        }
    ]);
Terrasoft.sdk.RecordPage.addColumn("Usrnomberoflid", {
    name: "CreatedOn"
}, "primaryColumnSet");

Connect these schemas to the manifest. For example, "UsrMobileApplicationManifestOpportunities":

"Usrnomberoflid": {
    "Edit": "UsrnomberoflidEditPage",
    "RequiredModels": [
        "Usrnomberoflid"
    ],
    "PagesExtensions": [
        "UsrMobileUsrnomberoflidModuleConfig"
    ]
},

Now if you click on a record, all its information will be displayed; if you swipe across the field from right to left, you will see a list of available values with a quick filter.

Like 0

Like

Share

0 comments
Show all comments

Question

The Activities section only displays the records that the user has the rights to/is the owner of. How do I disable the the filter that only displays current user activities?

The button for adding other users' activities dissapears in the offline mode. How do I bring it back?

Answer

The Activities section only displays records of the current user to avoid synchronizing large amounts of data to the local database (this process takes a considerable amount of time). 

Important: We do not recommend disabling this filter.

A manifest schema is used to configure/remove filters. Learn more about configuring filers in the manifest in the following article - https://academy.bpmonline.com/documents/technic-sdkmob/7-12/manifest-ap…

An example of removing the filter:

"Remove": {
        "SyncOptions": {
            "ModelDataImportConfig": [
                {
                    "Name": "Activity",
                    "QueryFilter": null
                },
                {
                    "Name": "ActivityParticipant",
                    "QueryFilter": null
                }
            ]
        }
    }

To have the button show up again in the Activities section, you need to extend the Terrasoft.configuration.controller.ActivityGridPage class, namely the initializeOwnerButton method. Example:


initializeOwnerButton: function() {
   this.callParent(arguments);
   if (!Terrasoft.ApplicationUtils.isOnlineMode()) {
      var view = this.getView();
      var ownerButton = view.getOwnerButton();
      ownerButton.on("tap", this.onOwnerButtonTap, this);
   }
}

 

Like 0

Like

Share

0 comments
Show all comments
Q&A
support
mobile
SDK

Question

Due to special characters, or because of the long file name, synchronization does not take place.

It is necessary to change the name of the file so that it is displayed.

Answer

To customize the display of the file name, you need to make the following changes in the manifest (example in the Activities section on the ActivityFile details): set the UseRecordIdAsFileName flag to true for the binary column Data. Thus, file names will be generated based on the record ID.

"SyncOptions": {
    "ModelDataImportConfig": [
        {
            "Name": "ActivityFile",
            "SyncColumns": [
                "Id",
                "Name",
                {
                    "Name": "Data",
                    "UseRecordIdAsFileName": true
                },
                "Activity",
                "Type"
            ]
        }
    ]
},

 

Like 0

Like

Share

0 comments
Show all comments
knowledge base
SDK
Q&A
support

Question

We need to add a "LinkedIn" communication option type to the  [Communication options] detail.

I mean, we do not need to add a new "Web" communication option and paste a link to the LinkedIn contact profile, but to add a link which would have the "LinkedIn" name.

Answer

1. In the [Communication option types] lookup, add a new communication option and name it, e.g., "LinkedIn", the Communication type - Web

2. On the LinkedIn record, click "Edit" and find the recordId.

3. In configuration, replace the CommunicationUtils schema by copying the code from the original schema. Add ConfigurationConstants in the dependency as it is in the original.

4. In the replaced schema, update the isWebType() method by adding a recordId (see above) verification block and return true.

function isWebType(communicationType) {
    if (!communicationType) {
        return false;
    }
 
    if (communicationType === "5e4025d7-84cf-43ce-9a90-64a966c34853") {
        return true; /*LinkedIn*/
    }
 
    communicationType = communicationType.value || communicationType;
    return ConfigurationConstants.CommunicationTypes.Web.indexOf(communicationType) !== -1;
}

5. Save the changes, clear the cache, reset the site. As a result, the new LinkedIn communication option will look and will be processed as a link.

Like 0

Like

Share

0 comments
Show all comments

Question

Required "Organization"  field is affixed to the contact object "at the application level"

In the mobile app:



- Create a new contact

- Fill in the "Organization" field (created earlier in the web app)

- Save

- Synchronize

- An error occurs

Call Stack:

Contact (9d6652ba-5062-45d2-a7f2-1fb6c3ba1978) at Wed May 16 2018 11:13:07 GMT + 0300 (MSK). Error text: Type: Terrasoft.ODataRequiredColumnsEmptyValuesException

Message: The Organization field is a required field.

AdditionalInfo: {"position": 0, "error": {"code": "3", "message": {"value": "The Organization field is required"}, "innererror": {"message": "Organization field is required", "type": "Terrasoft.Core.Entities.RequiredColumnsEmptyValuesException", "stacktrace": "in Terrasoft.Core.Entities.Entity.ValidateRequiredColumns () \ r \ n in Terrasoft.Core.Entities .Entity.InternalSave (Boolean validateRequired, Boolean setColumnDefValue) \ r \ n in Terrasoft.Core.Entities.Entity.Save (Boolean validateRequired, Boolean setColumnDefValue) \ r \ n in Terrasoft.Core.Entti.SerathiraADe.V. \ r \ n in Terrasoft.Core.Entities.Services.ServiceContext.SaveChanges () "," internalexception ": null}}}

Everything works correctly if the field is not required.

Answer

Contact and Account objects are bound by cyclic links (for example, in a mobile application, both a contact and an account (as well as the connection between them) can be added).

Therefore, when synchronizing records, requests are split for correct storage: 

First, creating a contact record, then creating an account, then the lookup fields of the connections between them are updated with the necessary values of the newly created data. Thus, the binding will not work.

As a workaround, we can propose making it required at the card level using business rules:

Terrasoft.sdk.Model.addBusinessRule('Contact', {
    ruleType: Terrasoft.RuleTypes.Requirement,
    triggeredByColumns: ['Name']
});

Then add the required module to the manifest in the ModelExtensions section.

An example implementation can be found in the "MobileActivityModelConfig" schema.

Like 0

Like

Share

0 comments
Show all comments

Symptoms

An error occurs during synchronization:

The element with the "90a3e9f6-........................-7c4aadb41f28" identifier is not found.

Cause

The SysLookup table is not used in desktop versions 7.5 and 7.6, but is used in the mobile application below version 7.7.1.

In the SysLookup table, there are records that refer to nonexistent schemas, for example:

90A3E9F6-12D4-45B5-9122-7C4AADB41F28

A85932A3-30A5-49D7-9627-7F749A055AB7

CCF7D813-FC83-47AD-BE61-8F3B3B98A54F

E0AA5FA2-0910-478D-943B-E9C2579AD7B4

Solution

Run script:

UPDATE [SysLookup]
SET IsSimple = 0
WHERE IsSimple = 1
AND NOT EXISTS (select 1 from SysSchema ss WHERE ss.[UId] = SysEntitySchemaUId)

 

Like 0

Like

Share

0 comments
Show all comments