Files
iTop/templates/components/button/layout.html.twig
Molkobain d2bf4de84c N°2847 - Refactor some early choices
- TWIG: Change calls to object methods from simple notation (eg. oObject.Id) to complete notation (eg. oObject.GetId()) to avoid confusion with use of arrays and variables (eg. aObject.sId)
- UIBlock: $sId should not be first parameter as most of the time it can be ignored and generated by the system
- NewsroomMenu: Rename method for something more less ambiguous
- Html: Embed content in <div /> so we can easily find all such HTML fragments in the UI
2020-08-26 16:03:33 +02:00

6 lines
403 B
Twig

<button id="{{ oUIBlock.GetId() }}" class="ibo-button ibo-is-{{ oUIBlock.GetActionType()}} ibo-is-{{ oUIBlock.GetColor() }}" type="{{ oUIBlock.GetType() }}" name="{{ oUIBlock.GetName() }}" value="{{ oUIBlock.GetValue() }}">
{% if oUIBlock.GetIconClass() is not empty %}
<span class="ibo-button-icon {{ oUIBlock.GetIconClass() }}"></span>
{% endif %}
{{ oUIBlock.GetLabel() }}
</button>