Hi everyone, I would like to know if it is possible to set default va

Hi everyone,

I would like to know if it is possible to set default values for decimal input fields (in SAIL interfaces) to "zero" value, for example. By default, these values are filled by "null" but i want to change these values How this is possible?

Someone help me, please?

Thanks,

OriginalPostID-188932

OriginalPostID-188932

  Discussion posts and replies are publicly visible

Parents
  • I would be wary about making it a habit to default data using the suggested if() method in the form. If a form field is not interacted with, the field will not save. In this case if zero is not interacted with and it doesn't save zero it probably won't be a problem (since integers default to zero anyways).

    However if you're defaulting a field with something you may expect the user to take (let's say you default a boolean approval to "false") and the user doesn't change it, a null will be saved, not false.

    A better way to default data on a form is to default the value of input in the user input task itself. You can default the data by setting the "value" attribute in the input to the data you want it to default to. Also by defaulting the data being passed in, your interface is more reusable--you could use the same interface but default different data values for different scenarios.
    forum.appian.com/.../Data_Tab.html
Reply
  • I would be wary about making it a habit to default data using the suggested if() method in the form. If a form field is not interacted with, the field will not save. In this case if zero is not interacted with and it doesn't save zero it probably won't be a problem (since integers default to zero anyways).

    However if you're defaulting a field with something you may expect the user to take (let's say you default a boolean approval to "false") and the user doesn't change it, a null will be saved, not false.

    A better way to default data on a form is to default the value of input in the user input task itself. You can default the data by setting the "value" attribute in the input to the data you want it to default to. Also by defaulting the data being passed in, your interface is more reusable--you could use the same interface but default different data values for different scenarios.
    forum.appian.com/.../Data_Tab.html
Children
No Data