script-server icon indicating copy to clipboard operation
script-server copied to clipboard

non-editable parameter

Open antonellocaroli opened this issue 3 years ago • 1 comments

Hi @bugy , I don't know if this question has already been asked.

I was wondering if this possibility existed, I'll give an example.

Let's say I have two parameters

Parameter1 and Parameter2

Parameter2 should only be editable if Parameter1 is equal to a certain value.

I can only do this if Parameter2 is of type "list". by exploiting

"default": {
        "script": "................... '${Param1}'"
      },

So if Parameter1 is equal to something it shows me the list otherwise the field appears as uneditable.

But I cannot do this when the parameter is of type "txt" or "int".

The only thing I can do is that it shows me a message like "NO EDIT". but still the user can edit it if they wish.

antonellocaroli avatar Apr 03 '23 06:04 antonellocaroli

Hi @antonellocaroli this is not possible, but you can use include feature with parameters. You would create a separate configuration file, called smth like Conf certain value.json, this file would contain this extra parameter. And then in the main config, you would specify "include": "Conf ${Parameter1}.json".

bugy avatar Apr 03 '23 07:04 bugy