Hello all,

 

How can I modify the page layout of a detail that isn't also a section within the Creatio mobile app? I only get the option to change how it's connected to a page. 

I need to be able to change the fields that are shown but the embedded detail won't do the trick because it's not clear on when one detail record ends and the next begins.

 

Thanks in advance for your help.

Like 0

Like

1 comments

Hello Kevin,

 

It is necessary to go to the section Page Setup, scroll down to New button, select Embedded detail option, add your detail and hit New column to add required fields. You can also the fields them in the required order there. 

 

Regards,

Dean

Show all comments

Hello, 

I have button to set some data in one field. this field is empty before button click, so it is hidden on record page. after button click when I set data to this field, I want to show this field immediately.

 

How can I reload record page? 

Like 0

Like

4 comments
Best reply

Hello Luka,

 

To solve your business task you need to add visible value to the field and bind it to the method:

"visible": {"bindTo": "visibleMethodName"}
and create an attribute 
"hideFieldAttribute": {
        "dataValueType": Terrasoft.DataValueType.BOOLEAN,
        "value": true
      },

This method will be triggered by a button click and should set an attribute:

buttonAction: function() {
        this.set("hideFieldAttribute", false);
      },

This method is bound to the visible property of the field:

 visibleMethodName: function() {
        var result = this.get("hideFieldAttribute");
        return result;
      },

Please let us know if it helps!

 

Best regards,

Bogdan S.

Hello Luka,

 

Have you tried calling the this.reloadEntity(); method on custom button click? What was the result?

 

Best regards,

Oscar

reloadEntity is for web app. in mobile app, record instance doesn't have reloadEntity :( 

Hello Luka,

 

To solve your business task you need to add visible value to the field and bind it to the method:

"visible": {"bindTo": "visibleMethodName"}
and create an attribute 
"hideFieldAttribute": {
        "dataValueType": Terrasoft.DataValueType.BOOLEAN,
        "value": true
      },

This method will be triggered by a button click and should set an attribute:

buttonAction: function() {
        this.set("hideFieldAttribute", false);
      },

This method is bound to the visible property of the field:

 visibleMethodName: function() {
        var result = this.get("hideFieldAttribute");
        return result;
      },

Please let us know if it helps!

 

Best regards,

Bogdan S.

I resolved it, using business rule. Thanks a lot, you gave me good point.

record.changeProperty("UsrGeneralAgreementUrl", {
    hidden: false
});

 

Show all comments

Hello, 

I want to override initializeView or pageLoadComplete in mobile app. I have to do some changes before page load completes.

 

on web app I override onEntityInitialized function and I can do things there.

 

How can I override functions in mobile app?

Like 0

Like

3 comments

Hello Luka,

 

If you need to perform any actions on the mobile before the page is loaded, you can use business rules functionality for that. Please check this Academy Article.

 

Best regards,

Bogdan S.

Bogdan Spasibov,

Yes, I have business rule and I am setting new value of empty field using it. Because of this field is empty, it is hidden on record page and after business rule sets value, it is stays hidden.

But, when I select another contact and then select updated contact again, it shows updated field.

 

Picture 1 . Updated, but didn't change focus

 

Picture 2, Changed focus and returned to previously selected contact

 

Now this Field 'UsrGeneralAgreementId' is visible with its data.

I couldn't override initializeView function, but resolved it using business rule and resolved field visibility problem using changeProperty function.

 

record.changeProperty("UsrGeneralAgreementUrl", {
    hidden: false
});

 

Show all comments

Hi Community,

In mobile, we have fields which basically of data type decimal. If these are not in focus, it should show on proper decimal format the same behavior in your web application. Any idea how to achieve this?

 

The below example should show 25,046

Like 0

Like

1 comments

Hi Community,

 

I able to change css dynamically for section list view on CRM (browser). This article I followed.

 

Question: How to change css dynamically for a section list view column on mobile interface? There is no documentation exist. I need to change background color of case status on mobile list view on the basis of its value

 

Any help will be highly appreciable.

 

Regards

Like 0

Like

1 comments

The article by the link below describes how to add custom css to a mobile application:

https://community.creatio.com/articles/adding-custom-css-mobile-application

Please find the correct selector for the element you want to apply the custom css to. For example, it's possible to change the background color for the records in the Case section using selector

$("div[class='ts-list-subtitle-column']").css("background-color", "yellow");

 

 

 

 

 

Show all comments

I am trying to create a mobile rule. This is in my DEV instance. Please see the screenshots.

My rule does not take effect in the mobile app and I am not sure why? Can anyone see any glaring issues?

 

Thanks,

Heather

Like 0

Like

2 comments

Heather,

Seems that the reason is in fact that you've specified your value using double quotes "", but it should be 'stage_id' (using single quotes instead).

Also you need to add your business rule to ModelExtensions, not PageExtensions of your mobile application manifest.

Please try applying stage id in such a way and also applying your business rule to ModelExtensions it should help, because there is nothing else that can cause the problem.

Best regards,

Oscar

Show all comments

Hi Community,

In mobile, how we can assign default workplace per user so that after login mobile user don't need to go to Settings->Workplace and change it everytime.

Like 0

Like

3 comments

Hi Fulgen,

To have mobile workplace by default you should go to the system settings -> search for "Default workspace" -> Choose the lookup "Mobile application workspace" -> the field Default value should be filled by the name of the workspace you want to be by default.

Thanks Bohdan,

But I believe this setup will applicable for all users, I want something to be it like per user of per role 

Fulgen Ninofranco,

You can use Access rights tab when setting up a workplace to choose roles.

Show all comments

Hi,

I am trying to override a few methods in the MobileFileService class on Mobile as I need to replace the default logic of using the "FileService/GetFile" with a custom fetch logic from Sharepoint as we are using it as our document repository.

I have tried the below steps.

1) Created a new class and overrode the existing logic with the custom logic for Sharepoint.

Ext.define("Terrasoft.configuration.MobileFileServiceOverride", {
	override: "Terrasoft.FileService",
	alternateClassName: "Terrasoft.MobileFileServiceO",
	singleton: true,
	/*
	* @override
	*/
	getDownloadServiceUrl: function(config, schemaUId) {
		var serviceUrl = Terrasoft.ServiceHelper.getServiceUrl("FileService", "GetFile");
		var serviceUrlSP = "rest/SharepointService/File";
		var schemaName = config.fileRecord.self.modelName;
		if(schemaName === "CUSTOM"){
			return Ext.String.format("{0}/{1}/{2}", serviceUrl, schemaUId, config.fileRecord.getId());
		}
		else {
			return Ext.String.format("{0}/{1}/{2}", serviceUrlSP, config.fileRecord.getId(), schemaName);
		}
	}
});

  2) In the manifest file, I included the new class in the "CustomSchemas" attribute.

{
 
	"CustomSchemas": [
        "UsrMobileFileServiceOverride"
    ],
 
	"SyncOptions": {
		"SysSettingsImportConfig": [
			"DefaultMessageLanguage",
			"PrimaryCurrency"
		],
 
...
...
...
}

While debugging this using the emulator, I see that the method is not getting overridden. It still calls the older method. Am I missing a step here? Any help is deeply appreciated.

Thanks in advance...

Like 0

Like

1 comments

Hi,

This is resolved now. I actually missed another step. We also need to include the new class "UsrMobileFileServiceOverride" as a page extension for the object like opportunity, customer, etc in the manifest file under Models -> Opportunity/Customer -> PageExtensions.

Show all comments

Hi,

I am relatively new to doing development. I have only used it for the addition/removal of columns in objects, and for cleaning up extra versions of Business Processes.

I am trying to learn more and am starting with trying to set up Business Rules for the Mobile application. I am using this article: https://academy.creatio.com/documents/technic-sdkmob/7-15/business-rules-mobile-application.

 

I can see where to update the extension section to add a business rule to a page, but I don't see where I create the rule itself. It says to use "add business rule", but where do I call that? Is it within the dev interface as a new object?

 

Thanks,

Heather

Like 0

Like

8 comments

Dear Heather, 

To add business rule you would need to create your custom module where you add the code similar to the one in the article, after that create a replacing schema for MobileApplicationManifestDefaultWorkplace and add the Module to the ModelExtensions. I've found a bit more detailed instruction here:

http://agiliztech.com/2019/06/11/conditionally-hideshow-fields-bpmonline-mobile-app/

Best regards, 

Dennis 

Thanks very much, that is helpful.

So I choose Module as the object type for the new rules? 

Dear Heather, 

Yes, you would need to create a module. 

Dennis Hudson,

Can you put code for more than one rule into one module, or do I create one for every rule? Thanks

Heather,

You need to create separate modules for each business rule and put those models to models extensions in MobileApplicationManifestDefaultWorkplace.

Thank you for your help so far. I did a test but my rule is not taking effect in the app. Can you see if you see any glaring errors?

Hello Heather,

Please mention the Object name to which you are applying the business rule.

As per your screenshots 

You need to mention the Object Name in line which i have highlighted.

In the below screen shot, you have defined the module name in page extensions of Opportunity . So the Object Name should be Opportunity. 

 

 

regards,

Sriraksha KS

Senior Software Engineer

AgilizTech software services pvt ltd

Show all comments

Hi Community,

I have this scenario below, I want to create a business rule that will hide/unhide field if record is in add mode or edit mode. How can I possibly do this?

Like 0

Like

2 comments

Hi Community, Any idea on this?



Thank you so much

Dear Fulgen,

It is possible to check a mode of a page using the “phantom” property of the “record” object https://prnt.sc/qkxh4q

If the value of the property is equal to “true” it is mean that the page is in the add mode and vice versa. Please see an example of the code below:

Terrasoft.sdk.Model.addBusinessRule("Case", {

            ruleType: Terrasoft.RuleTypes.Custom,

            position : 2,

            triggeredByColumns: ["UsrIncidentType"],

            events: [Terrasoft.BusinessRuleEvents.ValueChanged],

            executeFn : function(record, rule, column, customData, callbackConfig){

                        if(record.phantom)

                        {

                                    // true, when adding a new record (add mode)

                                    alert("New record");

                        }

                        else

                        {

                                    // edit mode   

                                    alert("Old record");

                        }

                        Ext.callback(callbackConfig.success, callbackConfig.scope, [true]);

            }

});

Please find more information about a custom business rules in the article by the link below:

https://academy.creatio.com/documents/technic-sdkmob/7-15/custom-business-rules-mobile-application

Best regards,

Norton

Show all comments