Abillity to add buttons next to (expressions / text / enum) form fields and trigger some endpoint / external URL / fn / refresh
Feature:
- Abillity to add buttons next expressions / text / enum and trigger some endpoint / external URL
- Additionally, Buttons can be programmed to execute some expression.
Use case example:
- Button next to free text field, to request an API endpoint for adding data to database.
- Authentication shall be considered also like fn.advancdRest()...
Can you give a more detailed example ? What data would be added to the database for example ? And what if a double click happens, should it add the data twice ? This wouldn't be such a big change, in the end the expression fields already to that (and not that you can have a post in the expressions. The post would then happen once or repost when a dependency changed. And there is a feature to refresh an expression too.
I don't have something specific currently in mind but, using ansible forms daily, I found that this sometimes would be awesome to have a button that calls an FN fuctnion.
- A quick example that comes in mind:
- Lets say "want to add a new user" to a "database" with a "Restapi call" to a custom backend
- A textfield with user email
- [ + ] button next to it that calls the RestAPI with FN function.
- Use User email in extra vars after to some ansible automation for granting priviledges to access a UI
- Another quick example that comes in mind:
- Reset to default button value for a field.
- Next to expression / text field
that is a bit vague isn't it.
It is I agree, but good feature to be able to add buttons in a UI. I only suggest, your application, your choice for adding it or ignoring it! Happy to help! :)
Additionally, you can have a counter and allow the button to be clicked only once or twice or specific number of times