How can i add new page parameter in pre-configured page in default creatio pre-configured page in freedom ui

Like 1

Like

2 comments

In the page designer, expand page parameters and add them there

Ryan

Hi Ryan Farley,

i just want to display the existing data source and the parameter, can i add to the parameter on the pre-configured page with the existing default parameter?

because in here i have most of the parameter but,

on the pre-configured page i just have some of them

Show all comments

Hi community,

Is there any Low-Code possibilty to navigate directlty to Form Page of the created record?

Chain of events

1 - Mini Page is opened and data is entered

2- Mini Page Save evend is performed

3- After the record is created we navigate directly to the created record Form Page

 

Basically we need the symetric operation of this articel but for FreedomUI

https://customerfx.com/article/automatically-navigating-to-the-new-record-created-by-an-add-mini-page-in-creatio/

 

If there is no-code possibility, can you provide a code snippet how to achieve  it?

Sasor

Like 0

Like

1 comments
Best reply

For a no code approach - there really isn't an exact match, the closest possibility is the action "Continue in other page" which will open it in the default page for the entity type (assuming the mini page is set up as the "Add" page). However, that doesn't actually save the record first (just validates it).

For a code approach, you'd need to add a save request handler see here, then use: 

const saveResult = await next.handle(request);
if (saveRequest) {
	// navigate here
}
return saveRequest;

The navigate here part would use this and open the record in edit mode. 

Also, it likely would not be a good idea to do this in the base page for all mini pages, since dialogs can be used for different purposes, not like how it was for mini pages in classic (although I suppose you could check if the current mini page is in add mode).

Ryan 

For a no code approach - there really isn't an exact match, the closest possibility is the action "Continue in other page" which will open it in the default page for the entity type (assuming the mini page is set up as the "Add" page). However, that doesn't actually save the record first (just validates it).

For a code approach, you'd need to add a save request handler see here, then use: 

const saveResult = await next.handle(request);
if (saveRequest) {
	// navigate here
}
return saveRequest;

The navigate here part would use this and open the record in edit mode. 

Also, it likely would not be a good idea to do this in the base page for all mini pages, since dialogs can be used for different purposes, not like how it was for mini pages in classic (although I suppose you could check if the current mini page is in add mode).

Ryan 

Show all comments

When trying to save the page this error popped up. Can you help? What might be the problem?

Like 0

Like

1 comments

Hello!
I recommend checking the application logs, where the error details will be specified. This information can help resolve the generation issue further.

Show all comments

I would like to disable the mini page that appears before the main page in Freedom UI. Currently, when we click on "Next Step," it first opens a mini page before navigating to the main page. Instead, I want it to directly open the main page without this intermediate step.

Like 3

Like

4 comments

Hello,

 

When clicking on the "Complete" button from the next steps, the system will show you the Freedom UI mini page, as this is a Next Steps core logic.

The only way to avoid opening this mini page is to develop your only Next Steps tiles and assign different logic for the complete button.

Dymytriy Vykhodets,

can you please help me where this core logic is written. so that i can try to create new logic.

Dymytriy Vykhodets,

the idea is to open the main page in place of mini page when we click on complete button

Alok Kumar,

Yes, we want to opent the main page directly

 

Show all comments

Hi,

I have a minipage that has lookup (contact) and whenever I try to add a new non-existing it suggests it as "New ContactName" which is nice, but when I click that, it opens the contact minipage and closes the original minipage and doesn't re-open the original minipage after I closed the contact minipage upon saving.

Do you have any idea of a better approach than making a custom modal?

Like 0

Like

3 comments
Best reply

Hi,

I ended up making a Modal [BaseModalBoxPage] to create my own minipage.

I found this code segment in LookupQuickAddMixin and I want to know where can I change the value of UseSilentCreation?
 

/**
		 * Checks that entity has mini page add mode allowed.
		 * @private
		 * @param {String} entitySchemaName Name of the entity.
		 * @param {Array} [additionalDefaultValues] Additional default values.
		 * @return {Boolean} True, if feature UseSilentCreation is turned off, and entity has add mini page.
		 */
		_needOpenMiniPage: function(entitySchemaName, additionalDefaultValues) {
			const entityStructure = this.getEntityStructure(entitySchemaName);
			if (!entityStructure) {
				return false;
			}
			const notUseSilentCreation = !Terrasoft.Features.getIsEnabled("UseSilentCreation");
			const editPages = entityStructure.pages;
			const typeLookupItem = additionalDefaultValues?.find((item) => item.attributeName === "TypeLookup");
			let page;
			if (typeLookupItem) {
				page = editPages.find((page) => page.UId === typeLookupItem.value);
			}
			page = page || Terrasoft.first(editPages);
			const hasAddMiniPage = page?.hasAddMiniPage;
			return notUseSilentCreation && Boolean(hasAddMiniPage);
		},
 
		/**
		 * Open page or mini page for new entity record.
		 * @protected
		 * @param {Object} newEntityConfig Entity config.
		 * @param {Object} newEntityConfig.entitySchema Entity schema.
		 * @param {String} newEntityConfig.entitySchemaName Entity schema name.
		 * @param {String} newEntityConfig.columnName Column name.
		 * @param {String} newEntityConfig.displayColumnValue Display column value.
		 * @param {String} newEntityConfig.valuePairsFromFilters Default values that were sent from filters.
		 * @param {Array} newEntityConfig.additionalDefaultValues Additional default values.
		 * @param {Object} viewModel View model context.
		 */
		openPageForNewEntity: function(newEntityConfig, viewModel) {
			var cardConfig = this._getNewEntityPageConfig(newEntityConfig);
			this._subscribeNewEntityCardModuleResponse(newEntityConfig.attributeName ?? newEntityConfig.columnName, cardConfig, viewModel);
			if (this._needOpenMiniPage(cardConfig.entitySchemaName, newEntityConfig.additionalDefaultValues)) {
				this.openAddMiniPage.call(this, cardConfig);
			} else {
				this._networkUtils.openCardInChain(cardConfig);
			}
			this.set && !newEntityConfig.attributeName && this.set(newEntityConfig.columnName, null);
		},

Hello,

 

It seems that this was already customized since OOB does not allow adding new records to the lookup inside the mini page.

 

As for the UseSilentCreation - it's a system feature with the UseSilentCreation code according to the code in the very same LookupQuickAddMixin

Go to 

 

/0/Nui/ViewModule.aspx#Section/AppFeature_ListPage - for old UI

/0/Shell/#Section/AppFeature_ListPage - Freedom UI

 

find the UseSilentCreation feature (if the record is not present there - create it and enable it for all employees role) and relogin to the app.

Hi,

I ended up making a Modal [BaseModalBoxPage] to create my own minipage.

Show all comments

Hello creatio community,

 

I am trying to apply a filter into cases mini page which is developed using freedom ui screens. Code as below:

{
	request: "crt.LoadDataRequest",
	handler: async (request, next) => {
 
		if(request.dataSourceName == "CaseDS_OPCaseType_4943d10_List_DS") {
			const caseType = await request.$context.CaseDS_OPCaseType_4943d10;
 
			var moduleTypesIds = await OPPermissionFunctionsSsp.getModuleTypes();
 
			const filter = new sdk.FilterGroup();
			if(moduleTypesIds.length > 0){
				filter.logicalOperation = sdk.LogicalOperatorType.Or;		
				for (let i = 0; i < moduleTypesIds.length; i++) {
					await filter.addSchemaColumnFilterWithParameter(sdk.ComparisonType.Equal, "Id", moduleTypesIds[i].value);
				}
			}
			else{
				await filter.addSchemaColumnFilterWithParameter(sdk.ComparisonType.Equal, "OPCode", '');
			}
 
			const newFilter = Object.assign({}, filter);
			newFilter.items = filter.items;
 
			request.parameters.push({
				type: "filter",
				value: newFilter
			});
		}
		return await next?.handle(request);
	}
}

 

The filter newFilter shows the right filter condition. I also used sql profiler and it returned the correct values. The issue here is that the CaseDS_OPCaseType_4943d10_List_DS lookup its not showing any value and does not apply the developed filter.

 

This issue happens only in the mini page. I have used this approach in freedom ui form pages and it works fine. Is there something I'm missing?

 

Kind regards

Like 0

Like

2 comments

I assume this is a dropdown lookup and not a lookup that opens the Select dialog? 

I just double-checked and I do have similar code to filter a dropdown on a Freedom UI mini page/dialog and it is working. I don't see anything that looks incorrect in the code you posted - just wanted to confirm that it does work on mini pages (at least in my case it is)

Show all comments

Hello,
 

I'm facing an issue with the AddTaskMiniPage. When attempting to create a task, I receive the following error message:
 

Field: "Id".
Error: Enter a value after clicking Save.
 

This prevents me from successfully creating tasks. I'm able to create tasks fine in the full window page. Has anyone encountered this issue before or knows how to resolve this?
 

Thanks!

Like 0

Like

3 comments

Hello,

Most likely, the issue lies with a base business rule at the object level that sets this value. I recommend disabling this rule, and after doing so, the behavior should not be repeated.

Best regards,
Antonii.

 


Antonii Viazovskyi,

Hello,

Thanks for your reply.

I disabled all the business rules, but I’m still getting the same result (Field: "Id". Error: Enter a value).

Interestingly, I have no issues if I click the "Continue in other page" button, which takes me to the full-page window.

Any further advice would be appreciated.

Thanks,
Romeo

Romeo Suarez,

 

Hello!

This issue can happen when you have feature DisableModelBindAttributeSynchronization enabled on your site.

To access the feature list, open the following link:
your_site/0/Nui/ViewModule.aspx#Section/AppFeature_ListPage

I hope this helps.
Have a great day!

Show all comments

Hi community,

This is an out of the box problem, because i tried it in a fresh Environment as well.

Here is the issue.

We have the Leads section in the Classic UI, meanwhile the Account section is in the FreedomUI

1-We click to the Account link from the Lead Section:

2- We expect that the Form Page will open since we are not adding a new Account. Instead of the Form Page the MiniPage of the Account opens

3- Status of the Pages established for the account

How can we fix this issue?

Sasor

Like 0

Like

2 comments

Hi Community,

Any update regarding this?

Hello,

 

Please make sure that the "Default page" setting is set to the "Form page" in the Accounts object located in a package that is at the end of the packages hierarchy (it might be in the Custom package). 

This issue might appear if in one of such objects the "Default page" setting is set to "Mini page", which overrides the base settings.

Show all comments

Hi community,

 

I need to show only active users in the Owner field of the activity mini page.

 

How can I do that?

 

Thank you!

Like 1

Like

2 comments

I could not find the field on contact record for this so I created a lookup with record status (active/inactive or something similar) and then used the add filter business rule on the mini page to only display specific owners.

Hi, Clara Fioranzato! 

 

This field is implemented by development methods, so unfortunately you cannot change it with basic methods. 

 

But you can add this filtering condition by creating a replacement view model schema for the page. To do this, use the instructions below with an example of such a setting:  

 

https://academy.creatio.com/docs/8.x/dev/development-on-creatio-platform/platform-customization/classic-ui/record-page/field/examples/set-up-filtering-of-lookup-field-values 

 

We also recommend reading a similar post on our community where this topic has already been raised. 

https://community.creatio.com/questions/show-only-active-users-owner-activity-filed 

 

Best regards, 

Halyna!

Show all comments

Hi Academy,

 

We would like to make one of the sections in the 'Connections' on the activity mini page mandatory when the category is "task".

Do you have any suggestions on how we can accomplish this?

 

Thank you in advance.

Like 1

Like

2 comments

Hello,

 

It depends on which column should be required here. One particular example: this method can be added to ActivityMiniPage:

save: function(callback, scope) {
				var opportunity = this.get("Opportunity");
				if (opportunity) {
					this.callParent(arguments);
				} else {
					Terrasoft.showInformation("Opportunity is required");
				}
			}

In this case saving of the mini page is not possible in case an opportunity is not connected to an activity and the information message will be shown on the page.

Hi Oleg,

 

Thank you, it works!

Show all comments