【发布时间】:2018-08-10 19:04:30
【问题描述】:
这是我的垫子按钮:
<button class="example-20-width" mat-raised-button disabled>Edit Client</button>
如何根据选择表单是否为空来控制它并使其禁用?
这是我的字段表单:
<mat-form-field class="example-full-width">
<mat-select placeholder="Select customer">
<mat-option *ngFor="let food of books.data"
[value]="food.company">
{{food.company}}
</mat-option>
<mat-option>
</mat-option>
</mat-select>
</mat-form-field>
【问题讨论】:
-
[disabled]="someCondition"