ansibleguy76 / ansibleforms

A webapplication to create pretty advanced forms to run ansible playbooks or awx templates.
https://ansibleforms.com/
GNU General Public License v3.0
66 stars 10 forks source link

change default number field value depending of a radio field. #132

Closed ansibleguy76 closed 8 months ago

ansibleguy76 commented 8 months ago

Discussed in https://github.com/ansibleguy76/ansibleforms/discussions/131

Originally posted by **revolonl** January 4, 2024 Hello, i have a Radio field (Small-Medium-Large). I want to set a number field with a number depending of the radio choice (2 if small is selectected, 4 if it's Medium and 8 if it's large) Is it possible, and how ? Thanks.
ansibleguy76 commented 8 months ago

5.0.0 (latest beta), now supports an array of objects with label/value properties.

values:
- label: Red
  code: ff0000
- label: Green
  code: 00ff00
- label: Blue
  code: 0000ff