Hi community,

I have a list of warehouses that contains the "Primary" field. It's only one of them that can be a primary warehouse.

When a user creates an order, I want the "Warehouse" field can be set automatically to the primary warehouse.

How to do this?

 

Thank you.

Like 1

Like

6 comments
Best reply

I has solved this problem by adding parameter "this" into the "result.collection.each()".

It will be shown as "result.collection.each(function(), this)"

esq.getEntityCollection(function(result) {
	debugger;
	if (!result.success) {
		// For example, error processing/logging.
		this.showInformationDialog("Can't set the location.");
		return;
	}
	result.collection.each(function(item) {
		var primaryWarehouse = {value: item.get("Id"), displayValue: item.get("SceName")};
		this.set("SceWarehouse", primaryWarehouse);
		return;
	}, this)
}, this);

 

You can Use Business Rule for auto populating Some fields. 

https:/academy.creatio.com/docs/user/customization_tools/ui_and_business_logic_customization/business_logic/setup/set_up_a_new_business_rule

 

Hi smit suthar,

 

I have tried to use the "Set field value" action, but it's too simple.

I want to set the value of "Warehouse" with a primary warehouse.

Note: The "Warehouse" section has the "Primary" (boolean) field.

So, for example; I have 2 warehouses, "A" and "B". And, I set the warehouse "B" primary field as TRUE. Then, when the user creates an order, the "Warehouse" field of the order will be filled by "B" automatically.

 

Do you have any other ideas?

Hello David Chandra,

 

Based on the shared information I can assume that your business task can be fully covered with a help of business rules functionality. 

If you'd like to expand the customization you can consider designing the custom business process that will read the needed columns from a page and apply changes with a Modify data element or even with script-task element where you can specify the custom logic with code. 

Alternatively, you can implement your business task with a help of additional development, but we do not have a specific ready to use example of such implementation. 



Best regards,

Anastasiia

Hello Anastasiia,

If we use the Business Rule means, we have to save the order and then use "added data trigger" to set the warehouse value.

Do you know how to set the warehouse value before we save the new order?

 

Regards,

David

Hello Anastasiia,

 

I managed to create a function in the page source code as below:

 

/* Overload the base Terrasoft.BasePageV2.onEntityInitialized method that is called after Creatio initializes the schema of the record page object. */
onEntityInitialized: function() {
	/* Call the parent implementation of the method. */
	this.callParent(arguments);
	/* Call the handler method that sets the [Location] column value. */
	this.setWarehouse();
},
/* The handler method that sets the [Warehouse] column value. */
setWarehouse: function() {
	/* The [Warehouse] column value. */
	var location = this.get("SceWarehouse");
	/* Checks whether the mode of the new record is set. */
	var newmode = this.isNewMode();
	// * If the value is not set and the mode of the new record is set. */
	if (!location && newmode) {
		/* Get the contact's location by using ESQ */
		const userContactId = Terrasoft.SysValue.CURRENT_USER_CONTACT.value;
		const esq = this.Ext.create(Terrasoft.EntitySchemaQuery, {
			rootSchemaName: "SceWarehouse"
		});
		esq.addColumn("Id");
		esq.addColumn("SceName");
		esq.addColumn("Primary");
		const esqFirstFilter = esq.createColumnFilterWithParameter(Terrasoft.ComparisonType.EQUAL,
				"Primary", true);
		esq.filters.add("esqFirstFilter", esqFirstFilter);
		esq.getEntityCollection(function(result) {
			debugger;
			if (!result.success) {
				// For example, error processing/logging.
				this.showInformationDialog("Can't set the location.");
				return;
			}
			result.collection.each(function(item) {
				var primaryWarehouse = item;
				this.showInformationDialog(primaryWarehouse.get("SceName"));
				this.set("SceWarehouse", primaryWarehouse);
			})
		}, this);
	}
}

The "showInformationDialog" function is able to show the correct record.

But, the "SceWarehouse" is still not populated.

Note: "SceWarehouse" field is a lookup based on the "SceWarehouse" section.



Could you help?



Thank you.

I has solved this problem by adding parameter "this" into the "result.collection.each()".

It will be shown as "result.collection.each(function(), this)"

esq.getEntityCollection(function(result) {
	debugger;
	if (!result.success) {
		// For example, error processing/logging.
		this.showInformationDialog("Can't set the location.");
		return;
	}
	result.collection.each(function(item) {
		var primaryWarehouse = {value: item.get("Id"), displayValue: item.get("SceName")};
		this.set("SceWarehouse", primaryWarehouse);
		return;
	}, this)
}, this);

 

Show all comments

Hello everyone.

Can you help me, what Creatio tools we can use to solve the following issue:

We want to implement in Creatio functional that will help our operators effectively help solve the client's problems by tooltips.

depending on the responses, the page should change dynamically

below you can find a picture how we imagine this functional

 

Like 0

Like

1 comments

Hello,

 

Please describe in more detail what features you want to add to Creatio? 

 

Thank you!

Show all comments

Hello colleagues,

 

I didn't find how can I create a Dynamic Folder in LOOKUPS to include my own lookups, from a specific package or with some specific prefix in the name or whatever.

 

Somebody have this need?

 

we want to bind my lookups and the folder to deploy to a production instance, but just can bind the lookups, the static folder where I added them (so cannot create a Dynamic one), but the static folder have no elements, I guess when imported to a new instance the id of the elements is another and didn't include them

 

I have no this problem in folder lookups of System setting, processes and another, just with lookups, I suppose is due to the another folders are dynamic ones.

 

So the question are:

  • It's possible to create a Dynamic Folder to lookups with met the conditions above, and
  • In case it isn't, how can I bind the static folder to lookups content?

 

Thanks in advance

 

Best regards

 

Like 0

Like

5 comments

Hello ,

You can Create Dynamic Folder based on their name . Please see the Attachment.

smit suthar,

Thanks Smith, I know to do this, but I have dozens of Lookups, for this reason I want to do a Dynamic Folder of LOOKUPS using the Starting as Using the Name (with my own prefix) or specifiing the package... But don't know how to get this filter (repeat for lookups)

 

Thanks again

Hello Julio.Falcon_Nodos,



You can create a dynamic folder and add "starts with" filtering for your prefix.




Anton, I have no access to object Code, I mean the internal code name of the lookup. What you get there is the name, localizable, not unique of the lookup, what I need to access is what you see in the image, below, and select "Code starts with Ndos" or "Package = Nodos.BirthdayGreeting"  to get all lookups created in the package in the folder.

Anton Starikov,

Anton, when I saw Name I refer to the internal code name, not to the localizable Name of the lookup, see my comment above. Thanks

Show all comments

I am trying to process a collection of objects. But I am unsure how to pass the collection from a read data element in a business process to a user task. I am also unsure what parameter type I should use on the user task. Can someone tell me the name of a process/user task in creatio I can look at for an example? Or tell me how I can do this?

Like 0

Like

2 comments

Hello, Josh.

I think you can find an example here 

https://academy.creatio.com/docs/user/bpm_tools/process_elements_refere…

Check the example with CompositeObjectList

Hello, Josh.

Check this article 

https://academy.creatio.com/docs/user/bpm_tools/process_elements_refere…

 

Example you need is CompositeObjectList

Show all comments

Hi Community,



Would like to know how enable elastic indexation for object if it have only Freedom UI section?



(If object have old sections - everything is obvious)

,Thanks

Like 1

Like

1 comments

Hello Pavel,

 

Indexation is turned on by default for sections created in the Freedom UI. Currently, there is no option to change it, but we will create an idea for our developers to implement it. 

 

Best Regards,

Anton

Show all comments

Hi Community,

 

Would like to know how we make a list display in FreedomUI editable or make one of it's columns editable.

 

 

Thanks in advance.

 

Regards,

Abilash.S

Like 0

Like

6 comments

Hi Abilash,



As I can see on the screenshot, it's not a freedom UI section.



For the freedom UI section, you can use the Expanded list element

 

And you can make it editable:

Bogdan,

When I open the designer for the above page I'm getting this:



 

As you can see, I don't have the option to make it editable.

 

Abilash,



Is it expanded list element?

Bogdan,

I'm not sure. How do I check that?

 

Abilash,

 

Tis is not a expanded list element this is a Attachment Element

To my pleasant surprise, it appeared that that attachments component became editable since 8.0.7. If you upgrade your instance you should be able to make it editable. 

Show all comments

Hi All,



The requirement is to generate a document where data is stored in detail inside a detail and it should be grouped based on the value in the parent detail.



Scenario Explanation,



We have created a custom section named "Quotes" and a detail inside it named "Parts, Design, Labor Components", this detail has a string column known as "CEID".





And we have detail named "Parts Transformation : Design Paid Upfront" and "Design Transformation : Design Paid Upfront" inside this main detail,





And our final printable document should be in the format like as below, As the CEID group should be common (pointing the main detail) and the parts and design records associated to it should be shown as table (pointing to child details). This printable should generate a single document for all the list of the CEID's and their associated parts and design. 





In OOTB printables, its unable to bring the printables in this format. Is there a way to implement this logic in creatio ?



Regards,

Adharsh S

Like 1

Like

1 comments

Hello,



As far as I understand you need to pull the "Design Transformation : Design Paid Upfront" detail data from the "Parts, Design, Labor Components" detail into Quotes printable. Unfortunately, that would not work since it is not possible to print out the table in the table.

As a workaround to display data in a report from the nested second-level detail data as a hierarchy, you can use an object as a database view. The view can be created using a Common Table Expression (CTE). For example:

WITH  cte AS (
    select
             cast(l1.Name as NVARCHAR(MAX)) as Name,
             l1.Id,
             0 as hierarhy,
             l1.Id as Level1,
             m.Id as MainId
       from Main as m
       join Level1 as l1 on m.Id = l1.MainId
 
    UNION ALL
 
     select
             cast('  -  ' + l2.Name as NVARCHAR(MAX)) as Name,
             l2.Id, 
             1 as hierarhy,
             l2.Level1Id as Level1,
             m.MainId as MainId
       from cte as m
       join Level2 as l2 on m.Id = l2.Level1Id
)
 
SELECT *
FROM   cte
order by Level1, hierarchy

In this example,

Main is the main object, Level1 is the detail that is linked to Main, and Level2 is the detail that is linked to Level1.

As a result, an object can be obtained that joins two tables and displayed the data. Therefore, when creating the necessary columns in the view, they can be used to build the table and output the information row by row.

 

Best regards,

Kate

Show all comments

Hi All,



How to map the related detail records from the section(root schema) with the external web form using landing page integration.



Example Scenario, When we are trying the create a Lead record using the landing page integration. The web form contains the "List of interested Products/Equipment" which is multi-select. When the user selects the values from the multi-select it should create a record in the Product detail in the Lead section. How do we implement this scenario?

 

Like 0

Like

1 comments

Adharsh, 



There is no OOB functionality yet which would allow you to achieve the described goal. 

However, you can consider the possibility of creating this functionality by means of development. 

Following articles can be helpful in this case:

https://academy.creatio.com/docs/developer/application_components/landi…



Thank you. 

Show all comments

Hi Community,

 

We are intending to create a list with editable textboxes like "Price", "Quantity", and "Unit of measure" columns below:



 

Is there any one who know how to do this?

 

Thank you,

Like 0

Like

2 comments

I believe when products will be switched to Freedom UI, probably Creatio 8.1, the lists will be editable :)

Hi Damien,

 

Thank you for your answer. :)

 

Just now I found a way to do that, accidentally. 

 

 

 

Show all comments

Hi Community,

 

Wanted to know if there's a way to load the DCM cycle faster. Currently, it's taking about 5 seconds for it load and would like it to appear sooner. Have attached a photo for your reference.

 

Thanks in advance.

 

Regards,

Abilash.S

 

 

 

File attachments
Like 0

Like

1 comments

Hello,

We have noticed that your DCM is customized. Most likely, these modifications are affecting its loading speed. It is necessary to investigate how the customization can be adjusted to improve the system's performance.

If you try working with the basic functionality, you will see that the transition between stages takes less than 5 seconds.

Show all comments