openmct/platform/forms/res/templates/controls/composite.html
Charles Hacskaylo cc181dbdc9 [Frontend] Form and form control enhancements
WTD-1002
Added Angular hooks to allow form elements to have JSON defined CSS classes
Form element cleanups
2015-03-10 22:36:35 -07:00

18 lines
702 B
HTML

<span ng-controller="CompositeController as compositeCtrl">
<ng-form name="mctFormItem" ng-repeat="item in structure.items">
<div class="l-composite-control l-{{item.control}} {{item.cssclass}}">
<mct-control key="item.control"
ng-model="ngModel[field]"
ng-required="ngRequired || compositeCtrl.isNonEmpty(ngModel[field])"
ng-pattern="ngPattern"
options="item.options"
structure="row"
field="$index">
</mct-control>
<span class="composite-control-label">
{{item.name}}
</span>
</div>
</ng-form>
</span>