How to make a list on a form page editable depending on a certain value

Hello, I just have a question about how to make a list on a form page editable when it hits a certain stage. I'm trying to make the associated list on the form, read-only for all statuses except the stage 'In Progress'. I tried to make the list read-only via a business rule, but it does not allow me to add the list in Read-Only. Is there a way make the list read-only via no-code or some easier solution?

 

Like 0

Like

3 comments

The out of the box rules don't work with lists in this way currently. I've not tried this approach with a list yet, but I believe your only option would be to use an attribute bound to the List's editable property and then set that attribute to true/false based on the record's stage.

First, see how to use attributes here: https://customerfx.com/article/using-custom-attributes-on-a-creatio-fre…

The list has a block that looks like this (in this case assuming the attribute is named "IsCensusListEnabled": 

"features": {
	"editable": {
		"enable": false,
		"itemsCreation": false
	}
}

You'd bind your attribute to the editable.enable property

"features": {
	"editable": {
		"enable": "$IsCensusListEnabled",
		"itemsCreation": false
	}
}

Then on a change event for the stage, you'd set that attribute to true/false. See how to listen for changes to the stage here (note, don't include the check for request.silent so it triggers when the page loads also): https://customerfx.com/article/responding-to-an-event-when-a-field-is-changed-on-a-creatio-freedom-ui-page/

Again, I've not tried this approach with a list, but will hopefully work.

Ryan

Another approach would be to have two lists on the page, both set up identical, one editable and the other not editable. Then show and hide those based on the stage. That would be pretty simple to set up and with no code.

Ryan

 

Hello,
 

Ryan's recommendations are indeed helpful and will assist you in implementing your task.
 

On our side, I would like to inform you that we have created a task to implement the ability to configure such business rules in future product releases. 

Best regards,
Pavlo!

Show all comments