Hi Community,

 

I want to make use of and set up OAuth 2.0 Authentication in web service authentication. For that I found below the academy article :

 

https://academy.creatio.com/docs/user/no_code_customization/web_service…

 

While setting up as per the article, there is one required field in the OAuth Setting fields which is "Auth code request URL".

 

But the API endpoints for which, I have to make use of Web Service OAuth Authentication, is not having settings for Auth code request URL required parameter.

 

 

Please guide and help me on this point that how I can set up OAuth Authentication in web service without Auth code request URL.

Like 0

Like

1 comments

Hello Pratic,



Unfortunately, the is no way to set up OAuth Authentication in web service without Auth code request URL.



This parameter is necessary to identify users.



Best regards,

Bogdan



 

Show all comments

Hi Team,

 

I was implementing a print report on a section. Now, I want to download the report in (ColumnName).docx in which ColumnName varies for each record based on the data stored in that column. By default, it is giving the same name as the printable name for all the records. Please help

Like 1

Like

1 comments

Hello, 

 

As for now there is no option to change the file name dynamically or assign some particular name. We have this task registered in our backlog and waiting for this option to be available in future application versions.

 

I will assign your case to this project in order to increase its priority.

Best regards,

Anastasiia

Show all comments

I installed the "Calculation Working Days" business process template from marketplace. It is set as having the Custom Package as its only dependent package, but we need to be able to use it as part of business processes in our current configuration package (which is not the Custom Package). When I try to add the  package from marketplace as a "dependent on" for our current package I get an error. See screenshot. Posting here as the Marketplace page says it's supported via posts in Creatio Community.   https://marketplace.creatio.com/template/calculation-working-days-busin…

Like 0

Like

2 comments

Hi Andriana!

The issue is caused by the missing data binding for the "SysWorkplace" and "SysModuleEntity" objects. To fix the issue, make sure that data with aforementioned IDs is bound to the package that is experiencing data binding issues.

Hello,

 

We are facing a similar issue. Could you please let me know if binding solved this issue? Please confirm what are the bindings that need to be done because I see that sections are already present in the SysModuleInWorkplace_SectionInWorkplaceManager data binding. 

Show all comments

Hello!

I'm trying to show a pop up message on the mobile app when a certain condition is given.

Is there a way to do this?

I'm doing this right now:





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

    name: "SaveValidationAprov",

    ruleType: Terrasoft.RuleTypes.Custom,

    events: [Terrasoft.BusinessRuleEvents.Save],

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

            debugger;

        var IsFieldValid = true;

        if ( (record.get("IcoTotalAvailableStock")) < (record.get("Quantity")) ){

            alert("There is not enough stock");

            IsFieldValid = false;

        }

       

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

    }






Thanks!

})

Like 0

Like

3 comments
Best reply

Hello Fernando,

You can display a message in mobile using the following: 

Terrasoft.MessageBox.showMessage("This is a message!");

This works from code in the mobile client - as Oscar mentioned, there's no option for sending a message from the server to the mobile client, however, from within the mobile client code, you can use the above.

Ryan

Hello,

 

As stated here there is no possibility to display such popups in the mobile app. However here is an article on how to setup push notifications in the mobile app https://academy.creatio.com/docs/user/bpm_tools/bpm_process_examples/ne…

 

You can trigger it once the record is modified and perform the condition check there directly and send a push notification about the result.

 

Best regards,

Oscar

Oscar Dylan,

Thank you for your time and knowledge :)

Hello Fernando,

You can display a message in mobile using the following: 

Terrasoft.MessageBox.showMessage("This is a message!");

This works from code in the mobile client - as Oscar mentioned, there's no option for sending a message from the server to the mobile client, however, from within the mobile client code, you can use the above.

Ryan

Show all comments

Until recently we have been using the Excel Reports builder without any issue.  We have now started receiving an error (below) when we try to generate a report with calculated Net Sales Entered.  If we remove the columns or generate a different report without these columns there is no issue.  If we add the columns back we again receive the error.  This is an excel report we've had and ran for several months and just now began receiving the error.

 

A severe error occurred on the current command. The results, if any, should be discarded. Operation cancelled by user. Please check filter settings

Like 1

Like

1 comments

Hi Garrett!

I recommend checking your calculation. If the final calculation is more than 2,147,483,647 in a field, integer overflow error occurs. Also, you might want to try basic export with the same parameters or build a dashboard using your data. If errors occur in these cases, the problem is caused not by the add-on but by data.

Show all comments

Hello Community,

 

I have a requirement, when a user changes the DCM status manually validation should trigger. To achieve this I am using asynValidate function and the validation is working fine.

But the issue here is status is not restoring back automatically and also both Save and Cancel button is showing as a result when I am trying to create a record in the connected detail the validation is triggering again. I have to manually click on Cancel before I can do any changes in the details. Please refer the screenshot below.

Before validation:

After validation:

 

Is there anyway after validation it should reset back to Close like in the 1st image?

 

Thanks,

Sourav Kumar Samal

Like 0

Like

4 comments
Best reply

Anastasiia Zhuravel,

 

I have resolved the issue. To acheive the desired output I have added a small line after the error message as follows:

			MandatoryValidation: function(callback, scope){
				var DCMstatus = this.get("MarketingPlansStatus").displayValue;
				if(DCMstatus === "Business Owner Review"){
					// Some query
                                        callback.call(scope || this, {
						success: false,
                                                message: "Error message"
					});
                                        this.reloadEntity();
				}else{
					callback.call(scope || this, {
						success: true
					});
				}
			},

Note: If the asynValidate is being used in this.NewMode(), avoid adding this.reloadEntity() as this may clear all the fields.

 

Thanks,

Sourav Kumar Samal

Hello, 

 

Could you please clarify how exactly the manually validation functionality has been achieved? Was it done by code?

 

Thank you in advance!

Best regards,

Anastasiia

Anastasiia Zhuravel,

 

Yes it has been achieved by using 'asyncValidate' function. The validation will only trigger when DCM status changed to "Business Owner Review".

 

Thanks,

Sourav

Anastasiia Zhuravel,

			asyncValidate: function(callback, scope) {
				if (this.isEditMode()){
					this.callParent([function(response) {
						if (!this.validateResponse(response)) {
							return;
						}
						Terrasoft.chain(
							function(next) {
								this.MandatoryValidation(function(response) {
									if (this.validateResponse(response)) {
										next();
									}
								}, this);
							},
							function(next) {
								callback.call(scope, response);
								next();
							}, this);
					}, this]);
				}else {
					this.callParent(arguments);
				}
			},
			MandatoryValidation: function(callback, scope){
				var DCMstatus = this.get("MarketingPlansStatus").displayValue;
				if(DCMstatus === "Business Owner Review"){
					// Some query
                                        callback.call(scope || this, {
						success: false,
                                                message: "Error message"
					});
				}else{
					callback.call(scope || this, {
						success: true
					});
				}
			},

 

Anastasiia Zhuravel,

 

I have resolved the issue. To acheive the desired output I have added a small line after the error message as follows:

			MandatoryValidation: function(callback, scope){
				var DCMstatus = this.get("MarketingPlansStatus").displayValue;
				if(DCMstatus === "Business Owner Review"){
					// Some query
                                        callback.call(scope || this, {
						success: false,
                                                message: "Error message"
					});
                                        this.reloadEntity();
				}else{
					callback.call(scope || this, {
						success: true
					});
				}
			},

Note: If the asynValidate is being used in this.NewMode(), avoid adding this.reloadEntity() as this may clear all the fields.

 

Thanks,

Sourav Kumar Samal

Show all comments

Hey Everyone, 

 

I would like the user to be able to add multiple notes that are time stamped, within the opportunities modules. 

 

It's actually the functionality of the "feed" that I am after. But I don't want each feed post/note to be shared + It would be good to change the placeholder text to something rather than 'What are you working on".

 

Would it be possible to change this just for one module? With/without dev help.

 

Thanks all. 

Like 1

Like

1 comments

Hi Mark,

 

To change the "What are you working on message" you need to create a replacing module for the "SocialFeed" module (for example with the code below):

 define("SocialFeed", [], function() {
		return {
			methods: {
			}
		};
	});

and then find the WritePostHint localizable string and modify its value. After the new schema is saved and the page refreshed you will get a new message (but please note that it will be done for all feed containers in all pages). If you need this change to be applied only to one section feed then the logic of the "SocialMessageEdit" element's "placeholder" property should be modified (in the same "SocialFeed" module).

 

As for different feed posts visibility and sharing: it's a better approach to use feed channels instead of posting into some record feed in case you need to not display every single feed post in the record. The feed itself was designed to leave comments on the workflow or tag someone in the record. Or you can try enabling record permissions for the "SocialMessage" object (that stands for feed messages) and create some business process that automatically distributes access rights based on some conditions.

 

Best regards,

Oscar

Show all comments

Hi,

 

Can some one help me,

 

I am using this tutorial for making section grid editable: https://community.creatio.com/articles/editable-grid-section#comment-81…

 

And I have two errors and it doesn't work.

 

My errors are: 

-Heading for label "DataGrid" not found.

-Unable to find column by configuration: "{"className":"Terrasoft.ConfigurationGrid","generateControlsConfig":{"bindTo":"generatActiveRowControlsConfig"},"changeRow":{"bindTo":"changeRow"},"unSelectRow":{"bindTo":"unSelectRow"},"onGridClick":{"bindTo":"onGridClick"},"initActiveRowKeyMap":{"bindTo":"initActiveRowKeyMap"},"activeRowAction":{"bindTo":"onActiveRowAction"},"multiSelect":{"bindTo":"MultiSelect"},"name":"DataGrid"}" .

Like 0

Like

2 comments

Can you post the complete code? Won't be able to see what might be wrong without that.

Ryan

Hi Marko,

 

Please check my reply in the original article, this should help.

 

Best regards,

Oscar

Show all comments

Hi Team,

 

I have configured one business process for creating one notification as soon as a lookup value in a section changes. I have referred the article: https://community.creatio.com/questions/create-notification-communication-center.

 

The issue that I'm facing is not getting any count alert for the new notification received although the notification is present in the notification center info section. The alert for the new notifications count is only visible if the user is already logged in to the system.

 

 

Kindly help.

 

Thanks,

Sarika

Like 0

Like

6 comments

Hello Sarika, 

 

Could you please check if the checkbox "Run following elements in the background" is cleared for the start signal of this business process?

 

If not, please clear it, save the changes and relogin to the system. 

Let us know if the issue persists despite the provided recommendation.

 

Best regards,

Anastasiia

Hi Anastasiia, 

 

I followed your recommendation but the issue is still the same. Please suggest me what to do

Hi team,

 

Please suggest me a solution for this.

 

Thanks

Hi Sarika,

 

I am reaching out to see if you were to resolve the issue. We have a similar problem with our instance as well. 

 

Thanks

Hi Nirupama,

 

I removed the 'message is need to send' parameter from the add notification element and was able to get the notifications successfully.

 

Hope this helps in your case as well.

 

Best Regards,

Sarika

Sarika Sharma,

Thank you for your response. Really appreciate it!

Just a follow up question - did removing that parameter have any impact on the notification getting sent? Were you able to find out what it is used for?

Show all comments

Hi Community,

 

We are trying to integrate the Zadarma Widget with Creatio. Our main objective is to load this widget every time we press the "Phone" button (marked with red square in the following image).

In order to achieve this, we need to call the necessary dependencies, so it's possible to execute the "zadarmaWidgetFn" function, as you can see on the next image.

require.config({
	paths: {
		loader_phone_lib: '//my.zadarma.com/webphoneWebRTCWidget/v8/js/loader-phone-lib.js?sub_v=62',
		loader_phone_fn: "//my.zadarma.com/webphoneWebRTCWidget/v8/js/loader-phone-fn.js?sub_v=62"
	},
});
 
define("CtiPanel", ["ServiceHelper", "loader_phone_lib", "loader_phone_fn"], function(ServiceHelper) {
	return {
		messages: {},
		mixins: {},
		attributes: {},
		methods: {
			callPhoneNumber: function (){
				var number = this.get("PhoneNumber");
				window.console.log(number);
 
				var sipValue = "SIP";
 
				var payload = {
					sip: sipValue
				};
 
				ServiceHelper.callService("ImdZadarmaWebHookService", "ZadarmaWebRTCKey", function(response) {
					var result = JSON.parse(response.ZadarmaWebRTCKeyResult);
					window.console.log(result.key);
					zadarmaWidgetFn(result.key, 'SIP', 'square', 'en', true, "{left:'10px',top:'5px'}");
				}, payload, this);
			}
		},
		diff: []
	};
});

However, we are getting the following error while loading these dependencies, because one of the files "loader_phone_lib" (https://my.zadarma.com/webphoneWebRTCWidget/v8/js/loader-phone-lib.js?s…) has other dependencies that are called through tags.

We would like to know, how can we load these dependencies, that are inside the "loader_phone_lib" file, without getting this error?

 

Thanks in Advance.

 

Best Regards,

Pedro Pinheiro

Like 3

Like

4 comments

Hi Pedro,

 

According to https://requirejs.org/docs/errors.html#mismatch there should be the anonymous define() method inside the script HTML tag in one of the dependencies that are loaded. So to fix the error you need to check all the steps described in the requirejs.org document.

 

Best regards,

Oscar

Hi Oscar,

 

Thank you for the response.

 

Yes, some of the scripts have the anonymous define() method inside, so by following the documentation you provided, I removed the dependencies from the "loader_phone_lib" script and added them using the code bellow:

....
require.config({
	paths: {
		zadarmaSocket: "//my.zadarma.com/webphoneWebRTCWidget/v8/js/socket.io",
		zadarmaDetectWebRTC: "//my.zadarma.com/webphoneWebRTCWidget/v8/js/detectWebRTC.min",
		zadarmaJssip: "//my.zadarma.com/webphoneWebRTCWidget/v8/js/jssip.min",
		zadarmaMd5: "//my.zadarma.com/webphoneWebRTCWidget/v8/js/md5.min",
		zadarmaWidgetAPI: "//my.zadarma.com/webphoneWebRTCWidget/v8/js/widget-api.min.js?sub_v=62",
		zadarmaWidget: "//my.zadarma.com/webphoneWebRTCWidget/v8/js/widget.min.js?sub_v=62",
		loader_phone_fn: "//my.zadarma.com/webphoneWebRTCWidget/v8/js/loader-phone-fn.js?sub_v=62"
	}
});
 
define("CtiPanel", ["ServiceHelper", "zadarmaSocket", "zadarmaDetectWebRTC", "zadarmaJssip", "zadarmaMd5", "zadarmaWidgetAPI", "zadarmaWidget", "loader_phone_fn"], function(ServiceHelper) {
	return {
		messages: {},
		mixins: {},
		attributes: {},
		methods: {
			callPhoneNumber: function (){
				var number = this.get("PhoneNumber");
				window.console.log(number);
 
				var sipValue = "SIP";
 
				var payload = {
					sip: sipValue
				};
 
				ServiceHelper.callService("ImdZadarmaWebHookService", "ZadarmaWebRTCKey", function(response) {
					var result = JSON.parse(response.ZadarmaWebRTCKeyResult);
					window.console.log(result.key);
					zadarmaWidgetFn(result.key, 'SIP', 'square', 'en', true, "{left:'10px',top:'5px'}");
				}, payload, this);
			}
		},
		diff: []
	};
});

This piece of code manage to "fix" the previous error. However, I'm getting a new error, which is related to the Socket.Io (zadarmaSocket), as you can see on the next image:

I think this error is caused by the fact that one of the dependencies cannot reach specific functions/vars from other dependencies. I've tried to use the "shim" attribute, in order to create a sequence for loading the dependencies and it didn't work.

 

Thanks in Advance.

 

Best Regards,

Pedro Pinheiro

 

Pedro Pinheiro,

 

Hello,

 

The new code returns another error message on my side, but it happens since there is no ImdZadarmaWebHookService service and ZadarmaWebRTCKey method in my app. Can you please also share the code of this part?

 

Thank you!

 

Best regards,

Oscar

Hello Oscar Dylan,

 

The ZadarmaWebRTCKey method is responsible for requesting the WebRTC key from a specific "Client Key", "Client Secret" and SIP Number. I use this key to start the communication between the widget and Zadarma.

 

ImdZadarmaWebHookService.cs

 /* The custom namespace. */
namespace Terrasoft.Configuration.ImdZadarmaWebHookServiceNamespace
{
    using System;
    using System.ServiceModel;
    using System.ServiceModel.Web;
    using System.ServiceModel.Activation;
    using Terrasoft.Core;
    using Terrasoft.Web.Common;
    using Terrasoft.Core.Entities; 
	using System.Web;
	using System.Collections.Generic;
	using Terrasoft.Configuration.ImdZadarmaAPI;
	using System.Net.Http;
 
    [ServiceContract]
    [AspNetCompatibilityRequirements(RequirementsMode = AspNetCompatibilityRequirementsMode.Required)]
    public class ImdZadarmaWebHookService: BaseService
    {
        [OperationContract]
       	[WebInvoke(Method = "POST", RequestFormat = WebMessageFormat.Json, ResponseFormat = WebMessageFormat.Json, BodyStyle = WebMessageBodyStyle.Wrapped)]
		public string ZadarmaWebRTCKey(string sip){
 
            //ZadarmaApi is a class that contains all the methods to work with Zadarma API
			var zadarma = new ZadarmaApi("KEY", "SECRET");
 
 
			SortedDictionary&lt;string, string&gt; parameters = new SortedDictionary&lt;string, string&gt;();			
			parameters.Add("sip", sip);
 
            var response = zadarma.Call("/v1/webrtc/get_key/", parameters, HttpMethod.Get);
            string str = (string) response.Content.ReadAsStringAsync().Result;
            return str;
		}
    }   
}

The code for ZadarmaApi class can be found here:

https://github.com/zadarma/user-api-cs-v1/blob/master/ZadarmaAPI/ZadarmaApi.cs

 

Best Regards,

Pedro Pinheiro

Show all comments