Hello,
I have a slightly urgent question on how to get Address from Account lookup
the code lookslike this
Terrasoft.sdk.Model.addBusinessRule("Activity", {

  name: "LatLongPreFilled",

  ruleType: Terrasoft.RuleTypes.Custom,

  triggeredByColumns: ["Usrcheck_in"],

  events: [

    Terrasoft.BusinessRuleEvents.ValueChanged,

    Terrasoft.BusinessRuleEvents.Save,

  ],

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

    if (navigator.geolocation) {

      navigator.geolocation.getCurrentPosition(

        function (position) {

          model.set("Usrcheck_in_longitude", position.coords.longitude, true);

          model.set("Usrcheck_in_latitude", position.coords.latitude, true);


 

          var account = model.get("Account").get("Address");


 

          alert(account);

          Ext.callback(callbackConfig.success, callbackConfig.scope);

        },


 

        function (error) {

          alert("Geolocation failed: " + error.message);

          Ext.callback(callbackConfig.success, callbackConfig.scope);

        }

      );

    } else {

      alert("Geolocation is not supported by this browser.");

      Ext.callback(callbackConfig.success, callbackConfig.scope);

    }

  },

});


i use this: var account = model.get("Account").get("Address"); 
but when i test it, displayed on an alert it says "undefined", but this model.get("Account").get("Id"); or model.get("Account").get("Name"); works fine.
Can anyone help me out? 

Thank you.  

Like 1

Like

3 comments

Hello,

 

Please check if the Address column is present in the SyncColumns array of the Account entity in the ModelDataImportConfig array of the mobile application manifest. It seems that the column is not synced so you receive undefined in the debugger.

Oleg Drobina,


Hi Oleg,
thanks for the reply,

should i add manually on Mobile manifest file or via Mobile Application Wizard?
PS: i don't use debugger like console.log, i use javascript's alert function since i use iOS and i have no clue on how to debug mobile apps on a smartphone, especially iOS.

Yanuar Adinagoro Vishnu Saputro,

 

It can be either manually or you can add the Address column to the account edit page and the column should be added to the manifest automatically in this case.

Show all comments

It is possible to change the name of the mobile app?

 

Can be rename with the name of the company instead of "Creatio"?

 

Thanks 

Like 0

Like

2 comments

Hello,

 

While it is not possible to change the name of the mobile app directly, you can use Mobile Branding to customize your mobile application.

 

You can find more information about Mobile app Branding in this article: https://academy.creatio.com/docs/8.x/dev/development-on-creatio-platfor…

Thanks for the tip

Show all comments

Hi Team,

 

We have installed the Field Management (Open Street Map) in our instance map configurations is working as we expected in web app but same thing we configured in the Mobile app, fields are displaying but the map UI is not showing in mobile.

And we have tried to install the Field Sales connector, DB error occurred while installing please help us to achieve the Mobile map configuration.

 

Error log on Filed Sales:

 

2024-09-23 14:09:41,557 Error occurred while installing data "SysModuleInWorkplace" in package "FieldForce". UId 5f69e597-9acb-4852-9f3d-e4d278c7b02b: The UPDATE statement conflicted with the FOREIGN KEY constraint "FKd5jrT2KFY0lXcOnqZCi4dxhomfE". The conflict occurred in database "Creatio8DB_GL_250424", table "dbo.SysModule", column 'Id'.

The statement has been terminated.

 

Thanks,

Prem

Like 0

Like

3 comments

You look like to be dealing with two different problems. It can be a platform-specific usability or setup problem with the mobile app map user interface. Examine any settings unique to mobile devices and see if the mobile map feature is properly supported. Regarding the Field Sales connector DB error, there can be an oversight or a problem with database compatibility. In addition to making that the connector is compatible with the version of your system, check the logs for detailed problem messages.

Hi Joshua,

 

We have the requirement to build map functionalities on web and mobile app it is like a (google map) for that we have implemented on web applications using  Field force connector it is working as we expected in web app and same things we configured on the mobile application wizard but we are not able to see the map in mobile as in web app. Please find the snap for the reference for map UI in web app, we are expecting the Open Street Map hyper link in mobile.
 

Web app Map Snap
 

Prem Kumar,

Hi!

This is not currently available in the mobile app.
You can inspect the Account address detail as an example of integration with OpenStreetMaps in the system and Field Force application as an example of maps functionality on mobile apps. 

And also, 

You can find information in these posts:

https://community.creatio.com/questions/account-address-map-mobile-application

https://community.creatio.com/questions/maps-mobile-application

 

Best regards,

Anton

Show all comments

Hello, I recently started working with Creatio Mobile. I have downloaded the files and was able to create the Creatio APK through the SDKConsole utility. I have a question: how can I add a page within the application? I see that most of the app is based on WebView. My goal is to import a library from Pub.dev (in my case, call_log) and implement it to display the data on a page within this app.

If anyone could help me, I would be very grateful. Thank you.

Like 0

Like

1 comments

Hello,
In the mobile application there is an abillity to open custom JS pages using the handler logic, an example of such handler:

const openCustomPageRequest: OpenCustomWebViewPageRequest = {
   type: 'crt.OpenCustomWebViewPageRequest',
   $context: request.$context,
   controllerName: 'Terrasoft.controller.MobileSyncLogPage',
   viewXClass: 'Terrasoft.view.MobileSyncLogPage',
   parameters: {
       "customParam": 1
   }
};
HandlerChainService.instance.process(openCustomPageRequest);

controllerName - class name of JS controller 
viewXClass - class name of JS view 
parameters - additional parameters of custom page. To get the parameter call this method inside the controller this.getPageHistoryItem().getRawConfig().customParam

This handler should be added via the remote module (see this article) and using the @creatio/mobile-common library enabling the feature EnableMobileSDK in the Features page.

Show all comments

Hi Team,

 

My team and I have been assigned to a project this month, and one of the requirements is to implement a QR code scanner in the mobile app. So far, I've been able to open the camera using `Ext.device.Camera.capture`, but it doesn't scan anything. I also came across the documentation mentioning Cordova, and I tried using the Cordova barcode scanner plugin, but that didn't work either.

 

Could anyone please provide any additional documentation or articles related to this issue? Specifically, it would be helpful if there are resources on how to use the Cordova plugin or how to develop a custom widget using Flutter.

Like 1

Like

2 comments

Also interested, lots of clients are interested in using QR code (for example, event registrations, or orders etc...), currently use of QR code is limited.

Hello,

Our R&D team has a task to implement a QR scanner in the mobile application. The task is still in progress on their end and we expect this functionality to appear in the app in the next application releases. Currently,  we do not have any examples of such implementation. 

You can use all the provided examples of customizations in mobile applications that we have provided on the Academy: https://academy.creatio.com/docs/8.x/dev/development-on-creatio-platform/category/mobile-app-development.

Show all comments

When making changes to the section list and/or section pages for the mobile app, should I create a new packages or is it ok to leave the current package as "custom" and make the changes via the mobile application wizard?

Like 0

Like

1 comments

Hi!

It is normal to leave the current package as "custom". You can change the package only if you want to keep some functionality in a separate package. 

Best regards, 
Anton

Show all comments

Hi Team,

 

Could you please help us to achieve the functionality to display the cases that are assigned to the current user who logged into the mobile application. Instead of displaying the cases assigned to all users. 

 

We are able to achieve this functionality in web application but unable to achieve the same in mobile application. 

Like 0

Like

2 comments

Hello,

 

You can achieve such logic using the development tools. You can find the examples in this post: https://community.creatio.com/articles/setting-filter-mobile-application

 

If you are using the offline mode, you can also set up the synchronization filter for the Mobile app. The detailed explanation is provided in this article: 

https://academy.creatio.com/docs/8.x/no-code-customization/customizatio…

Hanna Skalko,

Hi Hanna Skalko,

 

Thanks for the suggestions we are looking into it.

Show all comments

You need to create a custom detail generator(look at the example in Terrasoft.FileAndLinksEmbeddedDetailGenerator)

After that, create schema and add to manifest:

Ext.define("Terrasoft.configuration.CustomEmbeddedDetailGenerator", {
    extend: "Terrasoft.EmbeddedDetailGenerator",


    generateItem: function() {
        var config = this.callParent(arguments);

        var cardGenerator = this.getCardGenerator();

        var isEdit = cardGenerator.isEdit();
        if (isEdit) {
            config.xtype = "my_embeddeddetailitem";
        }
        return config;
    }

});

Create detail component with button 

Ext.define("Terrasoft.configuration.MyEditEmbeddedDetailItem", {
  extend: "Terrasoft.controls.EditEmbeddedDetailItem",
  xtype: "my_embeddeddetailitem",
  initialize: function () {
    this.myButton = Ext.create("Ext.Button", {
        text: ""
    });
    this.myButton.on("tap", this.onMyButtonTap, this);
    this.element.appendChild(this.myButton.element);
   this.callParent(arguments);
  },
  onMyButtonTap: function() {
    Terrasoft.Geolocation.getCurrentCoordinates({
        success: function(latitude, longitude, locationObj) {
        
        },
        scope: this
    });
  }
}

In RecordPageSettings metadata set generator xclass for detail
{
    "operation": "insert",
    "name": "AccountAddressDetail",
    "values": {
        "generator": {
            "xclass": "Terrasoft.configuration.CustomEmbeddedDetailGenerator"
        },
        
    },
    "parentName": "settings",
    "propertyName": "columnSets",
    "index": 3
}
 

Like 0

Like

0 comments
Show all comments

Hello, We've followed the steps here https://academy.creatio.com/docs/8.x/no-code-customization/customizatio… to create a Freedom UI page for an existing object (Leads) and can view the Freedom UI in the web interface, however we do not see the option to enable the Freedom UI for this section in the Mobile Application Wizard. There should be a checkbox next to the Leads section to enable the freedom UI but we do not see it. How do we do this?

 

Thank you,


Eric

Like 0

Like

3 comments

Good afternoon!
 

To do this, you need to enable the "UseMobileFlutterFirst" feature here:

https://mywebsite.creatio.com/0/flags


image.png

Regards,
Anton

Hi Anton, thank you for the reply. I enabled "UseMobileFlutterFirst" as you described but I still do not see the checkbox to enable freedomUI in the mobile app wizard for our leads section. Is there anything else I need to do?

 

Also, it looks like you posted an image but it didn't load for me in case that included an additional step.

 

Eric

Eric Curran,

Please contact technical support at support@creatio.com

Show all comments

Добрий день.
Допоможіть, будь ласка, відфільтрувати записи у кастомному розділі в мобільному додатку.

Потрібний фільтр "Створив = поточний користувач"

Створив фільтр 

Terrasoft.sdk.Module.addFilter("UsrMyNotes", Ext.create("Terrasoft.Filter", {
   type: Terrasoft.FilterTypes.Group,
   logicalOperation: Terrasoft.FilterLogicalOperations.And,
   subfilters: [
       {
           property: "CreatedBy",
           comparisonType: Terrasoft.ComparisonType.EQUAL,
           value: Terrasoft.sdk.CurrentUser.getContactId()
       }
   ]
}));

та зберіг у файл UsrMobileNotesModuleConfig та додав файл до маніфесту робочого місця. 


},
"UsrMyNotes": {
   "RequiredModels": [
       "UsrMyNotes"
   ],
   "ModelExtensions": [],
   "PagesExtensions": [
       "UsrMobileUsrMyNotesActionsSettingsBlyzenkoWS",
       "UsrMobileUsrMyNotesGridPageSettingsBlyzenkoWS",
       "UsrMobileUsrMyNotesRecordPageSettingsBlyzenkoWS",
       "UsrMobileNotesModuleConfig"
   ]
}
Але фільтр не працює. Допоможіть, будь ласка. 
 

Like 0

Like

1 comments

Доброго дня,
Наведений вами приклад актуальний для класичних секцій мобільного додатку, однак, вочевидь ви використовуєте інтерфейс Freedom UI для мобільного розділу вашого об'єкту. 
Для реалізації вашої задачі в даному випадку необхідно змінити схему Mobile[Object]GridPageSettings[Workplace].
В цій схемі всередині масиву [ ] необхідно додати блок з кодом фільтру:
{
    "operation": "merge",
    "name": "settings",
    "values": {
        "viewModelConfigDiff": "[{\"operation\":\"merge\",\"name\":\"Attribute_Items_ModelConfig\",\"values\":{\"filterAttributes\":[]}},{\"operation\":\"insert\",\"name\":\"MyFilter\",\"values\":{},\"parentName\":\"Attribute_Items_ModelConfig\",\"propertyName\": \"filterAttributes\"},{\"operation\":\"merge\",\"name\":\"Attributes\",\"values\":{\"MyFilter\":{ ВАШ ФІЛЬТР }}}]"
    }
}
Для отримання самого фільтру варто використати наступний метод:
1) В дизайнері Freedom UI для довільної сторінки додаєте новий список на ваш об'єкт 
2) В цьому списку налаштовуєте фільтр, який який ви хочете застосувати в мобільному додатку
3) Зберігаєте фільтр і саму сторінку
4) Відкриваєте код самої сторінки і всередині неї можете знайти повний код фільтру:
5) Цей код і треба вставити всередину {\"MyFilter\":{ ВАШ ФІЛЬТР }}.
Важливо, в ньому треба екранувати символи " за допомогою штриха \, тобто таким чином \" і код фільтру не повинен містити табуляцій.
В результаті ваша сторінка Mobile[Object]GridPageSettings[Workplace] має виглядати приблизно наступним чином:
[
{
    "operation": "merge",
    "name": "settings",
    "values": {
        "viewModelConfigDiff": "[{\"operation\":\"merge\",\"name\":\"Attribute_Items_ModelConfig\",\"values\":{\"filterAttributes\":[]}},{\"operation\":\"insert\",\"name\":\"MyFilter\",\"values\":{},\"parentName\":\"Attribute_Items_ModelConfig\",\"propertyName\": \"filterAttributes\"},{\"operation\":\"merge\",\"name\":\"Attributes\",\"values\":{\"MyFilter\":{\"value\": {\"items\": {\"154ca683-b9f9-4359-88ca-e9dfbd10481a\": {\"filterType\": 4,\"comparisonType\": 3,\"isEnabled\": true,\"trimDateTimeParameterToDate\": false,\"leftExpression\": {\"expressionType\": 0,\"columnPath\": \"Status\"},\"isAggregative\": false,\"dataValueType\": 10,\"referenceSchemaName\": \"CaseStatus\",\"rightExpressions\": [{\"expressionType\": 2,\"parameter\": {\"dataValueType\": 10,\"value\": {\"Name\": \"In progress\",\"IsFinal\": false,\"Id\": \"7e9f1204-f46b-1410-fb9a-0050ba5d6c38\",\"Image\": \"\",\"StatusColor\": \"#FFAC07\",\"value\": \"7e9f1204-f46b-1410-fb9a-0050ba5d6c38\",\"displayValue\": \"In progress\"}}}]},\"d819453a-7122-4f49-92e8-3b0d7e4601f5\": {\"filterType\": 4,\"comparisonType\": 3,\"isEnabled\": true,\"trimDateTimeParameterToDate\": false,\"leftExpression\": {\"expressionType\": 0,\"columnPath\": \"Status\"},\"isAggregative\": false,\"dataValueType\": 10,\"referenceSchemaName\": \"CaseStatus\",\"rightExpressions\": [{\"expressionType\": 2,\"parameter\": {\"dataValueType\": 10,\"value\": {\"Name\": \"New\",\"IsFinal\": false,\"Id\": \"ae5f2f10-f46b-1410-fd9a-0050ba5d6c38\",\"Image\": \"\",\"StatusColor\": \"#0058EF\",\"value\": \"ae5f2f10-f46b-1410-fd9a-0050ba5d6c38\",\"displayValue\": \"New\"}}}]}},\"logicalOperation\": 1,\"isEnabled\": true,\"filterType\": 6,\"rootSchemaName\": \"Case\"}}}}]"}
}
]
Після цього зберігаєте зміни і синхронізуєте мобільний додаток, в результаті розділ має бути відфільтрованим.

Show all comments