Hello. 

 

I'm doing an Web services to send a document to sign, the api request the Url of the document so I'm using the following link https:[creatio instance]/0/rest/FileService/GetFile/70ec5d9f-a55e-4f5c-8f59-30d2c5149c4a/ef68e95e-ef77-eddf-dfa8-685557ee4875

 

70ec5d9f-a55e-4f5c-8f59-30d2c5149c4a correspons to the  UId from the SysSchema table where the attachments are stored and the ef68e95e-ef77-eddf-dfa8-685557ee4875 is the Id of the attachment. This URL allows me to dowloand the document to my computer, so I know that is the right link but when I used it in the web service it says that there is no document. 

 

The json of the request is the following 

{
 
    "url_doc": {
 
        "url": "https://151929-crm-bundle.creatio.com/0/rest/FileService/GetFile/70ec5d9f-a55e-4f5c-8f59-30d2c5149c4a/ef68e95e-ef77-eddf-dfa8-685557ee4875",
 
        "name": "Contrato.pdf"
 
    },
 
    "stickers": [
 
        {
 
            "authority": "Vinculada a Correo Electronico por Liga",
 
            "stickerType": "line",
 
            "dataType": "email",
 
            "email":"laura@artica.digital",
 
            "data": "laura@artica.digital",
 
            "imageType": "stroke",
 
            "page": 0,
 
            "rect": {
 
                "lx":74.88173,
 
               "ly":312.32596,
 
               "tx":196.9875,
 
               "ty":373.37885
 
            }
 
        }
 
    ]
 
}

 

When I sent the request the response is 

 

{
    "error": "No document"
}

 

I had try this request with a Dropbox URL and works fine but I need to send the documents that are generated by the Word Reports. That why I'm trying to get the document from Creatio using the URL the API also gives me the option of sending the document using base64 but I dont know how to convert the file easly. 

 

Can you help me please to know what is happenig? 

Thank you

Like 0

Like

4 comments

The reason why this isn't working is because FileService/GetFile requires authentication to read. This is not an anonymous endpoint. The receiver of this, where ever you're sending this URL of the document to, is actually getting a 401 Unauthorized. 

You'd have to either go the route of sending the base64 of the file, or expose an anonymous service in Creatio to provide the file to the other service.

Ryan

Ryan Farley,

Thank you, can you explain me please how can I convert the file to base64 please, I had see some examples but I not sure if I can do it using a script task in a business process or a source code 

Laura Jurado,

The code would look something like this (not tested, but this should get you started). For this, I have two process params, one a uniqueidentifier AccountFileId (an Id of an account file) and second an unlimited text AccountFileBase64. The script task would look something like this:

var fileId = Get<Guid>("AccountFileId");
 
var entity = UserConnection.EntitySchemaManager.GetInstanceByName("AccountFile").CreateEntity(UserConnection);
if (entity.FetchFromDB(fileId))
{
    var base64FileData = Convert.ToBase64String(entity.GetBytesValue("Data"));
    Set("AccountFileBase64", base64FileData);
}

Ryan

Ryan Farley,

Thank you very much. It helped me a lot 

Show all comments

Hello,

 

is it possible to include Feed into global search results?

And/Or filter records by Feed in Section?

 

Thank you.

Vladimir

Like 1

Like

1 comments

Hello!

 

Regarding your first question, please note that at the moment, the feed is not indexed in the global search (the columns 'Message' of the 'CaseMessageHistory' object and the 'Message' of the 'SocialMessage' object). It is not possible to enable the feed in the global search in the current system configuration.

We have received similar inquiries in the past, and a development team has already registered a task to add this functionality. I have attached your request to the task to increase its priority. We will plan how to address this task and strive to develop a suitable mechanism, which will be presented in future Creatio releases.

Regarding your second question, unfortunately, it is impossible since we don't have direct connections between the record and Feed.


Best regards,

Mariia

Show all comments

Getting dateformat error during deserialization when calling a custom web service with the following JSON request:


{
  "ResultDate": "\"2000-01-01T00:00:00.000\""
}
The error message states:

The formatter threw an exception while trying to deserialize the message: There was an error while trying to deserialize parameter http://tempuri.org/:entity... "DateTime content '"2000-01-01T00:00:00.000"' does not start with '/Date(' and end with ')/' as required for JSON.' Please see InnerException for more details. See server logs for more details. The exception stack trace is: ...

Is there any way to pass a date in the "\"2000-01-01T00:00:00.000\"" format instead of using /Date(1511448000000)/

Like 0

Like

1 comments

Hello,

According to the given information, this article may be helpful:

https://stackoverflow.com/questions/44227653/content-date-does-not-start-with-date-and-end-with-as-requi

Also, you can write a DateTime to Unix timestamp converter and then extract the value:

public static DateTime UnixTimeStampToDateTime( double unixTimeStamp )
{
    DateTime dateTime = new DateTime(1970, 1, 1, 0, 0, 0, 0, DateTimeKind.Utc);
    dateTime = dateTime.AddSeconds( unixTimeStamp ).ToLocalTime();
    return dateTime;
}

Best regards,

Anhelina!

Show all comments

Hi all,

I need to process files attached to a record, and i am using the process file element to get access to those files. I need to get the files itself in a process parameter, so i can manipulate them in a c# script task.  But i see no way how i can get the file or files collection retrieved by the process element in a process parameter.  What am i missing?

 

Greetings,

 

Vincent

Like 0

Like

3 comments

You can generate the printable doc via code as well, then use the file  bytes. See https://customerfx.com/article/running-a-word-printable-in-a-process-script-task-and-add-as-attachment-on-a-record-in-bpmonline/

The report.Data in that code sample will give you the bytes of the file itself.

Ryan

Thanks for the reply, but it's not what I'm looking for.  The documentation of the process file element says:

What to do with file? – select one of the following options:

  1. Use in process” if you need to use the file records in the process itself without saving the files to any Creatio object or if you need to pass the files to a different business process as a parameter.


My question is: how can i pass that file(collection) to a different business process (or a script taks). ..

Hello,

 

Essentially, the process file element works with collections of records. For example, when reading object attachments from a specific record, there can be more than one attachment.

Therefore, if we need to work with this data further in a script or another process, we should handle collections of files.

For instance, if we have read some attachments and selected the 'use in process' option, we can pass the file from the collection to a subprocess with a File parameter.

 In the subprocess, this file can then be accessed through the parameter.

 

 

 

 

Show all comments

Hello everyone. Can someone tell me how to filter the list of emails address via Account? That is displayed when registering email sending activity via the Section Actions toolbar. Found a similar article https://community.creatio.com/questions/filter-contact-list-section-act….  Thanks!

Like 0

Like

3 comments

Hello Serhii,
Thank you for your question.

I have tried to use a similar approach to the one mentioned in the forum discussion. Here is an example of how to filter recipients to contain 'mycompany' in the email address in the action dashboard of the contacts section.


define("EmailMessagePublisherPage", ["LookupUtilities"],
       function(LookupUtilities) {
           return {
               entitySchemaName: "Activity",
               mixins: {},
               attributes: {},
               methods: {
                updateLookupFilter: function(lookup) {
                  lookup.config.updateViewModel = function() {
                    this.pushSelectFilters = function(select) {
                      const filters = select.filters;
                      const lookupInfo = this.getLookupInfo();
                      if (!lookupInfo.columnValue) {
                        const searchColumn = this.get("searchColumn");
                        if (searchColumn) {
                          const columnPath = searchColumn.value;
                          const stringComparisonType = this.getStringColumnComparisonType();   
                          const filter = select.createColumnFilterWithParameter(stringComparisonType, columnPath,
"mycompany");
                          filters.add("searchDataFilter", filter);
                        }
                      } else {
                        lookupInfo.columnValue = null;
                      }
                    }
                  };
                },
                openRecepientLookupEmail: function() {
                  var lookup = this.getLookupConfig("Recepient");
                  
                    this.updateLookupFilter(lookup);
                  
                  lookup.config.actionsButtonVisible = false;
                  var searchValue = this.get("RecepientLookupSearchValue");
                  if (searchValue) {
                    lookup.config.searchValue = searchValue;
                  }
                  LookupUtilities.Open(this.sandbox, lookup.config, lookup.callback, this, null, false, false);
                },
              },
               diff: /**SCHEMA_DIFF*/[]/**SCHEMA_DIFF*/
           };
       });

Hope this helps!

Hello. Thank you. The solution works, but it is not ideal. It is necessary to check the Account domain, or there may be employees who have a Gmail email. I am looking for another solution.

Hello Serhii,

The example I provided serves as a foundation for adding email address filtering for the action dashboard. You can use this example as a base and modify the filtering logic according to your preferences.

Hope this helps

Show all comments

Hello,

I would like to ask how to enable additional options such as editing or deleting notes in this section.

Currently, I can delete and edit them, but only from the message card; however, I am unable to edit directly on the object. It is important to me that the person who adds a note can independently edit it directly on the opportunity,

Best Regards 

 

 

Like 0

Like

3 comments

Hello

 

You should be able to delete records from the feed either on the feed page itself or from the communication panel, but only your own records. You cannot edit or delete other people's notes.


Dymytriy Vykhodets,

I understand, in that case how can you turn on the ability to edit own records 

Michał Zieliński,

 

Hello,

 

This option should be enabled by default. We would need to get access to your environment in order to investigate this issue. Please write to support@creatio.com and we will assist you with the request.

Show all comments

I'm encountering a recurring issue with logging into Creatio, which happens almost every day. After entering my login credentials, the system often gets stuck on the loading screen with the Creatio logo. This issue usually occurs during the first login of the day, but it has also happened during subsequent login attempts.

I've identified that the loading process halts at the following script:

https://<CREATIO_URL>/api/ClientScript/GenerateViewModuleScripts?v=8.1.0.6828
 

The time it takes to resolve this issue varies—sometimes it takes 2-10 minutes, but there have been instances where the screen remains stuck even after an hour. Importantly, there are no errors in the console during this time.This problem is significantly disrupting my ability to work with the system.

Has anyone else experienced this issue? Any suggestions or solutions would be greatly appreciated!

Like 0

Like

1 comments

Hello,

Please contact the Support team for analyzing this issue. The email address: support@creatio.com.

Show all comments

Hi can anyone help to build a tile view in freedom ui , I wanted to recreate the grid view that was present in classic ui .

Like 1

Like

1 comments

Hello,

Unfortunately, a tile view currently cannot be recreated in Freedom UI, and there is no option to display the images on the list page. We have registered a request with the responsible development team, and this team is working on adding this functionality in future releases.
 

Show all comments

Hello Creatio Community,

I'm encountering several script errors while using Creatio, as shown in the attached screenshot. The errors appear to be related to the following components:

  1. GHierarchyViewGeneratorV2:
    • Script error on line 9.
    • Error related to GHierarchyViewGeneratorV2.
  2. GHierarchicalGridUtilitiesV2:
    • Uncaught error for GHierarchicalGridUtilitiesV2.
  3. ViewModuleWrapper:
    • Uncaught error for ViewModuleWrapper.

These errors seem to be occurring consistently, preventing me from loading specific modules. I've tried refreshing the page and clearing the cache, but the issue persists.

Has anyone else encountered these errors, and if so, what steps did you take to resolve them? Any insights or suggestions would be greatly appreciated.
Screenshot:

 


Thank you in advance for your assistance!

Like 0

Like

1 comments

Hello,

Script Errors mean there are some issues with the code in a specific schema. In order to fix it we recommend asking the developers of the set schema so that they can check if there are any errors in the code.

Show all comments

Hi,

 

Is it possible to set a title for a column in a DataGrid dynamically via client code?

 

I tried the following steps:

  1. Add an attribute to viewModelConfigDiff called "InspectorsSundayCaption".

 

            viewModelConfigDiff: /**SCHEMA_VIEW_MODEL_CONFIG_DIFF*/[
            {
                "operation": "merge",
                "path": [
                    "attributes"
                ],
                "values": {
                   "InspectorsSundayCaption":{
                   },

            ......}

 

  2. Bind the attribute to the caption property of column

                       {
                            "id": "aaa335c2-8291-0f65-e930-e39ca7e333a7",
                            "code": "DataGrid_244wb6vDS_UsrwpPoliceCarsSunday",
                            "path": "UsrwpPoliceCarsSunday",
                            "caption":"$InspectorsSundayCaption2",
                            "dataValueType": 4
                        },

 

  3. Set the attribute in the HandleViewModelInitRequest handler with the specific value.

 

    {
                request: "crt.HandleViewModelInitRequest",
                  handler: async (request, next) => {

                           .....

                           request.$context.InspectorsSundayCaption = "Sunday inspectors " + sundayDateStr;

                           await next?.handle(request);

}

 

This way work to me in normal column caption, But it doesn't work in a DataGrid column

 

Is there any limitation/step I'm missing?

 

Thanks in advance for your assistance!
Rachel
 

 

Like 0

Like

2 comments

Hi,
Does anyone have an idea?

Hello Rachel Markovski,

I have contacted our R&D team in order to help find a solution for your problem. The answer is unfortunate - currently there is no mechanism to dynamically change column caption in the datagrid component. 

Hope this helps.

Show all comments